Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

1

How to import two records when each one needs the other?

By
Pascal Tremblay
on 4/3/15, 8:38 AM 515 views

Hello again guys!

I try to import these two records. The first record needs the second one. The second record needs the first one...

How to deal with this? Should I import one of these records in two shots?


<record id="stock_lapagept.pick_receipts_pt" model="stock.picking.type">

      <field name="name">Receipts - PT picking - 2</field>

      <field name="code">incoming</field>

      <field name="sequence_id" ref="stock_lapagept.pick_seq_receipts_pt" />

      <field name="warehouse_id" ref="stock_lapagept.warehouse_pt" />

      <field name="return_picking_type_id" ref="stock_lapagept.pick_delivery_orders_pt" />

      <field name="default_location_src_id" ref="stock_lapagept.suppliers_pt" />

      <field name="default_location_dest_id" ref="stock_lapagept.etagere_sous_sol_pt" />

</record>

<record id="stock_lapagept.pick_delivery_orders_pt" model="stock.picking.type">

      <field name="name">Delivery orders - PT picking - 2</field>

      <field name="code">outgoing</field>

      <field name="sequence_id" ref="stock_lapagept.pick_seq_delivery_orders_pt" />

      <field name="warehouse_id" ref="stock_lapagept.warehouse_pt" />

      <field name="return_picking_type_id" ref="stock_lapagept.pick_receipts_pt" />

      <field name="default_location_src_id" ref="stock_lapagept.etagere_sous_sol_pt" />

      <field name="default_location_dest_id" ref="stock_lapagept.customers_pt" />

</record>


I look forward to seeing your answer... Interesting case here.

Thanks


2

Pascal Tremblay

--Pascal Tremblay--
1312
| 5 2 7
Alma, Canada
--Pascal Tremblay--


Pascal Tremblay
On 4/3/15, 9:14 AM

This way works. BUT IS THIS A GOOD PRACTICE to separate a record like this in two shot?????


<record id="stock_lapagept.pick_receipts_pt" model="stock.picking.type">

      <field name="name">Receipts - PT picking - 2</field>

      <field name="code">incoming</field>

      <field name="sequence_id" ref="stock_lapagept.pick_seq_receipts_pt" />

      <field name="warehouse_id" ref="stock_lapagept.warehouse_pt" />

      <field name="default_location_src_id" ref="stock_lapagept.suppliers_pt" />

      <field name="default_location_dest_id" ref="stock_lapagept.etagere_sous_sol_pt" />

</record>

<record id="stock_lapagept.pick_delivery_orders_pt" model="stock.picking.type">

      <field name="name">Delivery orders - PT picking - 2</field>

      <field name="code">outgoing</field>

      <field name="sequence_id" ref="stock_lapagept.pick_seq_delivery_orders_pt" />

      <field name="warehouse_id" ref="stock_lapagept.warehouse_pt" />

      <field name="return_picking_type_id" ref="stock_lapagept.pick_receipts_pt" />

      <field name="default_location_src_id" ref="stock_lapagept.etagere_sous_sol_pt" />

      <field name="default_location_dest_id" ref="stock_lapagept.customers_pt" />

</record>

<record id="stock_lapagept.pick_receipts_pt" model="stock.picking.type">

      <field name="return_picking_type_id" ref="stock_lapagept.pick_delivery_orders_pt" />

</record>

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 4/3/15, 8:38 AM
Seen: 515 times
Last updated: 4/3/15, 4:56 PM