| | |
| | | |
| | | <script> |
| | | import permision from "@/common/permission.js" |
| | | import loginVue from "../login/login.vue"; |
| | | export default { |
| | | data() { |
| | | return { |
| | |
| | | 'token':uni.getStorageSync('token') |
| | | }, |
| | | success(result) { |
| | | console.log(result); |
| | | uni.vibrateShort(); |
| | | let res = result.data |
| | | if (res.code === 200 && res.data) { |
| | | that.matData = res.data |
| | | that.matnr = '' |
| | | that.matData['batch'] = '' |
| | | uni.navigateTo({ |
| | | url: "matQuery", |
| | | events: { |
| | |
| | | checkMat(mat) { |
| | | var len = this.matList.length |
| | | var add = true |
| | | var date = new Date() |
| | | var today = date.getFullYear() + '/' + (date.getMonth()+1) + '/' + date.getDate() |
| | | for (var i = 0; i < len; i++) { |
| | | if (mat.matnr == this.matList[i].matnr) { |
| | | this.matList[i].anfme += mat.anfme |
| | |
| | | } |
| | | } |
| | | if (add) { |
| | | if(mat.batch === '' || mat.batch === null) { |
| | | mat.batch = today |
| | | } |
| | | this.matList.unshift(mat) |
| | | } |
| | | }, |
| | |
| | | this.count = this.matList[index].anfme |
| | | this.batch = this.matList[index].batch |
| | | this.memo = this.matList[index].memo |
| | | // var maxCount = this.matList[index].maxCount |
| | | // if (maxCount == undefined ) { |
| | | // this.matList[index]["maxCount"] = item.enableQty |
| | | // } |
| | | // this.enableQty = item.enableQty |
| | | // this.count = this.minCount |
| | | // this.maxCount = item.maxCount |
| | | this.rowNum = index |
| | | this.eject() |
| | | }, |