模具 优化

This commit is contained in:
xielue 2023-09-16 10:40:58 +08:00
parent 9e49b56978
commit 293106346f
3 changed files with 44 additions and 18 deletions

View File

@ -62,9 +62,7 @@
<vxe-column field="mold_scheme" title="模型" width="160" :params="editor_scheme" formatter="formatRef"
:edit-render="{ name: 'MkGridDataSelector' }"></vxe-column>
<vxe-column field="production_type" title="布产类型" width="160" :params="options_production_type"
formatter='formatEnum'
:edit-render="{ name: '$select', props: { options: options_production_type } }"></vxe-column>
<vxe-column field="mold_master_user_detail" title="师傅" width="160" :params="editor_staff" formatter="formatRef"
:edit-render="{ name: 'MkGridDataSelector' }"></vxe-column>

View File

@ -31,9 +31,9 @@
:edit-render="{ name: '$input', props: { type: 'date' } }"></vxe-column>
<vxe-column title="完成" width="160">
<vxe-column title="完成" width="160" v-if="getDataId()">
<template #default="{ row }">
<div v-if="getDataId()">
<div>
<a-button v-if="pageIsComplete()" @click.stop="pageComplete(row)" type="primary">完成</a-button>
@ -44,7 +44,7 @@
<vxe-column field="complete_type" title="完工人员类型" width="160" :params="{ data: options_user_type }"
<vxe-column field="complete_type" v-if="getDataId()" title="完工人员类型" width="160" :params="{ data: options_user_type }"
formatter='formatEnum'></vxe-column>
<vxe-column field="remark" title="备注" width="160" :edit-render="{ name: '$input', props: {} }"></vxe-column>
@ -83,9 +83,9 @@
:edit-render="{ name: '$input', props: { type: 'date' } }"></vxe-column>
<vxe-column title="发料" width="210">
<vxe-column title="发料" width="210" v-if="getDataId()">
<template #default="{ row }">
<div v-if="getDataId()">
<div>
<a-button v-if="!row.is_send" @click.stop="pageSend(row)" type="primary">发料</a-button>
<div v-if="row.is_send">
@ -96,9 +96,9 @@
</template>
</vxe-column>
<vxe-column title="完成" width="210">
<vxe-column title="完成" width="210" v-if="getDataId()">
<template #default="{ row }">
<div v-if="getDataId() && row.is_send">
<div v-if="row.is_send">
<a-button v-if="!row.is_complete" @click.stop="pageDone(row)" type="primary">完成</a-button>
<div v-if="row.is_complete">
{{ $mk.getDateString(row.complete_time) }}
@ -108,11 +108,11 @@
</template>
</vxe-column>
<vxe-column field="send_type" title="发料人员类型" width="160" :params="{ data: options_user_type }"
<vxe-column field="send_type" v-if="getDataId()" title="发料人员类型" width="160" :params="{ data: options_user_type }"
formatter='formatEnum'></vxe-column>
<vxe-column field="complete_type" title="完工人员类型" width="160" :params="{ data: options_user_type }"
<vxe-column field="complete_type" v-if="getDataId()" title="完工人员类型" width="160" :params="{ data: options_user_type }"
formatter='formatEnum'></vxe-column>
<vxe-column field="remark" title="备注" width="160" :edit-render="{ name: '$input', props: {} }"></vxe-column>

View File

@ -7,7 +7,7 @@
<div class="voucher-toolbar-left">
<a-button @click="pageSelectOrder" :disabled="pageStatus == 'approved'">选择订单</a-button>
<a-button v-if="!getDataId()" @click="pageSelectOrder" :disabled="pageStatus == 'approved'">选择订单</a-button>
<a-button type="primary" @click="ok" :disabled="pageStatus == 'approved'">保存</a-button>
<a-button v-if="false" @click="pageApproved" type="primary" :disabled="!this.getDataId() || pageStatus == 'approved'">审批
</a-button>
@ -55,6 +55,10 @@
</a-tabs>
<h4 style="margin-top: 5px;">出现问题及建议反馈</h4>
<vxe-form :data="formOptions2.data" ref="xForm" :title-width="formOptions2.titleWidth"
:title-align="formOptions2.titleAlign" :rules="formOptions2.rules" :items="formOptions2.items" :titleColon="false" vertical>
</vxe-form>
<div class="mk-toolbar" v-if="isEdit">
@ -129,7 +133,7 @@ export default {
//
formOptions: {
data: {
production_type: "1"
production_type: 1
},
//
titleWidth: 180,
@ -223,6 +227,29 @@ export default {
]
},
formOptions2: {
data: {
},
//
titleWidth: 180,
//
titleAlign: 'top',
//
rules: {
},
//
items: [
{ showTitle:false, field: 'problem', title: '', span: 24, itemRender: { name: '$textarea', props: {} } },
]
},
//
addModeItems: [
@ -362,7 +389,9 @@ export default {
this.formOptions.data = this.$mk.formatDetailData({ data: a.data[this.detailDataFieldName], rules: this.formOptions.items });
this.formOptions2.data = {
problem : a.data[this.detailDataFieldName].problem
}
this.detailsData = JSON.parse(JSON.stringify(a.data[this.detailDataFieldName].mold_production_order_component || []));
this.detailsData2 = JSON.parse(JSON.stringify(a.data[this.detailDataFieldName].mold_production_order_component_processes || []));
@ -696,8 +725,7 @@ export default {
//
let action = !this.isEdit ? this.actions.create : this.actions.update;
// id id
let postdata = Object.assign({}, this.formOptions.data);
let postdata = Object.assign({}, this.formOptions.data, this.formOptions2.data);
//
this.$mk.formatFormData({ data: postdata, rules: this.formOptions.items });