|
1 | | -<?xml version="1.0" encoding="utf-8"?> |
| 1 | +<?xml version="1.0" encoding="utf-8" ?> |
2 | 2 | <odoo> |
3 | 3 | <!-- Wizard Form View --> |
4 | 4 | <record id="view_mis_demo_wizard_form" model="ir.ui.view"> |
|
7 | 7 | <field name="arch" type="xml"> |
8 | 8 | <form string="Load MIS Demo Data"> |
9 | 9 | <sheet> |
10 | | - <group> |
| 10 | + <field name="mis_demo_loaded" invisible="1" /> |
| 11 | + <field name="has_grm_demo" invisible="1" /> |
| 12 | + <field name="has_case_demo" invisible="1" /> |
| 13 | + <div |
| 14 | + class="alert alert-warning" |
| 15 | + role="alert" |
| 16 | + invisible="not mis_demo_loaded" |
| 17 | + > |
| 18 | + <p class="mb-0"> |
| 19 | + <strong |
| 20 | + >MIS Demo Data has already been loaded for this company.</strong> |
| 21 | + Loading it again may create duplicate records. |
| 22 | + </p> |
| 23 | + </div> |
| 24 | + <group invisible="mis_demo_loaded"> |
11 | 25 | <field name="country_id" widget="radio" /> |
12 | 26 | </group> |
13 | | - <div class="alert alert-info" role="alert"> |
14 | | - <p><strong>This will load comprehensive MIS demo data:</strong></p> |
| 27 | + <div |
| 28 | + class="alert alert-info" |
| 29 | + role="alert" |
| 30 | + invisible="mis_demo_loaded" |
| 31 | + > |
| 32 | + <p> |
| 33 | + <strong>This will load comprehensive MIS demo data:</strong> |
| 34 | + </p> |
15 | 35 | <ul> |
16 | | - <li>6 social protection programs (Child Grant, Pension, Emergency Relief, Cash Transfer, Disability Support, Food Assistance)</li> |
17 | | - <li>8 demo personas with full stories and payment history</li> |
18 | | - <li>~730 deterministic households with ~2,500 members (country-aware names)</li> |
| 36 | + <li |
| 37 | + >6 social protection programs (Child Grant, Pension, Emergency Relief, Cash Transfer, Disability Support, Food Assistance)</li> |
| 38 | + <li |
| 39 | + >8 demo personas with full stories and payment history</li> |
| 40 | + <li |
| 41 | + >~730 deterministic households with ~2,500 members (country-aware names)</li> |
19 | 42 | <li>Program enrollments based on household eligibility</li> |
20 | 43 | <li>Program cycles with entitlements</li> |
21 | 44 | <li>Logic Packs for eligibility rules</li> |
22 | 45 | <li>Change requests at various workflow stages</li> |
23 | | - <li>GRM tickets and case records</li> |
| 46 | + <li invisible="not has_grm_demo">GRM tickets</li> |
| 47 | + <li invisible="not has_case_demo">Case records</li> |
24 | 48 | <li>Fairness analysis data</li> |
25 | 49 | </ul> |
26 | | - <p class="mb-0"><em>Names are locale-aware and 100% reproducible per country selection.</em></p> |
| 50 | + <p class="mb-0"> |
| 51 | + <em |
| 52 | + >Names are locale-aware and 100% reproducible per country selection.</em> |
| 53 | + </p> |
27 | 54 | </div> |
28 | 55 | </sheet> |
29 | 56 | <footer> |
30 | | - <button name="action_generate_demo_data" string="Load Demo Data" type="object" class="btn-primary"/> |
31 | | - <button string="Cancel" class="btn-secondary" special="cancel"/> |
| 57 | + <button |
| 58 | + name="action_generate_demo_data" |
| 59 | + string="Load Demo Data" |
| 60 | + type="object" |
| 61 | + class="btn-primary" |
| 62 | + invisible="mis_demo_loaded" |
| 63 | + /> |
| 64 | + <button |
| 65 | + string="Cancel" |
| 66 | + class="btn-secondary" |
| 67 | + special="cancel" |
| 68 | + invisible="mis_demo_loaded" |
| 69 | + /> |
| 70 | + <button |
| 71 | + string="Close" |
| 72 | + class="btn-primary" |
| 73 | + special="cancel" |
| 74 | + invisible="not mis_demo_loaded" |
| 75 | + /> |
32 | 76 | </footer> |
33 | 77 | </form> |
34 | 78 | </field> |
|
40 | 84 | <field name="res_model">spp.mis.demo.wizard</field> |
41 | 85 | <field name="view_mode">form</field> |
42 | 86 | <field name="target">new</field> |
43 | | - <field name="view_id" ref="view_mis_demo_wizard_form"/> |
| 87 | + <field name="view_id" ref="view_mis_demo_wizard_form" /> |
44 | 88 | </record> |
45 | 89 |
|
46 | 90 | <!-- Parent menu for Demo Data (under Settings) --> |
47 | | - <menuitem id="menu_demo_data_root" |
48 | | - name="Demo Data" |
49 | | - parent="base.menu_administration" |
50 | | - sequence="100" |
51 | | - groups="base.group_system"/> |
| 91 | + <menuitem |
| 92 | + id="menu_demo_data_root" |
| 93 | + name="Demo Data" |
| 94 | + parent="base.menu_administration" |
| 95 | + sequence="100" |
| 96 | + groups="base.group_system" |
| 97 | + /> |
52 | 98 |
|
53 | 99 | <!-- Menu Item (under Settings > Demo Data) --> |
54 | 100 | <menuitem |
|
0 commit comments