fix travel style
This commit is contained in:
@ -83,15 +83,6 @@ Page({
|
||||
travel.travelDate = Time.toDate(travel.travelAt);
|
||||
travel.travelTime = Time.toTime(travel.travelAt);
|
||||
}
|
||||
|
||||
// 格式化创建和更新时间
|
||||
if (travel.createdAt) {
|
||||
(travel as any).createdAtFormatted = Time.toDateTime(travel.createdAt);
|
||||
}
|
||||
if (travel.updatedAt) {
|
||||
(travel as any).updatedAtFormatted = Time.toDateTime(travel.updatedAt);
|
||||
}
|
||||
|
||||
this.setData({ travel });
|
||||
|
||||
// 获取地点列表
|
||||
@ -151,13 +142,13 @@ Page({
|
||||
}
|
||||
},
|
||||
|
||||
/** 编辑地点 */
|
||||
toEditLocation(e: WechatMiniprogram.BaseEvent) {
|
||||
/** 查看地点详情 */
|
||||
toLocationDetail(e: WechatMiniprogram.BaseEvent) {
|
||||
const { id } = e.currentTarget.dataset;
|
||||
const { travel } = this.data;
|
||||
if (id && travel && travel.id) {
|
||||
wx.navigateTo({
|
||||
url: `/pages/main/travel-location-editor/index?id=${id}&travelId=${travel.id}`
|
||||
url: `/pages/main/travel-location-detail/index?id=${id}&travelId=${travel.id}`
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user