Commit Graph
691 Commits
Author SHA1 Message Date
Ankit Sathvara 0c1941ab15 [IMP] sale,account,pos: Improve label on config to active currencies
PURPOSE
=======

Simplify the way to activate currencies

SPECIFICATION
=============

On res.company :

Currency_id: options={‘no_open’: True}
oe_edit_only on “Activate more currencies”

In the list view of the currencies, replace the checkbox active by a boolean_toogle widger

There is normally a default filter on the currencies list view to only show the active currencies : this filter should be kept except if you arrive on this screen by clicking on "Activate more currencies"  from the res.company and from the settings. Only the menuitem Currencies should only show the active ones
2017-07-07 16:18:23 +02:00
Christophe Simonis bf51fe55a1 [MERGE] forward port branch saas-16 up to 0f2b2c4e2b 2017-07-07 14:30:30 +02:00
Christophe Simonis 0f2b2c4e2b [MERGE] forward port branch saas-15 up to 514a1a76d8 2017-07-07 14:18:07 +02:00
Christophe Simonis 514a1a76d8 [MERGE] forward port branch saas-14 up to 5b28570769 2017-07-07 14:14:55 +02:00
Christophe Simonis 5b28570769 [MERGE] forward port branch 10.0 up to aef7748845 2017-07-07 14:13:07 +02:00
Christophe Simonis aef7748845 [MERGE] forward port branch saas-11 up to 96fa86779b 2017-07-07 14:07:47 +02:00
Martin Geubelle a29f7f671b [FIX] *: explicit color_field attribute for m2m_tags
Since the previous commit, the `color_field` needs to be explicitly stated
in the options for the tags to be colored.

The previous behaviour (always read the field `color`) was leading to server
warnings if the field was not present on the comodel.

Thìs commit set the `color_field´ for every many2many_tags on fields that have
a `color` field on the comodel.
2017-07-07 13:40:50 +02:00
Christophe Monniez c1e154bee1 [FIX] tools: ensure xlsx worksheet names are valid
When xlsx is used, the worksheet name may be longer than 31 chars and
raise an exception.

This fix will troncate the name up to 31 chars and will remove invalid
chars.

Similar patch was already done at 0122c05eff for xlwt

xlsxwriter 0.9.8 has added a parameter worksheet_class=None so adding **kw to be
compatible with installs with the latest version (requirements.txt asks for
version 0.9.3)

Closes #18077
opw-751157
2017-07-07 09:44:09 +02:00
Yannick Tivisse 5e908b0b17 Revert "[IMP] base: Only show uninstalled languages on install wizard"
This reverts commit 1e2e55872f.

In debug mode, there's a checkbox to reload the language and overwrite the existing terms. This previous commit makes that use case impossible.
2017-07-06 14:22:16 +02:00
Yannick Tivisse 89d5fadc20 [IMP] base: Reload the webclient on language install
PURPOSE
=======

When I install a language, I shouldn't have to refresh the page to see the newly installed language.

Example : I install a language, then click on my user (upper right corner) and try to select this language. The newly installed language is not available. I first need to reload my page.
2017-07-06 14:12:49 +02:00
Yannick Tivisse 1e2e55872f [IMP] base: Only show uninstalled languages on install wizard 2017-07-06 14:12:49 +02:00
Christophe Simonis 7dc731db83 [MERGE] forward port branch saas-15 up to 1f16d34aaa 2017-07-06 13:54:22 +02:00
Christophe Simonis 1f16d34aaa [MERGE] forward port branch saas-14 up to 5009752dcf 2017-07-06 13:53:17 +02:00
Christophe Simonis 5009752dcf [MERGE] forward port branch 10.0 up to 1206cc3f7d 2017-07-06 13:05:24 +02:00
Denis Vermylen e0a1549307 [IMP] models: add access_user to get_access_action
In order to be able to identify what action to return based on the
access_user.

Typically portal users will need to be redirected to the front-end,
while internal users will need to be redirected to the back-end.
2017-07-06 12:53:39 +02:00
Christophe Simonis 1206cc3f7d [MERGE] forward port branch saas-11 up to 5f7f3209e0 2017-07-06 12:30:51 +02:00
Fabien Pinckaers cfd5f47493 [IMP] base: no image (and kanban use default values 2017-07-05 22:06:41 +02:00
Denis Ledoux 6078c04266 [IMP] models: allow to use a not automatic create_date field
Without this, you cannot use a `create_date` field
in a model with `_log_access` set to `False`
2017-07-05 13:50:15 +02:00
Denis Ledoux ad67f7aff8 [FIX] sql: Do no consider a table exists if this is a schema table/view
Before this revision, this is not possible to create a model
with a `_table` set to `domains`, for instance.
2017-07-05 13:47:29 +02:00
Martin Trigaux 8810cee440 [I18N] all: synchronise saas-14 terms
based on v10 terms and saas-15
add the new languages

Much noise due to the different softwares that do not indent the terms the same
way. Merged the po files with --no-wrap option which makes long lines.

opw-751014
2017-07-05 11:48:45 +02:00
Christophe Simonis 780ae8a808 [MERGE] forward port branch saas-15 up to 10cb34bcac 2017-07-04 18:14:13 +02:00
Christophe Simonis 10cb34bcac [MERGE] forward port branch saas-14 up to 97258040d8 2017-07-04 14:40:20 +02:00
Christophe Simonis 97258040d8 [MERGE] forward port branch 10.0 up to 657e328903 2017-07-04 13:17:16 +02:00
Fabien Pinckaers 5a97afcce1 [FIX] scaffold: small fix in template 2017-07-03 16:33:26 +02:00
Richard Mathot c47c52bfd9 [FIX] base: fetch gravatar images only from views
Before this commit, at each partner creation (including data import,
RPC import and tests) Gravatar server was polled, slowing down partner
batch import.

We then enable this feature only where it is needed: when creating a
partner from a view.
2017-07-03 15:04:29 +02:00
Odoo Translation Bot b5951dc6a3 [I18N] Update translation terms from Transifex 2017-07-02 07:03:10 +02:00
Odoo Translation Bot 0db908b399 [I18N] Update translation terms from Transifex 2017-07-02 04:27:01 +02:00
Martin Trigaux ec7b08d1ff [FIX] base: check description content
Some may say that fe346fa0 made the test fail but this is an illusion
2017-06-30 15:25:44 +02:00
Nicolas Martinelli c61ae3a3ed [FIX] models: copy field with unique constrain
When a model contains a field translatable which has a unique
constrain, it is impossible to copy a record. Indeed, the unicity
constrain is always triggered, even if the model takes in charge the
overriding of the copy method to avoid duplication.

Introduced with commit ce7f31b0b0, with the goal to target only
XML/HTML translations. We apply this behavior in case of a callable
translate property, to target only the desired problematic use case.

opw-749481
2017-06-30 10:52:15 +02:00
Christophe Simonis 936f39886c [MERGE] forward port branch 10.0 up to cb01cfe9ff 2017-06-29 16:40:39 +02:00
Nicolas Martinelli d63a01f939 [FIX] base: sequence date range
Ensure to search a maximum of 1 record to avoid crash.

opw-748971
2017-06-29 09:33:15 +02:00
Raphael Collet b8cf940247 [ADD] base: new wizard to uninstall a module (#17284)
The "Uninstall" button on the module form no longer changes the state of
modules, so that cancelling the wizard will not unexpectedly perform the
uninstallation.  The uninstallation is performed only by clicking on the
"Confirm" button on the wizard.

Moreover, the wizard provides clearer information about the impact of the
uninstallation: what apps/modules will be uninstalled and what documents
(models) will be lost.
2017-06-28 15:36:17 +02:00
xmo-odoo 98602e93cc [FIX] PO translations export
Within the scope of P3 compatibility, a StringIO was replaced by
BytesIO in b4429c2a91, however I missed
that BytesIO is much stricter about types than StringIO *even in
Python 2*. Some bits of text would sneak up in PoFile.write or
PoFile.write_info and blow up the export.

The BytesIO makes sense for output (tgz is definitely not a text
format and base64 is a bytes -> bytes encoding), but ensuring the
entirety of PoFile worked on bytes seemed distasteful (and lots of
changes), it seemed more sensible at all levels that PoFile would make
sure to properly work on *text*, and to add a text adapter wrapper
around the BytesIO buffer.

io.TextIOWrapper was almost perfect (it closes the underlying stream
on close but that can be worked around) *however* it turns out
TextIOWrapper does not work on Python 2's `file` objects... so use the
older codecs.StreamReaderWriter which should be able to do the job
properly.

fixes #17834
2017-06-28 15:35:53 +02:00
Martin Trigaux 81ff060fb4 [I18N] export base source terms 2017-06-28 14:53:55 +02:00
Laurent Smet 8e230ae25d [FIX] base/report: fix attachment creation without attachment_use
If attachment_use is false and attachment_name specified, the attachment
is not created.
2017-06-28 11:43:32 +02:00
Xavier Morel 6ad587dc8f [FIX] db restoration existence check
5ee9ec7d removed bool(Connection), turns out db restore still used it
but muted the logger so that was hard to notice in the logs.
2017-06-28 10:05:33 +02:00
Goffin Simon cf66983f37 [FIX] base: Language translation import issue
When importing translations with a csv, the state of the translations was
always set to "To translate" even if the state was "Translated"
due to function _inverse_source.

PS: Making self.source when self is considered as record set could lead to an error.
The return in this function was not needed.
In old API this function was called just for one record.
So this function expect only one record at each call.

opw:747877
2017-06-28 09:27:20 +02:00
Ankit Joshi 16ebec2324 [FIX] http: avoid crash in web/database/selector when selecting invalid database (#17830) 2017-06-27 16:52:20 +02:00
Christophe Simonis dd43071638 [MERGE] forward port branch saas-16 up to 278e478d55 2017-06-27 14:19:31 +02:00
Christophe Simonis 34b432d528 [MERGE] forward port branch saas-15 up to 4d79a1ff58 2017-06-26 19:19:39 +02:00
Xavier Morel 5ee9ec7d6c [FIX] P3: __nonzero__ -> __bool__
Also ~removed bool-testing on cursors
2017-06-26 16:45:03 +02:00
Xavier Morel c5dcf75a81 [FIX] P3: Unpickler.find_global -> Unpickler.find_class 2017-06-26 16:45:03 +02:00
Xavier Morel aaf8f3e37f [IMP] reorganise opcodes in categories 2017-06-26 16:45:03 +02:00
Xavier Morel 5810ea2a97 [FIX] P3: random.sample on a recordset
In P3, random.sample requires that its parameter be a Sequence or a
Set. This blows up _cart_accessories.

So opt BaseModel into both ABC, seems to work fine.
2017-06-26 16:45:02 +02:00
Xavier Morel 8f6e5dbdd3 [FIX] P3: assertItemsEqual is called assertCountEqual
The python 3 name is more correct as to what the assertion actually
does, but still makes for a breaking change.
2017-06-26 16:45:02 +02:00
Xavier Morel 3c95f7f25c [FIX] P3: ast changes
* P3 gets a "proper" arg node
* P3's arguments adds two parameters (kwonlyargs and kw_defaults) for
  keyword-only parameters
* P3's ``fn(**bar)`` only works if ``bar`` *only has string keys*,
  some of the contexts in qweb passed non-string keys and blew up
* P3's ast.If requires a non-empty body, add ``[ast.Pass()]`` ballback
  for non-literal bodies
2017-06-26 16:45:02 +02:00
Xavier Morel 6e9d29df1d [FIX] P3: bytecode changes
* Python 3.4 adds new convenient bytecode-inspection API to dis which
  is nice, however Python 3.6 also switches from the old bytecode to a
  new wordcode which breaks _get_opcodes and *requires* that we use
  the new API
* add various opcodes which either were added in Python
  3 (CALL_FUNCTION_EX) or were only used for some small corners of
  Python 2 but have been expanded or despecialised in Python
  3 (BUILD_SLICE)
2017-06-26 16:45:02 +02:00
Christophe Simonis e1c74e374c [MERGE] forward port branch saas-14 up to 3bac72ba74 2017-06-26 14:04:04 +02:00
Christophe Simonis 3bac72ba74 [MERGE] forward port branch 10.0 up to aaadb232b2 2017-06-26 13:00:18 +02:00
Odoo Translation Bot afba38b88d [I18N] Update translation terms from Transifex 2017-06-26 10:49:30 +02:00