binxie
2024-01-20 2ff0f0a7ab276c3466d9e06e14222db802194efc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
<?xml version="1.0" encoding="UTF-8"?>
<Workflow xmlns="http://soap.sforce.com/2006/04/metadata">
    <alerts>
        <fullName>OrderApprove</fullName>
        <description>订单Win通知</description>
        <protected>false</protected>
        <recipients>
            <field>SalesManager__c</field>
            <type>userLookup</type>
        </recipients>
        <senderType>CurrentUser</senderType>
        <template>Olympus_OCM/order_winrebut_HTML</template>
    </alerts>
    <alerts>
        <fullName>Order_Rebut</fullName>
        <description>订单驳回通知</description>
        <protected>false</protected>
        <recipients>
            <type>owner</type>
        </recipients>
        <senderType>CurrentUser</senderType>
        <template>Olympus_OCM/order_rebut_HTML</template>
    </alerts>
    <alerts>
        <fullName>Order_Request</fullName>
        <description>订单审批申请</description>
        <protected>false</protected>
        <recipients>
            <type>owner</type>
        </recipients>
        <senderType>CurrentUser</senderType>
        <template>Olympus_OCM/order_approval_HTML</template>
    </alerts>
    <alerts>
        <fullName>Order_Warn</fullName>
        <description>未到货订单信息警告(超过一周)</description>
        <protected>false</protected>
        <recipients>
            <type>owner</type>
        </recipients>
        <senderAddress>lu_liu@olympus.com.cn</senderAddress>
        <senderType>OrgWideEmailAddress</senderType>
        <template>Olympus_OCM/Order_Warn_HTML</template>
    </alerts>
    <alerts>
        <fullName>order_winrebut</fullName>
        <description>订单配置清单查看通知</description>
        <protected>false</protected>
        <recipients>
            <field>SalesManager__c</field>
            <type>userLookup</type>
        </recipients>
        <senderType>CurrentUser</senderType>
        <template>Olympus_OCM/order_winrebut_HTML</template>
    </alerts>
    <fieldUpdates>
        <fullName>ActionFieldUpdate</fullName>
        <description>Consumable_order__c</description>
        <field>Order_Indication__c</field>
        <formula>RCCD__c &amp;&quot;-&quot;&amp;  Order_period_New__c  &amp;&quot;-&quot;&amp;  AutoNumber__c</formula>
        <name>更新Order_Indication</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Formula</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>ApplySalsesTeam</fullName>
        <field>ApplySalsesTeam__c</field>
        <formula>ApplySalsesTeam_F__c</formula>
        <name>消耗品订单申请销售课</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Formula</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>Order_name</fullName>
        <field>Name</field>
        <formula>RCCD__c &amp;&quot;-&quot;&amp;  Order_period_New__c  &amp;&quot;-&quot;&amp;MID(Text(Today()), 6, 2)&amp;&quot;-&quot;&amp;Order_type_mark__c&amp;  AutoNumber__c</formula>
        <name>Order_name</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Formula</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>Update_invoice_status</fullName>
        <field>Invoice_status__c</field>
        <literalValue>已完成</literalValue>
        <name>更新发票状态</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Literal</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>Update_invoice_status_back</fullName>
        <field>Invoice_status__c</field>
        <literalValue>提交</literalValue>
        <name>更新发票状态_back</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Literal</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>update_orderName</fullName>
        <description>自动编码=&gt;Name</description>
        <field>Name</field>
        <formula>IF(Name = &apos;*&apos;,RCCD__c &amp; MID(Text(Today()), 3, 2) &amp; &quot;-&quot; &amp; RIGHT(AutoNumber__c,5),Name)</formula>
        <name>update_orderName</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Formula</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>update_status_01</fullName>
        <field>Order_status__c</field>
        <literalValue>已提交</literalValue>
        <name>订单状态更新-已提交</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Literal</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>update_status_02</fullName>
        <field>Order_status__c</field>
        <literalValue>批准</literalValue>
        <name>订单状态更新-批准</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Literal</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>update_status_03</fullName>
        <field>Order_status__c</field>
        <literalValue>驳回</literalValue>
        <name>订单状态更新-驳回</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Literal</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>update_status_04</fullName>
        <field>Order_status__c</field>
        <literalValue>草案中</literalValue>
        <name>订单状态更新-草案中</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Literal</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <fieldUpdates>
        <fullName>update_status_1</fullName>
        <field>Order_status__c</field>
        <literalValue>已提交</literalValue>
        <name>订单状态更新-已提交</name>
        <notifyAssignee>false</notifyAssignee>
        <operation>Literal</operation>
        <protected>false</protected>
        <reevaluateOnChange>false</reevaluateOnChange>
    </fieldUpdates>
    <rules>
        <fullName>Invoice_Status_back</fullName>
        <actions>
            <name>Update_invoice_status_back</name>
            <type>FieldUpdate</type>
        </actions>
        <active>true</active>
        <booleanFilter>(1 OR 2) AND 3</booleanFilter>
        <criteriaItems>
            <field>Consumable_order__c.Invoice_attachment__c</field>
            <operation>equals</operation>
            <value>假</value>
        </criteriaItems>
        <criteriaItems>
            <field>Consumable_order__c.Invoicedet_attachment__c</field>
            <operation>equals</operation>
            <value>假</value>
        </criteriaItems>
        <criteriaItems>
            <field>Consumable_order__c.Invoice_status__c</field>
            <operation>equals</operation>
            <value>已完成</value>
        </criteriaItems>
        <description>更新发票状态 提交</description>
        <triggerType>onCreateOrTriggeringUpdate</triggerType>
    </rules>
    <rules>
        <fullName>Invoice_Status_done</fullName>
        <actions>
            <name>Update_invoice_status</name>
            <type>FieldUpdate</type>
        </actions>
        <active>true</active>
        <booleanFilter>(1 AND 2)</booleanFilter>
        <criteriaItems>
            <field>Consumable_order__c.Invoice_attachment__c</field>
            <operation>equals</operation>
            <value>真</value>
        </criteriaItems>
        <criteriaItems>
            <field>Consumable_order__c.Invoicedet_attachment__c</field>
            <operation>equals</operation>
            <value>真</value>
        </criteriaItems>
        <description>更新发票状态 已完成</description>
        <triggerType>onCreateOrTriggeringUpdate</triggerType>
    </rules>
    <rules>
        <fullName>Order_Indication</fullName>
        <actions>
            <name>Order_name</name>
            <type>FieldUpdate</type>
        </actions>
        <active>true</active>
        <booleanFilter>(1 OR 2)</booleanFilter>
        <criteriaItems>
            <field>Consumable_order__c.Name</field>
            <operation>equals</operation>
            <value>*</value>
        </criteriaItems>
        <criteriaItems>
            <field>Consumable_order__c.Name</field>
            <operation>equals</operation>
        </criteriaItems>
        <description>Consumable_order__c</description>
        <triggerType>onCreateOrTriggeringUpdate</triggerType>
    </rules>
    <rules>
        <fullName>未到货订单信息警告%EF%BC%88超过一周%EF%BC%89</fullName>
        <active>true</active>
        <criteriaItems>
            <field>Consumable_order__c.RecordTypeId</field>
            <operation>equals</operation>
            <value>02 发货</value>
        </criteriaItems>
        <criteriaItems>
            <field>Consumable_order__c.Shipment_date__c</field>
            <operation>lessOrEqual</operation>
            <value>7 天前</value>
        </criteriaItems>
        <criteriaItems>
            <field>Consumable_order__c.Delivery_detail_count__c</field>
            <operation>greaterThan</operation>
            <value>0</value>
        </criteriaItems>
        <triggerType>onCreateOrTriggeringUpdate</triggerType>
        <workflowTimeTriggers>
            <actions>
                <name>Order_Warn</name>
                <type>Alert</type>
            </actions>
            <offsetFromField>Consumable_order__c.Shipment_date__c</offsetFromField>
            <timeLength>7</timeLength>
            <workflowTimeTriggerUnit>Days</workflowTimeTriggerUnit>
        </workflowTimeTriggers>
    </rules>
    <rules>
        <fullName>确定申请销售课</fullName>
        <actions>
            <name>ApplySalsesTeam</name>
            <type>FieldUpdate</type>
        </actions>
        <active>true</active>
        <formula>ISNEW() || ISCHANGED(ApplySalsesTeam_F__c)</formula>
        <triggerType>onAllChanges</triggerType>
    </rules>
    <rules>
        <fullName>追溯系统驳回提醒</fullName>
        <actions>
            <name>Order_Rebut</name>
            <type>Alert</type>
        </actions>
        <active>true</active>
        <formula>ISCHANGED(Order_status__c) &amp;&amp;  TEXT( Order_status__c)=  &apos;驳回&apos;</formula>
        <triggerType>onAllChanges</triggerType>
    </rules>
</Workflow>