[IMP] stock: define stock.location form view in a sheet

Related Task: 1935522

closes odoo/odoo#30785

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
This commit is contained in:
Jinal Patel
2019-05-06 09:14:24 +00:00
committed by William Henrotin
parent 1414470d34
commit 4cd8fd7228
+40 -38
View File
@@ -13,46 +13,48 @@
<field name="model">stock.location</field>
<field name="arch" type="xml">
<form string="Stock Location" create="false">
<div class="oe_button_box" name="button_box">
<button string="Putaway Rules"
class="oe_stat_button"
icon="fa-random" name="%(location_open_putaway)d" type="action"
groups="stock.group_stock_multi_locations"/>
<button string="Current Stock"
class="oe_stat_button"
icon="fa-building-o" name="%(location_open_quants)d" type="action"/>
<button string="Products"
class="oe_stat_button"
icon="fa-filter" name="%(act_product_location_open)d" type="action"
context="{'location_id': active_id}"
/>
<button name="toggle_active" type="object" class="oe_stat_button" icon="fa-archive">
<field name="active" widget="boolean_button" options='{"terminology": "archive"}'/>
</button>
</div>
<label for="name" class="oe_edit_only"/>
<h1><field name="name"/></h1>
<label for="location_id" class="oe_edit_only"/>
<h2><field name="location_id" options="{'no_create': True}"/></h2>
<sheet>
<div class="oe_button_box" name="button_box">
<button string="Putaway Rules"
class="oe_stat_button"
icon="fa-random" name="%(location_open_putaway)d" type="action"
groups="stock.group_stock_multi_locations"/>
<button string="Current Stock"
class="oe_stat_button"
icon="fa-building-o" name="%(location_open_quants)d" type="action"/>
<button string="Products"
class="oe_stat_button"
icon="fa-filter" name="%(act_product_location_open)d" type="action"
context="{'location_id': active_id}"
/>
<button name="toggle_active" type="object" class="oe_stat_button" icon="fa-archive">
<field name="active" widget="boolean_button" options='{"terminology": "archive"}'/>
</button>
</div>
<label for="name" class="oe_edit_only"/>
<h1><field name="name"/></h1>
<label for="location_id" class="oe_edit_only"/>
<h2><field name="location_id" options="{'no_create': True}"/></h2>
<group>
<group string="Additional Information">
<field name="usage"/>
<field name="company_id" groups="base.group_multi_company" options="{'no_create': True}"/>
<field name="scrap_location" attrs="{'invisible': [('usage', 'not in', ('inventory', 'internal'))]}"/>
<field name="return_location"/>
<group>
<group string="Additional Information">
<field name="usage"/>
<field name="company_id" groups="base.group_multi_company" options="{'no_create': True}"/>
<field name="scrap_location" attrs="{'invisible': [('usage', 'not in', ('inventory', 'internal'))]}"/>
<field name="return_location"/>
</group>
<group string="Localization" name="localization">
<field name="posx"/>
<field name="posy"/>
<field name="posz"/>
<field name="barcode"/>
</group>
<group string="Logistics" groups="stock.group_adv_location">
<field name="removal_strategy_id" options="{'no_create': True}"/>
</group>
</group>
<group string="Localization" name="localization">
<field name="posx"/>
<field name="posy"/>
<field name="posz"/>
<field name="barcode"/>
</group>
<group string="Logistics" groups="stock.group_adv_location">
<field name="removal_strategy_id" options="{'no_create': True}"/>
</group>
</group>
<field name="comment" placeholder="External note..."/>
<field name="comment" placeholder="External note..."/>
</sheet>
</form>
</field>
</record>