qinbai há 3 anos atrás
pai
commit
4849db2603

+ 4 - 1
src/api/workManagement/mainProject.js

@@ -119,10 +119,13 @@ export function masterCheck(id) {
   })
 }
 //统计列表下载
-export function statisticalAnalysis() {
+export function statisticalAnalysis(params) {
   return request({
     url: '/api/trade-project/project/statisticalAnalysis',
     method: 'get',
+    params:{
+      ...params
+    }
   })
 }
 

+ 5 - 3
src/components/check/check.vue

@@ -122,9 +122,11 @@
                 this.$emit("choceCheckFun")
               }
               if(!this.checkDetail){
-                this.$router.$avueRouter.closeTag();
-                this.$router.back();
-                this.$router.push({path: "/approveData/index"})
+                //关闭付费申请页面
+                let tag = this.$store.getters.tagList.filter(ele => ele.label === "付费申请")[0]
+                this.$store.commit('DEL_TAG', tag)
+                this.$store.commit("PQ_OUT_DETAIL");
+                this.$router.back(-1)
               }
             }).finally(()=>{
               this.buttonLoading = false

+ 16 - 0
src/router/views/index.js

@@ -520,6 +520,22 @@ export default [{
       }
     ]
   },
+  // 业绩分析
+  {
+    path: '/workManagement/performanceAnalysis/index',
+    component: Layout,
+    hidden: true,
+    children: [
+      {
+        path: '/workManagement/performanceAnalysis/index',
+        name:"业绩分析",
+        meta: {
+          keepAlive:true,
+        },
+        component: () => import( /* webpackChunkName: "views" */ '@/views/workManagement/performanceAnalysis/index')
+      }
+    ]
+  },
   // 结算详情页
   {
     path: '/workManagement/receipt/settleAccounts',

+ 4 - 9
src/views/approveData/index.vue

@@ -27,12 +27,6 @@
                    @click.stop="batchCheck"
         >批量审批
         </el-button>
-        <el-button size="small"
-                   type="info"
-                   :disabled="true"
-                   @click.stop=""
-        >报表
-        </el-button>
       </template>
       <template slot-scope="scope" slot="menu">
         <el-button
@@ -103,7 +97,8 @@
   import { getList,approvePass } from "@/api/approveData/main";
   import checkSchedule from "@/components/check/checkSchedule";
   import check from "@/components/check/check";
-
+let previousRouterName = ""
+  let checkRefresh = ""
   export default {
     components:{
       check,
@@ -262,8 +257,8 @@
       sizeChange() {
         console.log('1')
       },
-      refreshChange() {
-        this.onLoad(this.page);
+      refreshChange(params) {
+        this.onLoad(this.page,params);
       },
       paramsAdjustment(params) {
         params = Object.assign({}, this.search);

+ 10 - 1
src/views/financialManagement/paymentRequest/paymentRequestDetails.vue

@@ -95,6 +95,15 @@
               </el-option>
             </el-select>
           </template>
+          <template slot="remark">
+            <el-input type="textarea"
+                      v-model="form.remark"
+                      size="small"
+                      rows="2"
+                      autocomplete="off"
+                      placeholder="">
+            </el-input>
+          </template>
         </avue-form>
       </basic-container>
       <containerTitle title="明细列表"></containerTitle>
@@ -596,7 +605,7 @@
         this.option.column.forEach(item =>{
           if( item.prop == "remark" ){
             this.$set(item,"disabled",(this.auditDisabled || false))
-          }else if( item.prop == "createUserName" ||  item.prop == "createTime" ){
+          }else if( item.prop == "createUserName" ||  item.prop == "createTime" || item.prop == "sysNo"){
             this.$set(item,"disabled",true)
           }else{
             this.$set(item,"disabled",this.checkDisabled)

+ 1 - 1
src/views/purchase/contract/detailsPage.vue

@@ -1012,7 +1012,7 @@ export default {
         srcOrderno:this.form.orderNo,
         itemType:"采购",    //区分采购还是销售
         optionType:'JK',   //区分贸易类型
-        billNoList: this.contactsData.map(item =>{return item.billNo}),
+        billNoList: Array.from(new Set( this.contactsData.map(item =>{return item.billNo}))),
         price:this.form.salesPrice,
         corpsName:this.form.corpsName,
         corpId:this.form.corpId,

+ 13 - 0
src/views/wel/components/audit-data.vue

@@ -31,6 +31,9 @@
 <script>
 export default {
   name: "basicContainer",
+  props: {
+    sysType: Number
+  },
   data() {
     return {
       loading: false,
@@ -43,7 +46,17 @@ export default {
       ]
     };
   },
+  mounted() {
+    this.init()
+  },
   methods: {
+    init(){
+      if(this.sysType === 5){
+        this.list = [
+          { icon: "el-icon-s-order", qty: "0", text: "主营业务/待审核" },
+        ]
+      }
+    },
     refresh() {
       this.loading = true;
       setTimeout(() => {

+ 25 - 7
src/views/wel/components/quick-launch.vue

@@ -7,34 +7,42 @@
         </span>
       </div>
       <div class="content">
-        <div class="content-icon" @click="inPage('xs')">
+        <div class="content-icon" v-if="sysType !== 5" @click="inPage('xs')">
           <i class="tradingIcon icon-sales" style="color:#409EFF"></i>
           <span>销售</span>
         </div>
-        <div class="content-icon" @click="inPage('cg')">
+        <div class="content-icon" v-if="sysType !== 5" @click="inPage('cg')">
           <i class="tradingIcon icon-purchase" style="color:#75CD28"></i>
           <span>采购</span>
         </div>
-        <div class="content-icon" @click="inPage('fh')">
+        <div class="content-icon" v-if="sysType !== 5" @click="inPage('fh')">
           <i class="tradingIcon icon-ship" style="color:#143056"></i>
           <span>发货</span>
         </div>
-        <div class="content-icon" @click="inPage('sh')">
+        <div class="content-icon" v-if="sysType !== 5" @click="inPage('sh')">
           <i class="tradingIcon icon-receipt" style="color:#921939"></i>
           <span>收货</span>
         </div>
-        <div class="content-icon" @click="inPage('sqfk')">
+        <div class="content-icon" v-if="sysType !== 5" @click="inPage('sqfk')">
           <i class="tradingIcon icon-apply" style="color:#BE3216"></i>
           <span>申请付款</span>
         </div>
-        <div class="content-icon" @click="inPage('sf')">
+        <div class="content-icon" v-if="sysType !== 5" @click="inPage('sf')">
           <i class="tradingIcon icon-charge" style="color:#4D6016"></i>
           <span>收费</span>
         </div>
-        <div class="content-icon" @click="inPage('ff')">
+        <div class="content-icon" v-if="sysType !== 5" @click="inPage('ff')">
           <i class="tradingIcon icon-pay" style="color:#7E8270"></i>
           <span>付费</span>
         </div>
+        <div class="content-icon" v-if="sysType === 5" @click="inPage('zy')">
+          <i class="tradingIcon icon-pay" style="color:#57927a"></i>
+          <span>主营业务</span>
+        </div>
+        <div class="content-icon" v-if="sysType === 5" @click="inPage('yf')">
+          <i class="tradingIcon icon-pay" style="color:#576892"></i>
+          <span>业绩分析</span>
+        </div>
       </div>
     </el-card>
   </div>
@@ -108,7 +116,17 @@ export default {
             );
             break;
         }
+      }else if (this.sysType == 5) {
+        switch (type) {
+          case "zy":
+            this.$router.push("/workManagement/main-items/list");
+            break;
+          case "yf":
+            this.$router.push("/workManagement/performanceAnalysis/index");
+            break;
+        }
       }
+
     }
   }
 };

+ 1 - 1
src/views/wel/home/defaultPage.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="container">
     <quick-launch class="item1" :sysType="sysType" />
-    <audit-data class="item2" />
+    <audit-data class="item2" :sysType="sysType"/>
     <realtime-data class="item3" />
     <sales-reached class="item4" />
     <sales-trend class="item5" />

+ 6 - 0
src/views/workManagement/main-items/detailsPage.vue

@@ -1050,6 +1050,12 @@
           }
         })
       },
+      copyData(){
+        if(this.verificationData()){
+          delete this.form.id
+          delete this.formTwo.id
+        }
+      },
       createData(){
         if(this.verificationData()){
           this.$confirm("确定创建新的单据吗?", "提示", {

+ 14 - 6
src/views/workManagement/performanceAnalysis/config/clientList.json

@@ -3,7 +3,7 @@
   "tip": false,
   "simplePage": true,
   "searchShow": true,
-  "searchMenuSpan": 8,
+  "searchMenuSpan": 24,
   "dialogWidth": "60%",
   "align": "center",
   "searchSpan": 8,
@@ -20,7 +20,7 @@
   "searchIcon": true,
   "searchIndex": 2,
   "addBtn":false,
-  "menu": true,
+  "menu": false,
   "headerAlign": "center",
   "column": [
     {
@@ -63,15 +63,16 @@
     {
       "label": "客户名称",
       "prop": "corpNames",
+      "search": true,
       "overHidden": true,
-      "width": 200,
+      "width": 120,
       "index": 2
     },
     {
-      "label": "制单人数量",
-      "prop": "countCreateUser",
+      "label": "承做人数量",
+      "prop": "countUserName",
       "overHidden": true,
-      "width": 200,
+      "width": 120,
       "index": 3
     },
     {
@@ -157,6 +158,13 @@
       "overHidden": true,
       "width": 90,
       "index": 8
+    },
+    {
+      "label": "合计",
+      "prop": "total",
+      "overHidden": true,
+      "width": 90,
+      "index": 8
     }
   ]
 }

+ 13 - 6
src/views/workManagement/performanceAnalysis/config/mainList.json

@@ -3,7 +3,7 @@
   "tip": false,
   "simplePage": true,
   "searchShow": true,
-  "searchMenuSpan": 8,
+  "searchMenuSpan": 24,
   "dialogWidth": "60%",
   "align": "center",
   "searchSpan": 8,
@@ -20,7 +20,7 @@
   "searchIcon": true,
   "searchIndex": 2,
   "addBtn":false,
-  "menu": true,
+  "menu": false,
   "headerAlign": "center",
   "column": [
     {
@@ -61,17 +61,18 @@
       ]
     },
     {
-      "label": "制单人",
-      "prop": "createUserName",
+      "label": "承做人",
+      "prop": "userName",
       "overHidden": true,
-      "width": 200,
+      "search": true,
+      "width": 120,
       "index": 3
     },
     {
       "label": "客户数量",
       "prop": "countCorp",
       "overHidden": true,
-      "width": 200,
+      "width": 120,
       "index": 3
     },
     {
@@ -157,6 +158,12 @@
       "overHidden": true,
       "width": 90,
       "index": 8
+    }, {
+      "label": "合计",
+      "prop": "total",
+      "overHidden": true,
+      "width": 90,
+      "index": 8
     }
   ]
 }

+ 66 - 30
src/views/workManagement/performanceAnalysis/index.vue

@@ -15,7 +15,9 @@
                @refresh-change="refreshChange"
                @on-load="onLoad">
       <template slot="flagSearch">
-        <el-select   v-model="search.flag"  placeholder="" >
+        <el-select
+          v-model="search.flag"
+          placeholder="" >
           <el-option
             v-for="item in flagOptions"
             :key="item.value"
@@ -24,6 +26,29 @@
           </el-option>
         </el-select>
       </template>
+      <template slot="userNameSearch">
+        <el-select
+          v-model="search.userName"
+          remote
+          filterable
+          clearable
+          :remote-method="userNameRemoteMethod"
+        >
+          <el-option
+            v-for="item in userNameOptions"
+            :key="item.value"
+            :label="item.realName"
+            :value="item.realName">
+          </el-option>
+        </el-select>
+      </template>
+      <template slot="corpNamesSearch">
+        <crop-select
+          v-model="search.corpNames"
+          corpType="KH"
+          style="width: 100%"
+        ></crop-select>
+      </template>
     </avue-crud>
   </basic-container>
 </template>
@@ -32,18 +57,18 @@
   import option from "./config/mainList.json";
   import clientOption from "./config/clientList.json";
   import { performanceAnalysis } from "@/api/workManagement/mainProject";
+  import { getUserList } from "@/api/workManagement/mainProject";
   import _ from "lodash";
 
   export default {
     data() {
       return {
-        loading : false,
         form: {},
         search:{},
-        detailData:{},
         option: option,
-        parentId:0,
+        loading:false,
         dataList: [],
+        userNameOptions:[],
         flagOptions:[{
           value: '1',
           label: '制单人'
@@ -56,36 +81,26 @@
           pagerCount: 5,
           total: 0,
         },
-        query:{},
-        configuration:{
-          multipleChoices:false,
-          multiple:false,
-          disabled:false,
-          searchShow:true,
-          collapseTags:false,
-          clearable:true,
-          placeholder:'请点击右边按钮选择',
-          dicData:[]
-        },
-        breakConfiguration:{
-          multipleChoices:false,
-          multiple:false,
-          disabled:false,
-          searchShow:true,
-          collapseTags:false,
-          clearable:true,
-          placeholder:'请点击右边按钮选择',
-          dicData:[]
-        },
       }
     },
     created() {
-
+      getUserList().then(res=>{
+        res.data.data.map((item,index)=>{
+          if(index <= 20){
+            this.userNameOptions.push(item)
+          }
+        })
+      })
     },
     mounted() {
-      // option.height = window.innerHeight - 200 ;
+
     },
     methods: {
+      userNameRemoteMethod(val){
+        getUserList({realName : val}).then(res=>{
+          this.userNameOptions = res.data.data
+        })
+      },
       //新单打开
       addReceipt(row){
         console.log(1)
@@ -110,16 +125,23 @@
         this.onLoad(this.page,params);
       },
       //点击搜索按钮触发
-      searchChange(params) {
+      searchChange(params,done) {
         this.onLoad(this.page, params);
+        done()
       },
       paramsAdjustment(params) {
         params = Object.assign({}, this.search);
         if(!params.flag){
-          params.flag = 1
+          params.flag = "1"
         }
         if(!params.year){
-          params.year = 2021
+          params.year = "2021"
+        }
+
+        if(params.flag == 1){
+          this.option = option
+        }else{
+          this.option = clientOption
         }
         return params
       },
@@ -128,6 +150,20 @@
         this.loading = true;
         params = this.paramsAdjustment(params)
         performanceAnalysis(page.currentPage, page.pageSize,params).then(res=>{
+          res.data.data.records.forEach((item)=>{
+            item.total =parseFloat(item.jan)  +
+              parseFloat(item.feb)  +
+              parseFloat(item.mar)  +
+              parseFloat(item.apr)  +
+              parseFloat(item.may)  +
+              parseFloat(item.june)  +
+              parseFloat(item.july)  +
+              parseFloat(item.aug)  +
+              parseFloat(item.sept)  +
+              parseFloat(item.oct)  +
+              parseFloat(item.nov)  +
+              parseFloat(item.dece)
+          })
           this.dataList = res.data.data.records
           this.page.total = res.data.data.total
         }).finally(()=>{

+ 7 - 5
src/views/workManagement/receipt/statisticalList.vue

@@ -130,8 +130,11 @@
         this.exportLoading = true
         let  searchParams = Object.assign({},this.search);
         let param = this.paramsAdjustment(searchParams)
-        getFlowList(1, -1,param).then(res =>{
-          const fileData = this.deepClone(res.data.data.records)
+        if(param.status === "0,1,2,3,4,5,6"){
+          param.status = ""
+        }
+        statisticalAnalysis(param).then(res=>{
+          const fileData = this.deepClone(res.data.data)
           fileData.map(item =>{
             item.cornId = item.cornName
             item.deptid = item.deptName
@@ -144,14 +147,13 @@
               item.projectType = "退款"
             }
           })
-
           this.$Export.excel({
             title: "统计列表",
             columns: option.column,
             data: fileData,
           });
-        }).finally(()=>{
-          this.exportLoading = false
+          }).finally(()=>{
+            this.exportLoading = false
         })
       },
       rowDel() {