relation ids
This commit is contained in:
parent
db6e19bba9
commit
34b0f1f385
@ -14,6 +14,9 @@ class Coworker(models.Model):
|
||||
|
||||
events_coworker_count = fields.Integer('Number of event have participe',
|
||||
compute='_compute_events_coworker_count')
|
||||
#Relation fields
|
||||
coworker_relation_ids = fields.One2many(
|
||||
'coworking.relation', 'relation', 'coworker1')
|
||||
|
||||
@api.depends('event_ids')
|
||||
def _compute_events_coworker_count(self):
|
||||
|
@ -9,12 +9,9 @@
|
||||
<field name="inherit_id" ref ="coworking_coworker.view_form_coworker" />
|
||||
<field name="arch" type="xml">
|
||||
<notebook position="inside">
|
||||
<page string="Events" name="Events">
|
||||
<group name="events">
|
||||
<field name="manager_event_ids"
|
||||
context="{'default_manager_id': active_id}" />
|
||||
<field name="event_ids" />
|
||||
<field name="events_coworker_count" />
|
||||
<page string="Relation" name="Relation">
|
||||
<group name="relation">
|
||||
<field name="coworker_relation_ids" context="{'default_relation_id': active_id}" />
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
|
Loading…
Reference in New Issue
Block a user