|
|
@ -89,8 +89,8 @@ |
|
|
<el-dialog :close-on-click-modal="false" :before-close="closeModalX" v-drag :visible.sync="modalFlag" width="1110px"> |
|
|
<el-dialog :close-on-click-modal="false" :before-close="closeModalX" v-drag :visible.sync="modalFlag" width="1110px"> |
|
|
<el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 5px"> |
|
|
<el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 5px"> |
|
|
<el-form-item prop="partNo" :rules="rules.partNo"> |
|
|
<el-form-item prop="partNo" :rules="rules.partNo"> |
|
|
<span v-if="!modalDisableFlag" slot="label" @click="queryPartList()"><a herf="#">物料编码</a></span> |
|
|
|
|
|
<span v-if="modalDisableFlag" slot="label">物料编码</span> |
|
|
|
|
|
|
|
|
<span v-if="!modalDisableFlag" slot="label" @click="queryPartList"><a herf="#">物料编码</a></span> |
|
|
|
|
|
<span v-else slot="label">物料编码</span> |
|
|
<el-input v-model="modalData.partNo" :disabled="modalDisableFlag" style="width: 221px"></el-input> |
|
|
<el-input v-model="modalData.partNo" :disabled="modalDisableFlag" style="width: 221px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="'物料名称'" prop="partDesc" :rules="rules.partDesc"> |
|
|
<el-form-item :label="'物料名称'" prop="partDesc" :rules="rules.partDesc"> |
|
|
@ -100,7 +100,7 @@ |
|
|
<el-input v-model="modalData.printUnitName" disabled style="width: 221px"></el-input> |
|
|
<el-input v-model="modalData.printUnitName" disabled style="width: 221px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="'制造类型'" prop="bomType" :rules="rules.bomType"> |
|
|
<el-form-item :label="'制造类型'" prop="bomType" :rules="rules.bomType"> |
|
|
<el-select v-model="modalData.bomType" @change="bomTypeChange" :disabled="modalDisableFlag" style="width: 221px"> |
|
|
|
|
|
|
|
|
<el-select v-model="modalData.bomType" :disabled="modalDisableFlag" style="width: 221px"> <!-- @change="bomTypeChange" --> |
|
|
<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="Purchase" value="Purchase"></el-option> |
|
|
<el-option label="Purchase" value="Purchase"></el-option> |
|
|
@ -114,7 +114,7 @@ |
|
|
<el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 7px;margin-top: -5px;"> |
|
|
<el-form-item label="生效日期" prop="effPhaseInDate" :rules="rules.effPhaseInDate"> |
|
|
<el-form-item label="生效日期" prop="effPhaseInDate" :rules="rules.effPhaseInDate"> |
|
|
<el-date-picker |
|
|
<el-date-picker |
|
|
:readonly="this.detailData.partNo !== ''" |
|
|
|
|
|
|
|
|
:readonly="detailData.partNo != ''" |
|
|
style="width: 221px" |
|
|
style="width: 221px" |
|
|
v-model="modalData.effPhaseInDate" |
|
|
v-model="modalData.effPhaseInDate" |
|
|
type="date" |
|
|
type="date" |
|
|
@ -135,14 +135,14 @@ |
|
|
</el-date-picker> |
|
|
</el-date-picker> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="'BOM版本号'" prop="engChgLevel" :rules="rules.engChgLevel"> |
|
|
<el-form-item :label="'BOM版本号'" prop="engChgLevel" :rules="rules.engChgLevel"> |
|
|
<el-input v-model="modalData.engChgLevel" type="number" disabled style="width: 221px"></el-input> |
|
|
|
|
|
|
|
|
<el-input v-model="modalData.engChgLevel" :disabled="modalDisableFlag" type="number" style="width: 221px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="'工程版本号'"> |
|
|
<el-form-item :label="'工程版本号'"> |
|
|
<el-input v-model="modalData.engRevision" style="width: 221px"></el-input> |
|
|
<el-input v-model="modalData.engRevision" style="width: 221px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item> |
|
|
<el-form-item> |
|
|
<el-button v-if="modalData.flag === '1'" :loading="saveHeaderLoading" type="primary" @click="saveBomHeader()" style="margin-top: 23px;width: 120px">保存</el-button> |
|
|
|
|
|
<el-button v-else type="primary" @click="copyBomRevision()" style="margin-top: 23px;width: 120px">Copy</el-button> |
|
|
|
|
|
|
|
|
<el-button v-if="modalData.flag === '1'" :loading="saveHeaderLoading" type="primary" @click="saveBomHeader" style="margin-top: 23px;width: 120px">保存</el-button> |
|
|
|
|
|
<el-button v-else type="primary" @click="copyBomRevision" style="margin-top: 23px;width: 120px">Copy</el-button> |
|
|
</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;"> |
|
|
@ -155,17 +155,18 @@ |
|
|
<el-tab-pane label="Product Structure" name="bom_detail"> |
|
|
<el-tab-pane label="Product Structure" name="bom_detail"> |
|
|
<el-form label-position="top" style="margin-top: -10px"> |
|
|
<el-form label-position="top" style="margin-top: -10px"> |
|
|
<el-form-item> |
|
|
<el-form-item> |
|
|
<el-button type="primary" @click="saveBomDetail()" style="margin-left: 7px">新增</el-button> |
|
|
|
|
|
<el-button type="primary" @click="deleteBomDetail()">删除</el-button> |
|
|
|
|
|
<el-button type="primary" @click="updateBomDetail()">编辑</el-button> |
|
|
|
|
|
|
|
|
<el-button type="primary" @click="saveBomDetail" style="margin-left: 7px">新增</el-button> |
|
|
|
|
|
<el-button type="primary" @click="deleteBomDetail">删除</el-button> |
|
|
|
|
|
<el-button type="primary" @click="updateBomDetail">编辑</el-button> |
|
|
<el-button v-if="modalData.flag === '2'" type="primary" @click="copyBomAlternative()">Copy</el-button> |
|
|
<el-button v-if="modalData.flag === '2'" type="primary" @click="copyBomAlternative()">Copy</el-button> |
|
|
<el-button v-if="detailData.status === 'Tentative' || detailData.status === 'Obsolete'" type="primary" @click="updateStatusToBuildable()">Buildable</el-button> |
|
|
|
|
|
<el-button v-if="detailData.status === 'Buildable' && (modalData.effPhaseOutDate == null || modalData.effPhaseOutDate === '')" type="primary" @click="updateStatusToObsolete()">Obsolete</el-button> |
|
|
|
|
|
|
|
|
<el-button v-if="detailData.status === 'Tentative' || detailData.status === 'Obsolete'" type="primary" @click="updateStatusToBuildable">Build</el-button> |
|
|
|
|
|
<el-button v-if="detailData.status === 'Buildable' && (modalData.effPhaseOutDate == null || modalData.effPhaseOutDate === '')" type="primary" @click="updateStatusToObsolete">Retire</el-button> |
|
|
|
|
|
<el-button v-if="modalData.flag === '2' && detailData.officialFlag !== 'Y'" type="primary" @click="toBecomeOfficialBom">转正式Bom</el-button> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-form :inline="true" label-position="top" :model="detailData" :rules="rules" style="margin-left: 7px"> |
|
|
<el-form :inline="true" label-position="top" :model="detailData" :rules="rules" style="margin-left: 7px"> |
|
|
<el-form-item :label="'替代编码'"> |
|
|
<el-form-item :label="'替代编码'"> |
|
|
<el-select v-model="detailData.alternativeNo" @change="alternativeChange()" style="width: 221px"> |
|
|
|
|
|
|
|
|
<el-select v-model="detailData.alternativeNo" @change="alternativeChange" style="width: 221px"> |
|
|
<el-option |
|
|
<el-option |
|
|
v-for = "(i, index) in detailDataList" |
|
|
v-for = "(i, index) in detailDataList" |
|
|
:key = "index" |
|
|
:key = "index" |
|
|
@ -178,11 +179,6 @@ |
|
|
<el-input v-model="detailData.alternativeDescription" readonly style="width: 221px"></el-input> |
|
|
<el-input v-model="detailData.alternativeDescription" readonly style="width: 221px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="'状态'"> |
|
|
<el-form-item :label="'状态'"> |
|
|
<!-- <el-select v-model="detailData.status" disabled style="width: 221px">--> |
|
|
|
|
|
<!-- <el-option label="暂定" value="Tentative"></el-option>--> |
|
|
|
|
|
<!-- <el-option label="创建" value="Buildable"></el-option>--> |
|
|
|
|
|
<!-- <el-option label="销毁" value="Obsolete"></el-option>--> |
|
|
|
|
|
<!-- </el-select>--> |
|
|
|
|
|
<el-input v-model="detailData.status" readonly style="width: 221px"></el-input> |
|
|
<el-input v-model="detailData.status" readonly style="width: 221px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item :label="'最小订单数'"> |
|
|
<el-form-item :label="'最小订单数'"> |
|
|
@ -201,8 +197,8 @@ |
|
|
<el-tab-pane label="Components" name="bom_sub_detail"> |
|
|
<el-tab-pane label="Components" name="bom_sub_detail"> |
|
|
<el-form label-position="top" style="margin-top: 5px"> |
|
|
<el-form label-position="top" style="margin-top: 5px"> |
|
|
<el-form-item> |
|
|
<el-form-item> |
|
|
<el-button type="primary" @click="saveComponentModal()" style="margin-left: 7px">新增</el-button> |
|
|
|
|
|
<el-button type="primary" @click="deleteComponentPart()">删除</el-button> |
|
|
|
|
|
|
|
|
<el-button type="primary" @click="saveComponentModal" style="margin-left: 7px">新增</el-button> |
|
|
|
|
|
<el-button type="primary" @click="deleteComponentPart">删除</el-button> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-table |
|
|
<el-table |
|
|
@ -329,6 +325,12 @@ |
|
|
<el-form-item :label="'物料名称'"> |
|
|
<el-form-item :label="'物料名称'"> |
|
|
<el-input v-model="componentPartData.partDesc" clearable style="width: 120px"></el-input> |
|
|
<el-input v-model="componentPartData.partDesc" clearable style="width: 120px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
|
|
|
<el-form-item :label="'正式物料'"> |
|
|
|
|
|
<el-select v-model="componentPartData.status" clearable style="width: 120px"> |
|
|
|
|
|
<el-option label="临时物料" value="N"></el-option> |
|
|
|
|
|
<el-option label="正式物料" value="Y"></el-option> |
|
|
|
|
|
</el-select> |
|
|
|
|
|
</el-form-item> |
|
|
<el-form-item :label="' '"> |
|
|
<el-form-item :label="' '"> |
|
|
<el-button type="primary" @click="queryComponentPartList()">查询</el-button> |
|
|
<el-button type="primary" @click="queryComponentPartList()">查询</el-button> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
@ -367,7 +369,7 @@ |
|
|
<el-input class="inlineNumber numInput" v-model="componentData.lineSequence" type="number" style="width: 49px"></el-input> |
|
|
<el-input class="inlineNumber numInput" v-model="componentData.lineSequence" type="number" style="width: 49px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item prop="componentPart" :rules="componentRules.componentPart"> |
|
|
<el-form-item prop="componentPart" :rules="componentRules.componentPart"> |
|
|
<span v-if="!componentDisableFlag" slot="label" @click="queryComponentPartList()"><a herf="#">子物料编码</a></span> |
|
|
|
|
|
|
|
|
<span v-if="!componentDisableFlag" slot="label" @click="queryComponentPartList"><a herf="#">子物料编码</a></span> |
|
|
<span v-if="componentDisableFlag" slot="label">子物料编码</span> |
|
|
<span v-if="componentDisableFlag" slot="label">子物料编码</span> |
|
|
<el-input v-model="componentData.componentPart" :disabled="componentDisableFlag" style="width: 175px"></el-input> |
|
|
<el-input v-model="componentData.componentPart" :disabled="componentDisableFlag" style="width: 175px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
@ -389,8 +391,8 @@ |
|
|
<el-input class="inlineNumber numInput" v-model="componentData.shrinkageFactor" @input="handleInputB(componentData.shrinkageFactor)" type="number" style="width: 80px"></el-input> |
|
|
<el-input class="inlineNumber numInput" v-model="componentData.shrinkageFactor" @input="handleInputB(componentData.shrinkageFactor)" type="number" style="width: 80px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item> |
|
|
<el-form-item> |
|
|
<span slot="label" @click="queryOperationList()"><a>工序</a></span> |
|
|
|
|
|
<el-input v-model="componentData.operationName" style="width: 110px"></el-input> |
|
|
|
|
|
|
|
|
<span slot="label" @click="queryOperationList"><a>工序</a></span> |
|
|
|
|
|
<el-input v-model="componentData.operationId" style="width: 110px"></el-input> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
<el-form-item> |
|
|
<el-form-item> |
|
|
<span slot="label" @click="getBaseList(117)"><a herf="#">发料库位</a></span> |
|
|
<span slot="label" @click="getBaseList(117)"><a herf="#">发料库位</a></span> |
|
|
@ -410,7 +412,7 @@ |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-form> |
|
|
</el-form> |
|
|
<el-footer style="height:35px;margin-top:65px;text-align:center"> |
|
|
<el-footer style="height:35px;margin-top:65px;text-align:center"> |
|
|
<el-button :loading="saveComponentLoading" type="primary" @click="componentDataSave()">保存</el-button> |
|
|
|
|
|
|
|
|
<el-button :loading="saveComponentLoading" type="primary" @click="componentDataSave">保存</el-button> |
|
|
<el-button type="primary" @click="componentSaveModal = false">关闭</el-button> |
|
|
<el-button type="primary" @click="componentSaveModal = false">关闭</el-button> |
|
|
</el-footer> |
|
|
</el-footer> |
|
|
</el-dialog> |
|
|
</el-dialog> |
|
|
@ -636,7 +638,8 @@ import { |
|
|
getBomEngChgLevel, // 获取物料的bom版本号 |
|
|
getBomEngChgLevel, // 获取物料的bom版本号 |
|
|
getComponentLineSequence, // 获取子料的序号 |
|
|
getComponentLineSequence, // 获取子料的序号 |
|
|
copyBom, // 复制bom |
|
|
copyBom, // 复制bom |
|
|
copyAlternative, // 复制alternative |
|
|
|
|
|
|
|
|
copyAlternative, // 复制alternative, |
|
|
|
|
|
toBecomeOfficialBom, // 转正式Bom |
|
|
} from '@/api/part/bomManagement.js' |
|
|
} from '@/api/part/bomManagement.js' |
|
|
import ChooseList from '@/views/modules/common/Chooselist' |
|
|
import ChooseList from '@/views/modules/common/Chooselist' |
|
|
import dayjs from "dayjs"; |
|
|
import dayjs from "dayjs"; |
|
|
@ -716,6 +719,7 @@ export default { |
|
|
updateBy: '', |
|
|
updateBy: '', |
|
|
printUnit: '', |
|
|
printUnit: '', |
|
|
printUnitName: '', |
|
|
printUnitName: '', |
|
|
|
|
|
officialFlag: '' |
|
|
}, |
|
|
}, |
|
|
detailData: { |
|
|
detailData: { |
|
|
site: this.$store.state.user.site, |
|
|
site: this.$store.state.user.site, |
|
|
@ -731,7 +735,8 @@ export default { |
|
|
createDate: '', |
|
|
createDate: '', |
|
|
createBy: '', |
|
|
createBy: '', |
|
|
updateDate: '', |
|
|
updateDate: '', |
|
|
updateBy: '' |
|
|
|
|
|
|
|
|
updateBy: '', |
|
|
|
|
|
officialFlag: 'N' |
|
|
}, |
|
|
}, |
|
|
componentData: { |
|
|
componentData: { |
|
|
flag: '', |
|
|
flag: '', |
|
|
@ -749,7 +754,7 @@ export default { |
|
|
issueType: '', |
|
|
issueType: '', |
|
|
shrinkageFactor: '', |
|
|
shrinkageFactor: '', |
|
|
lineItemNo: '', |
|
|
lineItemNo: '', |
|
|
operationName: '', |
|
|
|
|
|
|
|
|
operationId: '', |
|
|
issueToLoc: '', |
|
|
issueToLoc: '', |
|
|
issueToLocName: '', |
|
|
issueToLocName: '', |
|
|
noteText: '', |
|
|
noteText: '', |
|
|
@ -768,6 +773,8 @@ export default { |
|
|
site: this.$store.state.user.site, |
|
|
site: this.$store.state.user.site, |
|
|
partNo: '', |
|
|
partNo: '', |
|
|
partDesc: '', |
|
|
partDesc: '', |
|
|
|
|
|
status: '', |
|
|
|
|
|
bomDetail: {} |
|
|
}, |
|
|
}, |
|
|
saveDetailData: { |
|
|
saveDetailData: { |
|
|
flag: '', |
|
|
flag: '', |
|
|
@ -784,7 +791,8 @@ export default { |
|
|
createDate: '', |
|
|
createDate: '', |
|
|
createBy: '', |
|
|
createBy: '', |
|
|
updateDate: '', |
|
|
updateDate: '', |
|
|
updateBy: '' |
|
|
|
|
|
|
|
|
updateBy: '', |
|
|
|
|
|
officialFlag: '' |
|
|
}, |
|
|
}, |
|
|
operationData: { |
|
|
operationData: { |
|
|
site: this.$store.state.user.site, |
|
|
site: this.$store.state.user.site, |
|
|
@ -799,7 +807,8 @@ export default { |
|
|
effPhaseInDate: '', |
|
|
effPhaseInDate: '', |
|
|
effPhaseOutDate: '', |
|
|
effPhaseOutDate: '', |
|
|
previousVersion: {}, |
|
|
previousVersion: {}, |
|
|
createBy: '' |
|
|
|
|
|
|
|
|
createBy: '', |
|
|
|
|
|
officialFlag: '' |
|
|
}, |
|
|
}, |
|
|
copyAlternativeData: { |
|
|
copyAlternativeData: { |
|
|
site: '', |
|
|
site: '', |
|
|
@ -813,7 +822,8 @@ export default { |
|
|
detailNoteText: '', |
|
|
detailNoteText: '', |
|
|
status: '', |
|
|
status: '', |
|
|
previousVersion: {}, |
|
|
previousVersion: {}, |
|
|
createBy: '' |
|
|
|
|
|
|
|
|
createBy: '', |
|
|
|
|
|
officialFlag: '' |
|
|
}, |
|
|
}, |
|
|
// ======== 数据列表 ======== |
|
|
// ======== 数据列表 ======== |
|
|
dataList: [], |
|
|
dataList: [], |
|
|
@ -1294,7 +1304,7 @@ export default { |
|
|
serialNumber: '104002Table2OperationDesc', |
|
|
serialNumber: '104002Table2OperationDesc', |
|
|
tableId: '104002Table2', |
|
|
tableId: '104002Table2', |
|
|
tableName: 'BOM子物料表', |
|
|
tableName: 'BOM子物料表', |
|
|
columnProp: 'operationName', |
|
|
|
|
|
|
|
|
columnProp: 'operationId', |
|
|
headerAlign: 'center', |
|
|
headerAlign: 'center', |
|
|
align: 'center', |
|
|
align: 'center', |
|
|
columnLabel: '工序', |
|
|
columnLabel: '工序', |
|
|
@ -1344,6 +1354,18 @@ export default { |
|
|
}, |
|
|
}, |
|
|
], |
|
|
], |
|
|
operationDetailList: [ |
|
|
operationDetailList: [ |
|
|
|
|
|
{ |
|
|
|
|
|
columnProp: 'operationNo', |
|
|
|
|
|
headerAlign: "center", |
|
|
|
|
|
align: "center", |
|
|
|
|
|
columnLabel: '工序编码', |
|
|
|
|
|
columnHidden: false, |
|
|
|
|
|
columnImage: false, |
|
|
|
|
|
columnSortable: false, |
|
|
|
|
|
sortLv: 0, |
|
|
|
|
|
status: true, |
|
|
|
|
|
fixed: '', |
|
|
|
|
|
}, |
|
|
{ |
|
|
{ |
|
|
columnProp: 'operationName', |
|
|
columnProp: 'operationName', |
|
|
headerAlign: "center", |
|
|
headerAlign: "center", |
|
|
@ -1654,6 +1676,7 @@ export default { |
|
|
createBy: this.$store.state.user.name, |
|
|
createBy: this.$store.state.user.name, |
|
|
printUnit: '', |
|
|
printUnit: '', |
|
|
printUnitName: '', |
|
|
printUnitName: '', |
|
|
|
|
|
officialFlag: 'N' |
|
|
} |
|
|
} |
|
|
this.detailData = { |
|
|
this.detailData = { |
|
|
site: this.$store.state.user.site, |
|
|
site: this.$store.state.user.site, |
|
|
@ -1669,8 +1692,10 @@ export default { |
|
|
createDate: '', |
|
|
createDate: '', |
|
|
createBy: this.$store.state.user.name, |
|
|
createBy: this.$store.state.user.name, |
|
|
updateDate: '', |
|
|
updateDate: '', |
|
|
updateBy: this.$store.state.user.name |
|
|
|
|
|
|
|
|
updateBy: this.$store.state.user.name, |
|
|
|
|
|
officialFlag: 'N' |
|
|
} |
|
|
} |
|
|
|
|
|
this.detailDataList = [] |
|
|
this.subDetailList = [] |
|
|
this.subDetailList = [] |
|
|
this.modalDisableFlag = false |
|
|
this.modalDisableFlag = false |
|
|
this.modalFlag = true |
|
|
this.modalFlag = true |
|
|
@ -1695,6 +1720,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, |
|
|
|
|
|
officialFlag: row.officialFlag |
|
|
} |
|
|
} |
|
|
// 查bom明细 |
|
|
// 查bom明细 |
|
|
queryBomDetail(this.modalData).then(({data}) => { |
|
|
queryBomDetail(this.modalData).then(({data}) => { |
|
|
@ -1741,6 +1767,7 @@ export default { |
|
|
status: 'Tentative', |
|
|
status: 'Tentative', |
|
|
createDate: '', |
|
|
createDate: '', |
|
|
createBy: this.$store.state.user.name, |
|
|
createBy: this.$store.state.user.name, |
|
|
|
|
|
officialFlag: 'N' |
|
|
} |
|
|
} |
|
|
// 查询bom主信息 |
|
|
// 查询bom主信息 |
|
|
queryBomHeader(this.modalData).then(({data}) => { |
|
|
queryBomHeader(this.modalData).then(({data}) => { |
|
|
@ -1787,6 +1814,7 @@ export default { |
|
|
detailNoteText: this.detailData.detailNoteText, |
|
|
detailNoteText: this.detailData.detailNoteText, |
|
|
status: this.detailData.status, |
|
|
status: this.detailData.status, |
|
|
updateBy: this.$store.state.user.name, |
|
|
updateBy: this.$store.state.user.name, |
|
|
|
|
|
officialFlag: this.detailData.officialFlag |
|
|
} |
|
|
} |
|
|
// 查询bom主信息 |
|
|
// 查询bom主信息 |
|
|
queryBomHeader(this.modalData).then(({data}) => { |
|
|
queryBomHeader(this.modalData).then(({data}) => { |
|
|
@ -1832,7 +1860,7 @@ export default { |
|
|
issueType: 'Reserve and Backflush', |
|
|
issueType: 'Reserve and Backflush', |
|
|
shrinkageFactor: 0, |
|
|
shrinkageFactor: 0, |
|
|
lineItemNo: '', |
|
|
lineItemNo: '', |
|
|
operationName: '', |
|
|
|
|
|
|
|
|
operationId: '', |
|
|
issueToLoc: '', |
|
|
issueToLoc: '', |
|
|
issueToLocName: '', |
|
|
issueToLocName: '', |
|
|
noteText: '', |
|
|
noteText: '', |
|
|
@ -1876,7 +1904,7 @@ export default { |
|
|
issueType: row.issueType, |
|
|
issueType: row.issueType, |
|
|
shrinkageFactor: row.shrinkageFactor, |
|
|
shrinkageFactor: row.shrinkageFactor, |
|
|
lineItemNo: row.lineItemNo, |
|
|
lineItemNo: row.lineItemNo, |
|
|
operationName: row.operationName, |
|
|
|
|
|
|
|
|
operationId: row.operationId, |
|
|
issueToLoc: row.issueToLoc, |
|
|
issueToLoc: row.issueToLoc, |
|
|
issueToLocName: row.issueToLocName, |
|
|
issueToLocName: row.issueToLocName, |
|
|
noteText: row.noteText, |
|
|
noteText: row.noteText, |
|
|
@ -1909,10 +1937,6 @@ export default { |
|
|
this.$message.warning('请选择生效日期!') |
|
|
this.$message.warning('请选择生效日期!') |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
// if (this.modalData.effPhaseOutDate === '' || this.modalData.effPhaseOutDate == null) { |
|
|
|
|
|
// this.$message.warning('请选择失效日期!') |
|
|
|
|
|
// return |
|
|
|
|
|
// } |
|
|
|
|
|
if (this.modalData.engChgLevel === '' || this.modalData.engChgLevel == null) { |
|
|
if (this.modalData.engChgLevel === '' || this.modalData.engChgLevel == null) { |
|
|
this.$message.warning('请填写BOM版本号!') |
|
|
this.$message.warning('请填写BOM版本号!') |
|
|
return |
|
|
return |
|
|
@ -1937,6 +1961,7 @@ export default { |
|
|
engRevision: this.modalData.engRevision, |
|
|
engRevision: this.modalData.engRevision, |
|
|
typeFlag: this.modalData.typeFlag, |
|
|
typeFlag: this.modalData.typeFlag, |
|
|
netWeight: this.modalData.netWeight, |
|
|
netWeight: this.modalData.netWeight, |
|
|
|
|
|
officialFlag: this.modalData.officialFlag, |
|
|
alternativeNo: this.detailData.alternativeNo, |
|
|
alternativeNo: this.detailData.alternativeNo, |
|
|
alternativeDescription: this.detailData.alternativeDescription, |
|
|
alternativeDescription: this.detailData.alternativeDescription, |
|
|
minLotQty: this.detailData.minLotQty, |
|
|
minLotQty: this.detailData.minLotQty, |
|
|
@ -2124,17 +2149,18 @@ export default { |
|
|
this.modalData.partDesc = row.partDesc |
|
|
this.modalData.partDesc = row.partDesc |
|
|
this.modalData.printUnit = row.printUnit |
|
|
this.modalData.printUnit = row.printUnit |
|
|
this.modalData.printUnitName = row.printUnitName |
|
|
this.modalData.printUnitName = row.printUnitName |
|
|
// 获取物料的bom版本号 |
|
|
|
|
|
getBomEngChgLevel(this.modalData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
this.modalData.engChgLevel = data.engChgLevel |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
|
|
confirmButtonText: '确定' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
this.partModelFlag = false |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
// // 获取物料的bom版本号 |
|
|
|
|
|
// getBomEngChgLevel(this.modalData).then(({data}) => { |
|
|
|
|
|
// if (data && data.code === 0) { |
|
|
|
|
|
// this.modalData.engChgLevel = data.engChgLevel |
|
|
|
|
|
// } else { |
|
|
|
|
|
// this.$alert(data.msg, '错误', { |
|
|
|
|
|
// confirmButtonText: '确定' |
|
|
|
|
|
// }) |
|
|
|
|
|
// } |
|
|
|
|
|
// this.partModelFlag = false |
|
|
|
|
|
// }) |
|
|
|
|
|
this.partModelFlag = false |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
// bom类型改变 |
|
|
// bom类型改变 |
|
|
@ -2156,9 +2182,10 @@ export default { |
|
|
* @param row |
|
|
* @param row |
|
|
*/ |
|
|
*/ |
|
|
getRowOperationData (row) { |
|
|
getRowOperationData (row) { |
|
|
this.componentData.operationName = row.operationName |
|
|
|
|
|
|
|
|
this.componentData.operationId = row.operationId |
|
|
this.operationModelFlag = false |
|
|
this.operationModelFlag = false |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
getComponentRowData (row) { |
|
|
getComponentRowData (row) { |
|
|
this.componentData.componentPart = row.partNo |
|
|
this.componentData.componentPart = row.partNo |
|
|
this.componentData.componentPartDesc = row.partDesc |
|
|
this.componentData.componentPartDesc = row.partDesc |
|
|
@ -2166,10 +2193,12 @@ export default { |
|
|
this.componentData.printUnitName = row.printUnitName |
|
|
this.componentData.printUnitName = row.printUnitName |
|
|
this.componentPartModelFlag = false |
|
|
this.componentPartModelFlag = false |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 物料列表 |
|
|
* 物料列表 |
|
|
*/ |
|
|
*/ |
|
|
queryComponentPartList () { |
|
|
queryComponentPartList () { |
|
|
|
|
|
this.componentPartData.bomDetail = this.detailData |
|
|
// 查询所有物料 |
|
|
// 查询所有物料 |
|
|
queryPartList(this.componentPartData).then(({data}) => { |
|
|
queryPartList(this.componentPartData).then(({data}) => { |
|
|
if (data && data.code === 0) { |
|
|
if (data && data.code === 0) { |
|
|
@ -2401,6 +2430,7 @@ export default { |
|
|
engRevision: data.rows.modalData.engRevision, |
|
|
engRevision: data.rows.modalData.engRevision, |
|
|
typeFlag: data.rows.modalData.typeFlag, |
|
|
typeFlag: data.rows.modalData.typeFlag, |
|
|
netWeight: data.rows.modalData.netWeight, |
|
|
netWeight: data.rows.modalData.netWeight, |
|
|
|
|
|
officialFlag: data.rows.modalData.officialFlag |
|
|
} |
|
|
} |
|
|
this.detailDataList = data.rows.detailDataList |
|
|
this.detailDataList = data.rows.detailDataList |
|
|
this.detailData = data.rows.detailData |
|
|
this.detailData = data.rows.detailData |
|
|
@ -2432,7 +2462,8 @@ export default { |
|
|
effPhaseInDate: this.dayjs(new Date()).format('YYYY-MM-DD'), |
|
|
effPhaseInDate: this.dayjs(new Date()).format('YYYY-MM-DD'), |
|
|
effPhaseOutDate: '', |
|
|
effPhaseOutDate: '', |
|
|
previousVersion: {}, |
|
|
previousVersion: {}, |
|
|
createBy: this.$store.state.user.name |
|
|
|
|
|
|
|
|
createBy: this.$store.state.user.name, |
|
|
|
|
|
officialFlag: 'N' |
|
|
} |
|
|
} |
|
|
this.copyBomModelFlag = true |
|
|
this.copyBomModelFlag = true |
|
|
}, |
|
|
}, |
|
|
@ -2485,6 +2516,7 @@ export default { |
|
|
defaultFlag: this.detailData.defaultFlag, |
|
|
defaultFlag: this.detailData.defaultFlag, |
|
|
detailNoteText: this.detailData.detailNoteText, |
|
|
detailNoteText: this.detailData.detailNoteText, |
|
|
status: 'Tentative', |
|
|
status: 'Tentative', |
|
|
|
|
|
officialFlag: 'N', |
|
|
previousVersion: {}, |
|
|
previousVersion: {}, |
|
|
createBy: this.$store.state.user.name |
|
|
createBy: this.$store.state.user.name |
|
|
} |
|
|
} |
|
|
@ -2518,6 +2550,7 @@ export default { |
|
|
this.copyAlternativeData.previousVersion = this.detailData |
|
|
this.copyAlternativeData.previousVersion = this.detailData |
|
|
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.$message({ |
|
|
this.$message({ |
|
|
message: '操作成功', |
|
|
message: '操作成功', |
|
|
@ -2721,7 +2754,23 @@ export default { |
|
|
}) |
|
|
}) |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// 临时Bom转为正式Bom |
|
|
|
|
|
toBecomeOfficialBom () { |
|
|
|
|
|
toBecomeOfficialBom(this.detailData).then(({data}) => { |
|
|
|
|
|
if (data && data.code === 0) { |
|
|
|
|
|
this.$message({ |
|
|
|
|
|
message: '操作成功', |
|
|
|
|
|
type: 'success', |
|
|
|
|
|
duration: 1500, |
|
|
|
|
|
onClose: () => {} |
|
|
|
|
|
}) |
|
|
|
|
|
} else { |
|
|
|
|
|
this.$alert(data.msg, '错误', { |
|
|
|
|
|
confirmButtonText: '确定' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
// ======= 正则校验 ======= |
|
|
// ======= 正则校验 ======= |
|
|
handleInput (value, type) { |
|
|
handleInput (value, type) { |
|
|
|