From d90ef2be7ef8b6d96722311b8fe4493ce3d0d59f Mon Sep 17 00:00:00 2001 From: whycq <10027870+whycq@user.noreply.gitee.com> Date: 星期三, 28 十二月 2022 10:36:23 +0800 Subject: [PATCH] # --- pages/basics/pakin.vue | 15 +++++++-------- 1 files changed, 7 insertions(+), 8 deletions(-) diff --git a/pages/basics/pakin.vue b/pages/basics/pakin.vue index 5e167e3..6e4a377 100644 --- a/pages/basics/pakin.vue +++ b/pages/basics/pakin.vue @@ -139,6 +139,7 @@ <script> import permision from "@/common/permission.js" +import loginVue from "../login/login.vue"; export default { data() { return { @@ -347,12 +348,12 @@ '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: { @@ -390,6 +391,8 @@ 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 @@ -398,6 +401,9 @@ } } if (add) { + if(mat.batch === '' || mat.batch === null) { + mat.batch = today + } this.matList.unshift(mat) } }, @@ -434,13 +440,6 @@ 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() }, -- Gitblit v1.9.1