排产BOM挂载
This commit is contained in:
@@ -6,7 +6,7 @@
|
|||||||
{{ material.rawMaterialName ? material.rawMaterialName : '--' }}
|
{{ material.rawMaterialName ? material.rawMaterialName : '--' }}
|
||||||
</slot>
|
</slot>
|
||||||
</span>
|
</span>
|
||||||
<el-dialog :visible="showDetail" @close="showDetail = false" :title="material.rawMaterialName" width="400px"
|
<el-dialog :visible="showDetail" @close="showDetail = false" :title="material.rawMaterialName" width="600px"
|
||||||
append-to-body>
|
append-to-body>
|
||||||
<el-descriptions :column="1" border>
|
<el-descriptions :column="1" border>
|
||||||
<el-descriptions-item label="ID">{{ material.rawMaterialId }}</el-descriptions-item>
|
<el-descriptions-item label="ID">{{ material.rawMaterialId }}</el-descriptions-item>
|
||||||
|
|||||||
@@ -164,6 +164,9 @@ export default {
|
|||||||
yAxis: {
|
yAxis: {
|
||||||
type: 'value'
|
type: 'value'
|
||||||
},
|
},
|
||||||
|
title: {
|
||||||
|
text: ''
|
||||||
|
},
|
||||||
series: [
|
series: [
|
||||||
{
|
{
|
||||||
name: '销售数量',
|
name: '销售数量',
|
||||||
@@ -207,6 +210,9 @@ export default {
|
|||||||
trigger: 'item',
|
trigger: 'item',
|
||||||
formatter: '{a} <br/>{b}: {c} ({d}%)'
|
formatter: '{a} <br/>{b}: {c} ({d}%)'
|
||||||
},
|
},
|
||||||
|
title: {
|
||||||
|
text: ''
|
||||||
|
},
|
||||||
series: [
|
series: [
|
||||||
{
|
{
|
||||||
name: '销售业绩',
|
name: '销售业绩',
|
||||||
|
|||||||
@@ -44,36 +44,6 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<!-- 原有图表区域(保留兼容性) -->
|
|
||||||
<el-row :gutter="20" class="section-row">
|
|
||||||
<el-col :span="24">
|
|
||||||
<div class="section-title">
|
|
||||||
<h2>原有图表区域</h2>
|
|
||||||
<p>兼容原有的图表展示</p>
|
|
||||||
</div>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<!-- 顶部:3 张summary卡片 -->
|
|
||||||
<el-row :gutter="20" class="top-row">
|
|
||||||
<el-col :span="24">
|
|
||||||
<OrderSummary :data-info="orderSummaryData" />
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<!-- 第一行图表 -->
|
|
||||||
<el-row :gutter="20" class="chart-row">
|
|
||||||
<el-col :span="8">
|
|
||||||
<OrderCompletion :completion-rate="orderSummaryData.completionRate" />
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
|
||||||
<ProductSales :product-sales="productSalesData" />
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="8">
|
|
||||||
<CustomerRegion :customer-data="customerClusterData" />
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<!-- 定时刷新设置抽屉 -->
|
<!-- 定时刷新设置抽屉 -->
|
||||||
<el-drawer
|
<el-drawer
|
||||||
title="定时刷新设置"
|
title="定时刷新设置"
|
||||||
@@ -98,10 +68,6 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import OrderSummary from './components/OrderSummary.vue'
|
|
||||||
import OrderCompletion from './components/OrderCompletion.vue'
|
|
||||||
import ProductSales from './components/ProductSales.vue'
|
|
||||||
import CustomerRegion from './components/CustomerRegion.vue'
|
|
||||||
import PerformanceArea from './components/PerformanceArea.vue'
|
import PerformanceArea from './components/PerformanceArea.vue'
|
||||||
import CurrentSituationArea from './components/CurrentSituationArea.vue'
|
import CurrentSituationArea from './components/CurrentSituationArea.vue'
|
||||||
import RecommendationArea from './components/RecommendationArea.vue'
|
import RecommendationArea from './components/RecommendationArea.vue'
|
||||||
@@ -110,10 +76,6 @@ import { getDashboardData } from '@/api/wms/order'
|
|||||||
export default {
|
export default {
|
||||||
name: 'OrderAnalysisDashboard',
|
name: 'OrderAnalysisDashboard',
|
||||||
components: {
|
components: {
|
||||||
OrderSummary,
|
|
||||||
OrderCompletion,
|
|
||||||
ProductSales,
|
|
||||||
CustomerRegion,
|
|
||||||
PerformanceArea,
|
PerformanceArea,
|
||||||
CurrentSituationArea,
|
CurrentSituationArea,
|
||||||
RecommendationArea,
|
RecommendationArea,
|
||||||
@@ -126,14 +88,6 @@ export default {
|
|||||||
currentSituationArea: {},
|
currentSituationArea: {},
|
||||||
recommendationArea: {}
|
recommendationArea: {}
|
||||||
},
|
},
|
||||||
// 原有数据结构(保持兼容性)
|
|
||||||
orderSummaryData: {
|
|
||||||
totalOrders: 0,
|
|
||||||
completedThisMonth: 0,
|
|
||||||
completionRate: 0
|
|
||||||
},
|
|
||||||
productSalesData: [],
|
|
||||||
customerClusterData: [],
|
|
||||||
// 新增定时刷新相关数据
|
// 新增定时刷新相关数据
|
||||||
drawerVisible: false,
|
drawerVisible: false,
|
||||||
autoRefresh: false,
|
autoRefresh: false,
|
||||||
@@ -164,21 +118,6 @@ export default {
|
|||||||
recommendationArea: data.recommendationArea || {}
|
recommendationArea: data.recommendationArea || {}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 保持原有数据结构的兼容性
|
|
||||||
this.orderSummaryData = {
|
|
||||||
totalOrders: data.orderSummary?.totalOrderCount || 0,
|
|
||||||
completedThisMonth: data.orderSummary?.monthFinishedOrderCount || 0,
|
|
||||||
completionRate: data.orderSummary?.finishedRate || 0,
|
|
||||||
...data.orderSummary
|
|
||||||
}
|
|
||||||
this.productSalesData = data.productRank || []
|
|
||||||
this.customerClusterData = data.customerRegion || []
|
|
||||||
this.materialAnalysisData = {
|
|
||||||
categories: (data.orderMaterial || []).map(item => item.materialName),
|
|
||||||
usageFrequency: (data.orderMaterial || []).map(item => item.usedCount),
|
|
||||||
stockQuantity: (data.orderMaterial || []).map(item => item.stockCount),
|
|
||||||
purchaseCycle: (data.orderMaterial || []).map(item => item.purchaseCycle)
|
|
||||||
}
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('获取数据看板数据失败:', error)
|
console.error('获取数据看板数据失败:', error)
|
||||||
this.$message.error('获取数据失败,请稍后重试')
|
this.$message.error('获取数据失败,请稍后重试')
|
||||||
|
|||||||
@@ -33,6 +33,9 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="unit" label="单位" />
|
<el-table-column prop="unit" label="单位" />
|
||||||
|
<el-table-column prop="onTheWay" label="在途" />
|
||||||
|
<el-table-column prop="inventory" label="在库" />
|
||||||
|
<el-table-column prop="demand" label="所需" />
|
||||||
<el-table-column prop="quantity" label="计划采购数">
|
<el-table-column prop="quantity" label="计划采购数">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-input-number v-model="scope.row.quantity" :min="0" size="small" />
|
<el-input-number v-model="scope.row.quantity" :min="0" size="small" />
|
||||||
|
|||||||
@@ -20,7 +20,12 @@
|
|||||||
<el-table :data="detailList" v-loading="loading" style="width: 100%">
|
<el-table :data="detailList" v-loading="loading" style="width: 100%">
|
||||||
<el-table-column prop="detailId" label="明细ID" align="center" />
|
<el-table-column prop="detailId" label="明细ID" align="center" />
|
||||||
<el-table-column prop="lineName" label="产线名称" align="center" />
|
<el-table-column prop="lineName" label="产线名称" align="center" />
|
||||||
<el-table-column prop="productName" label="产品名称" align="center" />
|
<!-- <el-table-column prop="productName" label="产品名称" align="center" /> -->
|
||||||
|
<el-table-column prop="productCode" label="产品信息" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<ProductInfo :productId="scope.row.productId" />
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="quantity" label="排产数量" align="center" />
|
<el-table-column prop="quantity" label="排产数量" align="center" />
|
||||||
<el-table-column prop="startDate" label="开始日期" align="center" />
|
<el-table-column prop="startDate" label="开始日期" align="center" />
|
||||||
<el-table-column prop="endDate" label="结束日期" align="center" />
|
<el-table-column prop="endDate" label="结束日期" align="center" />
|
||||||
@@ -82,10 +87,11 @@ import { listProduct } from '@/api/wms/product';
|
|||||||
import { listProductionLine } from '@/api/wms/productionLine';
|
import { listProductionLine } from '@/api/wms/productionLine';
|
||||||
import GanttChartEcharts from '../productionLine/GanttChartEcharts.vue';
|
import GanttChartEcharts from '../productionLine/GanttChartEcharts.vue';
|
||||||
import { ganttProductionLine } from '@/api/wms/productionLine';
|
import { ganttProductionLine } from '@/api/wms/productionLine';
|
||||||
|
import ProductInfo from '@/components/KLPService/Renderer/ProductInfo.vue';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'SchedulePlanDetail',
|
name: 'SchedulePlanDetail',
|
||||||
components: { GanttChartEcharts },
|
components: { GanttChartEcharts, ProductInfo },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
planId: null,
|
planId: null,
|
||||||
|
|||||||
Reference in New Issue
Block a user