From 0bb1834b9755eaf7c67d25cd9012be2ca14a7efe Mon Sep 17 00:00:00 2001
From: 南骏 池 <chiffly@163.com>
Date: 星期五, 11 四月 2025 09:13:16 +0800
Subject: [PATCH] 1.委外退料优化 2.核对送检
---
H5/Wwtl.aspx | 2
H5/Js/Cpbdsj.js | 115 +++++++++++++++++++
H5/Cpdbsj.aspx | 217 ++++++++++++++++++++++-------------
3 files changed, 250 insertions(+), 84 deletions(-)
diff --git a/H5/Cpdbsj.aspx b/H5/Cpdbsj.aspx
index f405cf3..38c2311 100644
--- a/H5/Cpdbsj.aspx
+++ b/H5/Cpdbsj.aspx
@@ -1,4 +1,4 @@
-锘�<%@ Page Title="缁戝畾閫佹" Language="C#" MasterPageFile="~/Mst.master" AutoEventWireup="true" CodeFile="Cpdbsj.aspx.cs" Inherits="H5_Cpdbsj" %>
+锘�<%@ Page Title="鏍稿閫佹" Language="C#" MasterPageFile="~/Mst.master" AutoEventWireup="true" CodeFile="Cpdbsj.aspx.cs" Inherits="H5_Cpdbsj" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
<style>
.si-status-box,
@@ -19,13 +19,48 @@
font-size: 0.33rem !important; /* 缁熶竴瀛椾綋澶у皬 */
color: inherit !important; /* 缁ф壙鐖剁骇鏂囧瓧棰滆壊 */
}
+
+
+ /* 灞呬腑鏍稿績鏍峰紡 */
+.centered-stepper-field {
+ .stepper-container {
+ display: flex;
+ justify-content: center; /* 姘村钩灞呬腑 */
+ width: 100%;
+ }
+
+ /* 璋冩暣姝ヨ繘鍣ㄦ寜閽棿璺� */
+ .van-stepper__minus {
+ margin-right: 12px;
+ }
+ .van-stepper__plus {
+ margin-left: 12px;
+ }
+}
+
+ /* 鏂板鏍峰紡 */
+ .button-container {
+ display: flex;
+ width: 100%;
+ gap: 12px; /* 鎸夐挳闂磋窛 */
+ padding: 0 16px; /* 宸﹀彸鐣欑櫧 */
+ box-sizing: border-box;
+ }
+
+ .action-button {
+ flex: 1; /* 绛夊垎鍓╀綑绌洪棿 */
+ min-width: 0; /* 闃叉鍐呭婧㈠嚭 */
+ }
+
+
+
</style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
<div class="content-wrapper">
<van-nav-bar
- title="缁戝畾閫佹"
+ title="鏍稿閫佹"
left-text="杩斿洖"
left-arrow
@click-left="GoBack()">
@@ -34,115 +69,131 @@
<div class="mySolid">
<van-cell-group>
<van-field
- ref="ZsBar"
- v-model="ZsBar"
- label="杩芥函鏉$爜"
+ ref="KbBar"
+ v-model="KbBar"
+ label="鍗℃澘鏉$爜"
clearable
placeholder="璇锋壂鐮�"
:right-icon-size="19"
v-focus.noKeyboard
- @keyup.enter.native="getZsBarInfo"
+ @keyup.enter.native="getKbBarInfo"
autofocus="true">
</van-field>
+
+ <div class="si-status-group">
+ <div class="si-status-box si-status--ok">
+ <div class="si-status__left">
+ <span class="si-status__label">鍙鏁�</span>
+ </div>
+ <div class="si-status__right">{{KbBarInfo.oldqty}}</div>
+ </div>
+
+ <div class="si-status-box si-status--error">
+ <div class="si-status__left">
+ <span class="si-status__label">寰呰鏁�</span>
+ </div>
+ <div class="si-status__right">{{KbBarInfo.ySum}}</div>
+ </div>
+ </div>
+
<van-field
- v-model="UserName"
- label="浣滀笟浜哄憳"
- clearable
- :right-icon-size="19"
- placeholder=""
- readonly >
- </van-field>
-
- <van-field
- ref="barcode"
- v-model="ZsBarInfo.lineName"
- label="浜х嚎"
- clearable
- placeholder="浜х嚎鍚嶇О"
- :right-icon-size="19"
- readonly >
+ label="瑁呯鏁�"
+ class="centered-stepper-field"
+ :model-value="Xvalue.toString()"
+ >
+ <template #input>
+ <div class="stepper-container">
+ <van-stepper
+ v-model="Xvalue"
+ :min="1"
+ :max="99"
+ integer
+ button-size="26px"
+ :disable-input="true"
+ />
+ </div>
+ </template>
</van-field>
<van-field
ref="LsBar"
v-model="LsBar"
- label="鍚庣洊鏉$爜"
- placeholder="璇锋壂鍚庣洊鐮�"
- @keyup.enter.native="getModel"
+ label="绠辨潯鐮�"
+ placeholder="璇锋壂澶栫鐮�"
+ autofocus="true">
+ </van-field>
+
+ <van-field
+ ref="LsBar"
+ v-model="LsBar"
+ label="浜у搧鏉$爜"
+ placeholder="璇锋壂浜у搧鏉$爜"
autofocus="true">
</van-field>
- <div class="si-status-group">
- <div class="si-status-box si-status--ok">
- <div class="si-status__left">
- <span class="si-status__label">鎬绘暟</span>
- </div>
- <div class="si-status__right">{{ZsBarInfo.sumQty}}</div>
- </div>
-
- <div class="si-status-box si-status--error">
- <div class="si-status__left">
- <span class="si-status__label">瀹屾垚鏁�</span>
- </div>
- <div class="si-status__right">{{ZsBarInfo.finQty}}</div>
- </div>
-
- <van-button
- slot="button"
- type="info"
- size="small"
- @click="getChaiFen">
- 鎻愪氦
- </van-button>
+ <van-field
+ ref="LsBar"
+ v-model="LsBar"
+ label="绾垮埆"
+ placeholder="璇烽�夋嫨绾垮埆"
+ autofocus="true">
+ </van-field>
+ <!-- 淇敼鍚庣殑鎸夐挳瀹瑰櫒 -->
+ <div class="button-container">
+ <van-button
+ type="warning"
+ class="action-button reset-button"
+ >閲嶇疆</van-button>
+ <van-button
+ type="info"
+ class="action-button submit-button"
+ >閫佹</van-button>
</div>
</van-cell-group>
</div>
<van-tabs color="#000" title-active-color="#0283EF">
- <van-tab title="浜у搧淇℃伅" class="mySolid font">
- <van-cell-group >
- <van-field label="鎸囦护鍗曞彿" colon="true" v-model="ZsBarInfo.daa001" readonly style="background: #ffa53b"></van-field>
- <van-field label="鏉$爜鏁伴噺" colon="true" v-model="ZsBarInfo.barQty" readonly style="background: #ffa53b" ></van-field>
- <van-field label="杩芥函鐮�" colon="true" v-model="ZsBarInfo.zsBarcode" readonly style="background: #ffa53b" ></van-field>
- <van-field label="浜у搧缂栫爜" colon="true" v-model="ZsBarInfo.item_no" readonly style="background: #ffa53b" ></van-field>
- <van-field label="浜у搧鍚嶇О" colon="true" v-model="ZsBarInfo.item_name" readonly style="background: #ffa53b" ></van-field>
- <van-field label="浜у搧瑙勬牸" colon="true" v-model="ZsBarInfo.item_model" readonly style="background: #ffa53b" ></van-field>
- <van-field label="鍓嶄竴宸ュ簭" colon="true" v-model="ZsBarInfo.lastGx" readonly style="background: #ffa53b" ></van-field>
- <van-field label="褰撳墠宸ュ簭" colon="true" v-model="GX" readonly style="background: #ffa53b" ></van-field>
- </van-cell-group>
- </van-tab>
-
- <van-tab title="鐢熶骇灞ュ巻" class="mySolid font">
+ <van-tab title="绠辨槑缁�" class="mySolid font">
<van-row>
- <van-col span="6">浜哄憳</van-col>
- <van-col span="6">浜х嚎</van-col>
- <van-col span="6">宸ュ簭</van-col>
- <van-col span="6">缁撴灉</van-col>
+ <van-col span="7" class="text-left padding-left">鏉$爜</van-col>
+ <van-col span="7" class="text-left padding-left">鐗╂枡</van-col>
+ <van-col span="7" class="text-left padding-left">瑙勬牸</van-col>
+ <van-col span="3" >鏁伴噺</van-col>
</van-row>
- <van-row v-for="(itm,index) in Traceability" :key="index">
- <van-col span="6" >{{itm.useR_NAME}}</van-col>
- <van-col span="6" >{{itm.line_no}}</van-col>
- <van-col span="6" class="blue-text">{{itm.processNo}}</van-col>
- <van-col span="6" >{{itm.checkResult}}</van-col>
+ <van-row v-for="(itm,index) in KbBarMxInfo" :key="index">
+ <van-col span="7" class="text-left padding-left" >{{itm.iteM_BARCODE}}</van-col>
+ <van-col span="7" class="text-left padding-left">
+ <div class="blue-text">{{itm.item_no}}</div>
+ <div>{{itm.item_name}}</div>
+ </van-col>
+ <van-col span="7" class="text-left padding-left">
+ <div>{{itm.item_model}}</div>
+ </van-col>
+
+ <van-col span="3" class="blue-text">{{itm.quantity}}</van-col>
</van-row>
</van-tab>
- <van-tab title="宸茬粦鏉$爜" class="mySolid font">
+ <van-tab title="鍗℃澘鏄庣粏" class="mySolid font">
<van-row>
- <van-col span="5">浜哄憳</van-col>
- <van-col span="5">浜х嚎</van-col>
- <van-col span="5">宸ュ簭</van-col>
- <van-col span="4">鑹搧</van-col>
- <van-col span="5">涓嶈壇鍝�</van-col>
+ <van-col span="7" class="text-left padding-left">鏉$爜</van-col>
+ <van-col span="7" class="text-left padding-left">鐗╂枡</van-col>
+ <van-col span="7" class="text-left padding-left">瑙勬牸</van-col>
+ <van-col span="3" >鏁伴噺</van-col>
</van-row>
- <van-row v-for="(itm,index) in Traceability" :key="index">
- <van-col span="5" >{{itm.fQty}}</van-col>
- <van-col span="5" >{{itm.fQty}}</van-col>
- <van-col span="5" class="blue-text">{{itm.fQty}}</van-col>
- <van-col span="4" >{{itm.fQty}}</van-col>
- <van-col span="5" >{{itm.sQty}}</van-col>
+ <van-row v-for="(itm,index) in KbBarMxInfo" :key="index">
+ <van-col span="7" class="text-left padding-left" >{{itm.iteM_BARCODE}}</van-col>
+ <van-col span="7" class="text-left padding-left">
+ <div class="blue-text">{{itm.item_no}}</div>
+ <div>{{itm.item_name}}</div>
+ </van-col>
+ <van-col span="7" class="text-left padding-left">
+ <div>{{itm.item_model}}</div>
+ </van-col>
+
+ <van-col span="3" class="blue-text">{{itm.quantity}}</van-col>
</van-row>
</van-tab>
</van-tabs>
@@ -154,5 +205,5 @@
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolder4" Runat="Server">
- <script src="Js/Cpbd.js?<%=121112 %>"></script>
+ <script src="Js/Cpbdsj.js?<%=11111 %>"></script>
</asp:Content>
\ No newline at end of file
diff --git a/H5/Js/Cpbdsj.js b/H5/Js/Cpbdsj.js
new file mode 100644
index 0000000..8569726
--- /dev/null
+++ b/H5/Js/Cpbdsj.js
@@ -0,0 +1,115 @@
+锘縱ar vm = new Vue({
+ el: '#app',
+ data: function () {
+ return {
+ isLoading: false,
+ userInfo: {
+ "loginGuid": '',
+ "loginAccount": '',
+ },
+ KbBar: "",//鍗℃澘鏉$爜
+ LsBar: "",//鍚庣洊娴佹按鏉$爜
+ UserName: Cookies.get('loginName'),//鐢ㄦ埛鍚嶇О
+ KbBarInfo: [],
+ KbBarMxInfo: [],
+ GX: "G007:鏍稿閫佹",
+ Xvalue:4,
+ ItemDetail:[],
+ }
+ },
+ mounted() {
+ var that = this;
+ this.userInfo = {
+ loginGuid: this.GetLoginInfor().loginGuid,
+ loginAccount: this.GetLoginInfor().loginAccount,
+ };
+ },
+ methods: {
+ getKbBarInfo() {
+ var that = this;
+ that.isLoading = true;
+ that.AxiosHttp("post", 'Womdaa/getKbBarInfo', {
+ Xt: that.GX,
+ Kbbarcode: that.KbBar
+ }, false)
+ .then(function (res) {
+ var json = res;
+ if (json.status == 0) {
+
+ that.$refs.LsBar.focus();
+ that.KbBarInfo = json.data.tbBillList.kbBarInfo[0];
+ that.KbBarMxInfo = json.data.tbBillList.kbBarMxInfo;
+ }
+ else {
+ that.$toast.fail(json.message);
+ that.$refs.KbBar.focus();
+ that.KbBar = "";
+ }
+ that.isLoading = false;
+ })
+ .catch(function (error) {
+ that.isLoading = false;
+ that.$toast.fail("缃戠粶閿欒锛岃閲嶈瘯锛�");
+ });
+ },
+ productBinding() {
+ var that = this;
+ if (that.ZsBar.length <= 0) {
+ that.$toast.fail("杩芥函鐮佷笉鑳戒负绌猴紒");
+ return;
+ }
+ if (that.LsBar.length <= 0) {
+ that.$toast.fail("鍚庣洊鐮佷笉鑳戒负绌猴紒");
+ return;
+ }
+
+ that.isLoading = true;
+ that.AxiosHttp("post", 'Womdaa/ProductBinding', {
+ ZsBar: that.ZsBar,
+ LsBar: that.LsBar,
+ userName: that.userInfo.loginAccount,
+ }, false)
+ .then(function (res) {
+ var json = res;
+ if (json.status == 0) {
+ // that.scanInfo = json.data.tbBillList;
+ that.$notify({ type: 'success', message: json.message });
+ that.$refs.ZsBar.focus();
+ that.ZsBar = null;
+ that.ZsBar = null;
+ }
+ else {
+ that.$toast.fail(json.message);
+ that.$refs.ZsBar.focus();
+ that.ZsBar = null;
+ that.ZsBar = null;
+ }
+
+ that.isLoading = false;
+ })
+ .catch(function (error) {
+ that.isLoading = false;
+ that.$toast.fail("缃戠粶閿欒锛岃閲嶈瘯锛�");
+ that.$refs.ZsBar.focus();
+ that.ZsBar = null;
+ that.ZsBar = null;
+ });
+ },
+ //鎵撳嵃鏈烘敞閲�
+ //selectPrinter(printer) {
+ // this.selectedPrinter = printer.printerId; // 鏇存柊閫変腑鐨勬墦鍗版満缂栧彿
+ //},
+ //confirmSelection() {
+ // if (this.selectedPrinter) {
+ // alert(`鎮ㄩ�夋嫨浜嗘墦鍗版満锛�${this.selectedPrinter}`);
+ // // 鍦ㄨ繖閲屽鐞嗛�夋嫨缁撴灉锛屼緥濡傝皟鐢ㄦ帴鍙f垨鏇存柊鐘舵��
+ // this.isPrinterPopupVisible = false; // 鍏抽棴寮圭獥
+ // } else {
+ // alert('璇烽�夋嫨涓�涓墦鍗版満锛�');
+ // }
+ //},
+ //onPrinterSelected(value) {
+ // console.log('褰撳墠閫変腑鐨勬墦鍗版満缂栧彿:', value);
+ //},
+ }
+})
\ No newline at end of file
diff --git a/H5/Wwtl.aspx b/H5/Wwtl.aspx
index 7047d8d..5cc1bcf 100644
--- a/H5/Wwtl.aspx
+++ b/H5/Wwtl.aspx
@@ -75,7 +75,7 @@
<van-col span="6">寰呮壂</van-col>
<van-col span="6">宸叉壂</van-col>
</van-row>
- <van-row v-for="value in ItemTblDetail" class="font">
+ <van-row v-for="value in ItemTblDetail.items" class="font">
<van-col span="12" class="text-left padding-left">
<div>{{value.itemNo}}</div>
<div>{{value.itemName}}</div>
--
Gitblit v1.9.3