| | |
| | | @AuraEnabled public Map<String,String> fieldsMap{get;set;} |
| | | @AuraEnabled public Map<String,List<Map<String,String>>> docmap{get;set;} |
| | | @AuraEnabled public List<Map<String,String>> doctorList{get;set;} |
| | | |
| | | // PIPL update Yin Mingjie 21/02/2022 start |
| | | @AuraEnabled public Map<String,String> awsurl{get;set;} |
| | | // PIPL update Yin Mingjie 21/02/2022 end |
| | | public WeeklyReportCmp() { |
| | | } |
| | | // PIPL update Yin Mingjie 21/02/2022 start |
| | | @RemoteAction |
| | | @AuraEnabled |
| | | public static Map<String,String> getAwsurl(String sobj){ |
| | | PIHelper.PIIntegration piIntegration = PIHelper.getPIIntegrationInfo(sobj); |
| | | Map<String,String> awsmap = new Map<String,String>(); |
| | | awsmap.put('token', piIntegration.token); |
| | | awsmap.put('newUrl', piIntegration.newUrl); |
| | | awsmap.put('searchUrl', piIntegration.searchUrl); |
| | | awsmap.put('transactionURL', piIntegration.transactionURL); |
| | | return awsmap; |
| | | } |
| | | |
| | | @RemoteAction |
| | | @AuraEnabled |
| | | public static Map<String, String> saveAgencyContact(String name, String nameEncrypt, String type, String typeEncrypt, String doctorDivision1, |
| | | String doctorDivision1Encrypt, String agencyHospitalid, String awsid) { |
| | | Agency_Contact__c agency_contact = new Agency_Contact__c(); |
| | | |
| | | agency_contact.Name = name; |
| | | agency_contact.Name_Encrypted__c = nameEncrypt; |
| | | agency_contact.Type__c = type; |
| | | agency_contact.Type_Encrypted__c = typeEncrypt; |
| | | agency_contact.Doctor_Division1__c = doctorDivision1; |
| | | agency_contact.Doctor_Division1_Encrypted__c = doctorDivision1Encrypt; |
| | | agency_contact.Agency_Hospital__c = agencyHospitalid; |
| | | agency_contact.AWS_Data_Id__c = awsid; |
| | | |
| | | Map<String, String> acMap = new Map<String, String>(); |
| | | |
| | | acMap = LightningUtil.insertAgencyContact(agency_contact); |
| | | return acMap; |
| | | } |
| | | // PIPL update Yin Mingjie 21/02/2022 end |
| | | @RemoteAction |
| | | @AuraEnabled |
| | | public static List<Map<String,String>> getProductList(String dc, String opdsis){ |
| | |
| | | |
| | | //System.debug('fieldsMap is ' + fieldsMap); |
| | | //System.debug('allselectlist is ' + this.allselectlist); |
| | | |
| | | this.awsurl = getAwsurl('Agency_Contact__c');// 20220222 PI改造 by Bright |
| | | } |
| | | |
| | | |
| | |
| | | |
| | | @RemoteAction |
| | | @AuraEnabled |
| | | // PIPL update Yin Mingjie 21/02/2022 start |
| | | public static Map<String,Map<String,String>> getDoctorList(String hospital_id){ |
| | | /* |
| | | public static List<Map<String,String>> getDoctorList(String hospital_id){ |
| | | List<Map<String,String>> ret = new List<Map<String,String>>(); |
| | | Map<String,String> space = new Map<String,String>(); |
| | |
| | | space.put('value', ''); |
| | | space.put('selected', 'true'); |
| | | ret.add(space); |
| | | */ |
| | | // PIPL update Yin Mingjie 21/02/2022 end |
| | | |
| | | // 戦略科室IDを取得して、それをもとに顧客をSELECT |
| | | Agency_Hospital_Link__c ahl = [select Hospital__c from Agency_Hospital_Link__c where id = :hospital_id]; |
| | | |
| | | // PIPL update Yin Mingjie 21/02/2022 start |
| | | /* |
| | | List<Agency_Contact__c> doctor_list = [select id,Name,Doctor_Division1__c,Type__c,Agency_Hospital__c |
| | | FROM Agency_Contact__c WHERE Hospital_ID18__c=:ahl.Hospital__c order by Name]; |
| | | |
| | |
| | | tmp.put('Doctor_Division1__c', row.Doctor_Division1__c); |
| | | ret.add(tmp); |
| | | } |
| | | */ |
| | | List<Agency_Contact__c> doctor_list = [select id,Name,AWS_Data_Id__c,Doctor_Division1__c,Type__c,Agency_Hospital__c |
| | | FROM Agency_Contact__c WHERE Hospital_ID18__c=:ahl.Hospital__c order by Name]; |
| | | |
| | | Map<String,Map<String,String>> ret_test = new Map<String,Map<String,String>>(); |
| | | for (Agency_Contact__c row : doctor_list) |
| | | { |
| | | if(row.AWS_Data_Id__c == '' || row.AWS_Data_Id__c == null){ |
| | | continue; |
| | | } |
| | | Map<String,String> tmp = new Map<String,String>(); |
| | | tmp.put('label', row.Name); |
| | | tmp.put('value', row.Id); |
| | | tmp.put('awsid', row.AWS_Data_Id__c); |
| | | tmp.put('selected', 'false'); |
| | | tmp.put('Doctor_Division1__c', row.Doctor_Division1__c); |
| | | ret_test.put(row.AWS_Data_Id__c, tmp); |
| | | } |
| | | PIHelper.PIIntegration piIntegration = PIHelper.getPIIntegrationInfo('Agency_Contact__c'); |
| | | Map<String, String> sre = new Map<String, String>(); |
| | | sre.put('token', piIntegration.token); |
| | | sre.put('searchUrl', piIntegration.searchUrl); |
| | | ret_test.put('sre', sre); |
| | | |
| | | return ret_test; |
| | | // PIPL update Yin Mingjie 21/02/2022 end |
| | | /* |
| | | String record_type_id = LightningUtil.getRecordTypeId(department); |
| | | |
| | |
| | | } |
| | | */ |
| | | |
| | | // PIPL update Yin Mingjie 21/02/2022 start |
| | | /* |
| | | return ret; |
| | | */ |
| | | // PIPL update Yin Mingjie 21/02/2022 end |
| | | } |
| | | |
| | | /* |