This question has been flagged
1 Reply
2835 Views

Hi, I have created a new many2many(x_recruiters) field to hr.recruitment.stage via user interface, and i am trying to access it in the tree view of the applicant, like 

<?xml version="1.0"?>

<tree string="Applicants" multi_edit="1" sample="1">

  <field name="stage_id.x_recruiters"/>

</tree>


But it showing an error

Error while validating view: Field "stage_id.x_recruiters" does not exist in model "hr.applicant"

Can you please guide me to achieve this in the tree view, it will be very helpful for me. thanks in advance.

Avatar
Discard
Best Answer

Hi,

Here the issue is, created a field in ‘hr.recruitment.stage’ model. But you try to create a view in the ‘hr.applicant’ model. And the important point here you can’t call a field like "stage_id.x_recruiters" in view definitions. You need to create another field on ‘hr.applicant’ model related to stage_id. Then only you can give the field inside a view definition.
Regards
Avatar
Discard