diff --git a/addons/account/product_view.xml b/addons/account/product_view.xml index a70fdf38f3c..44d53839700 100644 --- a/addons/account/product_view.xml +++ b/addons/account/product_view.xml @@ -4,6 +4,7 @@ product.normal.form.inherit product.product + 5 diff --git a/addons/account_asset/account_asset.py b/addons/account_asset/account_asset.py index a44226e76c8..3190801764b 100644 --- a/addons/account_asset/account_asset.py +++ b/addons/account_asset/account_asset.py @@ -41,8 +41,8 @@ class account_asset_category(osv.osv): 'company_id': fields.many2one('res.company', 'Company', required=True), 'method': fields.selection([('linear','Linear'),('degressive','Degressive')], 'Computation Method', required=True, help="Choose the method to use to compute the amount of depreciation lines.\n"\ " * Linear: Calculated on basis of: Gross Value / Number of Depreciations\n" \ - " * Degressive: Calculated on basis of: Remaining Value * Degressive Factor"), - 'method_number': fields.integer('Number of Depreciations'), + " * Degressive: Calculated on basis of: Residual Value * Degressive Factor"), + 'method_number': fields.integer('Number of Depreciations', help="The number of depreciations needed to depreciate your asset"), 'method_period': fields.integer('Period Length', help="State here the time between 2 depreciations, in months", required=True), 'method_progress_factor': fields.float('Degressive Factor'), 'method_time': fields.selection([('number','Number of Depreciations'),('end','Ending Date')], 'Time Method', required=True, @@ -222,6 +222,15 @@ class account_asset_asset(osv.osv): else: val['currency_id'] = company.currency_id.id return {'value': val} + + def onchange_purchase_salvage_value(self, cr, uid, ids, purchase_value, salvage_value, context=None): + val = {} + for asset in self.browse(cr, uid, ids, context=context): + if purchase_value: + val['value_residual'] = purchase_value - salvage_value + if salvage_value: + val['value_residual'] = purchase_value - salvage_value + return {'value': val} _columns = { 'account_move_line_ids': fields.one2many('account.move.line', 'asset_id', 'Entries', readonly=True, states={'draft':[('readonly',False)]}), @@ -243,9 +252,9 @@ class account_asset_asset(osv.osv): 'partner_id': fields.many2one('res.partner', 'Partner', readonly=True, states={'draft':[('readonly',False)]}), 'method': fields.selection([('linear','Linear'),('degressive','Degressive')], 'Computation Method', required=True, readonly=True, states={'draft':[('readonly',False)]}, help="Choose the method to use to compute the amount of depreciation lines.\n"\ " * Linear: Calculated on basis of: Gross Value / Number of Depreciations\n" \ - " * Degressive: Calculated on basis of: Remaining Value * Degressive Factor"), - 'method_number': fields.integer('Number of Depreciations', readonly=True, states={'draft':[('readonly',False)]}, help="Calculates Depreciation within specified interval"), - 'method_period': fields.integer('Number of Months in a Period', required=True, readonly=True, states={'draft':[('readonly',False)]}, help="State here the time during 2 depreciations, in months"), + " * Degressive: Calculated on basis of: Residual Value * Degressive Factor"), + 'method_number': fields.integer('Number of Depreciations', readonly=True, states={'draft':[('readonly',False)]}, help="The number of depreciations needed to depreciate your asset"), + 'method_period': fields.integer('Number of Months in a Period', required=True, readonly=True, states={'draft':[('readonly',False)]}, help="The amount of time between two depreciations, in months"), 'method_end': fields.date('Ending Date', readonly=True, states={'draft':[('readonly',False)]}), 'method_progress_factor': fields.float('Degressive Factor', readonly=True, states={'draft':[('readonly',False)]}), 'value_residual': fields.function(_amount_residual, method=True, digits_compute=dp.get_precision('Account'), string='Residual Value'), @@ -359,8 +368,8 @@ class account_asset_depreciation_line(osv.osv): 'sequence': fields.integer('Sequence', required=True), 'asset_id': fields.many2one('account.asset.asset', 'Asset', required=True), 'parent_state': fields.related('asset_id', 'state', type='char', string='State of Asset'), - 'amount': fields.float('Depreciation Amount', digits_compute=dp.get_precision('Account'), required=True), - 'remaining_value': fields.float('Amount to Depreciate', digits_compute=dp.get_precision('Account'),required=True), + 'amount': fields.float('Current Depreciation', digits_compute=dp.get_precision('Account'), required=True), + 'remaining_value': fields.float('Next Period Depreciation', digits_compute=dp.get_precision('Account'),required=True), 'depreciated_value': fields.float('Amount Already Depreciated', required=True), 'depreciation_date': fields.date('Depreciation Date', select=1), 'move_id': fields.many2one('account.move', 'Depreciation Entry'), @@ -460,7 +469,7 @@ class account_asset_history(osv.osv): help="The method to use to compute the dates and number of depreciation lines.\n"\ "Number of Depreciations: Fix the number of depreciation lines and the time between 2 depreciations.\n" \ "Ending Date: Choose the time between 2 depreciations and the date the depreciations won't go beyond."), - 'method_number': fields.integer('Number of Depreciations'), + 'method_number': fields.integer('Number of Depreciations', help="The number of depreciations needed to depreciate your asset"), 'method_period': fields.integer('Period Length', help="Time in month between two depreciations"), 'method_end': fields.date('Ending date'), 'note': fields.text('Note'), diff --git a/addons/account_asset/account_asset_view.xml b/addons/account_asset/account_asset_view.xml index 520ee733e73..c4cb17bded3 100644 --- a/addons/account_asset/account_asset_view.xml +++ b/addons/account_asset/account_asset_view.xml @@ -108,8 +108,8 @@ - - + + diff --git a/addons/account_asset/wizard/account_asset_change_duration_view.xml b/addons/account_asset/wizard/account_asset_change_duration_view.xml index 1c7f3458441..bb848e6db5d 100644 --- a/addons/account_asset/wizard/account_asset_change_duration_view.xml +++ b/addons/account_asset/wizard/account_asset_change_duration_view.xml @@ -8,12 +8,17 @@
- + - - + + + diff --git a/addons/account_check_writing/account_voucher_view.xml b/addons/account_check_writing/account_voucher_view.xml index 520c78009d5..de7ecd327a9 100644 --- a/addons/account_check_writing/account_voucher_view.xml +++ b/addons/account_check_writing/account_voucher_view.xml @@ -9,7 +9,7 @@ account.voucher - + diff --git a/addons/event_sale/event_sale.py b/addons/event_sale/event_sale.py index f4d7fcaa013..4f77b945f69 100644 --- a/addons/event_sale/event_sale.py +++ b/addons/event_sale/event_sale.py @@ -26,7 +26,7 @@ class product(osv.osv): _inherit = 'product.product' _columns = { 'event_ok': fields.boolean('Event Subscription', help='Determine if a product needs to create automatically an event registration at the confirmation of a sale order line.'), - 'event_type_id': fields.many2one('event.type', 'Type of Event', help='Filter the list of event on this category only, in the sale order lines'), + 'event_type_id': fields.many2one('event.type', 'Type of Event', help='Select event types so when we use this product in Sale order line, it will filter events of this type only.'), } def onchange_event_ok(self, cr, uid, ids, event_ok, context=None): diff --git a/addons/event_sale/event_sale_view.xml b/addons/event_sale/event_sale_view.xml index ab7568d704e..cc00365c980 100644 --- a/addons/event_sale/event_sale_view.xml +++ b/addons/event_sale/event_sale_view.xml @@ -10,9 +10,9 @@