1
chenjingwu
2024-04-11 3e13c5ebd0f27f18170078a56fb700e034b7d1ae
1
1个文件已修改
40 ■■■■■ 已修改文件
force-app/main/default/classes/lexNewQuoteEntryController.cls 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
force-app/main/default/classes/lexNewQuoteEntryController.cls
@@ -1760,6 +1760,10 @@
    List<string> xlslist = New list<string>();
    List<string> codelist = New List<string>();
    List<Integer> Quantitylist = New List<Integer>();
    // chenjingwu 20240411 start
    List<Integer> exYearList = New List<Integer>();
    Integer xlsExYear;
    // chenjingwu 20240411 end
    //String str ;
    Map<String, Integer> mp = new Map<String, Integer>();
@@ -1776,7 +1780,8 @@
          system.debug('xlslist+++'+xlslist);
          for (String s : xlslist) {
            //odd number or even number
            if (math.mod(i, 2) != 0) {
            // chenjingwu 20240411 start
            if (math.mod(i, 3) == 0) {
              system.debug('xlslist1+++'+s);
              //odd number
              if (s == '' || s == null) {
@@ -1790,7 +1795,7 @@
                xlsQuantity = Integer.valueOf(s);
                Quantitylist.add(xlsQuantity);
              }
            } else {
            } else if(math.mod(i, 3) == 1){
              system.debug('xlslist2+++'+s);
              //even number
              if (s == '' || s == null) {
@@ -1804,6 +1809,20 @@
                codelist.add(s);
                xlscode = s;
              }
            }else if(math.mod(i, 3) == 2){
              //even number
              if (s == '' || s == null) {
                errorflg = true;
                errormessage = System.Label.Error_Message31;
                activities = tmpactivities;
                // pageArrange();
                return errormessage+'---'+JSON.serialize(activities);
              } else {
                s = s.trim();
                xlsExYear = Integer.valueOf(s);
                exYearList.add(xlsExYear);
              }
              // chenjingwu 20240411 end
            }
            i++;
          }
@@ -1822,8 +1841,9 @@
    system.debug(j);
    system.debug('xlscnt:::::' + xlscnt);
    if (codelist.size() == 0 || Quantitylist.size() == 0) {
    // chenjingwu 20240411 start
    if (codelist.size() == 0 || Quantitylist.size() == 0 || exYearList.size() == 0) {
      // chenjingwu 20240411 end
      activities = tmpactivities;
      errorflg = true;
      system.debug('codelist+++'+codelist);
@@ -1909,6 +1929,9 @@
                            //chenjingwu DB202308355043 2023.8.25 start
                            , prd.Category5__c
                            //chenjingwu DB202308355043 2023.8.25 end
                            //chenjingwu  20240411 start
                            , exYearList[l]
                            //chenjingwu  20240411 end
                            //fy DB202312538864 2024.02.02 start
                            ,prd.LastbuyProductFLG__c
                            ,prd.whetherOldCode_PrePro__c
@@ -1935,6 +1958,9 @@
                            //chenjingwu DB202308355043 2023.8.25 start
                            , prd.Category5__c
                            //chenjingwu DB202308355043 2023.8.25 end
                            //chenjingwu  20240411 start
                            , exYearList[l]
                            //chenjingwu  20240411 end
                            //fy DB202312538864 2024.02.02 start
                            ,prd.LastbuyProductFLG__c
                            ,prd.whetherOldCode_PrePro__c
@@ -3134,6 +3160,9 @@
                //chenjingwu DB202308355043 2023.8.25 start
                ,String Category5
                //chenjingwu DB202308355043 2023.8.25 end
                //chenjingwu  20240411 start
                , Integer exYear
                //chenjingwu  20240411 end
                //fy DB202312538864 2024.02.02 start
                ,Boolean lastbuyProductFLG
                ,Boolean whetherOldCode_PrePro
@@ -3144,6 +3173,9 @@
               ) {
          pageObject = New QuoteLineItem();
          pageObject.Quantity__c = Quantity;
          //chenjingwu  20240411 start
          pageObject.ExtendedWarrantyPeriod__c = exYear;
          //chenjingwu  20240411 end
          this.lineNo = i;
          this.Asset_Model = Asset_Model;
          this.Sales_Possibility = Sales_Possibility_c;