@waron97/prbot 2.6.1 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/example.xml DELETED
@@ -1,3903 +0,0 @@
1
- <odoo>
2
- <data>
3
- <record id="symple_triplet_phase_A1001_-_Apertura_Wizard_Risoluzione_contrattuale" model="symple.triplet.phase">
4
- <field name="active">True</field>
5
- <field name="allowed_process_ids" model="symple.pb.process" eval="[(6, 0, obj().search([('name','in',('ml_cessazioni_point_selection',)),]).ids)]" />
6
- <field name="child_case">False</field>
7
- <field name="code"># Available variables:
8
- # - case_id: the case that just reached this phase
9
- # - request: allows you to make HTTP requests (method, url, headers, data)
10
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
11
- # - json_load: allows you to use JSON.load to convert a json into an object
12
- # - env: Odoo Environment on which the action is triggered
13
- # - time, datetime, dateutil, timezone: useful Python libraries
14
- # - float_compare: Odoo function to compare floats based on specific precisions
15
- # - ValidationError: Warning Exception to use with raise
16
- # - Command: x2Many commands namespace
17
- # - OrderedDict: ordered dictionaries
18
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
19
- # (line = case id, func = phase name)
20
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
21
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
22
- # To return a result, assign: result = {...}
23
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
24
- # phase result will not be set.
25
-
26
-
27
-
28
- </field>
29
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','Customer Care')])" />
30
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
31
- <field name="is_a_postalizer_phase">False</field>
32
- <field name="is_compute_refund">False</field>
33
- <field name="is_dl">False</field>
34
- <field name="is_needs_child_case">False</field>
35
- <field name="is_pick_refund_template">False</field>
36
- <field name="is_process_managed">True</field>
37
- <field name="is_quote_accepted">False</field>
38
- <field name="is_quote_sent">False</field>
39
- <field name="is_timeout">False</field>
40
- <field name="is_voidable">False</field>
41
- <field name="name">A1001 - Apertura Wizard Risoluzione contrattuale</field>
42
- </record>
43
- <record id="symple_triplet_phase_A1709_-_verifica_compatibilit_" model="symple.triplet.phase">
44
- <field name="active">True</field>
45
- <field name="child_case">False</field>
46
- <field name="code">def main():
47
- service_point = case_id.service_point_ids[0]
48
- billing_profile = service_point.billing_profile_id
49
- asset = service_point.asset(active=False)
50
-
51
- if not asset:
52
- asset_id = False
53
- else:
54
- asset_id = asset._id
55
-
56
- (result, incompatible_case_ids) = ( # "OK" | "KO" | "PARTIAL_KO" # List[int]
57
- case_id.check_compatibility_matrix(
58
- asset_id=asset_id,
59
- client_id=case_id.customer_id.user_sequence,
60
- billing_id=billing_profile.name,
61
- # external_id -> default a case.ticket_type_id.univocal_code
62
- )
63
- )
64
-
65
- if incompatible_case_ids:
66
- case_id.write({"incompatible_ticket_ids": incompatible_case_ids})
67
-
68
- if result in ["OK", "PARTIAL_KO"]:
69
- case_id.create_matrix_process(
70
- asset_id=asset_id,
71
- client_id=case_id.customer_id.user_sequence,
72
- billing_id=billing_profile.name,
73
- # external_id -> default a case.ticket_type_id.univocal_code
74
- )
75
-
76
- return result
77
-
78
-
79
- try:
80
- result = main()
81
- except Exception as e:
82
- log(format_exc())
83
- case_id.write({"error_message": str(e)})
84
- </field>
85
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
86
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
87
- <field name="is_a_postalizer_phase">False</field>
88
- <field name="is_compute_refund">False</field>
89
- <field name="is_dl">False</field>
90
- <field name="is_needs_child_case">False</field>
91
- <field name="is_pick_refund_template">False</field>
92
- <field name="is_process_managed">False</field>
93
- <field name="is_quote_accepted">False</field>
94
- <field name="is_quote_sent">False</field>
95
- <field name="is_timeout">False</field>
96
- <field name="is_voidable">False</field>
97
- <field name="name">A1709 - verifica compatibilità</field>
98
- <field name="set_result_automatically">from_code</field>
99
- </record>
100
- <record id="symple_triplet_phase_result_C1401_-_Risoluzione_contrattuale_OK_E-CC01-0002" model="symple.triplet.phase.result">
101
- <field name="active">True</field>
102
- <field name="has_message">False</field>
103
- <field name="is_annulment">False</field>
104
- <field name="is_dl_solicitation_result">False</field>
105
- <field name="is_hidden">False</field>
106
- <field name="is_quote_expired">False</field>
107
- <field name="name">C1401 - Risoluzione contrattuale OK</field>
108
- <field name="next_phase_id" ref="symple_triplet_phase_A1709_-_verifica_compatibilit_"/>
109
- <field name="state_code">E-CC01-0002</field>
110
- <field name="wizard_result">SUCCESS</field>
111
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1001_-_Apertura_Wizard_Risoluzione_contrattuale')])]"/>
112
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
113
- </record>
114
- <record id="symple_triplet_phase_A1710_-_Verifica_compatibilit__KO" model="symple.triplet.phase">
115
- <field name="active">True</field>
116
- <field name="child_case">False</field>
117
- <field name="code"># Available variables:
118
- # - case_id: the case that just reached this phase
119
- # - request: allows you to make HTTP requests (method, url, headers, data)
120
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
121
- # - json_load: allows you to use JSON.load to convert a json into an object
122
- # - env: Odoo Environment on which the action is triggered
123
- # - time, datetime, dateutil, timezone: useful Python libraries
124
- # - float_compare: Odoo function to compare floats based on specific precisions
125
- # - ValidationError: Warning Exception to use with raise
126
- # - Command: x2Many commands namespace
127
- # - OrderedDict: ordered dictionaries
128
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
129
- # (line = case id, func = phase name)
130
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
131
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
132
- # To return a result, assign: result = {...}
133
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
134
- # phase result will not be set.
135
-
136
-
137
-
138
- </field>
139
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','BOT')])" />
140
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
141
- <field name="is_a_postalizer_phase">False</field>
142
- <field name="is_compute_refund">False</field>
143
- <field name="is_dl">False</field>
144
- <field name="is_needs_child_case">False</field>
145
- <field name="is_pick_refund_template">False</field>
146
- <field name="is_process_managed">False</field>
147
- <field name="is_quote_accepted">False</field>
148
- <field name="is_quote_sent">False</field>
149
- <field name="is_timeout">False</field>
150
- <field name="is_voidable">False</field>
151
- <field name="name">A1710 - Verifica compatibilità KO</field>
152
- </record>
153
- <record id="symple_triplet_phase_result_C404_-_KO_-_Incompatibile_E-CC01-0003" model="symple.triplet.phase.result">
154
- <field name="active">True</field>
155
- <field name="has_message">False</field>
156
- <field name="is_annulment">False</field>
157
- <field name="is_dl_solicitation_result">False</field>
158
- <field name="is_hidden">False</field>
159
- <field name="is_quote_expired">False</field>
160
- <field name="name">C404 - KO - Incompatibile</field>
161
- <field name="next_phase_id" ref="symple_triplet_phase_A1710_-_Verifica_compatibilit__KO"/>
162
- <field name="state_code">E-CC01-0003</field>
163
- <field name="wizard_result">KO</field>
164
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1709_-_verifica_compatibilit_')])]"/>
165
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO')])" />
166
- </record>
167
- <record id="symple_triplet_phase_result_C2410_-_OK_Incompatibilit__Gestita_E-CC01-0007" model="symple.triplet.phase.result">
168
- <field name="active">True</field>
169
- <field name="has_message">False</field>
170
- <field name="is_annulment">False</field>
171
- <field name="is_dl_solicitation_result">False</field>
172
- <field name="is_hidden">False</field>
173
- <field name="is_quote_expired">False</field>
174
- <field name="name">C2410 - OK Incompatibilità Gestita</field>
175
- <field name="next_phase_id" ref="symple_triplet_phase_A1709_-_verifica_compatibilit_"/>
176
- <field name="state_code">E-CC01-0007</field>
177
- <field name="wizard_result">SUCCESS</field>
178
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1710_-_Verifica_compatibilit__KO')])]"/>
179
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
180
- </record>
181
- <record id="symple_triplet_phase_A1672_-_Recupero_dati_a_CRM" model="symple.triplet.phase">
182
- <field name="active">True</field>
183
- <field name="child_case">False</field>
184
- <field name="code"><![CDATA[# Available variables:
185
- # - case_id: the case that just reached this phase
186
- # - request: allows you to make HTTP requests (method, url, headers, data)
187
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
188
- # - json_load: allows you to use JSON.load to convert a json into an object
189
- # - env: Odoo Environment on which the action is triggered
190
- # - time, datetime, dateutil, timezone: useful Python libraries
191
- # - float_compare: Odoo function to compare floats based on specific precisions
192
- # - ValidationError: Warning Exception to use with raise
193
- # - Command: x2Many commands namespace
194
- # - OrderedDict: ordered dictionaries
195
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
196
- # (line = case id, func = phase name)
197
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
198
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
199
- # To return a result, assign: result = {...}
200
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
201
- # phase result will not be set.
202
-
203
-
204
- logs = []
205
-
206
-
207
- def fmt(date):
208
- return date.strftime("%d/%m/%Y")
209
-
210
-
211
- def last_day_of_this_month():
212
- today = datetime.datetime.today()
213
- first_of_next_month = today.replace(day=1) + dateutil.relativedelta.relativedelta(
214
- months=1
215
- )
216
- last_day = first_of_next_month - dateutil.relativedelta.relativedelta(days=1)
217
- return last_day
218
-
219
-
220
- def last_day_of_next_month():
221
- today = datetime.datetime.today()
222
- first_of_next_month = today.replace(day=1) + dateutil.relativedelta.relativedelta(
223
- months=2
224
- )
225
- last_day = first_of_next_month - dateutil.relativedelta.relativedelta(days=1)
226
- return last_day
227
-
228
-
229
- def last_day_of_next_next_month():
230
- today = datetime.datetime.today()
231
- first_of_next_month = today.replace(day=1) + dateutil.relativedelta.relativedelta(
232
- months=3
233
- )
234
- last_day = first_of_next_month - dateutil.relativedelta.relativedelta(days=1)
235
- return last_day
236
-
237
-
238
- def ten_days_from_now():
239
- today = datetime.datetime.today()
240
- return today + dateutil.relativedelta.relativedelta(days=10)
241
-
242
-
243
- # ------------------------------------------------
244
-
245
-
246
- def get_tipologia_risoluzione():
247
- table = {
248
- "CC01-1": ("CAE0", None),
249
- "CC01-2": ("CAE0", None),
250
- "CC02": ("CAE8", "CA7"),
251
- "CC03-1": ("CAE5", "CA5"),
252
- "CC04-1": ("CAE8", "CA4"),
253
- "CC05-1": ("CAE2", "CA6"),
254
- "CC06-1": ("CAE8", "CA7"),
255
- "CC12-1": ("CAE1", "CA1"),
256
- "CC13-1": ("CAE8", "CA7"),
257
- "CC26-1": ("CAE7", "CA3"),
258
- "CC27-1": ("CAE3", "CA2"),
259
- }
260
-
261
- code = case_id.ticket_type_id.code
262
-
263
- if code not in table:
264
- raise ValidationError(
265
- "Non è possibile determinare la tipologia di risoluzione per il dettaglio {}".format(
266
- code
267
- )
268
- )
269
-
270
- power, gas = table.get(code)
271
-
272
- sp = first(case_id.service_point_ids)
273
-
274
- if sp.pod_id and power:
275
- return power
276
-
277
- if sp.pdr_id and gas:
278
- return gas
279
-
280
- raise ValidationError(
281
- "Non è possibile determinare la tipologia di risoluzione per il dettaglio {}".format(
282
- code
283
- )
284
- )
285
-
286
-
287
- def get_data_decorrenza(tipologia_risoluzione):
288
- today = datetime.datetime.today()
289
- code = case_id.ticket_type_id.code
290
-
291
- # -------- Special Case --------
292
-
293
- if tipologia_risoluzione == "CA1":
294
- return fmt(ten_days_from_now())
295
-
296
- if tipologia_risoluzione in ["CA2", "CA3"]:
297
- return fmt(last_day_of_next_next_month())
298
-
299
- if (
300
- tipologia_risoluzione == "CA4"
301
- and code == "CC04-1"
302
- and case_id.customer_id.customer_care_category == "pmi"
303
- ):
304
- voltura_start_date = (
305
- today # TODO get real voltura_start_date, don't yet know how
306
- )
307
- if voltura_start_date <= today:
308
- if today.day <= 10:
309
- return fmt(last_day_of_this_month())
310
- return fmt(last_day_of_next_month())
311
- else:
312
- return fmt(voltura_start_date)
313
-
314
- # -------- Default Case --------
315
-
316
- if today.day <= 10:
317
- return fmt(last_day_of_this_month())
318
- return fmt(last_day_of_next_month())
319
-
320
-
321
- # ------------------------------------------------
322
-
323
-
324
- def main():
325
- tipologia_risoluzione = get_tipologia_risoluzione()
326
-
327
- kv_store = case_id.sudo().kv_store()
328
- data_decorrenza = get_data_decorrenza(tipologia_risoluzione)
329
- ifs_data = {
330
- "tipologia_risoluzione": tipologia_risoluzione,
331
- "data_decorrenza": data_decorrenza,
332
- }
333
- kv_store.sudo().set("ifs_data", ifs_data)
334
- case_id.write(
335
- {
336
- "disconnect_date": datetime.datetime.strptime(
337
- data_decorrenza, "%d/%m/%Y"
338
- ).date()
339
- }
340
- )
341
-
342
- sp = first(case_id.service_point_ids)
343
- asset = sp.asset(active=True) # solo sm_state attivo
344
-
345
- if not asset:
346
- raise Exception("Asset attivo non trovato per il punto {}".format(sp.code))
347
-
348
- case_id.sudo().kv_store().set("asset", asset.data)
349
-
350
- date_fmt = datetime.datetime.now().strftime("%Y-%m-%dT%H:%M:%S.%f") + "Z"
351
-
352
- sp.sudo().write({"state": "deactivating"})
353
- env["ir.config_parameter"].update_b2w_statemodel(
354
- "in_cessazione",
355
- sm_reason=case_id.ticket_type_id.name,
356
- expected_date=date_fmt,
357
- asset_id=str(asset._id),
358
- )
359
-
360
- return "OK"
361
-
362
-
363
- try:
364
- result = main()
365
- except Exception as e:
366
- logs.append({"message": str(e), "traceback": format_exc()})
367
- case_id.write(
368
- {"error_message": "Errore durante l'esecuzione della fase: {}".format(str(e))}
369
- )
370
-
371
-
372
- if logs:
373
- log(json_dumps(logs))]]></field>
374
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
375
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
376
- <field name="is_a_postalizer_phase">False</field>
377
- <field name="is_compute_refund">False</field>
378
- <field name="is_dl">False</field>
379
- <field name="is_needs_child_case">False</field>
380
- <field name="is_pick_refund_template">False</field>
381
- <field name="is_process_managed">False</field>
382
- <field name="is_quote_accepted">False</field>
383
- <field name="is_quote_sent">False</field>
384
- <field name="is_timeout">False</field>
385
- <field name="is_voidable">False</field>
386
- <field name="name">A1672 - Recupero dati a CRM</field>
387
- <field name="set_result_automatically">from_code</field>
388
- </record>
389
- <record id="symple_triplet_phase_result_C2654_-_Processo_Compatibile_E-CC01-0004" model="symple.triplet.phase.result">
390
- <field name="active">True</field>
391
- <field name="has_message">False</field>
392
- <field name="is_annulment">False</field>
393
- <field name="is_dl_solicitation_result">False</field>
394
- <field name="is_hidden">False</field>
395
- <field name="is_quote_expired">False</field>
396
- <field name="name">C2654 - Processo Compatibile</field>
397
- <field name="next_phase_id" ref="symple_triplet_phase_A1672_-_Recupero_dati_a_CRM"/>
398
- <field name="state_code">E-CC01-0004</field>
399
- <field name="wizard_result">SUCCESS</field>
400
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1709_-_verifica_compatibilit_')])]"/>
401
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
402
- </record>
403
- <record id="symple_triplet_phase_result_C2639_-_Incompatibilit__Non_bloccante_E-CC01-0005" model="symple.triplet.phase.result">
404
- <field name="active">True</field>
405
- <field name="has_message">False</field>
406
- <field name="is_annulment">False</field>
407
- <field name="is_dl_solicitation_result">False</field>
408
- <field name="is_hidden">False</field>
409
- <field name="is_quote_expired">False</field>
410
- <field name="name">C2639 - Incompatibilità Non bloccante</field>
411
- <field name="next_phase_id" ref="symple_triplet_phase_A1672_-_Recupero_dati_a_CRM"/>
412
- <field name="state_code">E-CC01-0005</field>
413
- <field name="wizard_result">PARTIAL_KO</field>
414
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1709_-_verifica_compatibilit_')])]"/>
415
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Partial KO')])" />
416
- </record>
417
- <record id="symple_triplet_phase_A1323_-_Errore_CRM__Recupero_dati_" model="symple.triplet.phase">
418
- <field name="active">True</field>
419
- <field name="child_case">False</field>
420
- <field name="code"># Available variables:
421
- # - case_id: the case that just reached this phase
422
- # - request: allows you to make HTTP requests (method, url, headers, data)
423
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
424
- # - json_load: allows you to use JSON.load to convert a json into an object
425
- # - env: Odoo Environment on which the action is triggered
426
- # - time, datetime, dateutil, timezone: useful Python libraries
427
- # - float_compare: Odoo function to compare floats based on specific precisions
428
- # - ValidationError: Warning Exception to use with raise
429
- # - Command: x2Many commands namespace
430
- # - OrderedDict: ordered dictionaries
431
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
432
- # (line = case id, func = phase name)
433
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
434
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
435
- # To return a result, assign: result = {...}
436
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
437
- # phase result will not be set.
438
-
439
-
440
-
441
- </field>
442
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','AMS')])" />
443
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
444
- <field name="is_a_postalizer_phase">False</field>
445
- <field name="is_compute_refund">False</field>
446
- <field name="is_dl">False</field>
447
- <field name="is_needs_child_case">False</field>
448
- <field name="is_pick_refund_template">False</field>
449
- <field name="is_process_managed">False</field>
450
- <field name="is_quote_accepted">False</field>
451
- <field name="is_quote_sent">False</field>
452
- <field name="is_timeout">False</field>
453
- <field name="is_voidable">False</field>
454
- <field name="name">A1323 - Errore CRM (Recupero dati)</field>
455
- </record>
456
- <record id="symple_triplet_phase_result_C1933_-_Recupero_Dati_KO_E-CC01-0009" model="symple.triplet.phase.result">
457
- <field name="active">True</field>
458
- <field name="has_message">False</field>
459
- <field name="is_annulment">False</field>
460
- <field name="is_dl_solicitation_result">False</field>
461
- <field name="is_hidden">False</field>
462
- <field name="is_quote_expired">False</field>
463
- <field name="name">C1933 - Recupero Dati KO</field>
464
- <field name="next_phase_id" ref="symple_triplet_phase_A1323_-_Errore_CRM__Recupero_dati_"/>
465
- <field name="state_code">E-CC01-0009</field>
466
- <field name="wizard_result">KO</field>
467
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1672_-_Recupero_dati_a_CRM')])]"/>
468
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO')])" />
469
- </record>
470
- <record id="symple_triplet_phase_result_C1616_-_Risoluzione_Errore_E-CC01-0010" model="symple.triplet.phase.result">
471
- <field name="active">True</field>
472
- <field name="has_message">False</field>
473
- <field name="is_annulment">False</field>
474
- <field name="is_dl_solicitation_result">False</field>
475
- <field name="is_hidden">False</field>
476
- <field name="is_quote_expired">False</field>
477
- <field name="name">C1616 - Risoluzione Errore</field>
478
- <field name="next_phase_id" ref="symple_triplet_phase_A1672_-_Recupero_dati_a_CRM"/>
479
- <field name="state_code">E-CC01-0010</field>
480
- <field name="wizard_result">SUCCESS</field>
481
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1323_-_Errore_CRM__Recupero_dati_')])]"/>
482
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
483
- </record>
484
- <record id="symple_triplet_phase_A1559_-_Invio_alla_Market_Communication" model="symple.triplet.phase">
485
- <field name="active">True</field>
486
- <field name="child_case">False</field>
487
- <field name="code"># Available variables:
488
- # - case_id: the case that just reached this phase
489
- # - request: allows you to make HTTP requests (method, url, headers, data)
490
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
491
- # - json_load: allows you to use JSON.load to convert a json into an object
492
- # - env: Odoo Environment on which the action is triggered
493
- # - time, datetime, dateutil, timezone: useful Python libraries
494
- # - float_compare: Odoo function to compare floats based on specific precisions
495
- # - ValidationError: Warning Exception to use with raise
496
- # - Command: x2Many commands namespace
497
- # - OrderedDict: ordered dictionaries
498
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
499
- # (line = case id, func = phase name)
500
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
501
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
502
- # To return a result, assign: result = {...}
503
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
504
- # phase result will not be set.
505
-
506
-
507
- logs = []
508
-
509
- # ------------------------------
510
-
511
-
512
- def get_addizione_regionale():
513
- return case_id.service_point_ids[0].regional_surcharge_value
514
-
515
-
516
- # ------------------------------
517
-
518
-
519
- def get_resubmit_bindings():
520
- return {
521
- "helpdesk_ticket": {
522
- "ids": [
523
- case_id.id,
524
- ]
525
- },
526
- "billing_profile": {"ids": []},
527
- "service_point": {"ids": []},
528
- "res_partner_pod": {"ids": []},
529
- "res_partner_pdr": {"ids": []},
530
- }
531
-
532
-
533
- def shared_data():
534
- sp = case_id.service_point_ids
535
- ifs_data = case_id.sudo().kv_store().get("ifs_data")
536
- tipologia_risoluzione = ifs_data.get("tipologia_risoluzione")
537
-
538
- return {
539
- "COD_FLUSSO": "0050",
540
- "PIVA": case_id.customer_id.numbers_only_vat or "",
541
- "CF": case_id.customer_id.fiscal_code or "",
542
- "CF_STRANIERO": "0",
543
- "ALIQUOTA_IVA": (
544
- sp.iva_rate if tipologia_risoluzione not in ["CAE1", "CA1"] else ""
545
- ),
546
- "ALIQUOTA_ACCISE": "0" if tipologia_risoluzione not in ["CAE1", "CA1"] else "",
547
- "ADDIZ_PROVINCIALE": (
548
- "0" if tipologia_risoluzione not in ["CAE1", "CA1"] else ""
549
- ),
550
- "ADDIZ_COMUNALE": "0" if tipologia_risoluzione not in ["CAE1", "CA1"] else "",
551
- "TIPOLOGIA_RISOLUZIONE": tipologia_risoluzione,
552
- "DATA_DECORRENZA": ifs_data.get("data_decorrenza"),
553
- "OWNER": "SORGE",
554
- }
555
-
556
-
557
- # ------------------------------
558
-
559
-
560
- def prep_rc1():
561
- message = shared_data()
562
- message.update(
563
- {"COD_SERVIZIO": "RC1", "COD_POD": case_id.service_point_ids[0].pod_id.code}
564
- )
565
- return message
566
-
567
-
568
- def _not_cae1_ca1(value, tipologia_risoluzione):
569
- if tipologia_risoluzione in ["CAE1", "CA1"]:
570
- return ""
571
- return value
572
-
573
-
574
- def prep_rcg1():
575
- ifs_data = case_id.sudo().kv_store().get("ifs_data")
576
- tipologia_risoluzione = ifs_data.get("tipologia_risoluzione")
577
- message = shared_data()
578
- is_person = not case_id.customer_id.is_company
579
- is_ui = message["TIPOLOGIA_RISOLUZIONE"] != "CA4"
580
- service_point = case_id.service_point_ids[0]
581
- invoicing_address = service_point.billing_profile_id.invoicing_address_id
582
- message.update(
583
- {
584
- "COD_SERVIZIO": "RCG1",
585
- "COD_PDR": case_id.service_point_ids[0].pdr_id.code,
586
- "MOTIVAZIONE": "Scelta commerciale Sorgenia",
587
- "PRIORITA": "",
588
- "ALTRE_INFORMAZIONI": "",
589
- "NOME": _not_cae1_ca1(
590
- case_id.customer_id.firstname if is_person else "",
591
- tipologia_risoluzione,
592
- ),
593
- "COGNOME": _not_cae1_ca1(
594
- case_id.customer_id.lastname if is_person else "", tipologia_risoluzione
595
- ),
596
- "EMAIL": _not_cae1_ca1(
597
- case_id.customer_id.email or "", tipologia_risoluzione
598
- ),
599
- "TELEFONO": _not_cae1_ca1(
600
- case_id.customer_id.phone or "", tipologia_risoluzione
601
- ),
602
- "ACCESSO_FUI": _not_cae1_ca1(
603
- "SI" if message["TIPOLOGIA_RISOLUZIONE"] == "CA4" else "NO",
604
- tipologia_risoluzione,
605
- ),
606
- "UI_CF": _not_cae1_ca1(
607
- case_id.customer_id.fiscal_code if is_ui else "", tipologia_risoluzione
608
- ),
609
- "UI_PIVA": _not_cae1_ca1(
610
- case_id.customer_id.vat if is_ui else "", tipologia_risoluzione
611
- ),
612
- "UI_CF_STRANIERO": _not_cae1_ca1("", tipologia_risoluzione),
613
- "UI_NOME": _not_cae1_ca1(
614
- case_id.customer_id.firstname if is_ui and is_person else "",
615
- tipologia_risoluzione,
616
- ),
617
- "UI_COGNOME": _not_cae1_ca1(
618
- case_id.customer_id.lastname if is_ui and is_person else "",
619
- tipologia_risoluzione,
620
- ),
621
- "UI_RAGIONE_SOCIALE_DENOMINAZIONE": _not_cae1_ca1(
622
- case_id.customer_id.name if is_ui and not is_person else "",
623
- tipologia_risoluzione,
624
- ),
625
- "UI_EMAIL": _not_cae1_ca1(
626
- case_id.customer_id.email or "" if is_ui else "", tipologia_risoluzione
627
- ),
628
- "UI_TELEFONO": _not_cae1_ca1(
629
- case_id.customer_id.phone or "" if is_ui else "", tipologia_risoluzione
630
- ),
631
- "UI_AF_CF": _not_cae1_ca1("", tipologia_risoluzione),
632
- "UI_AF_PIVA": _not_cae1_ca1("", tipologia_risoluzione),
633
- "UI_AF_CF_STRANIERO": _not_cae1_ca1("", tipologia_risoluzione),
634
- "UI_AF_NOME": _not_cae1_ca1("", tipologia_risoluzione),
635
- "UI_AF_COGNOME": _not_cae1_ca1("", tipologia_risoluzione),
636
- "UI_AF_RAGIONE_SOCIALE_DENOMINAZIONE": _not_cae1_ca1(
637
- "", tipologia_risoluzione
638
- ),
639
- "UI_FOR_TOPONIMO": _not_cae1_ca1(
640
- service_point.service_toponym_id.name or "", tipologia_risoluzione
641
- ),
642
- "UI_FOR_VIA": _not_cae1_ca1(
643
- service_point.service_street or "", tipologia_risoluzione
644
- ),
645
- "UI_FOR_CIV": _not_cae1_ca1(
646
- service_point.service_street_number or "", tipologia_risoluzione
647
- ),
648
- "UI_FOR_CAP": _not_cae1_ca1(
649
- service_point.service_zip or "40100", tipologia_risoluzione
650
- ),
651
- "UI_FOR_ISTAT": _not_cae1_ca1(
652
- service_point.service_city_id.istat_code or "", tipologia_risoluzione
653
- ),
654
- "UI_FOR_LOCALITA": _not_cae1_ca1(
655
- service_point.service_city_id.name or "", tipologia_risoluzione
656
- ),
657
- "UI_FOR_PROV": _not_cae1_ca1(
658
- service_point.service_state_code or "", tipologia_risoluzione
659
- ),
660
- "UI_FOR_NAZIONE": (
661
- _not_cae1_ca1(
662
- service_point.service_country_id.with_context(
663
- lang="it_IT"
664
- ).name.upper(),
665
- tipologia_risoluzione,
666
- )
667
- )
668
- or "",
669
- "UI_FOR_ALTRO": "",
670
- "UI_ES_TOPONIMO": _not_cae1_ca1(
671
- invoicing_address.toponym_id.name or "", tipologia_risoluzione
672
- ),
673
- "UI_ES_VIA": _not_cae1_ca1(
674
- invoicing_address.street or "", tipologia_risoluzione
675
- ),
676
- "UI_ES_CIV": _not_cae1_ca1(
677
- invoicing_address.street_num or "", tipologia_risoluzione
678
- ),
679
- "UI_ES_CAP": _not_cae1_ca1(
680
- invoicing_address.zip or "", tipologia_risoluzione
681
- ),
682
- "UI_ES_ISTAT": _not_cae1_ca1(
683
- invoicing_address.istat_code or "", tipologia_risoluzione
684
- ),
685
- "UI_ES_LOCALITA": _not_cae1_ca1(
686
- invoicing_address.city_id.name or "", tipologia_risoluzione
687
- ),
688
- "UI_ES_PROV": _not_cae1_ca1(
689
- invoicing_address.state_code or "", tipologia_risoluzione
690
- ),
691
- "UI_ES_NAZIONE": _not_cae1_ca1(
692
- invoicing_address.country_id.with_context(lang="it_IT").name.upper()
693
- or "",
694
- tipologia_risoluzione,
695
- ),
696
- "UI_ES_ALTRO": _not_cae1_ca1("", tipologia_risoluzione),
697
- "UI_CODICE_UFFICIO": service_point.billing_profile_id.office_code or "",
698
- "UI_PAGAMENTO_IVA": "",
699
- "SETT_MERCEOLOGICO": "",
700
- "COD_RICHIESTA": "",
701
- "ADDIZ_REGIONALE": (
702
- get_addizione_regionale()
703
- if message["TIPOLOGIA_RISOLUZIONE"] != "CA1"
704
- else ""
705
- ),
706
- }
707
- )
708
- return message
709
-
710
-
711
- # ------------------------------
712
-
713
-
714
- def main():
715
- ifs_data_message = None
716
- is_ele = case_id.service_point_ids[0].pod_id.exists()
717
-
718
- if is_ele:
719
- ifs_data_message = prep_rc1()
720
- else:
721
- ifs_data_message = prep_rcg1()
722
-
723
- ifs_dict = {
724
- "ifs_code": "RC1" if is_ele else "RCG1",
725
- "case_id": str(case_id.id),
726
- "entity_bindings_resubmit": get_resubmit_bindings(),
727
- "ifs_data_message": ifs_data_message,
728
- }
729
- ifs_json = json_dumps(ifs_dict)
730
- tenant_id = env["ir.config_parameter"].sudo().get_param("m2c_header_tenant_id")
731
- org_token = env["ir.config_parameter"].sudo().get_param("m2c_header_org_token")
732
- headers = {"tenantId": tenant_id, "orgToken": org_token}
733
- btw_url = "http://b2w-symphony-rest-service/api/symphony/process-instances/ml_IFS_passthrough"
734
- response = request("POST", btw_url, headers=headers, data=ifs_json)
735
-
736
- if str(response.status_code) != "200":
737
- raise ValidationError(str(response.status_code) + " " + str(response.text))
738
-
739
- return "OK"
740
-
741
-
742
- try:
743
- result = main()
744
- except Exception as e:
745
- logs.append({"message": str(e), "traceback": format_exc()})
746
- prev = case_id.info_message + "\n" if case_id.info_message else ""
747
- case_id.write({"info_message": prev + str(e)})
748
-
749
- result = "KO"
750
-
751
-
752
- if logs:
753
- log(json_dumps(logs))</field>
754
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
755
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
756
- <field name="is_a_postalizer_phase">False</field>
757
- <field name="is_compute_refund">False</field>
758
- <field name="is_dl">False</field>
759
- <field name="is_needs_child_case">False</field>
760
- <field name="is_pick_refund_template">False</field>
761
- <field name="is_process_managed">False</field>
762
- <field name="is_quote_accepted">False</field>
763
- <field name="is_quote_sent">False</field>
764
- <field name="is_timeout">False</field>
765
- <field name="is_voidable">False</field>
766
- <field name="name">A1559 - Invio alla Market Communication</field>
767
- <field name="set_result_automatically">from_code</field>
768
- </record>
769
- <record id="symple_triplet_phase_result_C2365_-_Recupero_Dati_OK_E-CC01-0008" model="symple.triplet.phase.result">
770
- <field name="active">True</field>
771
- <field name="has_message">False</field>
772
- <field name="is_annulment">False</field>
773
- <field name="is_dl_solicitation_result">False</field>
774
- <field name="is_hidden">False</field>
775
- <field name="is_quote_expired">False</field>
776
- <field name="name">C2365 - Recupero Dati OK</field>
777
- <field name="next_phase_id" ref="symple_triplet_phase_A1559_-_Invio_alla_Market_Communication"/>
778
- <field name="state_code">E-CC01-0008</field>
779
- <field name="wizard_result">SUCCESS</field>
780
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1672_-_Recupero_dati_a_CRM')])]"/>
781
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
782
- </record>
783
- <record id="symple_triplet_phase_A1715_-_In_attesa_check_IFS" model="symple.triplet.phase">
784
- <field name="active">True</field>
785
- <field name="child_case">False</field>
786
- <field name="code"># Available variables:
787
- # - case_id: the case that just reached this phase
788
- # - request: allows you to make HTTP requests (method, url, headers, data)
789
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
790
- # - json_load: allows you to use JSON.load to convert a json into an object
791
- # - env: Odoo Environment on which the action is triggered
792
- # - time, datetime, dateutil, timezone: useful Python libraries
793
- # - float_compare: Odoo function to compare floats based on specific precisions
794
- # - ValidationError: Warning Exception to use with raise
795
- # - Command: x2Many commands namespace
796
- # - OrderedDict: ordered dictionaries
797
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
798
- # (line = case id, func = phase name)
799
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
800
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
801
- # To return a result, assign: result = {...}
802
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
803
- # phase result will not be set.
804
-
805
-
806
-
807
- </field>
808
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
809
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
810
- <field name="is_a_postalizer_phase">False</field>
811
- <field name="is_compute_refund">False</field>
812
- <field name="is_dl">False</field>
813
- <field name="is_needs_child_case">False</field>
814
- <field name="is_pick_refund_template">False</field>
815
- <field name="is_process_managed">False</field>
816
- <field name="is_quote_accepted">False</field>
817
- <field name="is_quote_sent">False</field>
818
- <field name="is_timeout">False</field>
819
- <field name="is_voidable">False</field>
820
- <field name="name">A1715 - In attesa check IFS</field>
821
- </record>
822
- <record id="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0011" model="symple.triplet.phase.result">
823
- <field name="active">True</field>
824
- <field name="has_message">False</field>
825
- <field name="is_annulment">False</field>
826
- <field name="is_dl_solicitation_result">False</field>
827
- <field name="is_hidden">False</field>
828
- <field name="is_quote_expired">False</field>
829
- <field name="name">C1019 - Inviata</field>
830
- <field name="next_phase_id" ref="symple_triplet_phase_A1715_-_In_attesa_check_IFS"/>
831
- <field name="state_code">E-CC01-0011</field>
832
- <field name="wizard_result">SUCCESS</field>
833
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1559_-_Invio_alla_Market_Communication')])]"/>
834
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
835
- </record>
836
- <record id="symple_triplet_phase_A1717_-_Gestione_scarti_da_cruscotto" model="symple.triplet.phase">
837
- <field name="active">True</field>
838
- <field name="child_case">False</field>
839
- <field name="code"># Available variables:
840
- # - case_id: the case that just reached this phase
841
- # - request: allows you to make HTTP requests (method, url, headers, data)
842
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
843
- # - json_load: allows you to use JSON.load to convert a json into an object
844
- # - env: Odoo Environment on which the action is triggered
845
- # - time, datetime, dateutil, timezone: useful Python libraries
846
- # - float_compare: Odoo function to compare floats based on specific precisions
847
- # - ValidationError: Warning Exception to use with raise
848
- # - Command: x2Many commands namespace
849
- # - OrderedDict: ordered dictionaries
850
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
851
- # (line = case id, func = phase name)
852
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
853
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
854
- # To return a result, assign: result = {...}
855
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
856
- # phase result will not be set.
857
-
858
-
859
-
860
- </field>
861
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
862
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
863
- <field name="is_a_postalizer_phase">False</field>
864
- <field name="is_compute_refund">False</field>
865
- <field name="is_dl">False</field>
866
- <field name="is_needs_child_case">False</field>
867
- <field name="is_pick_refund_template">False</field>
868
- <field name="is_process_managed">False</field>
869
- <field name="is_quote_accepted">False</field>
870
- <field name="is_quote_sent">False</field>
871
- <field name="is_timeout">False</field>
872
- <field name="is_voidable">False</field>
873
- <field name="name">A1717 - Gestione scarti da cruscotto</field>
874
- </record>
875
- <record id="symple_triplet_phase_result_C2225_-_KO_-_Ammissibilit__Hub_E-CC01-0012" model="symple.triplet.phase.result">
876
- <field name="active">True</field>
877
- <field name="has_message">False</field>
878
- <field name="is_annulment">False</field>
879
- <field name="is_dl_solicitation_result">False</field>
880
- <field name="is_hidden">False</field>
881
- <field name="is_quote_expired">False</field>
882
- <field name="name">C2225 - KO - Ammissibilità Hub</field>
883
- <field name="next_phase_id" ref="symple_triplet_phase_A1717_-_Gestione_scarti_da_cruscotto"/>
884
- <field name="state_code">E-CC01-0012</field>
885
- <field name="wizard_result">KO-HUB</field>
886
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1715_-_In_attesa_check_IFS')])]"/>
887
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO-HUB')])" />
888
- </record>
889
- <record id="symple_triplet_phase_result_C2416_-_risottomessa_da_cruscotto_E-CC01-0015" model="symple.triplet.phase.result">
890
- <field name="active">True</field>
891
- <field name="has_message">False</field>
892
- <field name="is_annulment">False</field>
893
- <field name="is_dl_solicitation_result">False</field>
894
- <field name="is_hidden">False</field>
895
- <field name="is_quote_expired">False</field>
896
- <field name="name">C2416 - risottomessa da cruscotto</field>
897
- <field name="next_phase_id" ref="symple_triplet_phase_A1715_-_In_attesa_check_IFS"/>
898
- <field name="state_code">E-CC01-0015</field>
899
- <field name="wizard_result">RESUBMIT</field>
900
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1717_-_Gestione_scarti_da_cruscotto')])]"/>
901
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Resubmit')])" />
902
- </record>
903
- <record id="symple_triplet_phase_A2558_-_verifica_avvio_gestione_manuale" model="symple.triplet.phase">
904
- <field name="active">True</field>
905
- <field name="child_case">False</field>
906
- <field name="code"># Available variables:
907
- # - case_id: the case that just reached this phase
908
- # - request: allows you to make HTTP requests (method, url, headers, data)
909
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
910
- # - json_load: allows you to use JSON.load to convert a json into an object
911
- # - env: Odoo Environment on which the action is triggered
912
- # - time, datetime, dateutil, timezone: useful Python libraries
913
- # - float_compare: Odoo function to compare floats based on specific precisions
914
- # - ValidationError: Warning Exception to use with raise
915
- # - Command: x2Many commands namespace
916
- # - OrderedDict: ordered dictionaries
917
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
918
- # (line = case id, func = phase name)
919
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
920
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
921
- # To return a result, assign: result = {...}
922
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
923
- # phase result will not be set.
924
-
925
-
926
-
927
- </field>
928
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','BOT')])" />
929
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
930
- <field name="is_a_postalizer_phase">False</field>
931
- <field name="is_compute_refund">False</field>
932
- <field name="is_dl">False</field>
933
- <field name="is_needs_child_case">False</field>
934
- <field name="is_pick_refund_template">False</field>
935
- <field name="is_process_managed">False</field>
936
- <field name="is_quote_accepted">False</field>
937
- <field name="is_quote_sent">False</field>
938
- <field name="is_timeout">False</field>
939
- <field name="is_voidable">False</field>
940
- <field name="name">A2558 - verifica avvio gestione manuale</field>
941
- </record>
942
- <record id="symple_triplet_phase_result_C2509_-_Da_gestire_nuovo_invio_automatico_E-CC01-0019" model="symple.triplet.phase.result">
943
- <field name="active">True</field>
944
- <field name="has_message">False</field>
945
- <field name="is_annulment">False</field>
946
- <field name="is_dl_solicitation_result">False</field>
947
- <field name="is_hidden">False</field>
948
- <field name="is_quote_expired">False</field>
949
- <field name="name">C2509 - Da gestire nuovo invio automatico</field>
950
- <field name="next_phase_id" ref="symple_triplet_phase_A1559_-_Invio_alla_Market_Communication"/>
951
- <field name="state_code">E-CC01-0019</field>
952
- <field name="wizard_result">KO</field>
953
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2558_-_verifica_avvio_gestione_manuale')])]"/>
954
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO')])" />
955
- </record>
956
- <record id="symple_triplet_phase_A1879_-_Invio_alla_Market_Comm_Forzato" model="symple.triplet.phase">
957
- <field name="active">True</field>
958
- <field name="child_case">False</field>
959
- <field name="code"># Available variables:
960
- # - case_id: the case that just reached this phase
961
- # - request: allows you to make HTTP requests (method, url, headers, data)
962
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
963
- # - json_load: allows you to use JSON.load to convert a json into an object
964
- # - env: Odoo Environment on which the action is triggered
965
- # - time, datetime, dateutil, timezone: useful Python libraries
966
- # - float_compare: Odoo function to compare floats based on specific precisions
967
- # - ValidationError: Warning Exception to use with raise
968
- # - Command: x2Many commands namespace
969
- # - OrderedDict: ordered dictionaries
970
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
971
- # (line = case id, func = phase name)
972
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
973
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
974
- # To return a result, assign: result = {...}
975
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
976
- # phase result will not be set.
977
-
978
-
979
-
980
- </field>
981
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
982
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
983
- <field name="is_a_postalizer_phase">False</field>
984
- <field name="is_compute_refund">False</field>
985
- <field name="is_dl">False</field>
986
- <field name="is_needs_child_case">False</field>
987
- <field name="is_pick_refund_template">False</field>
988
- <field name="is_process_managed">False</field>
989
- <field name="is_quote_accepted">False</field>
990
- <field name="is_quote_sent">False</field>
991
- <field name="is_timeout">False</field>
992
- <field name="is_voidable">False</field>
993
- <field name="name">A1879 - Invio alla Market Comm Forzato</field>
994
- </record>
995
- <record id="symple_triplet_phase_result_C2598_-_gestione_manuale_E-CC01-0018" model="symple.triplet.phase.result">
996
- <field name="active">True</field>
997
- <field name="has_message">False</field>
998
- <field name="is_annulment">False</field>
999
- <field name="is_dl_solicitation_result">False</field>
1000
- <field name="is_hidden">False</field>
1001
- <field name="is_quote_expired">False</field>
1002
- <field name="name">C2598 - gestione manuale</field>
1003
- <field name="next_phase_id" ref="symple_triplet_phase_A1879_-_Invio_alla_Market_Comm_Forzato"/>
1004
- <field name="state_code">E-CC01-0018</field>
1005
- <field name="wizard_result">SUCCESS</field>
1006
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2558_-_verifica_avvio_gestione_manuale')])]"/>
1007
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1008
- </record>
1009
- <record id="symple_triplet_phase_A1806_-_In_Attesa_Check_HUB_Forzato" model="symple.triplet.phase">
1010
- <field name="active">True</field>
1011
- <field name="child_case">False</field>
1012
- <field name="code"># Available variables:
1013
- # - case_id: the case that just reached this phase
1014
- # - request: allows you to make HTTP requests (method, url, headers, data)
1015
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1016
- # - json_load: allows you to use JSON.load to convert a json into an object
1017
- # - env: Odoo Environment on which the action is triggered
1018
- # - time, datetime, dateutil, timezone: useful Python libraries
1019
- # - float_compare: Odoo function to compare floats based on specific precisions
1020
- # - ValidationError: Warning Exception to use with raise
1021
- # - Command: x2Many commands namespace
1022
- # - OrderedDict: ordered dictionaries
1023
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1024
- # (line = case id, func = phase name)
1025
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1026
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1027
- # To return a result, assign: result = {...}
1028
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1029
- # phase result will not be set.
1030
-
1031
-
1032
-
1033
- </field>
1034
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1035
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1036
- <field name="is_a_postalizer_phase">False</field>
1037
- <field name="is_compute_refund">False</field>
1038
- <field name="is_dl">False</field>
1039
- <field name="is_needs_child_case">False</field>
1040
- <field name="is_pick_refund_template">False</field>
1041
- <field name="is_process_managed">False</field>
1042
- <field name="is_quote_accepted">False</field>
1043
- <field name="is_quote_sent">False</field>
1044
- <field name="is_timeout">False</field>
1045
- <field name="is_voidable">False</field>
1046
- <field name="name">A1806 - In Attesa Check HUB Forzato</field>
1047
- </record>
1048
- <record id="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0020" model="symple.triplet.phase.result">
1049
- <field name="active">True</field>
1050
- <field name="has_message">False</field>
1051
- <field name="is_annulment">False</field>
1052
- <field name="is_dl_solicitation_result">False</field>
1053
- <field name="is_hidden">False</field>
1054
- <field name="is_quote_expired">False</field>
1055
- <field name="name">C1019 - Inviata</field>
1056
- <field name="next_phase_id" ref="symple_triplet_phase_A1806_-_In_Attesa_Check_HUB_Forzato"/>
1057
- <field name="state_code">E-CC01-0020</field>
1058
- <field name="wizard_result">SUCCESS</field>
1059
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1879_-_Invio_alla_Market_Comm_Forzato')])]"/>
1060
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1061
- </record>
1062
- <record id="symple_triplet_phase_A1834_-_Gestione_scarti_da_cruscotto_forzato" model="symple.triplet.phase">
1063
- <field name="active">True</field>
1064
- <field name="child_case">False</field>
1065
- <field name="code"># Available variables:
1066
- # - case_id: the case that just reached this phase
1067
- # - request: allows you to make HTTP requests (method, url, headers, data)
1068
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1069
- # - json_load: allows you to use JSON.load to convert a json into an object
1070
- # - env: Odoo Environment on which the action is triggered
1071
- # - time, datetime, dateutil, timezone: useful Python libraries
1072
- # - float_compare: Odoo function to compare floats based on specific precisions
1073
- # - ValidationError: Warning Exception to use with raise
1074
- # - Command: x2Many commands namespace
1075
- # - OrderedDict: ordered dictionaries
1076
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1077
- # (line = case id, func = phase name)
1078
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1079
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1080
- # To return a result, assign: result = {...}
1081
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1082
- # phase result will not be set.
1083
-
1084
-
1085
-
1086
- </field>
1087
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1088
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1089
- <field name="is_a_postalizer_phase">False</field>
1090
- <field name="is_compute_refund">False</field>
1091
- <field name="is_dl">False</field>
1092
- <field name="is_needs_child_case">False</field>
1093
- <field name="is_pick_refund_template">False</field>
1094
- <field name="is_process_managed">False</field>
1095
- <field name="is_quote_accepted">False</field>
1096
- <field name="is_quote_sent">False</field>
1097
- <field name="is_timeout">False</field>
1098
- <field name="is_voidable">False</field>
1099
- <field name="name">A1834 - Gestione scarti da cruscotto forzato</field>
1100
- </record>
1101
- <record id="symple_triplet_phase_result_C2225_-_KO_-_Ammissibilit__Hub_E-CC01-0021" model="symple.triplet.phase.result">
1102
- <field name="active">True</field>
1103
- <field name="has_message">False</field>
1104
- <field name="is_annulment">False</field>
1105
- <field name="is_dl_solicitation_result">False</field>
1106
- <field name="is_hidden">False</field>
1107
- <field name="is_quote_expired">False</field>
1108
- <field name="name">C2225 - KO - Ammissibilità Hub</field>
1109
- <field name="next_phase_id" ref="symple_triplet_phase_A1834_-_Gestione_scarti_da_cruscotto_forzato"/>
1110
- <field name="state_code">E-CC01-0021</field>
1111
- <field name="wizard_result">KO-HUB</field>
1112
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1806_-_In_Attesa_Check_HUB_Forzato')])]"/>
1113
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO-HUB')])" />
1114
- </record>
1115
- <record id="symple_triplet_phase_result_C2416_-_risottomessa_da_cruscotto_E-CC01-0023" model="symple.triplet.phase.result">
1116
- <field name="active">True</field>
1117
- <field name="has_message">False</field>
1118
- <field name="is_annulment">False</field>
1119
- <field name="is_dl_solicitation_result">False</field>
1120
- <field name="is_hidden">False</field>
1121
- <field name="is_quote_expired">False</field>
1122
- <field name="name">C2416 - risottomessa da cruscotto</field>
1123
- <field name="next_phase_id" ref="symple_triplet_phase_A1806_-_In_Attesa_Check_HUB_Forzato"/>
1124
- <field name="state_code">E-CC01-0023</field>
1125
- <field name="wizard_result">RESUBMIT</field>
1126
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1834_-_Gestione_scarti_da_cruscotto_forzato')])]"/>
1127
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Resubmit')])" />
1128
- </record>
1129
- <record id="symple_triplet_phase_A0816_-_In_attesa_esito_ammissibilit_" model="symple.triplet.phase">
1130
- <field name="active">True</field>
1131
- <field name="child_case">False</field>
1132
- <field name="code"># Available variables:
1133
- # - case_id: the case that just reached this phase
1134
- # - request: allows you to make HTTP requests (method, url, headers, data)
1135
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1136
- # - json_load: allows you to use JSON.load to convert a json into an object
1137
- # - env: Odoo Environment on which the action is triggered
1138
- # - time, datetime, dateutil, timezone: useful Python libraries
1139
- # - float_compare: Odoo function to compare floats based on specific precisions
1140
- # - ValidationError: Warning Exception to use with raise
1141
- # - Command: x2Many commands namespace
1142
- # - OrderedDict: ordered dictionaries
1143
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1144
- # (line = case id, func = phase name)
1145
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1146
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1147
- # To return a result, assign: result = {...}
1148
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1149
- # phase result will not be set.
1150
-
1151
-
1152
-
1153
- </field>
1154
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1155
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1156
- <field name="is_a_postalizer_phase">False</field>
1157
- <field name="is_compute_refund">False</field>
1158
- <field name="is_dl">False</field>
1159
- <field name="is_needs_child_case">False</field>
1160
- <field name="is_pick_refund_template">False</field>
1161
- <field name="is_process_managed">False</field>
1162
- <field name="is_quote_accepted">False</field>
1163
- <field name="is_quote_sent">False</field>
1164
- <field name="is_timeout">False</field>
1165
- <field name="is_voidable">False</field>
1166
- <field name="name">A0816 - In attesa esito ammissibilità</field>
1167
- </record>
1168
- <record id="symple_triplet_phase_result_C2224_-_OK_-_Ammissibilit__Hub_E-CC01-0022" model="symple.triplet.phase.result">
1169
- <field name="active">True</field>
1170
- <field name="has_message">False</field>
1171
- <field name="is_annulment">False</field>
1172
- <field name="is_dl_solicitation_result">False</field>
1173
- <field name="is_hidden">False</field>
1174
- <field name="is_quote_expired">False</field>
1175
- <field name="name">C2224 - OK - Ammissibilità Hub</field>
1176
- <field name="next_phase_id" ref="symple_triplet_phase_A0816_-_In_attesa_esito_ammissibilit_"/>
1177
- <field name="state_code">E-CC01-0022</field>
1178
- <field name="wizard_result">OK-HUB</field>
1179
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1806_-_In_Attesa_Check_HUB_Forzato')])]"/>
1180
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','OK-HUB')])" />
1181
- </record>
1182
- <record id="symple_triplet_phase_result_C1038_-_Ammissibilit__KO_E-CC01-0026" model="symple.triplet.phase.result">
1183
- <field name="active">True</field>
1184
- <field name="has_message">False</field>
1185
- <field name="is_annulment">False</field>
1186
- <field name="is_dl_solicitation_result">False</field>
1187
- <field name="is_hidden">False</field>
1188
- <field name="is_quote_expired">False</field>
1189
- <field name="name">C1038 - Ammissibilità KO</field>
1190
- <field name="next_phase_id" ref="symple_triplet_phase_A1717_-_Gestione_scarti_da_cruscotto"/>
1191
- <field name="state_code">E-CC01-0026</field>
1192
- <field name="wizard_result">KO-100</field>
1193
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0816_-_In_attesa_esito_ammissibilit_')])]"/>
1194
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO-100')])" />
1195
- </record>
1196
- <record id="symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza" model="symple.triplet.phase">
1197
- <field name="active">True</field>
1198
- <field name="allowed_process_ids" model="symple.pb.process" eval="[(6, 0, obj().search([('name','in',('ml_annullamento_cessazione',)),]).ids)]" />
1199
- <field name="child_case">False</field>
1200
- <field name="code"># Available variables:
1201
- # - case_id: the case that just reached this phase
1202
- # - request: allows you to make HTTP requests (method, url, headers, data)
1203
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1204
- # - json_load: allows you to use JSON.load to convert a json into an object
1205
- # - env: Odoo Environment on which the action is triggered
1206
- # - time, datetime, dateutil, timezone: useful Python libraries
1207
- # - float_compare: Odoo function to compare floats based on specific precisions
1208
- # - ValidationError: Warning Exception to use with raise
1209
- # - Command: x2Many commands namespace
1210
- # - OrderedDict: ordered dictionaries
1211
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1212
- # (line = case id, func = phase name)
1213
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1214
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1215
- # To return a result, assign: result = {...}
1216
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1217
- # phase result will not be set.
1218
-
1219
-
1220
-
1221
- </field>
1222
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1223
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1224
- <field name="is_a_postalizer_phase">False</field>
1225
- <field name="is_compute_refund">False</field>
1226
- <field name="is_dl">False</field>
1227
- <field name="is_needs_child_case">False</field>
1228
- <field name="is_pick_refund_template">False</field>
1229
- <field name="is_process_managed">False</field>
1230
- <field name="is_quote_accepted">False</field>
1231
- <field name="is_quote_sent">False</field>
1232
- <field name="is_timeout">False</field>
1233
- <field name="is_voidable">False</field>
1234
- <field name="name">A1004 - Verifica RCU + Data decorrenza</field>
1235
- </record>
1236
- <record id="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza" model="symple.triplet.phase">
1237
- <field name="active">True</field>
1238
- <field name="child_case">False</field>
1239
- <field name="code"><![CDATA[# RES1 = C1936 - Data raggiunta
1240
-
1241
- RES1 = "RES1"
1242
-
1243
- logs = []
1244
- debug_logs = []
1245
- error_occurred = False
1246
-
1247
-
1248
- def make_log(message, data=None, always=False):
1249
- log_entry = {"message": message}
1250
- if data is not None:
1251
- log_entry["data"] = data
1252
-
1253
- if always:
1254
- logs.append(log_entry)
1255
- else:
1256
- debug_logs.append(log_entry)
1257
-
1258
-
1259
- # --------------------------------------
1260
-
1261
-
1262
- def main():
1263
- date_to_check = case_id.disconnect_date
1264
- today = datetime.date.today()
1265
- cutoff = today.replace(day=1) - datetime.timedelta(days=1)
1266
- date_reached = date_to_check <= cutoff
1267
- if date_reached:
1268
- return RES1
1269
-
1270
-
1271
- try:
1272
- result = main()
1273
- except Exception as e:
1274
- error_occurred = True
1275
- make_log(
1276
- "Error occurred in phase",
1277
- {"error": str(e), "traceback": format_exc()},
1278
- always=True,
1279
- )
1280
- case_id.write({"error_message": str(e)})
1281
-
1282
-
1283
- if error_occurred and debug_logs:
1284
- logs.append({"message": "debug_logs", "logs": debug_logs})
1285
-
1286
- if logs:
1287
- log(json_dumps(logs, indent=2))]]></field>
1288
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1289
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1290
- <field name="is_a_postalizer_phase">False</field>
1291
- <field name="is_compute_refund">False</field>
1292
- <field name="is_dl">False</field>
1293
- <field name="is_needs_child_case">False</field>
1294
- <field name="is_pick_refund_template">False</field>
1295
- <field name="is_process_managed">False</field>
1296
- <field name="is_quote_accepted">False</field>
1297
- <field name="is_quote_sent">False</field>
1298
- <field name="is_timeout">False</field>
1299
- <field name="is_voidable">False</field>
1300
- <field name="name">A2397 - OK RCU + verifica data decorrenza</field>
1301
- <field name="set_result_automatically">from_code</field>
1302
- </record>
1303
- <record id="symple_triplet_phase_result_C1448_-_OK_controlli_RCU___Data_decorrenza_E-CC01-0027" model="symple.triplet.phase.result">
1304
- <field name="active">True</field>
1305
- <field name="has_message">False</field>
1306
- <field name="is_annulment">False</field>
1307
- <field name="is_dl_solicitation_result">False</field>
1308
- <field name="is_hidden">False</field>
1309
- <field name="is_quote_expired">False</field>
1310
- <field name="name">C1448 - OK controlli RCU + Data decorrenza</field>
1311
- <field name="next_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
1312
- <field name="state_code">E-CC01-0027</field>
1313
- <field name="wizard_result">SUCCESS</field>
1314
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza')])]"/>
1315
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1316
- </record>
1317
- <record id="symple_triplet_phase_A1577_-_Chiusura_Ordine_CRM" model="symple.triplet.phase">
1318
- <field name="active">True</field>
1319
- <field name="child_case">False</field>
1320
- <field name="code"># Available variables:
1321
- # - case_id: the case that just reached this phase
1322
- # - request: allows you to make HTTP requests (method, url, headers, data)
1323
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1324
- # - json_load: allows you to use JSON.load to convert a json into an object
1325
- # - env: Odoo Environment on which the action is triggered
1326
- # - time, datetime, dateutil, timezone: useful Python libraries
1327
- # - float_compare: Odoo function to compare floats based on specific precisions
1328
- # - ValidationError: Warning Exception to use with raise
1329
- # - Command: x2Many commands namespace
1330
- # - OrderedDict: ordered dictionaries
1331
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1332
- # (line = case id, func = phase name)
1333
- # To return a result, assign: result = {...}
1334
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1335
- # phase result will not be set.
1336
-
1337
- logs = []
1338
-
1339
-
1340
- def log_and_parse_response(response, log_message):
1341
- try:
1342
- json_data = response.json()
1343
- logs.append({"message": log_message, "data": json_data})
1344
- return json_data
1345
- except Exception:
1346
- logs.append({"message": log_message, "response_text": response.text})
1347
- return response.text
1348
-
1349
-
1350
- def create_order_disconnect(asset_id, token):
1351
- url = "http://b2w-cpq-order-management-service/v1/order"
1352
- headers = {
1353
- "X-Auth-Request-Access-Token": "" + token,
1354
- "Content-Type": "application/json",
1355
- "generatesession": "true",
1356
- }
1357
- body = {
1358
- "obj_type": "Order",
1359
- "crm_accountcode": case_id.customer_id.user_sequence,
1360
- "accountcode": str(case_id.customer_id.id),
1361
- "type": "Disconnect",
1362
- "subtype": case_id.ticket_type_id.name,
1363
- "industry": "BSP Utility",
1364
- "commodity": "power" if case_id.service_point_ids[0].pod_id else "gas",
1365
- "order_date": case_id.disconnect_date.strftime("%Y-%m-%d"),
1366
- "contract": True,
1367
- "singlecontract": True,
1368
- "assets": [asset_id],
1369
- "options": {
1370
- "userLanguage": "en-US",
1371
- "remotePagination": True,
1372
- "itemsForPage": 10,
1373
- "cartItemsForPage": 10,
1374
- },
1375
- }
1376
-
1377
- logs.append({"message": "Creating order", "data": {"body": body}})
1378
-
1379
- response = request("POST", url, headers=headers, data=json_dumps(body))
1380
- json = log_and_parse_response(
1381
- response,
1382
- "Order creation response",
1383
- )
1384
-
1385
- if response.status_code != 200:
1386
- raise ValidationError("Failed to create order")
1387
-
1388
- return json
1389
-
1390
-
1391
- def bind_catalog(config_id, catalog_id, token):
1392
- logs.append(
1393
- {
1394
- "message": "Binding catalog and order",
1395
- "data": {
1396
- "config_id": config_id,
1397
- "catalog_id": catalog_id,
1398
- },
1399
- }
1400
- )
1401
-
1402
- headers = {
1403
- "X-Auth-Request-Access-Token": "" + token,
1404
- "Content-Type": "application/json",
1405
- "generatesession": "true",
1406
- }
1407
- url = "http://b2w-cpq-catalog-navigator-node-service/v1/configurations/{}/catalogs/{}".format(
1408
- config_id, catalog_id
1409
- )
1410
-
1411
- response = request("GET", url, headers=headers)
1412
- json = log_and_parse_response(
1413
- response,
1414
- "Catalog binding response",
1415
- )
1416
-
1417
- if response.status_code != 200:
1418
- raise ValidationError("Failed to set catalog id on order")
1419
-
1420
- return json
1421
-
1422
-
1423
- def checkout(config_id, token):
1424
- logs.append(
1425
- {
1426
- "message": "Binding catalog and order",
1427
- "data": {
1428
- "config_id": config_id,
1429
- },
1430
- }
1431
- )
1432
-
1433
- headers = {
1434
- "X-Auth-Request-Access-Token": "" + token,
1435
- "Content-Type": "application/json",
1436
- "generatesession": "true",
1437
- }
1438
- url = "http://b2w-cpq-order-management-service/v1/order/{}".format(config_id)
1439
-
1440
- response = request("POST", url, headers=headers, data="{}")
1441
- json = log_and_parse_response(
1442
- response,
1443
- "Checkout response",
1444
- )
1445
-
1446
- if response.status_code != 200:
1447
- raise ValidationError("Failed to checkout")
1448
-
1449
- return json
1450
-
1451
-
1452
- try:
1453
- StagingArea = env["symple.pb.process.data"]
1454
- IrConfigParam = env["ir.config_parameter"].sudo()
1455
- token = IrConfigParam.get_b2w_access_token()
1456
-
1457
- code = case_id.service_point_ids[0].code
1458
- asset = case_id.sudo().kv_store().get("asset")
1459
- catalog_id = asset["catalogid"]
1460
- logs.append({"message": "Asset loaded", "data": asset})
1461
- order = create_order_disconnect(asset["_id"], token)
1462
- order_id = order["_id"]
1463
- config_id = order["conf_id"]
1464
- logs.append({"message": "Order created", "data": order})
1465
- bind_catalog(config_id, catalog_id, token)
1466
- checkout(config_id, token)
1467
-
1468
- kv_store = case_id.sudo().kv_store()
1469
- kv_store.set("order_id", order_id)
1470
- kv_store.set("asset_id", asset["_id"])
1471
- kv_store.set("config_id", order["conf_id"])
1472
- kv_store.set("contract_id", asset["contract_id"])
1473
-
1474
- result = "OK"
1475
-
1476
- except Exception as e:
1477
- logs.append({"message": str(e), "traceback": format_exc()})
1478
- case_id.write(
1479
- {"error_message": "Errore durante l'esecuzione della fase: {}".format(str(e))}
1480
- )
1481
-
1482
-
1483
- if logs:
1484
- log(json_dumps(logs))</field>
1485
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1486
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1487
- <field name="is_a_postalizer_phase">False</field>
1488
- <field name="is_compute_refund">False</field>
1489
- <field name="is_dl">False</field>
1490
- <field name="is_needs_child_case">False</field>
1491
- <field name="is_pick_refund_template">False</field>
1492
- <field name="is_process_managed">False</field>
1493
- <field name="is_quote_accepted">False</field>
1494
- <field name="is_quote_sent">False</field>
1495
- <field name="is_timeout">False</field>
1496
- <field name="is_voidable">False</field>
1497
- <field name="name">A1577 - Chiusura Ordine CRM</field>
1498
- <field name="set_result_automatically">from_code</field>
1499
- </record>
1500
- <record id="symple_triplet_phase_result_C1936_-_Data_raggiunta_E-CC01-0031" model="symple.triplet.phase.result">
1501
- <field name="active">True</field>
1502
- <field name="has_message">False</field>
1503
- <field name="is_annulment">False</field>
1504
- <field name="is_dl_solicitation_result">False</field>
1505
- <field name="is_hidden">False</field>
1506
- <field name="is_quote_expired">False</field>
1507
- <field name="name">C1936 - Data raggiunta</field>
1508
- <field name="next_phase_id" ref="symple_triplet_phase_A1577_-_Chiusura_Ordine_CRM"/>
1509
- <field name="state_code">E-CC01-0031</field>
1510
- <field name="wizard_result">SUCCESS</field>
1511
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza')])]"/>
1512
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1513
- </record>
1514
- <record id="symple_triplet_phase_A1321_-_Errore_CRM__RC1_" model="symple.triplet.phase">
1515
- <field name="active">True</field>
1516
- <field name="child_case">False</field>
1517
- <field name="code"># Available variables:
1518
- # - case_id: the case that just reached this phase
1519
- # - request: allows you to make HTTP requests (method, url, headers, data)
1520
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1521
- # - json_load: allows you to use JSON.load to convert a json into an object
1522
- # - env: Odoo Environment on which the action is triggered
1523
- # - time, datetime, dateutil, timezone: useful Python libraries
1524
- # - float_compare: Odoo function to compare floats based on specific precisions
1525
- # - ValidationError: Warning Exception to use with raise
1526
- # - Command: x2Many commands namespace
1527
- # - OrderedDict: ordered dictionaries
1528
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1529
- # (line = case id, func = phase name)
1530
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1531
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1532
- # To return a result, assign: result = {...}
1533
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1534
- # phase result will not be set.
1535
-
1536
-
1537
-
1538
- </field>
1539
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','AMS')])" />
1540
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1541
- <field name="is_a_postalizer_phase">False</field>
1542
- <field name="is_compute_refund">False</field>
1543
- <field name="is_dl">False</field>
1544
- <field name="is_needs_child_case">False</field>
1545
- <field name="is_pick_refund_template">False</field>
1546
- <field name="is_process_managed">False</field>
1547
- <field name="is_quote_accepted">False</field>
1548
- <field name="is_quote_sent">False</field>
1549
- <field name="is_timeout">False</field>
1550
- <field name="is_voidable">False</field>
1551
- <field name="name">A1321 - Errore CRM (RC1)</field>
1552
- </record>
1553
- <record id="symple_triplet_phase_result_C1899_-_Errore_CRM_durante_Chiusura_Ordine_E-CC01-0033" model="symple.triplet.phase.result">
1554
- <field name="active">True</field>
1555
- <field name="has_message">False</field>
1556
- <field name="is_annulment">False</field>
1557
- <field name="is_dl_solicitation_result">False</field>
1558
- <field name="is_hidden">False</field>
1559
- <field name="is_quote_expired">False</field>
1560
- <field name="name">C1899 - Errore CRM durante Chiusura Ordine</field>
1561
- <field name="next_phase_id" ref="symple_triplet_phase_A1321_-_Errore_CRM__RC1_"/>
1562
- <field name="state_code">E-CC01-0033</field>
1563
- <field name="wizard_result">SUCCESS</field>
1564
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1577_-_Chiusura_Ordine_CRM')])]"/>
1565
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1566
- </record>
1567
- <record id="symple_triplet_phase_A2398_-_Invio_ordine_CRM" model="symple.triplet.phase">
1568
- <field name="active">True</field>
1569
- <field name="child_case">False</field>
1570
- <field name="code"># Available variables:
1571
- # - case_id: the case that just reached this phase
1572
- # - request: allows you to make HTTP requests (method, url, headers, data)
1573
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1574
- # - json_load: allows you to use JSON.load to convert a json into an object
1575
- # - env: Odoo Environment on which the action is triggered
1576
- # - time, datetime, dateutil, timezone: useful Python libraries
1577
- # - float_compare: Odoo function to compare floats based on specific precisions
1578
- # - ValidationError: Warning Exception to use with raise
1579
- # - Command: x2Many commands namespace
1580
- # - OrderedDict: ordered dictionaries
1581
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1582
- # (line = case id, func = phase name)
1583
- # To return a result, assign: result = {...}
1584
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1585
- # phase result will not be set.
1586
-
1587
- logs = []
1588
-
1589
-
1590
- def log_and_parse_response(response, log_message):
1591
- try:
1592
- json_data = response.json()
1593
- logs.append({"message": log_message, "data": json_data})
1594
- return json_data
1595
- except Exception:
1596
- logs.append({"message": log_message, "response_text": response.text})
1597
- return response.text
1598
-
1599
-
1600
- def get_contract(contract_id, token):
1601
- response = request(
1602
- "GET",
1603
- "http://b2w-cpq-order-management-service/v1/contract/{}".format(contract_id),
1604
- headers={"X-Auth-Request-Access-Token": "" + token},
1605
- )
1606
-
1607
- json = log_and_parse_response(response, "get_contract")
1608
-
1609
- if response.status_code != 200:
1610
- raise ValidationError("Failed to download contract from B2W API")
1611
-
1612
- return json
1613
-
1614
-
1615
- def write_disconnect_date(asset_id, token):
1616
- dt = "{}T00:00:00.000+00:00".format(case_id.disconnect_date.isoformat())
1617
- body = {"disconnectdate": dt}
1618
-
1619
- response = request(
1620
- "PATCH",
1621
- "http://b2w-cpq-order-management-service/v1/asset/{}".format(asset_id),
1622
- headers={"X-Auth-Request-Access-Token": "" + token},
1623
- data=json_dumps(body),
1624
- )
1625
-
1626
- log_and_parse_response(response, "patch asset")
1627
-
1628
- if response.status_code != 200:
1629
- raise ValidationError("Failed to patch asset")
1630
-
1631
-
1632
- def order2asset(order_id, token):
1633
- url = "http://b2w-cpq-order-management-service/v1/order/asset/{}".format(order_id)
1634
- headers = {
1635
- "X-Auth-Request-Access-Token": "" + token,
1636
- "Content-Type": "application/json",
1637
- "generatesession": "true",
1638
- }
1639
-
1640
- response = request("POST", url, headers=headers, data=json_dumps([]))
1641
- json = log_and_parse_response(
1642
- response,
1643
- "Order2Asset response",
1644
- )
1645
-
1646
- if response.status_code != 200:
1647
- raise ValidationError("Failed to launch order2asset")
1648
-
1649
- return json
1650
-
1651
-
1652
- try:
1653
- IrConfigParam = env["ir.config_parameter"].sudo()
1654
- token = IrConfigParam.get_b2w_access_token()
1655
-
1656
- kv_store = case_id.sudo().kv_store()
1657
-
1658
- order_id = kv_store.get("order_id")
1659
- contract_id = kv_store.get("contract_id")
1660
- asset_id = kv_store.get("asset_id")
1661
-
1662
- if not order_id or not contract_id:
1663
- raise ValidationError("Order ID or Contract ID not found on case")
1664
-
1665
- order2asset(order_id, token)
1666
- logs.append({"message": "order2asset done"})
1667
-
1668
- date_fmt = (case_id.disconnect_date or datetime.datetime.now()).strftime(
1669
- "%Y-%m-%dT%H:%M:%S.%f"
1670
- ) + "Z"
1671
-
1672
- statemodel_result = IrConfigParam.update_b2w_statemodel(
1673
- "cessato",
1674
- sm_reason=case_id.ticket_type_id.name,
1675
- expected_date=date_fmt,
1676
- asset_id=asset_id,
1677
- token=token,
1678
- )
1679
- logs.append({"message": "Statemodel updates on asset", "data": statemodel_result})
1680
-
1681
- write_disconnect_date(asset_id, token)
1682
-
1683
- case_id.service_point_ids[0].sudo().write(
1684
- {
1685
- "state": "inactive",
1686
- "supply_end_date": datetime.datetime.today().strftime("%Y-%m-%d"),
1687
- }
1688
- )
1689
-
1690
- contract = get_contract(contract_id, token)
1691
-
1692
- if contract.get("status") == "disconnected":
1693
- statemodel_result = IrConfigParam.update_b2w_statemodel(
1694
- "cessato",
1695
- sm_reason=case_id.ticket_type_id.name,
1696
- expected_date=date_fmt,
1697
- contract_id=contract_id,
1698
- token=token,
1699
- )
1700
- logs.append(
1701
- {"message": "Statemodel updates on contract", "data": statemodel_result}
1702
- )
1703
- kv_store.set("is_contract_disconnected", True)
1704
- else:
1705
- kv_store.set("is_contract_disconnected", False)
1706
-
1707
- logs.append({"message": "service point updated"})
1708
-
1709
- result = "OK"
1710
-
1711
- except Exception as e:
1712
- logs.append({"message": str(e), "traceback": format_exc()})
1713
- case_id.write(
1714
- {"error_message": "Errore durante l'esecuzione della fase: {}".format(str(e))}
1715
- )
1716
-
1717
-
1718
- if logs:
1719
- log(json_dumps(logs))</field>
1720
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1721
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1722
- <field name="is_a_postalizer_phase">False</field>
1723
- <field name="is_compute_refund">False</field>
1724
- <field name="is_dl">False</field>
1725
- <field name="is_needs_child_case">False</field>
1726
- <field name="is_pick_refund_template">False</field>
1727
- <field name="is_process_managed">False</field>
1728
- <field name="is_quote_accepted">False</field>
1729
- <field name="is_quote_sent">False</field>
1730
- <field name="is_timeout">False</field>
1731
- <field name="is_voidable">False</field>
1732
- <field name="name">A2398 - Invio ordine CRM</field>
1733
- <field name="set_result_automatically">from_code</field>
1734
- </record>
1735
- <record id="symple_triplet_phase_result_C2242_-_Chiusura_Ordine_OK_E-CC01-0032" model="symple.triplet.phase.result">
1736
- <field name="active">True</field>
1737
- <field name="has_message">False</field>
1738
- <field name="is_annulment">False</field>
1739
- <field name="is_dl_solicitation_result">False</field>
1740
- <field name="is_hidden">False</field>
1741
- <field name="is_quote_expired">False</field>
1742
- <field name="name">C2242 - Chiusura Ordine OK</field>
1743
- <field name="next_phase_id" ref="symple_triplet_phase_A2398_-_Invio_ordine_CRM"/>
1744
- <field name="state_code">E-CC01-0032</field>
1745
- <field name="wizard_result">SUCCESS</field>
1746
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1577_-_Chiusura_Ordine_CRM')])]"/>
1747
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1748
- </record>
1749
- <record id="symple_triplet_phase_result_C1616_-_Risoluzione_Errore_E-CC01-0034" model="symple.triplet.phase.result">
1750
- <field name="active">True</field>
1751
- <field name="has_message">False</field>
1752
- <field name="is_annulment">False</field>
1753
- <field name="is_dl_solicitation_result">False</field>
1754
- <field name="is_hidden">False</field>
1755
- <field name="is_quote_expired">False</field>
1756
- <field name="name">C1616 - Risoluzione Errore</field>
1757
- <field name="next_phase_id" ref="symple_triplet_phase_A2398_-_Invio_ordine_CRM"/>
1758
- <field name="state_code">E-CC01-0034</field>
1759
- <field name="wizard_result">SUCCESS</field>
1760
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1321_-_Errore_CRM__RC1_')])]"/>
1761
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1762
- </record>
1763
- <record id="symple_triplet_phase_A0802_-_Integrazione_M2C" model="symple.triplet.phase">
1764
- <field name="active">True</field>
1765
- <field name="child_case">False</field>
1766
- <field name="code"># Available variables:
1767
- # - case_id: the case that just reached this phase
1768
- # - request: allows you to make HTTP requests (method, url, headers, data)
1769
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1770
- # - json_load: allows you to use JSON.load to convert a json into an object
1771
- # - env: Odoo Environment on which the action is triggered
1772
- # - time, datetime, dateutil, timezone: useful Python libraries
1773
- # - float_compare: Odoo function to compare floats based on specific precisions
1774
- # - ValidationError: Warning Exception to use with raise
1775
- # - Command: x2Many commands namespace
1776
- # - OrderedDict: ordered dictionaries
1777
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1778
- # (line = case id, func = phase name)
1779
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1780
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1781
- # To return a result, assign: result = {...}
1782
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1783
- # phase result will not be set.
1784
-
1785
-
1786
- logs = []
1787
-
1788
- ServicePoint = env["service.point"]
1789
-
1790
- try:
1791
- is_contract_done, contract_id = case_id.sudo().kv_store().get_many(
1792
- "is_contract_disconnected", "contract_id"
1793
- )
1794
- date_fmt = case_id.disconnect_date.strftime("%d%m%Y")
1795
-
1796
- logs.append({"date": date_fmt})
1797
-
1798
- next_phase_result = (
1799
- case_id.triplet_active_phase_id.allowed_phase_result_ids.filtered(
1800
- lambda x: x.wizard_result == "SUCCESS"
1801
- )[0]
1802
- )
1803
- ending_phase_result = (
1804
- next_phase_result.next_phase_id.allowed_phase_result_ids.filtered(
1805
- lambda x: x.wizard_result == "SUCCESS"
1806
- )[0].state_code
1807
- )
1808
-
1809
- sp = case_id.service_point_ids[0]
1810
- bp = sp.billing_profile_id
1811
- podPdr = sp.pod_id if sp.pod_id else sp.pdr_id
1812
-
1813
- json_dict = {
1814
- "caseId": str(case_id.id),
1815
- "flow": "m2c_passthrough",
1816
- "azione": {
1817
- "protocollo": str(case_id.id),
1818
- "case": case_id.ticket_type_id.name,
1819
- "cliente": {
1820
- "cCodiceBP": case_id.customer_id.golden_key,
1821
- "cCodiceCrm": case_id.customer_code,
1822
- "contrattiMandato": [
1823
- {
1824
- "cCodiceContrattoMandato": bp.name,
1825
- "contratti": {
1826
- "cCodiceContratto": contract_id,
1827
- "forniture": [
1828
- {
1829
- "cPodPdr": podPdr.code,
1830
- "cCodicePR": sp.code,
1831
- "cCausaleCessazione": case_id.ticket_type_id.name,
1832
- "cStatoFornitura": "CESSATO",
1833
- "dFineContrattoFornitura": date_fmt,
1834
- }
1835
- ],
1836
- },
1837
- }
1838
- ],
1839
- },
1840
- },
1841
- "m2c_callback_esito": ending_phase_result,
1842
- }
1843
-
1844
- if is_contract_done:
1845
- json_dict["azione"]["cliente"]["contrattiMandato"][0]["contratti"][
1846
- "dFineContratto"
1847
- ] = date_fmt
1848
-
1849
- has_active_points = ServicePoint.search(
1850
- [("client_id", "=", case_id.customer_id.id), ("state", "!=", "inactive")]
1851
- ).exists()
1852
-
1853
- if not has_active_points:
1854
- json_dict["azione"]["cliente"]["xStatoBp"] = "CESSATO"
1855
-
1856
- tenant_id = env["ir.config_parameter"].sudo().get_param("m2c_header_tenant_id")
1857
- org_token = env["ir.config_parameter"].sudo().get_param("m2c_header_org_token")
1858
- token = env["symple.pb.launcher"].get_access_token()
1859
- headers = {
1860
- "tenantId": tenant_id,
1861
- "orgToken": org_token,
1862
- "Content-Type": "application/json",
1863
- "X-Auth-Request-Access-Token": token,
1864
- }
1865
-
1866
- logs.append({"message": "m2c", "data": json_dict})
1867
-
1868
- m2c_url = "http://b2w-symphony-rest-service/api/symphony/process-instances/M2C_passthrough"
1869
- response = request("POST", m2c_url, headers=headers, data=json_dumps(json_dict))
1870
- result = "OK"
1871
-
1872
-
1873
- except Exception as e:
1874
- logs.append({"message": str(e), "traceback": format_exc()})
1875
- prev = case_id.info_message + "\n" if case_id.info_message else ""
1876
- case_id.write({"info_message": prev + str(e)})
1877
-
1878
- if logs:
1879
- log(json_dumps(logs))</field>
1880
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1881
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1882
- <field name="is_a_postalizer_phase">False</field>
1883
- <field name="is_compute_refund">False</field>
1884
- <field name="is_dl">False</field>
1885
- <field name="is_needs_child_case">False</field>
1886
- <field name="is_pick_refund_template">False</field>
1887
- <field name="is_process_managed">False</field>
1888
- <field name="is_quote_accepted">False</field>
1889
- <field name="is_quote_sent">False</field>
1890
- <field name="is_timeout">False</field>
1891
- <field name="is_voidable">False</field>
1892
- <field name="name">A0802 - Integrazione M2C</field>
1893
- <field name="set_result_automatically">from_code</field>
1894
- </record>
1895
- <record id="symple_triplet_phase_result_C1900_-_Integrazione_M2C_E-CC01-0035" model="symple.triplet.phase.result">
1896
- <field name="active">True</field>
1897
- <field name="has_message">False</field>
1898
- <field name="is_annulment">False</field>
1899
- <field name="is_dl_solicitation_result">False</field>
1900
- <field name="is_hidden">False</field>
1901
- <field name="is_quote_expired">False</field>
1902
- <field name="name">C1900 - Integrazione M2C</field>
1903
- <field name="next_phase_id" ref="symple_triplet_phase_A0802_-_Integrazione_M2C"/>
1904
- <field name="state_code">E-CC01-0035</field>
1905
- <field name="wizard_result">SUCCESS</field>
1906
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2398_-_Invio_ordine_CRM')])]"/>
1907
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1908
- </record>
1909
- <record id="symple_triplet_phase_A0803_-_In_attesa_esito_M2C" model="symple.triplet.phase">
1910
- <field name="active">True</field>
1911
- <field name="child_case">False</field>
1912
- <field name="code"># Available variables:
1913
- # - case_id: the case that just reached this phase
1914
- # - request: allows you to make HTTP requests (method, url, headers, data)
1915
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1916
- # - json_load: allows you to use JSON.load to convert a json into an object
1917
- # - env: Odoo Environment on which the action is triggered
1918
- # - time, datetime, dateutil, timezone: useful Python libraries
1919
- # - float_compare: Odoo function to compare floats based on specific precisions
1920
- # - ValidationError: Warning Exception to use with raise
1921
- # - Command: x2Many commands namespace
1922
- # - OrderedDict: ordered dictionaries
1923
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1924
- # (line = case id, func = phase name)
1925
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1926
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1927
- # To return a result, assign: result = {...}
1928
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1929
- # phase result will not be set.
1930
-
1931
-
1932
-
1933
- </field>
1934
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1935
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1936
- <field name="is_a_postalizer_phase">False</field>
1937
- <field name="is_compute_refund">False</field>
1938
- <field name="is_dl">False</field>
1939
- <field name="is_needs_child_case">False</field>
1940
- <field name="is_pick_refund_template">False</field>
1941
- <field name="is_process_managed">False</field>
1942
- <field name="is_quote_accepted">False</field>
1943
- <field name="is_quote_sent">False</field>
1944
- <field name="is_timeout">False</field>
1945
- <field name="is_voidable">False</field>
1946
- <field name="name">A0803 - In attesa esito M2C</field>
1947
- </record>
1948
- <record id="symple_triplet_phase_result_C1904_-_In_attesa_esito_M2C_E-CC01-0036" model="symple.triplet.phase.result">
1949
- <field name="active">True</field>
1950
- <field name="has_message">False</field>
1951
- <field name="is_annulment">False</field>
1952
- <field name="is_dl_solicitation_result">False</field>
1953
- <field name="is_hidden">False</field>
1954
- <field name="is_quote_expired">False</field>
1955
- <field name="name">C1904 - In attesa esito M2C</field>
1956
- <field name="next_phase_id" ref="symple_triplet_phase_A0803_-_In_attesa_esito_M2C"/>
1957
- <field name="state_code">E-CC01-0036</field>
1958
- <field name="wizard_result">SUCCESS</field>
1959
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0802_-_Integrazione_M2C')])]"/>
1960
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
1961
- </record>
1962
- <record id="symple_triplet_phase_A1836_-_Apertura_case_figlio" model="symple.triplet.phase">
1963
- <field name="active">True</field>
1964
- <field name="child_case">False</field>
1965
- <field name="code"># Available variables:
1966
- # - case_id: the case that just reached this phase
1967
- # - request: allows you to make HTTP requests (method, url, headers, data)
1968
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
1969
- # - json_load: allows you to use JSON.load to convert a json into an object
1970
- # - env: Odoo Environment on which the action is triggered
1971
- # - time, datetime, dateutil, timezone: useful Python libraries
1972
- # - float_compare: Odoo function to compare floats based on specific precisions
1973
- # - ValidationError: Warning Exception to use with raise
1974
- # - Command: x2Many commands namespace
1975
- # - OrderedDict: ordered dictionaries
1976
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
1977
- # (line = case id, func = phase name)
1978
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
1979
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
1980
- # To return a result, assign: result = {...}
1981
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
1982
- # phase result will not be set.
1983
-
1984
-
1985
-
1986
- </field>
1987
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
1988
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
1989
- <field name="is_a_postalizer_phase">False</field>
1990
- <field name="is_compute_refund">False</field>
1991
- <field name="is_dl">False</field>
1992
- <field name="is_needs_child_case">False</field>
1993
- <field name="is_pick_refund_template">False</field>
1994
- <field name="is_process_managed">False</field>
1995
- <field name="is_quote_accepted">False</field>
1996
- <field name="is_quote_sent">False</field>
1997
- <field name="is_timeout">False</field>
1998
- <field name="is_voidable">False</field>
1999
- <field name="name">A1836 - Apertura case figlio</field>
2000
- <field name="set_result_automatically">from_code</field>
2001
- </record>
2002
- <record id="symple_triplet_phase_result_C2552_-_Elaborazione_bloccata_nel_M2C_E-CC01-0039" model="symple.triplet.phase.result">
2003
- <field name="active">True</field>
2004
- <field name="has_message">False</field>
2005
- <field name="is_annulment">False</field>
2006
- <field name="is_dl_solicitation_result">False</field>
2007
- <field name="is_hidden">False</field>
2008
- <field name="is_quote_expired">False</field>
2009
- <field name="name">C2552 - Elaborazione bloccata nel M2C</field>
2010
- <field name="next_phase_id" ref="symple_triplet_phase_A1836_-_Apertura_case_figlio"/>
2011
- <field name="state_code">E-CC01-0039</field>
2012
- <field name="wizard_result">SUCCESS</field>
2013
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0803_-_In_attesa_esito_M2C')])]"/>
2014
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2015
- </record>
2016
- <record id="symple_triplet_phase_A1595_-_Invio_Annullamento_alla_Market_Communication" model="symple.triplet.phase">
2017
- <field name="active">True</field>
2018
- <field name="child_case">False</field>
2019
- <field name="code"># Available variables:
2020
- # - case_id: the case that just reached this phase
2021
- # - request: allows you to make HTTP requests (method, url, headers, data)
2022
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2023
- # - json_load: allows you to use JSON.load to convert a json into an object
2024
- # - env: Odoo Environment on which the action is triggered
2025
- # - time, datetime, dateutil, timezone: useful Python libraries
2026
- # - float_compare: Odoo function to compare floats based on specific precisions
2027
- # - ValidationError: Warning Exception to use with raise
2028
- # - Command: x2Many commands namespace
2029
- # - OrderedDict: ordered dictionaries
2030
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2031
- # (line = case id, func = phase name)
2032
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2033
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2034
- # To return a result, assign: result = {...}
2035
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2036
- # phase result will not be set.
2037
-
2038
- logs = []
2039
- bypass = False
2040
-
2041
-
2042
- def get_apr_reason():
2043
- kv_store = case_id.sudo().kv_store()
2044
- reason_code = kv_store.get("annulment_wizard_motivation")
2045
- map_motivazione = {
2046
- "RC01": "Annullamento RC per esecuzione di altra prestazione",
2047
- "RC02": "Annullamento RC per disattivazione della fornitura",
2048
- "RC04": "Revoca risoluzione per pratica errata",
2049
- "RG01": "Revoca RCG per esecuzione di altra prestazione",
2050
- "RG03": "Revoca risoluzione per errata trasmissione",
2051
- }
2052
-
2053
- return reason_code, map_motivazione.get(reason_code, "")
2054
-
2055
-
2056
- try:
2057
- sp = case_id.service_point_ids[0]
2058
- podPdr = sp.pod_id if sp.pod_id else sp.pdr_id
2059
- cod_causale, motivazione = get_apr_reason()
2060
-
2061
- tenant_id = env["ir.config_parameter"].sudo().get_param("m2c_header_tenant_id")
2062
- org_token = env["ir.config_parameter"].sudo().get_param("m2c_header_org_token")
2063
- headers = {"tenantId": tenant_id, "orgToken": org_token}
2064
- ok_payload = {
2065
- "refName": "Annulment",
2066
- "refId": case_id.symphonie_process,
2067
- "messageProcessVars": {
2068
- "ifs_code": "APR",
2069
- "bypass": bypass,
2070
- "aprInfo": {
2071
- "COD_CAUSALE": cod_causale,
2072
- "MOTIVAZIONE": motivazione,
2073
- "COD_POD_PDR": podPdr.code,
2074
- },
2075
- },
2076
- }
2077
-
2078
- url = env["ir.config_parameter"].sudo().get_param("b2w_wake_up_process_url")
2079
- payload = json_dumps(ok_payload)
2080
- response = request("POST", url, data=payload, headers=headers)
2081
-
2082
- if response.status_code != 200:
2083
- raise ValidationError("Failed to launch APR")
2084
-
2085
- result = "OK"
2086
-
2087
- except Exception as e:
2088
- prev = case_id.info_message + "\n" if case_id.info_message else ""
2089
- case_id.write({"info_message": prev + str(e)})
2090
-
2091
- log(json_dumps(logs))</field>
2092
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2093
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2094
- <field name="is_a_postalizer_phase">False</field>
2095
- <field name="is_compute_refund">False</field>
2096
- <field name="is_dl">False</field>
2097
- <field name="is_needs_child_case">False</field>
2098
- <field name="is_pick_refund_template">False</field>
2099
- <field name="is_process_managed">False</field>
2100
- <field name="is_quote_accepted">False</field>
2101
- <field name="is_quote_sent">False</field>
2102
- <field name="is_timeout">False</field>
2103
- <field name="is_voidable">False</field>
2104
- <field name="name">A1595 - Invio Annullamento alla Market Communication</field>
2105
- <field name="set_result_automatically">from_code</field>
2106
- </record>
2107
- <record id="symple_triplet_phase_result_C2549_-_annullamento_attivo_E-CC01-0029" model="symple.triplet.phase.result">
2108
- <field name="active">True</field>
2109
- <field name="has_message">False</field>
2110
- <field name="is_annulment">False</field>
2111
- <field name="is_dl_solicitation_result">False</field>
2112
- <field name="is_hidden">False</field>
2113
- <field name="is_quote_expired">False</field>
2114
- <field name="name">C2549 - annullamento attivo</field>
2115
- <field name="next_phase_id" ref="symple_triplet_phase_A1595_-_Invio_Annullamento_alla_Market_Communication"/>
2116
- <field name="state_code">E-CC01-0029</field>
2117
- <field name="wizard_result">CANCEL</field>
2118
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza')])]"/>
2119
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Cancel')])" />
2120
- </record>
2121
- <record id="symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento" model="symple.triplet.phase">
2122
- <field name="active">True</field>
2123
- <field name="child_case">False</field>
2124
- <field name="code"># Available variables:
2125
- # - case_id: the case that just reached this phase
2126
- # - request: allows you to make HTTP requests (method, url, headers, data)
2127
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2128
- # - json_load: allows you to use JSON.load to convert a json into an object
2129
- # - env: Odoo Environment on which the action is triggered
2130
- # - time, datetime, dateutil, timezone: useful Python libraries
2131
- # - float_compare: Odoo function to compare floats based on specific precisions
2132
- # - ValidationError: Warning Exception to use with raise
2133
- # - Command: x2Many commands namespace
2134
- # - OrderedDict: ordered dictionaries
2135
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2136
- # (line = case id, func = phase name)
2137
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2138
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2139
- # To return a result, assign: result = {...}
2140
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2141
- # phase result will not be set.
2142
-
2143
-
2144
-
2145
- </field>
2146
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2147
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2148
- <field name="is_a_postalizer_phase">False</field>
2149
- <field name="is_compute_refund">False</field>
2150
- <field name="is_dl">False</field>
2151
- <field name="is_needs_child_case">False</field>
2152
- <field name="is_pick_refund_template">False</field>
2153
- <field name="is_process_managed">False</field>
2154
- <field name="is_quote_accepted">False</field>
2155
- <field name="is_quote_sent">False</field>
2156
- <field name="is_timeout">False</field>
2157
- <field name="is_voidable">False</field>
2158
- <field name="name">A1767 - In attesa check IFS Annullamento</field>
2159
- </record>
2160
- <record id="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0041" model="symple.triplet.phase.result">
2161
- <field name="active">True</field>
2162
- <field name="has_message">False</field>
2163
- <field name="is_annulment">False</field>
2164
- <field name="is_dl_solicitation_result">False</field>
2165
- <field name="is_hidden">False</field>
2166
- <field name="is_quote_expired">False</field>
2167
- <field name="name">C1019 - Inviata</field>
2168
- <field name="next_phase_id" ref="symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento"/>
2169
- <field name="state_code">E-CC01-0041</field>
2170
- <field name="wizard_result">SUCCESS</field>
2171
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1595_-_Invio_Annullamento_alla_Market_Communication')])]"/>
2172
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2173
- </record>
2174
- <record id="symple_triplet_phase_result_C1448_-_OK_controlli_RCU_E-CC01-0046" model="symple.triplet.phase.result">
2175
- <field name="active">True</field>
2176
- <field name="has_message">False</field>
2177
- <field name="is_annulment">False</field>
2178
- <field name="is_dl_solicitation_result">False</field>
2179
- <field name="is_hidden">False</field>
2180
- <field name="is_quote_expired">False</field>
2181
- <field name="name">C1448 - OK controlli RCU</field>
2182
- <field name="next_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
2183
- <field name="state_code">E-CC01-0046</field>
2184
- <field name="wizard_result">SUCCESS</field>
2185
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento')])]"/>
2186
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2187
- </record>
2188
- <record id="symple_triplet_phase_A2562_-_verifica_avvio_gestione_manuale_annullamento" model="symple.triplet.phase">
2189
- <field name="active">True</field>
2190
- <field name="child_case">False</field>
2191
- <field name="code"># Available variables:
2192
- # - case_id: the case that just reached this phase
2193
- # - request: allows you to make HTTP requests (method, url, headers, data)
2194
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2195
- # - json_load: allows you to use JSON.load to convert a json into an object
2196
- # - env: Odoo Environment on which the action is triggered
2197
- # - time, datetime, dateutil, timezone: useful Python libraries
2198
- # - float_compare: Odoo function to compare floats based on specific precisions
2199
- # - ValidationError: Warning Exception to use with raise
2200
- # - Command: x2Many commands namespace
2201
- # - OrderedDict: ordered dictionaries
2202
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2203
- # (line = case id, func = phase name)
2204
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2205
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2206
- # To return a result, assign: result = {...}
2207
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2208
- # phase result will not be set.
2209
-
2210
-
2211
-
2212
- </field>
2213
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','BOT')])" />
2214
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2215
- <field name="is_a_postalizer_phase">False</field>
2216
- <field name="is_compute_refund">False</field>
2217
- <field name="is_dl">False</field>
2218
- <field name="is_needs_child_case">False</field>
2219
- <field name="is_pick_refund_template">False</field>
2220
- <field name="is_process_managed">False</field>
2221
- <field name="is_quote_accepted">False</field>
2222
- <field name="is_quote_sent">False</field>
2223
- <field name="is_timeout">False</field>
2224
- <field name="is_voidable">False</field>
2225
- <field name="name">A2562 - verifica avvio gestione manuale annullamento</field>
2226
- </record>
2227
- <record id="symple_triplet_phase_result_C2509_-_Da_gestire_nuovo_invio_automatico_E-CC01-0049" model="symple.triplet.phase.result">
2228
- <field name="active">True</field>
2229
- <field name="has_message">False</field>
2230
- <field name="is_annulment">False</field>
2231
- <field name="is_dl_solicitation_result">False</field>
2232
- <field name="is_hidden">False</field>
2233
- <field name="is_quote_expired">False</field>
2234
- <field name="name">C2509 - Da gestire nuovo invio automatico</field>
2235
- <field name="next_phase_id" ref="symple_triplet_phase_A1595_-_Invio_Annullamento_alla_Market_Communication"/>
2236
- <field name="state_code">E-CC01-0049</field>
2237
- <field name="wizard_result">SUCCESS</field>
2238
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2562_-_verifica_avvio_gestione_manuale_annullamento')])]"/>
2239
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2240
- </record>
2241
- <record id="symple_triplet_phase_result_C1448_-_OK_controlli_RCU_E-CC01-0051" model="symple.triplet.phase.result">
2242
- <field name="active">True</field>
2243
- <field name="has_message">False</field>
2244
- <field name="is_annulment">False</field>
2245
- <field name="is_dl_solicitation_result">False</field>
2246
- <field name="is_hidden">False</field>
2247
- <field name="is_quote_expired">False</field>
2248
- <field name="name">C1448 - OK controlli RCU</field>
2249
- <field name="next_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
2250
- <field name="state_code">E-CC01-0051</field>
2251
- <field name="wizard_result">SUCCESS</field>
2252
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2562_-_verifica_avvio_gestione_manuale_annullamento')])]"/>
2253
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2254
- </record>
2255
- <record id="symple_triplet_phase_A2142_-_Invio_alla_marketcom_annullamento_forzato" model="symple.triplet.phase">
2256
- <field name="active">True</field>
2257
- <field name="child_case">False</field>
2258
- <field name="code"># Available variables:
2259
- # - case_id: the case that just reached this phase
2260
- # - request: allows you to make HTTP requests (method, url, headers, data)
2261
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2262
- # - json_load: allows you to use JSON.load to convert a json into an object
2263
- # - env: Odoo Environment on which the action is triggered
2264
- # - time, datetime, dateutil, timezone: useful Python libraries
2265
- # - float_compare: Odoo function to compare floats based on specific precisions
2266
- # - ValidationError: Warning Exception to use with raise
2267
- # - Command: x2Many commands namespace
2268
- # - OrderedDict: ordered dictionaries
2269
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2270
- # (line = case id, func = phase name)
2271
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2272
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2273
- # To return a result, assign: result = {...}
2274
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2275
- # phase result will not be set.
2276
-
2277
- logs = []
2278
- bypass = True
2279
-
2280
-
2281
- def get_apr_reason():
2282
- kv_store = case_id.sudo().kv_store()
2283
- reason_code = kv_store.get("annulment_wizard_motivation")
2284
- map_motivazione = {
2285
- "RC01": "Annullamento RC per esecuzione di altra prestazione",
2286
- "RC02": "Annullamento RC per disattivazione della fornitura",
2287
- "RC04": "Revoca risoluzione per pratica errata",
2288
- "RG01": "Revoca RCG per esecuzione di altra prestazione",
2289
- "RG03": "Revoca risoluzione per errata trasmissione",
2290
- }
2291
-
2292
- return reason_code, map_motivazione.get(reason_code, "")
2293
-
2294
-
2295
- try:
2296
- sp = case_id.service_point_ids[0]
2297
- podPdr = sp.pod_id if sp.pod_id else sp.pdr_id
2298
- cod_causale, motivazione = get_apr_reason()
2299
-
2300
- tenant_id = env["ir.config_parameter"].sudo().get_param("m2c_header_tenant_id")
2301
- org_token = env["ir.config_parameter"].sudo().get_param("m2c_header_org_token")
2302
- headers = {"tenantId": tenant_id, "orgToken": org_token}
2303
- ok_payload = {
2304
- "refName": "Annulment",
2305
- "refId": case_id.symphonie_process,
2306
- "messageProcessVars": {
2307
- "ifs_code": "APR",
2308
- "bypass": bypass,
2309
- "aprInfo": {
2310
- "COD_CAUSALE": cod_causale,
2311
- "MOTIVAZIONE": motivazione,
2312
- "COD_POD_PDR": podPdr.code,
2313
- },
2314
- },
2315
- }
2316
-
2317
- url = env["ir.config_parameter"].sudo().get_param("b2w_wake_up_process_url")
2318
- payload = json_dumps(ok_payload)
2319
- response = request("POST", url, data=payload, headers=headers)
2320
-
2321
- if response.status_code != 200:
2322
- raise ValidationError("Failed to launch VT.0040")
2323
-
2324
- result = "OK"
2325
-
2326
- except Exception as e:
2327
- prev = case_id.info_message + "\n" if case_id.info_message else ""
2328
- case_id.write({"info_message": prev + str(e)})
2329
-
2330
- log(json_dumps(logs))</field>
2331
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2332
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2333
- <field name="is_a_postalizer_phase">False</field>
2334
- <field name="is_compute_refund">False</field>
2335
- <field name="is_dl">False</field>
2336
- <field name="is_needs_child_case">False</field>
2337
- <field name="is_pick_refund_template">False</field>
2338
- <field name="is_process_managed">False</field>
2339
- <field name="is_quote_accepted">False</field>
2340
- <field name="is_quote_sent">False</field>
2341
- <field name="is_timeout">False</field>
2342
- <field name="is_voidable">False</field>
2343
- <field name="name">A2142 - Invio alla marketcom annullamento forzato</field>
2344
- <field name="set_result_automatically">from_code</field>
2345
- </record>
2346
- <record id="symple_triplet_phase_result_C2508_-_gestione_fuori_linea_E-CC01-0048" model="symple.triplet.phase.result">
2347
- <field name="active">True</field>
2348
- <field name="has_message">False</field>
2349
- <field name="is_annulment">False</field>
2350
- <field name="is_dl_solicitation_result">False</field>
2351
- <field name="is_hidden">False</field>
2352
- <field name="is_quote_expired">False</field>
2353
- <field name="name">C2508 - gestione fuori linea</field>
2354
- <field name="next_phase_id" ref="symple_triplet_phase_A2142_-_Invio_alla_marketcom_annullamento_forzato"/>
2355
- <field name="state_code">E-CC01-0048</field>
2356
- <field name="wizard_result">SUCCESS</field>
2357
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2562_-_verifica_avvio_gestione_manuale_annullamento')])]"/>
2358
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2359
- </record>
2360
- <record id="symple_triplet_phase_A2143_-_In_attesa_check_IFS_Annullamento_forzato" model="symple.triplet.phase">
2361
- <field name="active">True</field>
2362
- <field name="child_case">False</field>
2363
- <field name="code"># Available variables:
2364
- # - case_id: the case that just reached this phase
2365
- # - request: allows you to make HTTP requests (method, url, headers, data)
2366
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2367
- # - json_load: allows you to use JSON.load to convert a json into an object
2368
- # - env: Odoo Environment on which the action is triggered
2369
- # - time, datetime, dateutil, timezone: useful Python libraries
2370
- # - float_compare: Odoo function to compare floats based on specific precisions
2371
- # - ValidationError: Warning Exception to use with raise
2372
- # - Command: x2Many commands namespace
2373
- # - OrderedDict: ordered dictionaries
2374
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2375
- # (line = case id, func = phase name)
2376
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2377
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2378
- # To return a result, assign: result = {...}
2379
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2380
- # phase result will not be set.
2381
-
2382
-
2383
-
2384
- </field>
2385
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2386
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2387
- <field name="is_a_postalizer_phase">False</field>
2388
- <field name="is_compute_refund">False</field>
2389
- <field name="is_dl">False</field>
2390
- <field name="is_needs_child_case">False</field>
2391
- <field name="is_pick_refund_template">False</field>
2392
- <field name="is_process_managed">False</field>
2393
- <field name="is_quote_accepted">False</field>
2394
- <field name="is_quote_sent">False</field>
2395
- <field name="is_timeout">False</field>
2396
- <field name="is_voidable">False</field>
2397
- <field name="name">A2143 - In attesa check IFS Annullamento forzato</field>
2398
- </record>
2399
- <record id="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0053" model="symple.triplet.phase.result">
2400
- <field name="active">True</field>
2401
- <field name="has_message">False</field>
2402
- <field name="is_annulment">False</field>
2403
- <field name="is_dl_solicitation_result">False</field>
2404
- <field name="is_hidden">False</field>
2405
- <field name="is_quote_expired">False</field>
2406
- <field name="name">C1019 - Inviata</field>
2407
- <field name="next_phase_id" ref="symple_triplet_phase_A2143_-_In_attesa_check_IFS_Annullamento_forzato"/>
2408
- <field name="state_code">E-CC01-0053</field>
2409
- <field name="wizard_result">SUCCESS</field>
2410
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2142_-_Invio_alla_marketcom_annullamento_forzato')])]"/>
2411
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2412
- </record>
2413
- <record id="symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento" model="symple.triplet.phase">
2414
- <field name="active">True</field>
2415
- <field name="child_case">False</field>
2416
- <field name="code"># Available variables:
2417
- # - case_id: the case that just reached this phase
2418
- # - request: allows you to make HTTP requests (method, url, headers, data)
2419
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2420
- # - json_load: allows you to use JSON.load to convert a json into an object
2421
- # - env: Odoo Environment on which the action is triggered
2422
- # - time, datetime, dateutil, timezone: useful Python libraries
2423
- # - float_compare: Odoo function to compare floats based on specific precisions
2424
- # - ValidationError: Warning Exception to use with raise
2425
- # - Command: x2Many commands namespace
2426
- # - OrderedDict: ordered dictionaries
2427
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2428
- # (line = case id, func = phase name)
2429
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2430
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2431
- # To return a result, assign: result = {...}
2432
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2433
- # phase result will not be set.
2434
-
2435
-
2436
-
2437
- </field>
2438
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2439
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2440
- <field name="is_a_postalizer_phase">False</field>
2441
- <field name="is_compute_refund">False</field>
2442
- <field name="is_dl">False</field>
2443
- <field name="is_needs_child_case">False</field>
2444
- <field name="is_pick_refund_template">False</field>
2445
- <field name="is_process_managed">False</field>
2446
- <field name="is_quote_accepted">False</field>
2447
- <field name="is_quote_sent">False</field>
2448
- <field name="is_timeout">False</field>
2449
- <field name="is_voidable">False</field>
2450
- <field name="name">A1732 - Gestione scarti da cruscotto annullamento</field>
2451
- </record>
2452
- <record id="symple_triplet_phase_result_C2476_-_KO_-_Ammissibilit__Annullamento_Hub_E-CC01-0043" model="symple.triplet.phase.result">
2453
- <field name="active">True</field>
2454
- <field name="has_message">False</field>
2455
- <field name="is_annulment">False</field>
2456
- <field name="is_dl_solicitation_result">False</field>
2457
- <field name="is_hidden">False</field>
2458
- <field name="is_quote_expired">False</field>
2459
- <field name="name">C2476 - KO - Ammissibilità Annullamento Hub</field>
2460
- <field name="next_phase_id" ref="symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento"/>
2461
- <field name="state_code">E-CC01-0043</field>
2462
- <field name="wizard_result">SUCCESS</field>
2463
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento')])]"/>
2464
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2465
- </record>
2466
- <record id="symple_triplet_phase_result_C2416_-_risottomessa_da_cruscotto_E-CC01-0056" model="symple.triplet.phase.result">
2467
- <field name="active">True</field>
2468
- <field name="has_message">False</field>
2469
- <field name="is_annulment">False</field>
2470
- <field name="is_dl_solicitation_result">False</field>
2471
- <field name="is_hidden">False</field>
2472
- <field name="is_quote_expired">False</field>
2473
- <field name="name">C2416 - risottomessa da cruscotto</field>
2474
- <field name="next_phase_id" ref="symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento"/>
2475
- <field name="state_code">E-CC01-0056</field>
2476
- <field name="wizard_result">RESUBMIT</field>
2477
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento')])]"/>
2478
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Resubmit')])" />
2479
- </record>
2480
- <record id="symple_triplet_phase_result_C1931_-_Errore_non_rilavorabile_E-CC01-0057" model="symple.triplet.phase.result">
2481
- <field name="active">True</field>
2482
- <field name="has_message">False</field>
2483
- <field name="is_annulment">False</field>
2484
- <field name="is_dl_solicitation_result">False</field>
2485
- <field name="is_hidden">False</field>
2486
- <field name="is_quote_expired">False</field>
2487
- <field name="name">C1931 - Errore non rilavorabile</field>
2488
- <field name="next_phase_id" ref="symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza"/>
2489
- <field name="state_code">E-CC01-0057</field>
2490
- <field name="wizard_result">SUCCESS</field>
2491
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento')])]"/>
2492
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2493
- </record>
2494
- <record id="symple_triplet_phase_result_C1448_-_OK_controlli_RCU_E-CC01-0059" model="symple.triplet.phase.result">
2495
- <field name="active">True</field>
2496
- <field name="has_message">False</field>
2497
- <field name="is_annulment">False</field>
2498
- <field name="is_dl_solicitation_result">False</field>
2499
- <field name="is_hidden">False</field>
2500
- <field name="is_quote_expired">False</field>
2501
- <field name="name">C1448 - OK controlli RCU</field>
2502
- <field name="next_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
2503
- <field name="state_code">E-CC01-0059</field>
2504
- <field name="wizard_result">SUCCESS</field>
2505
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento')])]"/>
2506
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2507
- </record>
2508
- <record id="symple_triplet_phase_A1832_-_gestione_scarti_da_cruscotto_annullamento_forzato" model="symple.triplet.phase">
2509
- <field name="active">True</field>
2510
- <field name="child_case">False</field>
2511
- <field name="code"># Available variables:
2512
- # - case_id: the case that just reached this phase
2513
- # - request: allows you to make HTTP requests (method, url, headers, data)
2514
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2515
- # - json_load: allows you to use JSON.load to convert a json into an object
2516
- # - env: Odoo Environment on which the action is triggered
2517
- # - time, datetime, dateutil, timezone: useful Python libraries
2518
- # - float_compare: Odoo function to compare floats based on specific precisions
2519
- # - ValidationError: Warning Exception to use with raise
2520
- # - Command: x2Many commands namespace
2521
- # - OrderedDict: ordered dictionaries
2522
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2523
- # (line = case id, func = phase name)
2524
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2525
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2526
- # To return a result, assign: result = {...}
2527
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2528
- # phase result will not be set.
2529
-
2530
-
2531
-
2532
- </field>
2533
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2534
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2535
- <field name="is_a_postalizer_phase">False</field>
2536
- <field name="is_compute_refund">False</field>
2537
- <field name="is_dl">False</field>
2538
- <field name="is_needs_child_case">False</field>
2539
- <field name="is_pick_refund_template">False</field>
2540
- <field name="is_process_managed">False</field>
2541
- <field name="is_quote_accepted">False</field>
2542
- <field name="is_quote_sent">False</field>
2543
- <field name="is_timeout">False</field>
2544
- <field name="is_voidable">False</field>
2545
- <field name="name">A1832 - gestione scarti da cruscotto annullamento forzato</field>
2546
- </record>
2547
- <record id="symple_triplet_phase_result_C2225_-_KO_-_Ammissibilit__Hub_E-CC01-0054" model="symple.triplet.phase.result">
2548
- <field name="active">True</field>
2549
- <field name="has_message">False</field>
2550
- <field name="is_annulment">False</field>
2551
- <field name="is_dl_solicitation_result">False</field>
2552
- <field name="is_hidden">False</field>
2553
- <field name="is_quote_expired">False</field>
2554
- <field name="name">C2225 - KO - Ammissibilità Hub</field>
2555
- <field name="next_phase_id" ref="symple_triplet_phase_A1832_-_gestione_scarti_da_cruscotto_annullamento_forzato"/>
2556
- <field name="state_code">E-CC01-0054</field>
2557
- <field name="wizard_result">SUCCESS</field>
2558
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2143_-_In_attesa_check_IFS_Annullamento_forzato')])]"/>
2559
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2560
- </record>
2561
- <record id="symple_triplet_phase_result_C2416_-_risottomessa_da_cruscotto_E-CC01-0061" model="symple.triplet.phase.result">
2562
- <field name="active">True</field>
2563
- <field name="has_message">False</field>
2564
- <field name="is_annulment">False</field>
2565
- <field name="is_dl_solicitation_result">False</field>
2566
- <field name="is_hidden">False</field>
2567
- <field name="is_quote_expired">False</field>
2568
- <field name="name">C2416 - risottomessa da cruscotto</field>
2569
- <field name="next_phase_id" ref="symple_triplet_phase_A2143_-_In_attesa_check_IFS_Annullamento_forzato"/>
2570
- <field name="state_code">E-CC01-0061</field>
2571
- <field name="wizard_result">RESUBMIT</field>
2572
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1832_-_gestione_scarti_da_cruscotto_annullamento_forzato')])]"/>
2573
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Resubmit')])" />
2574
- </record>
2575
- <record id="symple_triplet_phase_result_C1931_-_Errore_non_rilavorabile_E-CC01-0062" model="symple.triplet.phase.result">
2576
- <field name="active">True</field>
2577
- <field name="has_message">False</field>
2578
- <field name="is_annulment">False</field>
2579
- <field name="is_dl_solicitation_result">False</field>
2580
- <field name="is_hidden">False</field>
2581
- <field name="is_quote_expired">False</field>
2582
- <field name="name">C1931 - Errore non rilavorabile</field>
2583
- <field name="next_phase_id" ref="symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza"/>
2584
- <field name="state_code">E-CC01-0062</field>
2585
- <field name="wizard_result">SUCCESS</field>
2586
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1832_-_gestione_scarti_da_cruscotto_annullamento_forzato')])]"/>
2587
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2588
- </record>
2589
- <record id="symple_triplet_phase_result_C1448_-_OK_controlli_RCU_E-CC01-0064" model="symple.triplet.phase.result">
2590
- <field name="active">True</field>
2591
- <field name="has_message">False</field>
2592
- <field name="is_annulment">False</field>
2593
- <field name="is_dl_solicitation_result">False</field>
2594
- <field name="is_hidden">False</field>
2595
- <field name="is_quote_expired">False</field>
2596
- <field name="name">C1448 - OK controlli RCU</field>
2597
- <field name="next_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
2598
- <field name="state_code">E-CC01-0064</field>
2599
- <field name="wizard_result">SUCCESS</field>
2600
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1832_-_gestione_scarti_da_cruscotto_annullamento_forzato')])]"/>
2601
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2602
- </record>
2603
- <record id="symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento" model="symple.triplet.phase">
2604
- <field name="active">True</field>
2605
- <field name="child_case">False</field>
2606
- <field name="code"># Available variables:
2607
- # - case_id: the case that just reached this phase
2608
- # - request: allows you to make HTTP requests (method, url, headers, data)
2609
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2610
- # - json_load: allows you to use JSON.load to convert a json into an object
2611
- # - env: Odoo Environment on which the action is triggered
2612
- # - time, datetime, dateutil, timezone: useful Python libraries
2613
- # - float_compare: Odoo function to compare floats based on specific precisions
2614
- # - ValidationError: Warning Exception to use with raise
2615
- # - Command: x2Many commands namespace
2616
- # - OrderedDict: ordered dictionaries
2617
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2618
- # (line = case id, func = phase name)
2619
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2620
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2621
- # To return a result, assign: result = {...}
2622
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2623
- # phase result will not be set.
2624
-
2625
-
2626
-
2627
- </field>
2628
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2629
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
2630
- <field name="is_a_postalizer_phase">False</field>
2631
- <field name="is_compute_refund">False</field>
2632
- <field name="is_dl">False</field>
2633
- <field name="is_needs_child_case">False</field>
2634
- <field name="is_pick_refund_template">False</field>
2635
- <field name="is_process_managed">False</field>
2636
- <field name="is_quote_accepted">False</field>
2637
- <field name="is_quote_sent">False</field>
2638
- <field name="is_timeout">False</field>
2639
- <field name="is_voidable">False</field>
2640
- <field name="name">A0833 - In attesa ricezione Ammissibilità Annullamento</field>
2641
- </record>
2642
- <record id="symple_triplet_phase_result_C2224_-_OK_-_Ammissibilit__Hub_E-CC01-0055" model="symple.triplet.phase.result">
2643
- <field name="active">True</field>
2644
- <field name="has_message">False</field>
2645
- <field name="is_annulment">False</field>
2646
- <field name="is_dl_solicitation_result">False</field>
2647
- <field name="is_hidden">False</field>
2648
- <field name="is_quote_expired">False</field>
2649
- <field name="name">C2224 - OK - Ammissibilità Hub</field>
2650
- <field name="next_phase_id" ref="symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento"/>
2651
- <field name="state_code">E-CC01-0055</field>
2652
- <field name="wizard_result">SUCCESS</field>
2653
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2143_-_In_attesa_check_IFS_Annullamento_forzato')])]"/>
2654
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2655
- </record>
2656
- <record id="symple_triplet_phase_result_C1038_-_Ammissibilit__KO_E-CC01-0066" model="symple.triplet.phase.result">
2657
- <field name="active">True</field>
2658
- <field name="has_message">False</field>
2659
- <field name="is_annulment">False</field>
2660
- <field name="is_dl_solicitation_result">False</field>
2661
- <field name="is_hidden">False</field>
2662
- <field name="is_quote_expired">False</field>
2663
- <field name="name">C1038 - Ammissibilità KO</field>
2664
- <field name="next_phase_id" ref="symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento"/>
2665
- <field name="state_code">E-CC01-0066</field>
2666
- <field name="wizard_result">SUCCESS</field>
2667
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento')])]"/>
2668
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2669
- </record>
2670
- <record id="symple_triplet_phase_result_C1448_-_OK_controlli_RCU_E-CC01-0068" model="symple.triplet.phase.result">
2671
- <field name="active">True</field>
2672
- <field name="has_message">False</field>
2673
- <field name="is_annulment">False</field>
2674
- <field name="is_dl_solicitation_result">False</field>
2675
- <field name="is_hidden">False</field>
2676
- <field name="is_quote_expired">False</field>
2677
- <field name="name">C1448 - OK controlli RCU</field>
2678
- <field name="next_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
2679
- <field name="state_code">E-CC01-0068</field>
2680
- <field name="wizard_result">SUCCESS</field>
2681
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento')])]"/>
2682
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2683
- </record>
2684
- <record id="symple_triplet_phase_A0366_-_In_attesa_Esito_finale_annullamento" model="symple.triplet.phase">
2685
- <field name="active">True</field>
2686
- <field name="child_case">False</field>
2687
- <field name="code"># Available variables:
2688
- # - case_id: the case that just reached this phase
2689
- # - request: allows you to make HTTP requests (method, url, headers, data)
2690
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2691
- # - json_load: allows you to use JSON.load to convert a json into an object
2692
- # - env: Odoo Environment on which the action is triggered
2693
- # - time, datetime, dateutil, timezone: useful Python libraries
2694
- # - float_compare: Odoo function to compare floats based on specific precisions
2695
- # - ValidationError: Warning Exception to use with raise
2696
- # - Command: x2Many commands namespace
2697
- # - OrderedDict: ordered dictionaries
2698
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2699
- # (line = case id, func = phase name)
2700
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2701
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2702
- # To return a result, assign: result = {...}
2703
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2704
- # phase result will not be set.
2705
-
2706
-
2707
-
2708
- </field>
2709
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2710
- <field name="is_a_postalizer_phase">False</field>
2711
- <field name="is_compute_refund">False</field>
2712
- <field name="is_dl">False</field>
2713
- <field name="is_needs_child_case">False</field>
2714
- <field name="is_pick_refund_template">False</field>
2715
- <field name="is_process_managed">False</field>
2716
- <field name="is_quote_accepted">False</field>
2717
- <field name="is_quote_sent">False</field>
2718
- <field name="is_timeout">False</field>
2719
- <field name="is_voidable">False</field>
2720
- <field name="name">A0366 - In attesa Esito finale annullamento</field>
2721
- </record>
2722
- <record id="symple_triplet_phase_result_C1037_-_Ammissibilit__OK_E-CC01-0065" model="symple.triplet.phase.result">
2723
- <field name="active">True</field>
2724
- <field name="has_message">False</field>
2725
- <field name="is_annulment">False</field>
2726
- <field name="is_dl_solicitation_result">False</field>
2727
- <field name="is_hidden">False</field>
2728
- <field name="is_quote_expired">False</field>
2729
- <field name="name">C1037 - Ammissibilità OK</field>
2730
- <field name="next_phase_id" ref="symple_triplet_phase_A0366_-_In_attesa_Esito_finale_annullamento"/>
2731
- <field name="state_code">E-CC01-0065</field>
2732
- <field name="wizard_result">SUCCESS</field>
2733
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento')])]"/>
2734
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2735
- </record>
2736
- <record id="symple_triplet_phase_result_C1064_-_Esito_finale_Annullamento_KO_E-CC01-0071" model="symple.triplet.phase.result">
2737
- <field name="active">True</field>
2738
- <field name="has_message">False</field>
2739
- <field name="is_annulment">False</field>
2740
- <field name="is_dl_solicitation_result">False</field>
2741
- <field name="is_hidden">False</field>
2742
- <field name="is_quote_expired">False</field>
2743
- <field name="name">C1064 - Esito finale Annullamento KO</field>
2744
- <field name="next_phase_id" ref="symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza"/>
2745
- <field name="state_code">E-CC01-0071</field>
2746
- <field name="wizard_result">SUCCESS</field>
2747
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0366_-_In_attesa_Esito_finale_annullamento')])]"/>
2748
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2749
- </record>
2750
- <record id="symple_triplet_phase_result_C1448_-_OK_controlli_RCU_E-CC01-0073" model="symple.triplet.phase.result">
2751
- <field name="active">True</field>
2752
- <field name="has_message">False</field>
2753
- <field name="is_annulment">False</field>
2754
- <field name="is_dl_solicitation_result">False</field>
2755
- <field name="is_hidden">False</field>
2756
- <field name="is_quote_expired">False</field>
2757
- <field name="name">C1448 - OK controlli RCU</field>
2758
- <field name="next_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
2759
- <field name="state_code">E-CC01-0073</field>
2760
- <field name="wizard_result">SUCCESS</field>
2761
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0366_-_In_attesa_Esito_finale_annullamento')])]"/>
2762
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2763
- </record>
2764
- <record id="symple_triplet_phase_A0809_-_Case_Annullato" model="symple.triplet.phase">
2765
- <field name="active">True</field>
2766
- <field name="child_case">False</field>
2767
- <field name="code"># Available variables:
2768
- # - case_id: the case that just reached this phase
2769
- # - request: allows you to make HTTP requests (method, url, headers, data)
2770
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2771
- # - json_load: allows you to use JSON.load to convert a json into an object
2772
- # - env: Odoo Environment on which the action is triggered
2773
- # - time, datetime, dateutil, timezone: useful Python libraries
2774
- # - float_compare: Odoo function to compare floats based on specific precisions
2775
- # - ValidationError: Warning Exception to use with raise
2776
- # - Command: x2Many commands namespace
2777
- # - OrderedDict: ordered dictionaries
2778
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2779
- # (line = case id, func = phase name)
2780
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2781
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2782
- # To return a result, assign: result = {...}
2783
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2784
- # phase result will not be set.
2785
-
2786
- if case_id.matrix_process_id:
2787
- case_id.close_matrix_process()
2788
-
2789
- </field>
2790
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2791
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','Cancelled')])" />
2792
- <field name="is_a_postalizer_phase">False</field>
2793
- <field name="is_compute_refund">False</field>
2794
- <field name="is_dl">False</field>
2795
- <field name="is_needs_child_case">False</field>
2796
- <field name="is_pick_refund_template">False</field>
2797
- <field name="is_process_managed">False</field>
2798
- <field name="is_quote_accepted">False</field>
2799
- <field name="is_quote_sent">False</field>
2800
- <field name="is_timeout">False</field>
2801
- <field name="is_voidable">False</field>
2802
- <field name="name">A0809 - Case Annullato</field>
2803
- <field name="set_result_automatically">from_code</field>
2804
- </record>
2805
- <record id="symple_triplet_phase_result_C1402_-_Annullamento_Risoluzione_contrattuale_E-CC01-0001" model="symple.triplet.phase.result">
2806
- <field name="active">True</field>
2807
- <field name="has_message">False</field>
2808
- <field name="is_annulment">False</field>
2809
- <field name="is_dl_solicitation_result">False</field>
2810
- <field name="is_hidden">False</field>
2811
- <field name="is_quote_expired">False</field>
2812
- <field name="name">C1402 - Annullamento Risoluzione contrattuale</field>
2813
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2814
- <field name="state_code">E-CC01-0001</field>
2815
- <field name="wizard_result">CANCEL</field>
2816
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1001_-_Apertura_Wizard_Risoluzione_contrattuale')])]"/>
2817
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Cancel')])" />
2818
- </record>
2819
- <record id="symple_triplet_phase_result_C1449_-_KO_controlli_RCU___Data_decorrenza_E-CC01-0028" model="symple.triplet.phase.result">
2820
- <field name="active">True</field>
2821
- <field name="has_message">False</field>
2822
- <field name="is_annulment">False</field>
2823
- <field name="is_dl_solicitation_result">False</field>
2824
- <field name="is_hidden">False</field>
2825
- <field name="is_quote_expired">False</field>
2826
- <field name="name">C1449 - KO controlli RCU + Data decorrenza</field>
2827
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2828
- <field name="state_code">E-CC01-0028</field>
2829
- <field name="wizard_result">KO</field>
2830
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza')])]"/>
2831
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO')])" />
2832
- </record>
2833
- <record id="symple_triplet_phase_result_C1449_-_KO_controlli_RCU___Data_decorrenza_E-CC01-0045" model="symple.triplet.phase.result">
2834
- <field name="active">True</field>
2835
- <field name="has_message">False</field>
2836
- <field name="is_annulment">False</field>
2837
- <field name="is_dl_solicitation_result">False</field>
2838
- <field name="is_hidden">False</field>
2839
- <field name="is_quote_expired">False</field>
2840
- <field name="name">C1449 - KO controlli RCU + Data decorrenza</field>
2841
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2842
- <field name="state_code">E-CC01-0045</field>
2843
- <field name="wizard_result">SUCCESS</field>
2844
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento')])]"/>
2845
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2846
- </record>
2847
- <record id="symple_triplet_phase_result_C1449_-_KO_controlli_RCU___Data_decorrenza_E-CC01-0050" model="symple.triplet.phase.result">
2848
- <field name="active">True</field>
2849
- <field name="has_message">False</field>
2850
- <field name="is_annulment">False</field>
2851
- <field name="is_dl_solicitation_result">False</field>
2852
- <field name="is_hidden">False</field>
2853
- <field name="is_quote_expired">False</field>
2854
- <field name="name">C1449 - KO controlli RCU + Data decorrenza</field>
2855
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2856
- <field name="state_code">E-CC01-0050</field>
2857
- <field name="wizard_result">KO</field>
2858
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2562_-_verifica_avvio_gestione_manuale_annullamento')])]"/>
2859
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO')])" />
2860
- </record>
2861
- <record id="symple_triplet_phase_result_C1449_-_KO_controlli_RCU___Data_decorrenza_E-CC01-0058" model="symple.triplet.phase.result">
2862
- <field name="active">True</field>
2863
- <field name="has_message">False</field>
2864
- <field name="is_annulment">False</field>
2865
- <field name="is_dl_solicitation_result">False</field>
2866
- <field name="is_hidden">False</field>
2867
- <field name="is_quote_expired">False</field>
2868
- <field name="name">C1449 - KO controlli RCU + Data decorrenza</field>
2869
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2870
- <field name="state_code">E-CC01-0058</field>
2871
- <field name="wizard_result">SUCCESS</field>
2872
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento')])]"/>
2873
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2874
- </record>
2875
- <record id="symple_triplet_phase_result_C1449_-_KO_controlli_RCU___Data_decorrenza_E-CC01-0063" model="symple.triplet.phase.result">
2876
- <field name="active">True</field>
2877
- <field name="has_message">False</field>
2878
- <field name="is_annulment">False</field>
2879
- <field name="is_dl_solicitation_result">False</field>
2880
- <field name="is_hidden">False</field>
2881
- <field name="is_quote_expired">False</field>
2882
- <field name="name">C1449 - KO controlli RCU + Data decorrenza</field>
2883
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2884
- <field name="state_code">E-CC01-0063</field>
2885
- <field name="wizard_result">SUCCESS</field>
2886
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1832_-_gestione_scarti_da_cruscotto_annullamento_forzato')])]"/>
2887
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2888
- </record>
2889
- <record id="symple_triplet_phase_result_C1449_-_KO_controlli_RCU___Data_decorrenza_E-CC01-0067" model="symple.triplet.phase.result">
2890
- <field name="active">True</field>
2891
- <field name="has_message">False</field>
2892
- <field name="is_annulment">False</field>
2893
- <field name="is_dl_solicitation_result">False</field>
2894
- <field name="is_hidden">False</field>
2895
- <field name="is_quote_expired">False</field>
2896
- <field name="name">C1449 - KO controlli RCU + Data decorrenza</field>
2897
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2898
- <field name="state_code">E-CC01-0067</field>
2899
- <field name="wizard_result">SUCCESS</field>
2900
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento')])]"/>
2901
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2902
- </record>
2903
- <record id="symple_triplet_phase_result_C1449_-_KO_controlli_RCU___Data_decorrenza_E-CC01-0072" model="symple.triplet.phase.result">
2904
- <field name="active">True</field>
2905
- <field name="has_message">False</field>
2906
- <field name="is_annulment">False</field>
2907
- <field name="is_dl_solicitation_result">False</field>
2908
- <field name="is_hidden">False</field>
2909
- <field name="is_quote_expired">False</field>
2910
- <field name="name">C1449 - KO controlli RCU + Data decorrenza</field>
2911
- <field name="next_phase_id" ref="symple_triplet_phase_A0809_-_Case_Annullato"/>
2912
- <field name="state_code">E-CC01-0072</field>
2913
- <field name="wizard_result">SUCCESS</field>
2914
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0366_-_In_attesa_Esito_finale_annullamento')])]"/>
2915
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2916
- </record>
2917
- <record id="symple_triplet_phase_A0810_-_Case_Lavorato" model="symple.triplet.phase">
2918
- <field name="active">True</field>
2919
- <field name="child_case">False</field>
2920
- <field name="code">if case_id.matrix_process_id:
2921
- case_id.close_matrix_process()</field>
2922
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
2923
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','Done')])" />
2924
- <field name="is_a_postalizer_phase">False</field>
2925
- <field name="is_compute_refund">False</field>
2926
- <field name="is_dl">False</field>
2927
- <field name="is_needs_child_case">False</field>
2928
- <field name="is_pick_refund_template">False</field>
2929
- <field name="is_process_managed">False</field>
2930
- <field name="is_quote_accepted">False</field>
2931
- <field name="is_quote_sent">False</field>
2932
- <field name="is_timeout">False</field>
2933
- <field name="is_voidable">False</field>
2934
- <field name="name">A0810 - Case Lavorato</field>
2935
- <field name="set_result_automatically">from_code</field>
2936
- </record>
2937
- <record id="symple_triplet_phase_result_C1006_-_OK_Integrazione_M2C_E-CC01-0037" model="symple.triplet.phase.result">
2938
- <field name="active">True</field>
2939
- <field name="has_message">False</field>
2940
- <field name="is_annulment">False</field>
2941
- <field name="is_dl_solicitation_result">False</field>
2942
- <field name="is_hidden">False</field>
2943
- <field name="is_quote_expired">False</field>
2944
- <field name="name">C1006 - OK Integrazione M2C</field>
2945
- <field name="next_phase_id" ref="symple_triplet_phase_A0810_-_Case_Lavorato"/>
2946
- <field name="state_code">E-CC01-0037</field>
2947
- <field name="wizard_result">SUCCESS</field>
2948
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0803_-_In_attesa_esito_M2C')])]"/>
2949
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2950
- </record>
2951
- <record id="symple_triplet_phase_result_C2551_-_OK_Intregrazione_M2C_-_Fatture_di_Storno_da_emettere_E-CC01-0038" model="symple.triplet.phase.result">
2952
- <field name="active">True</field>
2953
- <field name="has_message">False</field>
2954
- <field name="is_annulment">False</field>
2955
- <field name="is_dl_solicitation_result">False</field>
2956
- <field name="is_hidden">False</field>
2957
- <field name="is_quote_expired">False</field>
2958
- <field name="name">C2551 - OK Intregrazione M2C - Fatture di Storno da emettere</field>
2959
- <field name="next_phase_id" ref="symple_triplet_phase_A0810_-_Case_Lavorato"/>
2960
- <field name="state_code">E-CC01-0038</field>
2961
- <field name="wizard_result">SUCCESS</field>
2962
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0803_-_In_attesa_esito_M2C')])]"/>
2963
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2964
- </record>
2965
- <record id="symple_triplet_phase_result_C2550_-_case_creato_E-CC01-0040" model="symple.triplet.phase.result">
2966
- <field name="active">True</field>
2967
- <field name="has_message">False</field>
2968
- <field name="is_annulment">False</field>
2969
- <field name="is_dl_solicitation_result">False</field>
2970
- <field name="is_hidden">False</field>
2971
- <field name="is_quote_expired">False</field>
2972
- <field name="name">C2550 - case creato</field>
2973
- <field name="next_phase_id" ref="symple_triplet_phase_A0810_-_Case_Lavorato"/>
2974
- <field name="state_code">E-CC01-0040</field>
2975
- <field name="wizard_result">SUCCESS</field>
2976
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1836_-_Apertura_case_figlio')])]"/>
2977
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
2978
- </record>
2979
- <record id="symple_triplet_phase_A1833_-_Case_annullato_da_APR" model="symple.triplet.phase">
2980
- <field name="active">True</field>
2981
- <field name="child_case">False</field>
2982
- <field name="code"># Available variables:
2983
- # - case_id: the case that just reached this phase
2984
- # - request: allows you to make HTTP requests (method, url, headers, data)
2985
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
2986
- # - json_load: allows you to use JSON.load to convert a json into an object
2987
- # - env: Odoo Environment on which the action is triggered
2988
- # - time, datetime, dateutil, timezone: useful Python libraries
2989
- # - float_compare: Odoo function to compare floats based on specific precisions
2990
- # - ValidationError: Warning Exception to use with raise
2991
- # - Command: x2Many commands namespace
2992
- # - OrderedDict: ordered dictionaries
2993
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
2994
- # (line = case id, func = phase name)
2995
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
2996
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
2997
- # To return a result, assign: result = {...}
2998
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
2999
- # phase result will not be set.
3000
-
3001
-
3002
-
3003
- </field>
3004
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3005
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','Cancelled')])" />
3006
- <field name="is_a_postalizer_phase">False</field>
3007
- <field name="is_compute_refund">False</field>
3008
- <field name="is_dl">False</field>
3009
- <field name="is_needs_child_case">False</field>
3010
- <field name="is_pick_refund_template">False</field>
3011
- <field name="is_process_managed">False</field>
3012
- <field name="is_quote_accepted">False</field>
3013
- <field name="is_quote_sent">False</field>
3014
- <field name="is_timeout">False</field>
3015
- <field name="is_voidable">False</field>
3016
- <field name="name">A1833 - Case annullato da APR</field>
3017
- </record>
3018
- <record id="symple_triplet_phase_result_C1063_-_Esito_finale_Annullamento_OK_E-CC01-0070" model="symple.triplet.phase.result">
3019
- <field name="active">True</field>
3020
- <field name="has_message">False</field>
3021
- <field name="is_annulment">False</field>
3022
- <field name="is_dl_solicitation_result">False</field>
3023
- <field name="is_hidden">False</field>
3024
- <field name="is_quote_expired">False</field>
3025
- <field name="name">C1063 - Esito finale Annullamento OK</field>
3026
- <field name="next_phase_id" ref="symple_triplet_phase_A1833_-_Case_annullato_da_APR"/>
3027
- <field name="state_code">E-CC01-0070</field>
3028
- <field name="wizard_result">SUCCESS</field>
3029
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0366_-_In_attesa_Esito_finale_annullamento')])]"/>
3030
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3031
- </record>
3032
- <record id="symple_triplet_phase_result_C2599_-_annullamento_confermato_E-CC01-00082" model="symple.triplet.phase.result">
3033
- <field name="active">True</field>
3034
- <field name="has_message">False</field>
3035
- <field name="is_annulment">False</field>
3036
- <field name="is_dl_solicitation_result">False</field>
3037
- <field name="is_hidden">False</field>
3038
- <field name="is_quote_expired">False</field>
3039
- <field name="name">C2599 - annullamento confermato</field>
3040
- <field name="next_phase_id" ref="symple_triplet_phase_A1833_-_Case_annullato_da_APR"/>
3041
- <field name="state_code">E-CC01-00082</field>
3042
- <field name="wizard_result">SUCCESS</field>
3043
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento')])]"/>
3044
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3045
- </record>
3046
- <record id="symple_triplet_phase_A1835_-_Case_annullato_da_APN" model="symple.triplet.phase">
3047
- <field name="active">True</field>
3048
- <field name="child_case">False</field>
3049
- <field name="code"># Available variables:
3050
- # - case_id: the case that just reached this phase
3051
- # - request: allows you to make HTTP requests (method, url, headers, data)
3052
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3053
- # - json_load: allows you to use JSON.load to convert a json into an object
3054
- # - env: Odoo Environment on which the action is triggered
3055
- # - time, datetime, dateutil, timezone: useful Python libraries
3056
- # - float_compare: Odoo function to compare floats based on specific precisions
3057
- # - ValidationError: Warning Exception to use with raise
3058
- # - Command: x2Many commands namespace
3059
- # - OrderedDict: ordered dictionaries
3060
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3061
- # (line = case id, func = phase name)
3062
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3063
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3064
- # To return a result, assign: result = {...}
3065
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3066
- # phase result will not be set.
3067
-
3068
-
3069
-
3070
- </field>
3071
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3072
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','Cancelled')])" />
3073
- <field name="is_a_postalizer_phase">False</field>
3074
- <field name="is_compute_refund">False</field>
3075
- <field name="is_dl">False</field>
3076
- <field name="is_needs_child_case">False</field>
3077
- <field name="is_pick_refund_template">False</field>
3078
- <field name="is_process_managed">False</field>
3079
- <field name="is_quote_accepted">False</field>
3080
- <field name="is_quote_sent">False</field>
3081
- <field name="is_timeout">False</field>
3082
- <field name="is_voidable">False</field>
3083
- <field name="name">A1835 - Case annullato da APN</field>
3084
- </record>
3085
- <record id="symple_triplet_phase_result_C1763_-_Annullamento_passivo_dal_SII_E-CC01-0017" model="symple.triplet.phase.result">
3086
- <field name="active">True</field>
3087
- <field name="has_message">False</field>
3088
- <field name="is_annulment">False</field>
3089
- <field name="is_dl_solicitation_result">False</field>
3090
- <field name="is_hidden">False</field>
3091
- <field name="is_quote_expired">False</field>
3092
- <field name="name">C1763 - Annullamento passivo dal SII</field>
3093
- <field name="next_phase_id" ref="symple_triplet_phase_A1835_-_Case_annullato_da_APN"/>
3094
- <field name="state_code">E-CC01-0017</field>
3095
- <field name="wizard_result">DEF_SUCCESS</field>
3096
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1717_-_Gestione_scarti_da_cruscotto')])]"/>
3097
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Definitive Success')])" />
3098
- </record>
3099
- <record id="symple_triplet_phase_result_C1763_-_Annullamento_passivo_dal_SII_E-CC01-0030" model="symple.triplet.phase.result">
3100
- <field name="active">True</field>
3101
- <field name="has_message">False</field>
3102
- <field name="is_annulment">False</field>
3103
- <field name="is_dl_solicitation_result">False</field>
3104
- <field name="is_hidden">False</field>
3105
- <field name="is_quote_expired">False</field>
3106
- <field name="name">C1763 - Annullamento passivo dal SII</field>
3107
- <field name="next_phase_id" ref="symple_triplet_phase_A1835_-_Case_annullato_da_APN"/>
3108
- <field name="state_code">E-CC01-0030</field>
3109
- <field name="wizard_result">CANCEL-APN</field>
3110
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza')])]"/>
3111
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','CANCEL-APN')])" />
3112
- </record>
3113
- <record id="symple_triplet_phase_result_C1763_-_Annullamento_passivo_dal_SII_E-CC01-0047" model="symple.triplet.phase.result">
3114
- <field name="active">True</field>
3115
- <field name="has_message">False</field>
3116
- <field name="is_annulment">False</field>
3117
- <field name="is_dl_solicitation_result">False</field>
3118
- <field name="is_hidden">False</field>
3119
- <field name="is_quote_expired">False</field>
3120
- <field name="name">C1763 - Annullamento passivo dal SII</field>
3121
- <field name="next_phase_id" ref="symple_triplet_phase_A1835_-_Case_annullato_da_APN"/>
3122
- <field name="state_code">E-CC01-0047</field>
3123
- <field name="wizard_result">SUCCESS</field>
3124
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento')])]"/>
3125
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3126
- </record>
3127
- <record id="symple_triplet_phase_result_C1763_-_Annullamento_passivo_dal_SII_E-CC01-0052" model="symple.triplet.phase.result">
3128
- <field name="active">True</field>
3129
- <field name="has_message">False</field>
3130
- <field name="is_annulment">False</field>
3131
- <field name="is_dl_solicitation_result">False</field>
3132
- <field name="is_hidden">False</field>
3133
- <field name="is_quote_expired">False</field>
3134
- <field name="name">C1763 - Annullamento passivo dal SII</field>
3135
- <field name="next_phase_id" ref="symple_triplet_phase_A1835_-_Case_annullato_da_APN"/>
3136
- <field name="state_code">E-CC01-0052</field>
3137
- <field name="wizard_result">CANCEL</field>
3138
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2562_-_verifica_avvio_gestione_manuale_annullamento')])]"/>
3139
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Cancel')])" />
3140
- </record>
3141
- <record id="symple_triplet_phase_result_C1763_-_Annullamento_passivo_dal_SII_E-CC01-0060" model="symple.triplet.phase.result">
3142
- <field name="active">True</field>
3143
- <field name="has_message">False</field>
3144
- <field name="is_annulment">False</field>
3145
- <field name="is_dl_solicitation_result">False</field>
3146
- <field name="is_hidden">False</field>
3147
- <field name="is_quote_expired">False</field>
3148
- <field name="name">C1763 - Annullamento passivo dal SII</field>
3149
- <field name="next_phase_id" ref="symple_triplet_phase_A1835_-_Case_annullato_da_APN"/>
3150
- <field name="state_code">E-CC01-0060</field>
3151
- <field name="wizard_result">SUCCESS</field>
3152
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1732_-_Gestione_scarti_da_cruscotto_annullamento')])]"/>
3153
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3154
- </record>
3155
- <record id="symple_triplet_phase_result_C1763_-_Annullamento_passivo_dal_SII_E-CC01-0069" model="symple.triplet.phase.result">
3156
- <field name="active">True</field>
3157
- <field name="has_message">False</field>
3158
- <field name="is_annulment">False</field>
3159
- <field name="is_dl_solicitation_result">False</field>
3160
- <field name="is_hidden">False</field>
3161
- <field name="is_quote_expired">False</field>
3162
- <field name="name">C1763 - Annullamento passivo dal SII</field>
3163
- <field name="next_phase_id" ref="symple_triplet_phase_A1835_-_Case_annullato_da_APN"/>
3164
- <field name="state_code">E-CC01-0069</field>
3165
- <field name="wizard_result">SUCCESS</field>
3166
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento')])]"/>
3167
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3168
- </record>
3169
- <record id="symple_triplet_phase_result_C1763_-_Annullamento_passivo_dal_SII_E-CC01-0074" model="symple.triplet.phase.result">
3170
- <field name="active">True</field>
3171
- <field name="has_message">False</field>
3172
- <field name="is_annulment">False</field>
3173
- <field name="is_dl_solicitation_result">False</field>
3174
- <field name="is_hidden">False</field>
3175
- <field name="is_quote_expired">False</field>
3176
- <field name="name">C1763 - Annullamento passivo dal SII</field>
3177
- <field name="next_phase_id" ref="symple_triplet_phase_A1835_-_Case_annullato_da_APN"/>
3178
- <field name="state_code">E-CC01-0074</field>
3179
- <field name="wizard_result">SUCCESS</field>
3180
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0366_-_In_attesa_Esito_finale_annullamento')])]"/>
3181
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3182
- </record>
3183
- <record id="symple_triplet_phase_A0811_-_Lavorato_KO" model="symple.triplet.phase">
3184
- <field name="active">True</field>
3185
- <field name="child_case">False</field>
3186
- <field name="code">if case_id.matrix_process_id:
3187
- case_id.close_matrix_process(status="ERROR")</field>
3188
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3189
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','Done KO')])" />
3190
- <field name="is_a_postalizer_phase">False</field>
3191
- <field name="is_compute_refund">False</field>
3192
- <field name="is_dl">False</field>
3193
- <field name="is_needs_child_case">False</field>
3194
- <field name="is_pick_refund_template">False</field>
3195
- <field name="is_process_managed">False</field>
3196
- <field name="is_quote_accepted">False</field>
3197
- <field name="is_quote_sent">False</field>
3198
- <field name="is_timeout">False</field>
3199
- <field name="is_voidable">False</field>
3200
- <field name="name">A0811 - Lavorato KO</field>
3201
- <field name="set_result_automatically">from_code</field>
3202
- </record>
3203
- <record id="symple_triplet_phase_result_C2409_-_KO_Confermato_E-CC01-0006" model="symple.triplet.phase.result">
3204
- <field name="active">True</field>
3205
- <field name="has_message">False</field>
3206
- <field name="is_annulment">False</field>
3207
- <field name="is_dl_solicitation_result">False</field>
3208
- <field name="is_hidden">False</field>
3209
- <field name="is_quote_expired">False</field>
3210
- <field name="name">C2409 - KO Confermato</field>
3211
- <field name="next_phase_id" ref="symple_triplet_phase_A0811_-_Lavorato_KO"/>
3212
- <field name="state_code">E-CC01-0006</field>
3213
- <field name="wizard_result">KO</field>
3214
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1710_-_Verifica_compatibilit__KO')])]"/>
3215
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO')])" />
3216
- </record>
3217
- <record id="symple_triplet_phase_result_C1931_-_Errore_non_rilavorabile_E-CC01-0016" model="symple.triplet.phase.result">
3218
- <field name="active">True</field>
3219
- <field name="has_message">False</field>
3220
- <field name="is_annulment">False</field>
3221
- <field name="is_dl_solicitation_result">False</field>
3222
- <field name="is_hidden">False</field>
3223
- <field name="is_quote_expired">False</field>
3224
- <field name="name">C1931 - Errore non rilavorabile</field>
3225
- <field name="next_phase_id" ref="symple_triplet_phase_A0811_-_Lavorato_KO"/>
3226
- <field name="state_code">E-CC01-0016</field>
3227
- <field name="wizard_result">DEF-KO</field>
3228
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1717_-_Gestione_scarti_da_cruscotto')])]"/>
3229
- </record>
3230
- <record id="symple_triplet_phase_result_C1931_-_Errore_non_rilavorabile_E-CC01-0024" model="symple.triplet.phase.result">
3231
- <field name="active">True</field>
3232
- <field name="has_message">False</field>
3233
- <field name="is_annulment">False</field>
3234
- <field name="is_dl_solicitation_result">False</field>
3235
- <field name="is_hidden">False</field>
3236
- <field name="is_quote_expired">False</field>
3237
- <field name="name">C1931 - Errore non rilavorabile</field>
3238
- <field name="next_phase_id" ref="symple_triplet_phase_A0811_-_Lavorato_KO"/>
3239
- <field name="state_code">E-CC01-0024</field>
3240
- <field name="wizard_result">DEF-KO</field>
3241
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1834_-_Gestione_scarti_da_cruscotto_forzato')])]"/>
3242
- </record>
3243
- <record id="symple_triplet_phase_A1590_-_Verifica_Tipologia_Apertura_Case" model="symple.triplet.phase">
3244
- <field name="active">True</field>
3245
- <field name="child_case">False</field>
3246
- <field name="code"># Available variables:
3247
- # - case_id: the case that just reached this phase
3248
- # - request: allows you to make HTTP requests (method, url, headers, data)
3249
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3250
- # - json_load: allows you to use JSON.load to convert a json into an object
3251
- # - env: Odoo Environment on which the action is triggered
3252
- # - time, datetime, dateutil, timezone: useful Python libraries
3253
- # - float_compare: Odoo function to compare floats based on specific precisions
3254
- # - ValidationError: Warning Exception to use with raise
3255
- # - Command: x2Many commands namespace
3256
- # - OrderedDict: ordered dictionaries
3257
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3258
- # (line = case id, func = phase name)
3259
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3260
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3261
- # To return a result, assign: result = {...}
3262
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3263
- # phase result will not be set.
3264
- try:
3265
- is_automatic = case_id.is_automatic_case
3266
- if is_automatic:
3267
- result = "AUTOMATICO"
3268
- else:
3269
- result = "MANUALE"
3270
- except Exception as e :
3271
- case_id.write({
3272
- 'info_message':(case_id.info_message + "\n" + str(e)) if case_id.info_message else str(e)
3273
- })
3274
-
3275
-
3276
- </field>
3277
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3278
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','New')])" />
3279
- <field name="is_a_postalizer_phase">False</field>
3280
- <field name="is_compute_refund">False</field>
3281
- <field name="is_dl">False</field>
3282
- <field name="is_needs_child_case">False</field>
3283
- <field name="is_pick_refund_template">False</field>
3284
- <field name="is_process_managed">False</field>
3285
- <field name="is_quote_accepted">False</field>
3286
- <field name="is_quote_sent">False</field>
3287
- <field name="is_timeout">False</field>
3288
- <field name="is_voidable">False</field>
3289
- <field name="name">A1590 - Verifica Tipologia Apertura Case</field>
3290
- <field name="set_result_automatically">from_code</field>
3291
- </record>
3292
- <record id="symple_triplet_phase_result_C2251_-_Apertura_Case_Manuale_E-CC01-0001-01" model="symple.triplet.phase.result">
3293
- <field name="active">True</field>
3294
- <field name="has_message">False</field>
3295
- <field name="is_annulment">False</field>
3296
- <field name="is_dl_solicitation_result">False</field>
3297
- <field name="is_hidden">False</field>
3298
- <field name="is_quote_expired">False</field>
3299
- <field name="name">C2251 - Apertura Case Manuale</field>
3300
- <field name="next_phase_id" ref="symple_triplet_phase_A1001_-_Apertura_Wizard_Risoluzione_contrattuale"/>
3301
- <field name="state_code">E-CC01-0001-01</field>
3302
- <field name="wizard_result">SUCCESS</field>
3303
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1590_-_Verifica_Tipologia_Apertura_Case')])]"/>
3304
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3305
- </record>
3306
- <record id="symple_workflow_ML_-_RISOLUZIONE_CONTRATTUALE" model="symple.workflow">
3307
- <field name="active">True</field>
3308
- <field name="code"># Available variables:
3309
- # - case_id: the case that just reached this phase
3310
- # - request: allows you to make HTTP requests (method, url, headers, data)
3311
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3312
- # - json_load: allows you to use JSON.load to convert a json into an object
3313
- # - env: Odoo Environment on which the action is triggered
3314
- # - time, datetime, dateutil, timezone: useful Python libraries
3315
- # - float_compare: Odoo function to compare floats based on specific precisions
3316
- # - ValidationError: Warning Exception to use with raise
3317
- # - Command: x2Many commands namespace
3318
- # - OrderedDict: ordered dictionaries
3319
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3320
- # (line = case id, func = phase name)
3321
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3322
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3323
- # To return a result, assign: result = {...}
3324
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3325
- # phase result will not be set.
3326
-
3327
-
3328
-
3329
- </field>
3330
- <field name="execute_code_every_phase">False</field>
3331
- <field name="is_tiqv">False</field>
3332
- <field name="name">ML - RISOLUZIONE CONTRATTUALE</field>
3333
- <field name="triplet_phase_id" ref="symple_triplet_phase_A1590_-_Verifica_Tipologia_Apertura_Case"/>
3334
- <field name="bpmn_diagram"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
3335
- <bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL"
3336
- xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
3337
- xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
3338
- xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
3339
- xmlns:bioc="http://bpmn.io/schema/bpmn/biocolor/1.0"
3340
- xmlns:color="http://www.omg.org/spec/BPMN/non-normative/color/1.0">
3341
- <bpmn:process id="process_458" name="ML - RISOLUZIONE CONTRATTUALE" isExecutable="false"><bpmn:startEvent id="start"/><bpmn:scriptTask id="phase18083" name="A1590 - Verifica Tipologia Apertura Case"/><bpmn:userTask id="phase17995" name="A1001 - Apertura Wizard Risoluzione contrattuale"/><bpmn:scriptTask id="phase18025" name="A0809 - Case Annullato"/><bpmn:scriptTask id="phase17996" name="A1709 - verifica compatibilità"/><bpmn:userTask id="phase17997" name="A1710 - Verifica compatibilità KO"/><bpmn:scriptTask id="phase18029" name="A0811 - Lavorato KO"/><bpmn:scriptTask id="phase17998" name="A1672 - Recupero dati a CRM"/><bpmn:scriptTask id="phase18000" name="A1559 - Invio alla Market Communication"/><bpmn:serviceTask id="phase18001" name="A1715 - In attesa check IFS"/><bpmn:serviceTask id="phase18002" name="A1717 - Gestione scarti da cruscotto"/><bpmn:serviceTask id="phase18028" name="A1835 - Case annullato da APN"/><bpmn:serviceTask id="phase20854" name="A2338 - Inserimento Pratica"/><bpmn:userTask id="phase18003" name="A2558 - verifica avvio gestione manuale"/><bpmn:serviceTask id="phase18004" name="A1879 - Invio alla Market Comm Forzato"/><bpmn:serviceTask id="phase18005" name="A1806 - In Attesa Check HUB Forzato"/><bpmn:serviceTask id="phase18006" name="A1834 - Gestione scarti da cruscotto forzato"/><bpmn:serviceTask id="phase18007" name="A0816 - In attesa esito ammissibilità"/><bpmn:scriptTask id="phase18099" name="A1556 - Verica commodity"/><bpmn:userTask id="phase18008" name="A1004 - Verifica RCU + Data decorrenza"/><bpmn:scriptTask id="phase18009" name="A2397 - OK RCU + verifica data decorrenza"/><bpmn:scriptTask id="phase18010" name="A1577 - Chiusura Ordine CRM"/><bpmn:scriptTask id="phase18012" name="A2398 - Invio ordine CRM"/><bpmn:scriptTask id="phase18013" name="A0802 - Integrazione M2C"/><bpmn:serviceTask id="phase18014" name="A0803 - In attesa esito M2C"/><bpmn:scriptTask id="phase18026" name="A0810 - Case Lavorato"/><bpmn:scriptTask id="phase18015" name="A1836 - Apertura case figlio"/><bpmn:userTask id="phase18011" name="A1321 - Errore CRM (RC1)"/><bpmn:scriptTask id="phase18016" name="A1595 - Invio Annullamento alla Market Communication"/><bpmn:serviceTask id="phase18017" name="A1767 - In attesa check IFS Annullamento"/><bpmn:serviceTask id="phase20855" name="A2561 - verifica stato invio pratica da annullare"/><bpmn:serviceTask id="phase20856" name="A0832 - Invio Richiesta Annullamento"/><bpmn:userTask id="phase18018" name="A2562 - verifica avvio gestione manuale annullamento"/><bpmn:scriptTask id="phase18019" name="A2142 - Invio alla marketcom annullamento forzato"/><bpmn:serviceTask id="phase18020" name="A2143 - In attesa check IFS Annullamento forzato"/><bpmn:serviceTask id="phase18022" name="A1832 - gestione scarti da cruscotto annullamento forzato"/><bpmn:serviceTask id="phase18023" name="A0833 - In attesa ricezione Ammissibilità Annullamento"/><bpmn:serviceTask id="phase18024" name="A0366 - In attesa Esito finale annullamento"/><bpmn:serviceTask id="phase18027" name="A1833 - Case annullato da APR"/><bpmn:serviceTask id="phase18021" name="A1732 - Gestione scarti da cruscotto annullamento"/><bpmn:sendTask id="phase18100" name="A2598 - Invio Pec"/><bpmn:userTask id="phase17999" name="A1323 - Errore CRM (Recupero dati)"/><bpmn:scriptTask id="phase18098" name="A1001 – Creazione Case di Risoluzione Contrattuale Automatica"/><bpmn:sequenceFlow id="flowStart" sourceRef="start" targetRef="phase18083"/><bpmn:sequenceFlow id="flow18083" sourceRef="phase18083" targetRef="gateway18083"/><bpmn:sequenceFlow id="flow31428" name="C2251 - Apertura Case Manuale" sourceRef="gateway18083" targetRef="phase17995"/><bpmn:sequenceFlow id="flow17995" sourceRef="phase17995" targetRef="gateway17995"/><bpmn:sequenceFlow id="flow31312" name="C1402 - Annullamento Risoluzione contrattuale" sourceRef="gateway17995" targetRef="phase18025"/><bpmn:sequenceFlow id="flowEnd18025" sourceRef="phase18025" targetRef="end18025"/><bpmn:sequenceFlow id="flow31313" name="C1401 - Risoluzione contrattuale OK" sourceRef="gateway17995" targetRef="phase17996"/><bpmn:sequenceFlow id="flow17996" sourceRef="phase17996" targetRef="gateway17996"/><bpmn:sequenceFlow id="flow31314" name="C404 - KO - Incompatibile" sourceRef="gateway17996" targetRef="phase17997"/><bpmn:sequenceFlow id="flow17997" sourceRef="phase17997" targetRef="gateway17997"/><bpmn:sequenceFlow id="flow31317" name="C2409 - KO Confermato" sourceRef="gateway17997" targetRef="phase18029"/><bpmn:sequenceFlow id="flowEnd18029" sourceRef="phase18029" targetRef="end18029"/><bpmn:sequenceFlow id="flow31318" name="C2410 - OK Incompatibilità Gestita" sourceRef="gateway17997" targetRef="phase17996"/><bpmn:sequenceFlow id="flow31315" name="C2654 - Processo Compatibile" sourceRef="gateway17996" targetRef="phase17998"/><bpmn:sequenceFlow id="flow17998" sourceRef="phase17998" targetRef="gateway17998"/><bpmn:sequenceFlow id="flow31319" name="C2365 - Recupero Dati OK" sourceRef="gateway17998" targetRef="phase18000"/><bpmn:sequenceFlow id="flow31322" name="C1019 - Inviata" sourceRef="phase18000" targetRef="phase18001"/><bpmn:sequenceFlow id="flow18001" sourceRef="phase18001" targetRef="gateway18001"/><bpmn:sequenceFlow id="flow31323" name="C2225 - KO - Ammissibilità Hub" sourceRef="gateway18001" targetRef="phase18002"/><bpmn:sequenceFlow id="flow18002" sourceRef="phase18002" targetRef="gateway18002"/><bpmn:sequenceFlow id="flow31326" name="C2416 - risottomessa da cruscotto" sourceRef="gateway18002" targetRef="phase18001"/><bpmn:sequenceFlow id="flow31327" name="C1931 - Errore non rilavorabile" sourceRef="gateway18002" targetRef="phase18029"/><bpmn:sequenceFlow id="flow31328" name="C1763 - Annullamento passivo dal SII" sourceRef="gateway18002" targetRef="phase18028"/><bpmn:sequenceFlow id="flowEnd18028" sourceRef="phase18028" targetRef="end18028"/><bpmn:sequenceFlow id="flow31324" name="C2224 - OK - Ammissibilità Hub" sourceRef="gateway18001" targetRef="phase20854"/><bpmn:sequenceFlow id="flow20854" sourceRef="phase20854" targetRef="gateway20854"/><bpmn:sequenceFlow id="flow31325" name="C3118 - KO AtoA/pdc" sourceRef="gateway20854" targetRef="phase18003"/><bpmn:sequenceFlow id="flow18003" sourceRef="phase18003" targetRef="gateway18003"/><bpmn:sequenceFlow id="flow31329" name="C2598 - gestione manuale" sourceRef="gateway18003" targetRef="phase18004"/><bpmn:sequenceFlow id="flow31331" name="C1019 - Inviata" sourceRef="phase18004" targetRef="phase18005"/><bpmn:sequenceFlow id="flow18005" sourceRef="phase18005" targetRef="gateway18005"/><bpmn:sequenceFlow id="flow31332" name="C2225 - KO - Ammissibilità Hub" sourceRef="gateway18005" targetRef="phase18006"/><bpmn:sequenceFlow id="flow18006" sourceRef="phase18006" targetRef="gateway18006"/><bpmn:sequenceFlow id="flow31334" name="C2416 - risottomessa da cruscotto" sourceRef="gateway18006" targetRef="phase18005"/><bpmn:sequenceFlow id="flow31335" name="C1931 - Errore non rilavorabile" sourceRef="gateway18006" targetRef="phase18029"/><bpmn:sequenceFlow id="flow31333" name="C2224 - OK - Ammissibilità Hub" sourceRef="gateway18005" targetRef="phase18007"/><bpmn:sequenceFlow id="flow18007" sourceRef="phase18007" targetRef="gateway18007"/><bpmn:sequenceFlow id="flow31336" name="C1037 - Ammissibilità OK" sourceRef="gateway18007" targetRef="phase18099"/><bpmn:sequenceFlow id="flow18099" sourceRef="phase18099" targetRef="gateway18099"/><bpmn:sequenceFlow id="flow31443" name="C2222 – Commodity Gas" sourceRef="gateway18099" targetRef="phase18008"/><bpmn:sequenceFlow id="flow18008" sourceRef="phase18008" targetRef="gateway18008"/><bpmn:sequenceFlow id="flow31338" name="C1448 - OK controlli RCU + Data decorrenza" sourceRef="gateway18008" targetRef="phase18009"/><bpmn:sequenceFlow id="flow31342" name="C1936 - Data raggiunta" sourceRef="phase18009" targetRef="phase18010"/><bpmn:sequenceFlow id="flow18010" sourceRef="phase18010" targetRef="gateway18010"/><bpmn:sequenceFlow id="flow31343" name="C2242 - Chiusura Ordine OK" sourceRef="gateway18010" targetRef="phase18012"/><bpmn:sequenceFlow id="flow31346" name="C1900 - Integrazione M2C" sourceRef="phase18012" targetRef="phase18013"/><bpmn:sequenceFlow id="flow31347" name="C1904 - In attesa esito M2C" sourceRef="phase18013" targetRef="phase18014"/><bpmn:sequenceFlow id="flow18014" sourceRef="phase18014" targetRef="gateway18014"/><bpmn:sequenceFlow id="flow31348" name="C1006 - OK Integrazione M2C" sourceRef="gateway18014" targetRef="phase18026"/><bpmn:sequenceFlow id="flowEnd18026" sourceRef="phase18026" targetRef="end18026"/><bpmn:sequenceFlow id="flow31349" name="C2551 - OK Intregrazione M2C - Fatture di Storno da emettere" sourceRef="gateway18014" targetRef="phase18026"/><bpmn:sequenceFlow id="flow31350" name="C2552 - Elaborazione bloccata nel M2C" sourceRef="gateway18014" targetRef="phase18015"/><bpmn:sequenceFlow id="flow31351" name="C2550 - case creato" sourceRef="phase18015" targetRef="phase18026"/><bpmn:sequenceFlow id="flow31344" name="C1899 - Errore CRM durante Chiusura Ordine" sourceRef="gateway18010" targetRef="phase18011"/><bpmn:sequenceFlow id="flow31345" name="C1616 - Risoluzione Errore" sourceRef="phase18011" targetRef="phase18012"/><bpmn:sequenceFlow id="flow31339" name="C1449 - KO controlli RCU + Data decorrenza" sourceRef="gateway18008" targetRef="phase18025"/><bpmn:sequenceFlow id="flow31340" name="C2549 - annullamento attivo" sourceRef="gateway18008" targetRef="phase18016"/><bpmn:sequenceFlow id="flow31352" name="C1019 - Inviata" sourceRef="phase18016" targetRef="phase18017"/><bpmn:sequenceFlow id="flow18017" sourceRef="phase18017" targetRef="gateway18017"/><bpmn:sequenceFlow id="flow31353" name="C2475 - OK - Ammissibilità Annullamento Hub" sourceRef="gateway18017" targetRef="phase20855"/><bpmn:sequenceFlow id="flow20855" sourceRef="phase20855" targetRef="gateway20855"/><bpmn:sequenceFlow id="flow37139" name="C3120 - annullamento da gestire" sourceRef="gateway20855" targetRef="phase20856"/><bpmn:sequenceFlow id="flow20856" sourceRef="phase20856" targetRef="gateway20856"/><bpmn:sequenceFlow id="flow31355" name="C3118 - KO AtoA/pdc" sourceRef="gateway20856" targetRef="phase18018"/><bpmn:sequenceFlow id="flow18018" sourceRef="phase18018" targetRef="gateway18018"/><bpmn:sequenceFlow id="flow31359" name="C2508 - gestione fuori linea" sourceRef="gateway18018" targetRef="phase18019"/><bpmn:sequenceFlow id="flow31364" name="C1019 - Inviata" sourceRef="phase18019" targetRef="phase18020"/><bpmn:sequenceFlow id="flow18020" sourceRef="phase18020" targetRef="gateway18020"/><bpmn:sequenceFlow id="flow31365" name="C2225 - KO - Ammissibilità Hub" sourceRef="gateway18020" targetRef="phase18022"/><bpmn:sequenceFlow id="flow18022" sourceRef="phase18022" targetRef="gateway18022"/><bpmn:sequenceFlow id="flow31372" name="C2416 - risottomessa da cruscotto" sourceRef="gateway18022" targetRef="phase18020"/><bpmn:sequenceFlow id="flow31373" name="C1931 - Errore non rilavorabile" sourceRef="gateway18022" targetRef="phase18008"/><bpmn:sequenceFlow id="flow31374" name="C1449 - KO controlli RCU + Data decorrenza" sourceRef="gateway18022" targetRef="phase18025"/><bpmn:sequenceFlow id="flow31375" name="C1448 - OK controlli RCU" sourceRef="gateway18022" targetRef="phase18009"/><bpmn:sequenceFlow id="flow31366" name="C2224 - OK - Ammissibilità Hub" sourceRef="gateway18020" targetRef="phase18023"/><bpmn:sequenceFlow id="flow18023" sourceRef="phase18023" targetRef="gateway18023"/><bpmn:sequenceFlow id="flow31376" name="C1037 - Ammissibilità OK" sourceRef="gateway18023" targetRef="phase18024"/><bpmn:sequenceFlow id="flow18024" sourceRef="phase18024" targetRef="gateway18024"/><bpmn:sequenceFlow id="flow31381" name="C1063 - Esito finale Annullamento OK" sourceRef="gateway18024" targetRef="phase18027"/><bpmn:sequenceFlow id="flowEnd18027" sourceRef="phase18027" targetRef="end18027"/><bpmn:sequenceFlow id="flow31382" name="C1064 - Esito finale Annullamento KO" sourceRef="gateway18024" targetRef="phase18008"/><bpmn:sequenceFlow id="flow31383" name="C1449 - KO controlli RCU + Data decorrenza" sourceRef="gateway18024" targetRef="phase18025"/><bpmn:sequenceFlow id="flow31384" name="C1448 - OK controlli RCU" sourceRef="gateway18024" targetRef="phase18009"/><bpmn:sequenceFlow id="flow31385" name="C1763 - Annullamento passivo dal SII" sourceRef="gateway18024" targetRef="phase18028"/><bpmn:sequenceFlow id="flow31377" name="C1038 - Ammissibilità KO" sourceRef="gateway18023" targetRef="phase18021"/><bpmn:sequenceFlow id="flow18021" sourceRef="phase18021" targetRef="gateway18021"/><bpmn:sequenceFlow id="flow31367" name="C2416 - risottomessa da cruscotto" sourceRef="gateway18021" targetRef="phase18017"/><bpmn:sequenceFlow id="flow31368" name="C1931 - Errore non rilavorabile" sourceRef="gateway18021" targetRef="phase18008"/><bpmn:sequenceFlow id="flow31369" name="C1449 - KO controlli RCU + Data decorrenza" sourceRef="gateway18021" targetRef="phase18025"/><bpmn:sequenceFlow id="flow31370" name="C1448 - OK controlli RCU" sourceRef="gateway18021" targetRef="phase18009"/><bpmn:sequenceFlow id="flow31371" name="C1763 - Annullamento passivo dal SII" sourceRef="gateway18021" targetRef="phase18028"/><bpmn:sequenceFlow id="flow31378" name="C1449 - KO controlli RCU + Data decorrenza" sourceRef="gateway18023" targetRef="phase18025"/><bpmn:sequenceFlow id="flow31379" name="C1448 - OK controlli RCU" sourceRef="gateway18023" targetRef="phase18009"/><bpmn:sequenceFlow id="flow31380" name="C1763 - Annullamento passivo dal SII" sourceRef="gateway18023" targetRef="phase18028"/><bpmn:sequenceFlow id="flow31360" name="C2509 - Da gestire nuovo invio automatico" sourceRef="gateway18018" targetRef="phase18016"/><bpmn:sequenceFlow id="flow31361" name="C1449 - KO controlli RCU + Data decorrenza" sourceRef="gateway18018" targetRef="phase18025"/><bpmn:sequenceFlow id="flow31362" name="C1448 - OK controlli RCU" sourceRef="gateway18018" targetRef="phase18009"/><bpmn:sequenceFlow id="flow31363" name="C1763 - Annullamento passivo dal SII" sourceRef="gateway18018" targetRef="phase18028"/><bpmn:sequenceFlow id="flow37141" name="C2875 - OK - Inviato Annullamento al SII" sourceRef="gateway20856" targetRef="phase18023"/><bpmn:sequenceFlow id="flow37140" name="C2599 - annullamento confermato" sourceRef="gateway20855" targetRef="phase18027"/><bpmn:sequenceFlow id="flow31354" name="C2476 - KO - Ammissibilità Annullamento Hub" sourceRef="gateway18017" targetRef="phase18021"/><bpmn:sequenceFlow id="flow31356" name="C1449 - KO controlli RCU + Data decorrenza" sourceRef="gateway18017" targetRef="phase18025"/><bpmn:sequenceFlow id="flow31357" name="C1448 - OK controlli RCU" sourceRef="gateway18017" targetRef="phase18009"/><bpmn:sequenceFlow id="flow31358" name="C1763 - Annullamento passivo dal SII" sourceRef="gateway18017" targetRef="phase18028"/><bpmn:sequenceFlow id="flow37138" name="C2599 - annullamento confermato" sourceRef="gateway18017" targetRef="phase18027"/><bpmn:sequenceFlow id="flow31341" name="C1763 - Annullamento passivo dal SII" sourceRef="gateway18008" targetRef="phase18028"/><bpmn:sequenceFlow id="flow31445" name="C2221 - Commodity Elettricità" sourceRef="gateway18099" targetRef="phase18100"/><bpmn:sequenceFlow id="flow31444" name="C1019 - Inviata" sourceRef="phase18100" targetRef="phase18008"/><bpmn:sequenceFlow id="flow31337" name="C1038 - Ammissibilità KO" sourceRef="gateway18007" targetRef="phase18002"/><bpmn:sequenceFlow id="flow31330" name="C2509 - Da gestire nuovo invio automatico" sourceRef="gateway18003" targetRef="phase18000"/><bpmn:sequenceFlow id="flow37137" name="C3117 - OK pratica inserita" sourceRef="gateway20854" targetRef="phase18007"/><bpmn:sequenceFlow id="flow31320" name="C1933 - Recupero Dati KO" sourceRef="gateway17998" targetRef="phase17999"/><bpmn:sequenceFlow id="flow31321" name="C1616 - Risoluzione Errore" sourceRef="phase17999" targetRef="phase17998"/><bpmn:sequenceFlow id="flow31316" name="C2639 - Incompatibilità Non bloccante" sourceRef="gateway17996" targetRef="phase17998"/><bpmn:sequenceFlow id="flow31429" name="C2252 - Apertura Case Automatica" sourceRef="gateway18083" targetRef="phase18098"/><bpmn:sequenceFlow id="flow31442" name="C1401 - Risoluzione contrattuale OK" sourceRef="phase18098" targetRef="phase17996"/><bpmn:exclusiveGateway id="gateway18083"/><bpmn:exclusiveGateway id="gateway17995"/><bpmn:exclusiveGateway id="gateway17996"/><bpmn:exclusiveGateway id="gateway17997"/><bpmn:exclusiveGateway id="gateway17998"/><bpmn:exclusiveGateway id="gateway18001"/><bpmn:exclusiveGateway id="gateway18002"/><bpmn:exclusiveGateway id="gateway20854"/><bpmn:exclusiveGateway id="gateway18003"/><bpmn:exclusiveGateway id="gateway18005"/><bpmn:exclusiveGateway id="gateway18006"/><bpmn:exclusiveGateway id="gateway18007"/><bpmn:exclusiveGateway id="gateway18099"/><bpmn:exclusiveGateway id="gateway18008"/><bpmn:exclusiveGateway id="gateway18010"/><bpmn:exclusiveGateway id="gateway18014"/><bpmn:exclusiveGateway id="gateway18017"/><bpmn:exclusiveGateway id="gateway20855"/><bpmn:exclusiveGateway id="gateway20856"/><bpmn:exclusiveGateway id="gateway18018"/><bpmn:exclusiveGateway id="gateway18020"/><bpmn:exclusiveGateway id="gateway18022"/><bpmn:exclusiveGateway id="gateway18023"/><bpmn:exclusiveGateway id="gateway18024"/><bpmn:exclusiveGateway id="gateway18021"/><bpmn:endEvent id="end18025"/><bpmn:endEvent id="end18029"/><bpmn:endEvent id="end18028"/><bpmn:endEvent id="end18026"/><bpmn:endEvent id="end18027"/></bpmn:process><bpmndi:BPMNDiagram id="BPMNDiagram_1">
3342
- <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="process_458"><bpmndi:BPMNShape id="start_di" bpmnElement="start" ><dc:Bounds x="150" y="-18.0" width="36" height="36"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18083_di" bpmnElement="phase18083" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="286" y="-40.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18083_di" bpmnElement="gateway18083" isMarkerVisible="true"><dc:Bounds x="496" y="-25.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase17995_di" bpmnElement="phase17995" bioc:stroke="#0d4372" bioc:fill="#bbdefb" color:background-color="#bbdefb" color:border-color="#0d4372"><dc:Bounds x="646" y="-40.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway17995_di" bpmnElement="gateway17995" isMarkerVisible="true"><dc:Bounds x="856" y="-25.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18025_di" bpmnElement="phase18025" bioc:stroke="#6b3c00" bioc:fill="#ffe0b2" color:background-color="#ffe0b2" color:border-color="#6b3c00"><dc:Bounds x="1006" y="-40.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="end18025_di" bpmnElement="end18025" bioc:stroke="#6b3c00" bioc:fill="#ffe0b2" color:background-color="#ffe0b2" color:border-color="#6b3c00"><dc:Bounds x="1216" y="-18.0" width="36" height="36"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase17996_di" bpmnElement="phase17996" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="1006" y="110.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway17996_di" bpmnElement="gateway17996" isMarkerVisible="true"><dc:Bounds x="1216" y="125.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase17997_di" bpmnElement="phase17997" ><dc:Bounds x="1366" y="110.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway17997_di" bpmnElement="gateway17997" isMarkerVisible="true"><dc:Bounds x="1576" y="125.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18029_di" bpmnElement="phase18029" bioc:stroke="#831311" bioc:fill="#ffcdd2" color:background-color="#ffcdd2" color:border-color="#831311"><dc:Bounds x="1726" y="110.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="end18029_di" bpmnElement="end18029" bioc:stroke="#831311" bioc:fill="#ffcdd2" color:background-color="#ffcdd2" color:border-color="#831311"><dc:Bounds x="1936" y="132.0" width="36" height="36"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase17998_di" bpmnElement="phase17998" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="1366" y="260.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway17998_di" bpmnElement="gateway17998" isMarkerVisible="true"><dc:Bounds x="1576" y="275.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18000_di" bpmnElement="phase18000" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="1726" y="260.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18001_di" bpmnElement="phase18001" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="1936" y="260.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18001_di" bpmnElement="gateway18001" isMarkerVisible="true"><dc:Bounds x="2146" y="275.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18002_di" bpmnElement="phase18002" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="2296" y="260.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18002_di" bpmnElement="gateway18002" isMarkerVisible="true"><dc:Bounds x="2506" y="275.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18028_di" bpmnElement="phase18028" bioc:stroke="#6b3c00" bioc:fill="#ffe0b2" color:background-color="#ffe0b2" color:border-color="#6b3c00"><dc:Bounds x="2656" y="410.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="end18028_di" bpmnElement="end18028" bioc:stroke="#6b3c00" bioc:fill="#ffe0b2" color:background-color="#ffe0b2" color:border-color="#6b3c00"><dc:Bounds x="2866" y="432.0" width="36" height="36"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase20854_di" bpmnElement="phase20854" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="2296" y="560.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway20854_di" bpmnElement="gateway20854" isMarkerVisible="true"><dc:Bounds x="2506" y="575.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18003_di" bpmnElement="phase18003" ><dc:Bounds x="2656" y="560.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18003_di" bpmnElement="gateway18003" isMarkerVisible="true"><dc:Bounds x="2866" y="575.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18004_di" bpmnElement="phase18004" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="3016" y="560.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18005_di" bpmnElement="phase18005" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="3226" y="560.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18005_di" bpmnElement="gateway18005" isMarkerVisible="true"><dc:Bounds x="3436" y="575.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18006_di" bpmnElement="phase18006" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="3586" y="560.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18006_di" bpmnElement="gateway18006" isMarkerVisible="true"><dc:Bounds x="3796" y="575.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18007_di" bpmnElement="phase18007" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="3586" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18007_di" bpmnElement="gateway18007" isMarkerVisible="true"><dc:Bounds x="3796" y="725.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18099_di" bpmnElement="phase18099" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="3946" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18099_di" bpmnElement="gateway18099" isMarkerVisible="true"><dc:Bounds x="4156" y="725.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18008_di" bpmnElement="phase18008" bioc:stroke="#0d4372" bioc:fill="#bbdefb" color:background-color="#bbdefb" color:border-color="#0d4372"><dc:Bounds x="4306" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18008_di" bpmnElement="gateway18008" isMarkerVisible="true"><dc:Bounds x="4516" y="725.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18009_di" bpmnElement="phase18009" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="4666" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18010_di" bpmnElement="phase18010" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="4876" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18010_di" bpmnElement="gateway18010" isMarkerVisible="true"><dc:Bounds x="5086" y="725.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18012_di" bpmnElement="phase18012" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="5236" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18013_di" bpmnElement="phase18013" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="5446" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18014_di" bpmnElement="phase18014" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="5656" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18014_di" bpmnElement="gateway18014" isMarkerVisible="true"><dc:Bounds x="5866" y="725.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18026_di" bpmnElement="phase18026" bioc:stroke="#205022" bioc:fill="#c8e6c9" color:background-color="#c8e6c9" color:border-color="#205022"><dc:Bounds x="6016" y="710.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="end18026_di" bpmnElement="end18026" bioc:stroke="#205022" bioc:fill="#c8e6c9" color:background-color="#c8e6c9" color:border-color="#205022"><dc:Bounds x="6226" y="732.0" width="36" height="36"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18015_di" bpmnElement="phase18015" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="6016" y="860.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18011_di" bpmnElement="phase18011" ><dc:Bounds x="5236" y="1010.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18016_di" bpmnElement="phase18016" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="4666" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18017_di" bpmnElement="phase18017" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="4876" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18017_di" bpmnElement="gateway18017" isMarkerVisible="true"><dc:Bounds x="5086" y="1175.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase20855_di" bpmnElement="phase20855" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="5236" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway20855_di" bpmnElement="gateway20855" isMarkerVisible="true"><dc:Bounds x="5446" y="1175.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase20856_di" bpmnElement="phase20856" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="5596" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway20856_di" bpmnElement="gateway20856" isMarkerVisible="true"><dc:Bounds x="5806" y="1175.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18018_di" bpmnElement="phase18018" ><dc:Bounds x="5956" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18018_di" bpmnElement="gateway18018" isMarkerVisible="true"><dc:Bounds x="6166" y="1175.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18019_di" bpmnElement="phase18019" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="6316" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18020_di" bpmnElement="phase18020" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="6526" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18020_di" bpmnElement="gateway18020" isMarkerVisible="true"><dc:Bounds x="6736" y="1175.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18022_di" bpmnElement="phase18022" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="6886" y="1160.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18022_di" bpmnElement="gateway18022" isMarkerVisible="true"><dc:Bounds x="7096" y="1175.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18023_di" bpmnElement="phase18023" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="6886" y="1310.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18023_di" bpmnElement="gateway18023" isMarkerVisible="true"><dc:Bounds x="7096" y="1325.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18024_di" bpmnElement="phase18024" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="7246" y="1310.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18024_di" bpmnElement="gateway18024" isMarkerVisible="true"><dc:Bounds x="7456" y="1325.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18027_di" bpmnElement="phase18027" bioc:stroke="#6b3c00" bioc:fill="#ffe0b2" color:background-color="#ffe0b2" color:border-color="#6b3c00"><dc:Bounds x="7606" y="1310.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="end18027_di" bpmnElement="end18027" bioc:stroke="#6b3c00" bioc:fill="#ffe0b2" color:background-color="#ffe0b2" color:border-color="#6b3c00"><dc:Bounds x="7816" y="1332.0" width="36" height="36"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18021_di" bpmnElement="phase18021" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="7246" y="1460.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="gateway18021_di" bpmnElement="gateway18021" isMarkerVisible="true"><dc:Bounds x="7456" y="1475.0" width="50" height="50"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18100_di" bpmnElement="phase18100" ><dc:Bounds x="4306" y="1610.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase17999_di" bpmnElement="phase17999" ><dc:Bounds x="1726" y="1760.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNShape id="phase18098_di" bpmnElement="phase18098" bioc:stroke="#5b176d" bioc:fill="#e1bee7" color:background-color="#e1bee7" color:border-color="#5b176d"><dc:Bounds x="646" y="1910.0" width="110" height="80"/></bpmndi:BPMNShape><bpmndi:BPMNEdge id="flowStart_di" bpmnElement="flowStart"><di:waypoint x="186" y="0.0" /><di:waypoint x="286" y="0.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18083_di" bpmnElement="flow18083"><di:waypoint x="396" y="0.0" /><di:waypoint x="496" y="0.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31428_di" bpmnElement="flow31428"><di:waypoint x="546" y="0.0" /><di:waypoint x="646" y="0.0" /><bpmndi:BPMNLabel><dc:Bounds x="546" y="5.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow17995_di" bpmnElement="flow17995"><di:waypoint x="756" y="0.0" /><di:waypoint x="856" y="0.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31312_di" bpmnElement="flow31312"><di:waypoint x="906" y="0.0" /><di:waypoint x="1006" y="0.0" /><bpmndi:BPMNLabel><dc:Bounds x="906" y="5.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flowEnd18025_di" bpmnElement="flowEnd18025"><di:waypoint x="1116" y="0.0" /><di:waypoint x="1216" y="0.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31313_di" bpmnElement="flow31313"><di:waypoint x="881.0" y="25.0" /><di:waypoint x="881.0" y="150.0" /><di:waypoint x="1006" y="150.0" /><bpmndi:BPMNLabel><dc:Bounds x="881.0" y="155.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow17996_di" bpmnElement="flow17996"><di:waypoint x="1116" y="150.0" /><di:waypoint x="1216" y="150.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31314_di" bpmnElement="flow31314"><di:waypoint x="1266" y="150.0" /><di:waypoint x="1366" y="150.0" /><bpmndi:BPMNLabel><dc:Bounds x="1266" y="155.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow17997_di" bpmnElement="flow17997"><di:waypoint x="1476" y="150.0" /><di:waypoint x="1576" y="150.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31317_di" bpmnElement="flow31317"><di:waypoint x="1626" y="150.0" /><di:waypoint x="1726" y="150.0" /><bpmndi:BPMNLabel><dc:Bounds x="1626" y="155.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flowEnd18029_di" bpmnElement="flowEnd18029"><di:waypoint x="1836" y="150.0" /><di:waypoint x="1936" y="150.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31318_di" bpmnElement="flow31318" bioc:stroke="#2a25a4" color:border-color="#2a25a4"><di:waypoint x="1601.0" y="175.0" /><di:waypoint x="1601.0" y="229.0" /><di:waypoint x="976" y="229.0" /><di:waypoint x="976" y="150.01" /><bpmndi:BPMNLabel><dc:Bounds x="1601.0" y="180.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31315_di" bpmnElement="flow31315"><di:waypoint x="1241.0" y="175.0" /><di:waypoint x="1241.0" y="300.0" /><di:waypoint x="1366" y="300.0" /><bpmndi:BPMNLabel><dc:Bounds x="1241.0" y="305.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow17998_di" bpmnElement="flow17998"><di:waypoint x="1476" y="300.0" /><di:waypoint x="1576" y="300.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31319_di" bpmnElement="flow31319"><di:waypoint x="1626" y="300.0" /><di:waypoint x="1726" y="300.0" /><bpmndi:BPMNLabel><dc:Bounds x="1626" y="305.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31322_di" bpmnElement="flow31322"><di:waypoint x="1836" y="300.0" /><di:waypoint x="1936" y="300.0" /><bpmndi:BPMNLabel><dc:Bounds x="1836" y="305.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18001_di" bpmnElement="flow18001"><di:waypoint x="2046" y="300.0" /><di:waypoint x="2146" y="300.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31323_di" bpmnElement="flow31323"><di:waypoint x="2196" y="300.0" /><di:waypoint x="2296" y="300.0" /><bpmndi:BPMNLabel><dc:Bounds x="2196" y="305.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18002_di" bpmnElement="flow18002"><di:waypoint x="2406" y="300.0" /><di:waypoint x="2506" y="300.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31326_di" bpmnElement="flow31326" bioc:stroke="#0194b5" color:border-color="#0194b5"><di:waypoint x="2531.0" y="325.0" /><di:waypoint x="2531.0" y="383.0" /><di:waypoint x="1906" y="383.0" /><di:waypoint x="1906" y="300.01" /><bpmndi:BPMNLabel><dc:Bounds x="2531.0" y="330.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31327_di" bpmnElement="flow31327" bioc:stroke="#b3f345" color:border-color="#b3f345"><di:waypoint x="2531.0" y="325.0" /><di:waypoint x="2531.0" y="383.0" /><di:waypoint x="1696" y="383.0" /><di:waypoint x="1696" y="150.01" /><bpmndi:BPMNLabel><dc:Bounds x="1696" y="383.0" width="31" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31328_di" bpmnElement="flow31328"><di:waypoint x="2531.0" y="325.0" /><di:waypoint x="2531.0" y="450.0" /><di:waypoint x="2656" y="450.0" /><bpmndi:BPMNLabel><dc:Bounds x="2531.0" y="455.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flowEnd18028_di" bpmnElement="flowEnd18028"><di:waypoint x="2766" y="450.0" /><di:waypoint x="2866" y="450.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31324_di" bpmnElement="flow31324"><di:waypoint x="2171.0" y="325.0" /><di:waypoint x="2171.0" y="600.0" /><di:waypoint x="2296" y="600.0" /><bpmndi:BPMNLabel><dc:Bounds x="2171.0" y="605.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow20854_di" bpmnElement="flow20854"><di:waypoint x="2406" y="600.0" /><di:waypoint x="2506" y="600.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31325_di" bpmnElement="flow31325"><di:waypoint x="2556" y="600.0" /><di:waypoint x="2656" y="600.0" /><bpmndi:BPMNLabel><dc:Bounds x="2556" y="605.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18003_di" bpmnElement="flow18003"><di:waypoint x="2766" y="600.0" /><di:waypoint x="2866" y="600.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31329_di" bpmnElement="flow31329"><di:waypoint x="2916" y="600.0" /><di:waypoint x="3016" y="600.0" /><bpmndi:BPMNLabel><dc:Bounds x="2916" y="605.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31331_di" bpmnElement="flow31331"><di:waypoint x="3126" y="600.0" /><di:waypoint x="3226" y="600.0" /><bpmndi:BPMNLabel><dc:Bounds x="3126" y="605.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18005_di" bpmnElement="flow18005"><di:waypoint x="3336" y="600.0" /><di:waypoint x="3436" y="600.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31332_di" bpmnElement="flow31332"><di:waypoint x="3486" y="600.0" /><di:waypoint x="3586" y="600.0" /><bpmndi:BPMNLabel><dc:Bounds x="3486" y="605.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18006_di" bpmnElement="flow18006"><di:waypoint x="3696" y="600.0" /><di:waypoint x="3796" y="600.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31334_di" bpmnElement="flow31334" bioc:stroke="#7a1a12" color:border-color="#7a1a12"><di:waypoint x="3821.0" y="625.0" /><di:waypoint x="3821.0" y="691.0" /><di:waypoint x="3196" y="691.0" /><di:waypoint x="3196" y="600.01" /><bpmndi:BPMNLabel><dc:Bounds x="3821.0" y="630.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31335_di" bpmnElement="flow31335" bioc:stroke="#4ee1ec" color:border-color="#4ee1ec"><di:waypoint x="3821.0" y="625.0" /><di:waypoint x="3821.0" y="691.0" /><di:waypoint x="1696" y="691.0" /><di:waypoint x="1696" y="150.01" /><bpmndi:BPMNLabel><dc:Bounds x="1696" y="691.0" width="31" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31333_di" bpmnElement="flow31333"><di:waypoint x="3461.0" y="625.0" /><di:waypoint x="3461.0" y="750.0" /><di:waypoint x="3586" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="3461.0" y="755.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18007_di" bpmnElement="flow18007"><di:waypoint x="3696" y="750.0" /><di:waypoint x="3796" y="750.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31336_di" bpmnElement="flow31336"><di:waypoint x="3846" y="750.0" /><di:waypoint x="3946" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="3846" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18099_di" bpmnElement="flow18099"><di:waypoint x="4056" y="750.0" /><di:waypoint x="4156" y="750.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31443_di" bpmnElement="flow31443"><di:waypoint x="4206" y="750.0" /><di:waypoint x="4306" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="4206" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18008_di" bpmnElement="flow18008"><di:waypoint x="4416" y="750.0" /><di:waypoint x="4516" y="750.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31338_di" bpmnElement="flow31338"><di:waypoint x="4566" y="750.0" /><di:waypoint x="4666" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="4566" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31342_di" bpmnElement="flow31342"><di:waypoint x="4776" y="750.0" /><di:waypoint x="4876" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="4776" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18010_di" bpmnElement="flow18010"><di:waypoint x="4986" y="750.0" /><di:waypoint x="5086" y="750.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31343_di" bpmnElement="flow31343"><di:waypoint x="5136" y="750.0" /><di:waypoint x="5236" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="5136" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31346_di" bpmnElement="flow31346"><di:waypoint x="5346" y="750.0" /><di:waypoint x="5446" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="5346" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31347_di" bpmnElement="flow31347"><di:waypoint x="5556" y="750.0" /><di:waypoint x="5656" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="5556" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18014_di" bpmnElement="flow18014"><di:waypoint x="5766" y="750.0" /><di:waypoint x="5866" y="750.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31348_di" bpmnElement="flow31348"><di:waypoint x="5916" y="750.0" /><di:waypoint x="6016" y="750.0" /><bpmndi:BPMNLabel><dc:Bounds x="5916" y="755.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flowEnd18026_di" bpmnElement="flowEnd18026"><di:waypoint x="6126" y="750.0" /><di:waypoint x="6226" y="750.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31349_di" bpmnElement="flow31349" bioc:stroke="#c365c0" color:border-color="#c365c0"><di:waypoint x="5891.0" y="775.0" /><di:waypoint x="5891.0" y="845.0" /><di:waypoint x="5986" y="845.0" /><di:waypoint x="5986" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="5891.0" y="780.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31350_di" bpmnElement="flow31350"><di:waypoint x="5891.0" y="775.0" /><di:waypoint x="5891.0" y="900.0" /><di:waypoint x="6016" y="900.0" /><bpmndi:BPMNLabel><dc:Bounds x="5891.0" y="905.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31351_di" bpmnElement="flow31351" bioc:stroke="#288096" color:border-color="#288096"><di:waypoint x="6071.0" y="940.0" /><di:waypoint x="6071.0" y="1014.0" /><di:waypoint x="5986" y="1014.0" /><di:waypoint x="5986" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="6071.0" y="945.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31344_di" bpmnElement="flow31344"><di:waypoint x="5111.0" y="775.0" /><di:waypoint x="5111.0" y="1050.0" /><di:waypoint x="5236" y="1050.0" /><bpmndi:BPMNLabel><dc:Bounds x="5111.0" y="1055.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31345_di" bpmnElement="flow31345" bioc:stroke="#28135a" color:border-color="#28135a"><di:waypoint x="5291.0" y="1090.0" /><di:waypoint x="5291.0" y="1168.0" /><di:waypoint x="5206" y="1168.0" /><di:waypoint x="5206" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="5291.0" y="1095.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31339_di" bpmnElement="flow31339" bioc:stroke="#2dd981" color:border-color="#2dd981"><di:waypoint x="4541.0" y="775.0" /><di:waypoint x="4541.0" y="853.0" /><di:waypoint x="976" y="853.0" /><di:waypoint x="976" y="0.01" /><bpmndi:BPMNLabel><dc:Bounds x="4541.0" y="780.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31340_di" bpmnElement="flow31340"><di:waypoint x="4541.0" y="775.0" /><di:waypoint x="4541.0" y="1200.0" /><di:waypoint x="4666" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="4541.0" y="1205.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31352_di" bpmnElement="flow31352"><di:waypoint x="4776" y="1200.0" /><di:waypoint x="4876" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="4776" y="1205.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18017_di" bpmnElement="flow18017"><di:waypoint x="4986" y="1200.0" /><di:waypoint x="5086" y="1200.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31353_di" bpmnElement="flow31353"><di:waypoint x="5136" y="1200.0" /><di:waypoint x="5236" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="5136" y="1205.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow20855_di" bpmnElement="flow20855"><di:waypoint x="5346" y="1200.0" /><di:waypoint x="5446" y="1200.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow37139_di" bpmnElement="flow37139"><di:waypoint x="5496" y="1200.0" /><di:waypoint x="5596" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="5496" y="1205.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow20856_di" bpmnElement="flow20856"><di:waypoint x="5706" y="1200.0" /><di:waypoint x="5806" y="1200.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31355_di" bpmnElement="flow31355"><di:waypoint x="5856" y="1200.0" /><di:waypoint x="5956" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="5856" y="1205.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18018_di" bpmnElement="flow18018"><di:waypoint x="6066" y="1200.0" /><di:waypoint x="6166" y="1200.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31359_di" bpmnElement="flow31359"><di:waypoint x="6216" y="1200.0" /><di:waypoint x="6316" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="6216" y="1205.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31364_di" bpmnElement="flow31364"><di:waypoint x="6426" y="1200.0" /><di:waypoint x="6526" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="6426" y="1205.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18020_di" bpmnElement="flow18020"><di:waypoint x="6636" y="1200.0" /><di:waypoint x="6736" y="1200.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31365_di" bpmnElement="flow31365"><di:waypoint x="6786" y="1200.0" /><di:waypoint x="6886" y="1200.0" /><bpmndi:BPMNLabel><dc:Bounds x="6786" y="1205.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18022_di" bpmnElement="flow18022"><di:waypoint x="6996" y="1200.0" /><di:waypoint x="7096" y="1200.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31372_di" bpmnElement="flow31372" bioc:stroke="#cac043" color:border-color="#cac043"><di:waypoint x="7121.0" y="1225.0" /><di:waypoint x="7121.0" y="1307.0" /><di:waypoint x="6496" y="1307.0" /><di:waypoint x="6496" y="1200.01" /><bpmndi:BPMNLabel><dc:Bounds x="7121.0" y="1230.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31373_di" bpmnElement="flow31373" bioc:stroke="#b9de0e" color:border-color="#b9de0e"><di:waypoint x="7121.0" y="1225.0" /><di:waypoint x="7121.0" y="1307.0" /><di:waypoint x="4276" y="1307.0" /><di:waypoint x="4276" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4276" y="1307.0" width="31" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31374_di" bpmnElement="flow31374" bioc:stroke="#e3fd5f" color:border-color="#e3fd5f"><di:waypoint x="7121.0" y="1225.0" /><di:waypoint x="7121.0" y="1307.0" /><di:waypoint x="976" y="1307.0" /><di:waypoint x="976" y="0.01" /><bpmndi:BPMNLabel><dc:Bounds x="976" y="1307.0" width="42" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31375_di" bpmnElement="flow31375" bioc:stroke="#3d5885" color:border-color="#3d5885"><di:waypoint x="7121.0" y="1225.0" /><di:waypoint x="7121.0" y="1307.0" /><di:waypoint x="4636" y="1307.0" /><di:waypoint x="4636" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4636" y="1307.0" width="24" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31366_di" bpmnElement="flow31366"><di:waypoint x="6761.0" y="1225.0" /><di:waypoint x="6761.0" y="1350.0" /><di:waypoint x="6886" y="1350.0" /><bpmndi:BPMNLabel><dc:Bounds x="6761.0" y="1355.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18023_di" bpmnElement="flow18023"><di:waypoint x="6996" y="1350.0" /><di:waypoint x="7096" y="1350.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31376_di" bpmnElement="flow31376"><di:waypoint x="7146" y="1350.0" /><di:waypoint x="7246" y="1350.0" /><bpmndi:BPMNLabel><dc:Bounds x="7146" y="1355.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18024_di" bpmnElement="flow18024"><di:waypoint x="7356" y="1350.0" /><di:waypoint x="7456" y="1350.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31381_di" bpmnElement="flow31381"><di:waypoint x="7506" y="1350.0" /><di:waypoint x="7606" y="1350.0" /><bpmndi:BPMNLabel><dc:Bounds x="7506" y="1355.0" width="100" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flowEnd18027_di" bpmnElement="flowEnd18027"><di:waypoint x="7716" y="1350.0" /><di:waypoint x="7816" y="1350.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31382_di" bpmnElement="flow31382" bioc:stroke="#510201" color:border-color="#510201"><di:waypoint x="7481.0" y="1375.0" /><di:waypoint x="7481.0" y="1461.0" /><di:waypoint x="4276" y="1461.0" /><di:waypoint x="4276" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="7481.0" y="1380.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31383_di" bpmnElement="flow31383" bioc:stroke="#1006f4" color:border-color="#1006f4"><di:waypoint x="7481.0" y="1375.0" /><di:waypoint x="7481.0" y="1461.0" /><di:waypoint x="976" y="1461.0" /><di:waypoint x="976" y="0.01" /><bpmndi:BPMNLabel><dc:Bounds x="976" y="1461.0" width="42" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31384_di" bpmnElement="flow31384" bioc:stroke="#6b96da" color:border-color="#6b96da"><di:waypoint x="7481.0" y="1375.0" /><di:waypoint x="7481.0" y="1461.0" /><di:waypoint x="4636" y="1461.0" /><di:waypoint x="4636" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4636" y="1461.0" width="24" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31385_di" bpmnElement="flow31385" bioc:stroke="#94a66d" color:border-color="#94a66d"><di:waypoint x="7481.0" y="1375.0" /><di:waypoint x="7481.0" y="1461.0" /><di:waypoint x="2626" y="1461.0" /><di:waypoint x="2626" y="450.01" /><bpmndi:BPMNLabel><dc:Bounds x="2626" y="1461.0" width="36" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31377_di" bpmnElement="flow31377"><di:waypoint x="7121.0" y="1375.0" /><di:waypoint x="7121.0" y="1500.0" /><di:waypoint x="7246" y="1500.0" /><bpmndi:BPMNLabel><dc:Bounds x="7121.0" y="1505.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow18021_di" bpmnElement="flow18021"><di:waypoint x="7356" y="1500.0" /><di:waypoint x="7456" y="1500.0" /></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31367_di" bpmnElement="flow31367" bioc:stroke="#99ddeb" color:border-color="#99ddeb"><di:waypoint x="7481.0" y="1525.0" /><di:waypoint x="7481.0" y="1615.0" /><di:waypoint x="4846" y="1615.0" /><di:waypoint x="4846" y="1200.01" /><bpmndi:BPMNLabel><dc:Bounds x="7481.0" y="1530.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31368_di" bpmnElement="flow31368" bioc:stroke="#6e37f9" color:border-color="#6e37f9"><di:waypoint x="7481.0" y="1525.0" /><di:waypoint x="7481.0" y="1615.0" /><di:waypoint x="4276" y="1615.0" /><di:waypoint x="4276" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4276" y="1615.0" width="31" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31369_di" bpmnElement="flow31369" bioc:stroke="#56defc" color:border-color="#56defc"><di:waypoint x="7481.0" y="1525.0" /><di:waypoint x="7481.0" y="1615.0" /><di:waypoint x="976" y="1615.0" /><di:waypoint x="976" y="0.01" /><bpmndi:BPMNLabel><dc:Bounds x="976" y="1615.0" width="42" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31370_di" bpmnElement="flow31370" bioc:stroke="#9a3cae" color:border-color="#9a3cae"><di:waypoint x="7481.0" y="1525.0" /><di:waypoint x="7481.0" y="1615.0" /><di:waypoint x="4636" y="1615.0" /><di:waypoint x="4636" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4636" y="1615.0" width="24" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31371_di" bpmnElement="flow31371" bioc:stroke="#132fae" color:border-color="#132fae"><di:waypoint x="7481.0" y="1525.0" /><di:waypoint x="7481.0" y="1615.0" /><di:waypoint x="2626" y="1615.0" /><di:waypoint x="2626" y="450.01" /><bpmndi:BPMNLabel><dc:Bounds x="2626" y="1615.0" width="36" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31378_di" bpmnElement="flow31378" bioc:stroke="#e055c0" color:border-color="#e055c0"><di:waypoint x="7121.0" y="1375.0" /><di:waypoint x="7121.0" y="1465.0" /><di:waypoint x="976" y="1465.0" /><di:waypoint x="976" y="0.01" /><bpmndi:BPMNLabel><dc:Bounds x="7121.0" y="1380.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31379_di" bpmnElement="flow31379" bioc:stroke="#aa7f6e" color:border-color="#aa7f6e"><di:waypoint x="7121.0" y="1375.0" /><di:waypoint x="7121.0" y="1465.0" /><di:waypoint x="4636" y="1465.0" /><di:waypoint x="4636" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4636" y="1465.0" width="24" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31380_di" bpmnElement="flow31380" bioc:stroke="#161cf9" color:border-color="#161cf9"><di:waypoint x="7121.0" y="1375.0" /><di:waypoint x="7121.0" y="1465.0" /><di:waypoint x="2626" y="1465.0" /><di:waypoint x="2626" y="450.01" /><bpmndi:BPMNLabel><dc:Bounds x="2626" y="1465.0" width="36" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31360_di" bpmnElement="flow31360" bioc:stroke="#93a8d9" color:border-color="#93a8d9"><di:waypoint x="6191.0" y="1225.0" /><di:waypoint x="6191.0" y="1315.0" /><di:waypoint x="4636" y="1315.0" /><di:waypoint x="4636" y="1200.01" /><bpmndi:BPMNLabel><dc:Bounds x="6191.0" y="1230.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31361_di" bpmnElement="flow31361" bioc:stroke="#ef091b" color:border-color="#ef091b"><di:waypoint x="6191.0" y="1225.0" /><di:waypoint x="6191.0" y="1315.0" /><di:waypoint x="976" y="1315.0" /><di:waypoint x="976" y="0.01" /><bpmndi:BPMNLabel><dc:Bounds x="976" y="1315.0" width="42" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31362_di" bpmnElement="flow31362" bioc:stroke="#4a32de" color:border-color="#4a32de"><di:waypoint x="6191.0" y="1225.0" /><di:waypoint x="6191.0" y="1315.0" /><di:waypoint x="4636" y="1315.0" /><di:waypoint x="4636" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4636" y="1315.0" width="24" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31363_di" bpmnElement="flow31363" bioc:stroke="#ab0726" color:border-color="#ab0726"><di:waypoint x="6191.0" y="1225.0" /><di:waypoint x="6191.0" y="1315.0" /><di:waypoint x="2626" y="1315.0" /><di:waypoint x="2626" y="450.01" /><bpmndi:BPMNLabel><dc:Bounds x="2626" y="1315.0" width="36" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow37141_di" bpmnElement="flow37141" bioc:stroke="#3d6859" color:border-color="#3d6859"><di:waypoint x="5831.0" y="1225.0" /><di:waypoint x="5831.0" y="1315.0" /><di:waypoint x="6856" y="1315.0" /><di:waypoint x="6856" y="1350.01" /><bpmndi:BPMNLabel><dc:Bounds x="5831.0" y="1230.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow37140_di" bpmnElement="flow37140" bioc:stroke="#d83824" color:border-color="#d83824"><di:waypoint x="5471.0" y="1225.0" /><di:waypoint x="5471.0" y="1315.0" /><di:waypoint x="7576" y="1315.0" /><di:waypoint x="7576" y="1350.01" /><bpmndi:BPMNLabel><dc:Bounds x="5471.0" y="1230.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31354_di" bpmnElement="flow31354" bioc:stroke="#ee49e5" color:border-color="#ee49e5"><di:waypoint x="5111.0" y="1225.0" /><di:waypoint x="5111.0" y="1315.0" /><di:waypoint x="7216" y="1315.0" /><di:waypoint x="7216" y="1500.01" /><bpmndi:BPMNLabel><dc:Bounds x="5111.0" y="1230.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31356_di" bpmnElement="flow31356" bioc:stroke="#cf7e9d" color:border-color="#cf7e9d"><di:waypoint x="5111.0" y="1225.0" /><di:waypoint x="5111.0" y="1315.0" /><di:waypoint x="976" y="1315.0" /><di:waypoint x="976" y="0.01" /><bpmndi:BPMNLabel><dc:Bounds x="976" y="1315.0" width="42" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31357_di" bpmnElement="flow31357" bioc:stroke="#388f9f" color:border-color="#388f9f"><di:waypoint x="5111.0" y="1225.0" /><di:waypoint x="5111.0" y="1315.0" /><di:waypoint x="4636" y="1315.0" /><di:waypoint x="4636" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4636" y="1315.0" width="24" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31358_di" bpmnElement="flow31358" bioc:stroke="#1391b5" color:border-color="#1391b5"><di:waypoint x="5111.0" y="1225.0" /><di:waypoint x="5111.0" y="1315.0" /><di:waypoint x="2626" y="1315.0" /><di:waypoint x="2626" y="450.01" /><bpmndi:BPMNLabel><dc:Bounds x="2626" y="1315.0" width="36" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow37138_di" bpmnElement="flow37138" bioc:stroke="#cb6aba" color:border-color="#cb6aba"><di:waypoint x="5111.0" y="1225.0" /><di:waypoint x="5111.0" y="1315.0" /><di:waypoint x="7576" y="1315.0" /><di:waypoint x="7576" y="1350.01" /><bpmndi:BPMNLabel><dc:Bounds x="7576" y="1315.0" width="31" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31341_di" bpmnElement="flow31341" bioc:stroke="#359707" color:border-color="#359707"><di:waypoint x="4541.0" y="775.0" /><di:waypoint x="4541.0" y="865.0" /><di:waypoint x="2626" y="865.0" /><di:waypoint x="2626" y="450.01" /><bpmndi:BPMNLabel><dc:Bounds x="2626" y="865.0" width="36" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31445_di" bpmnElement="flow31445"><di:waypoint x="4181.0" y="775.0" /><di:waypoint x="4181.0" y="1650.0" /><di:waypoint x="4306" y="1650.0" /><bpmndi:BPMNLabel><dc:Bounds x="4181.0" y="1655.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31444_di" bpmnElement="flow31444" bioc:stroke="#8f0608" color:border-color="#8f0608"><di:waypoint x="4361.0" y="1690.0" /><di:waypoint x="4361.0" y="1784.0" /><di:waypoint x="4276" y="1784.0" /><di:waypoint x="4276" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="4361.0" y="1695.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31337_di" bpmnElement="flow31337" bioc:stroke="#c5eb56" color:border-color="#c5eb56"><di:waypoint x="3821.0" y="775.0" /><di:waypoint x="3821.0" y="869.0" /><di:waypoint x="2266" y="869.0" /><di:waypoint x="2266" y="300.01" /><bpmndi:BPMNLabel><dc:Bounds x="3821.0" y="780.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31330_di" bpmnElement="flow31330" bioc:stroke="#edbdfb" color:border-color="#edbdfb"><di:waypoint x="2891.0" y="625.0" /><di:waypoint x="2891.0" y="719.0" /><di:waypoint x="1696" y="719.0" /><di:waypoint x="1696" y="300.01" /><bpmndi:BPMNLabel><dc:Bounds x="2891.0" y="630.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow37137_di" bpmnElement="flow37137" bioc:stroke="#0f2695" color:border-color="#0f2695"><di:waypoint x="2531.0" y="625.0" /><di:waypoint x="2531.0" y="719.0" /><di:waypoint x="3556" y="719.0" /><di:waypoint x="3556" y="750.01" /><bpmndi:BPMNLabel><dc:Bounds x="2531.0" y="630.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31320_di" bpmnElement="flow31320"><di:waypoint x="1601.0" y="325.0" /><di:waypoint x="1601.0" y="1800.0" /><di:waypoint x="1726" y="1800.0" /><bpmndi:BPMNLabel><dc:Bounds x="1601.0" y="1805.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31321_di" bpmnElement="flow31321" bioc:stroke="#2fa99b" color:border-color="#2fa99b"><di:waypoint x="1781.0" y="1840.0" /><di:waypoint x="1781.0" y="1938.0" /><di:waypoint x="1336" y="1938.0" /><di:waypoint x="1336" y="300.01" /><bpmndi:BPMNLabel><dc:Bounds x="1781.0" y="1845.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31316_di" bpmnElement="flow31316" bioc:stroke="#e7411c" color:border-color="#e7411c"><di:waypoint x="1241.0" y="175.0" /><di:waypoint x="1241.0" y="273.0" /><di:waypoint x="1336" y="273.0" /><di:waypoint x="1336" y="300.01" /><bpmndi:BPMNLabel><dc:Bounds x="1241.0" y="180.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31429_di" bpmnElement="flow31429"><di:waypoint x="521.0" y="25.0" /><di:waypoint x="521.0" y="1950.0" /><di:waypoint x="646" y="1950.0" /><bpmndi:BPMNLabel><dc:Bounds x="521.0" y="1955.0" width="125.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge><bpmndi:BPMNEdge id="flow31442_di" bpmnElement="flow31442" bioc:stroke="#ae68a9" color:border-color="#ae68a9"><di:waypoint x="701.0" y="1990.0" /><di:waypoint x="701.0" y="2092.0" /><di:waypoint x="976" y="2092.0" /><di:waypoint x="976" y="150.01" /><bpmndi:BPMNLabel><dc:Bounds x="701.0" y="1995.0" width="0.0" height="14" /></bpmndi:BPMNLabel></bpmndi:BPMNEdge></bpmndi:BPMNPlane> </bpmndi:BPMNDiagram></bpmn:definitions>]]></field>
3343
- <field name="can_update_pod_supply_state">True</field>
3344
- <field name="show_invoice_tab">False</field>
3345
- <field name="use_sla">False</field>
3346
- <field name="wf_code">CC01</field>
3347
- </record>
3348
- <record id="symple_triplet_phase_A1001___Creazione_Case_di_Risoluzione_Contrattuale_Automatica" model="symple.triplet.phase">
3349
- <field name="active">True</field>
3350
- <field name="child_case">False</field>
3351
- <field name="code"># Available variables:
3352
- # - case_id: the case that just reached this phase
3353
- # - request: allows you to make HTTP requests (method, url, headers, data)
3354
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3355
- # - json_load: allows you to use JSON.load to convert a json into an object
3356
- # - env: Odoo Environment on which the action is triggered
3357
- # - time, datetime, dateutil, timezone: useful Python libraries
3358
- # - float_compare: Odoo function to compare floats based on specific precisions
3359
- # - ValidationError: Warning Exception to use with raise
3360
- # - Command: x2Many commands namespace
3361
- # - OrderedDict: ordered dictionaries
3362
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3363
- # (line = case id, func = phase name)
3364
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3365
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3366
- # To return a result, assign: result = {...}
3367
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3368
- # phase result will not be set.
3369
-
3370
-
3371
- logs = []
3372
-
3373
-
3374
- def main():
3375
- if not case_id.service_point_ids:
3376
- raise ValidationError(
3377
- "Il case è stato aperto senza service point"
3378
- )
3379
-
3380
- sp = case_id.service_point_ids[0]
3381
-
3382
- if sp.state != "active":
3383
- raise ValidationError("Il service point non è in stato attivo.")
3384
-
3385
- return "OK"
3386
-
3387
-
3388
- try:
3389
- result = main()
3390
-
3391
-
3392
- except Exception as e:
3393
- logs.append({"message": str(e), "traceback": format_exc()})
3394
- case_id.write(
3395
- {"error_message": "Errore durante l'esecuzione della fase: {}".format(str(e))}
3396
- )
3397
-
3398
- if logs:
3399
- log(json_dumps(logs))</field>
3400
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3401
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
3402
- <field name="is_a_postalizer_phase">False</field>
3403
- <field name="is_compute_refund">False</field>
3404
- <field name="is_dl">False</field>
3405
- <field name="is_needs_child_case">False</field>
3406
- <field name="is_pick_refund_template">False</field>
3407
- <field name="is_process_managed">False</field>
3408
- <field name="is_quote_accepted">False</field>
3409
- <field name="is_quote_sent">False</field>
3410
- <field name="is_timeout">False</field>
3411
- <field name="is_voidable">False</field>
3412
- <field name="name">A1001 – Creazione Case di Risoluzione Contrattuale Automatica</field>
3413
- <field name="set_result_automatically">from_code</field>
3414
- </record>
3415
- <record id="symple_triplet_phase_result_C2252_-_Apertura_Case_Automatica_C" model="symple.triplet.phase.result">
3416
- <field name="active">True</field>
3417
- <field name="has_message">False</field>
3418
- <field name="is_annulment">False</field>
3419
- <field name="is_dl_solicitation_result">False</field>
3420
- <field name="is_hidden">False</field>
3421
- <field name="is_quote_expired">False</field>
3422
- <field name="name">C2252 - Apertura Case Automatica</field>
3423
- <field name="next_phase_id" ref="symple_triplet_phase_A1001___Creazione_Case_di_Risoluzione_Contrattuale_Automatica"/>
3424
- <field name="state_code">C</field>
3425
- <field name="wizard_result">SUCCESS</field>
3426
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1590_-_Verifica_Tipologia_Apertura_Case')])]"/>
3427
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3428
- </record>
3429
- <record id="symple_triplet_phase_result_C1401_-_Risoluzione_contrattuale_OK_E-CC01-0001-03" model="symple.triplet.phase.result">
3430
- <field name="active">True</field>
3431
- <field name="has_message">False</field>
3432
- <field name="is_annulment">False</field>
3433
- <field name="is_dl_solicitation_result">False</field>
3434
- <field name="is_hidden">False</field>
3435
- <field name="is_quote_expired">False</field>
3436
- <field name="name">C1401 - Risoluzione contrattuale OK</field>
3437
- <field name="next_phase_id" ref="symple_triplet_phase_A1709_-_verifica_compatibilit_"/>
3438
- <field name="state_code">E-CC01-0001-03</field>
3439
- <field name="wizard_result">SUCCESS</field>
3440
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1001___Creazione_Case_di_Risoluzione_Contrattuale_Automatica')])]"/>
3441
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3442
- </record>
3443
- <record id="symple_triplet_phase_A1556_-_Verica_commodity" model="symple.triplet.phase">
3444
- <field name="active">True</field>
3445
- <field name="child_case">False</field>
3446
- <field name="code"># Available variables:
3447
- # - case_id: the case that just reached this phase
3448
- # - request: allows you to make HTTP requests (method, url, headers, data)
3449
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3450
- # - json_load: allows you to use JSON.load to convert a json into an object
3451
- # - env: Odoo Environment on which the action is triggered
3452
- # - time, datetime, dateutil, timezone: useful Python libraries
3453
- # - float_compare: Odoo function to compare floats based on specific precisions
3454
- # - ValidationError: Warning Exception to use with raise
3455
- # - Command: x2Many commands namespace
3456
- # - OrderedDict: ordered dictionaries
3457
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3458
- # (line = case id, func = phase name)
3459
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3460
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3461
- # To return a result, assign: result = {...}
3462
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3463
- # phase result will not be set.
3464
-
3465
- sp = case_id.service_point_ids[0]
3466
-
3467
- if sp.pod_id:
3468
- result = "ELE"
3469
- elif sp.pdr_id:
3470
- result= "GAS"</field>
3471
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3472
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
3473
- <field name="is_a_postalizer_phase">False</field>
3474
- <field name="is_compute_refund">False</field>
3475
- <field name="is_dl">False</field>
3476
- <field name="is_needs_child_case">False</field>
3477
- <field name="is_pick_refund_template">False</field>
3478
- <field name="is_process_managed">False</field>
3479
- <field name="is_quote_accepted">False</field>
3480
- <field name="is_quote_sent">False</field>
3481
- <field name="is_timeout">False</field>
3482
- <field name="is_voidable">False</field>
3483
- <field name="name">A1556 - Verica commodity</field>
3484
- <field name="set_result_automatically">from_code</field>
3485
- </record>
3486
- <record id="symple_triplet_phase_result_C1037_-_Ammissibilit__OK_E-CC01-0025" model="symple.triplet.phase.result">
3487
- <field name="active">True</field>
3488
- <field name="has_message">False</field>
3489
- <field name="is_annulment">False</field>
3490
- <field name="is_dl_solicitation_result">False</field>
3491
- <field name="is_hidden">False</field>
3492
- <field name="is_quote_expired">False</field>
3493
- <field name="name">C1037 - Ammissibilità OK</field>
3494
- <field name="next_phase_id" ref="symple_triplet_phase_A1556_-_Verica_commodity"/>
3495
- <field name="state_code">E-CC01-0025</field>
3496
- <field name="wizard_result">OK-100</field>
3497
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0816_-_In_attesa_esito_ammissibilit_')])]"/>
3498
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','OK-100')])" />
3499
- </record>
3500
- <record id="symple_triplet_phase_result_C2222___Commodity_Gas_E-CC01-0001-04" model="symple.triplet.phase.result">
3501
- <field name="active">True</field>
3502
- <field name="has_message">False</field>
3503
- <field name="is_annulment">False</field>
3504
- <field name="is_dl_solicitation_result">False</field>
3505
- <field name="is_hidden">False</field>
3506
- <field name="is_quote_expired">False</field>
3507
- <field name="name">C2222 – Commodity Gas</field>
3508
- <field name="next_phase_id" ref="symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza"/>
3509
- <field name="state_code">E-CC01-0001-04</field>
3510
- <field name="wizard_result">SUCCESS</field>
3511
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1556_-_Verica_commodity')])]"/>
3512
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3513
- </record>
3514
- <record id="symple_triplet_phase_A2598_-_Invio_Pec" model="symple.triplet.phase">
3515
- <field name="active">True</field>
3516
- <field name="automatic_template_id" model="mail.template" eval="obj().search([('name','=','TEST PEC TG (copia)')])" />
3517
- <field name="child_case">False</field>
3518
- <field name="code"># Available variables:
3519
- # - case_id: the case that just reached this phase
3520
- # - request: allows you to make HTTP requests (method, url, headers, data)
3521
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3522
- # - json_load: allows you to use JSON.load to convert a json into an object
3523
- # - env: Odoo Environment on which the action is triggered
3524
- # - time, datetime, dateutil, timezone: useful Python libraries
3525
- # - float_compare: Odoo function to compare floats based on specific precisions
3526
- # - ValidationError: Warning Exception to use with raise
3527
- # - Command: x2Many commands namespace
3528
- # - OrderedDict: ordered dictionaries
3529
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3530
- # (line = case id, func = phase name)
3531
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3532
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3533
- # To return a result, assign: result = {...}
3534
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3535
- # phase result will not be set.
3536
-
3537
-
3538
-
3539
- </field>
3540
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','Customer Care')])" />
3541
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
3542
- <field name="is_a_postalizer_phase">False</field>
3543
- <field name="is_compute_refund">False</field>
3544
- <field name="is_dl">False</field>
3545
- <field name="is_mail_managed">manually</field>
3546
- <field name="is_needs_child_case">False</field>
3547
- <field name="is_pick_refund_template">False</field>
3548
- <field name="is_process_managed">True</field>
3549
- <field name="is_quote_accepted">False</field>
3550
- <field name="is_quote_sent">False</field>
3551
- <field name="is_timeout">False</field>
3552
- <field name="is_voidable">False</field>
3553
- <field name="name">A2598 - Invio Pec</field>
3554
- <field name="set_result_automatically">from_email</field>
3555
- </record>
3556
- <record id="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0001-05" model="symple.triplet.phase.result">
3557
- <field name="active">True</field>
3558
- <field name="has_message">False</field>
3559
- <field name="is_annulment">False</field>
3560
- <field name="is_dl_solicitation_result">False</field>
3561
- <field name="is_hidden">False</field>
3562
- <field name="is_quote_expired">False</field>
3563
- <field name="name">C1019 - Inviata</field>
3564
- <field name="next_phase_id" ref="symple_triplet_phase_A1004_-_Verifica_RCU___Data_decorrenza"/>
3565
- <field name="state_code">E-CC01-0001-05</field>
3566
- <field name="wizard_result">SUCCESS</field>
3567
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2598_-_Invio_Pec')])]"/>
3568
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3569
- </record>
3570
- <record id="symple_triplet_phase_result_C2221_-_Commodity_Elettricit__E-CC01-0001-06" model="symple.triplet.phase.result">
3571
- <field name="active">True</field>
3572
- <field name="has_message">False</field>
3573
- <field name="is_annulment">False</field>
3574
- <field name="is_dl_solicitation_result">False</field>
3575
- <field name="is_hidden">False</field>
3576
- <field name="is_quote_expired">False</field>
3577
- <field name="name">C2221 - Commodity Elettricità</field>
3578
- <field name="next_phase_id" ref="symple_triplet_phase_A2598_-_Invio_Pec"/>
3579
- <field name="state_code">E-CC01-0001-06</field>
3580
- <field name="wizard_result">SUCCESS</field>
3581
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1556_-_Verica_commodity')])]"/>
3582
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3583
- </record>
3584
- <record id="symple_triplet_phase_A2338_-_Inserimento_Pratica" model="symple.triplet.phase">
3585
- <field name="active">True</field>
3586
- <field name="child_case">False</field>
3587
- <field name="code"># Available variables:
3588
- # - case_id: the case that just reached this phase
3589
- # - request: allows you to make HTTP requests (method, url, headers, data)
3590
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3591
- # - json_load: allows you to use JSON.load to convert a json into an object
3592
- # - env: Odoo Environment on which the action is triggered
3593
- # - time, datetime, dateutil, timezone: useful Python libraries
3594
- # - float_compare: Odoo function to compare floats based on specific precisions
3595
- # - ValidationError: Warning Exception to use with raise
3596
- # - Command: x2Many commands namespace
3597
- # - OrderedDict: ordered dictionaries
3598
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3599
- # (line = case id, func = phase name)
3600
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3601
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3602
- # To return a result, assign: result = {...}
3603
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3604
- # phase result will not be set.
3605
-
3606
-
3607
-
3608
- </field>
3609
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3610
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
3611
- <field name="is_a_postalizer_phase">False</field>
3612
- <field name="is_compute_refund">False</field>
3613
- <field name="is_dl">False</field>
3614
- <field name="is_needs_child_case">False</field>
3615
- <field name="is_pick_refund_template">False</field>
3616
- <field name="is_process_managed">False</field>
3617
- <field name="is_quote_accepted">False</field>
3618
- <field name="is_quote_sent">False</field>
3619
- <field name="is_timeout">False</field>
3620
- <field name="is_voidable">False</field>
3621
- <field name="name">A2338 - Inserimento Pratica</field>
3622
- </record>
3623
- <record id="symple_triplet_phase_result_C2224_-_OK_-_Ammissibilit__Hub_E-CC01-0013" model="symple.triplet.phase.result">
3624
- <field name="active">True</field>
3625
- <field name="has_message">False</field>
3626
- <field name="is_annulment">False</field>
3627
- <field name="is_dl_solicitation_result">False</field>
3628
- <field name="is_hidden">False</field>
3629
- <field name="is_quote_expired">False</field>
3630
- <field name="name">C2224 - OK - Ammissibilità Hub</field>
3631
- <field name="next_phase_id" ref="symple_triplet_phase_A2338_-_Inserimento_Pratica"/>
3632
- <field name="state_code">E-CC01-0013</field>
3633
- <field name="wizard_result">OK-HUB</field>
3634
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1715_-_In_attesa_check_IFS')])]"/>
3635
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','OK-HUB')])" />
3636
- </record>
3637
- <record id="symple_triplet_phase_result_C3118_-_KO_AtoA_pdc_E-CC01-0014" model="symple.triplet.phase.result">
3638
- <field name="active">True</field>
3639
- <field name="has_message">False</field>
3640
- <field name="is_annulment">False</field>
3641
- <field name="is_dl_solicitation_result">False</field>
3642
- <field name="is_hidden">False</field>
3643
- <field name="is_quote_expired">False</field>
3644
- <field name="name">C3118 - KO AtoA/pdc</field>
3645
- <field name="next_phase_id" ref="symple_triplet_phase_A2558_-_verifica_avvio_gestione_manuale"/>
3646
- <field name="state_code">E-CC01-0014</field>
3647
- <field name="wizard_result">KO-PDC-A2A</field>
3648
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2338_-_Inserimento_Pratica')])]"/>
3649
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','KO-PDC-A2A')])" />
3650
- </record>
3651
- <record id="symple_triplet_phase_result_C3117_-_OK_pratica_inserita_E-CC01-00081" model="symple.triplet.phase.result">
3652
- <field name="active">True</field>
3653
- <field name="has_message">False</field>
3654
- <field name="is_annulment">False</field>
3655
- <field name="is_dl_solicitation_result">False</field>
3656
- <field name="is_hidden">False</field>
3657
- <field name="is_quote_expired">False</field>
3658
- <field name="name">C3117 - OK pratica inserita</field>
3659
- <field name="next_phase_id" ref="symple_triplet_phase_A0816_-_In_attesa_esito_ammissibilit_"/>
3660
- <field name="state_code">E-CC01-00081</field>
3661
- <field name="wizard_result">SUCCESS</field>
3662
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2338_-_Inserimento_Pratica')])]"/>
3663
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3664
- </record>
3665
- <record id="symple_triplet_phase_A2561_-_verifica_stato_invio_pratica_da_annullare" model="symple.triplet.phase">
3666
- <field name="active">True</field>
3667
- <field name="child_case">False</field>
3668
- <field name="code"># Available variables:
3669
- # - case_id: the case that just reached this phase
3670
- # - request: allows you to make HTTP requests (method, url, headers, data)
3671
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3672
- # - json_load: allows you to use JSON.load to convert a json into an object
3673
- # - env: Odoo Environment on which the action is triggered
3674
- # - time, datetime, dateutil, timezone: useful Python libraries
3675
- # - float_compare: Odoo function to compare floats based on specific precisions
3676
- # - ValidationError: Warning Exception to use with raise
3677
- # - Command: x2Many commands namespace
3678
- # - OrderedDict: ordered dictionaries
3679
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3680
- # (line = case id, func = phase name)
3681
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3682
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3683
- # To return a result, assign: result = {...}
3684
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3685
- # phase result will not be set.
3686
-
3687
-
3688
-
3689
- </field>
3690
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3691
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
3692
- <field name="is_a_postalizer_phase">False</field>
3693
- <field name="is_compute_refund">False</field>
3694
- <field name="is_dl">False</field>
3695
- <field name="is_needs_child_case">False</field>
3696
- <field name="is_pick_refund_template">False</field>
3697
- <field name="is_process_managed">False</field>
3698
- <field name="is_quote_accepted">False</field>
3699
- <field name="is_quote_sent">False</field>
3700
- <field name="is_timeout">False</field>
3701
- <field name="is_voidable">False</field>
3702
- <field name="name">A2561 - verifica stato invio pratica da annullare</field>
3703
- </record>
3704
- <record id="symple_triplet_phase_result_C2475_-_OK_-_Ammissibilit__Annullamento_Hub_E-CC01-0042" model="symple.triplet.phase.result">
3705
- <field name="active">True</field>
3706
- <field name="has_message">False</field>
3707
- <field name="is_annulment">False</field>
3708
- <field name="is_dl_solicitation_result">False</field>
3709
- <field name="is_hidden">False</field>
3710
- <field name="is_quote_expired">False</field>
3711
- <field name="name">C2475 - OK - Ammissibilità Annullamento Hub</field>
3712
- <field name="next_phase_id" ref="symple_triplet_phase_A2561_-_verifica_stato_invio_pratica_da_annullare"/>
3713
- <field name="state_code">E-CC01-0042</field>
3714
- <field name="wizard_result">SUCCESS</field>
3715
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A1767_-_In_attesa_check_IFS_Annullamento')])]"/>
3716
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3717
- </record>
3718
- <record id="symple_triplet_phase_result_C2599_-_annullamento_confermato_E-CC01-00084" model="symple.triplet.phase.result">
3719
- <field name="active">True</field>
3720
- <field name="has_message">False</field>
3721
- <field name="is_annulment">False</field>
3722
- <field name="is_dl_solicitation_result">False</field>
3723
- <field name="is_hidden">False</field>
3724
- <field name="is_quote_expired">False</field>
3725
- <field name="name">C2599 - annullamento confermato</field>
3726
- <field name="next_phase_id" ref="symple_triplet_phase_A1833_-_Case_annullato_da_APR"/>
3727
- <field name="state_code">E-CC01-00084</field>
3728
- <field name="wizard_result">SUCCESS</field>
3729
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2561_-_verifica_stato_invio_pratica_da_annullare')])]"/>
3730
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3731
- </record>
3732
- <record id="symple_triplet_phase_A0832_-_Invio_Richiesta_Annullamento" model="symple.triplet.phase">
3733
- <field name="active">True</field>
3734
- <field name="child_case">False</field>
3735
- <field name="code"># Available variables:
3736
- # - case_id: the case that just reached this phase
3737
- # - request: allows you to make HTTP requests (method, url, headers, data)
3738
- # - json_dumps: allows you to use JSON.dumps to convert an object into a json
3739
- # - json_load: allows you to use JSON.load to convert a json into an object
3740
- # - env: Odoo Environment on which the action is triggered
3741
- # - time, datetime, dateutil, timezone: useful Python libraries
3742
- # - float_compare: Odoo function to compare floats based on specific precisions
3743
- # - ValidationError: Warning Exception to use with raise
3744
- # - Command: x2Many commands namespace
3745
- # - OrderedDict: ordered dictionaries
3746
- # - log: log(message, level='info'): logging function to record debug information in ir.logging table
3747
- # (line = case id, func = phase name)
3748
- # - format_exc: forwarded from traceback.format_exc - returns str stack trace of last exception thrown
3749
- # - first: forwarded from odoo.fields.first - safely gets first element of recordset
3750
- # To return a result, assign: result = {...}
3751
- # WARNING: if return = False or return value is not in the result table or no result is returned at all,
3752
- # phase result will not be set.
3753
-
3754
-
3755
-
3756
- </field>
3757
- <field name="helpdesk_group_id" model="helpdesk.team" eval="obj().search([('name','=','SYSTEM-Sorgenia')])" />
3758
- <field name="helpdesk_stage_id" model="helpdesk.stage" eval="obj().search([('name','=','In Progress')])" />
3759
- <field name="is_a_postalizer_phase">False</field>
3760
- <field name="is_compute_refund">False</field>
3761
- <field name="is_dl">False</field>
3762
- <field name="is_needs_child_case">False</field>
3763
- <field name="is_pick_refund_template">False</field>
3764
- <field name="is_process_managed">False</field>
3765
- <field name="is_quote_accepted">False</field>
3766
- <field name="is_quote_sent">False</field>
3767
- <field name="is_timeout">False</field>
3768
- <field name="is_voidable">False</field>
3769
- <field name="name">A0832 - Invio Richiesta Annullamento</field>
3770
- </record>
3771
- <record id="symple_triplet_phase_result_C3118_-_KO_AtoA_pdc_E-CC01-0044" model="symple.triplet.phase.result">
3772
- <field name="active">True</field>
3773
- <field name="has_message">False</field>
3774
- <field name="is_annulment">False</field>
3775
- <field name="is_dl_solicitation_result">False</field>
3776
- <field name="is_hidden">False</field>
3777
- <field name="is_quote_expired">False</field>
3778
- <field name="name">C3118 - KO AtoA/pdc</field>
3779
- <field name="next_phase_id" ref="symple_triplet_phase_A2562_-_verifica_avvio_gestione_manuale_annullamento"/>
3780
- <field name="state_code">E-CC01-0044</field>
3781
- <field name="wizard_result">SUCCESS</field>
3782
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0832_-_Invio_Richiesta_Annullamento')])]"/>
3783
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3784
- </record>
3785
- <record id="symple_triplet_phase_result_C3120_-_annullamento_da_gestire_E-CC01-00083" model="symple.triplet.phase.result">
3786
- <field name="active">True</field>
3787
- <field name="has_message">False</field>
3788
- <field name="is_annulment">False</field>
3789
- <field name="is_dl_solicitation_result">False</field>
3790
- <field name="is_hidden">False</field>
3791
- <field name="is_quote_expired">False</field>
3792
- <field name="name">C3120 - annullamento da gestire</field>
3793
- <field name="next_phase_id" ref="symple_triplet_phase_A0832_-_Invio_Richiesta_Annullamento"/>
3794
- <field name="state_code">E-CC01-00083</field>
3795
- <field name="wizard_result">SUCCESS</field>
3796
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A2561_-_verifica_stato_invio_pratica_da_annullare')])]"/>
3797
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3798
- </record>
3799
- <record id="symple_triplet_phase_result_C2875_-_OK_-_Inviato_Annullamento_al_SII_E-CC01-00085" model="symple.triplet.phase.result">
3800
- <field name="active">True</field>
3801
- <field name="has_message">False</field>
3802
- <field name="is_annulment">False</field>
3803
- <field name="is_dl_solicitation_result">False</field>
3804
- <field name="is_hidden">False</field>
3805
- <field name="is_quote_expired">False</field>
3806
- <field name="name">C2875 - OK - Inviato Annullamento al SII</field>
3807
- <field name="next_phase_id" ref="symple_triplet_phase_A0833_-_In_attesa_ricezione_Ammissibilit__Annullamento"/>
3808
- <field name="state_code">E-CC01-00085</field>
3809
- <field name="wizard_result">SUCCESS</field>
3810
- <field name="starting_phase_ids" model="symple.triplet.phase" eval="[(6, 0, [ref('symple_triplet_phase_A0832_-_Invio_Richiesta_Annullamento')])]"/>
3811
- <field name="result_type_id" model="result.type" eval="obj().search([('name','=','Success')])" />
3812
- </record>
3813
- <record id="result_code_configurator_A1672_-_Recupero_dati_a_CRM_OK" model="result.code.configurator">
3814
- <field name="code_phase_id" ref="symple_triplet_phase_A1672_-_Recupero_dati_a_CRM"/>
3815
- <field name="result_value">OK</field>
3816
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2365_-_Recupero_Dati_OK_E-CC01-0008"/>
3817
- </record>
3818
- <record id="result_code_configurator_A1559_-_Invio_alla_Market_Communication_OK" model="result.code.configurator">
3819
- <field name="code_phase_id" ref="symple_triplet_phase_A1559_-_Invio_alla_Market_Communication"/>
3820
- <field name="result_value">OK</field>
3821
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0011"/>
3822
- </record>
3823
- <record id="result_code_configurator_A1590_-_Verifica_Tipologia_Apertura_Case_AUTOMATICO" model="result.code.configurator">
3824
- <field name="code_phase_id" ref="symple_triplet_phase_A1590_-_Verifica_Tipologia_Apertura_Case"/>
3825
- <field name="result_value">AUTOMATICO</field>
3826
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2252_-_Apertura_Case_Automatica_C"/>
3827
- </record>
3828
- <record id="result_code_configurator_A1590_-_Verifica_Tipologia_Apertura_Case_MANUALE" model="result.code.configurator">
3829
- <field name="code_phase_id" ref="symple_triplet_phase_A1590_-_Verifica_Tipologia_Apertura_Case"/>
3830
- <field name="result_value">MANUALE</field>
3831
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2251_-_Apertura_Case_Manuale_E-CC01-0001-01"/>
3832
- </record>
3833
- <record id="result_code_configurator_A1577_-_Chiusura_Ordine_CRM_OK" model="result.code.configurator">
3834
- <field name="code_phase_id" ref="symple_triplet_phase_A1577_-_Chiusura_Ordine_CRM"/>
3835
- <field name="result_value">OK</field>
3836
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2242_-_Chiusura_Ordine_OK_E-CC01-0032"/>
3837
- </record>
3838
- <record id="result_code_configurator_A2398_-_Invio_ordine_CRM_OK" model="result.code.configurator">
3839
- <field name="code_phase_id" ref="symple_triplet_phase_A2398_-_Invio_ordine_CRM"/>
3840
- <field name="result_value">OK</field>
3841
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C1900_-_Integrazione_M2C_E-CC01-0035"/>
3842
- </record>
3843
- <record id="result_code_configurator_A0802_-_Integrazione_M2C_OK" model="result.code.configurator">
3844
- <field name="code_phase_id" ref="symple_triplet_phase_A0802_-_Integrazione_M2C"/>
3845
- <field name="result_value">OK</field>
3846
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C1904_-_In_attesa_esito_M2C_E-CC01-0036"/>
3847
- </record>
3848
- <record id="result_code_configurator_A2142_-_Invio_alla_marketcom_annullamento_forzato_OK" model="result.code.configurator">
3849
- <field name="code_phase_id" ref="symple_triplet_phase_A2142_-_Invio_alla_marketcom_annullamento_forzato"/>
3850
- <field name="result_value">OK</field>
3851
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0053"/>
3852
- </record>
3853
- <record id="result_code_configurator_A1595_-_Invio_Annullamento_alla_Market_Communication_OK" model="result.code.configurator">
3854
- <field name="code_phase_id" ref="symple_triplet_phase_A1595_-_Invio_Annullamento_alla_Market_Communication"/>
3855
- <field name="result_value">OK</field>
3856
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C1019_-_Inviata_E-CC01-0041"/>
3857
- </record>
3858
- <record id="result_code_configurator_A1836_-_Apertura_case_figlio_OK" model="result.code.configurator">
3859
- <field name="code_phase_id" ref="symple_triplet_phase_A1836_-_Apertura_case_figlio"/>
3860
- <field name="result_value">OK</field>
3861
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2550_-_case_creato_E-CC01-0040"/>
3862
- </record>
3863
- <record id="result_code_configurator_A1556_-_Verica_commodity_ELE" model="result.code.configurator">
3864
- <field name="code_phase_id" ref="symple_triplet_phase_A1556_-_Verica_commodity"/>
3865
- <field name="result_value">ELE</field>
3866
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2221_-_Commodity_Elettricit__E-CC01-0001-06"/>
3867
- </record>
3868
- <record id="result_code_configurator_A1556_-_Verica_commodity_GAS" model="result.code.configurator">
3869
- <field name="code_phase_id" ref="symple_triplet_phase_A1556_-_Verica_commodity"/>
3870
- <field name="result_value">GAS</field>
3871
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2222___Commodity_Gas_E-CC01-0001-04"/>
3872
- </record>
3873
- <record id="result_code_configurator_A1001___Creazione_Case_di_Risoluzione_Contrattuale_Automatica_OK" model="result.code.configurator">
3874
- <field name="code_phase_id" ref="symple_triplet_phase_A1001___Creazione_Case_di_Risoluzione_Contrattuale_Automatica"/>
3875
- <field name="result_value">OK</field>
3876
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C1401_-_Risoluzione_contrattuale_OK_E-CC01-0001-03"/>
3877
- </record>
3878
- <record id="result_code_configurator_A1709_-_verifica_compatibilit__KO" model="result.code.configurator">
3879
- <field name="code_phase_id" ref="symple_triplet_phase_A1709_-_verifica_compatibilit_"/>
3880
- <field name="result_value">KO</field>
3881
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C404_-_KO_-_Incompatibile_E-CC01-0003"/>
3882
- </record>
3883
- <record id="result_code_configurator_A1709_-_verifica_compatibilit__OK" model="result.code.configurator">
3884
- <field name="code_phase_id" ref="symple_triplet_phase_A1709_-_verifica_compatibilit_"/>
3885
- <field name="result_value">OK</field>
3886
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2654_-_Processo_Compatibile_E-CC01-0004"/>
3887
- </record>
3888
- <record id="result_code_configurator_A1709_-_verifica_compatibilit__PARTIAL_KO" model="result.code.configurator">
3889
- <field name="code_phase_id" ref="symple_triplet_phase_A1709_-_verifica_compatibilit_"/>
3890
- <field name="result_value">PARTIAL_KO</field>
3891
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C2639_-_Incompatibilit__Non_bloccante_E-CC01-0005"/>
3892
- </record>
3893
- <record id="result_code_configurator_A2397_-_OK_RCU___verifica_data_decorrenza_RES1" model="result.code.configurator">
3894
- <field name="code_phase_id" ref="symple_triplet_phase_A2397_-_OK_RCU___verifica_data_decorrenza"/>
3895
- <field name="result_value">RES1</field>
3896
- <field name="triplet_phase_result_id" ref="symple_triplet_phase_result_C1936_-_Data_raggiunta_E-CC01-0031"/>
3897
- </record>
3898
-
3899
- </data>
3900
- </odoo>
3901
-
3902
- Processed_records: 145
3903
- Managed records: 145