Skip to content

Commit 9446832

Browse files
committed
Datamodell for feaure flags
1 parent d53d312 commit 9446832

File tree

9 files changed

+199
-0
lines changed

9 files changed

+199
-0
lines changed
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Layout xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<layoutSections>
4+
<customLabel>false</customLabel>
5+
<detailHeading>false</detailHeading>
6+
<editHeading>false</editHeading>
7+
<label>Information</label>
8+
<layoutColumns>
9+
<layoutItems>
10+
<behavior>Required</behavior>
11+
<field>MasterLabel</field>
12+
</layoutItems>
13+
<layoutItems>
14+
<behavior>Edit</behavior>
15+
<field>Is_Enabled__c</field>
16+
</layoutItems>
17+
<layoutItems>
18+
<behavior>Required</behavior>
19+
<field>Feature_flag_owner__c</field>
20+
</layoutItems>
21+
</layoutColumns>
22+
<layoutColumns>
23+
<layoutItems>
24+
<behavior>Required</behavior>
25+
<field>DeveloperName</field>
26+
</layoutItems>
27+
<layoutItems>
28+
<behavior>Edit</behavior>
29+
<field>Required_Custom_Permission__c</field>
30+
</layoutItems>
31+
</layoutColumns>
32+
<style>TwoColumnsLeftToRight</style>
33+
</layoutSections>
34+
<layoutSections>
35+
<customLabel>true</customLabel>
36+
<detailHeading>false</detailHeading>
37+
<editHeading>false</editHeading>
38+
<label>Description</label>
39+
<layoutColumns>
40+
<layoutItems>
41+
<behavior>Required</behavior>
42+
<field>Description__c</field>
43+
</layoutItems>
44+
</layoutColumns>
45+
<style>OneColumn</style>
46+
</layoutSections>
47+
<layoutSections>
48+
<customLabel>false</customLabel>
49+
<detailHeading>false</detailHeading>
50+
<editHeading>true</editHeading>
51+
<label>System Information</label>
52+
<layoutColumns>
53+
<layoutItems>
54+
<behavior>Edit</behavior>
55+
<field>NamespacePrefix</field>
56+
</layoutItems>
57+
<layoutItems>
58+
<behavior>Readonly</behavior>
59+
<field>CreatedById</field>
60+
</layoutItems>
61+
</layoutColumns>
62+
<layoutColumns>
63+
<layoutItems>
64+
<behavior>Edit</behavior>
65+
<field>IsProtected</field>
66+
</layoutItems>
67+
<layoutItems>
68+
<behavior>Readonly</behavior>
69+
<field>LastModifiedById</field>
70+
</layoutItems>
71+
</layoutColumns>
72+
<style>TwoColumnsTopToBottom</style>
73+
</layoutSections>
74+
<layoutSections>
75+
<customLabel>true</customLabel>
76+
<detailHeading>false</detailHeading>
77+
<editHeading>false</editHeading>
78+
<label>Custom Links</label>
79+
<layoutColumns/>
80+
<layoutColumns/>
81+
<layoutColumns/>
82+
<style>CustomLinks</style>
83+
</layoutSections>
84+
<showEmailCheckbox>false</showEmailCheckbox>
85+
<showHighlightsPanel>false</showHighlightsPanel>
86+
<showInteractionLogPanel>false</showInteractionLogPanel>
87+
<showRunAssignmentRulesCheckbox>false</showRunAssignmentRulesCheckbox>
88+
<showSubmitAndAttachButton>false</showSubmitAndAttachButton>
89+
<summaryLayout>
90+
<masterLabel>00hKH000000jisd</masterLabel>
91+
<sizeX>4</sizeX>
92+
<sizeY>0</sizeY>
93+
<summaryLayoutStyle>Default</summaryLayoutStyle>
94+
</summaryLayout>
95+
</Layout>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<CustomObject xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<description>Used to controll feature flags</description>
4+
<label>Feature Flag</label>
5+
<pluralLabel>Feature Flags</pluralLabel>
6+
<visibility>Public</visibility>
7+
</CustomObject>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<CustomField xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<fullName>Description__c</fullName>
4+
<businessStatus>Active</businessStatus>
5+
<description>A brief description of what the feature does.</description>
6+
<fieldManageability>DeveloperControlled</fieldManageability>
7+
<inlineHelpText>A brief description of what the feature does.</inlineHelpText>
8+
<label>Description</label>
9+
<required>true</required>
10+
<securityClassification>Public</securityClassification>
11+
<type>TextArea</type>
12+
</CustomField>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<CustomField xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<fullName>Feature_flag_owner__c</fullName>
4+
<description>Links to the Nav team that owns the feature flag.</description>
5+
<fieldManageability>DeveloperControlled</fieldManageability>
6+
<inlineHelpText>Links to the Nav team that owns the feature flag.</inlineHelpText>
7+
<label>Feature flag owner</label>
8+
<referenceTo>Nav_Team__mdt</referenceTo>
9+
<relationshipLabel>Feature Flags</relationshipLabel>
10+
<relationshipName>Feature_Flags</relationshipName>
11+
<required>true</required>
12+
<type>MetadataRelationship</type>
13+
<unique>false</unique>
14+
</CustomField>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<CustomField xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<fullName>Is_Enabled__c</fullName>
4+
<businessStatus>Active</businessStatus>
5+
<defaultValue>false</defaultValue>
6+
<description>A checkbox field that indicates whether the feature is currently enabled.</description>
7+
<fieldManageability>DeveloperControlled</fieldManageability>
8+
<inlineHelpText>A checkbox field that indicates whether the feature is currently enabled.</inlineHelpText>
9+
<label>Is Enabled</label>
10+
<securityClassification>Public</securityClassification>
11+
<type>Checkbox</type>
12+
</CustomField>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<CustomField xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<fullName>Required_Custom_Permission__c</fullName>
4+
<description>Sometimes a feature is granted on an individual or group level, this ensures that we check both the feature flag and custom permission.</description>
5+
<externalId>false</externalId>
6+
<fieldManageability>DeveloperControlled</fieldManageability>
7+
<inlineHelpText>Sometimes a feature is granted on an individual or group level, this ensures that we check both the feature flag and custom permission.</inlineHelpText>
8+
<label>Required Custom Permission</label>
9+
<length>255</length>
10+
<required>false</required>
11+
<type>Text</type>
12+
<unique>false</unique>
13+
</CustomField>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ListView xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<fullName>All</fullName>
4+
<columns>MasterLabel</columns>
5+
<columns>Is_Enabled__c</columns>
6+
<columns>DeveloperName</columns>
7+
<columns>Required_Custom_Permission__c</columns>
8+
<columns>Description__c</columns>
9+
<filterScope>Everything</filterScope>
10+
<label>All</label>
11+
<language>en_US</language>
12+
</ListView>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ListView xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<fullName>Disabled_Features</fullName>
4+
<columns>MasterLabel</columns>
5+
<columns>Is_Enabled__c</columns>
6+
<columns>DeveloperName</columns>
7+
<columns>Required_Custom_Permission__c</columns>
8+
<columns>Description__c</columns>
9+
<filterScope>Everything</filterScope>
10+
<filters>
11+
<field>Is_Enabled__c</field>
12+
<operation>equals</operation>
13+
<value>0</value>
14+
</filters>
15+
<label>Disabled Features</label>
16+
<language>en_US</language>
17+
</ListView>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ListView xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<fullName>Enabled_Features</fullName>
4+
<columns>MasterLabel</columns>
5+
<columns>Is_Enabled__c</columns>
6+
<columns>DeveloperName</columns>
7+
<columns>Required_Custom_Permission__c</columns>
8+
<columns>Description__c</columns>
9+
<filterScope>Everything</filterScope>
10+
<filters>
11+
<field>Is_Enabled__c</field>
12+
<operation>equals</operation>
13+
<value>1</value>
14+
</filters>
15+
<label>Enabled Features</label>
16+
<language>en_US</language>
17+
</ListView>

0 commit comments

Comments
 (0)