How to get field value from another Many2many field?












1














I use odoo 10 and I created a custom module to plan trips. I create a view for the plans in which I will select the list of my travels. My problem now is how I can get the Start and Destination fields of each trip insert in this view knowing that the field that displays the list of trips is travel_ids = fields.Many2many ('tms.travel', copy = False, string = 'Travels'). I try a lot but no result. Any idea for help please ??



enter image description here



tms_travel_planning.xml



<?xml version="1.0" encoding="UTF-8"?>
<odoo>
<data>

<record id="view_tms_travel_planning_form" model="ir.ui.view">
<field name="name">view.tms.travel.planning.form</field>
<field name="model">tms.planning</field>
<field name="arch" type="xml">
<form string="Plannification des voyage">
<header>
<field name="state" statusbar_visible="draft,approved,confirmed" widget="statusbar"/>
</header>
<sheet>
<div class="oe_title">
<h1>
<label class="oe_inline" style="font-size:30px;" string="Plannification - " attrs="{'invisible':[('name','=', False)]}"/>
<field name="name" readonly="1"/>
</h1>
</div>
<group>
<group>

<field name="datetime"/>
<field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>
</group>

<group>
<field name="num_vehicule_dispo"/>
<field name="num_chauffeur_dispo"/>

</group>
</group>
<notebook colspan="1">
<page string="Les voyages à planifier">
<separator coslpan="4" string="Voyages"/>
<!--<field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>-->
<field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" colspan="4"
domain="[('state','not in',('cancel','closed'))]" name="travel_ids" nolabel="1"/>
<separator coslpan="4" string="Véhicules"/>
<field colspan="4" name="fleet_ids" nolabel="1"/>
<separator coslpan="4" string="Conducteurs"/>
<field colspan="4" name="employee_ids" nolabel="1"/>

</page>

</notebook>
</sheet>
</form>
</field>
</record>
</data>
</odoo>


tms_travel_planning.py



 # -*- coding: utf-8 -*-

from odoo import _, api, fields, models
from odoo.exceptions import ValidationError


class TmsTravelPlanning(models.Model):
_name = 'tms.planning'

name = fields.Char('Num du plannification')
operating_unit_id = fields.Many2one(
'operating.unit', string='Operating Unit', required=True)
id_planning=fields.Integer(string="Numéro du plannification")
datetime=fields.Date(string="Date")
num_vehicule_dispo=fields.Integer(string="Nombre de véhicule disponible")
num_chauffeur_dispo=fields.Integer(string="Nombre de chauffeur disponible")
tms
fleet_ids = fields.Many2many('fleet.vehicle', copy=False, string='Véhicules')
employee_ids = fields.Many2many('hr.employee', copy=False, string='Conducteurs')

state = fields.Selection([
('draft', 'Pending'),
('approved', 'Approved'),
('confirmed', 'Confirmed'),
('cancel', 'Cancelled')], readonly=True,
help="Gives the state of the Waybill.",
default='draft')

@api.model
def create(self, values):
planning = super(TmsTravelPlanning, self).create(values)
if not planning.operating_unit_id.planning_sequence_id:
raise ValidationError(_(
'You need to define the sequence for planning in base %s' %
planning.operating_unit_id.name
))
sequence = planning.operating_unit_id.planning_sequence_id
planning.name = sequence.next_by_id()
print(str(values['num_vehicule_dispo']))
print(str(values['num_chauffeur_dispo']))
return planning


tms_travel.xml



    <?xml version="1.0" encoding="UTF-8"?>
<odoo>
<record id="view_tms_travel_tree" model="ir.ui.view">
<field name="name">tms.travel.tree</field>
<field name="model">tms.travel</field>
<field name="priority">1</field>
<field name="arch" type="xml">
<tree>
<field name="name"/>
<field name="date"/>
<field name="departure_id"/>
<field name="arrival_id"/>
<field name="state"/>
<button groups="tms.group_traffic,tms.group_expenses" icon="fa-thumbs-up" name="action_progress" states="draft" string="Dispatch Travel" type="object"/>
<button groups="tms.group_traffic,tms.group_expenses" icon="fa-check-square" name="action_end" states="progress" string="End Travel" type="object"/>
</tree>
</field>
</record>
</odoo>









share|improve this question





























    1














    I use odoo 10 and I created a custom module to plan trips. I create a view for the plans in which I will select the list of my travels. My problem now is how I can get the Start and Destination fields of each trip insert in this view knowing that the field that displays the list of trips is travel_ids = fields.Many2many ('tms.travel', copy = False, string = 'Travels'). I try a lot but no result. Any idea for help please ??



    enter image description here



    tms_travel_planning.xml



    <?xml version="1.0" encoding="UTF-8"?>
    <odoo>
    <data>

    <record id="view_tms_travel_planning_form" model="ir.ui.view">
    <field name="name">view.tms.travel.planning.form</field>
    <field name="model">tms.planning</field>
    <field name="arch" type="xml">
    <form string="Plannification des voyage">
    <header>
    <field name="state" statusbar_visible="draft,approved,confirmed" widget="statusbar"/>
    </header>
    <sheet>
    <div class="oe_title">
    <h1>
    <label class="oe_inline" style="font-size:30px;" string="Plannification - " attrs="{'invisible':[('name','=', False)]}"/>
    <field name="name" readonly="1"/>
    </h1>
    </div>
    <group>
    <group>

    <field name="datetime"/>
    <field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>
    </group>

    <group>
    <field name="num_vehicule_dispo"/>
    <field name="num_chauffeur_dispo"/>

    </group>
    </group>
    <notebook colspan="1">
    <page string="Les voyages à planifier">
    <separator coslpan="4" string="Voyages"/>
    <!--<field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>-->
    <field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" colspan="4"
    domain="[('state','not in',('cancel','closed'))]" name="travel_ids" nolabel="1"/>
    <separator coslpan="4" string="Véhicules"/>
    <field colspan="4" name="fleet_ids" nolabel="1"/>
    <separator coslpan="4" string="Conducteurs"/>
    <field colspan="4" name="employee_ids" nolabel="1"/>

    </page>

    </notebook>
    </sheet>
    </form>
    </field>
    </record>
    </data>
    </odoo>


    tms_travel_planning.py



     # -*- coding: utf-8 -*-

    from odoo import _, api, fields, models
    from odoo.exceptions import ValidationError


    class TmsTravelPlanning(models.Model):
    _name = 'tms.planning'

    name = fields.Char('Num du plannification')
    operating_unit_id = fields.Many2one(
    'operating.unit', string='Operating Unit', required=True)
    id_planning=fields.Integer(string="Numéro du plannification")
    datetime=fields.Date(string="Date")
    num_vehicule_dispo=fields.Integer(string="Nombre de véhicule disponible")
    num_chauffeur_dispo=fields.Integer(string="Nombre de chauffeur disponible")
    tms
    fleet_ids = fields.Many2many('fleet.vehicle', copy=False, string='Véhicules')
    employee_ids = fields.Many2many('hr.employee', copy=False, string='Conducteurs')

    state = fields.Selection([
    ('draft', 'Pending'),
    ('approved', 'Approved'),
    ('confirmed', 'Confirmed'),
    ('cancel', 'Cancelled')], readonly=True,
    help="Gives the state of the Waybill.",
    default='draft')

    @api.model
    def create(self, values):
    planning = super(TmsTravelPlanning, self).create(values)
    if not planning.operating_unit_id.planning_sequence_id:
    raise ValidationError(_(
    'You need to define the sequence for planning in base %s' %
    planning.operating_unit_id.name
    ))
    sequence = planning.operating_unit_id.planning_sequence_id
    planning.name = sequence.next_by_id()
    print(str(values['num_vehicule_dispo']))
    print(str(values['num_chauffeur_dispo']))
    return planning


    tms_travel.xml



        <?xml version="1.0" encoding="UTF-8"?>
    <odoo>
    <record id="view_tms_travel_tree" model="ir.ui.view">
    <field name="name">tms.travel.tree</field>
    <field name="model">tms.travel</field>
    <field name="priority">1</field>
    <field name="arch" type="xml">
    <tree>
    <field name="name"/>
    <field name="date"/>
    <field name="departure_id"/>
    <field name="arrival_id"/>
    <field name="state"/>
    <button groups="tms.group_traffic,tms.group_expenses" icon="fa-thumbs-up" name="action_progress" states="draft" string="Dispatch Travel" type="object"/>
    <button groups="tms.group_traffic,tms.group_expenses" icon="fa-check-square" name="action_end" states="progress" string="End Travel" type="object"/>
    </tree>
    </field>
    </record>
    </odoo>









    share|improve this question



























      1












      1








      1







      I use odoo 10 and I created a custom module to plan trips. I create a view for the plans in which I will select the list of my travels. My problem now is how I can get the Start and Destination fields of each trip insert in this view knowing that the field that displays the list of trips is travel_ids = fields.Many2many ('tms.travel', copy = False, string = 'Travels'). I try a lot but no result. Any idea for help please ??



      enter image description here



      tms_travel_planning.xml



      <?xml version="1.0" encoding="UTF-8"?>
      <odoo>
      <data>

      <record id="view_tms_travel_planning_form" model="ir.ui.view">
      <field name="name">view.tms.travel.planning.form</field>
      <field name="model">tms.planning</field>
      <field name="arch" type="xml">
      <form string="Plannification des voyage">
      <header>
      <field name="state" statusbar_visible="draft,approved,confirmed" widget="statusbar"/>
      </header>
      <sheet>
      <div class="oe_title">
      <h1>
      <label class="oe_inline" style="font-size:30px;" string="Plannification - " attrs="{'invisible':[('name','=', False)]}"/>
      <field name="name" readonly="1"/>
      </h1>
      </div>
      <group>
      <group>

      <field name="datetime"/>
      <field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>
      </group>

      <group>
      <field name="num_vehicule_dispo"/>
      <field name="num_chauffeur_dispo"/>

      </group>
      </group>
      <notebook colspan="1">
      <page string="Les voyages à planifier">
      <separator coslpan="4" string="Voyages"/>
      <!--<field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>-->
      <field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" colspan="4"
      domain="[('state','not in',('cancel','closed'))]" name="travel_ids" nolabel="1"/>
      <separator coslpan="4" string="Véhicules"/>
      <field colspan="4" name="fleet_ids" nolabel="1"/>
      <separator coslpan="4" string="Conducteurs"/>
      <field colspan="4" name="employee_ids" nolabel="1"/>

      </page>

      </notebook>
      </sheet>
      </form>
      </field>
      </record>
      </data>
      </odoo>


      tms_travel_planning.py



       # -*- coding: utf-8 -*-

      from odoo import _, api, fields, models
      from odoo.exceptions import ValidationError


      class TmsTravelPlanning(models.Model):
      _name = 'tms.planning'

      name = fields.Char('Num du plannification')
      operating_unit_id = fields.Many2one(
      'operating.unit', string='Operating Unit', required=True)
      id_planning=fields.Integer(string="Numéro du plannification")
      datetime=fields.Date(string="Date")
      num_vehicule_dispo=fields.Integer(string="Nombre de véhicule disponible")
      num_chauffeur_dispo=fields.Integer(string="Nombre de chauffeur disponible")
      tms
      fleet_ids = fields.Many2many('fleet.vehicle', copy=False, string='Véhicules')
      employee_ids = fields.Many2many('hr.employee', copy=False, string='Conducteurs')

      state = fields.Selection([
      ('draft', 'Pending'),
      ('approved', 'Approved'),
      ('confirmed', 'Confirmed'),
      ('cancel', 'Cancelled')], readonly=True,
      help="Gives the state of the Waybill.",
      default='draft')

      @api.model
      def create(self, values):
      planning = super(TmsTravelPlanning, self).create(values)
      if not planning.operating_unit_id.planning_sequence_id:
      raise ValidationError(_(
      'You need to define the sequence for planning in base %s' %
      planning.operating_unit_id.name
      ))
      sequence = planning.operating_unit_id.planning_sequence_id
      planning.name = sequence.next_by_id()
      print(str(values['num_vehicule_dispo']))
      print(str(values['num_chauffeur_dispo']))
      return planning


      tms_travel.xml



          <?xml version="1.0" encoding="UTF-8"?>
      <odoo>
      <record id="view_tms_travel_tree" model="ir.ui.view">
      <field name="name">tms.travel.tree</field>
      <field name="model">tms.travel</field>
      <field name="priority">1</field>
      <field name="arch" type="xml">
      <tree>
      <field name="name"/>
      <field name="date"/>
      <field name="departure_id"/>
      <field name="arrival_id"/>
      <field name="state"/>
      <button groups="tms.group_traffic,tms.group_expenses" icon="fa-thumbs-up" name="action_progress" states="draft" string="Dispatch Travel" type="object"/>
      <button groups="tms.group_traffic,tms.group_expenses" icon="fa-check-square" name="action_end" states="progress" string="End Travel" type="object"/>
      </tree>
      </field>
      </record>
      </odoo>









      share|improve this question















      I use odoo 10 and I created a custom module to plan trips. I create a view for the plans in which I will select the list of my travels. My problem now is how I can get the Start and Destination fields of each trip insert in this view knowing that the field that displays the list of trips is travel_ids = fields.Many2many ('tms.travel', copy = False, string = 'Travels'). I try a lot but no result. Any idea for help please ??



      enter image description here



      tms_travel_planning.xml



      <?xml version="1.0" encoding="UTF-8"?>
      <odoo>
      <data>

      <record id="view_tms_travel_planning_form" model="ir.ui.view">
      <field name="name">view.tms.travel.planning.form</field>
      <field name="model">tms.planning</field>
      <field name="arch" type="xml">
      <form string="Plannification des voyage">
      <header>
      <field name="state" statusbar_visible="draft,approved,confirmed" widget="statusbar"/>
      </header>
      <sheet>
      <div class="oe_title">
      <h1>
      <label class="oe_inline" style="font-size:30px;" string="Plannification - " attrs="{'invisible':[('name','=', False)]}"/>
      <field name="name" readonly="1"/>
      </h1>
      </div>
      <group>
      <group>

      <field name="datetime"/>
      <field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>
      </group>

      <group>
      <field name="num_vehicule_dispo"/>
      <field name="num_chauffeur_dispo"/>

      </group>
      </group>
      <notebook colspan="1">
      <page string="Les voyages à planifier">
      <separator coslpan="4" string="Voyages"/>
      <!--<field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" name="operating_unit_id"/>-->
      <field attrs="{'readonly':[('state','in',('confirmed', 'cancel'))]}" colspan="4"
      domain="[('state','not in',('cancel','closed'))]" name="travel_ids" nolabel="1"/>
      <separator coslpan="4" string="Véhicules"/>
      <field colspan="4" name="fleet_ids" nolabel="1"/>
      <separator coslpan="4" string="Conducteurs"/>
      <field colspan="4" name="employee_ids" nolabel="1"/>

      </page>

      </notebook>
      </sheet>
      </form>
      </field>
      </record>
      </data>
      </odoo>


      tms_travel_planning.py



       # -*- coding: utf-8 -*-

      from odoo import _, api, fields, models
      from odoo.exceptions import ValidationError


      class TmsTravelPlanning(models.Model):
      _name = 'tms.planning'

      name = fields.Char('Num du plannification')
      operating_unit_id = fields.Many2one(
      'operating.unit', string='Operating Unit', required=True)
      id_planning=fields.Integer(string="Numéro du plannification")
      datetime=fields.Date(string="Date")
      num_vehicule_dispo=fields.Integer(string="Nombre de véhicule disponible")
      num_chauffeur_dispo=fields.Integer(string="Nombre de chauffeur disponible")
      tms
      fleet_ids = fields.Many2many('fleet.vehicle', copy=False, string='Véhicules')
      employee_ids = fields.Many2many('hr.employee', copy=False, string='Conducteurs')

      state = fields.Selection([
      ('draft', 'Pending'),
      ('approved', 'Approved'),
      ('confirmed', 'Confirmed'),
      ('cancel', 'Cancelled')], readonly=True,
      help="Gives the state of the Waybill.",
      default='draft')

      @api.model
      def create(self, values):
      planning = super(TmsTravelPlanning, self).create(values)
      if not planning.operating_unit_id.planning_sequence_id:
      raise ValidationError(_(
      'You need to define the sequence for planning in base %s' %
      planning.operating_unit_id.name
      ))
      sequence = planning.operating_unit_id.planning_sequence_id
      planning.name = sequence.next_by_id()
      print(str(values['num_vehicule_dispo']))
      print(str(values['num_chauffeur_dispo']))
      return planning


      tms_travel.xml



          <?xml version="1.0" encoding="UTF-8"?>
      <odoo>
      <record id="view_tms_travel_tree" model="ir.ui.view">
      <field name="name">tms.travel.tree</field>
      <field name="model">tms.travel</field>
      <field name="priority">1</field>
      <field name="arch" type="xml">
      <tree>
      <field name="name"/>
      <field name="date"/>
      <field name="departure_id"/>
      <field name="arrival_id"/>
      <field name="state"/>
      <button groups="tms.group_traffic,tms.group_expenses" icon="fa-thumbs-up" name="action_progress" states="draft" string="Dispatch Travel" type="object"/>
      <button groups="tms.group_traffic,tms.group_expenses" icon="fa-check-square" name="action_end" states="progress" string="End Travel" type="object"/>
      </tree>
      </field>
      </record>
      </odoo>






      python-2.7 odoo-10






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Nov 21 at 15:02

























      asked Nov 21 at 10:13









      Dhouha

      949




      949
























          1 Answer
          1






          active

          oldest

          votes


















          0














          Ok, you are missing some information in your many2many relationship. here is what you need.



          field_name = fields.Manmy2many('related.model', 'relational_table', 'current_model_id', 'related_model_id', string='other information')


          and usually I put the inverse on the related model ex:



          (On the hr.holidays model)



          payslip_ids = fields.Many2many('hr.payslip', 'hr_payslip_holiday_rel', 'holiday_id', 'payslip_id', ...)


          (On the hr.payslip model)



          holiday_ids - fields.Many2many('hr.holidays', 'hr_payslip_holiday_rel', 'payslip_id', 'holiday_id', ...)


          Then at some point you need to add one of the ids to the other model for ex:



          holiday.payslip_ids |= current_payslip_id





          share|improve this answer





















            Your Answer






            StackExchange.ifUsing("editor", function () {
            StackExchange.using("externalEditor", function () {
            StackExchange.using("snippets", function () {
            StackExchange.snippets.init();
            });
            });
            }, "code-snippets");

            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "1"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53409732%2fhow-to-get-field-value-from-another-many2many-field%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            Ok, you are missing some information in your many2many relationship. here is what you need.



            field_name = fields.Manmy2many('related.model', 'relational_table', 'current_model_id', 'related_model_id', string='other information')


            and usually I put the inverse on the related model ex:



            (On the hr.holidays model)



            payslip_ids = fields.Many2many('hr.payslip', 'hr_payslip_holiday_rel', 'holiday_id', 'payslip_id', ...)


            (On the hr.payslip model)



            holiday_ids - fields.Many2many('hr.holidays', 'hr_payslip_holiday_rel', 'payslip_id', 'holiday_id', ...)


            Then at some point you need to add one of the ids to the other model for ex:



            holiday.payslip_ids |= current_payslip_id





            share|improve this answer


























              0














              Ok, you are missing some information in your many2many relationship. here is what you need.



              field_name = fields.Manmy2many('related.model', 'relational_table', 'current_model_id', 'related_model_id', string='other information')


              and usually I put the inverse on the related model ex:



              (On the hr.holidays model)



              payslip_ids = fields.Many2many('hr.payslip', 'hr_payslip_holiday_rel', 'holiday_id', 'payslip_id', ...)


              (On the hr.payslip model)



              holiday_ids - fields.Many2many('hr.holidays', 'hr_payslip_holiday_rel', 'payslip_id', 'holiday_id', ...)


              Then at some point you need to add one of the ids to the other model for ex:



              holiday.payslip_ids |= current_payslip_id





              share|improve this answer
























                0












                0








                0






                Ok, you are missing some information in your many2many relationship. here is what you need.



                field_name = fields.Manmy2many('related.model', 'relational_table', 'current_model_id', 'related_model_id', string='other information')


                and usually I put the inverse on the related model ex:



                (On the hr.holidays model)



                payslip_ids = fields.Many2many('hr.payslip', 'hr_payslip_holiday_rel', 'holiday_id', 'payslip_id', ...)


                (On the hr.payslip model)



                holiday_ids - fields.Many2many('hr.holidays', 'hr_payslip_holiday_rel', 'payslip_id', 'holiday_id', ...)


                Then at some point you need to add one of the ids to the other model for ex:



                holiday.payslip_ids |= current_payslip_id





                share|improve this answer












                Ok, you are missing some information in your many2many relationship. here is what you need.



                field_name = fields.Manmy2many('related.model', 'relational_table', 'current_model_id', 'related_model_id', string='other information')


                and usually I put the inverse on the related model ex:



                (On the hr.holidays model)



                payslip_ids = fields.Many2many('hr.payslip', 'hr_payslip_holiday_rel', 'holiday_id', 'payslip_id', ...)


                (On the hr.payslip model)



                holiday_ids - fields.Many2many('hr.holidays', 'hr_payslip_holiday_rel', 'payslip_id', 'holiday_id', ...)


                Then at some point you need to add one of the ids to the other model for ex:



                holiday.payslip_ids |= current_payslip_id






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Nov 28 at 13:32









                Cristin Meravi

                215




                215






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.





                    Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                    Please pay close attention to the following guidance:


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53409732%2fhow-to-get-field-value-from-another-many2many-field%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    404 Error Contact Form 7 ajax form submitting

                    How to know if a Active Directory user can login interactively

                    TypeError: fit_transform() missing 1 required positional argument: 'X'