Skip to content

Commit

Permalink
Merge pull request #1414 from bcgov/User/EDRD-98
Browse files Browse the repository at this point in the history
User/edrd 98
  • Loading branch information
deepakmulamalla authored Dec 23, 2024
2 parents 743ee66 + 7da27b1 commit e423eb7
Show file tree
Hide file tree
Showing 11 changed files with 330 additions and 102 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,13 @@
<value>CONTACT.ACCOUNT_NAME</value>
</valueListItems>
<valueListItems>
<value>Contact.Provider_Type__c</value>
<value>ACCCONRELATION.ROLES</value>
</valueListItems>
<valueListItems>
<value>Contact.Provider_Identifier__c</value>
<value>Contact.Provider_Type__c</value>
</valueListItems>
<valueListItems>
<value>ACCCONRELATION.ROLES</value>
<value>Contact.Provider_Identifier__c</value>
</valueListItems>
</valueList>
</componentInstanceProperties>
Expand Down
327 changes: 238 additions & 89 deletions dev-app-post/main/default/flows/Create_EDRD_Case.flow-meta.xml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<StandardValueSet xmlns="http://soap.sforce.com/2006/04/metadata">
<sorted>false</sorted>
<sorted>true</sorted>
<!--<standardValue>
<fullName>Business User</fullName>
<default>false</default>
Expand Down Expand Up @@ -51,4 +51,19 @@
<default>false</default>
<label>Physician</label>
</standardValue>
<standardValue>
<fullName>Chair</fullName>
<default>false</default>
<label>Chair</label>
</standardValue>
<standardValue>
<fullName>Reviewer</fullName>
<default>false</default>
<label>Reviewer</label>
</standardValue>
<standardValue>
<fullName>Vice Chair</fullName>
<default>false</default>
<label>Vice Chair</label>
</standardValue>
</StandardValueSet>
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<CustomPermission xmlns="http://soap.sforce.com/2006/04/metadata">
<description>Created for EDRD-Super user Permission set.</description>
<isLicensed>false</isLicensed>
<label>EDRD_SuperUser</label>
</CustomPermission>
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,13 @@
<value>CONTACT.ACCOUNT_NAME</value>
</valueListItems>
<valueListItems>
<value>Contact.Provider_Type__c</value>
<value>ACCCONRELATION.ROLES</value>
</valueListItems>
<valueListItems>
<value>Contact.Provider_Identifier__c</value>
<value>Contact.Provider_Type__c</value>
</valueListItems>
<valueListItems>
<value>ACCCONRELATION.ROLES</value>
<value>Contact.Provider_Identifier__c</value>
</valueListItems>
</valueList>
</componentInstanceProperties>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,11 @@
<field>Provider_Specialty__pc</field>
</layoutItems>
<layoutItems>
<behavior>Edit</behavior>
<behavior>Readonly</behavior>
<field>Committee__pc</field>
</layoutItems>
<layoutItems>
<behavior>Edit</behavior>
<behavior>Readonly</behavior>
<field>Committee_Name__pc</field>
</layoutItems>
<layoutItems>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ NOT(ISNEW()),
NOT($Permission.SA_Team_Lead),
NOT($Permission.EDRD_MOH_STAFF),
NOT($Permission.EDRD_PHSA_PSP_Staff),
NOT($Permission.EDRD_SuperUser),
ESA_Bypass_Validation__pc = FALSE)</errorConditionFormula>
<errorMessage>You don&apos;t have permission to edit the Account Name.</errorMessage>
</ValidationRule>
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<ValidationRule xmlns="http://soap.sforce.com/2006/04/metadata">
<fullName>EDRD_Validate_ACR_CR_Role</fullName>
<active>true</active>
<description>Prevents EDRD users from creating a Committee-Reviewer relationship with the role &quot;Physician&quot; when specific Account and Contact record types are used.</description>
<errorConditionFormula>AND(
CONTAINS($UserRole.Name, &quot;EDRD&quot;),
Account.RecordType.DeveloperName = &apos;EDRD_Committee&apos;,
OR(
Contact.Account.RecordType.DeveloperName = &apos;Provider&apos;,
Contact.Account.RecordType.DeveloperName = &apos;Committee_Reviewer&apos;
),
INCLUDES(Roles, &apos;Physician&apos;)
)</errorConditionFormula>
<errorMessage>An EDRD user cannot create a Committee-Reviewer relationship with the role as Physician.</errorMessage>
</ValidationRule>
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<ValidationRule xmlns="http://soap.sforce.com/2006/04/metadata">
<fullName>EDRD_Validate_ACR_Insert_ForCommitteeRec</fullName>
<active>true</active>
<description>Prevents EDRD users from creating an inactive Committee-Reviewer relationship when the Account and Contact record types are specific and roles include Reviewer, Chair, or Vice Chair.</description>
<errorConditionFormula>AND(
ISNEW(),
CONTAINS($UserRole.Name, &quot;EDRD&quot;),
Account.RecordType.DeveloperName = &apos;EDRD_Committee&apos;,
OR(
Contact.Account.RecordType.DeveloperName = &apos;Provider&apos;,
Contact.Account.RecordType.DeveloperName = &apos;Committee_Reviewer&apos;
),
OR(
INCLUDES(Roles, &apos;Reviewer&apos;),
INCLUDES(Roles, &apos;Chair&apos;),
INCLUDES(Roles, &apos;Vice Chair&apos;)
),
NOT(IsActive)
)</errorConditionFormula>
<errorMessage>An EDRD user cannot create an inactive Committee - Reviewer relationship.</errorMessage>
</ValidationRule>
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,10 @@
<enabled>true</enabled>
<name>ESA_CMD_Super_Stamps__mdt</name>
</customMetadataTypeAccesses>
<customPermissions>
<enabled>true</enabled>
<name>EDRD_SuperUser</name>
</customPermissions>
<fieldPermissions>
<editable>true</editable>
<field>Account.Description</field>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<StandardValueSet xmlns="http://soap.sforce.com/2006/04/metadata">
<sorted>false</sorted>
<standardValue>
<sorted>true</sorted>
<!--<standardValue>
<fullName>Business User</fullName>
<default>false</default>
<label>Business User</label>
Expand Down Expand Up @@ -41,14 +41,29 @@
<default>false</default>
<label>Technical Buyer</label>
</standardValue>
<standardValue>
<fullName>Other</fullName>
<default>false</default>
<label>Other</label>
</standardValue> -->
<standardValue>
<fullName>Physician</fullName>
<default>false</default>
<label>Physician</label>
</standardValue>
<standardValue>
<fullName>Other</fullName>
<fullName>Chair</fullName>
<default>false</default>
<label>Other</label>
<label>Chair</label>
</standardValue>
<standardValue>
<fullName>Reviewer</fullName>
<default>false</default>
<label>Reviewer</label>
</standardValue>
<standardValue>
<fullName>Vice Chair</fullName>
<default>false</default>
<label>Vice Chair</label>
</standardValue>
</StandardValueSet>

0 comments on commit e423eb7

Please sign in to comment.