Skip to content

Commit 3cf4796

Browse files
authored
Merge pull request #118 from navikt/restoreFlows
restored deleted flows
2 parents 23b538d + b54b5d6 commit 3cf4796

File tree

2 files changed

+242
-0
lines changed

2 files changed

+242
-0
lines changed
Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Flow xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<apiVersion>52.0</apiVersion>
4+
<decisions>
5+
<description>Checks which user that activated the office restriction</description>
6+
<name>Check_Office_Restriction_Activated_By</name>
7+
<label>Check Office Restriction Activated By</label>
8+
<locationX>182</locationX>
9+
<locationY>311</locationY>
10+
<defaultConnector>
11+
<targetReference>Updated_office_restriction_info_0</targetReference>
12+
</defaultConnector>
13+
<defaultConnectorLabel>Activated in Salesforce</defaultConnectorLabel>
14+
<rules>
15+
<name>Activated_Through_API</name>
16+
<conditionLogic>or</conditionLogic>
17+
<conditions>
18+
<leftValueReference>$Record.LastModifiedBy.CRM_NAV_Ident__c</leftValueReference>
19+
<operator>EqualTo</operator>
20+
<rightValue>
21+
<stringValue />
22+
</rightValue>
23+
</conditions>
24+
<conditions>
25+
<leftValueReference>$Record.LastModifiedBy.CRM_NAV_Ident__c</leftValueReference>
26+
<operator>IsNull</operator>
27+
<rightValue>
28+
<booleanValue>true</booleanValue>
29+
</rightValue>
30+
</conditions>
31+
<connector>
32+
<targetReference>Updated_office_restriction_info</targetReference>
33+
</connector>
34+
<label>Activated Through API</label>
35+
</rules>
36+
</decisions>
37+
<description>Set office restriction values if office restriction is set to true</description>
38+
<interviewLabel>Conversation Note - Before Update - Office Restriction Set to True
39+
{!$Flow.CurrentDateTime}</interviewLabel>
40+
<label>Conversation Note - Before Update - Office Restriction Set To True</label>
41+
<processMetadataValues>
42+
<name>BuilderType</name>
43+
<value>
44+
<stringValue>LightningFlowBuilder</stringValue>
45+
</value>
46+
</processMetadataValues>
47+
<processMetadataValues>
48+
<name>CanvasMode</name>
49+
<value>
50+
<stringValue>AUTO_LAYOUT_CANVAS</stringValue>
51+
</value>
52+
</processMetadataValues>
53+
<processMetadataValues>
54+
<name>OriginBuilderType</name>
55+
<value>
56+
<stringValue>LightningFlowBuilder</stringValue>
57+
</value>
58+
</processMetadataValues>
59+
<processType>AutoLaunchedFlow</processType>
60+
<recordUpdates>
61+
<name>Updated_office_restriction_info</name>
62+
<label>Updated office restriction info</label>
63+
<locationX>50</locationX>
64+
<locationY>431</locationY>
65+
<inputAssignments>
66+
<field>CRM_Office_Restriction_Activated_By__c</field>
67+
<value>
68+
<elementReference>$Record.CRM_Last_Edited_By__c</elementReference>
69+
</value>
70+
</inputAssignments>
71+
<inputAssignments>
72+
<field>CRM_Office_Restriction_Date__c</field>
73+
<value>
74+
<elementReference>$Flow.CurrentDateTime</elementReference>
75+
</value>
76+
</inputAssignments>
77+
<inputReference>$Record</inputReference>
78+
</recordUpdates>
79+
<recordUpdates>
80+
<name>Updated_office_restriction_info_0</name>
81+
<label>Updated office restriction info</label>
82+
<locationX>314</locationX>
83+
<locationY>431</locationY>
84+
<inputAssignments>
85+
<field>CRM_Office_Restriction_Activated_By__c</field>
86+
<value>
87+
<elementReference>$Record.LastModifiedBy.CRM_NAV_Ident__c</elementReference>
88+
</value>
89+
</inputAssignments>
90+
<inputAssignments>
91+
<field>CRM_Office_Restriction_Date__c</field>
92+
<value>
93+
<elementReference>$Flow.CurrentDateTime</elementReference>
94+
</value>
95+
</inputAssignments>
96+
<inputReference>$Record</inputReference>
97+
</recordUpdates>
98+
<start>
99+
<locationX>56</locationX>
100+
<locationY>0</locationY>
101+
<connector>
102+
<targetReference>Check_Office_Restriction_Activated_By</targetReference>
103+
</connector>
104+
<doesRequireRecordChangedToMeetCriteria>true</doesRequireRecordChangedToMeetCriteria>
105+
<filterLogic>and</filterLogic>
106+
<filters>
107+
<field>CRM_Office_Restriction__c</field>
108+
<operator>EqualTo</operator>
109+
<value>
110+
<booleanValue>true</booleanValue>
111+
</value>
112+
</filters>
113+
<object>Conversation_Note__c</object>
114+
<recordTriggerType>Update</recordTriggerType>
115+
<triggerType>RecordBeforeSave</triggerType>
116+
</start>
117+
<status>Draft</status>
118+
</Flow>
Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<Flow xmlns="http://soap.sforce.com/2006/04/metadata">
3+
<apiVersion>53.0</apiVersion>
4+
<assignments>
5+
<name>Set_office_restriction_date</name>
6+
<label>Set office restriction date</label>
7+
<locationX>182</locationX>
8+
<locationY>647</locationY>
9+
<assignmentItems>
10+
<assignToReference>$Record.CRM_Office_Restriction_Date__c</assignToReference>
11+
<operator>Assign</operator>
12+
<value>
13+
<elementReference>$Flow.CurrentDateTime</elementReference>
14+
</value>
15+
</assignmentItems>
16+
</assignments>
17+
<assignments>
18+
<name>Update_office_restriction_info</name>
19+
<label>Update office restriction info</label>
20+
<locationX>50</locationX>
21+
<locationY>431</locationY>
22+
<assignmentItems>
23+
<assignToReference>$Record.CRM_Office_Restriction_Activated_By__c</assignToReference>
24+
<operator>Assign</operator>
25+
<value>
26+
<elementReference>$Record.CRM_Last_Edited_By__c</elementReference>
27+
</value>
28+
</assignmentItems>
29+
<connector>
30+
<targetReference>Set_office_restriction_date</targetReference>
31+
</connector>
32+
</assignments>
33+
<assignments>
34+
<name>Update_office_restriction_info_SF</name>
35+
<label>Update office restriction info SF</label>
36+
<locationX>314</locationX>
37+
<locationY>431</locationY>
38+
<assignmentItems>
39+
<assignToReference>$Record.CRM_Office_Restriction_Activated_By__c</assignToReference>
40+
<operator>Assign</operator>
41+
<value>
42+
<elementReference>$Record.LastModifiedBy.CRM_NAV_Ident__c</elementReference>
43+
</value>
44+
</assignmentItems>
45+
<connector>
46+
<targetReference>Set_office_restriction_date</targetReference>
47+
</connector>
48+
</assignments>
49+
<decisions>
50+
<name>How_was_office_restrictions_activated</name>
51+
<label>How was office restrictions activated</label>
52+
<locationX>182</locationX>
53+
<locationY>311</locationY>
54+
<defaultConnector>
55+
<targetReference>Update_office_restriction_info_SF</targetReference>
56+
</defaultConnector>
57+
<defaultConnectorLabel>Activated in Salesforce</defaultConnectorLabel>
58+
<rules>
59+
<name>Activated_By_API</name>
60+
<conditionLogic>and</conditionLogic>
61+
<conditions>
62+
<leftValueReference>$Record.LastModifiedBy.CRM_NAV_Ident__c</leftValueReference>
63+
<operator>EqualTo</operator>
64+
<rightValue>
65+
<stringValue />
66+
</rightValue>
67+
</conditions>
68+
<conditions>
69+
<leftValueReference>$Record.LastModifiedBy.CRM_NAV_Ident__c</leftValueReference>
70+
<operator>IsNull</operator>
71+
<rightValue>
72+
<booleanValue>true</booleanValue>
73+
</rightValue>
74+
</conditions>
75+
<connector>
76+
<targetReference>Update_office_restriction_info</targetReference>
77+
</connector>
78+
<label>Activated By API</label>
79+
</rules>
80+
</decisions>
81+
<description>If office resrtiction is set to true update the office restriction fields</description>
82+
<interviewLabel>Thread - Before Update - On Office Restriction Set To True
83+
{!$Flow.CurrentDateTime}</interviewLabel>
84+
<label>Thread - Before Update - On Office Restriction Set To True</label>
85+
<processMetadataValues>
86+
<name>BuilderType</name>
87+
<value>
88+
<stringValue>LightningFlowBuilder</stringValue>
89+
</value>
90+
</processMetadataValues>
91+
<processMetadataValues>
92+
<name>CanvasMode</name>
93+
<value>
94+
<stringValue>AUTO_LAYOUT_CANVAS</stringValue>
95+
</value>
96+
</processMetadataValues>
97+
<processMetadataValues>
98+
<name>OriginBuilderType</name>
99+
<value>
100+
<stringValue>LightningFlowBuilder</stringValue>
101+
</value>
102+
</processMetadataValues>
103+
<processType>AutoLaunchedFlow</processType>
104+
<start>
105+
<locationX>56</locationX>
106+
<locationY>0</locationY>
107+
<connector>
108+
<targetReference>How_was_office_restrictions_activated</targetReference>
109+
</connector>
110+
<doesRequireRecordChangedToMeetCriteria>true</doesRequireRecordChangedToMeetCriteria>
111+
<filterLogic>and</filterLogic>
112+
<filters>
113+
<field>CRM_Office_Restriction__c</field>
114+
<operator>EqualTo</operator>
115+
<value>
116+
<booleanValue>true</booleanValue>
117+
</value>
118+
</filters>
119+
<object>Thread__c</object>
120+
<recordTriggerType>Update</recordTriggerType>
121+
<triggerType>RecordBeforeSave</triggerType>
122+
</start>
123+
<status>Draft</status>
124+
</Flow>

0 commit comments

Comments
 (0)