snow hace 1 año
padre
commit
c82a5dd875

La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 0 - 0
dist/index.html


La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 0 - 0
dist/static/css/app.634e6482.css


La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 0 - 0
dist/static/js/app.03b8ed94.js


BIN
dist/static/js/app.03b8ed94.js.gz


La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 0 - 0
dist/static/js/app.765ef1bc.js


BIN
dist/static/js/app.765ef1bc.js.gz


+ 2 - 1
src/components/newReport/src/_utils.js

@@ -88,8 +88,9 @@ export function subtraction(arg1, arg2) {
   return ((arg1 * m - arg2 * m) / m).toFixed(n);
 }
 
-export function unit2TenThousand(value){
+export function unit2TenThousand(value,isTenThound = true){
   if(value === NaN || value === "NaN" || Number(value) === 0) return '0'
+  if(!isTenThound) return value;
   if(value < 1000 && value > 0 || value < 0 && value > -1000) return value
   return division(value, 10000).toFixed(2) + 'W'
 }

+ 13 - 5
src/components/newResults/company-month.vue

@@ -1,6 +1,13 @@
 <template>
   <div v-loading="loading">
-    <div class="search clear">
+    <div class="search clear" style="align-items: center;">
+      <el-switch
+        style="margin-right: 10px;"
+        v-model="isTenThound"
+        active-text="万元"
+        inactive-text="元" 
+        />
+
       <el-select size="small" style="margin-right:10px" v-model="depart_id" @change="requestData">
         <el-option v-for="depart in departItems" :key="depart.id" :value="depart.value" :label="depart.label" />
       </el-select>
@@ -15,12 +22,12 @@
         <el-table-column fixed="left" label="月度" prop="month" align="center" width="60px" />
         <el-table-column label="当月营收目标" align="center" min-width="140px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.total_tips)}}
+            {{unit2TenThousand(scope.row.total_tips,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="当月营业收入(净)" align="center" min-width="140px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.pure_sale)}}
+            {{unit2TenThousand(scope.row.pure_sale,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="当月营收完成%" align="center" min-width="140px">
@@ -35,12 +42,12 @@
         </el-table-column>
         <el-table-column label="当月毛利指标" align="center" min-width="140px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.cost_tips)}}
+            {{unit2TenThousand(scope.row.cost_tips,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="当月毛利完成" align="center" min-width="140px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.pure_profit)}}
+            {{unit2TenThousand(scope.row.pure_profit,isTenThound)}}
           </template>
         </el-table-column>
       </el-table>
@@ -56,6 +63,7 @@ export default {
   data(){
     return {
       loading: false,
+      isTenThound:true,
       daytime: "",
       tableData: [],
       depart_id: "",

+ 21 - 13
src/components/newResults/company.vue

@@ -1,6 +1,13 @@
 <template>
   <div v-loading="loading">
-    <div class="search clear">
+    <div class="search clear" style="align-items: center;;">
+      <el-switch
+        style="margin-right: 10px;"
+        v-model="isTenThound"
+        active-text="万元"
+        inactive-text="元" 
+        />
+
       <el-select size="small" style="margin-right:10px" v-model="companyName" @change="requestData">
         <el-option label="所有公司" v-for="company in companies" :key="company.value" :value="company.value" :label="company.label" />
       </el-select>
@@ -15,34 +22,34 @@
         <el-table-column fixed="left" label="业务公司" prop="companyName" align="center" width="190px" />
         <el-table-column label="当日营业收入" align="center" width="120px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.sale_total)}}
+            {{unit2TenThousand(scope.row.sale_total, isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="当月营收目标" align="center" width="120px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.total_tips)}}
+            {{unit2TenThousand(scope.row.total_tips, isTenThound)}}
           </template>
         </el-table-column>
 
         <el-table-column label="当月营业收入(净)" align="center" width="400px">
           <template slot-scope="scope">
             <div style="display:flex;flex-direction: column;">
-              <p style="text-align: center;">{{unit2TenThousand(scope.row.msale_total)}}</p>
+              <p style="text-align: center;">{{unit2TenThousand(scope.row.msale_total, isTenThound)}}</p>
               <el-table border size="mini" :data="scope.row.info">
                 <el-table-column align="center" label="直营/自营">
                   <template slot-scope="scope">
-                    {{unit2TenThousand(scope.row[0].monthinfo.msale_total)}}
+                    {{unit2TenThousand(scope.row[0].monthinfo.msale_total, isTenThound)}}
                   </template>
                 </el-table-column>
                 
                 <el-table-column align="center" label="渠道">
                   <template slot-scope="scope">
-                    {{ unit2TenThousand(scope.row[1].monthinfo.msale_total)}}
+                    {{ unit2TenThousand(scope.row[1].monthinfo.msale_total,isTenThound)}}
                   </template>
                 </el-table-column>
                 <el-table-column align="center" label="供应商端">
                   <template slot-scope="scope">
-                    {{ unit2TenThousand(scope.row[2].monthinfo.msale_total)}}
+                    {{ unit2TenThousand(scope.row[2].monthinfo.msale_total,isTenThound)}}
                   </template>
                 </el-table-column>
               </el-table>
@@ -62,12 +69,12 @@
         </el-table-column>
         <el-table-column label="当月毛利指标" align="center" width="120px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.cost_tips)}}
+            {{unit2TenThousand(scope.row.cost_tips,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="当月毛利完成" align="center" width="120px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.gross_completion)}}
+            {{unit2TenThousand(scope.row.gross_completion,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="当月实际毛利率" align="center" width="120px">
@@ -77,22 +84,22 @@
         </el-table-column>
         <el-table-column label="当月成本合计" align="center" width="120px">
           <template slot-scope="scope">
-            {{unit2TenThousand(scope.row.mcost_total)}}
+            {{unit2TenThousand(scope.row.mcost_total,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="直营/自营成本" align="center" width="120px">
           <template slot-scope="scope">
-            {{ unit2TenThousand(scope.row.info[0][0].monthinfo.mcost_total)}}
+            {{ unit2TenThousand(scope.row.info[0][0].monthinfo.mcost_total,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="渠道成本" align="center" width="120px">
           <template slot-scope="scope">
-            {{ unit2TenThousand(scope.row.info[0][1].monthinfo.mcost_total)}}
+            {{ unit2TenThousand(scope.row.info[0][1].monthinfo.mcost_total,isTenThound)}}
           </template>
         </el-table-column>
         <el-table-column label="供应商端成本" align="center" width="120px">
           <template slot-scope="scope">
-            {{ unit2TenThousand(scope.row.info[0][2].monthinfo.mcost_total)}}
+            {{ unit2TenThousand(scope.row.info[0][2].monthinfo.mcost_total,isTenThound)}}
           </template>
         </el-table-column>
       </el-table>
@@ -107,6 +114,7 @@ import { addition, unit2TenThousand, subtraction, multiplication, division } fro
 export default {
   data() {
     return {
+      isTenThound: true,
       daytime: "",
       loading: false,
       tableData: [],

+ 24 - 16
src/components/newResults/department.vue

@@ -1,6 +1,13 @@
 <template>
   <div v-loading="loading">
-    <div class="search clear">
+    <div class="search clear" style="align-items: center;">
+      <el-switch
+        style="margin-right: 10px;"
+        v-model="isTenThound"
+        active-text="万元"
+        inactive-text="元" 
+        />
+
       <el-select size="small" style="margin-right:10px" v-model="depart_id" @change="requestData">
         <el-option 
           v-for="depart in departItems" 
@@ -13,7 +20,7 @@
       <el-date-picker 
         class="fr picker" 
         v-model="daytime" 
-        :picker-options="{ disabledDate(time) { return time.getTime() > Date.now(); } }" 
+        :picker-options="{disabledData(time) { return time.getTime() > Date.now(); } }" 
         placeholder="选择日期"
         style=";width:150px" 
         value-format="yyyy-MM-dd" 
@@ -31,23 +38,23 @@
         <el-table-column fixed="left" label="公司" prop="company" align="center" width="140px" />
         <el-table-column fixed="left" label="部门" prop="depart" align="center" width="140px" />
         <el-table-column label="当日营业收入"  align="center" width="120px">
-          <template slot-scope="scope">{{ unit2TenThousand(scope.row.dayinfo.sale_total) }}</template>
+          <template slot-scope="scope">{{ unit2TenThousand(scope.row.dayinfo.sale_total,isTenThound) }}</template>
         </el-table-column>
         
         <el-table-column label="当月营收目标" align="center" width="120px">
-          <template slot-scope="scope">{{ unit2TenThousand(scope.row.total_tips) }}</template>
+          <template slot-scope="scope">{{ unit2TenThousand(scope.row.total_tips,isTenThound) }}</template>
         </el-table-column>
 
         <el-table-column label="当月营业收入(净)" align="center" width="400px">
           <template slot-scope="scope">
             <div style="display:flex;flex-direction: column;">
-              <p style="text-align: center;">{{ unit2TenThousand(scope.row.monthinfo.monthNetSales)}}</p>
+              <p style="text-align: center;">{{ unit2TenThousand(scope.row.monthinfo.monthNetSales,isTenThound)}}</p>
               <el-table border size="mini" :data="scope.row.currentMonthPure">
                 <el-table-column align="center" label="直营/自营">
-                  <template slot-scope="scope">{{ unit2TenThousand(scope.row.zy) }}</template>
+                  <template slot-scope="scope">{{ unit2TenThousand(scope.row.zy,isTenThound) }}</template>
                 </el-table-column>
                 <el-table-column align="center" label="渠道">
-                  <template slot-scope="scope">{{unit2TenThousand(scope.row.qd)}}</template>
+                  <template slot-scope="scope">{{unit2TenThousand(scope.row.qd,isTenThound)}}</template>
                 </el-table-column>
               </el-table>
             </div>
@@ -56,21 +63,21 @@
 
         <el-table-column label="成本" align="center" min-width="400px">
           <el-table-column align="center" label="直营/自营">
-            <template slot-scope="scope">{{unit2TenThousand(scope.row.zy_cost)}}</template>
+            <template slot-scope="scope">{{unit2TenThousand(scope.row.zy_cost,isTenThound)}}</template>
           </el-table-column>
 
           <el-table-column align="center" label="渠道">
-            <template slot-scope="scope">{{unit2TenThousand(scope.row.qd_cost)}}</template>
+            <template slot-scope="scope">{{unit2TenThousand(scope.row.qd_cost,isTenThound)}}</template>
           </el-table-column>
         </el-table-column>
 
         <el-table-column align="center" label="毛利" min-width="400px">
           <el-table-column align="center" label="直营/自营">
-            <template slot-scope="scope">{{unit2TenThousand(scope.row.zy_gross)}}</template>
+            <template slot-scope="scope">{{unit2TenThousand(scope.row.zy_gross,isTenThound)}}</template>
           </el-table-column>
 
           <el-table-column align="center" label="渠道">
-            <template slot-scope="scope">{{unit2TenThousand(scope.row.qd_gross)}}</template>
+            <template slot-scope="scope">{{unit2TenThousand(scope.row.qd_gross,isTenThound)}}</template>
           </el-table-column>
         </el-table-column>
       </el-table>
@@ -99,12 +106,13 @@ export default {
       daytime: "",
       depart_id: "",
       loading: false,
+      isTenThound: true,
       departItems:[
-        {value:'',label:'所有平台'},
-        {value:'52',label:'百辰荣达'},
-        {value:'53',label:'普润心堂&锦兴弘昌'},
-        {value:'56',label:'泓源广诚'},
-        {value:'57',label:'万宇恒通'}
+        { value: '', label: '所有平台' },
+        { value: '52', label: '百辰荣达' },
+        { value: '53', label: '普润心堂&锦兴弘昌' },
+        { value: '56', label: '泓源广诚' },
+        { value: '57', label: '万宇恒通' }
       ]
     }
   },

Algunos archivos no se mostraron porque demasiados archivos cambiaron en este cambio