<?xml version="1.0" encoding="UTF-8"?>
|
<ValidationRule xmlns="http://soap.sforce.com/2006/04/metadata">
|
<fullName>Doctor_Create_dept_only</fullName>
|
<active>false</active>
|
<description>创建医生只能在科室里</description>
|
<errorConditionFormula>($User.ProfileId <>'00e10000000Y3o5' && $User.ProfileId <> '00e10000000dEQx')&&RecordTypeId='01210000000QfWd'&&isnew()&&
|
(Account.RecordType.DeveloperName=='HP'||
|
BEGINS(Account.RecordType.DeveloperName, 'Department_Class')
|
)</errorConditionFormula>
|
<errorDisplayField>AccountId</errorDisplayField>
|
<errorMessage>医生创建必须隶属于具体科室</errorMessage>
|
</ValidationRule>
|