Commit Graph
117156 Commits
Author SHA1 Message Date
Thibault Delavallée 0296f198b2 [IMP] mail: tests: add a new simple base model for testing
Purpose: have simple test models to use in various modules and be
independent from standard models behavior / tweaking.
2017-09-15 15:56:23 +02:00
Yannick Tivisse af2620a443 [IMP] web: reference field: add 'hide_model' option
It allows to see only records from a given model without allowing to
change the model. It gives a better experience to users that choose
records using a reference field when the model comes from some other
choice and should not be changed.
2017-09-15 15:56:23 +02:00
Thibault Delavallée d635547760 [IMP] mass_mailing: consider replying to an email imply opening it
Currently when people answers an email its statistics are set to replied
updating its replied field. However if the blank gif used to track the
opening fails for whatever reason we could have mail considered as replies
but not opened.

We consider that it is not common to reply to an email people did not
open. Let us therefore set a replied email as also opened.
2017-09-15 15:56:23 +02:00
Yannick Tivisse 51b5ee7c3c [IMP] mass_mailing: choose model among all chatter models
This commit removes the strange selection box based on a magic flag and
some strange methods returning a string. Instead just allow to send mass
mailing on all models inheriting from mail.thread using the is mail
thread flag.

Various addons are updated to remove the _mail_mass_mailing class
attribute used to determine mass mailing capability.

We consider people could send a mass mailing on every model inheriting
from mail.thread. It makes no sense to limit it to a given set of addons.
2017-09-15 15:56:23 +02:00
Thibault Delavallée e9fca14452 [IMP] mass_mailing: add support of clicked event on statistics
Currently there is no way to know on mail statistics if the customer
clicked on a link or not. This commit adds support of click like what
is already implemented for opened or replied. It stores the date when
the first tracked link has been clicked. A clicked mail is considered
as being opened related to its state if no other statistics has been
checked.
2017-09-15 15:56:23 +02:00
Thibault Delavallée ae455fb1f5 [FIX] mass_mailing: fix issue in _get_mailing_model
getattr crashes and in this case we probably meant to use hasattr as we
have a fallback behavior.
2017-09-15 15:56:23 +02:00
Thibault Delavallée 7accd77999 [REF][FIX] link_tracker, mass_mailing: factorize method creating link tracker click values
This commit factorizes the link.tracker.click values computation out of
the add_click method. This method is called when customers click on links
in email that are tracked in Odoo.

Purpose of this commit is

 * to effectively put mass mailing related code into mass mailing.
   Currently link_tracker holds code related to mass mailing which is
   not in its dependency tree. Let us therefore try to be a bit modular
   and add a proper inheritance in mass mailing;
 * allow addons to inherit from the click values prepare method to add
   specific values depending on their behavior like mass mailing adding
   links to a mass mailing and a mass mailing campaign;
2017-09-15 15:56:23 +02:00
Thibault Delavallée 83d3b281a4 [IMP] mass_mailing: allow to send a mailing on a given set of records
Currently mass mailing automatically computes the remaining recipients
to mail based on existing statistics and A/B testing. However in some
cases we would like to send the mailing on a given set of records. An
example of use is to use the mass mailing mechanism on records coming
from marketing activities. This commit adds this feature by adding an
optional parameter to send. If not given it falls back on the classic
mass mailing behavior.
2017-09-15 15:56:23 +02:00
xmo-odoo 02fe548000 [FIX] link_tracker: no string.letters in Python 3 2017-09-15 15:51:37 +02:00
chv-odoo 2dea77fe21 [FIX] link_tracker: no string.letters in Python 3 2017-09-15 15:50:23 +02:00
Christophe Simonis 82aaf1aa17 [MERGE] forward port branch 10.0 up to bf8f701032 2017-09-15 15:47:58 +02:00
Pratima Gupta 989e5ebc99 [IMP] mrp: usability improvements
1)Improve naming pattern of work order.
2)Default group by added for gantt view of both production and work center.
2017-09-15 15:38:37 +02:00
Pratima Gupta 8b2e0fcc5a [IMP] stock: Show the negative stock in red in inventory 2017-09-15 15:38:37 +02:00
rde 4ecbacaf59 [ADD] website: add new page management
website.page = old ir.ui.view with page=True
website.redirect is a new mechanism to replace in the futur the ir.attachment
mechanism of redirect.

From now, we don't have a specific /page controller to serve 'page'.

We use a new model website.page which is rendered if none route matches the url
 and that the field 'url' on website.page matches the request.httprequest.path.

The order to serve a path is:
    - Routes defines in controllers (/shop, /blog, ...)
    - ir.attachment with name matching the path
    - website.page with url matching the path
    - website.redirect with url_from matching the path
    - 404

To improve:
    - allow regexp in website.redirect model
    - allow to edit the view_arch from the page.management via redirect backend
      (needed when traceback in the page, or when modifying a js/css/less/...)
2017-09-15 15:29:37 +02:00
Aaron Bohy 13a44d33bd [MERGE] im_livechat, mail: new Discuss mobile UI
- Brand new UI for Discuss client action (with tabs for for
  Discuss client action (with tabs for Inbox, chats,
  channels...)
- In mobile, conversations always open in Chat Windows
- Chat window UI improved (both mobile and desktop)
- Channels preview (used in the systray menu, and now in the mobile
  UI of Discuss) improved
- Other minor less tweaks

Task #31446
PR #16995
2017-09-15 15:25:16 +02:00
Aaron Bohy 7a91d87614 [IMP] im_livechat, mail: Discuss UI in mobile
- Extract mobile specific code for the client action to a specific
  file
- Massive clean of less rules
- Unify channels preview of the systray dropdown and the mobile UI
  of Discuss
- Ensure to only load the last message of each channel in mobile,
  as this is not used in desktop (unless the user opens the systray
  menu)
- Make livechat available in Discuss mobile UI
2017-09-15 15:25:06 +02:00
Aaron Bohy 9850cb1c3c [REF] mail: client action: convert to new guidelines
And refactor the code to ease the development of the mobile
version.
2017-09-15 15:25:06 +02:00
Dharmang Soni 4685e4bc7f [IMP] mail: improve Discuss UI for mobile devices
- Brand new UI for Discuss client action (with tabs for Inbox,
  chats, channels...)
- In mobile, conversations always open in Chat Windows
- Chat window UI improved (both mobile and desktop)
- Channels preview (used in the systray menu, and now in the mobile
  UI of Discuss) improved
- Other minor less tweaks
2017-09-15 15:25:06 +02:00
qsm-odoo a8e7d096b8 [REF] web: adjust kanban dashboards layout
Crop long texts avoiding issues with <a> tags.
Use flex to align cards' content in order to place the latest block
at the end of the card.
2017-09-15 15:04:52 +02:00
stefanorigano 2edcd1cdc0 [REF] web: remove kanban useless LESS rules 2017-09-15 15:04:52 +02:00
Pierre Masereel ab31d43fb9 [FIX] stock: stock user create lot
When a stock user want to create a lot an exception is raised saying
that he cannot modify a product.

This is caused by the field 'product_uom_id' on the model
'stock.production.lot' that is a related to 'product.product' and not
set as readonly in the 'stock.production.lot' view.

So by setting it as readonly, we don't set the uom to the server, and so
don't try to re-write it on the product
2017-09-15 14:51:03 +02:00
stefanorigano fafbc5ebe9 [REF] *: use new kanban record classes/layout 2017-09-15 14:34:18 +02:00
qsm-odoo ae7f4c0485 [FIX] web: always quickcreate in the first kanban column
KanbanColumn instances are saved in an array in the renderer. The quick
create widget is always put in the first column found in this array.
Unfortunately, the array elements' order was broken after some
operations where column(s) are rerendered (like moving records).
2017-09-15 14:32:26 +02:00
Nhomar Hernández [Vauxoo] b1368d56be [FIX] base_vat: Regex need 'br' insted only 'r' now on python3 2017-09-15 14:24:30 +02:00
Olivier Colson 3e1d46dcc9 [IMP] l10n_es: improves localization package
* PYMES, non-profit associations, complete (large enterprises) CoA
* reviewed taxes, tax groups
* reviewed tags, account types for reports in l10n_es_reports

Thanks for the contribution and the original work, spanish community (esp. Pedro M. Baeza).

Was task 30669. Was PR #19154
2017-09-15 14:04:41 +02:00
stefanorigano 3fb7842864 [REF] web, mail: minors UI fixes
- List view: sortable icon, do not force position to right
- Mail: do not vertically reposition systray's icons
- Form view: oe_subtotal_footer, minor design imp
2017-09-15 13:39:01 +02:00
stefanorigano da21b03661 [REF] base, web: adapt base settings to new design
- Use mixins and default LESS variables whenever possible
- Get rid of useless “!important” rules
2017-09-15 13:39:01 +02:00
stefanorigano 38a1a452cf [REF] account: adapt dashboard header to new design 2017-09-15 13:39:01 +02:00
Mitali Patel 79038055f5 [IMP] base, res.currency: amount_to_text() based on num2words library
Old implementation of tools.amount_to_text() is now deprecated. The new one support more languages

Was task 27215. Was PR #16531
2017-09-15 13:24:02 +02:00
Yannick Tivisse be93768608 [FIX] product: Display product_id on supplier info form view
Purpose
=======

Now if we want to create a product supplier info, it's impossible to select the template if it has no variant, which is rather annoying.

Specification
=============

Remove the attrs
2017-09-15 12:56:00 +02:00
Pierre Masereel 470577c129 [CLEAN] stock: remove unused methods since stock refactoring 2017-09-15 12:00:40 +02:00
Pierre Masereel 62c6d6fc81 [FIX] stock: move_view without suggest
The move line view when the option no suggest is checked doesn't work
because it hasen't been adapted during the refactoring of stock module.

So to avoid having differences between the view in no suggest and in
suggest, we use the same tree view that we reference. Because the views
shouldn't be different if we are either in suggest or no suggest
2017-09-15 11:48:11 +02:00
Deep Patel 1c0befc8a6 [IMP] web: UX improvement on mobile for the sale order view 2017-09-15 11:16:11 +02:00
Martin Geubelle 74c27d81ed [FIX] web: deal with can_create and can_write option in M2O
The server postproccess the view to add attributes on many2one fields, i.e.
`can_create` and `can_write`, according to access rights.

These attributes are parsed by the client as string but should also be parsed by
the many2one when evaluating them.

The mock server has also been adapted to set these attributes.
2017-09-15 11:03:09 +02:00
Jose Suniaga [Vauxoo] 27edcaafd6 [FIX] l10n_mx: company in the journal cash basis configuration
When have more than one company, for all companies, the cash
basis journal  set in accounting configuration will be
always the related to first company.

This issue cause the followiong error trying to validate an
invoice for a company different to fisrt one:

'Cannot create moves for different companies.'

Because exist a 'cross-configuration' in the cash basis
journal.

The solution to this issue is include the company in domain
that does the search for cash basis journal.
2017-09-15 10:39:32 +02:00
Pierre Masereel b9be8402c3 [FIX] core: handle sql constraint exceptions in python3 2017-09-15 10:18:32 +02:00
Simon Lejeune a7fa3cc436 [FIX] stock, purchase: correctly remove stock_calendar 2017-09-15 08:34:35 +02:00
qsm-odoo 814304a227 [MERGE] web, *: add kanban column progressbar feature
* crm, project

See last merge commit for detail.
Work started by @pat-odoo and @stefanorigano
2017-09-14 23:51:48 +02:00
qsm-odoo 33f9e90bd5 [IMP] web, *: add kanban column progress bars
* crm, project

Add a new feature which allows to put a progressbar in the kanban
columns. The progressbar shows with the same color the amount of
records whose value of a given field are the same in the column.
It also indicate the sum of another given field or simply the total
number of records. It also allows to subgroup the column content.

To define a progressbar, add this as a direct child of the kanban
arch:

<progressbar field="<name of the field to use for subgroups>"
             colors="{<one possible value for the above field>: <success, warning or danger>, ...}"
             sum="<name of the field to sum or nothing to use total number of records>"/>

Also:
- Properly update record model data's parentID when moving a record
- ...
2017-09-14 23:48:56 +02:00
qsm-odoo 031dc1d952 [REF] web: allow to perform a standalone read_group
Before this commit, asking the basic model for a 'read_group' operation
was automatically followed by other operations to read groups content
('search_read', 'read', ...). This commit introduces an option to only
perform a 'read_group'.
2017-09-14 23:48:55 +02:00
qsm-odoo 76ad4e71a5 [REF] web: do kanban group manual update before saving a record move
Before this commit, when a record was moved in a kanban view, the
model saved the record change then manually updated the related groups
(to avoid performing a read_group and reloading the whole view). This
manual update can in fact be performed before the record save. This
allows customizing the save operation in some cases where a real
read_group would be needed.
2017-09-14 23:48:55 +02:00
qsm-odoo 8b00628aa2 [REF] web: also use _confirmSave when a kanban record is 'manually' updated
Normal flow for one record's changes to be saved is:

0) (use `_setValue` for fields)
1) `trigger_up('field_changed')`
2) field manager mixin: `_onFieldChanged`
3) model: apply changes and save
4) controller: `_confirmSave`

Kanban records are using another system for an unknown reason. This
system was calling the right model functions but was not calling the
controller `_confirmSave` and was instead re-coding it. This commit
makes sure that `_confirmSave` is now called.
2017-09-14 23:48:55 +02:00
qsm-odoo 5c6a7c9ea9 [REF] web: do not update groups model ID on read_group update
Performing a 'read_group' was creating new model group data which were
saving some properties of the old model group data. As KanbanColumn
widgets may not be updated in each case where we might want to re-do
a (partial) 'read_group', this commit changes the system so that old
model group data are simply updated with the useful new group data
properties (instead of being entirely replaced).
2017-09-14 23:48:54 +02:00
qsm-odoo f1370dfa0a [REF] web: allow adding custom stuff in kanban header
Previous kanban header was a div with `flex-flow: row nowrap`. So if
someone tried to add some stuff in it, it will be forced to stay on
the same row as the title and config buttons. This commit wraps these
row elements in a new div to allow kanban header customization (this
prepares for the kanban progressbars).
2017-09-14 23:48:54 +02:00
qsm-odoo 8496a31421 [REF] web: move misplaced kanban quick create code 2017-09-14 23:48:53 +02:00
qsm-odoo 268b4a5a1d [FIX] web: fix kanban alignments
Previous implementation contained negative paddings which are not valid
values for browsers. This also prepares for the kanban progressbars.
2017-09-14 22:46:04 +02:00
Christophe Simonis a63a805efb [FIX] core: python3 compat: do not modify dict during iteration 2017-09-14 19:41:13 +02:00
Prakash Prajapati 0c04aaa303 [IMP] account: generic PDF tax report for community.
Was PR #19097. Was task 35751.
2017-09-14 17:49:01 +02:00
Goffin Simon 82efd56593 [FIX] account: Reconciling residual payment in other currency
Steps to reproduce the bug:

-Let's consider a company A in the currency MXN
-Let's consider two invoices for customer C in USD one of 150$ and one of 50$
-Create a payment P of 180$ for customer C
-Reconcile P with the first invoice of 150$(with button add on the invoice)
-Go to the other invoice of 50$

Bug:

The residual amount of 30$ is not suggested.

Fix:

The residual amount is set in amount_residual_currency, that's why it
was not detected by the domain. Now the residual amounts in other currency
are also detected for the reconciliation.

opw:769090
2017-09-14 17:14:48 +02:00
Jeremy Kersten 8f99b24f6c [FIX] payment_sips, payment_ogone: remove call to partner_reference.
This field has been removed on transaction model in commit f8a98d9.
2017-09-14 16:27:43 +02:00