Skip to content

Commit bc54f42

Browse files
Add farm activity and event data tabs in the farmer group UI
1 parent 6856fb6 commit bc54f42

File tree

1 file changed

+54
-0
lines changed

1 file changed

+54
-0
lines changed

spp_farmer_registry_laos/views/farmer_group_view.xml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,18 @@
5454
<span class="o_stat_text">Enable</span>
5555
</div>
5656
</button>
57+
<button
58+
type="object"
59+
class="oe_stat_button"
60+
icon="fa-calendar"
61+
name="open_create_event_wizard"
62+
invisible="disabled"
63+
>
64+
<div class="o_form_field o_stat_info">
65+
<span class="o_stat_text">Event</span>
66+
<span class="o_stat_text">Data</span>
67+
</div>
68+
</button>
5769
</div>
5870
<widget name="web_ribbon" title="Archived" bg_color="bg-danger" invisible="active" />
5971
<widget
@@ -158,6 +170,7 @@
158170
name="group"
159171
options="{'no_open':True,'no_create_edit':True,'no_create':True}"
160172
readonly="1"
173+
force_save="1"
161174
/>
162175
</h1>
163176
<label for="individual" string="Child:" />
@@ -183,11 +196,52 @@
183196
<field name="ended_date" />
184197
</group>
185198
<field name="individual_domain" invisible="1" />
199+
<field name="group" invisible="1" />
186200
</sheet>
187201
</form>
188202
</field>
189203
</group>
190204
</page>
205+
<page name="section_farm_act" string="Farm Activity">
206+
<field name="farm_prod_ids">
207+
<tree editable="bottom">
208+
<field name="product_id" width="20%" />
209+
<field name="product_name" width="30%" />
210+
<field name="product_name_eng" width="30%" />
211+
<field name="target_year" width="20%" />
212+
</tree>
213+
</field>
214+
</page>
215+
<page name="event_data" string="Event Data">
216+
<group>
217+
<group name="event_data_group">
218+
</group>
219+
<group name="event_data_group2">
220+
</group>
221+
</group>
222+
<group>
223+
<field name="event_data_ids" readonly="1">
224+
<tree>
225+
<button
226+
name="open_form"
227+
type="object"
228+
icon="fa-external-link"
229+
class="btn-success"
230+
/>
231+
<field name="name" />
232+
<field name="event_type" />
233+
<field name="collection_date" />
234+
<field name="expiry_date" />
235+
<field
236+
name="state"
237+
decoration-success="state=='active'"
238+
decoration-warning="state=='inactive'"
239+
widget="badge"
240+
/>
241+
</tree>
242+
</field>
243+
</group>
244+
</page>
191245
<page name="address_coordinates" string="Address Coordinates">
192246
<field name="land_coordinates" />
193247
</page>

0 commit comments

Comments
 (0)