Explorar el Código

Merge branch 'dev0.3' into stage

asd26269546 hace 1 año
padre
commit
82b5d3f88f
Se han modificado 1 ficheros con 59 adiciones y 0 borrados
  1. 59 0
      src/views/salesMange/saleContract/contract/index.vue

+ 59 - 0
src/views/salesMange/saleContract/contract/index.vue

@@ -8,6 +8,7 @@
         :loading="loading"
         :selectConfig="selectConfig"
         highlight-current-row
+        :statConfig='statConfig'
         :action-list="[
           {
             text: '创建合同',
@@ -582,11 +583,69 @@ const getList = async (req) => {
     }, 200);
   });
 };
+const statConfig = computed(() => {
+	return [
+		{
+			label: '合计',
+			data:[],
+		},
+		
+	]
+})
 getDict();
 if (route.query.code) {
   sourceList.value.pagination.keyword = route.query.code;
 }
 getList();
+const getTotal = () => {
+  proxy.get("/contract/getHeadCustomerStatistics").then((res) => {
+    statConfig.value[0].data = [];
+    statConfig.value[0].data.push({
+      label:'合计',
+      data:[
+        {
+          label:'数量',
+          num:res.data.sumQuantity,
+          color:'rgb(171 0 255)',
+        },
+        {
+          label:'金额',
+          num:res.data.sumArrivalAmount,
+          color:'rgb(171 0 255)',
+        },
+        {
+          label:'到账金额',
+          num:res.data.sumAmount,
+          color:'rgb(171 0 255)',
+        },
+      ]
+    })
+    for (let i = 0; i < res.data.list.length; i++) {
+      statConfig.value[0].data.push({
+        label:res.data.list[i].sellCorporationName,
+        data:[
+          {
+            label:'数量',
+            num:res.data.list[i].sumQuantity,
+            color:'blue',
+          },
+          {
+            label:'金额',
+            num:res.data.list[i].sumClaimMoney,
+            color:'blue',
+          },
+          {
+            label:'到账金额',
+            num:res.data.list[i].sumClaimMoney,
+            color:'blue',
+          },
+        ]
+      })
+    }
+    console.log(res);
+  });
+};
+getTotal();
 const newContract = () => {
   proxy.$router.replace({
     path: "/platform_manage/process/processApproval",