When setOrgWideEmailAddressId is not set, sender will be excutor.
Search In This Blog
2023-12-27
2023-08-08
Not Admin User, How to delete/insert FinServ__FinancialAccount by Apex
Apex should be "without sharing".
Remove sObject.SObjectType.getDescribe().isDeletable() or sObject.SObjectType.getDescribe().isUpdateable() or sObject.SObjectType.getDescribe().isCreateable()
Inactive record in FinServ__RollupByLookupConfig__c, if need.
To Delete
Before delete, update "OwnerId" to current user. Like: FinServ__FinancialAccount.OwnerId = UserInfo.getUserId(). Then user can delete FinServ__FinancialAccount record.
To insert
If you want the special user can edit this FinServ__FinancialAccount record, don't forget to update "OwnerId" to the special user's id after insert.
Subscribe to:
Posts (Atom)