buli
2022-04-06 2d4a8d2dcad5a17127d2c73c48ddc4b67ec79448
force-app/main/default/classes/AgencyAccountCmp.cls
@@ -75,4 +75,52 @@
        return acList1;
    }
    @AuraEnabled
    public static void SaveLog(String module,String content,String status,String respMsg){
        string awsDataId = '';
        string sfId = '';
        string transId = '';
        try {
            Map<string,object> mso = (Map<string,object>)JSON.deserializeUntyped(respMsg);
            awsDataId = String.valueOf(mso.get('AWS_Data_Id__c'));
            transId = String.valueOf(mso.get('txId'));
        } catch (Exception e) {
        }
        PIHelper.saveTransLog(module, awsDataId, sfId, transId, content, status, respMsg);
    }
    // 20220222 PI改造 by Bright--start
    @AuraEnabled
    public static Map<string,string> GetConfig() {
        Map<String,string> result = new Map<String,string>();
        result.put('staticResource', JSON.serialize(PIHelper.getPIIntegrationInfo('Agency_Contact__c')));
        //result.put('sessionId', UserInfo.getSessionId());
        return result;
    }
    @AuraEnabled
    public static List<Agency_Contact__c> searchAccounts2(String hosStr, List<string> awsids) {
        System.debug('hosStr='+hosStr);
        System.debug('awsids='+awsids);
        String f1 = '%'+hosStr+'%';
        if (String.isBlank(hosStr)) f1 = '%';
        Set<String> hospitalSet = new Set<String>();
        Set<String> aHospitalSet = new Set<String>();
        List<Agency_Hospital_Link__c> ahls = [select Id, Hospital__c from Agency_Hospital_Link__c];
        for (Agency_Hospital_Link__c ahl : ahls) {
            hospitalSet.add(ahl.Hospital__c);
            aHospitalSet.add(ahl.Id);
        }
        List<Agency_Contact__c> acList1 = LightningUtil.searchOCMAgencyContact(hospitalSet, aHospitalSet, f1, awsids);
        return acList1;
    }
    // 20220222 PI改造 by Bright--end
}