Templates used to send invoice / quotation / PO by email are cleaned. Custom
style is removed. Content is simplified.
For sale, only one template is kept through the various addons. Previously to
this commit there are 3 templates: standard, portal and online quote. Those
template are similar except the link to get the sale order. Now the base template
contains some logic that should be sufficient to cover all cases. This breaks
the modular approach but is easier to use for users. As templates are still mako
it is not possible to use inheritance. So having a base template knowing some bits
of overriding modules is necessary if we want to avoid having the same template
duplicated.
The template used for notifications is updated. The general layout
is now
header: logo -- action buttons, contextual actions
separator
body
signature
Sent by company using Odoo
Action and access button in notification emails are added. Override
mail_thread methods to add a specific link + an access buttons to
everybody if the slide is published.
This makes every template holding images crash. As this feature will shortly be
fixed in 9, let us temporarily comment its use and wait for the forward port of
the fix.
Leads and opportunities have each their own search view.
- The menu Sales > Your pipeline must have
as search view the one of the opportunities,
like the "Pipeline" button in the crm dashboard
- In the leads search view, filters/groupbys
using fields that are not used in leads must be
removed
- `Channel` was renamed to `Medium` a while ago,
the filter must use the terminology used in the
lead/opportunity form view.
opw-652588
opw-653417
The notification box remains on the form until either:
- the user closes it explicitly, or
- the user edits the record, or
- the form view is refreshed (switch to another record, or refresh form).
Add a method `once` to `EventDispatcherMixin`, as it is convenient.
Make `FormView` trigger events `to_view_mode` and `to_edit_mode`.
When an account.move.line(aml) is created for a reconciliation, the date
used in the aml must be the date of the bank.statement.line used to
create the aml.
opw:653335
This revision is related to 0ea31c272c.
It's no longer really needed since the rescue sessions have been removed,
with the revision 87a3fe92de,
except for databases already having opened rescue sessions.
opw-653180
Using `fields.Date.context_today` for a `Date` field is the
right thing to do, but not for a `Datetime` field,
as it won't return the current hour, and this will lead
to issues with the different possible timezones.
opw-652391
When we had things like or & in a text we want to translate,
the translation system would save it unescape (so \xa0 and &).
So in this instance, the traduction would not match the real source
which was not subjected to this unescaping.
opw-653173
note: fix is courtesy of dle (no need to forward port after saas-6)
As this method is overided in several modules, the mix of new and
old API makes it difficult to handle. Indeed in some cases we
receive the expected dictionary, sometimes in a list, sometimes
in a list of list, due to api.one decorator.
This is a change in the method API, however it is currently completely
buggy. Moreover this method is used internally and should not be
used as an external API. Lastly, this method is new from v9.
/my/orders is available only for quotations not in draft or cancel mode. No
need to redirect to website for those quotations.
online quotation was buggy, id was not defined, use quote.id instead. Woaw.
The bus used to do a long poll as soon as it is started. This is fine
when the user has a single tab, but not so fine when 5 or 6 tabs are
open. This commit introduce the concept of tab manager, a way to decide
among all tabs who is the leader. The leader will then initiate the
long poll, and share the notifications via the local storage.
Issue: steps to reproduce:
create a purchase order
choose a supplier
choose a product
change the quantity
don't click anywhere on the form, just click on "confirm order"
you get an error "invalid field: scheduled date"
Use dataset instead of record because record can have an other value (a short for a moment due to deferred).
Use silent option to avoid onchange.
Since c04065abd8 (introduction of
accounting v9) bank statement lines can not have an amount of zero
anymore. So when we validate an order in the POS client we need to get
rid of paymentlines with an amount of zero.
The fix in 665bc1c solved the issue for pager of some X2Many widget x2m
which would shadow the accesskey to go to previous/next page of the top
view's current model.
But in the case a web.Pager (used in community for a X2Many kanban
widget) the fix had no effect.
opw-652888
This commit was necessary to fix weird problems in 9.0-nightly.
Phantomjs and the old nvd3 implementations did not play well together.
* transitionDuration() replaced by duration()
* tooltips() & tooltipContent replaced by tooltip.enable and tooltip.contentGenerator
* remove useless less for tooltip
Thanks to mge for his help
Before this fix, inconsistencies arise in the prices displayed in a
multi-currency environment. For example, let's consider these 2
pricelists:
- Public Pricelist, in USD
- Benelux Pricelist, in EUR with 10 % discount
When the Benelux Pricelist is selected, the strikethrough price is in
USD, the price is in EUR, and the currency displayed is $. The reason
is that the pricelist used is stored in request.session, but the
templates are still using the pricelist linked to the partner.
We link website.pricelist_id to the currency stored in request.session,
which is more logical. We also use the currency related to this
pricelist in the templates, which avoids the inconsistencies mentioned.
The function _onchange_partner_id must be triggered when the field 'company_id'
is modified like with function _onchange_partner_id in addons/account/models/account_invoice.py
In this way, the account_id is set in 'account.invoice when the 'company_id' is changed.
opw:652918