wbc
2025-11-01 7b3e82de6edc16f7cb9cfd5ce21137e95b2a9893
托板码pda基础修改后端
已添加6个文件
490 ■■■■■ 文件已修改
H5/Js/tbbd.js 138 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/Js/tbjb.js 137 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/tbbd.aspx 99 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/tbbd.aspx.cs 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/tbjb.aspx 88 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/tbjb.aspx.cs 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/Js/tbbd.js
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,138 @@
var vm = new Vue({
    el: '#app',
    data: function () {
        return {
            isLoading: false,
            userInfo: {
                "loginGuid": '',
                "loginAccount": '',
            },
            formData: {
                TbBarCode: "", //托板码
                barcode: "",
                itemNo: "",
                sumQuantity: 0
            },
            ItemDetail: {
                items: [] // ç¡®ä¿æœ‰è¿™ä¸ªç»“æž„
            },
            itemInsFormData: {},
            tableData: [],
            itemTableData: [],
            barMessage: "",
            Message: "",
            messageCenter: {},
            messageId: 0,
            showClearIcon: false,
            focus1: true,
            focus2: false,
            isActive: 0,
            index: 0,
            currentTab: 0,
            contentScrollW: 0, // å¯¼èˆªåŒºå®½åº¦
            scrollLeft: 0, // æ¨ªå‘滚动条位置
            fullHeight: "",
        }
    },
    mounted() {
        var that = this;
        this.userInfo = {
            loginGuid: this.GetLoginInfor().loginGuid,
            loginAccount: this.GetLoginInfor().loginAccount,
        };
    },
    methods: {
        getScanTb() {
            var that = this;
            that.isLoading = true;
            that.AxiosHttp("post", 'tbbd/GetBracodeDetails', {
                TbBarCode: that.formData.TbBarCode
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        //that.formData.sectionCode = json.data.tbBillList;
                        that.ItemDetail.items = json.data.tbBillList;
                        if (that.formData.barcode == "" || that.formData.barcode == null) {
                            that.$refs.barcode.focus();
                            that.isLoading = false;
                        }
                    }
                    else {
                        that.$toast.fail(json.message);
                        that.formData.sectionCode = null;
                        that.$refs.sectionCode.focus();
                        that.isLoading = false;
                    }
                })
                .catch(function (error) {
                    that.isLoading = false;
                    that.$toast.fail("网络错误,请重试!");
                    console.log(error);
                    that.formData.sectionCode = null;
                    that.$refs.sectionCode.focus();
                });
        },
        getScanBar() {
            var that = this;
            //that.isLoading = true;
            that.AxiosHttp("post", 'tbbd/ScanTBBD', {
                TbBarCode: that.formData.TbBarCode,
                ItemBarcode: that.formData.barcode,
                userName: that.userInfo.loginAccount,
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        that.getScanTb();
                        that.$refs.barcode.focus();
                        that.formData.barcode = null;
                            //that.ItemDetail.items = json.data.tbBillList;
                    }
                    else {
                        that.$toast.fail(json.message);
                        that.$refs.barcode.focus();
                        that.formData.barcode = null;
                        //that.ItemDetail = null;
                        that.isLoading = false;
                    }
                    that.isLoading = false;
                })
                .catch(function (error) {
                    that.isLoading = false;
                    that.$toast.fail("网络错误,请重试!");
                    console.log(error);
                    that.$refs.barcode.focus();
                });
        },
        cleraCode() {
            this.formData.sectionCode = null;
        },
        //更新接口记录表
        updateMessage(messageCenter) {
            this.$post({
                url: "/MessageCenter/ResetUpdate",
                data: messageCenter
            }).then(res => {
                if (res.data.tbBillList > 0) {
                    this.Message += " [问题记录成功!]";
                } else {
                    this.Message += " [问题记录失败!!!]";
                }
            });
        },
    }
})
H5/Js/tbjb.js
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,137 @@
var vm = new Vue({
    el: '#app',
    data: function () {
        return {
            isLoading: false,
            userInfo: {
                "loginGuid": '',
                "loginAccount": '',
            },
            formData: {
                TbBarCode: "", //托板码
                barcode: "",
                itemNo: "",
                sumQuantity: 0
            },
            ItemDetail: {
                items: [] // ç¡®ä¿æœ‰è¿™ä¸ªç»“æž„
            },
            itemInsFormData: {},
            tableData: [],
            itemTableData: [],
            barMessage: "",
            Message: "",
            messageCenter: {},
            messageId: 0,
            showClearIcon: false,
            focus1: true,
            focus2: false,
            isActive: 0,
            index: 0,
            currentTab: 0,
            contentScrollW: 0, // å¯¼èˆªåŒºå®½åº¦
            scrollLeft: 0, // æ¨ªå‘滚动条位置
            fullHeight: "",
        }
    },
    mounted() {
        var that = this;
        this.userInfo = {
            loginGuid: this.GetLoginInfor().loginGuid,
            loginAccount: this.GetLoginInfor().loginAccount,
        };
    },
    methods: {
        getScanTb() {
            var that = this;
            that.isLoading = true;
            that.AxiosHttp("post", 'tbjb/GetBracodeDetails', {
                TbBarCode: that.formData.TbBarCode
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        //that.formData.sectionCode = json.data.tbBillList;
                        that.ItemDetail.items = json.data.tbBillList;
                        if (that.formData.TbBarCode == "" || that.formData.TbBarCode == null) {
                            that.$refs.TbBarCode.focus();
                            that.isLoading = false;
                        }
                    }
                    else {
                        that.$toast.fail(json.message);
                        that.formData.sectionCode = null;
                        that.$refs.TbBarCode.focus();
                        that.isLoading = false;
                    }
                })
                .catch(function (error) {
                    that.isLoading = false;
                    that.$toast.fail("网络错误,请重试!");
                    console.log(error);
                    that.formData.sectionCode = null;
                    that.$refs.TbBarCode.focus();
                });
        },
        getScanBar() {
            var that = this;
            //that.isLoading = true;
            that.AxiosHttp("post", 'tbjb/ScanTBJB', {
                ItemBarcode: that.formData.TbBarCode,
                userName: that.userInfo.loginAccount,
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        that.getScanTb();
                        that.$refs.TbBarCode.focus();
                        that.formData.TbBarCode = null;
                        //that.ItemDetail.items = json.data.tbBillList;
                    }
                    else {
                        that.$toast.fail(json.message);
                        that.$refs.TbBarCode.focus();
                        that.formData.TbBarCode = null;
                        //that.ItemDetail = null;
                        that.isLoading = false;
                    }
                    that.isLoading = false;
                })
                .catch(function (error) {
                    that.isLoading = false;
                    that.$toast.fail("网络错误,请重试!");
                    console.log(error);
                    that.$refs.TbBarCode.focus();
                });
        },
        cleraCode() {
            this.formData.sectionCode = null;
        },
        //更新接口记录表
        updateMessage(messageCenter) {
            this.$post({
                url: "/MessageCenter/ResetUpdate",
                data: messageCenter
            }).then(res => {
                if (res.data.tbBillList > 0) {
                    this.Message += " [问题记录成功!]";
                } else {
                    this.Message += " [问题记录失败!!!]";
                }
            });
        },
    }
})
H5/tbbd.aspx
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,99 @@
<%@ Page Title="托板码绑定" Language="C#" MasterPageFile="~/Mst.master" AutoEventWireup="true" CodeFile="tbbd.aspx.cs" Inherits="H5_tbbd" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <style>
    .bg-info {
        background-color:#fff;
    }
</style>
</asp:Content>
    <asp:Content ID="Content5" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
        <van-notice-bar
    :scrollable="false"
    :text="'当前组织:' + (Cookies.get('orgName') || '暂无组织信息')"
    class="org-info"
/></van-notice-bar>
    <van-nav-bar
  title="托板码绑定"
  left-text="返回"
  left-arrow
  @click-left="GoBack()"
></van-nav-bar>
<%--    <div class="mySolid">--%>
        <van-cell-group>
  <van-field
    ref="TbBarCode"
    v-model="formData.TbBarCode"
    label="托板码编码"
    clearable
     placeholder="请扫码"
    :right-icon-size="19"
     v-focus.noKeyboard
    <%--@change="getModel"--%>
      @keyup.enter.native ="getScanTb"
      autofocus="true"
  ></van-field>
 <van-field
   ref="barcode"
   v-model="formData.barcode"
  label="物料条码"
   clearable
 placeholder="请扫码"
  :right-icon-size="19"
  v-focus.noKeyboard
      @keyup.enter.native ="getScanBar"
<%--  @change="getBarInfo"--%>
></van-field>
</van-cell-group>
<%--    </div>--%>
 <van-tabs color="#000" title-active-color="#0283EF">
   <van-tab title="托板码已绑定条码信息" class="mySolid font">
     <div class="container">
       <!-- è¡¨å¤´ -->
       <van-row class="header">
         <van-col span="5" class="text-left padding-left">物料条码</van-col>
         <van-col span="5" class="text-left padding-left">物料编码</van-col>
         <van-col span="5" class="text-left padding-left">物料名称</van-col>
          <van-col span="6" class="text-left padding-left">规格型号</van-col>
        <van-col span="3">数量</van-col>
       </van-row>
       <!-- æ•°æ®è¡Œ -->
       <div class="data-rows">
         <van-row v-for="(itm,index) in ItemDetail.items" :key="index" class="data-row">
            <van-col span="5" class="text-left padding-left">
                <div>{{itm.wltm}}</div>
           </van-col>
           <van-col span="5" class="text-left padding-left">
             <div class="blue-text">{{itm.itemNo}}</div>
           </van-col>
             <van-col span="5" class="text-left padding-left">
           <div>{{itm.itemName}}</div>
           </van-col>
            <van-col span="6">{{itm.itemModel}}</van-col>
           <van-col span="3" class="blue-text">{{itm.FQty}}</van-col>
         </van-row>
         <!-- ç©ºçŠ¶æ€æç¤º -->
         <div v-if="!ItemDetail.items || ItemDetail.items.length === 0" class="empty-state">
           æš‚无数据
         </div>
       </div>
     </div>
   </van-tab>
 </van-tabs>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ContentPlaceHolder3" Runat="Server">
    <comloading  v-if="isLoading"></comloading>
    <%--<comback ></comback>--%>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolder4" Runat="Server">
    <script src="Js/tbbd.js?<%=12146 %>"></script>
</asp:Content>
H5/tbbd.aspx.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
public partial class H5_tbbd : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
    }
}
H5/tbjb.aspx
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,88 @@
<%@ Page Title="托板码解绑" Language="C#" MasterPageFile="~/Mst.master" AutoEventWireup="true" CodeFile="tbjb.aspx.cs" Inherits="H5_tbjb" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <style>
    .bg-info {
        background-color:#fff;
    }
</style>
</asp:Content>
    <asp:Content ID="Content5" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
        <van-notice-bar
    :scrollable="false"
    :text="'当前组织:' + (Cookies.get('orgName') || '暂无组织信息')"
    class="org-info"
/></van-notice-bar>
    <van-nav-bar
  title="托板码解绑"
  left-text="返回"
  left-arrow
  @click-left="GoBack()"
></van-nav-bar>
<%--    <div class="mySolid">--%>
        <van-cell-group>
  <van-field
    ref="TbBarCode"
    v-model="formData.TbBarCode"
    label="扫描条码"
    clearable
     placeholder="请扫码"
    :right-icon-size="19"
     v-focus.noKeyboard
    <%--@change="getModel"--%>
      @keyup.enter.native ="getScanBar"
      autofocus="true"
  ></van-field>
</van-cell-group>
<%--    </div>--%>
 <van-tabs color="#000" title-active-color="#0283EF">
   <van-tab title="托板码已绑定条码信息" class="mySolid font">
     <div class="container">
       <!-- è¡¨å¤´ -->
       <van-row class="header">
         <van-col span="5" class="text-left padding-left">物料条码</van-col>
         <van-col span="5" class="text-left padding-left">物料编码</van-col>
         <van-col span="5" class="text-left padding-left">物料名称</van-col>
          <van-col span="6" class="text-left padding-left">规格型号</van-col>
        <van-col span="3">数量</van-col>
       </van-row>
       <!-- æ•°æ®è¡Œ -->
       <div class="data-rows">
         <van-row v-for="(itm,index) in ItemDetail.items" :key="index" class="data-row">
            <van-col span="5" class="text-left padding-left">
                <div>{{itm.wltm}}</div>
           </van-col>
           <van-col span="5" class="text-left padding-left">
             <div class="blue-text">{{itm.itemNo}}</div>
           </van-col>
             <van-col span="5" class="text-left padding-left">
           <div>{{itm.itemName}}</div>
           </van-col>
            <van-col span="6">{{itm.itemModel}}</van-col>
           <van-col span="3" class="blue-text">{{itm.FQty}}</van-col>
         </van-row>
         <!-- ç©ºçŠ¶æ€æç¤º -->
         <div v-if="!ItemDetail.items || ItemDetail.items.length === 0" class="empty-state">
           æš‚无数据
         </div>
       </div>
     </div>
   </van-tab>
 </van-tabs>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ContentPlaceHolder3" Runat="Server">
    <comloading  v-if="isLoading"></comloading>
    <%--<comback ></comback>--%>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolder4" Runat="Server">
    <script src="Js/tbjb.js?<%=12145 %>"></script>
</asp:Content>
H5/tbjb.aspx.cs
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
public partial class H5_tbjb : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
    }
}