Compare commits

..

No commits in common. "a492fe4c87280450d320a04bd1abfdbf56914971" and "e11c71edf1abf861701cda91ea3d8a239ebe5cd1" have entirely different histories.

6 changed files with 863 additions and 1033 deletions

View File

@ -1,7 +1,7 @@
###
# @Author: Do not edit
# @Date: 2023-08-29 09:40:39
# @LastEditTime: 2024-11-07 09:29:23
# @LastEditTime: 2024-10-21 16:41:54
# @LastEditors: zwq
# @Description:
###
@ -12,7 +12,16 @@ ENV = 'development'
VUE_APP_TITLE = MES系统
# 芋道管理系统/开发环境
# VUE_APP_BASE_API = 'http://172.16.21.222:48082'
# VUE_APP_BASE_API = 'http://100.64.0.26:48082'
# VUE_APP_BASE_API = 'http://192.168.0.33:48082'
# VUE_APP_BASE_API = 'http://192.168.4.173:48080'
# VUE_APP_BASE_API = 'http://192.168.2.173:48080'
# VUE_APP_BASE_API = 'http://192.168.1.81:48082'
# VUE_APP_BASE_API = 'http://192.168.1.8:48082'
# VUE_APP_BASE_API = 'http://192.168.4.159:48080'
# VUE_APP_BASE_API = 'http://192.168.1.56:48082'
# VUE_APP_BASE_API = 'http://192.168.4.159:48080'
# VUE_APP_BASE_API = 'http://192.168.1.64:48082'
VUE_APP_BASE_API = 'http://mes2.kszny.picaiba.com'

View File

@ -207,11 +207,11 @@ export function getDetailTree(data) {
params: data
})
}
export function getDetailTreeInfo(query) {
export function getDetailTreeInfo(data) {
return request({
url: 'base/order/getDetailTreeInfoByIdNew',
url: 'base/order/getDetailTreeInfoById',
method: 'get',
params: query
params: data
})
}

View File

@ -1,417 +1,290 @@
<template>
<el-form
ref="addWorkOrder"
:rules="rules"
label-width="130px"
:model="form"
label-position="top">
<el-row :gutter="20">
<el-col :span="6">
<el-form-item label="工单模式">
<el-radio-group v-model="isBind">
<el-radio :label="true">绑定工单</el-radio>
<el-radio :label="false">新增工单</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="工单名称" prop="name" v-if="!isBind">
<el-input v-model="form.name"></el-input>
</el-form-item>
<el-form-item label="工单名称" prop="workOrderId" v-if="isBind">
<el-select
v-model="form.workOrderId"
placeholder="请选择"
style="width: 100%"
filterable
@change="getWorkOrderMsg">
<el-option
v-for="item in workOrderList"
:key="item.id"
:label="item.name"
:value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="工单编码" prop="code">
<el-input v-model="form.code" disabled></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="产品名称" prop="planProductId">
<el-select
v-model="form.planProductId"
placeholder="请选择"
disabled
style="width: 100%">
<el-option
v-for="item in productList"
:key="item.id"
:label="item.name + ' | ' + item.specifications"
:value="item.id">
<span style="float: left">{{ item.name }}</span>
<span style="float: right; color: #8492a6; font-size: 13px">
{{ item.specifications }}
</span>
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="计划开始时间">
<el-date-picker
v-model="planStartTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
style="width: 100%"
placeholder="选择日期"
:disabled="isBind"></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="计划完成时间">
<el-date-picker
v-model="planFinishTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
style="width: 100%"
placeholder="选择日期"
:disabled="isBind"></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="计划投入数量" prop="planAssignQuantity">
<el-input-number
v-model="form.planAssignQuantity"
:min="0"
:max="9999999999999"
:disabled="isBind"
style="width: 100%"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="计划生产数量" prop="planQuantity">
<el-input-number
v-model="form.planQuantity"
:min="0"
:max="9999999999999"
:disabled="isBind"
style="width: 100%"></el-input-number>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="关联工艺" prop="processFlowId">
<el-select
v-model="form.processFlowId"
placeholder="请选择"
disabled
style="width: 100%">
<el-option
v-for="item in processFlowList"
:key="item.id"
:label="item.name"
:value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="物料计算方式" prop="materialMethod">
<el-select
v-model="form.materialMethod"
placeholder="请选择"
style="width: 100%"
disabled>
<el-option label="产品基础BOM" :value="1"></el-option>
<el-option label="工艺扩展BOM" :value="2"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="优先级" prop="priority">
<el-select
v-model="form.priority"
placeholder="请选择"
style="width: 100%"
:disabled="isBind">
<el-option
v-for="item in getDictDatas(DICT_TYPE.ORDER_PRIORITY)"
:key="item.value"
:label="item.label"
:value="item.value"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="工单类型" prop="type">
<el-select
v-model="form.type"
placeholder="请选择"
style="width: 100%"
:disabled="isBind">
<el-option
v-for="item in workOrderTypeList"
:key="item.id"
:label="item.name"
:value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="关联产线" prop="productLineId">
<el-select
v-model="form.productLineId"
placeholder="请选择"
multiple
style="width: 100%"
:disabled="isBind">
<el-option
v-for="item in productLineList"
:key="item.id"
:label="item.name"
:value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="负责人" prop="workers">
<el-input v-model="form.workers" :disabled="isBind"></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="负责部门" prop="deptId">
<el-select
v-model="form.deptId"
placeholder="请选择关联产线"
style="width: 100%">
<el-option
v-for="item in deptList"
:key="item.id"
:label="item.name"
:value="item.id"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="计划分配订单量" prop="planAssignmentQuantity">
<el-input-number
v-model="form.planAssignmentQuantity"
:min="0"
:max="9999999999999"
style="width: 100%"></el-input-number>
</el-form-item>
</el-col>
</el-row>
</el-form>
<el-form ref="addWorkOrder" :rules="rules" label-width="130px" :model="form" label-position='top'>
<el-row :gutter="20">
<el-col :span='6'>
<el-form-item label="工单名称" prop="name" v-if='!isBind'>
<el-input v-model="form.name"></el-input>
</el-form-item>
<el-form-item label="工单名称" prop="workOrderId" v-if='isBind'>
<el-select v-model="form.workOrderId" placeholder="请选择" style="width: 100%;" filterable
@change="getWorkOrderMsg">
<el-option v-for="item in workOrderList" :key="item.id" :label="item.name" :value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="工单编码" prop="code">
<el-input v-model="form.code" disabled></el-input>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="产品名称" prop="planProductId">
<el-select v-model="form.planProductId" placeholder="请选择" disabled style="width: 100%;">
<el-option v-for="item in productList" :key="item.id" :label="item.name+' | '+item.specifications"
:value="item.id">
<span style="float: left">{{ item.name }}</span>
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.specifications }}</span>
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="计划开始时间">
<el-date-picker v-model="planStartTime" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
style="width: 100%;" placeholder="选择日期" :disabled="isBind">
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span='6'>
<el-form-item label="计划完成时间">
<el-date-picker v-model="planFinishTime" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
style="width: 100%;" placeholder="选择日期" :disabled="isBind">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="计划投入数量" prop="planAssignQuantity">
<el-input-number v-model="form.planAssignQuantity" :min="0" :max="9999999999999" :disabled="isBind"
style="width: 100%;"></el-input-number>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="计划生产数量" prop="planQuantity">
<el-input-number v-model="form.planQuantity" :min="0" :max="9999999999999" :disabled="isBind"
style="width: 100%;"></el-input-number>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="关联工艺" prop="processFlowId">
<el-select v-model="form.processFlowId" placeholder="请选择" disabled style="width: 100%;">
<el-option v-for="item in processFlowList" :key="item.id" :label="item.name" :value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span='6'>
<el-form-item label="物料计算方式" prop="materialMethod">
<el-select v-model="form.materialMethod" placeholder="请选择" style="width: 100%;" disabled>
<el-option label="产品基础BOM" :value="1"></el-option>
<el-option label="工艺扩展BOM" :value="2"></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="优先级" prop="priority">
<el-select v-model="form.priority" placeholder="请选择" style="width: 100%;" :disabled="isBind">
<el-option v-for="item in getDictDatas(DICT_TYPE.ORDER_PRIORITY)" :key="item.value" :label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="工单类型" prop="type">
<el-select v-model="form.type" placeholder="请选择" style="width: 100%;" :disabled="isBind">
<el-option v-for="item in workOrderTypeList" :key="item.id" :label="item.name" :value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="关联产线" prop="productLineId">
<el-select v-model="form.productLineId" placeholder="请选择" multiple style="width: 100%;" :disabled="isBind">
<el-option v-for="item in productLineList" :key="item.id" :label="item.name" :value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span='6'>
<el-form-item label="负责人" prop="workers">
<el-input v-model="form.workers" :disabled="isBind"></el-input>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="负责部门" prop="deptId">
<el-select v-model="form.deptId" placeholder="请选择关联产线" style="width: 100%;">
<el-option v-for="item in deptList" :key="item.id" :label="item.name" :value="item.id">
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span='6'>
<el-form-item label="计划分配订单量" prop="planAssignmentQuantity">
<el-input-number v-model="form.planAssignmentQuantity" :min="0" :max="9999999999999" style="width: 100%;">
</el-input-number>
</el-form-item>
</el-col>
</el-row>
</el-form>
</template>
<script>
import { getProductAll } from '@/api/base/product';
import {
getProcessFlowList,
getWorkOrderCode,
orderIssue,
workOrderList,
getWorkOrderById,
} from '@/api/base/orderManage';
import { getLineAll } from '@/api/base/productionLine';
import { getProductAll } from '@/api/base/product'
import { getProcessFlowList, getWorkOrderCode, orderIssue, workOrderList, getWorkOrderById } from '@/api/base/orderManage'
import { getLineAll } from '@/api/base/productionLine'
import { listDept } from '@/api/system/dept';
import moment from 'moment';
import moment from 'moment'
export default {
name: 'AddWorkOrder',
data() {
return {
form: {
workOrderId: '',
orderId: '',
name: '',
code: '',
planProductId: '',
planStartTime: '',
planFinishTime: '',
planAssignQuantity: 0,
deptId: undefined,
planQuantity: 0,
processFlowId: '',
materialMethod: 1,
priority: '',
productLineId: [],
type: '',
workers: '',
planAssignmentQuantity: '',
},
deptList: [],
rules: {
name: [
{ required: true, message: '工单名称不能为空', trigger: 'blur' },
],
planProductId: [
{ required: true, message: '产品名称不能为空', trigger: 'change' },
],
planAssignQuantity: [
{ required: true, message: '计划投入数量不能为空', trigger: 'blur' },
],
planQuantity: [
{ required: true, message: '计划生产数量不能为空', trigger: 'blur' },
],
productLineId: [
{ required: true, message: '产线不能为空', trigger: 'change' },
],
planAssignmentQuantity: [
{
required: true,
message: '计划分配订单量不能为空',
trigger: 'blur',
},
],
},
productList: [],
processFlowList: [],
productLineList: [],
workOrderTypeList: [
{ id: 1, name: '标准工单' },
{ id: 2, name: '特殊工单' },
],
planStartTime: '',
planFinishTime: '',
isBind: false,
workOrderList: [],
orderData: {},
};
},
methods: {
init(data, param) {
this.isBind = true;
this.orderData = data;
this.form.orderId = data.id;
this.getList();
},
changeAdd() {
if (this.isBind) {
this.isBind = false;
getWorkOrderCode().then((res) => {
this.form.code = res.data || '';
});
this.form.orderId = null;
this.form.planProductId = this.orderData.planProductId;
this.form.processFlowId = this.orderData.processFlowId;
this.form.materialMethod = this.orderData.materialMethod;
} else {
this.isBind = true;
this.form.orderId = this.orderData.id;
this.form.planProductId = null;
this.form.processFlowId = null;
this.form.materialMethod = null;
this.form.code = null;
}
},
getList() {
listDept().then((res) => {
this.deptList = res.data || [];
});
//
getProductAll().then((res) => {
this.productList = res.data || [];
});
// 线
getLineAll().then((res) => {
this.productLineList = res.data || [];
});
//
getProcessFlowList().then((res) => {
this.processFlowList = res.data || [];
});
// list
workOrderList({
status: 1,
}).then((res) => {
this.workOrderList = res.data || [];
});
},
addWorkOrderSubmit() {
this.$refs['addWorkOrder'].validate((valid) => {
if (valid) {
if (this.isBind) {
//
orderIssue({
workOrderId: this.form.workOrderId,
orderId: this.form.orderId,
planAssignmentQuantity: this.form.planAssignmentQuantity,
}).then((res) => {
if (res.code === 0) {
this.$modal.msgSuccess('操作成功');
this.$emit('addWorkOrderSubmit');
}
});
} else {
//
let _this = this;
_this.form.planStartTime = _this.planStartTime
? new Date(_this.planStartTime).valueOf()
: '';
_this.form.planFinishTime = _this.planFinishTime
? new Date(_this.planFinishTime).valueOf()
: '';
orderIssue({ ..._this.form }).then((res) => {
if (res.code === 0) {
_this.$modal.msgSuccess('操作成功');
let name = this.form.name;
_this.$emit('addWorkOrderSubmit');
// 使
// _this.$modal.confirm('使?').then(function() {
// _this.$router.push({
// path: '/core/core-work-order?workOrderName='+encodeURI(name)
// })
// })
}
});
}
} else {
return false;
}
});
},
formClear() {
this.$refs.addWorkOrder.resetFields();
this.form.materialMethod = 1;
this.form.planAssignQuantity = 0;
this.form.planQuantity = 0;
this.planFinishTime = '';
this.planStartTime = '';
this.form.planFinishTime = '';
this.form.planStartTime = '';
this.isBind = false;
},
//
getWorkOrderMsg() {
if (this.form.workOrderId) {
getWorkOrderById({ id: this.form.workOrderId }).then((res) => {
if (res.code === 0) {
this.form.code = res.data.code;
this.form.planProductId = res.data.planProductId;
this.planStartTime = res.data.planStartTime
? moment
.unix(res.data.planStartTime)
.format('YYYY-MM-DD HH:mm:ss')
: null;
this.planFinishTime = res.data.planFinishTime
? moment
.unix(res.data.planFinishTime)
.format('YYYY-MM-DD HH:mm:ss')
: null;
this.form.planAssignQuantity = res.data.planAssignQuantity;
this.form.planQuantity = res.data.planQuantity;
this.form.processFlowId = res.data.processFlowId;
this.form.materialMethod = res.data.materialMethod;
this.form.priority = res.data.priority
? res.data.priority + ''
: '';
this.form.productLineId = res.data.productLineIds;
this.form.type = res.data.type;
this.form.workers = res.data.workers;
}
});
}
},
},
};
name: 'AddWorkOrder',
data() {
return {
form: {
workOrderId: '',
orderId: '',
name: '',
code: '',
planProductId: '',
planStartTime: '',
planFinishTime: '',
planAssignQuantity: 0,
deptId:undefined,
planQuantity: 0,
processFlowId: '',
materialMethod: 1,
priority: '',
productLineId: [],
type: '',
workers: '',
planAssignmentQuantity: ''
},
deptList:[],
rules: {
name: [{ required: true, message: "工单名称不能为空", trigger: "blur" }],
planProductId: [{ required: true, message: "产品名称不能为空", trigger: "change" }],
planAssignQuantity: [{ required: true, message: "计划投入数量不能为空", trigger: "blur" }],
planQuantity: [{ required: true, message: "计划生产数量不能为空", trigger: "blur" }],
productLineId: [{ required: true, message: "产线不能为空", trigger: "change" }],
planAssignmentQuantity: [{ required: true, message: "计划分配订单量不能为空", trigger: "blur" }]
},
productList: [],
processFlowList: [],
productLineList: [],
workOrderTypeList: [
{id: 1,name:'标准工单'},
{id: 2, name:'特殊工单'}
],
planStartTime: '',
planFinishTime: '',
isBind: false,
workOrderList: []
}
},
methods: {
init(data, param) {
this.form.orderId = data.id
this.getList()
if (param === 'add') {
this.isBind = false
getWorkOrderCode().then(res => {
this.form.code = res.data || ''
})
this.form.planProductId = data.planProductId
this.form.processFlowId = data.processFlowId
this.form.materialMethod = data.materialMethod
}else{//
this.isBind = true
}
},
getList() {
listDept().then(res => {
this.deptList = res.data || []
})
//
getProductAll().then(res => {
this.productList = res.data || []
})
// 线
getLineAll().then(res => {
this.productLineList = res.data || []
})
//
getProcessFlowList().then(res => {
this.processFlowList = res.data || []
})
// list
workOrderList({
status: 1
}).then(res => {
this.workOrderList = res.data || []
})
},
addWorkOrderSubmit() {
this.$refs['addWorkOrder'].validate((valid) => {
if (valid) {
if (this.isBind) {
//
orderIssue({
workOrderId: this.form.workOrderId,
orderId: this.form.orderId,
planAssignmentQuantity: this.form.planAssignmentQuantity
}).then((res) => {
if (res.code === 0) {
this.$modal.msgSuccess("操作成功")
this.$emit('addWorkOrderSubmit')
}
})
} else {
//
let _this = this
_this.form.planStartTime = _this.planStartTime ? new Date(_this.planStartTime).valueOf() : ''
_this.form.planFinishTime = _this.planFinishTime ? new Date(_this.planFinishTime).valueOf() : ''
orderIssue({ ..._this.form }).then(res => {
if (res.code === 0) {
_this.$modal.msgSuccess("操作成功")
let name = this.form.name
_this.$emit('addWorkOrderSubmit')
// 使
// _this.$modal.confirm('使?').then(function() {
// _this.$router.push({
// path: '/core/core-work-order?workOrderName='+encodeURI(name)
// })
// })
}
})
}
} else {
return false
}
})
},
formClear() {
this.$refs.addWorkOrder.resetFields()
this.form.materialMethod = 1
this.form.planAssignQuantity = 0
this.form.planQuantity = 0
this.planFinishTime = ''
this.planStartTime = ''
this.form.planFinishTime = ''
this.form.planStartTime = ''
this.isBind = false
},
//
getWorkOrderMsg() {
if (this.form.workOrderId) {
getWorkOrderById({id:this.form.workOrderId}).then(res => {
if (res.code === 0) {
this.form.code = res.data.code
this.form.planProductId = res.data.planProductId
this.planStartTime = res.data.planStartTime ? moment.unix(res.data.planStartTime).format('YYYY-MM-DD HH:mm:ss') : null
this.planFinishTime = res.data.planFinishTime ? moment.unix(res.data.planFinishTime).format('YYYY-MM-DD HH:mm:ss') : null
this.form.planAssignQuantity = res.data.planAssignQuantity
this.form.planQuantity = res.data.planQuantity
this.form.processFlowId = res.data.processFlowId
this.form.materialMethod = res.data.materialMethod
this.form.priority = res.data.priority ? res.data.priority + '' : ''
this.form.productLineId = res.data.productLineIds
this.form.type = res.data.type
this.form.workers = res.data.workers
}
})
}
}
}
}
</script>

View File

@ -2,7 +2,7 @@
* @Author: zwq
* @Date: 2024-09-26 14:08:58
* @LastEditors: zwq
* @LastEditTime: 2024-11-06 09:52:59
* @LastEditTime: 2024-11-05 14:19:46
* @Description:
-->
<template>
@ -27,7 +27,7 @@
<base-table
:table-props="tableProps"
:table-data="list"
@emitFun="inputChange"
@emitFun="inputChange"
:max-height="tableH">
<!-- <method-btn v-if="tableBtn.length" slot="handleBtn" :width="240" label="操作" :method-list="tableBtn"
@clickBtn="handleClick" /> -->
@ -49,7 +49,6 @@ import { parseTime } from '@/utils/ruoyi';
import inputArea from './inputArea.vue';
import selectMember from './selectMember';
import selectTime from './selectTime';
import { publicFormatter } from '@/utils/dict'
const tableProps = [
{
prop: 'name',
@ -62,16 +61,19 @@ const tableProps = [
prop: 'code',
label: '订单编码',
minWidth: 180,
subcomponent: inputArea,
},
{
prop: 'productName',
label: '产品',
showOverflowtooltip: true,
subcomponent: inputArea,
},
{
prop: 'specifications',
label: '产品规格',
showOverflowtooltip: true,
subcomponent: inputArea,
},
// {
// prop: 'priority',
@ -95,20 +97,19 @@ const tableProps = [
prop: 'customerId',
label: '客户',
showOverflowtooltip: true,
// subcomponent: selectMember,
subcomponent: selectMember,
},
{
prop: 'price',
label: '单价',
width: 100,
// subcomponent: inputArea,
subcomponent: inputArea,
},
{
prop: 'packSpec',
label: '包装规格',
width: 100,
filter: publicFormatter('pack_spec')
// subcomponent: selectMember,
subcomponent: selectMember,
},
{
prop: 'remark',
@ -170,7 +171,6 @@ export default {
this.list = res.data;
this.list.forEach((item, index) => {
item.name = item.name + '-' + (index + 1);
item.code = item.code + '-' + (index + 1);
});
});
} else {
@ -220,7 +220,7 @@ export default {
//
getCustomerList().then((res) => {
this.customerList = res.data || [];
this.$set(this.tableProps[6], 'customerList', this.customerList);
this.$set(this.tableProps[6], 'customerList', this.customerList);
});
//
// getProcessFlowList().then(res => {
@ -249,12 +249,13 @@ export default {
// }
// },
inputChange(data) {
console.log(data)
switch (data.sType) {
case 1:
this.list[data._pageIndex - 1][data.prop] = data[data.prop];
break;
case 2:
this.list[data._pageIndex - 1][data.prop] = data[data.prop];
this.list[data._pageIndex - 1][data.prop] = data[data.prop];
break;
case 3:
this.list[data._pageIndex - 1][data.prop] = data.deliveTime;

File diff suppressed because it is too large Load Diff

View File

@ -38,18 +38,11 @@
{{ getDictDataLabel(DICT_TYPE.PACK_SPEC, orderMsg.packSpec) }}
</div>
</el-col>
<el-col :span="3">
<div class="blodTip">物料计算方式</div>
<div class="lightTip">
{{
orderMsg.materialMethod
? orderMsg.materialMethod === 1
? '产品基础'
: '工艺扩展'
: ''
}}
</div>
</el-col>
<el-col :span='3'>
<div class="blodTip">物料计算方式</div>
<div class="lightTip">{{orderMsg.materialMethod ? (orderMsg.materialMethod === 1 ? '产品基础' : '工艺扩展') : ''}}
</div>
</el-col>
<!-- <el-col :span="3">
<div class="blodTip">计划开始时间</div>
<div class="lightTip">{{ parseTime(orderMsg.planStartTime) }}</div>
@ -150,7 +143,6 @@
<el-tree
:data="treeData"
:props="defaultProps"
default-expand-all
@node-click="handleNodeClick"></el-tree>
</el-col>
<el-col :span="18">
@ -193,23 +185,16 @@ const tableProps1 = [
filter: parseTime,
minWidth: 160,
},
{
prop: 'type',
label: '订单/工单类型',
minWidth: 140,
showOverflowtooltip: true,
sortable:true
},
{
prop: 'name',
label: '订单/工单名',
label: '工单名',
minWidth: 100,
showOverflowtooltip: true,
},
{
prop: 'code',
label: '订单/工单编码',
minWidth: 165,
label: '工单编码',
minWidth: 150,
},
{
prop: 'planAssignmentQuantity',
@ -221,11 +206,11 @@ const tableProps1 = [
label: '实际加工量',
width: 100,
},
// {
// prop: 'actualArea',
// label: '',
// width: 100,
// },
{
prop: 'actualArea',
label: '加工平方数',
width: 100,
},
{
prop: 'status',
label: '状态',
@ -313,23 +298,27 @@ export default {
this.activeModule = val;
},
handleNodeClick(val) {
console.log(val);
getDetailTreeInfo({
id: val.id,
}).then((res) => {
this.list1 = res.data;
this.list1 = res.data.order;
console.log(res);
});
},
initData(to) {
if (to.name === 'OrderDetailData') {
this.orderId = location.href.split('=')[1];
this.orderId = location.href.split('=')[1];
this.getMsg();
}
},
getMsg() {
console.log(this.orderId)
orderDetail({
id: this.orderId,
}).then((res) => {
this.orderMsg = res.data;
this.list1 = res.data.coreWorkOrderRespVOS;
getOrderRemainNum(this.orderId).then((resNum) => {
bomUseNum({
@ -350,20 +339,11 @@ export default {
}
});
});
getDetailTreeInfo({
id: this.orderId,
}).then((res) => {
this.list1 = res.data;
});
getDetailTree({
id: this.orderId,
}).then((res) => {
console.log(res);
this.treeData = res.data;
this.treeData.unshift({
id:this.orderId,
name:'全部'
})
});
//
getProcessFlowList().then((res) => {