| | |
| | | return re; |
| | | } |
| | | |
| | | //OCSM不要报告 |
| | | @AuraEnabled |
| | | public static InitData initForlexOCSMNoToReportLightingButton (String recordId){ |
| | | InitData res = new initData(); |
| | | try{ |
| | | QIS_Report__c report = [SELECT id ,OCSMAdministrativeReportNumber__c,OCSMAdministrativeReportDate__c,Aware_date__c FROM QIS_Report__c WHERE Id = :recordId LIMIT 1]; |
| | | res.Id = report.Id; |
| | | res.oCSMAdministrativeReportNumber = report.OCSMAdministrativeReportNumber__c; |
| | | res.oCSMAdministrativeReportDate = report.OCSMAdministrativeReportDate__c; |
| | | res.Awaredate = report.Aware_date__c; |
| | | System.debug(LoggingLevel.INFO, '*** res: ' + res); |
| | | }catch(Exception e){ |
| | | System.debug(LoggingLevel.INFO, '*** e: ' + e); |
| | | } |
| | | return res; |
| | | } |
| | | @AuraEnabled |
| | | public static String updateQisForlexOCSMNoToReportLighting (String recordId){ |
| | | String re = '成功'; |
| | | QIS_Report__c report = [SELECT id FROM QIS_Report__c WHERE Id = :recordId LIMIT 1]; |
| | | try{ |
| | | QIS_Report__c rac = new QIS_Report__c(); |
| | | rac.id = recordId; |
| | | rac.OCSMAdministrativeReportStatus__c = '无需报告'; |
| | | update rac; |
| | | }catch(Exception e){ |
| | | System.debug(LoggingLevel.INFO, '*** e: ' + e); |
| | | re = e.getMessage(); |
| | | } |
| | | return re; |
| | | } |
| | | //OCSM要报告 |
| | | @AuraEnabled |
| | | public static InitData initForlexOCSMToReportLightingButton (String recordId){ |
| | | InitData res = new initData(); |
| | | try{ |
| | | QIS_Report__c report = [SELECT id ,OCSMAdministrativeReportStatus__c,Aware_date__c FROM QIS_Report__c WHERE Id = :recordId LIMIT 1]; |
| | | res.Id = report.Id; |
| | | res.oCSMAdministrativeReportStatus = report.OCSMAdministrativeReportStatus__c; |
| | | res.Awaredate = report.Aware_date__c; |
| | | System.debug(LoggingLevel.INFO, '*** res: ' + res); |
| | | }catch(Exception e){ |
| | | System.debug(LoggingLevel.INFO, '*** e: ' + e); |
| | | } |
| | | return res; |
| | | } |
| | | |
| | | @AuraEnabled |
| | | public static String updateQisForlexOCSMToReportLighting (String recordId){ |
| | | String re = '成功'; |
| | | QIS_Report__c report = [SELECT id FROM QIS_Report__c WHERE Id = :recordId LIMIT 1]; |
| | | try{ |
| | | QIS_Report__c rac = new QIS_Report__c(); |
| | | rac.id = recordId; |
| | | rac.OCSMAdministrativeReportStatus__c = '待报告'; |
| | | update rac; |
| | | }catch(Exception e){ |
| | | System.debug(LoggingLevel.INFO, '*** e: ' + e); |
| | | re = e.getMessage(); |
| | | } |
| | | return re; |
| | | } |
| | | public class InitData{ |
| | | @AuraEnabled |
| | | public String Id; |