From 130a6f0e125a29223131cd8749203a7826d8cf86 Mon Sep 17 00:00:00 2001
From: zjj <3272660260@qq.com>
Date: 星期五, 27 十二月 2024 14:19:21 +0800
Subject: [PATCH] #
---
pages/home/home.vue | 13 +-
pages/order/orderList.vue | 34 ++++++
pages/order/orderPakin2.vue | 132 +++++++++++++++-----------
pages/order/orderDetlList.vue | 42 ++++++++
pages/mat/matList.vue | 1
pages/stock/stockCheck.vue | 67 ++++++++----
6 files changed, 200 insertions(+), 89 deletions(-)
diff --git a/pages/home/home.vue b/pages/home/home.vue
index 1470972..12f5269 100644
--- a/pages/home/home.vue
+++ b/pages/home/home.vue
@@ -58,6 +58,12 @@
color: 'orange',
cuIcon: 'order',
url: '/AGV/AGVUnbind'
+ },{
+ title: '鐩樼偣',
+ name: 'stockCheck',
+ color: 'red',
+ cuIcon: 'post',
+ url: '/stock/stockCheck'
},
// {
// title: '缁勬墭涓婃灦',
@@ -95,12 +101,7 @@
// url: '/stock/stockQuery'
// },
// {
- // title: '鐩樼偣',
- // name: 'stockCheck',
- // color: 'red',
- // cuIcon: 'post',
- // url: '/stock/stockCheck'
- // },
+
// {
// title: '鍟嗗搧鎵撳嵃',
// name: 'matList',
diff --git a/pages/mat/matList.vue b/pages/mat/matList.vue
index c4470ee..0412155 100644
--- a/pages/mat/matList.vue
+++ b/pages/mat/matList.vue
@@ -75,6 +75,7 @@
},
methods: {
search() {
+ console.log("1")
},
showTag(parentId) {
let that = this
diff --git a/pages/order/orderDetlList.vue b/pages/order/orderDetlList.vue
index 91e66f3..85b849d 100644
--- a/pages/order/orderDetlList.vue
+++ b/pages/order/orderDetlList.vue
@@ -1,5 +1,9 @@
<template>
<view>
+ <!-- 鎼滅储妗� -->
+ <view class="search-bar">
+ <uni-search-bar v-model="condition" placeholder=" 鎵爜 / 杈撳叆" bgColor="#EEEEEE" @input="search" />
+ </view>
<view class="card" v-show="item.enableQty >0" v-for="item in menuList" @click="chose(item)">
<view class="tag-item">鍗曟嵁鍙凤細 {{item.orderNo}}</view>
<view class="tag-item">鐗╂枡鐮侊細 {{item.matnr}}</view>
@@ -16,7 +20,8 @@
export default {
data() {
return {
- data:'',
+ data:'',
+ condition:'',
menuList: [],
order:'',
baseUrl: '',
@@ -33,9 +38,42 @@
},
onShow() {
let that = this
-
+ this.baseUrl = uni.getStorageSync('baseUrl');
+ this.token = uni.getStorageSync('token');
+ that.getOrderNoList(that.order)
},
methods: {
+ search(){
+ let that = this
+ uni.request({
+ url: that.baseUrl + '/orderDetl/search/pda/auth',
+ data: {
+ condition: that.condition,
+ order: that.order.orderNo
+ },
+ // method:"GET",
+ header: {
+ 'token':uni.getStorageSync('token'),
+ },
+ success(result) {
+ console.log(result);
+ var res = result.data
+ if (res.code === 200 ) {
+ that.menuList = res.data
+ // that.save()
+ } else if (res.code == 403) {
+ uni.showToast({title: res.msg, icon: "none", position: 'top'})
+ setTimeout(() => {
+ uni.reLaunch({
+ url: '../login/login'
+ });
+ }, 1000);
+ } else {
+ uni.showToast({title: res.msg, icon: "none",position: 'top'})
+ }
+ }
+ });
+ },
getOrderNoList(order) {
let that = this
uni.request({
diff --git a/pages/order/orderList.vue b/pages/order/orderList.vue
index 264da1d..d123abf 100644
--- a/pages/order/orderList.vue
+++ b/pages/order/orderList.vue
@@ -2,7 +2,7 @@
<view>
<!-- 鎼滅储妗� -->
<view class="search-bar">
- <uni-search-bar placeholder=" 鎵爜 / 杈撳叆" bgColor="#EEEEEE" @confirm="search" />
+ <uni-search-bar v-model="condition" placeholder=" 鎵爜 / 杈撳叆" bgColor="#EEEEEE" @confirm="search" />
</view>
<view>
<view class="tag-list" v-for="(item,i) in matList" :key="i" @click="toPrint(item)">
@@ -27,6 +27,7 @@
return {
tagList: [],
matList: [],
+ condition: '',
reload: false,
curr:1,
tag: '鍒嗙被',
@@ -41,7 +42,8 @@
contentnomore: '娌℃湁鏇村'
},
// 褰撳墠tagId
- tagIdNow: 1
+ tagIdNow: 1,
+
}
},
onReachBottom() {
@@ -66,6 +68,34 @@
},
methods: {
search() {
+ let that = this
+ uni.request({
+ url: that.baseUrl + '/order/search/pda/auth',
+ data: {
+ condition: that.condition
+ },
+ method:"GET",
+ header: {
+ 'token':uni.getStorageSync('token'),
+ },
+ success(result) {
+ console.log(result);
+ var res = result.data
+ if (res.code === 200 ) {
+ that.matList = res.data
+ // that.save()
+ } else if (res.code == 403) {
+ uni.showToast({title: res.msg, icon: "none", position: 'top'})
+ setTimeout(() => {
+ uni.reLaunch({
+ url: '../login/login'
+ });
+ }, 1000);
+ } else {
+ uni.showToast({title: res.msg, icon: "none",position: 'top'})
+ }
+ }
+ });
},
showTag(parentId) {
let that = this
diff --git a/pages/order/orderPakin2.vue b/pages/order/orderPakin2.vue
index fa138ab..1849506 100644
--- a/pages/order/orderPakin2.vue
+++ b/pages/order/orderPakin2.vue
@@ -13,15 +13,15 @@
<input type="text" placeholder=" 鎵爜 / 杈撳叆" v-model="barcode" :focus="barcodeFocus"
@input="barcodeInput()">
</view>
- <!-- <view class="item">
+ <view class="item">
<view class="code-decs">鐗╂枡鐮�:</view>
<input type="text" placeholder=" 鎵爜 / 杈撳叆" v-model="matnr" :focus="matFocus" @input="findMat()">
- <view class="item-right">
+ <!-- <view class="item-right">
<button></button>
<text style="text-align: right;color: #409EFF;" @click="selectMat()">鎻愬彇+</text>
<uni-icons type="right" color="#c1c1c1"></uni-icons>
- </view>
- </view> -->
+ </view> -->
+ </view>
</view>
<view class="mat-list-title">
鍟嗗搧鍒楄〃
@@ -62,6 +62,10 @@
<view class="list-left-item">
<view class="desc">鏁伴噺锛�</view>
<view class="left-item">{{item.anfme}}</view>
+ </view>
+ <view class="list-left-item">
+ <view class="desc">鐘舵�侊細</view>
+ <view class="left-item">{{item.review}}</view>
</view>
</view>
<view class="list-right">
@@ -241,57 +245,66 @@
let that = this
let m = that.matnr.split(";")
let matnr1 = m[0].slice(3)
- uni.request({
- url: that.baseUrl + '/mat/auth',
- data: {
- matnr: matnr1
- },
- header: {
- 'token': uni.getStorageSync('token')
- },
- success(result) {
- result = result.data
- if (result.code === 200 && result.data) {
- that.matData = result.data
- that.matnr = ''
- that.matData['batch'] = ''
- uni.navigateTo({
- url: "../mat/matSelected",
- // 閫氳繃eventChannel鍚戣鎵撳紑椤甸潰浼犻�佹暟鎹�
- success: function(res) {
- res.eventChannel.emit('mat', {
- data: result.data
- })
- },
- // 涓烘寚瀹氫簨浠舵坊鍔犱竴涓洃鍚櫒锛岃幏鍙栬鎵撳紑椤甸潰浼犻�佸埌褰撳墠椤甸潰鐨勬暟鎹�
- events: {
- matList: function(data) {
- that.checkMat(data.data)
- that.focuss()
- },
- },
- });
- } else if (result.code == 403) {
- uni.showToast({
- title: result.msg,
- icon: "none",
- position: 'top'
- })
- setTimeout(() => {
- uni.reLaunch({
- url: '../login/login'
- });
- }, 1000);
- } else {
- uni.showToast({
- title: result.msg,
- icon: "none",
- position: 'top'
- })
- }
-
+ for(var i = 0;i<that.dataList.length;i++){
+ if(that.dataList[i].matnr === matnr1){
+ that.dataList[i].review = "宸插鏍�"
}
- });
+
+ }
+ setTimeout(() => {
+ this.matnr = '';
+ }, 100);
+ // uni.request({
+ // url: that.baseUrl + '/mat/auth',
+ // data: {
+ // matnr: matnr1
+ // },
+ // header: {
+ // 'token': uni.getStorageSync('token')
+ // },
+ // success(result) {
+ // result = result.data
+ // if (result.code === 200 && result.data) {
+ // that.matData = result.data
+ // that.matnr = ''
+ // that.matData['batch'] = ''
+ // uni.navigateTo({
+ // url: "../mat/matSelected",
+ // // 閫氳繃eventChannel鍚戣鎵撳紑椤甸潰浼犻�佹暟鎹�
+ // success: function(res) {
+ // res.eventChannel.emit('mat', {
+ // data: result.data
+ // })
+ // },
+ // // 涓烘寚瀹氫簨浠舵坊鍔犱竴涓洃鍚櫒锛岃幏鍙栬鎵撳紑椤甸潰浼犻�佸埌褰撳墠椤甸潰鐨勬暟鎹�
+ // events: {
+ // matList: function(data) {
+ // that.checkMat(data.data)
+ // that.focuss()
+ // },
+ // },
+ // });
+ // } else if (result.code == 403) {
+ // uni.showToast({
+ // title: result.msg,
+ // icon: "none",
+ // position: 'top'
+ // })
+ // setTimeout(() => {
+ // uni.reLaunch({
+ // url: '../login/login'
+ // });
+ // }, 1000);
+ // } else {
+ // uni.showToast({
+ // title: result.msg,
+ // icon: "none",
+ // position: 'top'
+ // })
+ // }
+
+ // }
+ // });
},
selectMat() {
@@ -317,6 +330,7 @@
that.matnr = ''
},
checkMat(mat) {
+ mat.review = "鏈鏍�"
var len = this.dataList.length
var add = true ,sameItem = false
for (var i = 0; i < len; i++) {
@@ -421,11 +435,17 @@
return;
}
for (var i = 0; i < that.dataList.length; i++) {
+ if (that.dataList[i].review !== "宸插鏍�" ) {
+ this.messageText = that.dataList[i].matnr + '鏈鏍�'
+ this.messageToggle('error')
+ return;
+ }
if (that.dataList[i].anfme == 0 || that.dataList[i].anfme == '') {
this.messageText = that.dataList[i].matnr + '缁勬墭鏁伴噺涓嶈兘涓�0'
this.messageToggle('error')
return;
- }
+ }
+
}
uni.request({
url: that.baseUrl + '/mobile/comb/auth',
@@ -540,7 +560,7 @@
width: 100%;
background-color: white;
position: fixed;
- margin-top: 200rpx;
+ margin-top: 300rpx;
z-index: 9;
/* border-top: 1px solid #DCDFE6; */
text-align: center;
diff --git a/pages/stock/stockCheck.vue b/pages/stock/stockCheck.vue
index 614db9d..dbebda6 100644
--- a/pages/stock/stockCheck.vue
+++ b/pages/stock/stockCheck.vue
@@ -5,19 +5,10 @@
<view class="code-decs">鎵樼洏鐮�:</view>
<input type="text" placeholder=" 鎵爜 / 杈撳叆" v-model="barcode" :focus="barcodeFocus"
@input="search()">
- </view>
- <view class="item">
- <view class="code-decs">鐗╂枡鐮�:</view>
- <input type="text" placeholder=" 鎵爜 / 杈撳叆" v-model="matnr" :focus="matFocus" @input="findMat()">
- <view class="item-right">
- <button></button>
- <text style="text-align: right;color: #409EFF;" @click="selectMat()">鎻愬彇+</text>
- <uni-icons type="right" color="#c1c1c1"></uni-icons>
- </view>
- </view>
+ </view>
</view>
<view class="mat-list-title">
- 鍟嗗搧鍒楄〃
+ 鐗╂枡鍒楄〃
</view>
<scroll-view>
<view class="list" v-for="(item,i) in dataList" :key="i">
@@ -43,12 +34,18 @@
<view class="list-left-item">
<view class="desc">鎵瑰彿锛�</view>
<view class="left-item">
- <uni-tag :text="item.batch" type="warning"></uni-tag>
+ {{item.batch}}
</view>
</view>
<view class="list-left-item">
- <view class="desc">鏁伴噺锛�</view>
- <view class="left-item">{{item.anfme}}</view>
+ <view class="desc">搴撳瓨锛�</view>
+ <view class="left-item">
+ {{item.anfme}}
+ </view>
+ </view>
+ <view class="list-left-item">
+ <view class="desc">鐩樼偣锛�</view>
+ <view class="left-item">{{item.checkAnfme}}</view>
</view>
</view>
<view class="list-right">
@@ -78,8 +75,9 @@
</view>
<view class="popup-item">
<view class="popup-item-left">鎵瑰彿:</view>
- <view class="popup-item-right"><input type="text" v-model="batch"></view>
- </view>
+ <view class="popup-item-right"><input type="text" v-model="batch" disabled="true"
+ style="background-color: #f7f7f7;padding: 0;color: #d5d5d5;"></view>
+ </view>
<view class="popup-item">
<view class="popup-item-left">鏁伴噺:</view>
<view class="popup-item-right" style="border: none;justify-content: center;">
@@ -162,8 +160,11 @@
// 鏍规嵁鎵樼洏鐮佹悳绱�
search() {
let that = this
+ if(that.barcode === "" || that.barcode === null || that.barcode === ''){
+ return
+ }
uni.request({
- url: that.baseUrl + '/mobile/checkDetl/auth2',
+ url: that.baseUrl + '/inventoryCheckOrder/StockCheck/select/barcode',
header: {
'token':uni.getStorageSync('token')
},
@@ -184,6 +185,7 @@
});
}, 1000);
} else {
+ that.dataList = []
uni.showToast({title: res.msg, icon: "none",position: 'top'})
}
}
@@ -323,7 +325,7 @@
// 淇敼鎵瑰彿
revise(item, i) {
this.matnr = this.dataList[i].matnr
- this.count = this.dataList[i].anfme
+ this.count = this.dataList[i].checkAnfme
this.batch = this.dataList[i].batch
this.rowNum = i
this.eject()
@@ -350,7 +352,7 @@
this.$refs.alertDialog.close()
},
reviseConfirm() {
- this.dataList[this.rowNum].anfme = this.count
+ this.dataList[this.rowNum].checkAnfme = this.count
this.dataList[this.rowNum].batch = this.batch
this.messageText = "淇敼鎴愬姛"
this.messageToggle('success')
@@ -396,12 +398,20 @@
},
adjust() {
let that = this
+
+ for (var i = 0; i < that.dataList.length; i++) {
+ if (that.dataList[i].checkAnfme == 0 || that.dataList[i].checkAnfme == '' || that.dataList[i].checkAnfme == null) {
+ this.messageText = that.dataList[i].matnr + '鐩樼偣鏁伴噺涓嶈兘涓�0'
+ this.messageToggle('error')
+ return;
+ }
+ }
var combMats = []
var combParam = {}
combParam['barcode'] = that.barcode
- combParam['wrkDetls'] = that.dataList
+ combParam['param'] = that.dataList
uni.request({
- url: that.baseUrl + '/mobile/adjustNew/auth',
+ url: that.baseUrl + '/mobile/pda/adjust/auth',
method: 'POST',
data: JSON.stringify(combParam),
header: {
@@ -436,7 +446,7 @@
.code {
width: 100%;
position: fixed;
- min-height: 200rpx;
+ min-height: 100rpx;
background-color: #FFF;
z-index: 10;
}
@@ -476,10 +486,21 @@
width: 100%;
background-color: white;
position: fixed;
- margin-top: 200rpx;
+ margin-top: 100rpx;
z-index: 9;
/* border-top: 1px solid #DCDFE6; */
text-align: center;
box-shadow: 0px 0px 30px 0px rgba(0, 0, 0, 0.5);
}
+ .list {
+ display: flex;
+ min-height: 80rpx;
+ background-color: #FFF;
+ margin: 20rpx 20rpx;
+ border-radius: 20rpx;
+ box-shadow: 0px 0px 30px 0px rgba(0,0,0,0.2);
+ }
+ .list:first-child {
+ margin-top: 250rpx;
+ }
</style>
--
Gitblit v1.9.1