tangning 1 dzień temu
rodzic
commit
a40c696a83

+ 3 - 2
src/views/productOperation/data.ts

@@ -1,7 +1,8 @@
 import { BasicColumn } from '/@/components/Table';
 import { SCENE_TYPE } from '/@/settings/siteSetting';
 import { Time } from '/@/components/Time';
-import { pageAuthList, sceneGroupCount, cameraList } from '/@/api/jyUserPlatform/index'; //roleLIstApi
+import { sceneGroupCount, cameraList } from '/@/api/jyUserPlatform/index'; //roleLIstApi
+import { platformList } from '/@/api/statistics/index'; //roleLIstApi
 import dayjs from 'dayjs';
 import { h } from 'vue';
 export const columns: BasicColumn[] = [
@@ -433,7 +434,7 @@ export const searchFormData = (show) => [
     componentProps: {
       style: { maxWidth: '250px', placeholder: '全部' },
       placeholder: '全部',
-      api: pageAuthList,
+      api: platformList,
       immediate: false,
       resultField: 'list',
       labelField: 'platformName',

+ 6 - 3
src/views/statistics/scene/addModal.vue

@@ -92,10 +92,11 @@ import { formatStrategyValues } from 'ant-design-vue/lib/vc-tree-select/utils/st
                   return Promise.reject('人员编号不存在');
                 }
                 Promise.resolve();
-                let ryNickName = res && res.data && res.data.ryNickName;
+                let ryNickName = res && res.data && res.data.ryNickName || '暂无姓名';
+                console.log('ryNickName', ryNickName, myData.ryNickName);
                 if(myData.ryNickName != ryNickName || !myData.ryNickName){
                   setFieldsValue({
-                    ryNickName: res && res.data ? res.data.ryNickName : '',
+                    ryNickName: ryNickName,
                     jyId: res && res.data ? res.data.id : '',
                   });
                 }
@@ -111,6 +112,7 @@ import { formatStrategyValues } from 'ant-design-vue/lib/vc-tree-select/utils/st
           field: 'ryNickName',
           component: 'Input',
           label: '姓名',
+          required: false,
           colProps: {
             span: 20,
           },
@@ -213,10 +215,11 @@ import { formatStrategyValues } from 'ant-design-vue/lib/vc-tree-select/utils/st
       }
       const handleSubmit = async () => {
         const params = await validate();
+        console.log('params', params);
         try {
-          console.log('params', params);
           await pageDataAuth({
             ...params,
+            ryNickName: params.ryNickName == '暂无姓名' ? '' : params.ryNickName,
             pageAuth: 1,
           });
           closeModal();

+ 2 - 2
src/views/statistics/scene/exportModal.vue

@@ -23,7 +23,7 @@
   import { useMessage } from '/@/hooks/web/useMessage';
   import { useI18n } from '/@/hooks/web/useI18n';
   import { getinnerByRyId, userShareAdd } from '/@/api/operate';
-  import { sceneGroupCount } from '/@/api/jyUserPlatform/index'; //roleLIstApi
+  import { cameraList } from '/@/api/jyUserPlatform/index'; //roleLIstApi
   import { exportSceneList } from '/@/api/statistics/index'; //roleLIstApi
   import { district, jyType } from '/@/views/statistics/scene/data';
 
@@ -86,7 +86,7 @@
           componentProps: {
             style: { maxWidth: '297px' },
             placeholder: '全部',
-            api: sceneGroupCount,
+            api: cameraList,
             mode: 'multiple',
             immediate: false,
             resultField: 'list',

+ 2 - 2
src/views/statistics/scene/index.vue

@@ -106,7 +106,7 @@
 <script lang="ts" setup>
   import { ref, onMounted, reactive } from 'vue';
   import { renameTreeFields } from '/@/utils/treeUtils';
-  import { sceneGroupCount, getDistrict, getJyType } from '/@/api/jyUserPlatform/index'; //roleLIstApi
+  import { cameraList, getDistrict, getJyType } from '/@/api/jyUserPlatform/index'; //roleLIstApi
   import { sceneTotal, sceneTrend, platformList } from '/@/api/statistics/index';
   import VisitSource from '../components/VisitSource.vue';
   import lineEcharts2 from '../components/lineEcharts2.vue';
@@ -155,7 +155,7 @@
     ssobjList: [],
     echartTypr: 'bar',
   });
-  sceneGroupCount({ type: 'camera' }).then((res) => {
+  cameraList({ type: 'camera' }).then((res) => {
     options.value = res.map((ele) => ({ label: ele.name, value: ele.id }));
   });
   const echartData = reactive({