Parcourir la source

订单产品管理,待备料页面增加页面统计

lxf il y a 1 an
Parent
commit
cea0c537b0

+ 9 - 0
src/api/shengde/group/order/orderProductManagement.js

@@ -8,3 +8,12 @@ export function getList(data) {
     data: data,
   })
 }
+
+// 订单SKU管理-统计
+export function contractProductStatistics(data) {
+  return request({
+    url: '/saas-subsidiary/saas/subsidiary/contract/contractProductStatistics',
+    method: 'post',
+    data: data,
+  })
+}

+ 9 - 0
src/api/shengde/productionSystem/productionOperation/batching/index.js

@@ -41,3 +41,12 @@ export function burdeningLabel(arr) {
     data: arr,
   })
 }
+
+// 生产备料-列表统计
+export function bladeStatistics(data) {
+  return request({
+    url: '/saas-production/saas/production/burdening/bladeStatistics',
+    method: 'post',
+    data: data,
+  })
+}

+ 23 - 1
src/views/shengde/group/order/orderProductManagement/index.vue

@@ -66,7 +66,21 @@
         <el-button size="mini" @click="resetQuery">重置</el-button>
       </el-form-item>
     </el-form>
-    <!-- 表格数据 -->
+
+    <el-row :gutter="10" style="margin-bottom: 10px">
+      <el-col :span="24">
+        <span>
+          订单数量:
+          <span style="margin-left: 4px" v-if="statisticsData && statisticsData.contractCount">{{ Number(statisticsData.contractCount) }}</span>
+          <span style="margin-left: 4px" v-else>0</span>
+        </span>
+        <span style="margin-left: 16px">
+          主材数量:
+          <span style="margin-left: 4px" v-if="statisticsData && statisticsData.quantity">{{ Number(statisticsData.quantity) }}</span>
+          <span style="margin-left: 4px" v-else>0</span>
+        </span>
+      </el-col>
+    </el-row>
 
     <el-table
       :data="tableList"
@@ -159,6 +173,7 @@
 <script>
 import * as API from '@/api/shengde/group/order/orderProductManagement.js'
 import { mapGetters } from 'vuex'
+
 export default {
   data() {
     return {
@@ -198,6 +213,10 @@ export default {
       },
       tableList: [],
       total: null,
+      statisticsData: {
+        quantity: 0,
+        contractCount: 0,
+      },
     }
   },
   created() {
@@ -222,6 +241,9 @@ export default {
           this.loading = false
         }
       )
+      API.contractProductStatistics(this.queryParams).then((res) => {
+        this.statisticsData = res.data.data
+      })
     },
     handleQuery() {
       this.queryParams.pageNum = 1

+ 22 - 0
src/views/shengde/productionSystem/productionOperation/batching/stay.vue

@@ -52,6 +52,21 @@
       <el-button size="mini" @click="handleComplete">4. 完成备料</el-button>
     </el-row>
 
+    <el-row :gutter="10" style="margin-bottom: 10px">
+      <el-col :span="24">
+        <span>
+          订单数量:
+          <span style="margin-left: 4px" v-if="statisticsData && statisticsData.contractCount">{{ Number(statisticsData.contractCount) }}</span>
+          <span style="margin-left: 4px" v-else>0</span>
+        </span>
+        <span style="margin-left: 16px">
+          主材数量:
+          <span style="margin-left: 4px" v-if="statisticsData && statisticsData.quantity">{{ Number(statisticsData.quantity) }}</span>
+          <span style="margin-left: 4px" v-else>0</span>
+        </span>
+      </el-col>
+    </el-row>
+
     <el-table
       :data="tableList"
       size="small"
@@ -236,6 +251,10 @@ export default {
       },
       openSetLabel: false,
       openQuickDelivery: false,
+      statisticsData: {
+        quantity: 0,
+        contractCount: 0,
+      },
     }
   },
   created() {
@@ -261,6 +280,9 @@ export default {
           this.loading = false
         }
       )
+      API.bladeStatistics(this.queryParams).then((res) => {
+        this.statisticsData = res.data.data
+      })
     },
     handleQuery() {
       this.queryParams.pageNum = 1

+ 23 - 0
src/views/shengde/subsidiary/order/productManagement/index.vue

@@ -60,6 +60,22 @@
         <el-button size="mini" @click="resetQuery">重置</el-button>
       </el-form-item>
     </el-form>
+
+    <el-row :gutter="10" style="margin-bottom: 10px">
+      <el-col :span="24">
+        <span>
+          订单数量:
+          <span style="margin-left: 4px" v-if="statisticsData && statisticsData.contractCount">{{ Number(statisticsData.contractCount) }}</span>
+          <span style="margin-left: 4px" v-else>0</span>
+        </span>
+        <span style="margin-left: 16px">
+          主材数量:
+          <span style="margin-left: 4px" v-if="statisticsData && statisticsData.quantity">{{ Number(statisticsData.quantity) }}</span>
+          <span style="margin-left: 4px" v-else>0</span>
+        </span>
+      </el-col>
+    </el-row>
+
     <el-table
       :data="tableList"
       size="small"
@@ -202,6 +218,10 @@ export default {
       },
       tableList: [],
       total: null,
+      statisticsData: {
+        quantity: 0,
+        contractCount: 0,
+      },
     }
   },
   created() {},
@@ -228,6 +248,9 @@ export default {
           this.loading = false
         }
       )
+      API.contractProductStatistics(this.queryParams).then((res) => {
+        this.statisticsData = res.data.data
+      })
     },
     /** 搜索按钮操作 */
     handleQuery() {