openobject-italia-core-devs team mailing list archive
-
openobject-italia-core-devs team
-
Mailing list archive
-
Message #01315
[Merge] lp:~elbati/openobject-italia/7-fix-1169140 into lp:openobject-italia/7.0
Lorenzo Battistini - Agile BG has proposed merging lp:~elbati/openobject-italia/7-fix-1169140 into lp:openobject-italia/7.0.
Requested reviews:
OpenERP Italia core devs (openobject-italia-core-devs)
Related bugs:
Bug #1169140 in OpenERP Italia: "errore generazione numero DDT"
https://bugs.launchpad.net/openobject-italia/+bug/1169140
For more details, see:
https://code.launchpad.net/~elbati/openobject-italia/7-fix-1169140/+merge/162031
--
https://code.launchpad.net/~elbati/openobject-italia/7-fix-1169140/+merge/162031
Your team OpenERP Italia core devs is requested to review the proposed merge of lp:~elbati/openobject-italia/7-fix-1169140 into lp:openobject-italia/7.0.
=== modified file 'l10n_it_sale/stock/picking.py'
--- l10n_it_sale/stock/picking.py 2013-03-14 11:11:29 +0000
+++ l10n_it_sale/stock/picking.py 2013-05-02 06:33:28 +0000
@@ -34,7 +34,6 @@
'name':fields.char('Carriage Condition', size=64, required=True, readonly=False),
'note': fields.text('Note'),
}
-stock_picking_carriage_condition()
class stock_picking_goods_description(orm.Model):
"""
@@ -47,8 +46,6 @@
'name':fields.char('Description of Goods', size=64, required=True, readonly=False),
'note': fields.text('Note'),
}
-stock_picking_goods_description()
-
class stock_picking_reason(orm.Model):
"""
@@ -61,7 +58,6 @@
'name':fields.char('Reason For Transportation', size=64, required=True, readonly=False),
'note': fields.text('Note'),
}
-stock_picking_reason()
class stock_picking(orm.Model):
_inherit = "stock.picking.out"
@@ -103,4 +99,16 @@
default.update({'ddt_number': ''})
return super(stock_picking, self).copy(cr, uid, id, default, context)
-stock_picking()
+# Redefinition of the new fields in order to update the model stock.picking in the orm
+# FIXME: this is a temporary workaround because of a framework bug (ref: lp996816).
+# It should be removed as soon as
+# the bug is fixed
+class stock_picking(orm.Model):
+ _inherit = 'stock.picking'
+ _columns = {
+ 'carriage_condition_id': fields.many2one('stock.picking.carriage_condition', 'Carriage condition'),
+ 'goods_description_id': fields.many2one('stock.picking.goods_description', 'Description of goods'),
+ 'transportation_reason_id': fields.many2one('stock.picking.transportation_reason', 'Reason for transportation'),
+ 'ddt_number': fields.char('DDT', size=64),
+ 'ddt_date': fields.date('DDT date'),
+ }
=== modified file 'l10n_it_sale/stock/picking_view.xml'
--- l10n_it_sale/stock/picking_view.xml 2013-03-13 08:21:42 +0000
+++ l10n_it_sale/stock/picking_view.xml 2013-05-02 06:33:28 +0000
@@ -4,7 +4,7 @@
<record id="stock_picking_form_ddt_inherit" model="ir.ui.view">
<field name="name">stock.picking.form.ddt.inherit</field>
<field name="model">stock.picking.out</field>
- <field name="inherit_id" ref="stock.view_picking_form"/>
+ <field name="inherit_id" ref="stock.view_picking_out_form"/>
<field name="arch" type="xml">
<field name="move_type" position="after">
<field name="goods_description_id"/>
@@ -18,7 +18,7 @@
<record id="stock_picking_tree_ddt_inherit" model="ir.ui.view">
<field name="name">stock.picking.tree.ddt.inherit</field>
<field name="model">stock.picking.out</field>
- <field name="inherit_id" ref="stock.vpicktree"/>
+ <field name="inherit_id" ref="stock.view_picking_out_tree"/>
<field name="arch" type="xml">
<field name="name" position="before">
<field name="ddt_number"/>
@@ -30,7 +30,7 @@
<record id="stock_view_picking_form_ddt" model="ir.ui.view">
<field name="name">stock.view.picking.form.ddt</field>
<field name="model">stock.picking.out</field>
- <field name="inherit_id" ref="stock.view_picking_form"/>
+ <field name="inherit_id" ref="stock.view_picking_out_form"/>
<field name="arch" type="xml">
<field name="backorder_id" position="after">
<field name="ddt_number" readonly="1"/>
Follow ups