Sfoglia il codice sorgente

fix(bugs): 修改优化

tangning 3 anni fa
parent
commit
dda347498e

+ 6 - 5
src/views/rightsEnterprises/addModal.vue

@@ -150,6 +150,7 @@
         console.log('Data Received', data);
         // 方式1;
         resetFields();
+        reloadSubtable();
         modelRef.companyId = data.companyId;
         setFieldsValue({
           ...data,
@@ -270,11 +271,11 @@
           }
         });
         console.log('look', look, shoot, 'shotNum, lookNum', shotNum, lookNum, newUser);
-        if ((newUser.roleId == 8 || newUser.roleId == 81) && !(look < lookNum)) {
-          return createMessage.error('可带看员工数不足');
-        } else if ((newUser.roleId == 8 || newUser.roleId == 82) && !(shoot < shotNum)) {
-          return createMessage.error('可拍摄员工数不足');
-        }
+        // if ((newUser.roleId == 8 || newUser.roleId == 81) && !(look < lookNum)) {
+        //   return createMessage.error('可带看员工数不足');
+        // } else if ((newUser.roleId == 8 || newUser.roleId == 82) && !(shoot < shotNum)) {
+        //   return createMessage.error('可拍摄员工数不足');
+        // }
         minNumber.lookNum = lookNum;
         minNumber.shotNum = shotNum;
         let obj = {

+ 6 - 7
src/views/rightsEnterprises/camera.vue

@@ -13,13 +13,12 @@
       <template #status="{ record }">
         {{ renderStatus(record.state) }}
       </template>
-      <template #createTime="{ record, field }">
-        <Time :value="record[field]" mode="datetime" />
+      <template #createTime="{ record }">
+        <Time :value="record.createTime" mode="datetime" />
+      </template>
+      <template #incrementEndTime="{ record }">
+        <Time :value="record.incrementEndTime" mode="datetime" />
       </template>
-      <!-- onClick: handleOpenModal.bind(null, record), 
-            ifShow: record.state == 0 && !!record.userId,
-            ifShow: !!record.userId,
-      -->
       <template #action="{ record }">
         <TableAction
           :actions="[
@@ -147,7 +146,7 @@
         {
           title: t('routes.rightsEnterprises.expirationTime'),
           dataIndex: 'incrementEndTime',
-          // slots: { customRender: 'createTime' },
+          slots: { customRender: 'incrementEndTime' },
           width: 160,
         },
         {

+ 7 - 7
src/views/rightsEnterprises/cameraList.vue

@@ -106,30 +106,30 @@
         {
           title: t('routes.rightsEnterprises.companyName'),
           dataIndex: 'name',
-          width: 160,
+          width: 180,
         },
         {
           title: t('routes.rightsEnterprises.companyPhone'),
           dataIndex: 'phone',
-          width: 120,
+          width: 150,
         },
         {
           title: t('routes.rightsEnterprises.kk'),
           dataIndex: 'proIncrementNum',
-          width: 130,
+          width: 80,
         },
 
         {
           title: t('routes.rightsEnterprises.kj'),
           dataIndex: 'seeIncrementNum',
-          sorter: true,
-          width: 130,
+          // sorter: true,
+          width: 80,
         },
         {
           title: t('routes.rightsEnterprises.ss'),
           dataIndex: 'sensorIncrementNum',
           // slots: { customRender: 'createTime' },
-          width: 130,
+          width: 80,
         },
         {
           title: '操作',
@@ -137,7 +137,7 @@
           ifShow: !getCheckRole('tourist'),
           slots: { customRender: 'action' },
           fixed: 'right',
-          width: 120,
+          width: 80,
         },
       ];
 

+ 1 - 1
src/views/rightsEnterprises/enterprises.vue

@@ -114,7 +114,7 @@
         {
           title: t('routes.staff.createTime'),
           dataIndex: 'createTime',
-          slots: { customRender: 'createTime' },
+          // slots: { customRender: 'createTime' },
           width: 130,
         },
         {

+ 3 - 3
src/views/rightsEnterprises/list.vue

@@ -148,19 +148,19 @@
         {
           title: t('routes.rightsEnterprises.createTime'),
           dataIndex: 'createTime',
-          slots: { customRender: 'createTime' },
+          // slots: { customRender: 'createTime' },
           width: 160,
         },
         {
           title: t('routes.rightsEnterprises.activationTime'),
           dataIndex: 'activationTime',
-          slots: { customRender: 'createTime' },
+          // slots: { customRender: 'createTime' },
           width: 160,
         },
         {
           title: t('routes.rightsEnterprises.expirationTime'),
           dataIndex: 'expirationTime',
-          slots: { customRender: 'createTime' },
+          // slots: { customRender: 'createTime' },
           width: 160,
         },
         {

+ 11 - 11
src/views/rightsEnterprises/rightsList.vue

@@ -32,7 +32,7 @@
               onClick: handleEdit.bind(null, record),
             },
             {
-              color: 'warning',
+              color: 'success',
               label: t('routes.rightsEnterprises.add'),
               onClick: handleOpenModal.bind(null, record),
             },
@@ -108,7 +108,7 @@
         {
           title: t('routes.rightsEnterprises.companyPhone'),
           dataIndex: 'companyPhone',
-          width: 80,
+          width: 120,
         },
         {
           title: t('routes.rightsEnterprises.userPermNum'),
@@ -119,22 +119,22 @@
         {
           title: t('routes.rightsEnterprises.exUserPermNum'),
           dataIndex: 'exUserPermNum',
-          sorter: true,
-          width: 130,
-        },
-        {
-          title: t('routes.staff.createTime'),
-          dataIndex: 'createTime',
-          slots: { customRender: 'createTime' },
-          width: 130,
+          // sorter: true,
+          width: 120,
         },
+        // {
+        //   title: t('routes.staff.createTime'),
+        //   dataIndex: 'createTime',
+        //   // slots: { customRender: 'createTime' },
+        //   width: 130,
+        // },
         {
           title: '操作',
           dataIndex: '',
           ifShow: !getCheckRole('tourist'),
           slots: { customRender: 'action' },
           fixed: 'right',
-          width: 120,
+          width: 80,
         },
       ];
 

+ 3 - 3
src/views/rightsEnterprises/staff.vue

@@ -123,19 +123,19 @@
         {
           title: t('routes.rightsEnterprises.createTime'),
           dataIndex: 'createTime',
-          slots: { customRender: 'createTime' },
+          // slots: { customRender: 'createTime' },
           width: 160,
         },
         {
           title: t('routes.rightsEnterprises.activationTime'),
           dataIndex: 'activationTime',
-          slots: { customRender: 'createTime' },
+          // slots: { customRender: 'createTime' },
           width: 160,
         },
         {
           title: t('routes.rightsEnterprises.expirationTime'),
           dataIndex: 'expirationTime',
-          slots: { customRender: 'createTime' },
+          // slots: { customRender: 'createTime' },
           width: 160,
         },
         {