1
wangyi
2026-04-02 96785ebcfe1bc9210f3d9d4056f4ec29fb60d810
WebTM/views/³µ¼ä¹ÜÀí/µ¥Æ·¹ýÕ¾_СÎÀ/Cj_ProcessItemStationPlatform_checkPackage_Sec.html
@@ -966,40 +966,24 @@
            var rowIndex = $(obj.tr).attr("data-index");
            if (obj.event === 'del') {
                layer.confirm('真的删除行吗?', function (index) {
                    console.log("索引为:" + rowIndex);
                    var wait = layer.load();
                    //删除临时表数据
                    $.ajax({
                        url: GetWEBURL() + 'Deltet_Sc_AssemblyBill_BindBarCodeTemp',
                        type: "GET",
                        data: { "HBillNo": $("#HBillNo").val(), "HBarCode": option.data[rowIndex].HBarCode, "user": sessionStorage["HUserName"] },
                        success: function (result) {
                            if (result.count == 1) {
                                layer.msg(result.Message, { icon: 1, time: 500 }, function () {
                                    //关闭当前frame
                                    layer.close(wait);
                                });
                            } else {
                                layer.alert(result.code + result.Message, { icon: 5 });
                                layer.close(wait);
                            }
                        }, error: function () {
                            layer.alert("接口请求失败!", { icon: 5 });
                            layer.close(wait);
                        }
                    });
                    //刷新表格数据
                    option.data[rowIndex].HBarCode = "";
                    option.data[rowIndex].HBindingQty = 0;
                    //option.data[rowIndex].HMaterID = 0;
                    option.data[rowIndex].HMaterNumber = "";
                    option.data[rowIndex].HMaterName = "";
                    option.data[rowIndex].HMaterModel = "";
                    option.data[rowIndex].HBarCode = "";
                    var oldData = table.cache["mainTable"];
                    oldData.splice(obj.tr.data('index'), 1);
                    option.data = oldData;
                    table.render(option);
                    rowarr = [];
                    for (var i = 0; i < option.data.length; i++) {
                        rowarr.push({
                            "HBarCode_P": option.data[i].HBarCode_P, "HPartsBarCode": "", "HPartsQty": option.data[i].HPartsQty, "HBindingQty": 0
                            , "HMaterID": option.data[i].HMaterID, "HMaterNumber": option.data[i].HMaterNumber, "HMaterName": option.data[i].HMaterName, "HMaterModel": option.data[i].HMaterModel, "HBatchNo": ""
                            , "HSourceID": $("#HSourceID").val(), "HEquipID": 0, "HGroupID": $("#HGroupID").val(), "HWorkerID": $("#HEmpID").val()
                            , "HScanDate": new Date(), "HSourceInterID": $("#HICMOInterID").val()
                            , "HSourceEntryID": $("#HICMOEntryID").val(), "HSourceBillNo": $("#HICMOBillNo").val()
                        });
                    }
                    layer.close(index);
                });
            }