| | |
| | | * @Author: chen jing wu |
| | | * @Date: 2023-04-12 11:16:07 |
| | | * @LastEditors: chen jing wu |
| | | * @LastEditTime: 2023-10-08 18:09:35 |
| | | * @LastEditTime: 2023-10-10 17:08:13 |
| | | */ |
| | | public with sharing class OpportunityLightingButtonController { |
| | | @AuraEnabled |
| | |
| | | from Lost_cancel_report__c where RecordTypeId != '01210000000R4hHAAS' and Opportunity__c =: recordId]; |
| | | rep.lostReport = re; |
| | | objs.put('report',rep); |
| | | Schema.DescribeSObjectResult s = Lost_cancel_report__c.sObjectType.getDescribe(); |
| | | if( !s.isCreateable()) { |
| | | objs.put('error',true); |
| | | }else{ |
| | | objs.put('error',false); |
| | | } |
| | | } catch (Exception e) { |
| | | objs.put('error',e.getMessage()); |
| | | return objs; |
| | |
| | | res.salesOwnerBuchang = opportunity.Sales_owner_buchang__c; |
| | | res.salesOwnerBuchangID = opportunity.Sales_owner_buchangID__c; |
| | | res.cntLostCancelDraft = opportunity.Cnt_Lost_cancel_Draft__c; |
| | | Schema.DescribeSObjectResult s = Lost_cancel_report__c.sObjectType.getDescribe(); |
| | | if( !s.isCreateable()) { |
| | | res.isHavePower = false; |
| | | }else{ |
| | | res.isHavePower = true; |
| | | } |
| | | } catch (Exception e) { |
| | | |
| | | } |
| | |
| | | public String reportStatus; |
| | | @AuraEnabled |
| | | public String reportId; |
| | | @AuraEnabled |
| | | public Boolean isHavePower; |
| | | } |
| | | } |