This repository was archived by the owner on Mar 21, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 110
10.0 17012018 #95
Open
iledarn
wants to merge
18
commits into
itpp-labs:10.0
Choose a base branch
from
iledarn:10.0-17012018
base: 10.0
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
10.0 17012018 #95
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
b3fec20
[ADD] telegram_expense_manager: currency_id in expenses account.move.…
c5c51f6
[FIX] telegram_expense_manager: typo
c6e537c
[ADD] telegram_expense_manager: multicurrency expenses
7ada112
[ADD] telegram_expense_manager: multicurrency /income
18e08e6
[ADD] telegram_expense_manager: multicurrency in total row for /accou…
9feee23
[ADD] telegram_expense_manager: multicurrency /account_all report
a7b4567
[ADD] telegram_expense_manager: res.currency.alias
47c113d
[ADD] telegram_expense_manager: use currency aliases to get an expens…
ed9bec1
[FIX] telegram_expense_manager: base_currency might not have rate 1
050d398
[ADD] telegram_expense_manager: add em_currency_id on partner's form
4ac68c0
[ADD] telegram_expense_manager: allow multicurrency by default
87b2c0a
[FIX] telegram_expense_manager: search currency by name first, if fai…
ca01be3
[FIX] telegram_expense_manager: fix multicurrency /account_all report
4874de3
[ADD] telegram_expense_manager: multicurrency expense record report
e645bd0
[FIX] telegram_expense_manager: take currency from alias if there is …
e77fd45
[ADD] telegram_expense_manager: case-insensitive currency search
b3262fd
[FIX] telegram_expense_manager: don't specify base currency in accoun…
ab00b11
[ADD] telegram_expense_manager: data file for currency aliases
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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,44 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<odoo> | ||
<data noupdate="1"> | ||
<record id="base.RUB" model="res.currency"> | ||
<field name="active" eval="True"/> | ||
</record> | ||
<record id="rub_alias_1" model="res.currency.alias"> | ||
<field name="name">руб</field> | ||
<field name="currency_id" eval="ref('base.RUB')"/> | ||
</record> | ||
<record id="rub_alias_2" model="res.currency.alias"> | ||
<field name="name">руб.</field> | ||
<field name="currency_id" eval="ref('base.RUB')"/> | ||
</record> | ||
<record id="rub_alias_3" model="res.currency.alias"> | ||
<field name="name">р.</field> | ||
<field name="currency_id" eval="ref('base.RUB')"/> | ||
</record> | ||
<record id="rub_alias_4" model="res.currency.alias"> | ||
<field name="name">рубль</field> | ||
<field name="currency_id" eval="ref('base.RUB')"/> | ||
</record> | ||
<record id="rub_alias_5" model="res.currency.alias"> | ||
<field name="name">рубля</field> | ||
<field name="currency_id" eval="ref('base.RUB')"/> | ||
</record> | ||
<record id="rub_alias_6" model="res.currency.alias"> | ||
<field name="name">рублей</field> | ||
<field name="currency_id" eval="ref('base.RUB')"/> | ||
</record> | ||
<record id="usd_alias_1" model="res.currency.alias"> | ||
<field name="name">доллар</field> | ||
<field name="currency_id" eval="ref('base.USD')"/> | ||
</record> | ||
<record id="usd_alias_2" model="res.currency.alias"> | ||
<field name="name">долларов</field> | ||
<field name="currency_id" eval="ref('base.USD')"/> | ||
</record> | ||
<record id="eur_alias_1" model="res.currency.alias"> | ||
<field name="name">евро</field> | ||
<field name="currency_id" eval="ref('base.EUR')"/> | ||
</record> | ||
</data> | ||
</odoo> |
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
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
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
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
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,21 @@ | ||
# -*- coding: utf-8 -*- | ||
|
||
from odoo import api, fields, models, tools, _ | ||
|
||
|
||
class CurrencyAlias(models.Model): | ||
_name = "res.currency.alias" | ||
|
||
name = fields.Char(string='Currency Alias') | ||
_sql_constraints = [ | ||
|
||
('unique_name', 'unique (name)', 'The currency alias must be unique!'), | ||
] | ||
|
||
currency_id = fields.Many2one('res.currency', string='Currency', readonly=True) | ||
|
||
|
||
class Currency(models.Model): | ||
_inherit = "res.currency" | ||
|
||
alias_ids = fields.One2many('res.currency.alias', 'currency_id', string='Aliases') | ||
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,15 @@ | ||
# -*- coding: utf-8 -*- | ||
|
||
from odoo import api, fields, models, _ | ||
|
||
|
||
class Partner(models.Model): | ||
_inherit = "res.partner" | ||
|
||
def _default_em_currency(self): | ||
return self.env.user.company_id.currency_id | ||
|
||
em_currency_id = fields.Many2one('res.currency', | ||
string="Base currency for personal expense management", | ||
ondelete='restrict', | ||
default=_default_em_currency) |
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,6 @@ | ||
<?xml version="1.0"?> | ||
<odoo> | ||
<record id="base.group_user" model="res.groups"> | ||
<field name="implied_ids" eval="[(4, ref('base.group_multi_currency'))]"/> | ||
</record> | ||
</odoo> |
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,21 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<odoo> | ||
<record id="view_currency_form_inherit_expense_manager" model="ir.ui.view"> | ||
<field name="name">res.currency.form.inherit.expense_manager</field> | ||
<field name="model">res.currency</field> | ||
<field name="inherit_id" ref="base.view_currency_form"/> | ||
<field name="arch" type="xml"> | ||
<xpath expr="//sheet" position="inside"> | ||
<notebook> | ||
<page string="Aliases"> | ||
<field name="alias_ids"> | ||
<tree string="Currency Aliases" editable="bottom"> | ||
<field name="name"/> | ||
</tree> | ||
</field> | ||
</page> | ||
</notebook> | ||
</xpath> | ||
</field> | ||
</record> | ||
</odoo> |
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,17 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<odoo> | ||
<record id="view_partner_form_inherit_expense_manager" model="ir.ui.view"> | ||
<field name="name">res.partner.form.inherit.expense_manager</field> | ||
<field name="model">res.partner</field> | ||
<field name="inherit_id" ref="base.view_partner_form"/> | ||
<field name="arch" type="xml"> | ||
<xpath expr="//notebook" position="inside"> | ||
<page string="Personal Expenses"> | ||
<group> | ||
<field name="em_currency_id"/> | ||
</group> | ||
</page> | ||
</xpath> | ||
</field> | ||
</record> | ||
</odoo> |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍