tangning hai 8 meses
pai
achega
b557f05769

+ 6 - 0
src/components/Table/src/BasicTable.vue

@@ -443,4 +443,10 @@
   .ant-table-cell:empty:after,.ant-table-cell span:empty:after {
     content: '-';
   }
+  .ant-table-row-indent {
+    &:after {
+      content: '' !important;
+
+    }
+  }
 </style>

+ 1 - 1
src/views/account/details/data.ts

@@ -209,7 +209,7 @@ export const equityColumns: BasicColumn[] = [
     dataIndex: 'customerTypeStr',
     width: 100,
     customRender: ({ record }) => {
-      return record.customerType == 1 ? '经销' : '直销';
+      return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
     },
   },
   {

+ 3 - 1
src/views/device/editModal.vue

@@ -2,7 +2,7 @@
   <BasicModal
     v-bind="$attrs"
     @register="register"
-    title="编辑"
+    :title="model.title"
     @visible-change="handleVisibleChange"
     @cancel="resetFields"
     @ok="handleSubmit"
@@ -44,6 +44,7 @@
     setup(_, { emit }) {
       const modelRef = ref({
         isUpdate: false,
+        title: '入库',
       });
       const { createMessage } = useMessage();
       const schemas: FormSchema[] = [
@@ -139,6 +140,7 @@
 
       function onDataReceive(data) {
         modelRef.value = data;
+        modelRef.value.title = data.id ? '编辑' : '入库';
         let wifiNamePrefix = data.wifiName.indexOf('YUNPRO_') != -1 ? 'YUNPRO_' : '4DKKPRO_';
         const { type } = data;
         resetFields();

+ 1 - 3
src/views/device/index.vue

@@ -359,7 +359,6 @@
             field: 'colour',
             component: 'Select',
             label: '设备颜色',
-            required: true,
             defaultValue: '黑色',
             colProps: {
               span: 7,
@@ -392,7 +391,6 @@
           {
             field: 'version',
             component: 'Select',
-            required: true,
             label: '设备版本',
             colProps: {
               span: 6,
@@ -488,7 +486,7 @@
         // });
       }
       function put() {
-        openModalEnter(true);
+        openModalEnter(true, {});
       }
       function batchPut() {
         console.log('批量入库');

+ 7 - 7
src/views/device/putModal.vue

@@ -75,7 +75,6 @@
             valueField: 'cameraType',
             immediate: true,
             onChange: (val) => {
-              setFieldsValue({ color: '', wifiNamePrefix: '', version: '标准版' });
               let option = [
                 {
                   label: '标准版',
@@ -91,11 +90,13 @@
                 });
               }
               // ifShow: val == 9 || val == 10
+              let wifiNamePrefixlist = getWifilist(val);
               updateSchema([
                 { field: 'colour', componentProps: { options: getColor(val) } },
                 { field: 'version', componentProps: { options: option } },
-                { field: 'wifiNamePrefix', componentProps: { options: getWifilist(val) } },
+                { field: 'wifiNamePrefix', componentProps: { options: wifiNamePrefixlist } },
               ]);
+              setFieldsValue({ color: '', wifiNamePrefix: wifiNamePrefixlist[0].value, version: '标准版' });
             },
           },
         },
@@ -104,7 +105,6 @@
           component: 'Select',
           label: 'wifi前缀',
           required: true,
-          defaultValue: '4DKKPRO_',
           colProps: {
             span: 18,
           },
@@ -164,13 +164,12 @@
       onMounted(() => {});
       let addListFunc = () => {};
       const [register, { closeModal }] = useModalInner((data) => {
-        // console.log(data);
+        fileFlow.title = data.id ? '编辑' : '设备入库';
         data && onDataReceive(data);
       });
 
       function onDataReceive(data) {
         modelRef.value = data;
-        fileFlow.title = data.id ? '编辑' : '设备入库';
         resetFields();
         let wifiNamePrefix = data.wifiName && data.wifiName.split('_')[0];
         updateSchema([
@@ -201,12 +200,13 @@
                     ],
             },
           },
-          { field: 'wifiNamePrefix', componentProps: { options: getWifilist(data.type || 1) } },
+          { field: 'wifiNamePrefix', show: !data.id,  componentProps: { options: getWifilist(data.type || 1) } },
+          { field: 'snCode', show: !data.id, },
         ]);
         setFieldsValue({
           ...data,
           cameraType: data.type,
-          wifiNamePrefix: wifiNamePrefix + '_',
+          wifiNamePrefix: wifiNamePrefix && (wifiNamePrefix + '_') || '',
         });
       }
       function handleVisibleChange() {}

+ 1 - 1
src/views/empower/algorithm.vue

@@ -80,7 +80,7 @@
           ellipsis: true,
           width: 80,
           customRender: ({ record }) => {
-            return record.customerType == 1 ? '经销' : '直销';
+            return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
           },
         },
         {

+ 1 - 1
src/views/empower/apilist.vue

@@ -101,7 +101,7 @@
           ellipsis: true,
           width: 80,
           customRender: ({ record }) => {
-            return record.customerType == 1 ? '经销' : '直销';
+            return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
           },
         },
         {

+ 1 - 2
src/views/empower/camera.vue

@@ -16,7 +16,6 @@
           :actions="[
             {
               label: '详情',
-              ifShow: getCheckPerm('empowerCamera-detail'),
               onClick: handleDetail.bind(null, record),
             },
             {
@@ -101,7 +100,7 @@
           ellipsis: true,
           width: 80,
           customRender: ({ record }) => {
-            return record.customerType == 1 ? '经销' : '直销';
+            return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
           },
         },
         {

+ 1 - 1
src/views/empower/install.vue

@@ -77,7 +77,7 @@
           ellipsis: true,
           width: 80,
           customRender: ({ record }) => {
-            return record.customerType == 1 ? '经销' : '直销';
+            return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
           },
         },
         {

+ 3 - 3
src/views/order/data.ts

@@ -376,7 +376,7 @@ export const dowmColumns: BasicColumn[] = [
     dataIndex: 'customerTypeStr',
     width: 100,
     customRender: ({ record }) => {
-      return record.customerType == 1 ? '经销' : '直销';
+      return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
     },
   },
   {
@@ -516,7 +516,7 @@ export const localCameraColumns: BasicColumn[] = [
     dataIndex: 'customerTypeStr',
     width: 100,
     customRender: ({ record }) => {
-      return record.customerType == 1 ? '经销' : '直销';
+      return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
     },
   },
   {
@@ -637,7 +637,7 @@ export const differenceColumns: BasicColumn[] = [
     dataIndex: 'customerTypeStr',
     width: 100,
     customRender: ({ record }) => {
-      return record.customerType == 1 ? '经销' : '直销';
+      return record.customerType == 1 ? '经销' : record.customerType == 0 ? '直销' : '';
     },
   },
   {