diff --git a/pages/institutionalStructure/mixins/donation-mixin.js b/pages/institutionalStructure/mixins/donation-mixin.js index 8a34b27..b014fdb 100644 --- a/pages/institutionalStructure/mixins/donation-mixin.js +++ b/pages/institutionalStructure/mixins/donation-mixin.js @@ -91,12 +91,13 @@ export const donationMixin = { * @returns {string} 格式化后的日期 */ formatDate(dateStr) { - if (!dateStr) return ""; - const date = new Date(dateStr); - const year = date.getFullYear(); - const month = String(date.getMonth() + 1).padStart(2, "0"); - const day = String(date.getDate()).padStart(2, "0"); - return `${year}/${month}/${day}`; + return this.$u.date(dateStr, "yyyy-MM-dd"); + // if (!dateStr) return ""; + // const date = new Date(dateStr); + // const year = date.getFullYear(); + // const month = String(date.getMonth() + 1).padStart(2, "0"); + // const day = String(date.getDate()).padStart(2, "0"); + // return `${year}/${month}/${day}`; }, /** diff --git a/pages/memorial/compositons/enshrinedList.vue b/pages/memorial/compositons/enshrinedList.vue index 590bddf..635ed83 100644 --- a/pages/memorial/compositons/enshrinedList.vue +++ b/pages/memorial/compositons/enshrinedList.vue @@ -16,10 +16,16 @@ class="table-row" @click="handleItemClick(item)" > - {{ item.worshiperName || '未知' }} - {{ formatDate(item.startDate) }} + {{ + item.worshiperName || "未知" + }} + {{ + formatDate(item.startDate) + }} {{ formatDate(item.endDate) }} - {{ item.thaliName || '未知类型' }} + {{ + item.thaliName || "未知类型" + }} @@ -42,324 +48,326 @@ diff --git a/pages/memorial/compositons/enshrinedListIndex.vue b/pages/memorial/compositons/enshrinedListIndex.vue index 652054b..b3a1d9c 100644 --- a/pages/memorial/compositons/enshrinedListIndex.vue +++ b/pages/memorial/compositons/enshrinedListIndex.vue @@ -16,10 +16,16 @@ class="table-row" @click="handleItemClick(item)" > - {{ item.worshiperName || '未知' }} - {{ formatDate(item.startDate) }} + {{ + item.worshiperName || "未知" + }} + {{ + formatDate(item.startDate) + }} {{ formatDate(item.endDate) }} - {{ item.thaliName || '未知类型' }} + {{ + item.thaliName || "未知类型" + }} @@ -42,324 +48,326 @@