浏览代码

销售漏斗项目预计成交统计调整

qymljy 6 月之前
父节点
当前提交
00a8f0d276
共有 2 个文件被更改,包括 130 次插入42 次删除
  1. 4 0
      src/style/style.css
  2. 126 42
      src/views/mediaStatistics/modules/salesfunnel.vue

+ 4 - 0
src/style/style.css

@@ -311,3 +311,7 @@ ul{
   white-space: nowrap !important;
   width: auto !important;
 }
+.justify-between-flex-style{
+  display: flex;
+  justify-content: space-between;
+}

+ 126 - 42
src/views/mediaStatistics/modules/salesfunnel.vue

@@ -94,7 +94,7 @@
         <div class="statistics-box">
           <div style="margin: 10px 20px 10px 20px">
             <div class="statistics-box-title">
-              {{$t(`前12个月数据`)}}
+              {{$t(`前12个月成交项目数据`)}}
               <el-tooltip effect="dark" placement="top-start">
                 <div slot="content">
                   {{
@@ -111,52 +111,55 @@
                 />
               </el-tooltip>
             </div>
-            <div class="title-margin-15">
-              <div class="title-font-style1">
-                {{$t(`准确率`)}}
-              </div>
-              <div class="title-margin-5 title-font-style2">
-                {{Math.round((previousYearData.dealaccuracyrate * 100)*100)/100}}%
-              </div>
-            </div>
-            <div class="title-margin-15">
-              <div class="title-font-style1">
-                {{$t(`偏差金额`)}}
-              </div>
-              <div class="title-margin-5 title-font-style2">
-                {{tool.formatAmount(tool.unitConversion(previousYearData.totaldeviationamount,10000),2)}}
-                <span class="title-font-style4">{{$t(`万元`)}}</span>
-              </div>
-            </div>
-            <div class="title-margin-15">
-              <div class="title-font-style1">
-                {{$t(`项目成交金额`)}}
+            <div class="justify-between-flex-style">
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`准确率`)}}
+                </div>
+                <div class="title-margin-5 title-font-style2">
+                  {{Math.round((previousYearData.dealaccuracyrate * 100)*100)/100}}%
+                </div>
               </div>
-              <div class="title-margin-5 title-font-style3">
-                {{tool.formatAmount(tool.unitConversion(previousYearData.totaldealamount,10000),2)}}
-                <span>{{$t(`万元`)}}</span>
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`偏差金额`)}}
+                </div>
+                <div class="title-margin-5 title-font-style2">
+                  {{tool.formatAmount(tool.unitConversion(previousYearData.totaldeviationamount,10000),2)}}
+                  <span class="title-font-style4">{{$t(`万元`)}}</span>
+                </div>
               </div>
-            </div>
-            <div class="title-margin-15">
-              <div class="title-font-style1">
-                {{$t(`预计签约金额`)}}
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`项目成交金额`)}}
+                </div>
+                <div class="title-margin-5 title-font-style3">
+                  {{tool.formatAmount(tool.unitConversion(previousYearData.totaldealamount,10000),2)}}
+                  <span>{{$t(`万元`)}}</span>
+                </div>
               </div>
-              <div class="title-margin-5 title-font-style3">
-                {{tool.formatAmount(tool.unitConversion(previousYearData.totalsignamount_due,10000),2)}}
-                <span>{{$t(`万元`)}}</span>
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`预计签约金额`)}}
+                </div>
+                <div class="title-margin-5 title-font-style3">
+                  {{tool.formatAmount(tool.unitConversion(previousYearData.totalsignamount_due,10000),2)}}
+                  <span>{{$t(`万元`)}}</span>
+                </div>
               </div>
             </div>
           </div>
         </div>
-        <div class="screen-box">
-          <div style="margin: 20px">
-            <div class="title-font-style5">
-              {{$t(`未来12月项目预计签约金额统计(单位:万)`)}}
+
+        <div class="statistics-box">
+          <div style="margin: 10px 20px 10px 20px">
+            <div class="statistics-box-title">
+              {{$t(`前12个月项目总数据`)}}
               <el-tooltip effect="dark" placement="top-start">
                 <div slot="content">
                   {{
                     $t(
-                        "统计当前月份往后(包含当前月份)的12个月的每个月份的(跟进中状态)的项目预计签约金额"
+                        "统计当前月份之前(不包含当前月份)的12个月的(已成交、结案状态)的项目预计成交准确率、偏差金额"
                     )
                   }}
                 </div>
@@ -168,12 +171,71 @@
                 />
               </el-tooltip>
             </div>
-            <div style="margin-top: 20px">
-              <chartTemplate ref="chartColumn" chartRef="signChart" :param="paramChart" height-chart="232px" width-chart="100%"></chartTemplate>
+            <div class="justify-between-flex-style">
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`准确率`)}}
+                </div>
+                <div class="title-margin-5 title-font-style2">
+                  {{Math.round((previousYearAllData.dealaccuracyrate * 100)*100)/100}}%
+                </div>
+              </div>
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`偏差金额`)}}
+                </div>
+                <div class="title-margin-5 title-font-style2">
+                  {{tool.formatAmount(tool.unitConversion(previousYearAllData.totaldeviationamount,10000),2)}}
+                  <span class="title-font-style4">{{$t(`万元`)}}</span>
+                </div>
+              </div>
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`项目成交金额`)}}
+                </div>
+                <div class="title-margin-5 title-font-style3">
+                  {{tool.formatAmount(tool.unitConversion(previousYearAllData.totaldealamount,10000),2)}}
+                  <span>{{$t(`万元`)}}</span>
+                </div>
+              </div>
+              <div class="title-margin-15">
+                <div class="title-font-style1">
+                  {{$t(`预计签约金额`)}}
+                </div>
+                <div class="title-margin-5 title-font-style3">
+                  {{tool.formatAmount(tool.unitConversion(previousYearAllData.totalsignamount_due,10000),2)}}
+                  <span>{{$t(`万元`)}}</span>
+                </div>
+              </div>
             </div>
           </div>
         </div>
       </div>
+      <div class="screen-box">
+        <div style="margin: 20px">
+          <div class="title-font-style5">
+            {{$t(`未来12月项目预计签约金额统计(单位:万)`)}}
+            <el-tooltip effect="dark" placement="top-start">
+              <div slot="content">
+                {{
+                  $t(
+                      "统计当前月份往后(包含当前月份)的12个月的每个月份的(跟进中状态)的项目预计签约金额"
+                  )
+                }}
+              </div>
+              <!--        <i class="el-icon-question" style="color: #afb0be;float: right"></i>-->
+              <img
+                  width="14px"
+                  height="14px"
+                  src="../../../assets/icons/prompt_icon.svg"
+              />
+            </el-tooltip>
+          </div>
+          <div style="margin-top: 10px">
+            <chartTemplate ref="chartColumn" chartRef="signChart" :param="paramChart" height-chart="232px" width-chart="100%"></chartTemplate>
+          </div>
+        </div>
+      </div>
     </div>
     <div style="margin-top: 40px">
       <p class="title">{{projectTile}}</p>
@@ -330,6 +392,7 @@ export default {
       tradefields:[],
       unfinish:'1',
       previousYearData:{},
+      previousYearAllData:{},
       paramChart:{
         "id": 20241028162004,
         "content": {
@@ -912,6 +975,7 @@ export default {
         this.paramChart.content.where.isleave = this.dataParam.content.where.isleave
         this.$refs.chartColumn.chartData(false)
         this.previousYear()
+        this.previousAllYear()
       }
       const res = await this.$api.requested(this.projectParam)
       this.projectList = res.data
@@ -932,7 +996,7 @@ export default {
       const res = await this.$store.dispatch('optiontypeselect','tradefield')
       this.tradefields = res.data
     },
-    /*前12个月数据*/
+    /*前12个月项目成交数据*/
     async previousYear(){
       let param = {
         "id": 20241028162104,
@@ -951,6 +1015,26 @@ export default {
       param.content.where.isleave = this.dataParam.content.where.isleave
       const res = await this.$api.requested(param)
       this.previousYearData = res.data
+    },
+    /*前12个月项目总数据*/
+    async previousAllYear(){
+      let param = {
+        "id": 2024112813172602,
+        "content": {
+          "type": "0",
+          "dataid": "0",
+          "where": {
+            "tradefield": "",
+            "isleave":""
+          }
+        }
+      }
+      param.content.type = this.dataParam.content.type
+      param.content.dataid = this.dataParam.content.dataid
+      param.content.where.tradefield = this.dataParam.content.where.tradefield
+      param.content.where.isleave = this.dataParam.content.where.isleave
+      const res = await this.$api.requested(param)
+      this.previousYearAllData = res.data
     }
   },
   mounted () {
@@ -983,8 +1067,7 @@ export default {
  /* height:calc(100vh)*/
 }
 .statistics-box{
-  width: 28%;
-  height: 302px;
+  width: 49%;
   background: #FFFFFF;
   box-shadow: 0px 1px 6px 1px rgba(0,0,0,0.16);
   border-radius: 10px 10px 10px 10px;
@@ -1001,7 +1084,7 @@ export default {
   text-transform: none;
 }
 .screen-box{
-  width: 70%;
+  width: 100%;
   height: 302px;
   background: #FFFFFF;
   box-shadow: 0px 1px 6px 1px rgba(0,0,0,0.16);
@@ -1058,5 +1141,6 @@ export default {
   text-align: left;
   font-style: normal;
   text-transform: none;
+  padding-top: 20px;
 }
 </style>