Преглед изворни кода

fix:系统指引分页问题修复

johnsen пре 7 месеци
родитељ
комит
d09ef4341b

+ 15 - 7
src/views/component/device/deviceDialog.vue

@@ -276,7 +276,14 @@
                   <el-col :span="8">
                     <el-form-item prop="chuChangRiQi">
                       <template slot="label">
-                        <span class="required">出厂日期:</span>
+                        <span>出厂日期</span>
+                        <el-tooltip
+                          effect="dark"
+                          content="根据使用年限,提前一个月推送提醒"
+                          placement="top"
+                        >
+                          <i class="el-icon-question question-icon">:</i>
+                        </el-tooltip>
                       </template>
                       <el-date-picker
                         v-if="!readonly"
@@ -697,11 +704,12 @@
                             />
                           </el-col>
                         </el-row>
-                        <el-row >
+                        <el-row>
                           <el-col>
                             <el-form-item
-                              :style="{'margin-top': '10px'}" 
-                              label="备注:">
+                              :style="{ 'margin-top': '10px' }"
+                              label="备注:"
+                            >
                               <el-input
                                 v-model="form.remark"
                                 size="mini"
@@ -1309,10 +1317,10 @@ export default {
         ],
         shiFouXiaoZhun: [
           { required: true, message: '是否校准不能为空', trigger: 'blur' }
-        ],
-        chuChangRiQi: [
-          { required: true, message: '出厂日期不能为空', trigger: 'blur' }
         ]
+        // chuChangRiQi: [
+        //   { required: true, message: '出厂日期不能为空', trigger: 'blur' }
+        // ]
       }
     }
   },

+ 8 - 17
src/views/system/dashboard/templates/systemGuide.vue

@@ -11,7 +11,7 @@
           :columns="listConfig.columns"
           :pagination="pagination"
           :loading="loading"
-          :index-row="false"
+          :index-row="true"
           :selection-row="false"
           :display-field="title"
           @row-click="handleRowClick"
@@ -126,7 +126,7 @@ export default {
         ],
         // 表格字段配置
         columns: [
-          { prop: 'sn', label: '序号', width: 60 },
+          // { prop: '$index', label: '序号', width: 60 },
           { prop: 'suoShuXiTong', label: '所属子系统', width: 100 },
           {
             prop: 'gongNengMoKuai',
@@ -192,7 +192,6 @@ export default {
       querySystemGuide(this.getSearchFormData())
         .then((res) => {
           const { dataResult } = res.data
-          const { page, limit } = this.pagination
           const { isEmpty } = this.$utils
           // 无排序字段时,默认按序号排序
           if (isEmpty(this.sorts)) {
@@ -201,17 +200,12 @@ export default {
             })
           }
           // 处理分页
-          const pageResult = {
-            limit,
-            page,
-            totalCount: dataResult.length,
-            totalPages: Math.ceil(dataResult.length / limit)
-          }
+          const pageResult = res.data.pageResult
           const result = {
-            dataResult: dataResult.slice((page - 1) * limit, page * limit),
+            dataResult,
             pageResult
           }
-          // console.log(result)
+          console.log(result)
           ActionUtils.handleListData(this, result)
         })
         .finally(() => {
@@ -254,7 +248,7 @@ export default {
         parameters: this.formatParameters(params),
         ...ActionUtils.formatParams(
           null,
-          { ...this.pagination, limit: 9999 },
+          { ...this.pagination, limit: this.pagination.limit || 100 },
           this.sorts
         )
       }
@@ -388,11 +382,8 @@ export default {
 }
 .home-text-border {
   color: #999999;
-  box-shadow:
-    0 0 0 0 rgba(0, 0, 0, 0.1),
-    0 0 0 0 rgba(0, 0, 0, 0.1),
-    0 0 0 0 rgba(0, 0, 0, 0.1),
-    0 1px 0px 0 rgba(0, 0, 0, 0.1);
+  box-shadow: 0 0 0 0 rgba(0, 0, 0, 0.1), 0 0 0 0 rgba(0, 0, 0, 0.1),
+    0 0 0 0 rgba(0, 0, 0, 0.1), 0 1px 0px 0 rgba(0, 0, 0, 0.1);
   min-height: 20px;
   font-size: 14px;
   margin-left: 60px;