-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#296 - creating apex function to be used as call back on the mc init …
…function to create the environments
- Loading branch information
Daniel Ventura
committed
Dec 16, 2022
1 parent
8e76cd5
commit e63464d
Showing
2 changed files
with
26 additions
and
0 deletions.
There are no files selected for viewing
16 changes: 16 additions & 0 deletions
16
force-app/main/default/classes/mcdo_CreateEnvironments.cls
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
/** | ||
* This class is used by the MC Init function, | ||
* responsible for creating all environments | ||
*/ | ||
Global class mcdo_CreateEnvironments implements copado.MCCallback { | ||
Global void execute(copado__Function__c function, copado__Result__c result, String status) { | ||
if(status == 'Failed') { | ||
// handle Error | ||
} else if(status == 'Success') { | ||
// handle Success | ||
System.debug('Entered the createEnvironments callback function with the status equals to "Success"'); | ||
} else { | ||
// handle In progress if necessary | ||
} | ||
} | ||
} |
10 changes: 10 additions & 0 deletions
10
force-app/main/default/classes/mcdo_CreateEnvironments.cls-meta.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata"> | ||
<apiVersion>56.0</apiVersion> | ||
<packageVersions> | ||
<majorNumber>20</majorNumber> | ||
<minorNumber>2</minorNumber> | ||
<namespace>copado</namespace> | ||
</packageVersions> | ||
<status>Active</status> | ||
</ApexClass> |