瀏覽代碼

Merge branch 'develop_yh31' of http://git.chelingzhu.com/jianguan-web/jg-ocs-html into develop_yh31

chenrui 1 年之前
父節點
當前提交
2b134daf26

+ 7 - 5
src/bigScreenComponents/scale-screen/scale-screen.vue

@@ -74,6 +74,7 @@ export default {
       originalHeight: 0,
       onResize: null,
       observer: null,
+      isInnerPage: false
     };
   },
   watch: {
@@ -94,10 +95,11 @@ export default {
   },
   methods: {
     initSize() {
+      this.isInnerPage = this.$route.path.indexOf("bigStatistics")>=0
       return new Promise((resolve, reject) => {
         // console.log("初始化样式");
         //给父元素设置 overflow:hidden
-        this.screenWrapper.parentNode.style.overflow = "hidden";
+        this.screenWrapper.parentNode.style.overflow = !this.isInnerPage ? "hidden" : 'auto';
         this.screenWrapper.parentNode.scrollLeft = 0;
         this.screenWrapper.parentNode.scrollTop = 0;
 
@@ -135,8 +137,8 @@ export default {
       const screenWrapper = this.screenWrapper;
       const domWidth = screenWrapper.clientWidth;
       const domHeight = screenWrapper.clientHeight;
-      const currentWidth = document.body.clientWidth;
-      const currentHeight = document.body.clientHeight;
+      const currentWidth = !this.isInnerPage ? document.body.clientWidth : screenWrapper.parentNode.clientWidth;
+      const currentHeight = !this.isInnerPage ? document.body.clientHeight : screenWrapper.parentNode.clientHeight;
       screenWrapper.style.transform = `scale(${scale},${scale}) `;
       let mx = Math.max((currentWidth - domWidth * scale) / 2, 0);
       let my = Math.max((currentHeight - domHeight * scale) / 2, 0);
@@ -160,8 +162,8 @@ export default {
     updateScale() {
       const screenWrapper = this.screenWrapper;
       // 获取真实视口尺寸
-      const currentWidth = document.body.clientWidth;
-      const currentHeight = document.body.clientHeight;
+      const currentWidth = !this.isInnerPage ? document.body.clientWidth : screenWrapper.parentNode.clientWidth;
+      const currentHeight = !this.isInnerPage ? document.body.clientHeight : screenWrapper.parentNode.clientHeight;
       // 获取大屏最终的宽高onResize
       const realWidth = this.currentWidth || this.originalWidth;
       const realHeight = this.currentHeight || this.originalHeight;

+ 57 - 0
src/config/router.config.js

@@ -3390,6 +3390,63 @@ export const asyncRouterMap = [
           }
         ]
       },
+      // 大屏数据
+      {
+        path: '/bigStatistics',
+        redirect: '/bigStatistics/realTimeSalesReport',
+        component: PageView,
+        meta: {
+          title: '数据统计',
+          icon: 'desktop',
+          permission: 'M_bigScreenStatistics'
+        },
+        children: [
+          {
+            path: '/bigStatistics/realTimeSalesReport',
+            redirect: '/bigStatistics/realTimeSalesReport/index',
+            name: 'bigRealTimeSalesReport',
+            component: BigScreen,
+            meta: {
+              title: '实时销售看板',
+              icon: 'deployment-unit',
+              permission: 'M_realTimeSalesReportIndex'
+            },
+            hideChildrenInMenu: true,
+            children: [
+              {
+                path: 'index',
+                name: 'realTimeSalesReportIndex',
+                component: () => import(/* webpackChunkName: "bigScreen" */ '@/views/bigScreen/realTimeSalesReport/index'),
+                meta: {
+                  title: '实时销售看板'
+                }
+              },
+            ]
+          },
+          {
+            path: '/bigStatistics/fPanalysisReport',
+            redirect: '/bigStatistics/fPanalysisReport/index',
+            name: 'bigfPanalysisReport',
+            component: BigScreen,
+            meta: {
+              title: '加盟商/产品分析',
+              icon: 'interaction',
+              permission: 'M_fPanalysisReportIndex'
+            },
+            hideChildrenInMenu: true,
+            children: [
+              {
+                path: 'index',
+                name: 'fPanalysisReportIndex',
+                component: () => import(/* webpackChunkName: "bigScreen" */ '@/views/bigScreen/fPanalysisReport/index'),
+                meta: {
+                  title: '加盟商/产品分析'
+                }
+              }
+            ]
+          }
+        ]
+      },
       // 基础设置
       {
         path: '/basicData',

+ 12 - 5
src/layouts/BigScreen.vue

@@ -57,7 +57,6 @@ export default {
   mounted () {
     this.timeFn()
     this.cancelLoading()
-    console.log(this.$route.meta.title)
   },
   beforeDestroy () {
     clearInterval(this.timing)
@@ -204,10 +203,18 @@ export default {
               margin-right: 20px;
               background: linear-gradient(to right, rgba(39, 180, 255, 0.5), rgba(76, 245, 255, 0.1));
   			cursor: pointer;
-  			&:hover,&:active{
-  				color: #f1f1f1;
-  				background: linear-gradient(to right, rgba(39, 180, 255, 0.7), rgba(76, 245, 255, 0.3));
-  			}
+            &:hover,&:active{
+              color: #f1f1f1;
+              background: linear-gradient(to right, rgba(39, 180, 255, 0.7), rgba(76, 245, 255, 0.3));
+            }
+            select{
+              border:0;
+              background:none;
+              font-size: 16px;
+              option{
+                color: #333
+              }
+            }
           }
   		.focus{
   			transform: scale(1.1);

+ 31 - 6
src/views/bigScreen/fPanalysisReport/index.vue

@@ -1,8 +1,19 @@
 <template>
   <div class="contents">
     <div class="contetn_left">
-      <div class="pagetab">
-        <div class="item" ref="myDiv" v-focusable @click="toPage">﹤实时销售看板</div>
+      <div class="pagetab" v-if="!isInnerPage">
+        <div class="item" ref="myDiv" v-focusable @click="toPage">
+          ﹤实时销售看板
+        </div>
+      </div>
+      <div class="pagetab" v-else>
+        <div class="item" style="width: 120px;margin-right:10px" v-focusable>
+          <select @click="changeYear">
+            <option v-for="item in yearArr" :key="item" :value="item" :selected="curYear==item" >
+              {{item}} 年
+            </option>
+          </select>
+        </div>
       </div>
       <ItemWrap class="contetn_left-top contetn_lr-aitem" title="加盟商分布">
         <LeftBottom />
@@ -75,7 +86,9 @@ export default {
       curTab: 1,
       jmsTotal: 0,
       cpTotal: 0,
-      curYear: ''
+      curYear: '',
+      isInnerPage: false,
+      yearArr: []
     }
   },
   filters: {
@@ -89,11 +102,23 @@ export default {
 	  })
     const year = location.href.split('?')[1]
     this.curYear = year ? year.split('=')[1] : new Date().getFullYear()
+    this.isInnerPage = this.$route.path.indexOf("bigStatistics")>=0
+  },
+  mounted () {
+    const toYeay = new Date().getFullYear()
+    this.yearArr = [toYeay-3,toYeay-2,toYeay-1,toYeay]
   },
-  mounted () {},
   methods: {
-    toPage () {
-      this.$router.push({ name: 'realTimeSalesReport', query: { year: this.curYear } })
+    changeYear(e){
+      this.toPage(e.target.value)
+    },
+    toPage (curYear) {
+      if(!this.isInnerPage){
+        this.$router.push({ name: 'realTimeSalesReport', query: { year: this.curYear } })
+      }else{
+        this.curYear = curYear
+        this.$router.replace({ name: 'bigfPanalysisReport', query: { year: curYear } })
+      }
     },
     setJmsTotal (val) {
       this.jmsTotal = val

+ 3 - 0
src/views/bigScreen/fPanalysisReport/right-bottom.vue

@@ -75,6 +75,9 @@ export default {
     })
   },
   watch: {
+    curYear (a,b){
+      this.getData()
+    },
   	curTab (newValue, oldValue) {
       this.queryType = newValue == 1 ? 'qty' : 'amount'
   		this.getData()

+ 5 - 1
src/views/bigScreen/fPanalysisReport/right-top.vue

@@ -65,7 +65,11 @@ export default {
   created () {
     this.getData()
   },
-  mounted () { },
+  watch:{
+    curYear (a,b){
+      this.getData()
+    }
+  },
   beforeDestroy () {
     this.clearData()
   },

+ 5 - 0
src/views/bigScreen/realTimeSalesReport/center-bottom.vue

@@ -30,6 +30,11 @@ export default {
   mounted () {
     this.getData()
   },
+  watch:{
+    curYear (a,b){
+      this.getData()
+    }
+  },
   beforeDestroy () {
     this.clearData()
   },

+ 5 - 1
src/views/bigScreen/realTimeSalesReport/center-map.vue

@@ -37,7 +37,11 @@ export default {
       loading: false
     }
   },
-  created () {},
+  watch:{
+    curYear (a,b){
+      this.getData('china')
+    }
+  },
   mounted () {
     this.getData('china')
   },

+ 3 - 2
src/views/bigScreen/realTimeSalesReport/center-top.vue

@@ -34,9 +34,10 @@ export default {
       config1: null
     }
   },
-  mounted () {
-  },
   watch: {
+    curYear (a,b){
+      this.getData()
+    },
     totalNums (newValue, oldValue) {
       console.log(newValue)
       this.config = {

+ 28 - 5
src/views/bigScreen/realTimeSalesReport/index.vue

@@ -1,11 +1,20 @@
 <template>
   <div class="contents">
     <div class="contetn_left">
-      <div class="pagetab">
+      <div class="pagetab" v-if="!isInnerPage">
         <div class="item" ref="myDiv" v-focusable @click="toPage">
           ﹤加盟商/产品分析
         </div>
       </div>
+      <div class="pagetab" v-else>
+        <div class="item" style="width: 120px;margin-right:10px" v-focusable>
+          <select @click="changeYear">
+            <option v-for="item in yearArr" :key="item" :value="item" :selected="curYear==item" >
+              {{item}} 年
+            </option>
+          </select>
+        </div>
+      </div>
       <ItemWrap class="contetn_left-top contetn_lr-item" :title="'区域销售金额占比'">
         <LeftTop :curYear="curYear" />
       </ItemWrap>
@@ -68,7 +77,9 @@ export default {
     return {
       yearTotalNums: 0,
       yearTotalAmount: 0,
-      curYear: ''
+      curYear: '',
+      isInnerPage: false,
+      yearArr: []
     }
   },
   filters: {
@@ -82,11 +93,23 @@ export default {
 	  })
     const year = location.href.split('?')[1]
     this.curYear = year ? year.split('=')[1] : new Date().getFullYear()
+    this.isInnerPage = this.$route.path.indexOf("bigStatistics")>=0
+  },
+  mounted () { 
+    const toYeay = new Date().getFullYear()
+    this.yearArr = [toYeay-3,toYeay-2,toYeay-1,toYeay]
   },
-  mounted () { },
   methods: {
-    toPage () {
-      this.$router.push({ name: 'fPanalysisReport', query: { year: this.curYear } })
+    changeYear(e){
+      this.toPage(e.target.value)
+    },
+    toPage (curYear) {
+      if(!this.isInnerPage){
+        this.$router.push({ name: 'fPanalysisReport', query: { year: this.curYear } })
+      }else{
+        this.curYear = curYear
+        this.$router.replace({ name: 'bigRealTimeSalesReport', query: { year: curYear } })
+      }
     },
     setYearData (data) {
       console.log(data)

+ 4 - 1
src/views/bigScreen/realTimeSalesReport/left-bottom.vue

@@ -30,7 +30,10 @@ export default {
   created () {
     this.getData()
   },
-  computed: {
+  watch:{
+    curYear (a,b){
+      this.getData()
+    }
   },
   mounted () { },
   beforeDestroy () {

+ 4 - 1
src/views/bigScreen/realTimeSalesReport/left-top.vue

@@ -29,7 +29,10 @@ export default {
   created () {
     this.getData()
   },
-  mounted () {
+  watch:{
+    curYear (a,b){
+      this.getData()
+    }
   },
   beforeDestroy () {
     this.clearData()

+ 5 - 0
src/views/bigScreen/realTimeSalesReport/right-top.vue

@@ -36,6 +36,11 @@ export default {
   mounted () {
     this.getData()
   },
+  watch:{
+    curYear (a,b){
+      this.getData()
+    }
+  },
   beforeDestroy () {
     this.clearData()
   },

+ 8 - 1
src/views/expenseManagement/expenseReimbursement/epenseCdfModal.vue

@@ -48,6 +48,12 @@
                 enableFlag="1"
                 v-model="record.splitObjSn"
                 placeholder="请选择(输入名称搜索)"></supplier>
+              <!-- 其它往来 -->
+              <otherTransactions 
+              style="width: 100%;"
+              v-show="record.splitObjType=='OTHER_ORG'" 
+              v-model="record.splitObjSn" 
+              placeholder="请选择(输入名称搜索)"></otherTransactions>
               <span v-if="!record.splitObjType">--</span>
             </template>
             <!-- 费用承担金额 -->
@@ -131,8 +137,9 @@ import department from './department.js'
 import employee from './employee.js'
 import custList from '@/views/common/custList.vue'
 import supplier from '@/views/common/supplier.js'
+import otherTransactions from '@/views/common/otherTransactions.js'
 export default {
-  components: { VSelect, department, employee, custList, supplier },
+  components: { VSelect, department, employee, custList, supplier, otherTransactions },
   name: 'EpenseCdfModal',
   props: {
     list: { //  弹框显示状态

+ 4 - 1
src/views/expenseManagement/expenseReimbursement/epenseDetailModal.vue

@@ -38,6 +38,8 @@
                   <custList v-show="form.accountType=='CUSTOMER'" cooperateFlag="1" ref="custList" @change="accountNameSnChange" placeholder="请选择记账名称(输入名称搜索)"></custList>
                   <!-- 供应商 -->
                   <supplier v-show="form.accountType=='OUT_ACCOUNT'" enableFlag="1" @change="accountNameSnChange" v-model="form.accountNameSn" placeholder="请选择记账名称(输入名称搜索)"></supplier>
+                  <!-- 其它往来 -->
+                  <otherTransactions v-show="form.accountType=='OTHER_ACCOUNT'" @change="accountNameSnChange" v-model="form.accountNameSn" placeholder="请选择记账名称(输入名称搜索)"></otherTransactions>
                   <span v-if="!form.accountType">
                     <a-select style="width: 100%" placeholder="请选择记账名称">
                       <a-select-option value="" :disabled="true">
@@ -118,11 +120,12 @@ import subarea from '@/views/common/subarea.js'
 import Area from '@/views/common/area.js'
 import custList from '@/views/common/custList.vue'
 import supplier from '@/views/common/supplier.js'
+import otherTransactions from '@/views/common/otherTransactions.js'
 import department from './department.js'
 import { expenseAcctDetailSave, expenseAcctDetailFindBySn } from '@/api/expenseManagement.js'
 export default {
   name: 'EpenseDetailModal',
-  components: { VSelect, subarea, Area, epenseCdfModal, custList, supplier, department },
+  components: { VSelect, subarea, Area, epenseCdfModal, custList, supplier, department, otherTransactions },
   props: {
     openModal: { //  弹框显示状态
       type: Boolean,

+ 7 - 16
src/views/productManagement/productSourcePath/list.vue

@@ -67,7 +67,11 @@
               </a-col>
               <a-col :md="6" :sm="24">
                 <a-form-model-item label="客户名称">
-                  <dealerSearchList ref="dealerSubareaScopeList" id="productSourceList-buyerName" @change="custChange" />
+                  <a-input
+                    id="productSourceList-buyerName"
+                    v-model.trim="queryParam.buyerName"
+                    allowClear
+                    placeholder="请输入客户名称" />
                 </a-form-model-item>
               </a-col>
               <a-col :md="6" :sm="24">
@@ -181,11 +185,10 @@ import warrantyInfoModal from './warrantyInfoModal.vue'
 import importGuideModal from './importGuideModal.vue'
 import { hdExportExcel } from '@/libs/exportExcel'
 import { traceCodeInsertBatch, traceCodeQueryCount, traceCodeList, excelOnlineList } from '@/api/reportData'
-import dealerSearchList from '@/views/common/dealerSearchList.vue'
 export default {
   name: 'ProductSourceList',
   mixins: [commonMixin],
-  components: { STable, VSelect, rangeDate, warrantyInfoModal, importGuideModal, dealerSearchList },
+  components: { STable, VSelect, rangeDate, warrantyInfoModal, importGuideModal },
   data () {
     return {
       loading: false,
@@ -205,8 +208,7 @@ export default {
         traceCode: undefined,
         buyerName: undefined,
         bizStatus: undefined,
-        warrantyState: undefined,
-        targetSn: undefined
+        warrantyState: undefined
       },
       openInfoModal: false, // 质保信息弹窗
       columns: [{ title: '序号', dataIndex: 'no', width: '5%', align: 'center' },
@@ -261,15 +263,6 @@ export default {
     }
   },
   methods: {
-    custChange (val) {
-      if (val.row) {
-        this.queryParam.targetSn = val.row.dealerSn
-        this.queryParam.buyerName = val.name
-      } else {
-        this.queryParam.targetSn = undefined
-        this.queryParam.buyerName = val.key
-      }
-    },
     // 单据类型操作
     handleBizStatus (val) {
       this.queryParam.bizStatus = val
@@ -330,10 +323,8 @@ export default {
       this.queryParam.bizCode = undefined
       this.queryParam.traceCode = undefined
       this.queryParam.buyerName = undefined
-      this.queryParam.targetSn = undefined
       this.queryParam.bizStatus = undefined
       this.queryParam.warrantyState = undefined
-      this.$refs.dealerSubareaScopeList.resetForm()
       this.$refs.table.refresh(true)
     },
     //  导出

+ 2 - 2
vue.config.js

@@ -108,9 +108,9 @@ const vueConfig = {
     // If you want to turn on the proxy, please remosve the mockjs /src/main.jsL11
     proxy: {
       '/api': {
-        target: 'http://192.168.2.113:8660/ocs-admin',
+        // target: 'http://192.168.2.113:8660/ocs-admin',
         // target: 'https://t.ocs.360arrow.com/ocs-admin', //  练习
-        // target: 'https://p.ocs.360arrow.com/ocs-admin', //  预发布
+        target: 'https://p.ocs.360arrow.com/ocs-admin', //  预发布
         ws: false,
         changeOrigin: true,
         pathRewrite: {