| | |
| | | hasError = false; |
| | | ord = new Order(); |
| | | cc = new Order(); |
| | | List<Order> raList = [select Id, Name, Dealer__c,SplitRatio__c,SplitRatiotext__c,CrossCooperativeDealerText__c,SplitRatioFormule__c,BS_AsistGenManger_BS__c,ApproveStatus__c from Order where Id = :raid]; |
| | | List<Order> raList = [select Id, Name, Dealer__c,SplitRatio__c,CrossCooperativeDealerText__c,SplitRatioFormule__c,BS_AsistGenManger_BS__c,ApproveStatus__c from Order where Id = :raid]; |
| | | UsId = UserInfo.getUserId().subString(0, 15); |
| | | if (raList.size() > 0) { |
| | | ord = raList[0]; |
| | |
| | | AppSta = ''; |
| | | hasError = false; |
| | | ra1 = new Order(); |
| | | List<Order> ra1List = [select Id, Name, Dealer__c,Dealer_A__r.Name,Dealer_B__r.Name ,SplitRatio__c,SplitRatiotext__c,CrossCooperativeDealerText__c,SplitRatioFormule__c,BS_AsistGenManger_BS__c from Order where Id = :raid]; |
| | | List<Order> ra1List = [select Id, Name, Dealer__c,SplitRatio__c,CrossCooperativeDealerText__c,SplitRatioFormule__c,BS_AsistGenManger_BS__c from Order where Id = :raid]; |
| | | UsId = UserInfo.getUserId().subString(0, 15); |
| | | if (ra1List.size() > 0) { |
| | | ra1 = ra1List[0]; |
| | |
| | | public PageReference saveBtn() { |
| | | hasError = false; |
| | | String response = ra1.SplitRatio__c; |
| | | /* if (String.isBlank(ra1.SplitRatio__c)) { |
| | | String SplitRatiotext = ra1.Dealer_A__r.Name +' '+ ra1.SplitRatio__c +' '+ ra1.Dealer_B__r.Name; |
| | | ra1.SplitRatiotext__c = SplitRatiotext; |
| | | ra1. |
| | | update ra1; |
| | | if (String.isBlank(ra1.SplitRatio__c)) { |
| | | /*String SplitRatiotext = ra1.Dealer__c +' '+ ra1.SplitRatio__c +' '+ ra1.CrossCooperativeDealerText__c; |
| | | ra1.SplitRatiotext__c = SplitRatiotext;*/ |
| | | update ra1; |
| | | }else { |
| | | update ra1; |
| | | }*/ |
| | | ra1.dealer_A_Name__c = ra1.Dealer_A__r.Name; |
| | | ra1.dealer_B_Name__c = ra1.Dealer_B__r.Name; |
| | | update ra1; |
| | | } |
| | | |
| | | return null; |
| | | } |