Browse Source

2025-01-20

优化
master
fengyuan_yang 12 months ago
parent
commit
492b687f5b
  1. 7
      src/api/changeManagement/changeManagement.js
  2. 168
      src/views/modules/changeManagement/changeRecord.vue
  3. 176
      src/views/modules/changeManagement/changeRequest.vue
  4. 69
      src/views/modules/part/bomSearch3.vue

7
src/api/changeManagement/changeManagement.js

@ -228,6 +228,13 @@ export const getBuBySite = data => createAPI(`/plm/changeManagement/getBuBySite`
*/ */
export const getNodeAuthorityForCheck = data => createAPI(`/plm/changeManagement/getNodeAuthorityForCheck`,'post',data) export const getNodeAuthorityForCheck = data => createAPI(`/plm/changeManagement/getNodeAuthorityForCheck`,'post',data)
/**
* 根据视图查物料计划
* @param data
* @returns {*}
*/
export const choosePartNoList = data => createAPI(`/plm/changeManagement/choosePartNoList`,'post',data)

168
src/views/modules/changeManagement/changeRecord.vue

@ -1015,6 +1015,65 @@
</el-footer> </el-footer>
</el-dialog> </el-dialog>
<!-- 物料模态框 -->
<el-dialog title="物料清单" :close-on-click-modal="false" v-drag :visible.sync="partModelFlag" width="940px">
<div class="rq">
<el-form :inline="true" label-position="top" :model="partData">
<el-form-item :label="'IFS料号'">
<el-input v-model="partData.finalPartNo" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="'物料编码'">
<el-input v-model="partData.testPartNo" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="'客户料号'">
<el-input v-model="partData.customerPartNo" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="'物料名称'">
<el-input v-model="partData.partDesc" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="' '">
<el-button type="primary" @click="queryPartList()">查询</el-button>
</el-form-item>
</el-form>
<el-table
:height="300"
:data="partList"
@row-dblclick="getRowData"
border
style="width: 100%;">
<el-table-column
v-for="(item,index) in partColumnList" :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
style="margin-top: 5px"
@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>
<el-footer style="height:35px;margin-top: 10px;text-align:center">
<el-button type="primary" @click="partModelFlag=false">关闭</el-button>
</el-footer>
</el-dialog>
<ChooseList ref="baseList" @getBaseData="getBaseData"></ChooseList> <ChooseList ref="baseList" @getBaseData="getBaseData"></ChooseList>
<!-- 上传文件的modal --> <!-- 上传文件的modal -->
@ -1049,6 +1108,7 @@
getApprovalList, // getApprovalList, //
getBuBySite, // sitebu getBuBySite, // sitebu
technicalSpecificationSearch2, // technicalSpecificationSearch2, //
choosePartNoList, //
} from '@/api/changeManagement/changeManagement.js' } from '@/api/changeManagement/changeManagement.js'
import ChooseList from '@/views/modules/common/Chooselist' import ChooseList from '@/views/modules/common/Chooselist'
import {verifyData} from "@/api/chooselist/chooselist.js" import {verifyData} from "@/api/chooselist/chooselist.js"
@ -1210,6 +1270,9 @@
pageIndex: 1, pageIndex: 1,
pageSize: 50, pageSize: 50,
totalPage: 0, totalPage: 0,
pageIndex2: 1,
pageSize2: 20,
totalPage2: 0,
// //
searchData: { searchData: {
site: this.$store.state.user.site, site: this.$store.state.user.site,
@ -1364,6 +1427,16 @@
updateBy: '', updateBy: '',
chooseCSItemList: [] chooseCSItemList: []
}, },
partData: {
site: '',
buNo: '',
finalPartNo: '',
testPartNo: '',
customerPartNo: '',
partDesc: '',
page: 1,
limit: 10
},
// ======== ======== // ======== ========
dataList: [], dataList: [],
dataList2: [], dataList2: [],
@ -1382,6 +1455,7 @@
itemCSList: [], itemCSList: [],
chooseFileList: [], chooseFileList: [],
approvalList: [], approvalList: [],
partList: [],
// ======== ======== // ======== ========
columnList: [ columnList: [
{ {
@ -2362,6 +2436,58 @@
columnWidth: 300 columnWidth: 300
}, },
], ],
partColumnList: [
{
columnProp: 'finalPartNo',
headerAlign: "center",
align: "left",
columnLabel: 'IFS料号',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 120
},
{
columnProp: 'testPartNo',
headerAlign: "center",
align: "left",
columnLabel: '物料编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 120
},
{
columnProp: 'customerPartNo',
headerAlign: "center",
align: "left",
columnLabel: '客户料号',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 120
},
{
columnProp: 'partDesc',
headerAlign: "center",
align: "left",
columnLabel: '物料名称',
columnHidden: false,
columnImage: false,
status: true,
fixed: '',
columnWidth: 200
},
],
// ======== ======== // ======== ========
rules: { rules: {
applicantId: [ applicantId: [
@ -2520,6 +2646,7 @@
authFileDownLoad: false, authFileDownLoad: false,
authFileRemove: false, authFileRemove: false,
authFilePreview: false, authFilePreview: false,
partModelFlag: false,
} }
}, },
@ -2811,11 +2938,50 @@
}, },
choosePartNo (row) { choosePartNo (row) {
this.partData.site = row.site
this.partData.buNo = row.buNo
this.tempPartRow = row this.tempPartRow = row
if (this.tempPartRow.newPartNo == null) { if (this.tempPartRow.newPartNo == null) {
this.tempPartRow.newPartNo = '' this.tempPartRow.newPartNo = ''
} }
this.getBaseList(133)
this.queryPartList()
//this.getBaseList(133)
},
//
queryPartList () {
this.partData.limit = this.pageSize2
this.partData.page = this.pageIndex2
choosePartNoList(this.partData).then(({data}) => {
if (data && data.code === 0) {
this.partList = data.page.list
this.pageIndex2 = data.page.currPage
this.pageSize2 = data.page.pageSize
this.totalPage2 = data.page.totalCount
this.partModelFlag = true
} else {
this.partList = []
}
})
},
//
getRowData (row) {
this.$set(this.tempPartRow,'newPartNo', row.testPartNo)
this.partModelFlag = false
},
//
sizeChangeHandle2 (val) {
this.pageSize2 = val
this.pageIndex2 = 1
this.queryPartList()
},
//
currentChangeHandle2 (val) {
this.pageIndex2 = val
this.queryPartList()
}, },
chooseExecutor (row) { chooseExecutor (row) {

176
src/views/modules/changeManagement/changeRequest.vue

@ -867,6 +867,65 @@
</el-footer> </el-footer>
</el-dialog> </el-dialog>
<!-- 物料模态框 -->
<el-dialog title="物料清单" :close-on-click-modal="false" v-drag :visible.sync="partModelFlag" width="940px">
<div class="rq">
<el-form :inline="true" label-position="top" :model="partData">
<el-form-item :label="'IFS料号'">
<el-input v-model="partData.finalPartNo" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="'物料编码'">
<el-input v-model="partData.testPartNo" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="'客户料号'">
<el-input v-model="partData.customerPartNo" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="'物料名称'">
<el-input v-model="partData.partDesc" clearable style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="' '">
<el-button type="primary" @click="queryPartList()">查询</el-button>
</el-form-item>
</el-form>
<el-table
:height="300"
:data="partList"
@row-dblclick="getRowData"
border
style="width: 100%;">
<el-table-column
v-for="(item,index) in partColumnList" :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
style="margin-top: 5px"
@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>
<el-footer style="height:35px;margin-top: 10px;text-align:center">
<el-button type="primary" @click="partModelFlag=false">关闭</el-button>
</el-footer>
</el-dialog>
<ChooseList ref="baseList" @getBaseData="getBaseData"></ChooseList> <ChooseList ref="baseList" @getBaseData="getBaseData"></ChooseList>
<!-- 上传文件的modal --> <!-- 上传文件的modal -->
@ -891,6 +950,7 @@
getItemList, // getItemList, //
countersignatureSave, // countersignatureSave, //
getBuBySite, // sitebu getBuBySite, // sitebu
choosePartNoList, //
} from "@/api/changeManagement/changeManagement.js" } from "@/api/changeManagement/changeManagement.js"
import {getChooselistData, verifyData} from "@/api/chooselist/chooselist.js" import {getChooselistData, verifyData} from "@/api/chooselist/chooselist.js"
import ChooseList from '@/views/modules/common/Chooselist' import ChooseList from '@/views/modules/common/Chooselist'
@ -943,6 +1003,9 @@
pageIndex: 1, pageIndex: 1,
pageSize: 50, pageSize: 50,
totalPage: 0, totalPage: 0,
pageIndex2: 1,
pageSize2: 20,
totalPage2: 0,
activeName: 'basicInformation', activeName: 'basicInformation',
tempPartRow: {}, tempPartRow: {},
tempExecutorRow: {}, tempExecutorRow: {},
@ -1091,6 +1154,16 @@
fileRemark: '', fileRemark: '',
folder: '' folder: ''
}, },
partData: {
site: '',
buNo: '',
finalPartNo: '',
testPartNo: '',
customerPartNo: '',
partDesc: '',
page: 1,
limit: 10
},
// ======== ======== // ======== ========
dataList: [], dataList: [],
dataList2: [], dataList2: [],
@ -1105,6 +1178,7 @@
chooseItemList: [], chooseItemList: [],
chooseItemList2: [], chooseItemList2: [],
chooseCSItemList: [], chooseCSItemList: [],
partList: [],
// ======== ======== // ======== ========
columnList: [ columnList: [
{ {
@ -1790,6 +1864,58 @@
columnWidth: 150 columnWidth: 150
}, },
], ],
partColumnList: [
{
columnProp: 'finalPartNo',
headerAlign: "center",
align: "left",
columnLabel: 'IFS料号',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 120
},
{
columnProp: 'testPartNo',
headerAlign: "center",
align: "left",
columnLabel: '物料编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 120
},
{
columnProp: 'customerPartNo',
headerAlign: "center",
align: "left",
columnLabel: '客户料号',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 120
},
{
columnProp: 'partDesc',
headerAlign: "center",
align: "left",
columnLabel: '物料名称',
columnHidden: false,
columnImage: false,
status: true,
fixed: '',
columnWidth: 200
},
],
// ======== ======== // ======== ========
rules: { rules: {
applicantId: [ applicantId: [
@ -1936,7 +2062,8 @@
chooseModelFlag2: false, chooseModelFlag2: false,
chooseCSModelFlag: false, chooseCSModelFlag: false,
CountersignatureFlag: false, CountersignatureFlag: false,
addDetailModal: false
addDetailModal: false,
partModelFlag: false,
} }
}, },
@ -2009,18 +2136,51 @@
}, },
choosePartNo (row) { choosePartNo (row) {
this.partData.site = row.site
this.partData.buNo = row.buNo
this.tempPartRow = row this.tempPartRow = row
// if (!this.tempPartRow.newPartNo) {
// this.tempPartRow.newPartNo = ''
// }
this.getBaseList(133)
this.queryPartList()
//this.getBaseList(133)
},
//
queryPartList () {
this.partData.limit = this.pageSize2
this.partData.page = this.pageIndex2
choosePartNoList(this.partData).then(({data}) => {
if (data && data.code === 0) {
this.partList = data.page.list
this.pageIndex2 = data.page.currPage
this.pageSize2 = data.page.pageSize
this.totalPage2 = data.page.totalCount
this.partModelFlag = true
} else {
this.partList = []
}
})
},
//
getRowData (row) {
this.$set(this.tempPartRow,'newPartNo', row.testPartNo)
this.partModelFlag = false
},
//
sizeChangeHandle2 (val) {
this.pageSize2 = val
this.pageIndex2 = 1
this.queryPartList()
},
//
currentChangeHandle2 (val) {
this.pageIndex2 = val
this.queryPartList()
}, },
chooseExecutor (row) { chooseExecutor (row) {
this.tempExecutorRow = row this.tempExecutorRow = row
// if (this.tempExecutorRow.executor == null) {
// this.tempExecutorRow.executor = ''
// }
this.getBaseList(103, 7) this.getBaseList(103, 7)
}, },

69
src/views/modules/part/bomSearch3.vue

@ -645,13 +645,7 @@ export default {
fixed: '', fixed: '',
columnWidth: 150 columnWidth: 150
}, },
]
// ======== ========
// ======== ========
// ======== ========
],
} }
}, },
@ -670,29 +664,21 @@ export default {
// js // js
methods: { methods: {
// ======== ======== // ======== ========
/**
* 每页数
* @param val
*/
//
sizeChangeHandle (val) { sizeChangeHandle (val) {
this.pageSize = val this.pageSize = val
this.pageIndex = 1 this.pageIndex = 1
this.getDataList() this.getDataList()
}, },
/**
* 当前页
* @param val
*/
//
currentChangeHandle (val) { currentChangeHandle (val) {
this.pageIndex = val this.pageIndex = val
this.getDataList() this.getDataList()
}, },
// ======== ======== // ======== ========
/**
* 获取数据列表
*/
//
getDataList () { getDataList () {
this.searchData.limit = this.pageSize this.searchData.limit = this.pageSize
this.searchData.page = this.pageIndex this.searchData.page = this.pageIndex
@ -718,20 +704,13 @@ export default {
}) })
}, },
/**
* 单机选中信息
* @param row
*/
//
headerClickRow (row) { headerClickRow (row) {
this.$refs.bomHeaderTable.toggleRowSelection(row) this.$refs.bomHeaderTable.toggleRowSelection(row)
this.headerCurrentRow = JSON.parse(JSON.stringify(row)) this.headerCurrentRow = JSON.parse(JSON.stringify(row))
}, },
/**
* 树节点单机事件
* @param e
* @param node
*/
//
handleNodeClick (e, node) { handleNodeClick (e, node) {
this.alternativeData = { this.alternativeData = {
site: e.site, site: e.site,
@ -755,21 +734,13 @@ export default {
}) })
}, },
// ======== ======== // ======== ========
/**
* 列表表格选择替换
* @param tab
* @param event
*/
//
tabClick (tab, event) { tabClick (tab, event) {
// //
this.refreshCurrentTabTable() this.refreshCurrentTabTable()
}, },
/**
* 当前值发生变化的时候修改
* @param row
* @param oldRow
*/
//
changeCurrentRow (row, oldRow) { changeCurrentRow (row, oldRow) {
// //
if (row) { if (row) {
@ -793,9 +764,7 @@ export default {
} }
}, },
/**
* 刷新页签的table数据
*/
// table
refreshCurrentTabTable () { refreshCurrentTabTable () {
if (this.activeTable === 'GraphicalStructure') { if (this.activeTable === 'GraphicalStructure') {
// bom // bom
@ -803,9 +772,7 @@ export default {
} }
}, },
/**
* 获取bom替代树形
*/
// bom
getAlternativeTree () { getAlternativeTree () {
getAlternativeTree(this.headerCurrentRow).then(({data}) => { getAlternativeTree(this.headerCurrentRow).then(({data}) => {
if (data && data.code === 0) { if (data && data.code === 0) {
@ -817,11 +784,7 @@ export default {
}, },
// ======== chooseList ======== // ======== chooseList ========
/**
* 获取基础数据列表S
* @param val
* @param type
*/
// S
getBaseList (val, type) { getBaseList (val, type) {
this.tagNo = val this.tagNo = val
this.$nextTick(() => { this.$nextTick(() => {
@ -832,10 +795,8 @@ export default {
this.$refs.baseList.init(val, strVal) this.$refs.baseList.init(val, strVal)
}) })
}, },
/**
* 列表方法的回调
* @param val
*/
//
getBaseData (val) { getBaseData (val) {
if (this.tagNo === 117) { if (this.tagNo === 117) {
this.componentData.issueToLoc = val.location_id this.componentData.issueToLoc = val.location_id
@ -844,9 +805,7 @@ export default {
}, },
// ======== ======== // ======== ========
/**
* 导出excel
*/
// excel
async createExportData () { async createExportData () {
this.searchData.limit = -1 this.searchData.limit = -1
this.searchData.page = 1 this.searchData.page = 1

Loading…
Cancel
Save