buli
2023-06-05 0f44cb1a0b7b36860e9ce81c1eac9e395d87f0b4
force-app/main/default/classes/ArriveGoodsController.cls
@@ -142,8 +142,8 @@
                consumableorderdetailsRecordsview.add(recordsdummy);
            }
            // Integer count = recordsdummy.size() / 1000;
            // Integer last = recordsdummy.size() - (1000*count);
      // Integer count = recordsdummy.size() / 1000;
      // Integer last = recordsdummy.size() - (1000*count);
            // for(Integer i = 0; i < count ; i++){
            //     List<ConsumableorderdetailsInfo> tempList = new List<ConsumableorderdetailsInfo>();
@@ -316,18 +316,18 @@
        HosErrorMap = new Map<String,String>();
        //add by rentx 2021-01-27 end
        noboxBarcodeList.clear();
        //再检索项目清空
        ConsumableorderdetailsRecordserror = new List<ConsumableorderdetailsInfo>();
        ErrorIdMap = new Map<String, String>();
        ErrorIdMap.clear();
        AllMap = new Map<String, String>();
        AllMap.clear();
        ExistIdMap = new Map<String, String>();
        ExistIdMap.clear();
        consumableorderdetails2Insert = new List<Consumable_order_details2__c>();
        ConsumableorderdetailsRecordsdummy = new List<ConsumableorderdetailsInfo>();
        /*if(EsetId != null && EsetId != ''){
    noboxBarcodeList.clear();
    //再检索项目清空
    ConsumableorderdetailsRecordserror = new List<ConsumableorderdetailsInfo>();
    ErrorIdMap = new Map<String, String>();
    ErrorIdMap.clear();
    AllMap = new Map<String, String>();
    AllMap.clear();
    ExistIdMap = new Map<String, String>();
    ExistIdMap.clear();
    consumableorderdetails2Insert = new List<Consumable_order_details2__c>();
    ConsumableorderdetailsRecordsdummy = new List<ConsumableorderdetailsInfo>();
    /*if(EsetId != null && EsetId != ''){
            List<Consumable_order_details2__c> reSet1 = [SELECT Id,
                            Name,
                            Intra_Trade_List_RMB__c,
@@ -885,8 +885,6 @@
                        WHERE Dealer_Arrive__c = FALSE 
                        AND  Dealer_Shipment__c= FALSE
                        AND  Dealer_Saled__c = FALSE
                        // gzw fix 取消产品判断为未入库 20230323
                        AND Cancellation_Flag__c = false
                        AND  Dealer_Returned__c = false
                        AND  Bar_Code__c in :BarCodeListP
                        AND Dealer_Info_text__c = :accountName
@@ -1028,24 +1026,10 @@
                    }else{
                        Matcher n = Pattern.compile('[0-9]').matcher(reSet[i].TracingCode__c);
                        if(n.find()){
                            // gzw DB202305352696 入库管理编码验证程序调整 start
                            if (reSet[i].TracingCode__c.length() == 5) {
                                String tr = reSet[i].TracingCode__c;
                                String Ctr = tr.substring(tr.length() - 3,tr.length());
                                String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                    String str = '管理编码有误,请检查条形码数据。';
                                    ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                                    ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                                    continue;
                                }
                            }
                            // String str = '管理编码中有数字,请与管理员确认是否错误。';
                            // ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            // ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            // continue;
                            // gzw DB202305352696 入库管理编码验证程序调整 end
                            String str = '管理编码中有数字,请与管理员确认是否错误。';
                            ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            continue;
                        }
                        if(otherAgencyMap.containsKey(reSet[i].Bar_Code__c)){
                            for (Integer j=0; j<consumableInventory.size(); j++) {
@@ -1125,24 +1109,11 @@
                        continue;
                    }else{
                        Matcher n = Pattern.compile('[0-9]').matcher(reSet[i].TracingCode__c);
                        if(n.find()){// gzw DB202305352696 入库管理编码验证程序调整 start
                            if (reSet[i].TracingCode__c.length() == 5) {
                                String tr = reSet[i].TracingCode__c;
                                String Ctr = tr.substring(tr.length() - 3,tr.length());
                                String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                    String str = '管理编码有误,请检查条形码数据。';
                                    ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                                    ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                                    continue;
                                }
                            }
                            // String str = '管理编码中有数字,请与管理员确认是否错误。';
                            // ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            // ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            // continue;
                            // gzw DB202305352696 入库管理编码验证程序调整 end
                        if(n.find()){
                            String str = '管理编码中有数字,请与管理员确认是否错误。';
                            ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            continue;
                        }
                        ExistIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                        for(String str : barMcodeMap.keySet()){
@@ -1448,24 +1419,10 @@
                    }else{
                        Matcher n = Pattern.compile('[0-9]').matcher(reSet[i].TracingCode__c);
                        if(n.find()){
                            // gzw DB202305352696 入库管理编码验证程序调整 start
                            if (reSet[i].TracingCode__c.length() == 5) {
                                String tr = reSet[i].TracingCode__c;
                                String Ctr = tr.substring(tr.length() - 3,tr.length());
                                String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                    String str = '管理编码有误,请检查条形码数据。';
                                    ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                                    ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                                    continue;
                                }
                            }
                            // String str = '管理编码中有数字,请与管理员确认是否错误。';
                            // ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            // ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            // continue;
                            // gzw DB202305352696 入库管理编码验证程序调整 end
                            String str = '管理编码中有数字,请与管理员确认是否错误。';
                            ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            continue;
                        }
                        ConsumableorderdetailsRecordsdummy.add(new ConsumableorderdetailsInfo(reSet[i]));
                        ConsumableorderdetailsRecords.add(new ConsumableorderdetailsInfo(reSet[i]));
@@ -1524,24 +1481,10 @@
                    }else{
                        Matcher n = Pattern.compile('[0-9]').matcher(reSet[i].TracingCode__c);
                        if(n.find()){
                            // gzw DB202305352696 入库管理编码验证程序调整 start
                            if (reSet[i].TracingCode__c.length() == 5) {
                                String tr = reSet[i].TracingCode__c;
                                String Ctr = tr.substring(tr.length() - 3,tr.length());
                                String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                    String str = '管理编码有误,请检查条形码数据。';
                                    ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                                    ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                                    continue;
                                }
                            }
                            // String str = '管理编码中有数字,请与管理员确认是否错误。';
                            // ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            // ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            // continue;
                            // gzw DB202305352696 入库管理编码验证程序调整 end
                            String str = '管理编码中有数字,请与管理员确认是否错误。';
                            ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(reSet[i],str));
                            ErrorIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                            continue;
                        }
                        ExistIdMap.put(reSet[i].Bar_Code__c,reSet[i].Bar_Code__c);
                        for(String str : barMcodeMap.keySet()){
@@ -1594,7 +1537,7 @@
        }
        //add by rentx 2021-01-27 end
        makeArrivedSummary();
    makeArrivedSummary();
        //add by rentx 20210602 start CHAN-C3K4ZQ
@@ -1711,22 +1654,9 @@
                            tracingCode = barCodeList[i].substring(barCodeList[i].length() - 5,barCodeList[i].length());
                            Matcher n = Pattern.compile('[0-9]').matcher(tracingCode);
                            if(n.find()){
                                // gzw DB202305352696 入库管理编码验证程序调整 start
                                if (tracingCode.length() == 5) {
                                    String tr = tracingCode;
                                    String Ctr = tr.substring(tr.length() - 3,tr.length());
                                    String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                    String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                    if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                        String str = '管理编码有误,请检查条形码数据。';
                                        ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')管理编码有误,请检查条形码数据。'));
                                        continue;
                                    }
                                }
                                // String str = '管理编码不正确,请与管理员确认是否错误。';
                                // ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')管理编码中有数字,请与管理员确认是否错误!'));
                                // continue;
                                // gzw DB202305352696 入库管理编码验证程序调整 end
                                String str = '管理编码不正确,请与管理员确认是否错误。';
                                ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')管理编码中有数字,请与管理员确认是否错误!'));
                                continue;
                            }
                        }else{
                            ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')的tracingCode错误!'));
@@ -1978,22 +1908,9 @@
                                        tracingCode = bar.substring(bar.length() - 5,bar.length());
                                        Matcher n = Pattern.compile('[0-9]').matcher(tracingCode);
                                        if(n.find()){
                                            // gzw DB202305352696 入库管理编码验证程序调整 start
                                            if (tracingCode.length() == 5) {
                                                String tr = tracingCode;
                                                String Ctr = tr.substring(tr.length() - 3,tr.length());
                                                String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                                String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                                if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                                    String str = '管理编码有误,请检查条形码数据。';
                                                    ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')管理编码有误,请检查条形码数据。'));
                                                    continue;
                                                }
                                            }
                                            // String str = '管理编码不正确,请与管理员确认是否错误。';
                                            // ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')管理编码中有数字,请与管理员确认是否错误!'));
                                            // continue;
                                            // gzw DB202305352696 入库管理编码验证程序调整 end
                                            String str = '管理编码不正确,请与管理员确认是否错误。';
                                            ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')管理编码中有数字,请与管理员确认是否错误!'));
                                            continue;
                                        }
                                    }else{
                                        ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')的tracingCode错误!'));
@@ -2143,22 +2060,9 @@
                        tracingCode = barCodeList[i].substring(barCodeList[i].length() - 5,barCodeList[i].length());
                        Matcher n = Pattern.compile('[0-9]').matcher(tracingCode);
                        if(n.find()){
                            // gzw DB202305352696 入库管理编码验证程序调整 start
                            if (tracingCode.length() == 5) {
                                String tr = tracingCode;
                                String Ctr = tr.substring(tr.length() - 3,tr.length());
                                String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                    String str = '管理编码有误,请检查条形码数据。';
                                    ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')管理编码有误,请检查条形码数据。'));
                                    continue;
                                }
                            }
                            // String str = '管理编码不正确,请与管理员确认是否错误。';
                            // ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')管理编码中有数字,请与管理员确认是否错误!'));
                            // continue;
                            // gzw DB202305352696 入库管理编码验证程序调整 end
                            String str = '管理编码不正确,请与管理员确认是否错误。';
                            ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')管理编码中有数字,请与管理员确认是否错误!'));
                            continue;
                        }
                    }else{
                        ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + barCodeList[i] + ')的tracingCode错误!'));
@@ -2433,22 +2337,9 @@
                                tracingCode = bar.substring(bar.length() - 5,bar.length());
                                Matcher n = Pattern.compile('[0-9]').matcher(tracingCode);
                                if(n.find()){
                                    // gzw DB202305352696 入库管理编码验证程序调整 start
                                    if (tracingCode.length() == 5) {
                                        String tr = tracingCode;
                                        String Ctr = tr.substring(tr.length() - 3,tr.length());
                                        String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                        String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                        if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                            String str = '管理编码有误,请检查条形码数据。';
                                            ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')管理编码有误,请检查条形码数据。'));
                                            continue;
                                        }
                                    }
                                    // String str = '管理编码不正确,请与管理员确认是否错误。';
                                    // ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')管理编码中有数字,请与管理员确认是否错误!'));
                                    // continue;
                                    // gzw DB202305352696 入库管理编码验证程序调整 end
                                    String str = '管理编码不正确,请与管理员确认是否错误。';
                                    ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')管理编码中有数字,请与管理员确认是否错误!'));
                                    continue;
                                }
                            }else{
                                ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'产品BarCode(' + bar + ')的tracingCode错误!'));
@@ -2565,8 +2456,8 @@
    }
    public void confimResultWithoutOrder() {
        /*list<String> overOrderproList = new list<String>();
  public void confimResultWithoutOrder() {
    /*list<String> overOrderproList = new list<String>();
        list<String> overOrderBARcodeCunList = new list<String>();
        orderProductCunMap.clear();
        orderProductArrivedCunMap.clear();
@@ -2620,7 +2511,7 @@
            /*orderWantArriveCunMap.put(ass.esd.Consumable_order_minor__c + ass.esd.Asset_Model_No__c,orderWantArriveCunMap.get(ass.esd.Consumable_order_minor__c + ass.esd.Asset_Model_No__c)+1);
        }
        return overOrderproList;*/
    }
  }
    // WYIN-BLZE48盘点丢失产品增加入库方式 update by vivek 2020-03-05 start
    // 虚拟盘点单消耗品明细1创建巡回
@@ -2772,11 +2663,11 @@
                ins.Used_date__c = Date.today();
                ins.OwnerId = arriveAccount.OwnerId;
                insDetail1.add(ins);
            }
            insDetail1Map.put(acc, insDetail1);
        }
        insert orderList;
        insDetail1.add(ins);
      }
      insDetail1Map.put(acc, insDetail1);
    }
    insert orderList;
        List<Id> orderIdList = new List<Id> ();
        for (Consumable_order__c co : orderList) {
@@ -2803,29 +2694,31 @@
                insDetail1List.add(dtl1);
            }
            // 明细2
            List<Consumable_order_details2__c> d2list = accountGroupMap.get(setId.Dealer_Info__r.Name + setId.Order_Owner_WorkLocal__c);
            for (Consumable_order_details2__c dtl2 : d2list) {
                dtl2.Send_Date__c = Date.today();
                dtl2.Consumable_Sale_order__c = null;
                dtl2.Consumable_Return_order__c = null;
                dtl2.Consumable_ZS_order__c = setId.Id;
                //dtl2.Delivery_List_RMB__c = null;
                dtl2.Return_date__c = null;
                dtl2.Return_reason__c = null;
                dtl2.Consumable_Shipment_order__c = setId.Id;
                // 更新借调信息 add by gzw 2020-0-415 start
                dtl2.Transfer_Time__c = 1;
                dtl2.Agency_Transfer__c = true;
                dtl2.Frist_Transfer_Agency__c = dtl2.Dealer_Info_text__c;
                // 更新借调信息 add by gzw 2020-0-415 end
                updDetail2List.add(dtl2);
            }
        }
        insert insDetail1List;
        update updDetail2List;
      // 明细2
      List<Consumable_order_details2__c> d2list = accountGroupMap.get(
        setId.Dealer_Info__r.Name + setId.Order_Owner_WorkLocal__c
      );
      for (Consumable_order_details2__c dtl2 : d2list) {
        dtl2.Send_Date__c = Date.today();
        dtl2.Consumable_Sale_order__c = null;
        dtl2.Consumable_Return_order__c = null;
        dtl2.Consumable_ZS_order__c = setId.Id;
        //dtl2.Delivery_List_RMB__c = null;
        dtl2.Return_date__c = null;
        dtl2.Return_reason__c = null;
        dtl2.Consumable_Shipment_order__c = setId.Id;
        // 更新借调信息 add by gzw 2020-0-415 start
        dtl2.Transfer_Time__c = 1;
        dtl2.Agency_Transfer__c = true;
        dtl2.Frist_Transfer_Agency__c = dtl2.Dealer_Info_text__c;
        // 更新借调信息 add by gzw 2020-0-415 end
        updDetail2List.add(dtl2);
      }
    }
    insert insDetail1List;
    update updDetail2List;
  }
    //到货确认
    public PageReference ArriveGoodsConfim() {
@@ -2982,9 +2875,9 @@
                }
            }
            if (addSaleOrderList.size() > 0) {
                addSaleOrderAuto(addSaleOrderList);
            }
      if (addSaleOrderList.size() > 0) {
        addSaleOrderAuto(addSaleOrderList);
      }
            if(updateconsumableorderdetails2.size() > 0){
                update updateconsumableorderdetails2;
@@ -3215,24 +3108,10 @@
                Matcher n = Pattern.compile('[0-9]').matcher(codc.TracingCode__c);
                if(n.find()){
                    // gzw DB202305352696 入库管理编码验证程序调整 start
                            if (codc.TracingCode__c.length() == 5) {
                                String tr = codc.TracingCode__c;
                                String Ctr = tr.substring(tr.length() - 3,tr.length());
                                String Btr = tr.substring(tr.length() - 4,tr.length()-3);
                                String Atr = tr.substring(tr.length() - 5,tr.length()-4);
                                if (Pattern.compile('[0-9]').matcher(Atr).find() || Pattern.compile('[0-9]').matcher(Ctr).find()) {
                                    String str = '管理编码有误,请检查条形码数据。';
                                    ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(codc,str));
                                    ErrorIdMap.put(codc.Bar_Code__c,codc.Bar_Code__c);
                                    continue;
                                }
                            }
                            // String str = '管理编码中有数字,请与管理员确认是否错误。';
                            // ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(codc,str));
                            // ErrorIdMap.put(codc.Bar_Code__c,codc.Bar_Code__c);
                            // continue;
                            // gzw DB202305352696 入库管理编码验证程序调整 end
                    String str = '管理编码中有数字,请与管理员确认是否错误。';
                    ConsumableorderdetailsRecordserror.add(new ConsumableorderdetailsInfo(codc,str));
                    ErrorIdMap.put(codc.Bar_Code__c,codc.Bar_Code__c);
                    continue;
                }
                if( CheckBarcodeResult.containsKey( codc.Bar_Code__c    )){
                    GrList.add(codc.Bar_Code__c);
@@ -3259,8 +3138,8 @@
            }
        }
        return BarcodeRetrunResult.size();
    }
    return BarcodeRetrunResult.size();
  }
    // 单位为个的Barcode对应的出库单
    public integer Getconsumableorderdetails2Nobox(){
@@ -3670,7 +3549,7 @@
                    // tcm end
                    //add by rentx 2020-10-14 end
                    codcorderdetList.add(codcorderdetail);
          codcorderdetList.add(codcorderdetail);
                    //返品明细
                    retorddetail.Return_reason__c            = ass.ReturnReason;
@@ -3715,12 +3594,12 @@
                    // tcm end
                    //add by rentx 2020-10-14 end
                    codcorderdetList.add(retorddetail);
                    i++;
                }
          codcorderdetList.add(retorddetail);
          i++;
        }
                // ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'------end------'));
                // return null;
        // ApexPages.addmessage(new ApexPages.message(ApexPages.severity.ERROR,'------end------'));
        // return null;
                if(codcList.size()>0){
                    ControllerUtil.updateOrderDetailsSatus(   codcList    );
@@ -3809,9 +3688,9 @@
            // ApexPages.addMessages(e);
            // ApexPages.addMessages(e.getLineNumber() + '  11111111111111111');
            //return null;
        }
      //return null;
    }
  }
    //跳转到返品页面
    public Pagereference ToReturnGoodsPage(){
@@ -3835,22 +3714,22 @@
        return ref;
    }
    class ConsumableorderdetailsInfo implements Comparable {
        public Consumable_order_details2__c esd { get; set; }
        public Product2__c Prod { get; set; }
        public String ProductName { get; set; }
        //public Boolean canSELECT { get; set; }
        public String barCodeNo { get; set; }
        public Date sterilizationlimitDate { get; set; }
        public String serialNoorLotNo { get; set; }
        public String tracingCodeNo { get; set; }
        public String ReturnReason { get; set; }
        public String oldConsumableCount { get; set; }
        public String ErrorReason { get; set; }
        public boolean canEdit { get; set; }
        public Integer intMark { get; set; }
        public Decimal arriveAmount { get; set; }
        public Decimal arrivedCount { get; set; }
  public class ConsumableorderdetailsInfo implements Comparable {
    public Consumable_order_details2__c esd { get; set; }
    public Product2__c Prod { get; set; }
    public String ProductName { get; set; }
    //public Boolean canSELECT { get; set; }
    public String barCodeNo { get; set; }
    public Date sterilizationlimitDate { get; set; }
    public String serialNoorLotNo { get; set; }
    public String tracingCodeNo { get; set; }
    public String ReturnReason { get; set; }
    public String oldConsumableCount { get; set; }
    public String ErrorReason { get; set; }
    public boolean canEdit { get; set; }
    public Integer intMark { get; set; }
    public Decimal arriveAmount { get; set; }
    public Decimal arrivedCount { get; set; }
        public String ReportProductExpirationDate {get;set;}
        public ConsumableorderdetailsInfo(Consumable_order_details2__c e,string str) {
@@ -3915,4 +3794,4 @@
            return null;
        }
    }
}
}