Reviewers: ,


Please review this at http://codereview.tryton.org/229003/

Affected files:
  M move.xml
  M shipment.xml


Index: move.xml
===================================================================

--- a/move.xml
+++ b/move.xml
@@ -41,6 +41,7 @@
         <record model="ir.ui.view" id="move_view_tree">
             <field name="model">stock.move</field>
             <field name="type">tree</field>
+            <field name="priority" eval="10"/>
             <field name="arch" type="xml">
                 <![CDATA[
                     <tree string="Moves">
@@ -49,6 +50,7 @@
                         <field name="to_location"/>
                         <field name="quantity"/>
                         <field name="uom"/>
+                        <field name="planned_date"/>
                         <field name="state"/>
                         <field name="unit_digits" tree_invisible="1"/>
                         <field name="create_date" tree_invisible="1"/>
@@ -56,6 +58,23 @@
                 ]]>
             </field>
         </record>
+
+        <record model="ir.ui.view" id="move_view_tree_simple">
+            <field name="model">stock.move</field>
+            <field name="type">tree</field>
+            <field name="priority" eval="20"/>
+            <field name="arch" type="xml">
+                <![CDATA[
+                <tree string="Moves" fill="1">
+                    <field name="product"/>
+                    <field name="quantity"/>
+                    <field name="uom"/>
+                    <field name="unit_digits" tree_invisible="1"/>
+                </tree>
+                ]]>
+            </field>
+        </record>
+
         <record model="ir.action.act_window" id="act_move_form">
             <field name="name">Moves</field>
             <field name="res_model">stock.move</field>

Index: shipment.xml
===================================================================

--- a/shipment.xml
+++ b/shipment.xml
@@ -29,18 +29,7 @@
                         <field name="warehouse"/>
                         <notebook colspan="6">
<page string="Incoming Moves" id="incoming_moves">
-                                <field name="incoming_moves" colspan="4">
-                                    <tree string="Moves">
-                                        <field name="product"/>
-                                        <field name="from_location"/>
-                                        <field name="to_location"/>
-                                        <field name="quantity"/>
-                                        <field name="uom"/>
-                                        <field name="planned_date"/>
-                                        <field name="state"/>
- <field name="unit_digits" tree_invisible="1"/>
-                                    </tree>
-                                </field>
+                                <field name="incoming_moves" colspan="4"/>
                             </page>
<page string="Inventory Moves" id="inventory_moves">
                                 <field name="inventory_moves" colspan="4"/>
@@ -249,14 +238,8 @@
<image name="tryton-dialog-warning" xexpand="0" xfill="0"/>
                     <separator string="Unable to assign those products:"
                         id="unable"/>
-                    <field name="moves" colspan="2">
-                        <tree string="Moves" fill="1">
-                            <field name="product"/>
-                            <field name="quantity"/>
-                            <field name="uom"/>
-                            <field name="unit_digits" tree_invisible="1"/>
-                        </tree>
-                    </field>
+                    <field name="moves" colspan="2"
+                        view_ids="stock.move_view_tree_simple"/>
                 </form>
                 ]]>
             </field>
@@ -453,14 +436,8 @@
<image name="tryton-dialog-warning" xexpand="0" xfill="0"/>
                     <separator string="Unable to assign those products:"
                         id="unable"/>
-                    <field name="inventory_moves" colspan="2">
-                        <tree string="Inventory Moves" fill="1">
-                            <field name="product"/>
-                            <field name="quantity"/>
-                            <field name="uom"/>
-                            <field name="unit_digits" tree_invisible="1"/>
-                        </tree>
-                    </field>
+                    <field name="inventory_moves" colspan="2"
+                        view_ids="stock.move_view_tree_simple"/>
                 </form>
                 ]]>
             </field>
@@ -632,14 +609,8 @@
<image name="tryton-dialog-warning" xexpand="0" xfill="0"/>
                     <separator string="Unable to assign those products:"
                         id="unable"/>
-                    <field name="moves" colspan="2">
-                        <tree string="Moves"  fill="1">
-                            <field name="product"/>
-                            <field name="quantity"/>
-                            <field name="uom"/>
-                            <field name="unit_digits" tree_invisible="1"/>
-                        </tree>
-                    </field>
+                    <field name="moves" colspan="2"
+                        view_ids="stock.move_view_tree_simple"/>
                 </form>
                 ]]>
             </field>
@@ -670,18 +641,7 @@
                         <field name="warehouse"/>
                         <notebook colspan="6">
<page string="Incoming Moves" id="incoming_moves">
-                                <field name="incoming_moves" colspan="4">
-                                    <tree string="Moves">
-                                        <field name="product"/>
-                                        <field name="from_location"/>
-                                        <field name="to_location"/>
-                                        <field name="quantity"/>
-                                        <field name="uom"/>
-                                        <field name="planned_date"/>
-                                        <field name="state"/>
- <field name="unit_digits" tree_invisible="1"/>
-                                    </tree>
-                                </field>
+                                <field name="incoming_moves" colspan="4"/>
                             </page>
<page string="Inventory Moves" id="inventory_moves">
                                 <field name="inventory_moves" colspan="4"/>



--
[email protected] mailing list

Reply via email to