-
-
Notifications
You must be signed in to change notification settings - Fork 779
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
af77965
commit a51f200
Showing
4 changed files
with
37 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
from . import account_asset_method_number_end | ||
from . import account_asset | ||
from . import account_asset_profile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
account_asset_management_method_number_end/models/account_asset_method_number_end.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Copyright 2018 Camptocamp SA | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
from odoo import models, fields | ||
|
||
|
||
class AccountAssetMethodNumberEnd(models.AbstractModel): | ||
|
||
_name = 'account.asset.method.number.end.mixin' | ||
|
||
method_number = fields.Integer( | ||
string='Number', | ||
help="The meaning of this parameter depends on the Time Method.\n" | ||
" * Number of Years: Specify the number of years " | ||
"for the depreciation.\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_time = fields.Selection( | ||
selection=lambda self: self.env[ | ||
'account.asset.profile']._selection_method_time(), | ||
help="Choose the method to use to compute the dates and " | ||
"number of depreciation lines.\n" | ||
" * Number of Years: Specify the number of years " | ||
"for the depreciation.\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.") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters