huawei
6 天以前 5163becaa67240089cfb499fceb40f71799ee284
搬标准版代码(采购退货单,申请单 销售退货单申请单)
已修改5个文件
162 ■■■■ 文件已修改
H5/Js/PurchaseReturn.js 113 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/Js/Xsth.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/PurchaseReturn.aspx 40 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Mst.master 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
UserLogin.aspx 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
H5/Js/PurchaseReturn.js
@@ -11,7 +11,7 @@
                itemOutNo: "",
                barcode: "",
                itemNo: "",
                quantity:0
                quantity: 0
            },
            formData: {},
            ItemDetail: [],
@@ -26,13 +26,21 @@
            messageCenter: {},
            messageId: 0,
            show: false,
            scanInfo: { barcodeNum: "", splitNum: "", barcode: "" },
            ip: "",
            port: "",
            oldBarInfo: [],
            cfBarInfo: [],
            selectKey: "",//查询关键字
            actions: [],//列表的值
            show: false,//列表展示
            // 当前选中行的索引
            currentIndex: -1,
            // 存储选中行数据对象
            selItem: {},
            ItemBarKw: [],//当天行相关条码库位信息
            DaaInfo: {},
        }
    },
    mounted() {
@@ -45,20 +53,78 @@
        //that.show = false;
    },
    methods: {
        getItemOutNo() {
            var that = this;
        /**
        * 处理行点击事件(单选逻辑)
        * @param {Object} item 当前行数据
        * @param {Number} index 当前行索引
        */
        handleRowClick(item, index) {
            if (this.isLoading) {
                return;
            }
            // 重置所有行的选中状态
            this.currentIndex = -1;
            // 设置当前选中行
            this.currentIndex = index;
            this.selItem = {
                itemid: item.itemId,//驼峰命名法!!!
                index: index
            };
            console.log('当前选中项:', this.selItem); // 调试用
            this.GetBarKwByItem();
        },
        //获取库位信息
        GetBarKwByItem() {
            //Womdaa
            //WwGd
            var that = this;
            that.isLoading = true;
            that.AxiosHttp("post", 'MesCgthSq/GetMesCgthSq', {
            that.AxiosHttp("post", 'Womdaa/GetBarKwByItemCK', {
                itemId: that.selItem.itemid,
                userName: that.userInfo.loginAccount,
                type: 'CGCK',
                billNo: that.scanFormData.itemOutNo
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        that.ItemBarKw = json.data.tbBillList;
                    }
                    else {
                        that.$toast.fail(json.message);
                        that.$playSound('error');
                        that.ItemBarKw = [];
                    }
                    that.isLoading = false;
                })
                .catch(function (error) {
                    that.isLoading = false;
                    that.$toast.fail("网络错误,请重试!");
                    that.$playSound('error');
                    console.log(error);
                    that.ItemBarKw = [];
                });
        },
        getItemOutNo() {
            var that = this;
            that.isLoading = true;
            that.AxiosHttp("post", 'MesCgthSq/GetMesCgthSq', {}, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        that.itemOutNoList = json.data.tbBillList;
                        that.itemOutNoStr = that.itemOutNoList.map(s => {
                            return { name: s.billNo }
                        });
                        that.show = true;
                        if (!Array.isArray(that.itemOutNoList) || that.itemOutNoList.length === 0) {
                            that.$toast.fail("没有可用的数据");
                            that.show = false;
                        }
                        else {
                            that.itemOutNoStr = that.itemOutNoList.map(s => ({ name: s }));
                            that.show = true;
                        }
                    }
                    else {
                        that.$playSound('error');
@@ -100,38 +166,27 @@
        },
        onSelect(item) {
            // 默认情况下点击选项时不会自动收起
            // 可以通过 close-on-click-action 属性开启自动收起
            this.show = false;
            //let staf = this.stafList.filter(it => it.staffName === item.name);
            this.scanFormData.itemOutNo = item.name;
            let itemOut = this.itemOutNoList.filter(it => it.billNo == item.name);
            this.invItemOutId = itemOut[0].id;
            this.invItemOutId = item.name;
            this.ItemBarKw = []; // 选择申请单号后清空库位列表
            this.getItem();
        },
        getItem() {
            var that = this;
            that.isLoading = true;
            let itemOut = this.itemOutNoList.filter(it => it.billNo == that.scanFormData.itemOutNo);
            //this.invItemOutId = itemOut[0].id;
            that.AxiosHttp("post", 'MesCgthSq/GetSumItem', {
                //id: that.invItemOutId,
                billNo: that.scanFormData.itemOutNo,
                barcode: that.scanFormData.barcode,
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        that.ItemDetail = json.data.tbBillList;
                        that.ItemDetail = {
                            items: json.data.tbBillList.items,
                            ysitems: json.data.tbBillList.ysitems,
                            allList: json.data.tbBillList.allList
                        };
                        that.$refs.barcode.focus();
                    }
                    else {
@@ -252,7 +307,7 @@
                        that.sendPrintMessage(json.data.tbBillList);
                        that.$refs.barcode.focus();
                    }
                    else {
                        that.$playSound('error');
H5/Js/Xsth.js
@@ -11,13 +11,13 @@
            billNo: "",
            depotSectionCode: "",
            barcode: "",
            itemNo:"",
            itemNo: "",
            modeInfo: [],
            active: 0,
            depot: {},
            show: false,
            actions: [],
            ItemTblDetail:[]
            ItemTblDetail: []
        }
    },
    mounted() {
@@ -139,7 +139,7 @@
            var that = this;
            that.isLoading = true;
            if (that.depotSectionCode.length * 1 <= 0) {
                that.$toast.fail("库位编码不能为空!");
H5/PurchaseReturn.aspx
@@ -8,6 +8,12 @@
</style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
            <van-notice-bar
    :scrollable="false"
    :text="'当前组织:' + (Cookies.get('orgName') || '暂无组织信息')"
    class="org-info"
/></van-notice-bar>
        <div class="content-wrapper">
    <van-nav-bar
  title="采购退料"
@@ -41,7 +47,7 @@
  <%--@change="SaveBarCodes"--%>
></van-field>
   <van-field
  v-model="scanFormData.itemNo"
  v-model="scanFormData.itemid"
  label="物料编码"
  placeholder="物料编码"
  disabled
@@ -70,7 +76,7 @@
</van-field>
</van-cell-group>
    </div>
  <van-tabs color="#000" title-active-color="#0283EF">
    <van-tabs color="#000" title-active-color="#0283EF">
    <van-tab title="待扫物料" class="mySolid font">
        <van-row>
            <van-col span="8" class="text-left padding-left">物料</van-col>
@@ -78,7 +84,12 @@
            <van-col span="3">待扫</van-col>
            <van-col span="5">推荐库位</van-col>
        </van-row>
        <van-row v-for="(itm,index) in ItemDetail.items" :key="index">
        <!-- 增加行点击与选中高亮 -->
            <van-row
            v-for="(itm,index) in ItemDetail.items"
            :key="index"
            :style="{ background: currentIndex === index ? '#87CEEB' : '' }"
            @click.native="handleRowClick(itm, index)">
            <van-col span="8" class="text-left padding-left">
                <div class="blue-text">{{itm.itemNo}}</div>
                <div>{{itm.itemName}}</div>
@@ -91,6 +102,25 @@
        </van-row>
    </van-tab>
                          <van-tab title="库位列表" class="mySolid font">
                <van-row>
                    <van-col span="10" class="text-left padding-left">条码编号</van-col>
                    <van-col span="5" class="text-left padding-left">库位</van-col>
                    <van-col span="4">数量</van-col>
                    <van-col span="5">仓库</van-col>
                </van-row>
                <van-row v-for="(itm,index) in ItemBarKw" :key="index">
                    <van-col span="10" class="text-left padding-left">
                        <div class="blue-text">{{itm.iteM_BARCODE}}</div>
                    </van-col>
                    <van-col span="5" class="text-left padding-left">
                        <div>{{itm.depoT_SECTIONS_CODE}}</div>
                    </van-col>
                    <van-col span="4" class="blue-text">{{itm.quantity}}</van-col>
                    <van-col span="5" >{{itm.depot_name}}</van-col>
                </van-row>
            </van-tab>
    <van-tab title="已扫物料" class="mySolid font">
        <van-row>
            <van-col span="8" class="text-left padding-left">物料</van-col>
@@ -100,7 +130,7 @@
        </van-row>
        <van-row v-for="(itm,index) in ItemDetail.ysitems" :key="index">
            <van-col span="8" class="text-left padding-left">
                <div class="blue-text">{{itm.itemNo}}</div>
                <div class="blue-text">{{itm.itemid}}</div>
                <div>{{itm.itemName}}</div>
            </van-col>
            <van-col span="8" class="text-left padding-left">
@@ -123,5 +153,5 @@
    <%--<comback ></comback>--%>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolder4" Runat="Server">
    <script src="Js/PurchaseReturn.js?<%=1281111111 %>"></script>
    <script src="Js/PurchaseReturn.js?<%=1281111234 %>"></script>
</asp:Content>
Mst.master
@@ -11,7 +11,7 @@
    <script src="/Scripts/vue.min.js"></script>
    <script src="/Scripts/js.cookie.min.js"></script>
    <script src="/scripts/axios0.25.0.js"></script>
    <script src="/scripts/config.js?<%=123611137 %>"></script>
    <script src="/scripts/config.js?<%=1236111372 %>"></script>
   <!-- <script src="/scripts/config.js?<%=DateTime.Now.Ticks %>"></script>-->
    <link href="/scripts/vant/vant.css" rel="stylesheet" />
    <script src="/scripts/vant/vant.js"></script>
UserLogin.aspx
@@ -93,5 +93,6 @@
  <comloading  v-if="isLoading"></comloading>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="ContentPlaceHolder4" runat="Server">
    <script src="/H5/Js/UserLogin.js?<%=1246 %>"></script>
</asp:Content>