Compare commits

..

No commits in common. "26772a324a0e571052bd435ea64a279fab6368fd" and "d8424e1752f0d39cc001c9256d4617647b790d9d" have entirely different histories.

3 changed files with 39 additions and 51 deletions

View File

@ -4,7 +4,7 @@
* @Author: fzq * @Author: fzq
* @Date: 2022-03-05 17:45:46 * @Date: 2022-03-05 17:45:46
* @LastEditors: fzq * @LastEditors: fzq
* @LastEditTime: 2022-03-16 16:11:55 * @LastEditTime: 2022-03-07 09:19:34
--> -->
<template> <template>
<!-- <el-dialog <!-- <el-dialog
@ -40,7 +40,7 @@
</template> </template>
<script> <script>
import { updateSubstrate } from '@/api/report-manage/report' import { updateSubstrate, listSubstrate } from '@/api/report-manage/report'
export default { export default {
props: { props: {
@ -55,18 +55,15 @@ export default {
return { return {
visible: false, visible: false,
dataForm: { dataForm: {
// substrateCode: '', id: '',
// location: '', substrateCode: '',
// storeTime: '', location: '',
// substrateStatus: '', storeTime: '',
// code: '', substrateStatus: '',
// storageBoxId: '', code: '',
// storageCode: '', storageBoxId: '',
// interCode: '', storageCode: '',
// id: '', interCode: ''
// current: 1,
// size: 10,
// locationStorageSubID: ''
}, },
list: { list: {
id: '', id: '',
@ -110,25 +107,22 @@ export default {
// }) // })
// }) // })
// }, // },
init(data) { init(id) {
// this.dataForm.id = id || '' // this.dataForm.id = id || ''
// console.log(this.$route.query) this.dataForm.storageBoxId = this.$route.query.id
// this.dataForm.id = this.$route.query.id this.dataForm.storageCode = this.$route.query.code
// this.dataForm.substrateCode = this.$route.query.substrateCode
// this.dataForm.locationStorageSubID = this.$route.query.locationStorageSubID
this.dataForm = data
this.visible = true this.visible = true
// console.log(this.dataForm) // console.log(this.dataForm)
// listSubstrate(this.dataForm).then(res => { listSubstrate(this.dataForm).then(res => {
// // console.log(res) console.log(res.data[0])
// this.dataForm.id = res.data[0].id this.dataForm.id = res.data[0].id
// this.dataForm.location = res.data[0].location this.dataForm.location = res.data[0].location
// this.dataForm.storeTime = res.data[0].storeTime this.dataForm.storeTime = res.data[0].storeTime
// this.dataForm.substrateCode = res.data[0].substrateCode this.dataForm.substrateCode = res.data[0].substrateCode
// this.dataForm.substrateStatus = res.data[0].substrateStatus this.dataForm.substrateStatus = res.data[0].substrateStatus
// this.dataForm.interCode = res.data[0].interCode this.dataForm.interCode = res.data[0].interCode
// // console.log(this.dataForm) // console.log(this.dataForm)
// }) })
}, },
// //
dataFormSubmit() { dataFormSubmit() {
@ -138,10 +132,10 @@ export default {
'substrateStatus': this.dataForm.substrateStatus, 'substrateStatus': this.dataForm.substrateStatus,
'storeTime': this.dataForm.storeTime, 'storeTime': this.dataForm.storeTime,
'id': this.dataForm.id, 'id': this.dataForm.id,
'code': this.dataForm.substrateCode, 'substrateCode': this.dataForm.substrateCode,
'location': this.dataForm.location, 'location': this.dataForm.location,
'interCode': this.dataForm.interCode, 'interCode': this.dataForm.interCode,
'storageBoxFid': this.dataForm.storageBoxFid 'storageBoxId': this.dataForm.storageBoxId
} }
console.log(data) console.log(data)
updateSubstrate(data).then(res => { updateSubstrate(data).then(res => {

View File

@ -4,7 +4,7 @@
* @Author: fzq * @Author: fzq
* @Date: 2022-03-05 14:35:07 * @Date: 2022-03-05 14:35:07
* @LastEditors: fzq * @LastEditors: fzq
* @LastEditTime: 2022-03-16 16:13:58 * @LastEditTime: 2022-03-05 16:44:43
--> -->
<template> <template>
<span> <span>
@ -26,8 +26,7 @@ export default {
name: 'viewSubstrate', name: 'viewSubstrate',
query: { query: {
id: this.injectData.id, id: this.injectData.id,
code: this.injectData.code, code: this.injectData.code
locationStorageSubID: this.injectData.locationStorageSubID
} }
}) })
} }

View File

@ -4,7 +4,7 @@
* @Author: fzq * @Author: fzq
* @Date: 2022-03-05 15:55:45 * @Date: 2022-03-05 15:55:45
* @LastEditors: fzq * @LastEditors: fzq
* @LastEditTime: 2022-03-16 16:09:15 * @LastEditTime: 2022-03-11 11:08:53
--> -->
<template> <template>
<div class="app-container"> <div class="app-container">
@ -29,7 +29,7 @@
@clickBtn="handleClick" @clickBtn="handleClick"
/> />
</base-table> </base-table>
<edit-substrate v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getList" /> <edit-substrate v-if="addOrUpdateVisible" :id="listQuery.id" ref="addOrUpdate" @refreshDataList="getList" />
</div> </div>
</template> </template>
@ -104,7 +104,7 @@ export default {
return { return {
addOrUpdateVisible: false, addOrUpdateVisible: false,
num: '', num: '',
storageCode: this.$t('module.basicData.visual.storageCode'), storageCode: this.$t('module.basicData.visual.TipsBefore'),
tableBtn, tableBtn,
trueWidth: 200, trueWidth: 200,
tableProps, tableProps,
@ -113,17 +113,14 @@ export default {
listQuery: { listQuery: {
current: 1, current: 1,
size: 10, size: 10,
locationStorageSubID: '' storageBoxCode: '',
// storageBoxCode: '', storageBoxId: ''
// storageBoxId: '' }
},
count: 0
} }
}, },
created() { created() {
this.listQuery.storageBoxCode = this.$route.query.code this.listQuery.storageBoxCode = this.$route.query.code
// this.listQuery.storageBoxId = this.$route.query.id this.listQuery.storageBoxId = this.$route.query.id
this.listQuery.locationStorageSubID = this.$route.query.locationStorageSubID
this.getList() this.getList()
}, },
methods: { methods: {
@ -134,7 +131,7 @@ export default {
cancelButtonText: this.$t('module.basicData.visual.cancelButtonText'), cancelButtonText: this.$t('module.basicData.visual.cancelButtonText'),
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
// console.log(raw.data) // console.log(raw.data)
deleSubstrate(raw.data).then(response => { deleSubstrate(raw.data).then(response => {
this.$message({ this.$message({
message: this.$t('module.basicData.visual.success'), message: this.$t('module.basicData.visual.success'),
@ -147,18 +144,16 @@ export default {
}) })
}).catch(() => {}) }).catch(() => {})
} else { } else {
// this.count = raw.data._pageIndex this.addNew(raw.data.id)
// console.log(this.count)
this.addNew(raw.data)
} }
}, },
getList() { getList() {
this.listLoading = true this.listLoading = true
this.num = this.listQuery.storageBoxCode this.num = this.listQuery.storageBoxCode
this.listQuery.code = this.$route.query.code this.listQuery.code = this.$route.query.code
// console.log(this.listQuery) console.log(this.listQuery)
listSubstrate(this.listQuery).then(response => { listSubstrate(this.listQuery).then(response => {
// console.log(response) console.log(response)
if (response.data) { if (response.data) {
this.list = response.data this.list = response.data
console.log(this.list) console.log(this.list)