update style

This commit is contained in:
Timi
2025-12-17 16:16:10 +08:00
parent 423775c255
commit 369cfe2bf2
40 changed files with 375 additions and 507 deletions

View File

@ -7,7 +7,7 @@ import { TravelStatus, TransportationType } from "../../../types/Travel";
interface TravelEditorData {
/** 模式create 或 edit */
mode: "create" | "edit";
/** 行 ID编辑模式 */
/** 行 ID编辑模式 */
id?: number;
/** 标题 */
title: string;
@ -105,7 +105,7 @@ Page({
});
}
},
/** 加载行详情(编辑模式) */
/** 加载行详情(编辑模式) */
async loadTravelDetail(id: number) {
wx.showLoading({ title: "加载中...", mask: true });
try {
@ -230,7 +230,7 @@ Page({
this.updateTravel();
}
},
/** 创建行 */
/** 创建行 */
async createTravel() {
this.setData({ isSaving: true });
@ -238,9 +238,7 @@ Page({
await TravelApi.create({
title: this.data.title.trim(),
content: this.data.content.trim(),
travelAt: this.data.travelAtUndecided
? null
: new Date(`${this.data.date}T${this.data.time}:00`).getTime(),
travelAt: this.data.travelAtUndecided ? null : Time.now(),
days: this.data.daysUndecided ? null : this.data.days,
transportationType: this.data.transportationType,
status: this.data.status
@ -256,7 +254,7 @@ Page({
this.setData({ isSaving: false });
}
},
/** 更新行 */
/** 更新行 */
async updateTravel() {
this.setData({ isSaving: true });
try {
@ -283,7 +281,7 @@ Page({
this.setData({ isSaving: false });
}
},
/** 删除行 */
/** 删除行 */
deleteTravel() {
this.setData({
deleteDialogVisible: true,