[IMP] stock: onboarding (display improvements)
This commit is contained in:
committed by
Richard Mathot
parent
c93815c805
commit
52c3b52bf0
@@ -35,7 +35,7 @@
|
||||
</header>
|
||||
<sheet>
|
||||
<div class="oe_right oe_button_box" name="button_box">
|
||||
<button name="do_view_procurements" string="Group's Procurements" type="object"/>
|
||||
<button name="do_view_procurements" class="oe_stat_button" icon="fa-bars" string="Group's Procurements" type="object"/>
|
||||
</div>
|
||||
<group>
|
||||
<group>
|
||||
@@ -60,7 +60,6 @@
|
||||
</group>
|
||||
<notebook>
|
||||
<page string="Notes">
|
||||
<label for="name" class="oe_edit_only"/>
|
||||
<field name="name" placeholder="External note..."/>
|
||||
</page>
|
||||
<page string="Extra Information">
|
||||
|
||||
@@ -60,11 +60,11 @@
|
||||
<div class="oe_title" style="width: 390px;">
|
||||
<label class="oe_edit_only" for="name" string="Product Name"/>
|
||||
<h1><field name="name" class="oe_inline"/></h1>
|
||||
</div>
|
||||
<div class="oe_left" name="options" groups="base.group_user">
|
||||
<div>
|
||||
<field name="sale_ok"/>
|
||||
<label for="sale_ok"/>
|
||||
<div name="options" groups="base.group_user">
|
||||
<div>
|
||||
<field name="sale_ok"/>
|
||||
<label for="sale_ok"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -126,7 +126,6 @@
|
||||
<group groups="product.group_uos" string="Unit of Measure">
|
||||
<field name="uos_id"/>
|
||||
<field name="uos_coeff"/>
|
||||
<field name="mes_type"/>
|
||||
</group>
|
||||
</group>
|
||||
<group name="website_and_pos" col="2">
|
||||
|
||||
@@ -234,6 +234,11 @@ class product_product(osv.osv):
|
||||
'orderpoint_ids': fields.one2many('stock.warehouse.orderpoint', 'product_id', 'Minimum Stock Rules'),
|
||||
}
|
||||
|
||||
_defaults = {
|
||||
# Dirty hack to avoid empty stat button in create view
|
||||
'qty_available_text': lambda *x: '0.0 On Hand',
|
||||
}
|
||||
|
||||
def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
|
||||
res = super(product_product,self).fields_view_get(cr, uid, view_id, view_type, context, toolbar=toolbar, submenu=submenu)
|
||||
if context is None:
|
||||
@@ -381,6 +386,8 @@ class product_template(osv.osv):
|
||||
|
||||
_defaults = {
|
||||
'sale_delay': 7,
|
||||
# Dirty hack to avoid empty stat button in create view
|
||||
'qty_available_text': lambda *x: '0.0 On Hand',
|
||||
}
|
||||
|
||||
def action_view_routes(self, cr, uid, ids, context=None):
|
||||
|
||||
@@ -635,7 +635,7 @@ class stock_quant(osv.osv):
|
||||
class stock_picking(osv.osv):
|
||||
_name = "stock.picking"
|
||||
_inherit = ['mail.thread']
|
||||
_description = "Picking List"
|
||||
_description = "Transfer"
|
||||
_order = "priority desc, date asc, id desc"
|
||||
|
||||
def _set_min_date(self, cr, uid, id, field, value, arg, context=None):
|
||||
@@ -1685,7 +1685,7 @@ class stock_move(osv.osv):
|
||||
'move_dest_id': fields.many2one('stock.move', 'Destination Move', help="Optional: next stock move when chaining them", select=True, copy=False),
|
||||
'move_orig_ids': fields.one2many('stock.move', 'move_dest_id', 'Original Move', help="Optional: previous stock move when chaining them", select=True),
|
||||
|
||||
'picking_id': fields.many2one('stock.picking', 'Reference', select=True, states={'done': [('readonly', True)]}),
|
||||
'picking_id': fields.many2one('stock.picking', 'Reference Stock Move', select=True, states={'done': [('readonly', True)]}),
|
||||
'note': fields.text('Notes'),
|
||||
'state': fields.selection([('draft', 'New'),
|
||||
('cancel', 'Cancelled'),
|
||||
@@ -1705,7 +1705,7 @@ class stock_move(osv.osv):
|
||||
'company_id': fields.many2one('res.company', 'Company', required=True, select=True),
|
||||
'split_from': fields.many2one('stock.move', string="Move Split From", help="Technical field used to track the origin of a split move, which can be useful in case of debug", copy=False),
|
||||
'backorder_id': fields.related('picking_id', 'backorder_id', type='many2one', relation="stock.picking", string="Back Order of", select=True),
|
||||
'origin': fields.char("Source"),
|
||||
'origin': fields.char("Source Document"),
|
||||
'procure_method': fields.selection([('make_to_stock', 'Default: Take From Stock'), ('make_to_order', 'Advanced: Apply Procurement Rules')], 'Supply Method', required=True,
|
||||
help="""By default, the system will take from the stock in the source location and passively wait for availability. The other possibility allows you to directly create a procurement on the source location (and thus ignore its current stock) to gather products. If we want to chain moves and have this one to wait for the previous, this second option should be chosen."""),
|
||||
|
||||
|
||||
+28
-21
@@ -338,26 +338,31 @@
|
||||
<h2><field name="location_id"/></h2>
|
||||
|
||||
<group>
|
||||
<group string="Additional Information">
|
||||
<field name="usage"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
|
||||
<field name="scrap_location"/>
|
||||
<field name="active"/>
|
||||
</group>
|
||||
<group string="Localization" name="localization">
|
||||
<field name="posx"/>
|
||||
<field name="posy"/>
|
||||
<field name="posz"/>
|
||||
<field name="loc_barcode"/>
|
||||
</group>
|
||||
<group string="Logistics" groups="stock.group_adv_location">
|
||||
<field name="removal_strategy_id" options="{'no_create': True}"/>
|
||||
<field name="putaway_strategy_id"/>
|
||||
</group>
|
||||
<div>
|
||||
<group string="Additional Information">
|
||||
<field name="usage"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
|
||||
<field name="scrap_location"/>
|
||||
<field name="active"/>
|
||||
</group>
|
||||
</div>
|
||||
<div>
|
||||
<group string="Localization" name="localization">
|
||||
<field name="posx"/>
|
||||
<field name="posy"/>
|
||||
<field name="posz"/>
|
||||
<field name="loc_barcode"/>
|
||||
</group>
|
||||
</div>
|
||||
<div>
|
||||
<group string="Logistics" groups="stock.group_adv_location">
|
||||
<field name="removal_strategy_id" options="{'no_create': True}"/>
|
||||
<field name="putaway_strategy_id"/>
|
||||
</group>
|
||||
</div>
|
||||
</group>
|
||||
<separator string="Additional Information"/>
|
||||
<field name="comment"/>
|
||||
<field name="comment" placeholder="External note..."/>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
@@ -1046,7 +1051,9 @@
|
||||
<field name="move_dest_id" groups="base.group_no_one" readonly="1"/>
|
||||
</group>
|
||||
<group name="quants_grp" string="Reserved Quants" colspan="4" groups="base.group_no_one">
|
||||
<field name="reserved_quant_ids"/>
|
||||
<div>
|
||||
<field name="reserved_quant_ids"/>
|
||||
</div>
|
||||
</group>
|
||||
</group>
|
||||
</sheet>
|
||||
@@ -1552,7 +1559,7 @@
|
||||
</group>
|
||||
</xpath>
|
||||
<xpath expr="//div[@name='button_box']" position="inside">
|
||||
<button name="do_view_pickings" string="Group's Pickings" type="object"/>
|
||||
<button name="do_view_pickings" class="oe_stat_button" icon="fa-bars" string="Group's Pickings" type="object"/>
|
||||
</xpath>
|
||||
<xpath expr="//field[@name='rule_id']" position="replace">
|
||||
<field name="rule_id" domain="['|', ('location_id', '=', False), ('location_id', '=', location_id)]"/>
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<label for="qty"/>
|
||||
<div>
|
||||
<field name="qty" class="oe_inline"/>
|
||||
<field name="uom_id" groups="product.group_uom"/>
|
||||
<field name="uom_id" groups="product.group_uom" class="oe_inline"/>
|
||||
</div>
|
||||
<field name="date_planned"/>
|
||||
</group>
|
||||
|
||||
Reference in New Issue
Block a user