diff --git a/components/easy-scancode/easy-scancode.vue b/components/easy-scancode/easy-scancode.vue
index 1aa6e90..7e141ab 100644
--- a/components/easy-scancode/easy-scancode.vue
+++ b/components/easy-scancode/easy-scancode.vue
@@ -95,9 +95,9 @@ export default {
that.html5QrCode = new Html5Qrcode("reader");
let windowInfo = uni.getWindowInfo();
- console.log(windowInfo);
- const width = windowInfo.windowWidth?windowInfo.windowWidth:375;
- const height = windowInfo.windowHeight?windowInfo.windowHeight:720;
+ // console.log(windowInfo);
+ const width = windowInfo&&windowInfo.windowWidth?windowInfo.windowWidth:375;
+ const height = windowInfo&&windowInfo.windowHeight?windowInfo.windowHeight:720;
// 横屏
const aspectRatio = width / height;
@@ -134,6 +134,11 @@ export default {
facingMode: "environment",
aspectRatio: width < 600 ? mobileAspectRatio : aspectRatio,
},
+ autofocus:true, //自动对焦 但使用的时候没有体会到
+ colorDark: '#0000ff', //加深二维码黑色部分的颜色提高识别度
+ colorLight: '#ffffff',//这个应该是提高非黑即白部分的亮度 提高识别度
+ visualFeedback:true, //开启视觉反馈 没有体会到
+ halfSample:true,//缩小二维码提高识别精度吧
},
(decodedText, decodedResult) => {
// 当码被读取时执行操作
@@ -182,6 +187,8 @@ export default {
top: 50%;
left: 0;
transform: translateY(-50%);
+ width: 100vw;
+ height: 100vh;
}
.scan-tip-overlay {
diff --git a/components/psDetail.vue b/components/psDetail.vue
index 6824c51..5c823d5 100644
--- a/components/psDetail.vue
+++ b/components/psDetail.vue
@@ -221,146 +221,148 @@
{{ item.groupDesc }} ({{ item.qty?parseFloat(item.qty).toFixed(2):'0.00'}})
-
@@ -451,44 +453,50 @@
palletNo: this.pallet.palletNo
});
if(res.success){
- if(res.data)
+ if(res.data&&res.data.length>0)
{
- this.pallet["instdetailList"]=res.data;
- // this.pallet["instdetailList"]=[{
- // "id": "b0ce28eb-cf71-466f-952f-17b7663c29f2",
- // "project": "T300K-106",
- // "instno": "9201FP12010MV",
- // "dwgno": "9201MP12MVM",
- // "section": "9201",
- // "assemcode": "40-CW02-L3S-05",
- // "spec": "21.3*2.11",
- // "grd": "A312 TP316",
- // "qty": "1.000000",
- // "weight": "0.6500",
- // "treatment": "钝化",
- // "status": "配送出库",
- // "statusDate": "2026/01/07",
- // "manuDept": "九作业区",
- // "treatDept": "永合机电",
- // "deliverDept": "集配组",
- // "palletNo": "",
- // "deliveryCar": "284",
- // "deliveryDate": "2026/01/07",
- // "deliveryRemark": "协商 (刘文禄 2026/01/06)",
- // "requireDate": "2026/01/05",
- // "requireDepartCode": "P30000",
- // "requireAddress": "分段二部装焊厂房(钢加配送)",
- // "requireName": "郝名远",
- // "requirePhone": "13500795290",
- // "groupDesc": "T300K-106 9201FP12010MV",
- // "uniStr": "T300K-106 9201FP12010MV 40-CW02-L3S-05\n21.3*2.11 A312 TP316 1.000000"
- // }]
+ this.pallet["instdetailList"]=[];
+ res.data.forEach(cell=>{
+ var findx = -1;
+ findx = this.pallet["instdetailList"].findIndex(item => item.groupDesc === cell.groupDesc);
+ if(findx<0){
+ var add = {
+ ...cell,
+ items:[cell],
+ };
+ this.pallet["instdetailList"].push(add);
+ this.$forceUpdate();
+ }
+ else {
+ this.pallet["instdetailList"][findx].items.push(cell);
+ this.$forceUpdate();
+ }
+ });
+
+ this.pallet["instdetailList"].forEach((cell,idx)=>{
+ cell["qty"]=this.getQty(cell.items);
+ this.$forceUpdate();
+ });
+
+ // this.pallet["instdetailList"]=res.data;
this.$forceUpdate();
}
}
}
},
+ getQty(items){
+ var num=0
+ if (items&&items.length>0) {
+ items.forEach(cell=>{
+ num=num+1.0*(cell.qty?cell.qty:0);
+ });
+ return num.toFixed(2);
+ }
+ else{
+ return 0;
+ }
+ },
toggleDetail(index) {
if (this.expandedIndex === index) {
this.expandedIndex = null;
@@ -719,6 +727,7 @@
padding: 12rpx;
border-radius: 10rpx;
border: 1rpx solid #007aff;
+ background: #e2eefa;
}
.item-title {
display: flex;
diff --git a/pages/pallet/ck.vue b/pages/pallet/ck.vue
index 5484bdd..4e12547 100644
--- a/pages/pallet/ck.vue
+++ b/pages/pallet/ck.vue
@@ -310,15 +310,18 @@
if(res.data){
this.ifsm = false;
this.trayInfo=res.data;
- if(this.trayInfo.loadId){
- console.log(1)
- // 查询托盘明细
- this.getYpDetail()
- }
- else{
- // this.open() // 打开基本详情
- this.openPalletDetail(); // 基本详情
- }
+
+ // 基本详情 全部弹框查询
+ this.openPalletDetail();
+
+ // if(this.trayInfo.loadId){
+ // // 查询托盘明细
+ // this.getYpDetail()
+ // }
+ // else{
+ // // this.open() // 打开基本详情
+ // this.openPalletDetail(); // 基本详情
+ // }
}
else{
this.ifsm = true;
diff --git a/pages/pallet/yz.vue b/pages/pallet/yz.vue
index eecd451..f728049 100644
--- a/pages/pallet/yz.vue
+++ b/pages/pallet/yz.vue
@@ -66,12 +66,13 @@
-
-
+
+
+