Commit Graph
126256 Commits
Author SHA1 Message Date
Jinal Patel 7e49fda883 [IMP] point_of_sale: Allow to filter partners based on pos orders
Especially used for e-marketing to filter the customers who purchased from store using pos.

Related Task ID: 1931528

closes odoo/odoo#30645
2019-02-13 07:28:08 +00:00
Nimesh Jethva 2d633fc7ac [IMP] mrp : BoM of type kit improvement.
- Hide operation as well as menufacturing readiness when bom type is kit also make help message user friendly.

Task : https://www.odoo.com/web#id=1929631&action=327&model=project.task&view_type=form&menu_id=4720

This commit is related to task ID : 1929631

closes odoo/odoo#30405
2019-02-13 06:16:47 +00:00
Yannick Tivisse 9a8863d01f [FIX] l10n_in: Fix forwardport
closes odoo/odoo#28816
2019-02-13 06:12:39 +00:00
Barad Mahendra 4ef4aa2083 [IMP] payment: Log error message on payment transaction failure
Currently when the payment is initiated there is a message in
sale order for waiting for confirmation.

But when the payment returns an error there is no message on
sales order so it's not clear for the end user that payment
is still pending.

Related Task ID : 58741
2019-02-13 06:12:39 +00:00
Jinal PatelandRohan Patel f735951d5c [ADD] payment_ccavenue: Add new payment acquirer for India
CCAvenue is the most popular payment provider in india.

Co-authored-by: Rohan Patel <rop@odoo.com>

Related Task ID : 58741
2019-02-13 06:12:39 +00:00
Toufik Ben Jaa bed3b4a5cb [FIX] hr_*: access rights issues when changing employee's user
- When changing the user of a `hr.employee` record, access rights errors
  could be triggered.

  Those errors are triggered when a record (for example a leave) is
  linked to this employee and the current user has limited write
  accesses by record rules on this record.

closes odoo/odoo#31032
2019-02-12 15:47:02 +00:00
Nicolas Martinelli 0191b65b25 [FIX] stock: inventory value
- Go to Inventory > Reports > Inventory Valuation
- Select the pivot view

The top row (containing the Total) has an empty 'Inventory Value'.

This is because there is no domain on the line, so it is skipped.

We fall back on the global domain instead.

opw-1933191

closes odoo/odoo#31280
2019-02-20 13:39:36 +00:00
Nicolas Lempereur 8183f92de4 [FIX] web: ie11 autocomplete field no open itself
On IE11, in 10.0 up to master in some instance when creating a record
under some conditions the dropdown may be automatically opened and need
to be closed.

This has been pinpointed to 90c1af1151 so it seem that a combination of
fields/code/autocomplete and changing the placeholder at one time causes
the issue.

Since IE11 lie and say it is mozilla 11.0 we just apply the 90c1af1151
when the browser is chrome (we did no did this at first to have the same
behavior accross browsers).

note: there is an opened bug in chromium https://crbug.com/928305 if
solved the hack could be removed completely.

opw-1940592
closes #31271
2019-02-20 10:39:17 +00:00
Jairo Llopis 2b1d3ff82d [FIX] core: log unexpected validation exceptions
Before this patch, any exception raised by a constraint method that
were not of type `ValidationError` were hard to debug, because the
origin line was never logged.

Explicitly logging the error (with traceback) when we catch it
ensures proper contextual info, even in the absence of exception
chaining.

closes odoo/odoo#28612
2019-02-20 09:47:56 +00:00
Mathieu Duckerts-Antoine 01c159fd9f [FIX] web: quotes and backslashes in search view
The commit 6d3ada178f
aimed to solve problems occuring whith (single or
double) quotes when creating new custom filters.
Unfortunately, the point was missed and bugs were
still present. The present commit solves the
orginial problem satisfactorily.
There was also a problem in the management of
backslashes. Type '\\' in the search bar would
lead to a domain like
[('...', 'ilike', '\\\\\\\\\\\\\\\\')].
This has also been fixed. Note that it is
necessary to input "\\" if one is looking for a
backslash in db (as before).

A remark on the _formatAST function (py_utils.js):

We deescape only the chars `'`, `"`, and `\`
because it does not seem possible to produce a
string in the search view that would intend a
search for a line return or a tab for example.

A general remark:

Domains should always be in normalized form.
In that way they could be manipulated and combined
together without a tokenization/parsing!

closes odoo/odoo#29756
2019-02-12 12:45:51 +00:00
Lucas Perais (lpe) 6d5a993cf7 [FIX] web: control panel load/save filter sort param
Before this commit, the wrong semantics was implemented in the webclient
concerning the "sort" char field in ir.filter
Loading a filter with a sort with negative order made the webclient crash

This field holds a JSON string, representing a list of field names
If the order of the field is inverse, there should be a "-" before it
for legacy purposes

After this commit, the semantics have changed for consistency
that is, at save time the sql notation is preferred
We support the legacy notation too for backward compatibility

closes odoo/odoo#31102
2019-02-15 09:58:47 +00:00
Robot Odoo b923ef6c3f [MERGE] mail: fix performance issues with channel seen feature
Revision on https://github.com/odoo/odoo/commit/844fb2b51ea7cfa557b19466c0a53dde19433e7a

There were some performance issue with this newly added feature.
This was particularly the case on channels with multiple users, therefore
we have decided to only enable it on direct chats for the moment.

Also, we avoid unnecessary writing in DB and sending notification on longpoll
if the seen information of a user is already up-to-date.

closes odoo/odoo#31074
2019-02-15 09:25:06 +01:00
Toufik Ben Jaa 9cd8410f69 [FIX] website_sale: avoid to consider quotations as eCommerce carts
- An eCommerce cart is a quotation linked to a website.
- The feature to consider a cart as abandonned wasn't correctly checking
  if the quotation is linked to a website and flag regular quotation as
  abandonned carts.

  This causes issues since Sales may wish to send the quotation by mail,
  but the button is hidden and replaced by the button "send recovery
  mail" which send an email with a specific email template.

closes odoo/odoo#31103
2019-02-14 16:12:08 +00:00
Alexandre Kühn 8ee218aa5c [FIX] mail: notify channel_fetched/channel_seen only when changes
Revision on https://github.com/odoo/odoo/commit/844fb2b51ea7cfa557b19466c0a53dde19433e7a

With the commit above, when the JS notified on `channel_fetched` and
`channel_seen`, it was always writing in DB and sending notifications
on the longpoll.

This is useless if the information on last fetched/seen message
of the conversation remains unchanged, which is what this commit
solves.

Also prevent `channel_fetched` from seding notifications on
the longpoll if this is called on a non-chat channel.
2019-02-14 12:55:24 +00:00
Alexandre Kühn 62294921b8 [FIX] mail: enable seen feature only on direct chats
Revision on https://github.com/odoo/odoo/commit/844fb2b51ea7cfa557b19466c0a53dde19433e7a

There were performance issue with the seen feature in multi-
user channnels, therefore it has been disabled for them.
As a result, only direct chats have this feature.
2019-02-14 12:55:24 +00:00
Toufik Ben Jaa 4a4101c09c [FIX] oe: allow to add attachments on bank statements
- It was impossible to add attachments on the `account.bank.statement`
  form view due to the chatter not being displayed.

  This commit add the chatter widget to the Bank Statements form view.

closes odoo/odoo#31098
2019-02-14 09:48:18 +00:00
Christophe Simonis 1cc285ee30 [FIX] project: count tasks of child contacts
Allow to have the count to match the one you will get when clicking on
statbutton (behavior changed by #27118).

closes odoo/odoo#31081
2019-02-13 17:22:38 +00:00
Toufik Ben Jaa e8b28c02a0 [FIX] website: server images for website_published records
- When a record has `website_published` field set at True the method
  `binary_content` on `ir.http` should bypass the access rules and
  always deserve the content.

  This wasn't the case due to a mistake on the code. The code is
  checking the access rules and may in some cases not return the
  content.

closes odoo/odoo#31068
2019-02-13 13:48:33 +00:00
Alexandre Kühn 98e3ca4e67 [FIX] mail: throttle batched channel_fetched RPCs
Revision on https://github.com/odoo/odoo/commit/844fb2b51ea7cfa557b19466c0a53dde19433e7a

The commit above added the seen icon on messages in a channel.
However, since this feature, there was a performance issue
when opening the systray messaging menu with several pinned
channels: lots of RPCs are made, almost 1 for each preview
in the messaging menu.

The RPCs comes from the reception of the last message in the
channel, to let the current user notify that he has received
the messages in the channel.
Those RPCs were made for each channel, thus the more pinned
channels the more RPCs were made when opening the messaging
menu.

This commit fixes the issue by throttling and batching the RPCs.
To do so, instead of letting the channel model handle the RPC
`channel_fetched`, the mail service now handles it. This has
the advantage to throttle the RPC globally and to batch the
requests to notify that messages have been received on channels.

closes odoo/odoo#31026
2019-02-12 14:38:32 +00:00
Jeremy Kersten 055ca53c20 [FIX] website_forum: fix traceback where answer is not set
+ add button Comment lost during forum conversion to bs4
+ fix typo t/a
2019-02-12 16:46:31 +01:00
Nicolas Seinlet b90fcdb162 [FIX] sale: avoid false positives in reconciliation match
- ILIKE and other regex operators are not appropriate for the
  comparison, as we need an exact substring match.
  Using POSITION() and looking for position != 0 gives the expected behavior.
- Addiionally, regex operator ~  is not available in PostgreSQL 9.x
- Add regression tests

Closes #30720
2019-02-12 15:56:59 +01:00
Nicolas Martinelli f45609d76b [FIX] hr_expense: multi-currency
- Set your company to USD
- Create an expense in EUR:
  Amount: 100
  Tax: 15% Excluded
- Validate, post the journal entries

It crashes because of a missing `.id`, but on top of that... not a
single AML is correct.

opw-1938570

Fwd-port of ab06e9cad36d7398de709d6a6c994cbbeb7737f4
2019-02-12 15:50:01 +01:00
wan 7a1c8d54b4 [IMP] account: filter reconciliation with check number
Task 1881964
Allow to search for counterparts with a check number

closes odoo/odoo#30593
2019-02-12 12:13:59 +00:00
Thibault Delavallée 752c8925ea [FIX] website_slides: fix typos
Othrewsie you colud have some isuses.

closes odoo/odoo#31020
2019-02-12 11:24:30 +00:00
David Beguin f95f8cc696 [FIX] gamification: fix rank computation 2019-02-12 11:24:23 +00:00
David Beguin b0aa6f654b [MOV] gamification, website_forum : move karma data and demo in gamification
As gamification karma-based features can be used outside of forum let us
move demo and data directly in gamification. It will be used notably for
eLearning.
2019-02-12 11:23:34 +00:00
Robot Odoo 77b5673a0d [MERGE][REF] website_slides: allow / improve channel and slide creation
This merge provides new modal to create slide channel from the 'New' website
menu, like blogpost or forum. It also improves the upload slide widget from
channel homepage.

This merge also brings new slide type 'webpage'. This allow user to create
completely customized content as a slide.

This merge is linked to Task-1938643. More generally it is linked to the
eLearning feature [1]. For more details see subcommits.

[1] see task ID 1902304 (main eLearning task) PR #29876

closes odoo/odoo#30991
2019-02-12 14:03:26 +01:00
qmo-odoo 1b1732beb5 [IMP] website_slides: new modal to upload a document
With new slide type, it was required to change the
upload modaL. Now, the use select first the type
of document he wants to upload, then the correct
form appears. When filled, user can sumbit it to
be redirect to the slide he just create.

Task-1938643
2019-02-12 11:23:13 +00:00
qmo-odoo 0f22f95289 [IMP] website_slides: webpage slide type
The idea is a slide can be a HTML page completely customized by
user. So, you can now easily create custom content and publish
it on your website, like a normal slide.

Task-1938643
2019-02-12 11:22:59 +00:00
qmo-odoo b8a24751c2 [IMP] website_slides: remove unique slide name constraint within channel
Having a unique constraint for a slide name in a channel look strange.
It force an RPC call to check this when uploading a slide, making the
process a little bit slow.
Morevover, name is a translatable field on slide.slide model, so the
constraint can not be fully respected.

To simplify the model, we decided to remove this.

Task-1938643
2019-02-12 11:22:59 +00:00
qmo-odoo 5aa645c89f [IMP] website_slides: add external links on slide
A slide can now have some external link. For instance, links to
the origin of the document (sources for scientifics papers, ...).
A new model is added to allow the user to provide several link
per slide. Those are display below the channel on website page.

Task-1938643
2019-02-12 11:22:59 +00:00
qmo-odoo c2a38e4602 [IMP] website_slides: create channel in frontend
This commit provides the abilty to create channel from the website
instead of creating a slide. To do so, the user still have the "upload"
button on the channel home page.
The new modal allow user to set title, description, type and channel
tags. We prevent channel tag and group tag creation on the fly, as it
can impact the UI (coming in a future commits).

Task-1938643
2019-02-12 11:22:55 +00:00
Christophe Simonis 93d736e905 [MERGE] forward port branch 12.0 up to 6e8dff1952 2019-02-11 16:17:02 +01:00
Arnold Moyaux 333b3caa19 [FIX] stock: Perf, move order by picking_id
It will force a JOIN between stock_move and stock_picking
table. That could cost a lot on huge databases.
2019-02-11 14:58:34 +00:00
jbm-odoo 4960453db9 [IMP] web Add widget signature on binary field
Add a new widget for binary fields. It open a dialog box and the user can sign manually,
or an signature can be draw automatically or he can upload a picture of his signature.
Move fonts, controller, scss,templates about signature from portal to web to avoid redundance

closes odoo/odoo#30222
2019-02-14 12:59:10 +00:00
Pierre Masereel 7410de111f [ADD] reveal_service : allow user to generate leads based on filters
Purpose :

Allow the user to generate a certain number of leads based on certain criteria like localization, technologies used, or size.

Available filters are :

- company size
- localization (country and states)
- industries
- technologies

The user can also ask for a few contacts that can be filtered based on
their role or seniority.

Each company found generates a new lead/opportunity for which the sales
team, salesperson and tags can be preset from the lead mining request.

This commit includes the followings changes :

- New module crm_iap_lead
- New model crm.iap.lead.helpers which contains helper methods used by
both modules crm_iap_lead and crm_iap_lead_website
- New model crm.iap.lead.mining.request that holds the data of a lead
mining request
- An option in the CRM settings to install this feature
- New button 'Generate Leads' in the leads/opportunity ListView and
KanbanView that opens a modal allowing to create a lead mining request
- New section 'Lead Generation' in menuitem 'Configuration' of CRM

TaskID : 1902172

closes odoo/odoo#30189
2019-02-14 14:10:35 +00:00
Pierre Masereel 6703840062 [REF] crm_iap_lead: split crm_iap_lead into two modules 2019-02-12 11:00:18 +00:00
Pierre Masereel f597916963 [MOV] crm_reveal: rename crm_reveal in crm_iap_lead_website 2019-02-12 11:00:18 +00:00
Louis Baudoux da4cb0acb5 [FIX] web: pass buttons_template as parameter of KanbanController
Before buttons_template couldn't be passed as parameter, which prevented
from changing the button template used when rendering the button
2019-02-12 11:00:18 +00:00
Robot Odoo 5fa651cb01 [MERGE][ADD] website{_profile,_slides,_forum,*} : new profile page yayy
Purpose of this merge is to provide a completely new and improved user profile
page linked to gamification, slides and forum. Those frontend applications
now heavily rely on website profile and add their own custom content like
channel or forum participation or challenges results. This merge is linked
to the currently under development eLearning feature [1][2].

This merge contains notably

 * review website profile page centralized in a new module : website_profile;
 * move everything that was linked to the profile from website_forum in
   website_profile;
 * properly add forum informations in website_forum through inheritance;
 * add channel / course informations in website_slides through inheritance;

A new bridge module is added that is website_slide_forum. It makes a link
between those two applications. Publishers can create a forum linked to a
course allowing participants to communicate and ask questions related to a
course.

Profile page is contextualized. When coming from a channel informations about
this channel is displayed. Linked forum information is added. When coming from
a specific forum only information related to this forum is displayed.
Otherwise a profile page with aggregated information is displayed.

Some other improvements are done: ranks, karma, badges from gamification are
included in forum and eLearning, 'new badge notifications' mechanism is removed
as email are send, and various other improvements. See sub commits for more
details.

Merge linked to task ID 1922159.

[1] see task ID 1902304 (main eLearning task) PR #29876;
[2] see task ID 1936153 (new homepage for slides) PR #30770;

closes odoo/odoo#30988
2019-02-14 16:34:36 +01:00
Romain Estievenart 873ea984a5 [FIX] board: dashboard app mobile layout
Follow-up of task 1904747

closes odoo/odoo#30853
2019-02-14 10:32:12 +00:00
Romeo Fragomeli 183ff490d6 [IMP] *: add mobile (native) barcode scanner for product field
This commit change widget to many2one_barcode in these views:
- sale_order
- purchase
- invoice
- expense

In the fields register 'many2one_barcode' is mapped to many2one as fallback.
many2one_barcode is implemented in odoo enterprise

Task ID: 1924766

closes odoo/odoo#31018
2019-02-14 09:41:33 +00:00
jem-odoo ec212de5c7 [IMP] gamification,forum: remove deprecated alert when sending badge
Since 56645335b7, when a user get a badge,
an email is sent. The subtype is not used anymore, so the alert
mecanism in forum to display a message to the user to show him
his new badges can not work.
This commit removes this dead code.
Task-1922159
2019-02-14 09:24:10 +00:00
David Beguin a4a0436ddd [ADD] website_slides_forum : Allow to create forum on a course
Adds the mega power to make Super Saiyan fusion between website_slides and website_forum
A slide.channel can now be linked to a forum to allow users to discuss about their courses.

Overrides the slides profile routes to include the potiential linked forum.
The profile page will display now all the information of a specific channel with, also, all the
information of the linked forum. If no channel is specified, the profile page shows
everything (information about all channel and information about all forum).

Task ID : 1922159
PR #30988
2019-02-14 09:24:10 +00:00
David Beguin d8f156ae73 [IMP] website_slides : use website_profile page template and adds website_slides specific information
Adds slides ands slide.channels specific information (courses) into the website_profile template page.

As there can be more than one slide.channel,the profile page shows everything linked to every slide.channel,
except if the channel_id is given in url arguments.

Adds the 'Go to eLearning' button in the 'new rank reached' mail to encourage the users to continue
to be active on the eLearning platform as well, to gain more karma point and improve there rank.

Task ID : 1922159
PR #30988
2019-02-14 09:24:10 +00:00
David Beguin 336a90e530 [REF] website_forum : use website_profile templates and adds forum specific information
Adds forum specific information into the website_profile template page.
Removes everything linked to profile that is already in website_profile module to avoid duplicates.

As there can be more than one forum, the profile page shows everything linked to every forum,
except if the forum id is given in url arguments.
The old route (forum/forum-1/user/user_id) have been kept for backward compatibility reasons.

Adds the 'Go to forum' button in the 'new rank reached' mail to encourage the users to continue
to be active on the forum as well, to gain more karma point and improve there rank.

Image rpc calls have been reviewed for profile page part to use only the standard way to get image
-> web/image/model_name/id/image_size

Task ID : 1922159
PR #30988
2019-02-14 08:30:29 +00:00
David Beguin ff870099c5 [ADD] website_profile : add profile page template for website modules
Move Profile part from website_forum into this module in order to be usable in other modules
(like website_slides) that will depend of this module.

Applies gamification.ranks on website_profile page. Show the current rank and the next rank
but also the progression until the next rank. Adds also an 'about rank' page to allow users to know
more about available ranks.

The goal here is to make the profile page more modular and to allow other modules to add informations
or modify easily link or part of profile page in order to be specifically contextualised
for the module in question.

Task ID : 1922159
PR #30988
2019-02-14 08:30:29 +00:00
David Beguin cfbd8d1ada [IMP] gamification, website_forum : apply various improvements
- add menu to configure ranks in gamification tools because was missing
- move admin karma data in gamification : karma linked to gamification
  and not forum anymore
- fix rank computation : next_rank_id could never been recomputed correctly
  if rank are created in a karma ascending order.

Task ID : 1922159
PR #30988
2019-02-14 08:30:29 +00:00
Pierre Masereel 4a857060e1 [IMP] delivery: print return label
We want to allow to print return labels on picking that contains retrun
moves and having a carrier that support return labels.

closes odoo/odoo#30886
2019-02-12 09:29:51 +00:00
David Beguin b8a8c28554 [IMP] im_livechat : review channel history layout
The Live chat history was taking too much space and was hard to read.
The goal here is to display more information on the screen.
The pictures and padding are then reduced.

Note that kanban view is not a solution in long term.
At it does not allow to squash messages per user (if consecutive
messages from same user at close interval of time).
As the thread widget will be reviewed by discuss team in a
near future, we keep this at the moment and will integrate the
new thread widget later, mainly to be able to squash the messages.

Task ID : 1913869
Closes PR #30343
2019-02-14 08:57:57 +00:00