Browse Source

🎈 perf: 优化显示部分内容

Pchen. 8 months ago
parent
commit
fb8492af83

+ 1 - 1
index.html

@@ -4,7 +4,7 @@
     <meta charset="UTF-8" />
     <meta charset="UTF-8" />
     <link rel="icon" type="image/svg+xml" href="/logo.svg" />
     <link rel="icon" type="image/svg+xml" href="/logo.svg" />
     <meta name="viewport" content="width=1280">
     <meta name="viewport" content="width=1280">
-    <title>RunForge - 智能自助校园乐跑平台</title>
+    <title>RunForge - 智能校园乐跑平台</title>
   </head>
   </head>
   <body>
   <body>
     <div id="app"></div>
     <div id="app"></div>

+ 2 - 2
src/pages/admin/lepaoAccount/accountList.vue

@@ -99,7 +99,7 @@
                     <a-tag color="red" v-else>关闭</a-tag>
                     <a-tag color="red" v-else>关闭</a-tag>
                 </template>
                 </template>
                 <template #num="{ record }">
                 <template #num="{ record }">
-                    {{ record.term_num - record.total_num > 0 ? `${record.total_num} / ${record.term_num}` :
+                    {{ record.term_num != record.total_num ? `${record.total_num} / ${record.term_num}` :
                         '已完成' }}
                         '已完成' }}
                 </template>
                 </template>
                 <template #state="{ record }">
                 <template #state="{ record }">
@@ -479,7 +479,7 @@ const SingleRun = async (item) => {
     if (item.state !== 1)
     if (item.state !== 1)
         return Notification.warning({
         return Notification.warning({
             title: '当前乐跑账号需登录,请登录后再试',
             title: '当前乐跑账号需登录,请登录后再试',
-            content: '如有疑问请联系RunForge客服'
+            content: '如有疑问请联系客服'
         })
         })
     Modal.confirm({
     Modal.confirm({
         title: '开始乐跑',
         title: '开始乐跑',

+ 4 - 4
src/pages/admin/lepaoRecords/lepaoRecords.vue

@@ -77,7 +77,7 @@
             filter: (value, record) => (record.name ?? '').includes(value),
             filter: (value, record) => (record.name ?? '').includes(value),
             slotName: 'name-filter',
             slotName: 'name-filter',
             icon: () => h(IconSearch)
             icon: () => h(IconSearch)
-          }">
+          }" :width="140">
             <template #cell="{ record }">
             <template #cell="{ record }">
               <a-avatar :size="30">
               <a-avatar :size="30">
                 <img :alt="record.name ?? ''"
                 <img :alt="record.name ?? ''"
@@ -86,7 +86,7 @@
               {{ record.name }}
               {{ record.name }}
             </template>
             </template>
           </a-table-column>
           </a-table-column>
-          <a-table-column title="状态" ellipsis tooltip>
+          <a-table-column title="状态" ellipsis tooltip :width="230">
             <template #cell="{ record }">
             <template #cell="{ record }">
               <div class="state">
               <div class="state">
                 <div class="circle one" v-if="record.result.record_failed_reason === '自动确认有效'"></div>
                 <div class="circle one" v-if="record.result.record_failed_reason === '自动确认有效'"></div>
@@ -99,7 +99,7 @@
             filter: (value, record) => (record.result.pass_tit ?? '').includes(value),
             filter: (value, record) => (record.result.pass_tit ?? '').includes(value),
             slotName: 'name-filter',
             slotName: 'name-filter',
             icon: () => h(IconSearch)
             icon: () => h(IconSearch)
-          }">
+          }" :width="220">
             <template #cell="{ record }">
             <template #cell="{ record }">
               {{ record.result.pass_tit }}
               {{ record.result.pass_tit }}
             </template>
             </template>
@@ -124,7 +124,7 @@
               {{ stramptoTime(record.time) }}
               {{ stramptoTime(record.time) }}
             </template>
             </template>
           </a-table-column>
           </a-table-column>
-          <a-table-column title="操作" :width="170" ellipsis tooltip>
+          <a-table-column title="" :width="100" fixed="right">
             <template #cell="{ record }">
             <template #cell="{ record }">
               <a-button @click="$router.push(`/admin/lepaoRecords/${record.id}`)">查看详情</a-button>
               <a-button @click="$router.push(`/admin/lepaoRecords/${record.id}`)">查看详情</a-button>
             </template>
             </template>

+ 1 - 1
src/pages/admin/user/userList.vue

@@ -70,7 +70,7 @@
                     {{ stramptoTime(record.registTime) }}
                     {{ stramptoTime(record.registTime) }}
                 </template>
                 </template>
                 <template #lastTime="{ record }">
                 <template #lastTime="{ record }">
-                    {{ stramptoTime(record.lastTime) }}
+                    {{ stramptoTime(record.lastTime ?? record.registTime) }}
                 </template>
                 </template>
                 <template #optional="{ record }">
                 <template #optional="{ record }">
                     <a-button @click="changeCount(record)">更改次数</a-button>
                     <a-button @click="changeCount(record)">更改次数</a-button>

+ 5 - 11
src/pages/lepao/accountList/index.vue

@@ -135,17 +135,11 @@
               {{ record.sex === 1 ? '男' : (record.sex === 2 ? '女' : '') }}
               {{ record.sex === 1 ? '男' : (record.sex === 2 ? '女' : '') }}
             </template>
             </template>
           </a-table-column>
           </a-table-column>
-          <a-table-column title="学院" :width="220" data-index="academy_name" ellipsis tooltip :filterable="{
-            filter: (value, record) => (record.academy_name ?? '').includes(value),
-            slotName: 'name-filter',
-            icon: () => h(IconSearch)
-          }"></a-table-column>
+          <a-table-column title="年级" :width="70" data-index="grade_id" tooltip></a-table-column>
+          <a-table-column title="学院" :width="220" data-index="academy_name" tooltip></a-table-column>
           <a-table-column title="跑区" :width="130">
           <a-table-column title="跑区" :width="130">
             <template #cell="{ record }">
             <template #cell="{ record }">
-              <div class="vipcontent">
-                <span>{{ record.area || '随机分配' }} </span>
-                <!-- <img src="@/assets/vip.svg" alt="vip" height="20" v-if="record.area"> -->
-              </div>
+              {{ record.area || '随机分配' }}
             </template>
             </template>
           </a-table-column>
           </a-table-column>
           <a-table-column title="通知邮箱" :width="180" data-index="email" ellipsis tooltip></a-table-column>
           <a-table-column title="通知邮箱" :width="180" data-index="email" ellipsis tooltip></a-table-column>
@@ -194,7 +188,7 @@
           </a-table-column>
           </a-table-column>
           <a-table-column title="累计次数" :width="88" ellipsis tooltip>
           <a-table-column title="累计次数" :width="88" ellipsis tooltip>
             <template #cell="{ record }">
             <template #cell="{ record }">
-              {{ record.term_num - record.total_num > 0 ? `${record.total_num} / ${record.term_num}` :
+              {{ record.term_num != record.total_num ? `${record.total_num} / ${record.term_num}` :
                 '已完成' }}
                 '已完成' }}
             </template>
             </template>
           </a-table-column>
           </a-table-column>
@@ -434,7 +428,7 @@ const editAccount = (item) => {
     form.student_num = ''
     form.student_num = ''
     form.email = ''
     form.email = ''
     form.auto_run = 1
     form.auto_run = 1
-    form.auto_time = 7
+    form.auto_time = 8
     form.area = ''
     form.area = ''
     form.notes = ''
     form.notes = ''
   }
   }

+ 2 - 2
src/pages/lepao/lepaoRecords/index.vue

@@ -97,7 +97,7 @@
             </template>
             </template>
 
 
           </a-table-column>
           </a-table-column>
-          <a-table-column title="状态" ellipsis tooltip width="230">
+          <a-table-column title="状态" ellipsis tooltip :width="230">
             <template #cell="{ record }">
             <template #cell="{ record }">
               <div class="state">
               <div class="state">
                 <div class="circle one" v-if="record.result.record_failed_reason === '自动确认有效'"></div>
                 <div class="circle one" v-if="record.result.record_failed_reason === '自动确认有效'"></div>
@@ -135,7 +135,7 @@
               {{ stramptoTime(record.time) }}
               {{ stramptoTime(record.time) }}
             </template>
             </template>
           </a-table-column>
           </a-table-column>
-          <a-table-column title="" :width="170" ellipsis tooltip fixed="right">
+          <a-table-column title="" :width="100" fixed="right">
             <template #cell="{ record }">
             <template #cell="{ record }">
               <a-button @click="$router.push(`/lepao/recordDetail/${record.id}`)">查看详情</a-button>
               <a-button @click="$router.push(`/lepao/recordDetail/${record.id}`)">查看详情</a-button>
             </template>
             </template>

+ 3 - 7
src/router/index.js

@@ -444,7 +444,6 @@ router.beforeEach(async (to, from, next) => {
         }
         }
     }
     }
 
 
-    
     if (to.meta.viewport) {
     if (to.meta.viewport) {
         const meta = document.querySelector('meta[name="viewport"]')
         const meta = document.querySelector('meta[name="viewport"]')
         meta.setAttribute('content', to.meta.viewport)
         meta.setAttribute('content', to.meta.viewport)
@@ -456,13 +455,10 @@ router.beforeEach(async (to, from, next) => {
         if (to.meta.onlyElectron && !electronEnv) return next('/lepao/accountList')
         if (to.meta.onlyElectron && !electronEnv) return next('/lepao/accountList')
     }
     }
 
 
-    if (!to.meta.title) {
-        document.title = 'RunForge - 智能自助校园乐跑平台'
-    } else {
-        document.title = to.meta.title + ' - RunForge'
-    }
+    if (!to.meta.title) document.title = 'RunForge - 智能校园乐跑平台'
+    else document.title = to.meta.title + ' - RunForge'
 
 
     next()
     next()
 })
 })
 
 
-export { routes, router };
+export { routes, router }