1
TableHandler.prototype.IsAlreadySelected = function(dataToCheck) 
{
    var _this = this;

    if (_this.NewTemplateUsageSelected.length > 0) 
    {
        var len = _this.NewTemplateUsageSelected.length;
        for (var i = 0; i < len; i++) 
        {
            var an = _this.NewTemplateUsageSelected[i];
            var isTemplateUsageDataDuplicate=false; 
            var isNonApplicableCGDataDuplicate=false; 
            if ((an.CustomerName == dataToCheck.CustomerName) &&
                (an.ProgramName == dataToCheck.ProgramName) &&
                (an.WorkpackageName == dataToCheck.WorkpackageName) &&
                (an.ActivityName == dataToCheck.ActivityName) &&
                (an.SelectedWorkFlowType == dataToCheck.SelectedWorkFlowType) &&
                (an.SelectedWorkFlowCategory == dataToCheck.SelectedWorkFlowCategory) &&
                (an.ReWorkflow== dataToCheck.ReWorkflow) &&
                (an.AllowCheckGroupSelection == dataToCheck.AllowCheckGroupSelection) &&
                (an.InitiatorGroupSelection == dataToCheck.InitiatorGroupSelection) &&
                (an.R1GroupSelection == dataToCheck.R1GroupSelection) &&
                (an.R2GroupSelection == dataToCheck.R2GroupSelection) &&
                (an.R3GroupSelection == dataToCheck.R3GroupSelection) &&
                (an.R4GroupSelection == dataToCheck.R4GroupSelection) &&    
                (an.InitiatorMinReworkEffort == dataToCheck.InitiatorMinReworkEffort) &&
                (an.R1MinReworkEffort == dataToCheck.R1MinReworkEffort) &&
                (an.R2MinReworkEffort == dataToCheck.R2MinReworkEffort) &&
                (an.R3MinReworkEffort == dataToCheck.R3MinReworkEffort) &&
                (an.R4MinReworkEffort == dataToCheck.R4MinReworkEffort) &&                               
                (an.AllowFileAttachment == dataToCheck.AllowFileAttachment) &&
                (an.QualityReviewer== dataToCheck.QualityReviewer) &&
                (an.AllowLiabiltySelection == dataToCheck.AllowLiabiltySelection)&&
                (an.SetToInactive == dataToCheck.SetToInactive)&&
                (an.NonApplicabilityCheckGroupAllowed == dataToCheck.NonApplicabilityCheckGroupAllowed))
                    {
                    istemplateusagedataduplicate=true;
                    }  

                var checkgroupslendataToCheck=dataToCheck.NonApplicableCheckGroupList.length;               
              var nalen=an.NonApplicableCheckGroupList.length;
              if(checkgroupslendataToCheck  == nalen )  
              {
        for (var i = 0 ;i < checkgroupslendataToCheck ; i++)
               {

               var naDatatocheck= dataToCheck.NonApplicableCheckGroupList[i];
               var naData=an.NonApplicableCheckGroupList[i];
               if(            
                                  ( naDatatocheck.INonApplicability == naData.INonApplicability )&&
                                  ( naDatatocheck.R1NonApplicability == naData.R1NonApplicability )&&
                                  ( naDatatocheck.R2NonApplicability == naData.R2NonApplicability) &&
                                  ( naDatatocheck.R3NonApplicability == naData.R3NonApplicability )&&
                                  ( naDatatocheck.R4NonApplicability == naData.R4NonApplicability))
                                                                   isNonApplicableCGDataDuplicate=true;
                                   else
                                  {
                                   isNonApplicableCGDataDuplicate=false;
                                   break;
                                  }

                   }
                   if(isNonApplicableCGDataDuplicate==true && istemplateusagedataduplicate==true)
                   return true;

               } 
               }
               }
               };   

上記のコードはエラーを引き起こしていますインターネットが遅くなる可能性があります。解決策を探したとき、レジストリやIEバージョンの変更、コードのcdebehindへの移動、プラグインの使用などの解決策がありました。これは、私たちのプロジェクトでは実行できません。したがって、上記のロジックを変更する必要があります.2つのネストされたリストをキャンプするために使用できるjavascriptまたはjqueryの組み込み関数。

4

1 に答える 1