|
|
@ -319,6 +319,16 @@ |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
</el-table> |
|
|
</el-table> |
|
|
|
|
|
<!-- 分页插件 --> |
|
|
|
|
|
<el-pagination |
|
|
|
|
|
@size-change="sizeChangeHandle2" |
|
|
|
|
|
@current-change="currentChangeHandle2" |
|
|
|
|
|
:current-page="pageIndex2" |
|
|
|
|
|
:page-sizes="[20, 50, 100, 200, 500]" |
|
|
|
|
|
:page-size="pageSize2" |
|
|
|
|
|
:total="totalPage2" |
|
|
|
|
|
layout="total, sizes, prev, pager, next, jumper"> |
|
|
|
|
|
</el-pagination> |
|
|
</div> |
|
|
</div> |
|
|
<el-footer style="height:40px;margin-top: 20px;text-align:center"> |
|
|
<el-footer style="height:40px;margin-top: 20px;text-align:center"> |
|
|
<el-button type="primary" @click="partModelFlag=false">关闭</el-button> |
|
|
<el-button type="primary" @click="partModelFlag=false">关闭</el-button> |
|
|
@ -417,15 +427,18 @@ |
|
|
<legend>Source Revision</legend> |
|
|
<legend>Source Revision</legend> |
|
|
<el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form-item label="物料编码"> |
|
|
<el-form-item label="物料编码"> |
|
|
<el-input v-model="modalData.partNo" readonly style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-model="modalData.partNo" readonly style="width: 120px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="modalData.site" disabled style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-form-item label="物料名称"> |
|
|
|
|
|
<el-input v-model="modalData.partDesc" readonly style="width: 249px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
|
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="modalData.site" readonly style="width: 85px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-input v-model="modalData.routingRevision" readonly style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-model="modalData.routingRevision" readonly style="width: 85px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-input v-model="modalData.routingType" readonly style="width: 185px"></el-input> |
|
|
<el-input v-model="modalData.routingType" readonly style="width: 185px"></el-input> |
|
|
@ -464,19 +477,23 @@ |
|
|
<fieldset style="width: 426px"> |
|
|
<fieldset style="width: 426px"> |
|
|
<legend>Destination Revision</legend> |
|
|
<legend>Destination Revision</legend> |
|
|
<el-form :inline="true" label-position="top" :model="copyRoutingData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="copyRoutingData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form-item label="物料编码"> |
|
|
|
|
|
<el-input v-model="copyRoutingData.partNo" style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-form-item> |
|
|
|
|
|
<span slot="label" @click="queryCopyPartModal"><a herf="#">物料编码</a></span> |
|
|
|
|
|
<el-input v-model="copyRoutingData.partNo" @change="copyRoutingTypeChange" @blur="copyPartBlur" style="width: 120px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="copyRoutingData.site" disabled style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-form-item :label="'物料名称'"> |
|
|
|
|
|
<el-input v-model="copyRoutingData.partDesc" disabled style="width: 249px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-form :inline="true" label-position="top" :model="copyRoutingData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="copyRoutingData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
|
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="copyRoutingData.site" disabled style="width: 85px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-input v-model="copyRoutingData.routingRevision" style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-model="copyRoutingData.routingRevision" style="width: 85px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-select v-model="copyRoutingData.routingType" style="width: 185px"> |
|
|
|
|
|
|
|
|
<el-select v-model="copyRoutingData.routingType" @change="copyRoutingTypeChange" style="width: 185px"> |
|
|
<el-option label="Manufacturing" value="Manufacturing"></el-option> |
|
|
<el-option label="Manufacturing" value="Manufacturing"></el-option> |
|
|
<el-option label="Repair" value="Repair"></el-option> |
|
|
<el-option label="Repair" value="Repair"></el-option> |
|
|
<el-option label="Prototype" value="Prototype"></el-option> |
|
|
<el-option label="Prototype" value="Prototype"></el-option> |
|
|
@ -493,7 +510,7 @@ |
|
|
</el-form> |
|
|
</el-form> |
|
|
</fieldset> |
|
|
</fieldset> |
|
|
<el-footer style="height:40px;margin-top: 10px;text-align:center"> |
|
|
<el-footer style="height:40px;margin-top: 10px;text-align:center"> |
|
|
<el-button type="primary" @click="copyRouting">保存</el-button> |
|
|
|
|
|
|
|
|
<el-button type="primary" :loading="copyLoading" @click="copyRouting">保存</el-button> |
|
|
<el-button type="primary" @click="copyRoutingModelFlag = false">关闭</el-button> |
|
|
<el-button type="primary" @click="copyRoutingModelFlag = false">关闭</el-button> |
|
|
</el-footer> |
|
|
</el-footer> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
@ -504,15 +521,18 @@ |
|
|
<legend>Source Revision</legend> |
|
|
<legend>Source Revision</legend> |
|
|
<el-form :inline="true" label-position="top" :model="detailData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="detailData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form-item label="物料编码"> |
|
|
<el-form-item label="物料编码"> |
|
|
<el-input v-model="detailData.partNo" readonly style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-model="detailData.partNo" readonly style="width: 120px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="detailData.site" disabled style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-form-item label="物料名称"> |
|
|
|
|
|
<el-input v-model="modalData.partDesc" readonly style="width: 249px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-form :inline="true" label-position="top" :model="detailData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="detailData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
|
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="detailData.site" readonly style="width: 85px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-input v-model="detailData.routingRevision" readonly style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-model="detailData.routingRevision" readonly style="width: 85px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-input v-model="detailData.routingType" readonly style="width: 185px"></el-input> |
|
|
<el-input v-model="detailData.routingType" readonly style="width: 185px"></el-input> |
|
|
@ -530,16 +550,20 @@ |
|
|
<fieldset style="width: 426px"> |
|
|
<fieldset style="width: 426px"> |
|
|
<legend>Destination Revision</legend> |
|
|
<legend>Destination Revision</legend> |
|
|
<el-form :inline="true" label-position="top" :model="copyAlternativeData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="copyAlternativeData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form-item label="物料编码"> |
|
|
|
|
|
<el-input v-model="copyAlternativeData.partNo" style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-form-item> |
|
|
|
|
|
<span slot="label" @click="queryCopyPartModal"><a herf="#">物料编码</a></span> |
|
|
|
|
|
<el-input v-model="copyAlternativeData.partNo" @blur="copyPartBlur" style="width: 120px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="copyAlternativeData.site" disabled style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-form-item :label="'物料名称'"> |
|
|
|
|
|
<el-input v-model="copyAlternativeData.partDesc" disabled style="width: 249px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-form :inline="true" label-position="top" :model="copyAlternativeData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="copyAlternativeData" style="margin-left: 7px;margin-top: -5px;"> |
|
|
|
|
|
<el-form-item label="Site"> |
|
|
|
|
|
<el-input v-model="copyAlternativeData.site" disabled style="width: 85px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-form-item label="Routing版本号"> |
|
|
<el-input v-model="copyAlternativeData.routingRevision" style="width: 185px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-model="copyAlternativeData.routingRevision" style="width: 85px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-form-item label="工艺类型"> |
|
|
<el-select v-model="copyAlternativeData.routingType" style="width: 185px"> |
|
|
<el-select v-model="copyAlternativeData.routingType" style="width: 185px"> |
|
|
@ -559,11 +583,61 @@ |
|
|
</el-form> |
|
|
</el-form> |
|
|
</fieldset> |
|
|
</fieldset> |
|
|
<el-footer style="height:40px;margin-top: 10px;text-align:center"> |
|
|
<el-footer style="height:40px;margin-top: 10px;text-align:center"> |
|
|
<el-button type="primary" @click="copyAlternative">保存</el-button> |
|
|
|
|
|
|
|
|
<el-button type="primary" :loading="copyLoading" @click="copyAlternative">保存</el-button> |
|
|
<el-button type="primary" @click="copyAlternativeModelFlag = false">关闭</el-button> |
|
|
<el-button type="primary" @click="copyAlternativeModelFlag = false">关闭</el-button> |
|
|
</el-footer> |
|
|
</el-footer> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
|
|
|
<!-- copy物料模态框 --> |
|
|
|
|
|
<el-dialog title="物料清单" top="17vh" :close-on-click-modal="false" v-drag :visible.sync="copyPartModelFlag" width="700px"> |
|
|
|
|
|
<el-form :inline="true" label-position="top" :model="copyPartData"> |
|
|
|
|
|
<el-form-item :label="'物料编码'"> |
|
|
|
|
|
<el-input v-model="copyPartData.partNo" clearable style="width: 120px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
<el-form-item :label="'物料名称'"> |
|
|
|
|
|
<el-input v-model="copyPartData.partDesc" clearable style="width: 120px"></el-input> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
<el-form-item :label="' '"> |
|
|
|
|
|
<el-button type="primary" @click="queryCopyPartList">查询</el-button> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
</el-form> |
|
|
|
|
|
<el-table |
|
|
|
|
|
:height="250" |
|
|
|
|
|
:data="copyPartList" |
|
|
|
|
|
@row-dblclick="getCopyRowData" |
|
|
|
|
|
border |
|
|
|
|
|
style="width: 100%;"> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
v-for="(item,index) in componentPartColumnList" :key="index" |
|
|
|
|
|
:sortable="item.columnSortable" |
|
|
|
|
|
:prop="item.columnProp" |
|
|
|
|
|
:header-align="item.headerAlign" |
|
|
|
|
|
:show-overflow-tooltip="item.showOverflowTooltip" |
|
|
|
|
|
:align="item.align" |
|
|
|
|
|
:fixed="item.fixed==''?false:item.fixed" |
|
|
|
|
|
:min-width="item.columnWidth" |
|
|
|
|
|
:label="item.columnLabel"> |
|
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
<span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span> |
|
|
|
|
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span> |
|
|
|
|
|
</template> |
|
|
|
|
|
</el-table-column> |
|
|
|
|
|
</el-table> |
|
|
|
|
|
<!-- 分页插件 --> |
|
|
|
|
|
<el-pagination |
|
|
|
|
|
@size-change="sizeChangeHandle4" |
|
|
|
|
|
@current-change="currentChangeHandle4" |
|
|
|
|
|
:current-page="pageIndex4" |
|
|
|
|
|
:page-sizes="[20, 50, 100, 200, 500]" |
|
|
|
|
|
:page-size="pageSize4" |
|
|
|
|
|
:total="totalPage4" |
|
|
|
|
|
layout="total, sizes, prev, pager, next, jumper"> |
|
|
|
|
|
</el-pagination> |
|
|
|
|
|
<el-footer style="height:35px;margin-top:10px;text-align:center"> |
|
|
|
|
|
<el-button type="primary" @click="copyPartModelFlag = false">关闭</el-button> |
|
|
|
|
|
</el-footer> |
|
|
|
|
|
</el-dialog> |
|
|
|
|
|
|
|
|
<!-- chooseList模态框 --> |
|
|
<!-- chooseList模态框 --> |
|
|
<ChooseList ref="baseList" @getBaseData="getBaseData"></ChooseList> |
|
|
<ChooseList ref="baseList" @getBaseData="getBaseData"></ChooseList> |
|
|
</div> |
|
|
</div> |
|
|
@ -660,6 +734,12 @@ export default { |
|
|
pageIndex: 1, |
|
|
pageIndex: 1, |
|
|
pageSize: 50, |
|
|
pageSize: 50, |
|
|
totalPage: 0, |
|
|
totalPage: 0, |
|
|
|
|
|
pageIndex2: 1, |
|
|
|
|
|
pageSize2: 20, |
|
|
|
|
|
totalPage2: 0, |
|
|
|
|
|
pageIndex4: 1, |
|
|
|
|
|
pageSize4: 20, |
|
|
|
|
|
totalPage4: 0, |
|
|
selectedDataNum: 0, |
|
|
selectedDataNum: 0, |
|
|
// 条件查询 |
|
|
// 条件查询 |
|
|
searchData: { |
|
|
searchData: { |
|
|
@ -676,6 +756,7 @@ export default { |
|
|
saveHeaderLoading: false, |
|
|
saveHeaderLoading: false, |
|
|
saveDetailLoading: false, |
|
|
saveDetailLoading: false, |
|
|
saveAllLoading: false, |
|
|
saveAllLoading: false, |
|
|
|
|
|
copyLoading: false, |
|
|
// 初始页签 |
|
|
// 初始页签 |
|
|
detailTable: 'routing_detail', |
|
|
detailTable: 'routing_detail', |
|
|
subDetailTable: 'routing_sub_detail', |
|
|
subDetailTable: 'routing_sub_detail', |
|
|
@ -763,6 +844,8 @@ export default { |
|
|
buNo: '', |
|
|
buNo: '', |
|
|
partNo: '', |
|
|
partNo: '', |
|
|
partDesc: '', |
|
|
partDesc: '', |
|
|
|
|
|
page: 1, |
|
|
|
|
|
limit: 10 |
|
|
}, |
|
|
}, |
|
|
operationData: { |
|
|
operationData: { |
|
|
site: this.$store.state.user.site, |
|
|
site: this.$store.state.user.site, |
|
|
@ -800,7 +883,9 @@ export default { |
|
|
}, |
|
|
}, |
|
|
copyRoutingData: { |
|
|
copyRoutingData: { |
|
|
site: '', |
|
|
site: '', |
|
|
|
|
|
buNo: '', |
|
|
partNo: '', |
|
|
partNo: '', |
|
|
|
|
|
partDesc: '', |
|
|
routingRevision: '', |
|
|
routingRevision: '', |
|
|
routingType: '', |
|
|
routingType: '', |
|
|
phaseInDate: '', |
|
|
phaseInDate: '', |
|
|
@ -811,6 +896,7 @@ export default { |
|
|
copyAlternativeData: { |
|
|
copyAlternativeData: { |
|
|
site: '', |
|
|
site: '', |
|
|
partNo: '', |
|
|
partNo: '', |
|
|
|
|
|
partDesc: '', |
|
|
routingRevision: '', |
|
|
routingRevision: '', |
|
|
routingType: '', |
|
|
routingType: '', |
|
|
alternativeNo: '', |
|
|
alternativeNo: '', |
|
|
@ -829,6 +915,15 @@ export default { |
|
|
previousVersion: {}, |
|
|
previousVersion: {}, |
|
|
createBy: '' |
|
|
createBy: '' |
|
|
}, |
|
|
}, |
|
|
|
|
|
copyPartData: { |
|
|
|
|
|
type: '', |
|
|
|
|
|
site: '', |
|
|
|
|
|
buNo: '', |
|
|
|
|
|
partNo: '', |
|
|
|
|
|
partDesc: '', |
|
|
|
|
|
page: 1, |
|
|
|
|
|
limit: 10 |
|
|
|
|
|
}, |
|
|
// ======== 数据列表 ======== |
|
|
// ======== 数据列表 ======== |
|
|
dataList: [], |
|
|
dataList: [], |
|
|
partList: [], |
|
|
partList: [], |
|
|
@ -839,6 +934,7 @@ export default { |
|
|
checkedDetail: [], |
|
|
checkedDetail: [], |
|
|
checkedTool: [], |
|
|
checkedTool: [], |
|
|
alternativeList: [], |
|
|
alternativeList: [], |
|
|
|
|
|
copyPartList: [], |
|
|
// ======== 列表表头 ======== |
|
|
// ======== 列表表头 ======== |
|
|
columnList: [ |
|
|
columnList: [ |
|
|
{ |
|
|
{ |
|
|
@ -1384,6 +1480,68 @@ export default { |
|
|
fixed: '', |
|
|
fixed: '', |
|
|
}, |
|
|
}, |
|
|
], |
|
|
], |
|
|
|
|
|
componentPartColumnList: [ |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'partNo', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '物料编码', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'partDesc', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "left", |
|
|
|
|
|
columnLabel: '物料名称', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'familyName', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '物料分类', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'printUnit', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '计量单位', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'spec', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '规格型号', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'partType', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '零件类型', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
} |
|
|
|
|
|
], |
|
|
// ======== 必填规则 ======== |
|
|
// ======== 必填规则 ======== |
|
|
rules: { |
|
|
rules: { |
|
|
partNo: [ |
|
|
partNo: [ |
|
|
@ -1556,6 +1714,7 @@ export default { |
|
|
copyAlternativeModelFlag: false, |
|
|
copyAlternativeModelFlag: false, |
|
|
headerSaveFlag: false, |
|
|
headerSaveFlag: false, |
|
|
menuId: this.$route.meta.menuId, |
|
|
menuId: this.$route.meta.menuId, |
|
|
|
|
|
copyPartModelFlag: false, |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
@ -1628,6 +1787,149 @@ export default { |
|
|
this.getDataList() |
|
|
this.getDataList() |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* 每页数 |
|
|
|
|
|
* @param val |
|
|
|
|
|
*/ |
|
|
|
|
|
sizeChangeHandle2 (val) { |
|
|
|
|
|
this.pageSize2 = val |
|
|
|
|
|
this.pageIndex2 = 1 |
|
|
|
|
|
this.queryPartList() |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* 当前页 |
|
|
|
|
|
* @param val |
|
|
|
|
|
*/ |
|
|
|
|
|
currentChangeHandle2 (val) { |
|
|
|
|
|
this.pageIndex2 = val |
|
|
|
|
|
this.queryPartList() |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* 每页数 |
|
|
|
|
|
* @param val |
|
|
|
|
|
*/ |
|
|
|
|
|
sizeChangeHandle4 (val) { |
|
|
|
|
|
this.pageSize4 = val |
|
|
|
|
|
this.pageIndex4 = 1 |
|
|
|
|
|
this.queryCopyPartModal() |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* 当前页 |
|
|
|
|
|
* @param val |
|
|
|
|
|
*/ |
|
|
|
|
|
currentChangeHandle4 (val) { |
|
|
|
|
|
this.pageIndex4 = val |
|
|
|
|
|
this.queryCopyPartModal() |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* copy物料列表 |
|
|
|
|
|
*/ |
|
|
|
|
|
queryCopyPartModal () { |
|
|
|
|
|
this.copyPartData.limit = this.pageSize4 |
|
|
|
|
|
this.copyPartData.page = this.pageIndex4 |
|
|
|
|
|
this.copyPartData.site = this.modalData.site |
|
|
|
|
|
this.copyPartData.buNo = this.modalData.buNo |
|
|
|
|
|
// 查询所有物料 |
|
|
|
|
|
queryPartList(this.copyPartData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
this.copyPartList = data.page.list |
|
|
|
|
|
this.pageIndex4 = data.page.currPage |
|
|
|
|
|
this.pageSize4 = data.page.pageSize |
|
|
|
|
|
this.totalPage4 = data.page.totalCount |
|
|
|
|
|
this.copyPartModelFlag = true |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
|
|
confirmButtonText: '确定' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
|
* copy物料查询列表 |
|
|
|
|
|
*/ |
|
|
|
|
|
queryCopyPartList () { |
|
|
|
|
|
this.copyPartData.limit = this.pageSize4 |
|
|
|
|
|
this.copyPartData.page = this.pageIndex4 |
|
|
|
|
|
// 查询所有物料 |
|
|
|
|
|
queryPartList(this.copyPartData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
this.copyPartList = data.page.list |
|
|
|
|
|
this.pageIndex4 = data.page.currPage |
|
|
|
|
|
this.pageSize4 = data.page.pageSize |
|
|
|
|
|
this.totalPage4 = data.page.totalCount |
|
|
|
|
|
} else { |
|
|
|
|
|
this.copyPartList = [] |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// copy物料编码失焦事件 |
|
|
|
|
|
copyPartBlur () { |
|
|
|
|
|
if (this.copyPartData.type === '1') { |
|
|
|
|
|
if (this.copyRoutingData.partNo != null && this.copyRoutingData.partNo !== '') { |
|
|
|
|
|
this.copyPartData.limit = this.pageSize4 |
|
|
|
|
|
this.copyPartData.page = this.pageIndex4 |
|
|
|
|
|
this.copyPartData.partNo = this.copyRoutingData.partNo |
|
|
|
|
|
queryPartList(this.copyPartData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
if (data.page.list.length === 1) { |
|
|
|
|
|
this.copyRoutingData.partDesc = data.page.list[0].partDesc |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$message.warning('该物料不存在!') |
|
|
|
|
|
this.copyRoutingData.partDesc = '' |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
} else { |
|
|
|
|
|
if (this.copyAlternativeData.partNo != null && this.copyAlternativeData.partNo !== '') { |
|
|
|
|
|
this.copyPartData.limit = this.pageSize4 |
|
|
|
|
|
this.copyPartData.page = this.pageIndex4 |
|
|
|
|
|
this.copyPartData.partNo = this.copyAlternativeData.partNo |
|
|
|
|
|
queryPartList(this.copyPartData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
if (data.page.list.length === 1) { |
|
|
|
|
|
this.copyAlternativeData.partDesc = data.page.list[0].partDesc |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$message.warning('该物料不存在!') |
|
|
|
|
|
this.copyAlternativeData.partDesc = '' |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// 双击选择copy物料 |
|
|
|
|
|
getCopyRowData (row) { |
|
|
|
|
|
if (this.copyPartData.type === '1') { |
|
|
|
|
|
this.copyRoutingData.partNo = row.partNo |
|
|
|
|
|
this.copyRoutingData.partDesc = row.partDesc |
|
|
|
|
|
this.copyRoutingTypeChange() |
|
|
|
|
|
} else { |
|
|
|
|
|
this.copyAlternativeData.partNo = row.partNo |
|
|
|
|
|
this.copyAlternativeData.partDesc = row.partDesc |
|
|
|
|
|
} |
|
|
|
|
|
this.copyPartModelFlag = false |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
// copy BOM类型改变 |
|
|
|
|
|
copyRoutingTypeChange () { |
|
|
|
|
|
// 获取物料的routing版本号 |
|
|
|
|
|
getRottingRevision(this.copyRoutingData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
this.copyRoutingData.routingRevision = data.routingRevision |
|
|
|
|
|
} else { |
|
|
|
|
|
this.copyRoutingData.routingRevision = '' |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
// ======== 列表数据操作方法 ======== |
|
|
// ======== 列表数据操作方法 ======== |
|
|
/** |
|
|
/** |
|
|
* 获取数据列表 |
|
|
* 获取数据列表 |
|
|
@ -1728,6 +2030,7 @@ export default { |
|
|
updateBy: this.$store.state.user.name, |
|
|
updateBy: this.$store.state.user.name, |
|
|
printUnit: row.printUnit, |
|
|
printUnit: row.printUnit, |
|
|
printUnitName: row.printUnitName, |
|
|
printUnitName: row.printUnitName, |
|
|
|
|
|
alternativeNo: row.alternativeNo, |
|
|
} |
|
|
} |
|
|
// 查routing明细 |
|
|
// 查routing明细 |
|
|
queryRoutingDetail(this.modalData).then(({data}) => { |
|
|
queryRoutingDetail(this.modalData).then(({data}) => { |
|
|
@ -2102,11 +2405,16 @@ export default { |
|
|
* 查询物料 |
|
|
* 查询物料 |
|
|
*/ |
|
|
*/ |
|
|
queryPartList () { |
|
|
queryPartList () { |
|
|
|
|
|
this.partData.limit = this.pageSize2 |
|
|
|
|
|
this.partData.page = this.pageIndex2 |
|
|
this.partData.site = this.modalData.bu.split('_')[0] |
|
|
this.partData.site = this.modalData.bu.split('_')[0] |
|
|
this.partData.buNo = this.modalData.bu.split('_')[1] |
|
|
this.partData.buNo = this.modalData.bu.split('_')[1] |
|
|
queryPartListRouting(this.partData).then(({data}) => { |
|
|
queryPartListRouting(this.partData).then(({data}) => { |
|
|
if (data && data.code === 0) { |
|
|
if (data && data.code === 0) { |
|
|
this.partList = data.rows |
|
|
|
|
|
|
|
|
this.partList = data.page.list |
|
|
|
|
|
this.pageIndex2 = data.page.currPage |
|
|
|
|
|
this.pageSize2 = data.page.pageSize |
|
|
|
|
|
this.totalPage2 = data.page.totalCount |
|
|
this.partModelFlag = true |
|
|
this.partModelFlag = true |
|
|
} else { |
|
|
} else { |
|
|
this.$alert(data.msg, '错误', { |
|
|
this.$alert(data.msg, '错误', { |
|
|
@ -2118,13 +2426,15 @@ export default { |
|
|
|
|
|
|
|
|
// 物料编码失焦事件 |
|
|
// 物料编码失焦事件 |
|
|
partNoBlur () { |
|
|
partNoBlur () { |
|
|
|
|
|
this.partData.limit = this.pageSize2 |
|
|
|
|
|
this.partData.page = this.pageIndex2 |
|
|
this.partData.partNo = this.modalData.partNo |
|
|
this.partData.partNo = this.modalData.partNo |
|
|
queryPartList(this.partData).then(({data}) => { |
|
|
queryPartList(this.partData).then(({data}) => { |
|
|
if (data && data.code === 0) { |
|
|
if (data && data.code === 0) { |
|
|
if (data.rows.length === 1) { |
|
|
|
|
|
this.modalData.partDesc = data.rows[0].partDesc |
|
|
|
|
|
this.modalData.printUnit = data.rows[0].printUnit |
|
|
|
|
|
this.modalData.printUnitName = data.rows[0].printUnitName |
|
|
|
|
|
|
|
|
if (data.page.list.length === 1) { |
|
|
|
|
|
this.modalData.partDesc = data.page.list[0].partDesc |
|
|
|
|
|
this.modalData.printUnit = data.page.list[0].printUnit |
|
|
|
|
|
this.modalData.printUnitName = data.page.list[0].printUnitName |
|
|
// 获取物料的routing版本号 |
|
|
// 获取物料的routing版本号 |
|
|
getRottingRevision(this.modalData).then(({data}) => { |
|
|
getRottingRevision(this.modalData).then(({data}) => { |
|
|
if (data && data.code === 0) { |
|
|
if (data && data.code === 0) { |
|
|
@ -2443,6 +2753,7 @@ export default { |
|
|
site: this.modalData.site, |
|
|
site: this.modalData.site, |
|
|
buNo: this.modalData.buNo, |
|
|
buNo: this.modalData.buNo, |
|
|
partNo: this.modalData.partNo, |
|
|
partNo: this.modalData.partNo, |
|
|
|
|
|
partDesc: this.modalData.partDesc, |
|
|
routingRevision: this.modalData.routingRevision + 1, |
|
|
routingRevision: this.modalData.routingRevision + 1, |
|
|
routingType: this.modalData.routingType, |
|
|
routingType: this.modalData.routingType, |
|
|
phaseInDate: this.dayjs(new Date()).format('YYYY-MM-DD'), |
|
|
phaseInDate: this.dayjs(new Date()).format('YYYY-MM-DD'), |
|
|
@ -2450,6 +2761,15 @@ export default { |
|
|
previousVersion: {}, |
|
|
previousVersion: {}, |
|
|
createBy: this.$store.state.user.name, |
|
|
createBy: this.$store.state.user.name, |
|
|
} |
|
|
} |
|
|
|
|
|
this.copyPartData = { |
|
|
|
|
|
type: '1', |
|
|
|
|
|
site: this.modalData.site, |
|
|
|
|
|
buNo: this.modalData.buNo, |
|
|
|
|
|
partNo: '', |
|
|
|
|
|
partDesc: '', |
|
|
|
|
|
page: 1, |
|
|
|
|
|
limit: 10 |
|
|
|
|
|
} |
|
|
this.copyRoutingModelFlag = true |
|
|
this.copyRoutingModelFlag = true |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
@ -2470,11 +2790,12 @@ export default { |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
this.copyRoutingData.previousVersion = this.modalData |
|
|
this.copyRoutingData.previousVersion = this.modalData |
|
|
|
|
|
this.copyLoading = true |
|
|
// 新增主表信息 |
|
|
// 新增主表信息 |
|
|
copyRouting(this.copyRoutingData).then(({data}) => { |
|
|
copyRouting(this.copyRoutingData).then(({data}) => { |
|
|
if (data && data.code === 0) { |
|
|
if (data && data.code === 0) { |
|
|
this.modalData.phaseOutDate = data.rows.phaseOutDate |
|
|
|
|
|
this.copyRoutingModelFlag = false |
|
|
this.copyRoutingModelFlag = false |
|
|
|
|
|
this.updateModal(data.rows) |
|
|
this.$message({ |
|
|
this.$message({ |
|
|
message: '操作成功', |
|
|
message: '操作成功', |
|
|
type: 'success', |
|
|
type: 'success', |
|
|
@ -2486,6 +2807,9 @@ export default { |
|
|
confirmButtonText: '确定' |
|
|
confirmButtonText: '确定' |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
|
|
|
this.copyLoading = false |
|
|
|
|
|
}).catch(()=>{ |
|
|
|
|
|
this.copyLoading = false |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
@ -2497,6 +2821,7 @@ export default { |
|
|
site: this.detailData.site, |
|
|
site: this.detailData.site, |
|
|
buNo: this.detailData.buNo, |
|
|
buNo: this.detailData.buNo, |
|
|
partNo: this.detailData.partNo, |
|
|
partNo: this.detailData.partNo, |
|
|
|
|
|
partDesc: this.modalData.partDesc, |
|
|
routingRevision: this.detailData.routingRevision, |
|
|
routingRevision: this.detailData.routingRevision, |
|
|
routingType: this.detailData.routingType, |
|
|
routingType: this.detailData.routingType, |
|
|
alternativeNo: this.detailData.alternativeNo, |
|
|
alternativeNo: this.detailData.alternativeNo, |
|
|
@ -2515,6 +2840,15 @@ export default { |
|
|
previousVersion: {}, |
|
|
previousVersion: {}, |
|
|
createBy: this.$store.state.user.name |
|
|
createBy: this.$store.state.user.name |
|
|
} |
|
|
} |
|
|
|
|
|
this.copyPartData = { |
|
|
|
|
|
type: '2', |
|
|
|
|
|
site: this.detailData.site, |
|
|
|
|
|
buNo: this.detailData.buNo, |
|
|
|
|
|
partNo: '', |
|
|
|
|
|
partDesc: '', |
|
|
|
|
|
page: 1, |
|
|
|
|
|
limit: 10 |
|
|
|
|
|
} |
|
|
this.copyAlternativeModelFlag = true |
|
|
this.copyAlternativeModelFlag = true |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
@ -2543,10 +2877,11 @@ export default { |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
this.copyAlternativeData.previousVersion = this.detailData |
|
|
this.copyAlternativeData.previousVersion = this.detailData |
|
|
|
|
|
this.copyLoading = true |
|
|
copyAlternative(this.copyAlternativeData).then(({data}) => { |
|
|
copyAlternative(this.copyAlternativeData).then(({data}) => { |
|
|
if (data && data.code === 0) { |
|
|
if (data && data.code === 0) { |
|
|
this.detailDataList = data.rows.detailDataList |
|
|
|
|
|
this.copyAlternativeModelFlag = false |
|
|
this.copyAlternativeModelFlag = false |
|
|
|
|
|
this.updateModal(data.rows) |
|
|
this.$message({ |
|
|
this.$message({ |
|
|
message: '操作成功', |
|
|
message: '操作成功', |
|
|
type: 'success', |
|
|
type: 'success', |
|
|
@ -2558,6 +2893,9 @@ export default { |
|
|
confirmButtonText: '确定' |
|
|
confirmButtonText: '确定' |
|
|
}) |
|
|
}) |
|
|
} |
|
|
} |
|
|
|
|
|
this.copyLoading = false |
|
|
|
|
|
}).catch(()=>{ |
|
|
|
|
|
this.copyLoading = false |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|