Compare commits
3 Commits
e64e33a203
...
b185d3ebf7
Author | SHA1 | Date | |
---|---|---|---|
b185d3ebf7 | |||
045843bc1c | |||
3812eb38a9 |
@ -71,3 +71,21 @@ export function deliveryLogDetCreate(data) {
|
|||||||
data: data
|
data: data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 获得一条发货详细
|
||||||
|
export function deliveryLogDetGet(query) {
|
||||||
|
return request({
|
||||||
|
url: '/extend/delivery-log-det/get',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 编辑发货详情
|
||||||
|
export function deliveryLogDetUpdate(data) {
|
||||||
|
return request({
|
||||||
|
url: '/extend/delivery-log-det/update',
|
||||||
|
method: 'put',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
@ -137,4 +137,13 @@ export function bomUseNum(query) {
|
|||||||
method: 'get',
|
method: 'get',
|
||||||
params: query
|
params: query
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 完成订单
|
||||||
|
export function orderFinish(query) {
|
||||||
|
return request({
|
||||||
|
url: '/base/order/finish',
|
||||||
|
method: 'post',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
}
|
}
|
@ -1,46 +1,69 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-drawer
|
<div>
|
||||||
title="发货清单详情"
|
<el-drawer
|
||||||
size="60%"
|
title="发货清单详情"
|
||||||
:append-to-body="true"
|
size="60%"
|
||||||
:visible.sync="centervisible"
|
:append-to-body="true"
|
||||||
@close='close'>
|
:visible.sync="centervisible"
|
||||||
<div class="box1">
|
@close='close'>
|
||||||
<el-row>
|
<div class="box1">
|
||||||
<el-col :span='12'>
|
<el-row>
|
||||||
<span class="title">订单名:</span>
|
<el-col :span='12'>
|
||||||
<span class="text">{{orderName ? orderName : '-'}}</span>
|
<span class="title">订单名:</span>
|
||||||
</el-col>
|
<span class="text">{{orderName ? orderName : '-'}}</span>
|
||||||
<el-col :span='12'>
|
</el-col>
|
||||||
<span class="title">发货单号:</span>
|
<el-col :span='12'>
|
||||||
<span class="text">{{code ? code : '-'}}</span>
|
<span class="title">发货单号:</span>
|
||||||
</el-col>
|
<span class="text">{{code ? code : '-'}}</span>
|
||||||
</el-row>
|
</el-col>
|
||||||
</div>
|
</el-row>
|
||||||
<div class="box2">
|
|
||||||
<div class="boxTitle">
|
|
||||||
<span class="blueTitle"></span>
|
|
||||||
<span>详情</span>
|
|
||||||
</div>
|
</div>
|
||||||
<base-table
|
<div class="box2">
|
||||||
:page="queryParams.pageNo"
|
<div class="boxTitle">
|
||||||
:limit="queryParams.pageSize"
|
<span class="blueTitle"></span>
|
||||||
:table-props="tableProps"
|
<span>详情</span>
|
||||||
:table-data="tableData"
|
</div>
|
||||||
:max-height="tableH"
|
<base-table
|
||||||
/>
|
:page="queryParams.pageNo"
|
||||||
<pagination
|
:limit="queryParams.pageSize"
|
||||||
:page.sync="queryParams.pageNo"
|
:table-props="tableProps"
|
||||||
:limit.sync="queryParams.pageSize"
|
:table-data="tableData"
|
||||||
:total="total"
|
:max-height="tableH"
|
||||||
@pagination="getList"
|
>
|
||||||
/>
|
<method-btn
|
||||||
</div>
|
v-if="tableBtn.length"
|
||||||
</el-drawer>
|
slot="handleBtn"
|
||||||
|
:width="80"
|
||||||
|
label="操作"
|
||||||
|
:method-list="tableBtn"
|
||||||
|
@clickBtn="editDetDetail"
|
||||||
|
/>
|
||||||
|
</base-table>
|
||||||
|
<pagination
|
||||||
|
:page.sync="queryParams.pageNo"
|
||||||
|
:limit.sync="queryParams.pageSize"
|
||||||
|
:total="total"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</el-drawer>
|
||||||
|
<!-- 编辑详情 -->
|
||||||
|
<base-dialog
|
||||||
|
dialogTitle="编辑"
|
||||||
|
:dialogVisible="detailEditVisible"
|
||||||
|
@cancel="handleCancel"
|
||||||
|
@confirm="handleConfirm"
|
||||||
|
:before-close="handleCancel"
|
||||||
|
width="50%"
|
||||||
|
>
|
||||||
|
<edit-detail ref="editDetail" @successSubmit="successSubmit" />
|
||||||
|
</base-dialog>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { parseTime } from '@/utils/ruoyi'
|
import { parseTime } from '@/utils/ruoyi'
|
||||||
import { deliveryLogDetPage } from '@/api/base/delivery'
|
import { deliveryLogDetPage } from '@/api/base/delivery'
|
||||||
|
import EditDetail from './editDetail.vue'
|
||||||
const tableProps = [
|
const tableProps = [
|
||||||
{
|
{
|
||||||
prop: 'createTime',
|
prop: 'createTime',
|
||||||
@ -51,6 +74,7 @@ const tableProps = [
|
|||||||
{
|
{
|
||||||
prop: 'deliveryCarCode',
|
prop: 'deliveryCarCode',
|
||||||
label: '装车单号',
|
label: '装车单号',
|
||||||
|
minWidth: 100,
|
||||||
showOverflowtooltip: true
|
showOverflowtooltip: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -96,11 +120,21 @@ export default {
|
|||||||
total: 0,
|
total: 0,
|
||||||
tableProps,
|
tableProps,
|
||||||
tableData: [],
|
tableData: [],
|
||||||
|
tableBtn: [
|
||||||
|
this.$auth.hasPermi('extend:delivery-log:update')
|
||||||
|
? {
|
||||||
|
type: 'edit',
|
||||||
|
btnName: '编辑'
|
||||||
|
}
|
||||||
|
: undefined
|
||||||
|
].filter((v) => v),
|
||||||
tableH: this.tableHeight(275),
|
tableH: this.tableHeight(275),
|
||||||
orderName: '',
|
orderName: '',
|
||||||
code: ''
|
code: '',
|
||||||
|
detailEditVisible: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
components: { EditDetail },
|
||||||
mounted() {
|
mounted() {
|
||||||
window.addEventListener('resize', () => {
|
window.addEventListener('resize', () => {
|
||||||
this.tableH = this.tableHeight(275)
|
this.tableH = this.tableHeight(275)
|
||||||
@ -128,6 +162,23 @@ export default {
|
|||||||
this.queryParams.logId = ''
|
this.queryParams.logId = ''
|
||||||
this.tableData = []
|
this.tableData = []
|
||||||
this.total = 0
|
this.total = 0
|
||||||
|
},
|
||||||
|
editDetDetail(val) {
|
||||||
|
this.detailEditVisible = true
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.editDetail.init(val.data.id)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
handleCancel() {
|
||||||
|
this.$refs.editDetail.formClear()
|
||||||
|
this.detailEditVisible = false
|
||||||
|
},
|
||||||
|
handleConfirm() {
|
||||||
|
this.$refs.editDetail.submitForm()
|
||||||
|
},
|
||||||
|
successSubmit() {
|
||||||
|
this.handleCancel()
|
||||||
|
this.getList()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
124
src/views/delivery/deliveryLog/components/editDetail.vue
Normal file
124
src/views/delivery/deliveryLog/components/editDetail.vue
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
<template>
|
||||||
|
<el-form ref="addOrUpdate" :rules="rules" label-width="130px" :model="form">
|
||||||
|
<el-row>
|
||||||
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="装车单号" prop="deliveryCarCode">
|
||||||
|
<el-input v-model="form.deliveryCarCode"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="装车时间" prop="loadTime">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="form.loadTime"
|
||||||
|
type="datetime"
|
||||||
|
format='yyyy-MM-dd HH:mm:ss'
|
||||||
|
value-format="timestamp"
|
||||||
|
style="width: 100%;"
|
||||||
|
placeholder="选择日期">
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="装车产品" prop="productId">
|
||||||
|
<el-select v-model="form.productId" disabled placeholder="请选择" style="width: 100%;">
|
||||||
|
<el-option
|
||||||
|
v-for="item in productList"
|
||||||
|
:key="item.id"
|
||||||
|
:label="item.name"
|
||||||
|
:value="item.id">
|
||||||
|
</el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="装箱规格(片/箱)" prop="packagingSize">
|
||||||
|
<el-input-number v-model="form.packagingSize" :min="0" :max='9999999999' style="width:100%"></el-input-number>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="产品批次" prop="productDate">
|
||||||
|
<el-input v-model="form.productDate" placeholder="多个批次用','隔开"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="箱/托数" prop="packagingNum">
|
||||||
|
<el-input-number v-model="form.packagingNum" :min="0" :max='9999999999' style="width:100%"></el-input-number>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="装车总量" prop="quantity">
|
||||||
|
<el-input-number v-model="form.quantity" :min="0" :max='9999999999' style="width:100%"></el-input-number>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { getProductAll } from '@/api/base/product'
|
||||||
|
import { deliveryLogDetGet, deliveryLogDetUpdate } from '@/api/base/delivery'
|
||||||
|
export default {
|
||||||
|
name: 'editDetail',
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
form: {
|
||||||
|
logId: '',
|
||||||
|
deliveryCarCode: '',
|
||||||
|
loadTime: null,
|
||||||
|
productId: '',
|
||||||
|
packagingSize: null,
|
||||||
|
productDate: '',
|
||||||
|
packagingNum: null,
|
||||||
|
quantity: null
|
||||||
|
},
|
||||||
|
rules: {
|
||||||
|
deliveryCarCode: [{ required: true, message: "装车单号不能为空", trigger: "blur" }],
|
||||||
|
productId: [{ required: true, message: "装车产品不能为空", trigger: "change" }],
|
||||||
|
packagingSize: [{ required: true, message: "装箱规格不能为空", trigger: "blur" }],
|
||||||
|
packagingNum: [{ required: true, message: "箱/托数不能为空", trigger: "blur" }],
|
||||||
|
quantity: [{ required: true, message: "装车总量不能为空", trigger: "blur" }]
|
||||||
|
},
|
||||||
|
productList: []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
this.getSelectList()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
init(id) {
|
||||||
|
deliveryLogDetGet({id}).then(res => {
|
||||||
|
console.log(res)
|
||||||
|
this.form = res.data
|
||||||
|
})
|
||||||
|
},
|
||||||
|
getSelectList() {
|
||||||
|
getProductAll().then(res => {
|
||||||
|
this.productList = res.data || []
|
||||||
|
})
|
||||||
|
},
|
||||||
|
submitForm() {
|
||||||
|
this.$refs['addOrUpdate'].validate((valid) => {
|
||||||
|
if (valid) {
|
||||||
|
console.log(this.form)
|
||||||
|
deliveryLogDetUpdate({ ...this.form }).then((res) => {
|
||||||
|
if (res.code === 0) {
|
||||||
|
this.$modal.msgSuccess("操作成功");
|
||||||
|
this.$emit('successSubmit')
|
||||||
|
}
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
formClear() {
|
||||||
|
this.$refs.addOrUpdate.resetFields()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
@ -302,7 +302,7 @@ export default {
|
|||||||
successSubmit2() {
|
successSubmit2() {
|
||||||
this.handleCancel2()
|
this.handleCancel2()
|
||||||
this.getList()
|
this.getList()
|
||||||
},
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
@ -19,11 +19,11 @@
|
|||||||
<div class="lightTip">{{orderMsg.num ? orderMsg.num : '-'}}</div>
|
<div class="lightTip">{{orderMsg.num ? orderMsg.num : '-'}}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="box_col">
|
<div class="box_col">
|
||||||
<div class="blodTip">累积占比(%)</div>
|
<div class="blodTip">累计占比(%)</div>
|
||||||
<div class="lightTip">{{orderMsg.rate ? orderMsg.rate : '-'}}</div>
|
<div class="lightTip">{{orderMsg.rate ? orderMsg.rate : '-'}}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="box_col">
|
<div class="box_col">
|
||||||
<div class="blodTip">累积运输费用</div>
|
<div class="blodTip">累计运输费用</div>
|
||||||
<div class="lightTip">{{orderMsg.cost ? orderMsg.cost : '-'}}</div>
|
<div class="lightTip">{{orderMsg.cost ? orderMsg.cost : '-'}}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -305,8 +305,11 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
legend: {
|
legend: {
|
||||||
bottom: '5%',
|
type: 'scroll',
|
||||||
left: 'center',
|
orient: 'vertical',
|
||||||
|
right: '10%',
|
||||||
|
top: 20,
|
||||||
|
bottom: 20,
|
||||||
icon: 'rect',
|
icon: 'rect',
|
||||||
itemHeight: 8,
|
itemHeight: 8,
|
||||||
itemWidth: 8
|
itemWidth: 8
|
||||||
|
@ -61,7 +61,7 @@ const tableProps = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'rate',
|
prop: 'rate',
|
||||||
label: '累积发货比例(%)'
|
label: '累计发货比例(%)'
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
export default {
|
export default {
|
||||||
|
@ -25,23 +25,18 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="产品名称" prop="planProductId">
|
<el-form-item label="产品名称" prop="planProductId">
|
||||||
<el-select v-model="form.planProductId" placeholder="请选择" :disabled="isBind" style="width: 100%;" @change="selectProduct">
|
<el-select v-model="form.planProductId" placeholder="请选择" disabled style="width: 100%;">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in productList"
|
v-for="item in productList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
:label="item.name"
|
:label="item.name+' | '+item.specifications"
|
||||||
:value="item.id">
|
: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-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='12'>
|
|
||||||
<el-form-item label="产品规格" prop="productSpec">
|
|
||||||
<el-input v-model="form.productSpec" disabled></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="计划开始时间">
|
<el-form-item label="计划开始时间">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
@ -54,6 +49,8 @@
|
|||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="计划完成时间">
|
<el-form-item label="计划完成时间">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
@ -66,23 +63,21 @@
|
|||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="计划投入数量" prop="planAssignQuantity">
|
<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-input-number v-model="form.planAssignQuantity" :min="0" :max="9999999999999" :disabled="isBind" style="width: 100%;"></el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="计划生产数量" prop="planQuantity">
|
<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-input-number v-model="form.planQuantity" :min="0" :max="9999999999999" :disabled="isBind" style="width: 100%;"></el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="关联工艺" prop="processFlowId">
|
<el-form-item label="关联工艺" prop="processFlowId">
|
||||||
<el-select v-model="form.processFlowId" placeholder="请选择" :disabled="isBind" style="width: 100%;">
|
<el-select v-model="form.processFlowId" placeholder="请选择" disabled style="width: 100%;">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in processFlowList"
|
v-for="item in processFlowList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
@ -92,16 +87,16 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="物料计算方式" prop="materialMethod">
|
<el-form-item label="物料计算方式" prop="materialMethod">
|
||||||
<el-radio-group v-model="form.materialMethod" :disabled="isBind">
|
<el-radio-group v-model="form.materialMethod" disabled>
|
||||||
<el-radio :label="1">产品基础</el-radio>
|
<el-radio :label="1">产品基础</el-radio>
|
||||||
<el-radio :label="2">工艺扩展</el-radio>
|
<el-radio :label="2">工艺扩展</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="优先级" prop="priority">
|
<el-form-item label="优先级" prop="priority">
|
||||||
<el-select v-model="form.priority" placeholder="请选择" style="width: 100%;" :disabled="isBind">
|
<el-select v-model="form.priority" placeholder="请选择" style="width: 100%;" :disabled="isBind">
|
||||||
@ -114,6 +109,8 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="工单类型" prop="type">
|
<el-form-item label="工单类型" prop="type">
|
||||||
<el-select v-model="form.type" placeholder="请选择" style="width: 100%;" :disabled="isBind">
|
<el-select v-model="form.type" placeholder="请选择" style="width: 100%;" :disabled="isBind">
|
||||||
@ -126,8 +123,6 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="关联产线" prop="productLineId">
|
<el-form-item label="关联产线" prop="productLineId">
|
||||||
<el-select v-model="form.productLineId" placeholder="请选择" multiple style="width: 100%;" :disabled="isBind">
|
<el-select v-model="form.productLineId" placeholder="请选择" multiple style="width: 100%;" :disabled="isBind">
|
||||||
@ -140,6 +135,8 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="负责人" prop="workers">
|
<el-form-item label="负责人" prop="workers">
|
||||||
<el-input v-model="form.workers" :disabled="isBind"></el-input>
|
<el-input v-model="form.workers" :disabled="isBind"></el-input>
|
||||||
@ -170,7 +167,6 @@ export default {
|
|||||||
name: '',
|
name: '',
|
||||||
code: '',
|
code: '',
|
||||||
planProductId: '',
|
planProductId: '',
|
||||||
productSpec: '',
|
|
||||||
planStartTime: '',
|
planStartTime: '',
|
||||||
planFinishTime: '',
|
planFinishTime: '',
|
||||||
planAssignQuantity: 0,
|
planAssignQuantity: 0,
|
||||||
@ -205,14 +201,17 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
init(id, param) {
|
init(data, param) {
|
||||||
this.form.orderId = id
|
this.form.orderId = data.id
|
||||||
this.getList()
|
this.getList()
|
||||||
if (param === 'add') {
|
if (param === 'add') {
|
||||||
this.isBind = false
|
this.isBind = false
|
||||||
getWorkOrderCode().then(res => {
|
getWorkOrderCode().then(res => {
|
||||||
this.form.code = res.data || ''
|
this.form.code = res.data || ''
|
||||||
})
|
})
|
||||||
|
this.form.planProductId = data.planProductId
|
||||||
|
this.form.processFlowId = data.processFlowId
|
||||||
|
this.form.materialMethod = data.materialMethod
|
||||||
}else{//绑定
|
}else{//绑定
|
||||||
this.isBind = true
|
this.isBind = true
|
||||||
}
|
}
|
||||||
@ -237,18 +236,6 @@ export default {
|
|||||||
this.workOrderList = res.data || []
|
this.workOrderList = res.data || []
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 选产品带出规格
|
|
||||||
selectProduct(val) {
|
|
||||||
if (val) {
|
|
||||||
this.productList.map(item => {
|
|
||||||
if (val === item.id) {
|
|
||||||
this.form.productSpec = item.specifications
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
this.form.productSpec = ''
|
|
||||||
}
|
|
||||||
},
|
|
||||||
addWorkOrderSubmit() {
|
addWorkOrderSubmit() {
|
||||||
this.$refs['addWorkOrder'].validate((valid) => {
|
this.$refs['addWorkOrder'].validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
@ -298,8 +285,6 @@ export default {
|
|||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.form.code = res.data.code
|
this.form.code = res.data.code
|
||||||
this.form.planProductId = res.data.planProductId
|
this.form.planProductId = res.data.planProductId
|
||||||
this.selectProduct(this.form.planProductId)
|
|
||||||
this.form.productSpec = res.data.productSpec
|
|
||||||
this.planStartTime = res.data.planStartTime ? moment.unix(res.data.planStartTime).format('YYYY-MM-DD HH:mm:ss') : null
|
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.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.planAssignQuantity = res.data.planAssignQuantity
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="订单号" prop="code">
|
<el-form-item label="订单号" prop="code">
|
||||||
<el-input v-model="form.code" disabled></el-input>
|
<el-input v-model="form.code"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
@ -20,12 +20,14 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="产品名称" prop="planProductId">
|
<el-form-item label="产品名称" prop="planProductId">
|
||||||
<el-select v-model="form.planProductId" placeholder="请选择" style="width: 100%;" @change="selectProduct">
|
<el-select v-model="form.planProductId" placeholder="请选择" style="width: 100%;">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in productList"
|
v-for="item in productList"
|
||||||
:key="item.id"
|
:key="item.id"
|
||||||
:label="item.name"
|
:label="item.name+' | '+item.specifications"
|
||||||
:value="item.id">
|
: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-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@ -37,13 +39,6 @@
|
|||||||
<el-input-number v-model="form.price" :min="0" :max="9999999999999" :precision='2' style="width: 100%;"></el-input-number>
|
<el-input-number v-model="form.price" :min="0" :max="9999999999999" :precision='2' style="width: 100%;"></el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='12'>
|
|
||||||
<el-form-item label="产品规格" prop="productSpec">
|
|
||||||
<el-input v-model="form.productSpec" disabled></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="客户" prop="customerId">
|
<el-form-item label="客户" prop="customerId">
|
||||||
<el-select v-model="form.customerId" placeholder="请选择" style="width: 100%;">
|
<el-select v-model="form.customerId" placeholder="请选择" style="width: 100%;">
|
||||||
@ -56,6 +51,8 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="优先级" prop="priority">
|
<el-form-item label="优先级" prop="priority">
|
||||||
<el-select v-model="form.priority" placeholder="请选择" style="width: 100%;">
|
<el-select v-model="form.priority" placeholder="请选择" style="width: 100%;">
|
||||||
@ -68,8 +65,6 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="包装规格" prop="packSpec">
|
<el-form-item label="包装规格" prop="packSpec">
|
||||||
<el-select v-model="form.packSpec" placeholder="请选择" style="width: 100%;">
|
<el-select v-model="form.packSpec" placeholder="请选择" style="width: 100%;">
|
||||||
@ -82,13 +77,13 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="负责人" prop="workers">
|
<el-form-item label="负责人" prop="workers">
|
||||||
<el-input v-model="form.workers"></el-input>
|
<el-input v-model="form.workers"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="关联工艺" prop="processFlowId">
|
<el-form-item label="关联工艺" prop="processFlowId">
|
||||||
<el-select v-model="form.processFlowId" placeholder="请选择" style="width: 100%;">
|
<el-select v-model="form.processFlowId" placeholder="请选择" style="width: 100%;">
|
||||||
@ -101,6 +96,8 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="物料计算方式" prop="materialMethod">
|
<el-form-item label="物料计算方式" prop="materialMethod">
|
||||||
<el-radio-group v-model="form.materialMethod">
|
<el-radio-group v-model="form.materialMethod">
|
||||||
@ -109,35 +106,33 @@
|
|||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span='12'>
|
<el-col :span='12'>
|
||||||
<el-form-item label="订单计划开始时间">
|
<el-form-item label="订单计划开始时间" prop="planStartTime">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="planStartTime"
|
v-model="form.planStartTime"
|
||||||
type="date"
|
type="datetime"
|
||||||
format='yyyy-MM-dd'
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
style="width: 100%;"
|
|
||||||
placeholder="选择日期">
|
|
||||||
</el-date-picker>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span='12'>
|
|
||||||
<el-form-item label="订单计划完成时间">
|
|
||||||
<el-date-picker
|
|
||||||
v-model="planFinishTime"
|
|
||||||
type="date"
|
|
||||||
format='yyyy-MM-dd'
|
|
||||||
value-format="yyyy-MM-dd"
|
|
||||||
style="width: 100%;"
|
style="width: 100%;"
|
||||||
|
value-format="timestamp"
|
||||||
|
@change="timeChange"
|
||||||
placeholder="选择日期">
|
placeholder="选择日期">
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span='24'>
|
<el-col :span='12'>
|
||||||
|
<el-form-item label="订单计划完成时间" prop="planFinishTime">
|
||||||
|
<el-date-picker
|
||||||
|
v-model="form.planFinishTime"
|
||||||
|
type="datetime"
|
||||||
|
style="width: 100%;"
|
||||||
|
value-format="timestamp"
|
||||||
|
@change="timeChange"
|
||||||
|
placeholder="选择日期">
|
||||||
|
</el-date-picker>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span='12'>
|
||||||
<el-form-item label="备注" prop="remark">
|
<el-form-item label="备注" prop="remark">
|
||||||
<el-input v-model="form.remark"></el-input>
|
<el-input v-model="form.remark"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@ -168,7 +163,6 @@ export default {
|
|||||||
planQuantity: '',
|
planQuantity: '',
|
||||||
planProductId: '',
|
planProductId: '',
|
||||||
price: '',
|
price: '',
|
||||||
productSpec: '',
|
|
||||||
customerId: '',
|
customerId: '',
|
||||||
priority: '',
|
priority: '',
|
||||||
packSpec: '',
|
packSpec: '',
|
||||||
@ -180,8 +174,6 @@ export default {
|
|||||||
planStartTime: '',
|
planStartTime: '',
|
||||||
planFinishTime: ''
|
planFinishTime: ''
|
||||||
},
|
},
|
||||||
planStartTime: '',
|
|
||||||
planFinishTime: '',
|
|
||||||
rules: {
|
rules: {
|
||||||
name: [{ required: true, message: "订单名称不能为空", trigger: "blur" }],
|
name: [{ required: true, message: "订单名称不能为空", trigger: "blur" }],
|
||||||
planQuantity: [{ required: true, message: "计划加工数量不能为空", trigger: "blur" }],
|
planQuantity: [{ required: true, message: "计划加工数量不能为空", trigger: "blur" }],
|
||||||
@ -205,16 +197,15 @@ export default {
|
|||||||
this.form.code = res.data.code
|
this.form.code = res.data.code
|
||||||
this.form.planQuantity = res.data.planQuantity
|
this.form.planQuantity = res.data.planQuantity
|
||||||
this.form.planProductId = res.data.planProductId
|
this.form.planProductId = res.data.planProductId
|
||||||
this.selectProduct(this.form.planProductId)
|
|
||||||
this.form.price = res.data.price
|
this.form.price = res.data.price
|
||||||
this.form.customerId = res.data.customerId
|
this.form.customerId = res.data.customerId
|
||||||
this.form.priority = res.data.priority ? res.data.priority + '' : ''
|
this.form.priority = res.data.priority ? res.data.priority + '' : ''
|
||||||
this.planStartTime = res.data.planStartTime ? moment(res.data.planStartTime).format('YYYY-MM-DD') : null
|
this.form.planStartTime = res.data.planStartTime ? res.data.planStartTime : null
|
||||||
this.form.packSpec = res.data.packSpec ? res.data.packSpec+'' : ''
|
this.form.packSpec = res.data.packSpec ? res.data.packSpec+'' : ''
|
||||||
this.form.workers = res.data.workers
|
this.form.workers = res.data.workers
|
||||||
this.form.processFlowId = res.data.processFlowId
|
this.form.processFlowId = res.data.processFlowId
|
||||||
this.form.materialMethod = res.data.materialMethod
|
this.form.materialMethod = res.data.materialMethod
|
||||||
this.planFinishTime = res.data.planFinishTime ? moment(res.data.planFinishTime).format('YYYY-MM-DD') : null
|
this.form.planFinishTime = res.data.planFinishTime ? res.data.planFinishTime : null
|
||||||
this.form.remark = res.data.remark
|
this.form.remark = res.data.remark
|
||||||
this.form.description = res.data.description
|
this.form.description = res.data.description
|
||||||
}
|
}
|
||||||
@ -242,24 +233,23 @@ export default {
|
|||||||
this.processFlowList = res.data || []
|
this.processFlowList = res.data || []
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 选产品带出规格
|
timeChange() {
|
||||||
selectProduct(val) {
|
if (this.form.planStartTime && this.form.planFinishTime) {
|
||||||
if (val) {
|
if (this.form.planStartTime > this.form.planFinishTime) {
|
||||||
this.productList.map(item => {
|
this.$modal.msgError('计划开始时间不能大于结束时间')
|
||||||
if (val === item.id) {
|
}
|
||||||
this.form.productSpec = item.specifications
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
this.form.productSpec = ''
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
submitForm() {
|
submitForm() {
|
||||||
this.$refs['orderAddForm'].validate((valid) => {
|
this.$refs['orderAddForm'].validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
this.form.planStartTime = this.planStartTime ? new Date(this.planStartTime).valueOf() : ''
|
if (this.form.planStartTime && this.form.planFinishTime) {
|
||||||
this.form.planFinishTime = this.planFinishTime ? new Date(this.planFinishTime).valueOf() : ''
|
if (this.form.planStartTime > this.form.planFinishTime) {
|
||||||
console.log(this.form)
|
this.$modal.msgError('计划开始时间不能大于结束时间')
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// console.log(this.form)
|
||||||
if (this.isEdit) {
|
if (this.isEdit) {
|
||||||
//编辑
|
//编辑
|
||||||
orderUpdate({ ...this.form }).then((res) => {
|
orderUpdate({ ...this.form }).then((res) => {
|
||||||
@ -288,10 +278,6 @@ export default {
|
|||||||
this.form.materialMethod = 1
|
this.form.materialMethod = 1
|
||||||
this.form.price = 0.00
|
this.form.price = 0.00
|
||||||
this.form.planQuantity = 0
|
this.form.planQuantity = 0
|
||||||
this.planFinishTime = ''
|
|
||||||
this.planStartTime = ''
|
|
||||||
this.form.planFinishTime = ''
|
|
||||||
this.form.planStartTime = ''
|
|
||||||
this.isEdit = false
|
this.isEdit = false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
<method-btn
|
<method-btn
|
||||||
v-if="tableBtn.length"
|
v-if="tableBtn.length"
|
||||||
slot="handleBtn"
|
slot="handleBtn"
|
||||||
:width="250"
|
:width="320"
|
||||||
label="操作"
|
label="操作"
|
||||||
:method-list="tableBtn"
|
:method-list="tableBtn"
|
||||||
@clickBtn="handleClick"
|
@clickBtn="handleClick"
|
||||||
@ -56,7 +56,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { parseTime } from '@/utils/ruoyi'
|
import { parseTime } from '@/utils/ruoyi'
|
||||||
import { getOrderPage, orderDelete, customerList } from '@/api/base/orderManage'
|
import { getOrderPage, orderDelete, customerList, orderFinish } from '@/api/base/orderManage'
|
||||||
import OrderAdd from './components/orderAdd'
|
import OrderAdd from './components/orderAdd'
|
||||||
import AddWorkOrder from './components/addWorkOrder'
|
import AddWorkOrder from './components/addWorkOrder'
|
||||||
import { publicFormatter } from '@/utils/dict'
|
import { publicFormatter } from '@/utils/dict'
|
||||||
@ -115,7 +115,8 @@ const tableProps = [
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'unit',
|
prop: 'unit',
|
||||||
label: '单位'
|
label: '单位',
|
||||||
|
filter: publicFormatter('unit_dict')
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
prop: 'price',
|
prop: 'price',
|
||||||
@ -191,13 +192,49 @@ export default {
|
|||||||
this.$auth.hasPermi('base:order-manage:addWorkOrder')
|
this.$auth.hasPermi('base:order-manage:addWorkOrder')
|
||||||
? {
|
? {
|
||||||
type: 'add',
|
type: 'add',
|
||||||
btnName: '新增工单'
|
btnName: '新增工单',
|
||||||
|
showParam: {
|
||||||
|
type: '&',
|
||||||
|
data: [
|
||||||
|
{
|
||||||
|
type: 'equal',
|
||||||
|
name: 'status',
|
||||||
|
value: 1
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
: undefined,
|
: undefined,
|
||||||
this.$auth.hasPermi('base:order-manage:bindWorkOrder')
|
this.$auth.hasPermi('base:order-manage:bindWorkOrder')
|
||||||
? {
|
? {
|
||||||
type: 'bind',
|
type: 'bind',
|
||||||
btnName: '绑定工单'
|
btnName: '绑定工单',
|
||||||
|
showParam: {
|
||||||
|
type: '&',
|
||||||
|
data: [
|
||||||
|
{
|
||||||
|
type: 'equal',
|
||||||
|
name: 'status',
|
||||||
|
value: 1
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
: undefined,
|
||||||
|
this.$auth.hasPermi('base:order-manage:bindWorkOrder')
|
||||||
|
? {
|
||||||
|
type: 'complete',
|
||||||
|
btnName: '完成工单',
|
||||||
|
showParam: {
|
||||||
|
type: '&',
|
||||||
|
data: [
|
||||||
|
{
|
||||||
|
type: 'equal',
|
||||||
|
name: 'status',
|
||||||
|
value: 2
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
: undefined,
|
: undefined,
|
||||||
this.$auth.hasPermi('base:order-manage:detail')
|
this.$auth.hasPermi('base:order-manage:detail')
|
||||||
@ -209,13 +246,43 @@ export default {
|
|||||||
this.$auth.hasPermi('base:order-manage:edit')
|
this.$auth.hasPermi('base:order-manage:edit')
|
||||||
? {
|
? {
|
||||||
type: 'edit',
|
type: 'edit',
|
||||||
btnName: '编辑'
|
btnName: '编辑',
|
||||||
|
showParam: {
|
||||||
|
type: '&',
|
||||||
|
data: [
|
||||||
|
{
|
||||||
|
type: 'equal',
|
||||||
|
name: 'triggerOrigin',
|
||||||
|
value: 1
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'equal',
|
||||||
|
name: 'status',
|
||||||
|
value: 1
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
: undefined,
|
: undefined,
|
||||||
this.$auth.hasPermi('base:order-manage:delete')
|
this.$auth.hasPermi('base:order-manage:delete')
|
||||||
? {
|
? {
|
||||||
type: 'delete',
|
type: 'delete',
|
||||||
btnName: '删除'
|
btnName: '删除',
|
||||||
|
showParam: {
|
||||||
|
type: '&',
|
||||||
|
data: [
|
||||||
|
{
|
||||||
|
type: 'equal',
|
||||||
|
name: 'triggerOrigin',
|
||||||
|
value: 1
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'equal',
|
||||||
|
name: 'status',
|
||||||
|
value: 1
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
: undefined
|
: undefined
|
||||||
].filter((v) => v),
|
].filter((v) => v),
|
||||||
@ -298,7 +365,7 @@ export default {
|
|||||||
this.workIssueTitle = '新增工单'
|
this.workIssueTitle = '新增工单'
|
||||||
this.addWorkOrdervisible = true
|
this.addWorkOrdervisible = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs.addWorkOrder.init(val.data.id, 'add')
|
this.$refs.addWorkOrder.init(val.data, 'add')
|
||||||
})
|
})
|
||||||
break
|
break
|
||||||
case 'bind':
|
case 'bind':
|
||||||
@ -308,6 +375,9 @@ export default {
|
|||||||
this.$refs.addWorkOrder.init(val.data.id, 'bind')
|
this.$refs.addWorkOrder.init(val.data.id, 'bind')
|
||||||
})
|
})
|
||||||
break
|
break
|
||||||
|
case 'complete':
|
||||||
|
this.handleComplete(val.data)
|
||||||
|
break
|
||||||
default:
|
default:
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -320,6 +390,15 @@ export default {
|
|||||||
this.$modal.msgSuccess("操作成功");
|
this.$modal.msgSuccess("操作成功");
|
||||||
}).catch(() => {});
|
}).catch(() => {});
|
||||||
},
|
},
|
||||||
|
// 完成
|
||||||
|
handleComplete(val) {
|
||||||
|
this.$modal.confirm('是否确认完成订单"' + val.name + '"?').then(function() {
|
||||||
|
return orderFinish({ id: val.id })
|
||||||
|
}).then(() => {
|
||||||
|
this.getList();
|
||||||
|
this.$modal.msgSuccess("操作成功");
|
||||||
|
}).catch(() => {});
|
||||||
|
},
|
||||||
// 新增
|
// 新增
|
||||||
handleCancel() {
|
handleCancel() {
|
||||||
this.$refs.orderAdd.formClear()
|
this.$refs.orderAdd.formClear()
|
||||||
|
@ -3,86 +3,94 @@
|
|||||||
<div class="box1">
|
<div class="box1">
|
||||||
<div class="boxTitle">
|
<div class="boxTitle">
|
||||||
<span class="blueTitle"></span>
|
<span class="blueTitle"></span>
|
||||||
<span>订单编码: 432784632747238</span>
|
<span>订单编码: {{orderMsg.code}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div style="padding-left: 14px;">
|
<div style="padding-left: 14px;">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">订单名</div>
|
<div class="blodTip">订单名</div>
|
||||||
<div class="lightTip">{{orderMsg.name}}</div>
|
<div class="lightTip">{{orderMsg.name}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">产品信息</div>
|
<div class="blodTip">产品信息</div>
|
||||||
<div class="lightTip">{{orderMsg.productName}}</div>
|
<div class="lightTip">{{orderMsg.productName}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">产品规格</div>
|
<div class="blodTip">产品规格</div>
|
||||||
<div class="lightTip">{{orderMsg.specifications}}</div>
|
<div class="lightTip">{{orderMsg.specifications}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">客户</div>
|
<div class="blodTip">客户</div>
|
||||||
<div class="lightTip">{{orderMsg.customerName}}</div>
|
<div class="lightTip">{{orderMsg.customerName}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">包装规格</div>
|
<div class="blodTip">包装规格</div>
|
||||||
<div class="lightTip">{{ getDictDataLabel(DICT_TYPE.PACK_SPEC, orderMsg.packSpec)}}</div>
|
<div class="lightTip">{{ getDictDataLabel(DICT_TYPE.PACK_SPEC, orderMsg.packSpec)}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">物料计算方式</div>
|
<div class="blodTip">物料计算方式</div>
|
||||||
<div class="lightTip">{{orderMsg.materialMethod ? (orderMsg.materialMethod === 1 ? '产品基础' : '工艺扩展') : ''}}</div>
|
<div class="lightTip">{{orderMsg.materialMethod ? (orderMsg.materialMethod === 1 ? '产品基础' : '工艺扩展') : ''}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
<el-col :span='3'>
|
||||||
<el-row>
|
|
||||||
<el-col :span='4'>
|
|
||||||
<div class="blodTip">创建时间</div>
|
<div class="blodTip">创建时间</div>
|
||||||
<div class="lightTip">{{ parseTime(orderMsg.triggerTime) }}</div>
|
<div class="lightTip">{{ parseTime(orderMsg.createTime) }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">计划开始时间</div>
|
<div class="blodTip">计划开始时间</div>
|
||||||
<div class="lightTip">{{ parseTime(orderMsg.planStartTime) }}</div>
|
<div class="lightTip">{{ parseTime(orderMsg.planStartTime) }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span='3'>
|
||||||
<div class="blodTip">计划完成时间</div>
|
<div class="blodTip">计划完成时间</div>
|
||||||
<div class="lightTip">{{ parseTime(orderMsg.planFinishTime) }}</div>
|
<div class="lightTip">{{ parseTime(orderMsg.planFinishTime) }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">计划加工数量</div>
|
<div class="blodTip">计划加工数量</div>
|
||||||
<div class="lightTip">{{orderMsg.planQuantity}}</div>
|
<div class="lightTip">{{orderMsg.planQuantity}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">加工平方数(平方米)</div>
|
<div class="blodTip">加工平方数(平方米)</div>
|
||||||
<div class="lightTip">{{orderMsg.planArea}}</div>
|
<div class="lightTip">{{orderMsg.planArea}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">预计用时(时)</div>
|
<div class="blodTip">预计用时(时)</div>
|
||||||
<div class="lightTip">{{ orderMsg.expectTime }}</div>
|
<div class="lightTip">{{ orderMsg.expectTime }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
<el-col :span='3'>
|
||||||
<el-row>
|
|
||||||
<el-col :span='4'>
|
|
||||||
<div class="blodTip">状态</div>
|
<div class="blodTip">状态</div>
|
||||||
<div class="lightTip">{{getDictDataLabel(DICT_TYPE.ORDER_STATUS, orderMsg.status)}}</div>
|
<div class="lightTip">{{getDictDataLabel(DICT_TYPE.ORDER_STATUS, orderMsg.status)}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">实际开始时间</div>
|
<div class="blodTip">实际开始时间</div>
|
||||||
<div class="lightTip">{{ parseTime(orderMsg.startProduceTime) }}</div>
|
<div class="lightTip">{{ parseTime(orderMsg.startProduceTime) }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">实际完成时间</div>
|
<div class="blodTip">实际完成时间</div>
|
||||||
<div class="lightTip">{{ parseTime(orderMsg.finishProduceTime) }}</div>
|
<div class="lightTip">{{ parseTime(orderMsg.finishProduceTime) }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">实际生产数量</div>
|
<div class="blodTip">实际生产数量</div>
|
||||||
<div class="lightTip">{{orderMsg.actualQuantity }}</div>
|
<div class="lightTip">{{orderMsg.actualQuantity }}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span='3'>
|
||||||
<div class="blodTip">完成比%</div>
|
<div class="blodTip">完成比%</div>
|
||||||
<div class="lightTip">{{orderMsg.completeProp}}</div>
|
<div class="lightTip">{{orderMsg.completeProp}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span='4'>
|
<el-col :span='3'>
|
||||||
<div class="blodTip">废片数量</div>
|
<div class="blodTip">废片数量</div>
|
||||||
<div class="lightTip">{{orderMsg.nokQuantity}}</div>
|
<div class="lightTip">{{orderMsg.nokQuantity}}</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span='3'>
|
||||||
|
<div class="blodTip">负责人</div>
|
||||||
|
<div class="lightTip">{{orderMsg.workers}}</div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span='3'>
|
||||||
|
<div class="blodTip">关联工艺</div>
|
||||||
|
<div class="lightTip">{{processFlowName}}</div>
|
||||||
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -118,7 +126,8 @@
|
|||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { parseTime } from '@/utils/ruoyi'
|
import { parseTime } from '@/utils/ruoyi'
|
||||||
import { publicFormatter } from '@/utils/dict';
|
import { publicFormatter } from '@/utils/dict'
|
||||||
|
import { getProcessFlowList } from '@/api/base/orderManage'
|
||||||
const tableProps1 = [
|
const tableProps1 = [
|
||||||
{
|
{
|
||||||
prop: 'issueTime',
|
prop: 'issueTime',
|
||||||
@ -172,7 +181,7 @@ const tableProps1 = [
|
|||||||
{
|
{
|
||||||
prop: 'productLineNames',
|
prop: 'productLineNames',
|
||||||
label: '关联产线',
|
label: '关联产线',
|
||||||
filter: (val) => val.join(','),
|
filter: (val) => val ? val.join(',') : '',
|
||||||
showOverflowtooltip: true
|
showOverflowtooltip: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -215,7 +224,8 @@ export default {
|
|||||||
pageNo: 1,
|
pageNo: 1,
|
||||||
pageSize: 500
|
pageSize: 500
|
||||||
},
|
},
|
||||||
orderMsg: {}
|
orderMsg: {},
|
||||||
|
processFlowName: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@ -256,6 +266,17 @@ export default {
|
|||||||
this.list2 = []
|
this.list2 = []
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
// 工艺
|
||||||
|
getProcessFlowList().then(res => {
|
||||||
|
let arr = res.data || []
|
||||||
|
if (arr.length > 0) {
|
||||||
|
arr.map(item => {
|
||||||
|
if (item.id === this.orderMsg.processFlowId) {
|
||||||
|
this.processFlowName = item.name
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -278,12 +299,14 @@ export default {
|
|||||||
padding: 16px 16px 0 16px;
|
padding: 16px 16px 0 16px;
|
||||||
.blodTip {
|
.blodTip {
|
||||||
height: 16px;
|
height: 16px;
|
||||||
|
font-size: 14px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: rgba(0,0,0,0.85);
|
color: rgba(0,0,0,0.85);
|
||||||
margin-bottom: 8px;
|
margin-bottom: 8px;
|
||||||
}
|
}
|
||||||
.lightTip {
|
.lightTip {
|
||||||
height: 16px;
|
height: 16px;
|
||||||
|
font-size: 14px;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
color: rgba(102,102,102,0.75);
|
color: rgba(102,102,102,0.75);
|
||||||
margin-bottom: 12px;
|
margin-bottom: 12px;
|
||||||
|
Loading…
Reference in New Issue
Block a user