Przeglądaj źródła

设计人员报表增加公司查询条件

朱鑫波 4 lat temu
rodzic
commit
8317b147aa

+ 27 - 3
src/views/modules/Statistics/designerReport/designerReport.vue

@@ -39,6 +39,18 @@
                         </a-form-item>
                     </a-col>
                     <a-col :md="8" :sm="8" :xxl="6">
+                        <a-form-item label="公司">
+                            <a-select
+                                v-decorator="['companyId',{initialValue:''}]"
+                                placeholder="请选择"
+                                allow-clear
+                            >
+                                <a-select-option :value="''">不限</a-select-option>
+                                <a-select-option v-for="(item, index) in allCompany" :value="item.companyId">{{ item.companyName }} </a-select-option>
+                            </a-select>
+                        </a-form-item>
+                    </a-col>
+                    <a-col :md="8" :sm="8" :xxl="6">
                         <span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
                             <a-button type="primary" icon="search" @click="handleQueryList">查询</a-button>
                             <a-button type="primary" @click="handleResetForm" icon="reload" class="middle-button">重置</a-button>
@@ -125,6 +137,7 @@ import selectTable from '@/views/modules/Statistics/components/selectPagination.
 import ChartCard from '@/components/ChartCard';
 import Trend from '@/components/Trend';
 import { stopOtherVideo, closeAllVideoFun } from '@/utils/videoControl'; // 停止除当前外的其他视频播放,及停止所有视频播放的方法
+import { getAction } from '../../../../api/manage';
 export default {
     components: {
         selectTable,
@@ -141,6 +154,7 @@ export default {
             projectId: '',
             dataSource: [],
             dataLoading: false,
+            allCompany: [],
             columns: [ {
                     title: '设计人员',
                     dataIndex: 'realname',
@@ -206,7 +220,8 @@ export default {
                     // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
                     this.ipagination.current = current;
                     this.ipagination.pageSize= pageSize;
-                    this.handleGetTableList({})
+                    const paramsData = this.form.getFieldsValue();
+                    this.handleGetTableList(paramsData)
                 }
             },
             totalData: null
@@ -229,11 +244,11 @@ export default {
             // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
             this.ipagination.current = current;
             this.ipagination.pageSize= pageSize;
-            this.handleGetTableList({})
+            const paramsData = this.form.getFieldsValue();
+            this.handleGetTableList(paramsData)
         },
         handleQueryList() {
             this.ipagination.current = 1;
-            event.preventDefault();
             const paramsData = this.form.getFieldsValue();
             this.handleGetTableList(paramsData);
         },
@@ -249,6 +264,7 @@ export default {
             const paramsData = {
                 realname: data.realname,
                 roleCode: data.roleCode ? data.roleCode === '' ? null : data.roleCode : null,
+                companyId: data.companyId ? data.companyId === '' ? null : data.companyId : null,
                 startTime: this.timeRange&&this.timeRange.length === 2 ?  moment(this.timeRange[0]).format('YYYY-MM-DD') : null,
                 endTime: this.timeRange&&this.timeRange.length === 2 ?  moment(this.timeRange[1]).format('YYYY-MM-DD') : null,
                 pageNo:  this.ipagination.current,
@@ -276,9 +292,17 @@ export default {
                 console.log(error, 'eeee');
             });
         },
+        getAllCompany() {
+            getAction('/system/userCompany/allCompany').then(res => {
+                if(res.success) {
+                    this.allCompany = res.result;
+                }
+            })
+        }
     },
     mounted() {
         this.handleGetTableList({});
+        this.getAllCompany();
     },
 }
 </script>

+ 2 - 2
vue.config.js

@@ -77,10 +77,10 @@ module.exports = {
         // target: 'http://192.168.1.43:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.1.43:8806', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.0.252:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
-        // target: 'http://192.168.1.219:8081', //请求本地 需要jeecg-boot后台项目  赵西安
+        target: 'http://192.168.1.219:8081', //请求本地 需要jeecg-boot后台项目  赵西安
         // target: 'http://192.168.1.193:8080', //请求本地 需要jeecg-boot后台项目  李煜一
         // target: 'http://192.168.1.193:31012', //请求本地 需要jeecg-boot后台项目  李煜一
-         target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
+        //  target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'https://trac.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'http://39.106.184.70:8088/', //请求本地 需要jeecg-boot后台项目
         //  target: 'http://adsp.tjyourong.com.cn/', //请求本地 需要jeecg-boot后台项目