public with sharing class AccountDelayApplyController { @AuraEnabled public static InitData init(String recordId){ InitData res = new initData(); try { Account report = [SELECT Id,Name,Is_Active__c,Grade__c,Alias_Name2__c,Abbreviation__c,Attribute_Type__c, //2023-10-12 新增 包含科室 WYL DB202306499625 start Including_departments__c, //2023-10-12 新增 包含科室 WYL DB202306499625 end // 2023-12-14 WYL add start Sparepartsdeliveryaddress1__c,Sparepartsdeliveryaddress2__c,Sparepartsdeliveryaddress3__c,Sparepartsdeliveryaddress4__c,Sparepartsdeliveryaddress5__c, Sparepartsdeliveryaddress6__c,Sparepartsdeliveryaddress7__c,Sparepartsdeliveryaddress8__c,Sparepartsdeliveryaddress9__c,Sparepartsdeliveryaddress10__c //2023-12-14 WYL add end ,Postal_Code__c,Speciality_Type__c,State_Master__c,Town__c,City_Master__c,Address__c,Street__c ,Field3_companyname__c,WhetherRiskPassing__c,RejectionReason__c,AssociatedHospital__c,site FROM Account WHERE Id = :recordId]; List AccQuery = [SELECT id FROM Account_Delay_Apply__c WHERE Is_Active__c = '申请中' and Hospital__c = :recordId]; res.accId = report.Id; res.accname = report.Name; res.status = report.Is_Active__c; res.accgrade = report.Grade__c; res.aliasName2 = report.Alias_Name2__c; res.abbreviation = report.Abbreviation__c; res.attributeType = report.Attribute_Type__c; res.postalCode = report.Postal_Code__c; res.specialityType = report.Speciality_Type__c; res.stateMaster = report.State_Master__c; res.town = report.Town__c; res.cityMaster = report.City_Master__c; res.address = report.Address__c; res.street = report.Street__c; res.field3companyname = report.Field3_companyname__c; res.WhetherRiskPassing = report.WhetherRiskPassing__c; res.rejectionReason = report.RejectionReason__c; res.associatedHospital = report.AssociatedHospital__c; res.site = report.site; res.shengId = report.State_Master__c; res.shiId = report.City_Master__c; // 2023-12-14 WYL add start res.Sparepartsdeliveryaddress1 = report.Sparepartsdeliveryaddress1__c; res.Sparepartsdeliveryaddress2 = report.Sparepartsdeliveryaddress2__c; res.Sparepartsdeliveryaddress3 = report.Sparepartsdeliveryaddress3__c; res.Sparepartsdeliveryaddress4 = report.Sparepartsdeliveryaddress4__c; res.Sparepartsdeliveryaddress5 = report.Sparepartsdeliveryaddress5__c; res.Sparepartsdeliveryaddress6 = report.Sparepartsdeliveryaddress6__c; res.Sparepartsdeliveryaddress7 = report.Sparepartsdeliveryaddress7__c; res.Sparepartsdeliveryaddress8 = report.Sparepartsdeliveryaddress8__c; res.Sparepartsdeliveryaddress9 = report.Sparepartsdeliveryaddress9__c; res.Sparepartsdeliveryaddress10 = report.Sparepartsdeliveryaddress10__c; // 2023-12-14 WYL add end //2023-10-12 新增 包含科室 WYL DB202306499625 start res.IncludingDepartments = report.Including_departments__c; //2023-10-12 新增 包含科室 WYL DB202306499625 end res.AccSize = AccQuery; } catch (Exception e) { throw new AuraHandledException(e.getMessage()); } return res; } public class InitData{ @AuraEnabled public String accId; @AuraEnabled public String accname; @AuraEnabled public String status; @AuraEnabled public String accgrade; @AuraEnabled public String aliasName2; @AuraEnabled public String abbreviation; @AuraEnabled public String attributeType; @AuraEnabled public String postalCode; @AuraEnabled public String specialityType; @AuraEnabled public String stateMaster; @AuraEnabled public String town; @AuraEnabled public String cityMaster; @AuraEnabled public String address; @AuraEnabled public String street; @AuraEnabled public String field3companyname; @AuraEnabled public String WhetherRiskPassing; @AuraEnabled public String rejectionReason; @AuraEnabled public String associatedHospital; @AuraEnabled public String site; @AuraEnabled public String shengId; //2023-10-12 新增 包含科室 WYL DB202306499625 start @AuraEnabled public String IncludingDepartments; //2023-10-12 新增 包含科室 WYL DB202306499625 end @AuraEnabled public String shiId; @AuraEnabled public List AccSize; // 2023-12-14 WYL add start @AuraEnabled public String Sparepartsdeliveryaddress1; @AuraEnabled public String Sparepartsdeliveryaddress2; @AuraEnabled public String Sparepartsdeliveryaddress3; @AuraEnabled public String Sparepartsdeliveryaddress4; @AuraEnabled public String Sparepartsdeliveryaddress5; @AuraEnabled public String Sparepartsdeliveryaddress6; @AuraEnabled public String Sparepartsdeliveryaddress7; @AuraEnabled public String Sparepartsdeliveryaddress8; @AuraEnabled public String Sparepartsdeliveryaddress9; @AuraEnabled public String Sparepartsdeliveryaddress10; // 2023-12-14 WYL add end } }