|
|
@ -132,14 +132,16 @@ |
|
|
|
v-if="isAddOrEdit" |
|
|
|
:isAddOrEdit="isAddOrEdit" |
|
|
|
:item="item" |
|
|
|
:planList="planList" |
|
|
|
|
|
|
|
:articleList="articleList" |
|
|
|
:maxCoverPeriodTypeArray="maxCoverPeriodTypeArray" |
|
|
|
:minCoverPeriodTypeArray="minCoverPeriodTypeArray" |
|
|
|
:mainResourceList="mainResourceList" |
|
|
|
:secondaryResourceList="secondaryResourceList" |
|
|
|
@setIsAddOrEdit="setIsAddOrEdit" |
|
|
|
/> |
|
|
|
|
|
|
|
<Upload |
|
|
|
v-model="importDialogVisible" |
|
|
|
@editCallBack="completeCallBack" /> |
|
|
|
<Upload v-if="importDialogVisible" @editCallBack="completeCallBack" /> |
|
|
|
|
|
|
|
</div> |
|
|
|
</template> |
|
|
@ -148,7 +150,7 @@ import AddOrEdit from "./addOrEdit.vue"; |
|
|
|
import Upload from "./upload.vue"; |
|
|
|
import { ListMixin } from "@/mixins/newListMixin"; |
|
|
|
import { queryTableData, getPlantList } from "@/server/factoryModel/materialResourceMaintenance/inventoryLevels"; |
|
|
|
import { deleteHanle,getArtIdList } from "@/server/factoryModel/materialResourceMaintenance/artStockResource"; |
|
|
|
import { deleteHanle,getArtIdList, getMainResourceList, getSecondaryResourceList, } from "@/server/factoryModel/materialResourceMaintenance/artStockResource"; |
|
|
|
|
|
|
|
|
|
|
|
export default { |
|
|
@ -181,28 +183,29 @@ export default { |
|
|
|
articleList:[], // 物料列表 |
|
|
|
minCoverPeriodTypeArray:[], |
|
|
|
maxCoverPeriodTypeArray:[], |
|
|
|
completeStatusList:[] |
|
|
|
completeStatusList:[], |
|
|
|
mainResourceList:[], |
|
|
|
secondaryResourceList:[], |
|
|
|
|
|
|
|
}; |
|
|
|
} |
|
|
|
}, |
|
|
|
created(){ |
|
|
|
this.getStanderData() |
|
|
|
}, |
|
|
|
mounted(){ |
|
|
|
this.getList(); |
|
|
|
this.$nextTick(() => { |
|
|
|
this.tableHeight = this.calculationTableHeight( |
|
|
|
this.$refs.tableRef, |
|
|
|
120 |
|
|
|
); |
|
|
|
}) |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
// 上传回调 |
|
|
|
completeCallBack() { |
|
|
|
this.importDialogVisible = false |
|
|
|
}, |
|
|
|
|
|
|
|
// 物料列表 |
|
|
|
getArticleList(){ |
|
|
|
getArtIdList().then(({data=[]})=>{ |
|
|
|
this.articleList=data; |
|
|
|
}) |
|
|
|
}, |
|
|
|
// 工厂列表 |
|
|
|
getPlantList(){ |
|
|
|
getPlantList().then(({data=[]})=>{ |
|
|
|
this.planList=data; |
|
|
|
}) |
|
|
|
}, |
|
|
|
// 搜索按钮操作 |
|
|
|
handleQuery() { |
|
|
|
this.getList(); |
|
|
@ -230,6 +233,18 @@ export default { |
|
|
|
}, |
|
|
|
|
|
|
|
getStanderData(){ |
|
|
|
getMainResourceList().then(({ data = [] }) => { |
|
|
|
this.mainResourceList = data; |
|
|
|
}); |
|
|
|
getSecondaryResourceList().then(({ data = [] }) => { |
|
|
|
this.secondaryResourceList = data; |
|
|
|
}); |
|
|
|
getArtIdList().then(({data=[]})=>{ |
|
|
|
this.articleList=data; |
|
|
|
}) |
|
|
|
getPlantList().then(({data=[]})=>{ |
|
|
|
this.planList=data; |
|
|
|
}) |
|
|
|
this.getStanderOne({ statid: 'AP_ArticleStockLevel-MinCoverPeriodType' }).then((res) => { |
|
|
|
this.minCoverPeriodTypeArray = res.data |
|
|
|
}) |
|
|
@ -238,25 +253,9 @@ export default { |
|
|
|
}) |
|
|
|
this.getStanderOne({ statid: 'AP_ArticleStockLevel-CompleteStatus' }).then((res) => { |
|
|
|
this.completeStatusList = res.data |
|
|
|
console.log(this.completeStatusList); |
|
|
|
}) |
|
|
|
} |
|
|
|
}, |
|
|
|
created(){ |
|
|
|
this.getPlantList(); |
|
|
|
this.getArticleList(); |
|
|
|
this.getStanderData(); |
|
|
|
}, |
|
|
|
mounted(){ |
|
|
|
this.getList(); |
|
|
|
this.$nextTick(() => { |
|
|
|
this.tableHeight = this.calculationTableHeight( |
|
|
|
this.$refs.tableRef, |
|
|
|
120 |
|
|
|
); |
|
|
|
}); |
|
|
|
|
|
|
|
} |
|
|
|
}; |
|
|
|
</script> |
|
|
|
<style lang="less" scoped> |
|
|
|