|
|
|
@ -6,25 +6,25 @@
|
|
|
|
|
<div class="title">工单信息</div>
|
|
|
|
|
<div class="chart">
|
|
|
|
|
<div class="form1">
|
|
|
|
|
<el-form label-position="right" label-width="80px" :model="form1">
|
|
|
|
|
<el-form :model="form" label-position="right" label-width="80px">
|
|
|
|
|
<el-form-item label="工单编号">
|
|
|
|
|
<el-input v-model="form1.name"></el-input>
|
|
|
|
|
<el-input v-model="form.planCode"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="物料编号">
|
|
|
|
|
<el-input v-model="form1.region"></el-input>
|
|
|
|
|
<el-form-item label="明细编号">
|
|
|
|
|
<el-input v-model="form.planDetailCode"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="物料名称">
|
|
|
|
|
<el-input v-model="form1.type"></el-input>
|
|
|
|
|
<el-form-item label="成品名称">
|
|
|
|
|
<el-input v-model="form.materialId"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="扫码时间">
|
|
|
|
|
<el-input v-model="form1.type"></el-input>
|
|
|
|
|
<el-form-item label="成品编号">
|
|
|
|
|
<el-input v-model="form.materialName"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="产品型号">
|
|
|
|
|
<el-input v-model="form1.type"></el-input>
|
|
|
|
|
<el-form-item label="状态">
|
|
|
|
|
<el-input v-model="form.planDetailStatus"></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-form>
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
|
<el-button type="primary">图纸下发</el-button>
|
|
|
|
|
<el-button type="primary" @click="finish()">完成</el-button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
@ -55,12 +55,13 @@
|
|
|
|
|
<div class="chart">
|
|
|
|
|
<div class="whiteTable">
|
|
|
|
|
<el-table
|
|
|
|
|
:data="tableData"
|
|
|
|
|
style="width: 100%"
|
|
|
|
|
max-height="19.13vw"
|
|
|
|
|
:cell-style="{textAlign:'center'}"
|
|
|
|
|
:data="tableData"
|
|
|
|
|
:header-cell-style="{textAlign:'center'}"
|
|
|
|
|
|
|
|
|
|
:max-height="19.13 * vw"
|
|
|
|
|
highlight-current-row
|
|
|
|
|
style="width: 100%"
|
|
|
|
|
@current-change="tableClick"
|
|
|
|
|
>
|
|
|
|
|
<el-table-column
|
|
|
|
|
label="序号"
|
|
|
|
@ -69,32 +70,41 @@
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="workOrderNumber"
|
|
|
|
|
label="工单编号"
|
|
|
|
|
prop="planCode"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
label="物料名称"
|
|
|
|
|
prop="materialName"
|
|
|
|
|
width="100"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="planNum"
|
|
|
|
|
label="计划"
|
|
|
|
|
width="80"
|
|
|
|
|
prop="planAmount"
|
|
|
|
|
width="100"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="realNum"
|
|
|
|
|
label="实际"
|
|
|
|
|
width="80"
|
|
|
|
|
prop="completeAmount"
|
|
|
|
|
width="100"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="quantityNum"
|
|
|
|
|
label="差异"
|
|
|
|
|
width="80"
|
|
|
|
|
prop="difference"
|
|
|
|
|
width="100"
|
|
|
|
|
>
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
{{ scope.row.planAmount - scope.row.completeAmount }}
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="startTime"
|
|
|
|
|
label="开始时间"
|
|
|
|
|
width="200"
|
|
|
|
|
label="交付时间"
|
|
|
|
|
prop="planDeliveryDate"
|
|
|
|
|
width="150"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
@ -102,31 +112,40 @@
|
|
|
|
|
width="120"
|
|
|
|
|
>
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
<el-button
|
|
|
|
|
type="text"
|
|
|
|
|
size="small"
|
|
|
|
|
<!-- <el-button-->
|
|
|
|
|
<!-- size="small"-->
|
|
|
|
|
<!-- type="text"-->
|
|
|
|
|
<!-- >-->
|
|
|
|
|
<!-- SOP预览-->
|
|
|
|
|
<!-- </el-button>-->
|
|
|
|
|
<el-popconfirm
|
|
|
|
|
cancel-button-text='否'
|
|
|
|
|
confirm-button-text='是'
|
|
|
|
|
icon="el-icon-info"
|
|
|
|
|
icon-color="red"
|
|
|
|
|
title="确定开始计划吗?"
|
|
|
|
|
@confirm="startPlan(scope.row)"
|
|
|
|
|
>
|
|
|
|
|
开始
|
|
|
|
|
</el-button>
|
|
|
|
|
<el-button
|
|
|
|
|
type="text"
|
|
|
|
|
size="small"
|
|
|
|
|
>
|
|
|
|
|
退库
|
|
|
|
|
</el-button>
|
|
|
|
|
<el-button
|
|
|
|
|
type="text"
|
|
|
|
|
slot="reference"
|
|
|
|
|
size="small"
|
|
|
|
|
style="color: #f56c6c"
|
|
|
|
|
>
|
|
|
|
|
删除
|
|
|
|
|
type="text">开始
|
|
|
|
|
</el-button>
|
|
|
|
|
</el-popconfirm>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
</el-table>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div>
|
|
|
|
|
<div class="roundBorder" style="top: 72%;left: 1.2%;">
|
|
|
|
|
<el-button :disabled="nowNum1 <= 1" circle icon="el-icon-back" size="mini" @click="pre1"></el-button>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="roundBorder" style="top: 72%;left: 49%;">
|
|
|
|
|
<el-button :disabled="nowNum1 >= totalNum1" circle icon="el-icon-right" size="mini" @click="next1"></el-button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="chartBox chartBox4">
|
|
|
|
|
<div class="title">当日产量</div>
|
|
|
|
@ -149,7 +168,25 @@
|
|
|
|
|
<script>
|
|
|
|
|
import Chart from '@/components/board/Chart'
|
|
|
|
|
import * as echarts from 'echarts'
|
|
|
|
|
import {
|
|
|
|
|
completeProductPlanDetail,
|
|
|
|
|
getNewestProductPlanDetail,
|
|
|
|
|
getProductPlanDetails,
|
|
|
|
|
getProductPlans,
|
|
|
|
|
startNextProductPlanDetail
|
|
|
|
|
} from '@/api/board'
|
|
|
|
|
|
|
|
|
|
const setState = (e) => {
|
|
|
|
|
if (e === '1') {
|
|
|
|
|
return '未开始'
|
|
|
|
|
}
|
|
|
|
|
if (e === '2') {
|
|
|
|
|
return '已开始'
|
|
|
|
|
}
|
|
|
|
|
if (e === '3' || e === '9') {
|
|
|
|
|
return '已完成'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
const vw = (document.documentElement.clientWidth || document.body.clientWidth) / 100
|
|
|
|
|
export default {
|
|
|
|
|
name: 'Board1',
|
|
|
|
@ -158,47 +195,220 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
form: {
|
|
|
|
|
name: '',
|
|
|
|
|
region: '',
|
|
|
|
|
date1: '',
|
|
|
|
|
date2: '',
|
|
|
|
|
delivery: false,
|
|
|
|
|
type: [],
|
|
|
|
|
resource: '',
|
|
|
|
|
desc: ''
|
|
|
|
|
},
|
|
|
|
|
form1: {
|
|
|
|
|
name: '',
|
|
|
|
|
region: '',
|
|
|
|
|
type: ''
|
|
|
|
|
},
|
|
|
|
|
tableData: [
|
|
|
|
|
nowNum1: 1,
|
|
|
|
|
totalNum1: 0,
|
|
|
|
|
form: {},
|
|
|
|
|
tableData: [],
|
|
|
|
|
vw: (document.documentElement.clientWidth || document.body.clientWidth) / 100,
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
|
this.$refs.chart2.setData({
|
|
|
|
|
tooltip: {
|
|
|
|
|
trigger: 'axis',
|
|
|
|
|
axisPointer: {
|
|
|
|
|
// 坐标轴指示器,坐标轴触发有效
|
|
|
|
|
type: 'shadow' // 默认为直线,可选为:'line' | 'shadow'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
grid: {
|
|
|
|
|
left: '0',
|
|
|
|
|
right: '4%',
|
|
|
|
|
bottom: '0',
|
|
|
|
|
top: 20,
|
|
|
|
|
containLabel: true
|
|
|
|
|
},
|
|
|
|
|
xAxis: {
|
|
|
|
|
type: 'category',
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6],
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
// interval: 0,
|
|
|
|
|
// rotate: 40,
|
|
|
|
|
textStyle: {
|
|
|
|
|
fontFamily: 'Microsoft YaHei'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
yAxis: {
|
|
|
|
|
type: 'value',
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {}
|
|
|
|
|
},
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
workOrderNumber: '202401221413',
|
|
|
|
|
planNum: '1000',
|
|
|
|
|
realNum: '800',
|
|
|
|
|
quantityNum: '200',
|
|
|
|
|
startTime: '2024-01-01',
|
|
|
|
|
name: '数量',
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
show: true,
|
|
|
|
|
position: 'top',
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#a8aab0',
|
|
|
|
|
fontStyle: 'normal',
|
|
|
|
|
fontFamily: '微软雅黑',
|
|
|
|
|
fontSize: 0.75 * vw
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
type: 'bar',
|
|
|
|
|
barWidth: '30%',
|
|
|
|
|
barMaxWidth: 50,
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
|
|
|
|
|
{
|
|
|
|
|
workOrderNumber: '202401221413',
|
|
|
|
|
planNum: '1000',
|
|
|
|
|
realNum: '800',
|
|
|
|
|
quantityNum: '200',
|
|
|
|
|
startTime: '2024-01-01',
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: '#39ffff'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
workOrderNumber: '202401221413',
|
|
|
|
|
planNum: '1000',
|
|
|
|
|
realNum: '800',
|
|
|
|
|
quantityNum: '200',
|
|
|
|
|
startTime: '2024-01-01',
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: '#5affa6'
|
|
|
|
|
}
|
|
|
|
|
])
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6]
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
})
|
|
|
|
|
this.$refs.chart4.setData({
|
|
|
|
|
tooltip: {
|
|
|
|
|
trigger: 'axis',
|
|
|
|
|
axisPointer: {
|
|
|
|
|
// 坐标轴指示器,坐标轴触发有效
|
|
|
|
|
type: 'shadow' // 默认为直线,可选为:'line' | 'shadow'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
|
grid: {
|
|
|
|
|
left: '0',
|
|
|
|
|
right: '4%',
|
|
|
|
|
bottom: '0',
|
|
|
|
|
top: 20,
|
|
|
|
|
containLabel: true
|
|
|
|
|
},
|
|
|
|
|
xAxis: {
|
|
|
|
|
type: 'category',
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6],
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
// interval: 0,
|
|
|
|
|
// rotate: 40,
|
|
|
|
|
textStyle: {
|
|
|
|
|
fontFamily: 'Microsoft YaHei'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
yAxis: {
|
|
|
|
|
type: 'value',
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {}
|
|
|
|
|
},
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
name: '数量',
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
show: true,
|
|
|
|
|
position: 'top',
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#a8aab0',
|
|
|
|
|
fontStyle: 'normal',
|
|
|
|
|
fontFamily: '微软雅黑',
|
|
|
|
|
fontSize: 0.75 * vw
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
type: 'bar',
|
|
|
|
|
barWidth: '30%',
|
|
|
|
|
barMaxWidth: 50,
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: '#39ffff'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: '#5affa6'
|
|
|
|
|
}
|
|
|
|
|
])
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6]
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
})
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
this.tableClick(e.rows[0])
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
next1() {
|
|
|
|
|
this.nowNum1 += 1
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
pre1() {
|
|
|
|
|
this.nowNum1 -= 1
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
async startPlan(val) {
|
|
|
|
|
const data = await startNextProductPlanDetail({planId: val.planId})
|
|
|
|
|
if (data.code === 200) {
|
|
|
|
|
this.$message({
|
|
|
|
|
message: '已开始',
|
|
|
|
|
type: 'success'
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
this.form = data.data || {}
|
|
|
|
|
this.form.materialId = val.materialId
|
|
|
|
|
this.form.materialName = val.materialName
|
|
|
|
|
this.form.planDetailStatus = setState(data.data.planDetailStatus)
|
|
|
|
|
this.getInfo(val)
|
|
|
|
|
},
|
|
|
|
|
async tableClick(val) {
|
|
|
|
|
const {data} = await getNewestProductPlanDetail({planId: val.planId})
|
|
|
|
|
this.form = data || {}
|
|
|
|
|
this.form.materialId = val.materialId
|
|
|
|
|
this.form.materialName = val.materialName
|
|
|
|
|
this.form.planDetailStatus = setState(data.planDetailStatus)
|
|
|
|
|
this.getInfo(val)
|
|
|
|
|
},
|
|
|
|
|
getInfo(e) {
|
|
|
|
|
this.$refs.chart1_1.setData({
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
@ -221,7 +431,7 @@ export default {
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 100,
|
|
|
|
|
value: e.planAmount === 0 ? 0.0001 : e.planAmount,
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
rich: {
|
|
|
|
@ -240,7 +450,7 @@ export default {
|
|
|
|
|
formatter: function (params) {
|
|
|
|
|
return (
|
|
|
|
|
"{a|" +
|
|
|
|
|
100 +
|
|
|
|
|
(params.data.value === 0.0001 ? 0 : params.data.value) +
|
|
|
|
|
"}" +
|
|
|
|
|
"\n{b|计划}"
|
|
|
|
|
);
|
|
|
|
@ -300,7 +510,7 @@ export default {
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 100,
|
|
|
|
|
value: e.completeAmount === 0 ? 0.0001 : e.completeAmount,
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
rich: {
|
|
|
|
@ -319,7 +529,7 @@ export default {
|
|
|
|
|
formatter: function (params) {
|
|
|
|
|
return (
|
|
|
|
|
"{a|" +
|
|
|
|
|
100 +
|
|
|
|
|
(params.data.value === 0.0001 ? 0 : params.data.value) +
|
|
|
|
|
"}" +
|
|
|
|
|
"\n{b|实际}"
|
|
|
|
|
);
|
|
|
|
@ -379,7 +589,7 @@ export default {
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 100,
|
|
|
|
|
value: Math.abs((e.planAmount - e.completeAmount) === 0 ? 0.0001 : (e.planAmount - e.completeAmount)),
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
rich: {
|
|
|
|
@ -398,7 +608,7 @@ export default {
|
|
|
|
|
formatter: function (params) {
|
|
|
|
|
return (
|
|
|
|
|
"{a|" +
|
|
|
|
|
100 +
|
|
|
|
|
(params.data.value === 0.0001 ? 0 : params.data.value) +
|
|
|
|
|
"}" +
|
|
|
|
|
"\n{b|差异}"
|
|
|
|
|
);
|
|
|
|
@ -458,7 +668,7 @@ export default {
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 100,
|
|
|
|
|
value: ((e.completeAmount / e.planAmount) * 100).toFixed(2),
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
rich: {
|
|
|
|
@ -477,7 +687,7 @@ export default {
|
|
|
|
|
formatter: function (params) {
|
|
|
|
|
return (
|
|
|
|
|
"{a|" +
|
|
|
|
|
100 +
|
|
|
|
|
(params.data.value === 0.0001 ? 0 : params.data.value) +
|
|
|
|
|
"%}" +
|
|
|
|
|
"\n{b|完成率}"
|
|
|
|
|
);
|
|
|
|
@ -500,7 +710,7 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
value: 0,
|
|
|
|
|
value: ((1 - (e.completeAmount / e.planAmount)) * 100).toFixed(2),
|
|
|
|
|
name: "invisible",
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
@ -515,170 +725,36 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
})
|
|
|
|
|
this.$refs.chart2.setData({
|
|
|
|
|
tooltip: {
|
|
|
|
|
trigger: 'axis',
|
|
|
|
|
axisPointer: {
|
|
|
|
|
// 坐标轴指示器,坐标轴触发有效
|
|
|
|
|
type: 'shadow' // 默认为直线,可选为:'line' | 'shadow'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
grid: {
|
|
|
|
|
left: '0',
|
|
|
|
|
right: '4%',
|
|
|
|
|
bottom: '0',
|
|
|
|
|
top: 20,
|
|
|
|
|
containLabel: true
|
|
|
|
|
},
|
|
|
|
|
xAxis: {
|
|
|
|
|
type: 'category',
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6],
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
// interval: 0,
|
|
|
|
|
// rotate: 40,
|
|
|
|
|
textStyle: {
|
|
|
|
|
fontFamily: 'Microsoft YaHei'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
async finish() {
|
|
|
|
|
|
|
|
|
|
yAxis: {
|
|
|
|
|
type: 'value',
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {}
|
|
|
|
|
},
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
name: '数量',
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
show: true,
|
|
|
|
|
position: 'top',
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#a8aab0',
|
|
|
|
|
fontStyle: 'normal',
|
|
|
|
|
fontFamily: '微软雅黑',
|
|
|
|
|
fontSize: 0.75 * vw
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
type: 'bar',
|
|
|
|
|
barWidth: '30%',
|
|
|
|
|
barMaxWidth: 50,
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: '#39ffff'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: '#5affa6'
|
|
|
|
|
}
|
|
|
|
|
])
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6]
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
this.$confirm('确认计划完成?', '提示', {
|
|
|
|
|
confirmButtonText: '确定',
|
|
|
|
|
cancelButtonText: '取消',
|
|
|
|
|
type: 'warning'
|
|
|
|
|
}).then(async () => {
|
|
|
|
|
const data = await completeProductPlanDetail({
|
|
|
|
|
planDetailId: this.form.planDetailId
|
|
|
|
|
})
|
|
|
|
|
this.$refs.chart4.setData({
|
|
|
|
|
tooltip: {
|
|
|
|
|
trigger: 'axis',
|
|
|
|
|
axisPointer: {
|
|
|
|
|
// 坐标轴指示器,坐标轴触发有效
|
|
|
|
|
type: 'shadow' // 默认为直线,可选为:'line' | 'shadow'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
grid: {
|
|
|
|
|
left: '0',
|
|
|
|
|
right: '4%',
|
|
|
|
|
bottom: '0',
|
|
|
|
|
top: 20,
|
|
|
|
|
containLabel: true
|
|
|
|
|
},
|
|
|
|
|
xAxis: {
|
|
|
|
|
type: 'category',
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6],
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
// interval: 0,
|
|
|
|
|
// rotate: 40,
|
|
|
|
|
textStyle: {
|
|
|
|
|
fontFamily: 'Microsoft YaHei'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
yAxis: {
|
|
|
|
|
type: 'value',
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: 'white'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {}
|
|
|
|
|
},
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
name: '数量',
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
show: true,
|
|
|
|
|
position: 'top',
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#a8aab0',
|
|
|
|
|
fontStyle: 'normal',
|
|
|
|
|
fontFamily: '微软雅黑',
|
|
|
|
|
fontSize: 0.75 * vw
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
type: 'bar',
|
|
|
|
|
barWidth: '30%',
|
|
|
|
|
barMaxWidth: 50,
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: '#39ffff'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: '#5affa6'
|
|
|
|
|
}
|
|
|
|
|
])
|
|
|
|
|
if (data.code === 200) {
|
|
|
|
|
this.$message({
|
|
|
|
|
message: '已完成',
|
|
|
|
|
type: 'success'
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
getProductPlans({pageNum: this.nowNum1, pageSize: 5}).then(e => {
|
|
|
|
|
this.tableData = e.rows
|
|
|
|
|
this.totalNum1 = Math.ceil(e.total / 5)
|
|
|
|
|
this.tableClick(e.rows.find(v => v.planCode === this.form.planCode))
|
|
|
|
|
})
|
|
|
|
|
}).catch(() => {
|
|
|
|
|
this.$message({
|
|
|
|
|
type: 'info',
|
|
|
|
|
message: '已取消'
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: [1, 2, 3, 4, 5, 6]
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
methods: {}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
<style lang="less" scoped>
|
|
|
|
@ -830,4 +906,13 @@ export default {
|
|
|
|
|
border-radius: 0;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.roundBorder {
|
|
|
|
|
position: absolute;
|
|
|
|
|
transform: translate(-50%, -50%);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/deep/ .current-row td .cell {
|
|
|
|
|
color: #000 !important;
|
|
|
|
|
}
|
|
|
|
|
</style>
|
|
|
|
|