Commit Graph
117834 Commits
Author SHA1 Message Date
qdp-odoo e0591346a4 [FIX] purchase: fix test_main_flows.
The action 'account.action_invoice_tree2' has been changed into a server action, so we want to open the tree view of invoices by modifying some values of the action we should now use the xml reference 'account.action_vendor_bill_template'.

Additionally, the help tooltip is now completed as would do the server action
2018-06-07 11:28:11 +02:00
RomainLibert b6642f1b70 [IMP] hr_holidays: add support for taking leaves differently
We would like to be able to take leaves using different units, currently
we only support taking leaves by hours because we use datetimes.

We need to support three units:
 * days
 * half days
 * hours

These units will be defined on the leave type.

Task #40995
Closes #21760
2018-06-06 17:04:07 +02:00
Prakash Prajapati d8a5141c17 [FIX] mail: Add a mark as read option on systray message dropdown
- 'Mark as Read' icon will be shown by moving the mouse over the message
- if it's channel then make it Mark as Seen
- if it's inbox notification then mark all message as read
- The inbox notification icon has been changed

This commit is related to task ID 1817646
2018-06-06 17:01:26 +02:00
Mathieu Duckaerts-Antoine 299ebb2cdf [IMP] mail: add moderation on channels
Purpose of this commit is to allow moderation on incoming messages in
discussion channels. On some channels on which moderation is required
messages should be in a pending moderation stage. Moderators can accept
or refuse messages as well as always allow or ban messages coming from
a given set of emails.

Channels now have an option to be moderated. Moderators can be added on
channels. They have access to a specific UI in Discuss to see and take
action on messages waiting for moderation.

Concerning mail.thread message that are pending moderation are not notified.
It means nobody receives a notification about them. Moderation process calls
the notification once the message is validated.

Various features included in this commit :

 * a model is added to store the decision about emails, allow or ban;
 * access rights are updated so that only moderators can modify moderation
   fields on message;
 * specific bus notifications are send to moderated people as well as to
   moderators on incoming emails as well as when a decision is taken;
 * options are added on channels to send explanations to moderated emails;
 * options are added on channels to write and send guidelines explaining
   why and how moderation is performed;
 * a reminder is send daily to moderators with remaining messages to moderate;
 * discuss UI is adapted and a new channel is added below Inbox and Starred
   giving access to moderation tools;
 * chanenl UI is adapted allowing to moderate directly inside channels;

This commit is linked to task ID 29521. Closes #21921.
2018-06-06 16:01:33 +02:00
Thibault Delavallée eeab18d753 [IMP] test_mail: assert_email now allow email_from, not only a partner-based author
Some tests could require it.
2018-06-06 15:58:23 +02:00
Thibault Delavallée de0b9e519d [IMP] test_mail: add an assert method for bus notifications content
Purpose is to ease the check of bus notifications content by having a tool
method doing it.
2018-06-06 15:58:23 +02:00
Sanjay Jamod a4df9f8c93 [IMP] account: vendor bill creation upon email reception
This allows to set up a mail alias per purchase journal. Then share that email address to your supplier, or use it internally to forward the vendor bills received by mail, to automatically create an empty vendor bill with the mail attachments linked, and the partner might be filled if the source email matches a supplier.

Thanks to the document preview on the side, it's now super easy and super fast to copy the vendor bill info from the received PDF into the account.invoice object. This would eventually be improved later on (IAP).

Was task: 37703
Was PR #22158
2018-06-06 14:17:03 +02:00
qdp-odoo a6b75d401d [REF] mail_thread: refactoring of _find_partner_from_emails()
More flexibility equals more powa
2018-06-06 14:17:03 +02:00
Ivan Yelizariev f81963addd [IMP] base: correct link in comment
To describe the date format on babel website
Closes #25085
2018-06-06 10:11:47 +02:00
jem-odoo 09658b041a [FIX] purchase_stock: display form view
Since the split of stock and purchase, some
field are badly displayed on PO form view.
This is due to a bad xpath. This commits
fixes the issue.
2018-06-05 14:55:13 +02:00
Christophe Simonis 279d928693 [FIX] core: always load base and web as server wide modules
Since 285ead28e3, `base` should be loaded
as a server wide module to enable rpc routes.
2018-06-05 14:46:24 +02:00
RomainLibert 83aa86d658 [IMP] website_event: avoid reading of emails
The new route make_event_ics_file received a list of attendee ids and was sending
the emails associated with these in an ics file, this could potentially
give out some information about the attendees.

(see commit 7862b2b71c)

Also the method get_ics_file had no reason to be public and so is now
private.

Closes #24711
2018-06-05 12:22:30 +02:00
XavierDo 3a2c87674b [FIX] web: getFocusableElement error in tree view
When a line in a editable tree view has no acivable element
(readonly or toggle_bollean fields only) the currentFieldIndex
will be null after selecting the row, and when trying to edit a
field (boolean field_toggle in this example) an error will be
thrown when trying to put focus on currentWidget.
We need to check that the currentWidget is not undefined.
2018-06-04 16:49:24 +02:00
Martin Geubelle aabe35c76c [DOC] add documentation for position='move'
Feature merged in odoo/odoo@eee245c
2018-06-04 09:52:08 +02:00
Raphael Collet a058bf18d3 [FIX] resource: field tz defaults to UTC if no timezone found 2018-06-01 18:27:52 +02:00
jem-odoo a0546578ee [MERGE] sale_timesheet: invoice from project overview
These commit allows users to create sales order, and invoice
from the project overview. To do, the overview is now refreshed
when naviguating throught the breadcrumb, and supports action
buttons on its control panel.
Also, some stat buttons are added on the overview (sales order
and invoices).

The process of invoice creation is the same wizard than the one
from the sale order.
Thoses actions are only available when there is no ambiguity
to determine the SO from the project, or for non billable project
(to create the SO).

Task #49213
Closes #24280
2018-06-01 15:47:16 +02:00
jem-odoo 72e3ebc4f9 [IMP] sale_timesheet: overview access
On sales order form view, we display a "project overview"
stat button. It redirects to the overview of the only
billable project of the SO.
To avoid access error, and because this dahsboard is usefull
only for project manager, only those ones will have access to
this overview. So, stat button (Sales order) and label on
project kanban are aonly visible for manager.
2018-06-01 15:14:23 +02:00
jem-odoo 6b1aec5bb7 [IMP] sale_timesheet: SO/INV stat button on project overview
Now that the overview is refreshed when it is displayed and that we
can create SO/INV from it, it is usefull for the users to have
a stat button displaying those new documents directly from
the overview.
This commit use the already existing mecanism to display
Sales Order and Invoices stata buttons.
Thoses 2 stat buttons are only visible for salesperson seeing
all document, to avoid access errors.

Task #49213
2018-06-01 15:14:23 +02:00
jem-odoo 55ca3dd2b1 [IMP] sale_timesheet: invoice from plan project
We want to invoice from the project overview. To do so,
a button can help people: it is only visible when an order
linked to task in that project has something to invoice
Any sale order line, even the ones with no service product
will be invoiced.

However, the user will have to choose which SO (involved in
the project) to invoice. Then the "invoice order" wizard
takes over.
2018-06-01 15:14:23 +02:00
jem-odoo 9f3040ee1f [IMP] sale_timesheet: control button on plan project
This commit makes the project overview handle action
button in its control panel. When calling server to get
overview HTML code, we also get a list of actions to display
in the control panel. Those are rendered client side.

Since when an action is done, we usually don't want the button
to be display anymore, reloading the overview is required.
The overview is now refreshed when navigating with the breadcrumb,
so each time the overview is displayed, an RPC call to the server
is done (`do_show` method override).

Task #49213
2018-06-01 15:14:07 +02:00
jem-odoo d8f2b1b87e [IMP] sale_timesheet: wizard to create SO from project
This commit provides a wizard to create a SO from
a non billable project. It sets sale_line_id on the
project, and the project on the SO line to simulate
the project was created by the SOL.
The created SO contains one line with a selected
service product, with ordered qty set as the total
of planned hours of all task in projects.
The wizard also links all non billable active
tasks of the project to the SO line (and its
timesheet entries).
2018-06-01 15:14:07 +02:00
Raphael Collet 627292f7f3 [IMP] convert: simplify context when creating records
The context was containing a dictionary under the key `install_mode_data`,
which was informing about the model, xml_id, module, filename.  Actually only
the module and filename were necessary, and the others were slowing down the
import because of generating artificially different environments.

The context now has two entries `install_module` and `install_filename`.
2018-06-01 13:30:28 +02:00
Raphael Collet 655ec91807 [IMP] models: simplify API of _parent_store_create and _parent_store_update
The parameter `vals` is no longer given, and the first method has been adapted
to work on several records.
2018-06-01 13:30:28 +02:00
Raphael Collet 23a3ee1254 [IMP] models: no need to mark non-stored fields as modified
Those will be handled by the transitive closure made over non-stored
dependencies.
2018-06-01 13:30:28 +02:00
Martin Geubelle eee245cee8 [IMP] base: allow to move an element in inherited view
The `position='move'` has been introduced to move an element in an inherited
view.

It's used as
<xpath expr="//@target" position="after">
    <xpath expr="//@node" position="move"/>
</xpath>

or also

<field name="target_field" position="after">
    <field name="my_field" position="move"/>
</field>

The xpath with a position `after`, `before`, `inside` or `replace` can thus now
have another xpath as *direct* child with position `move`.
2018-06-01 10:19:09 +02:00
Raphael Collet 975c6c8639 [REF] resource calendar (#24717)
Refactor resource calendar and resource mixin:
 - add a required timezone field on models 'resource.calendar' and 'resource.resource';
 - resource calendar attendances are now computed in the timezone of the resource
   or the calendar;
 - improve API of 'resource.calendar' and 'resource.mixin';
 - avoid other modules from using the implementation methods of 'resource.calendar';
 - refactor implementation of 'resource.calendar' to make it more efficient.
2018-05-31 20:28:12 +02:00
Thibault Delavallée f5af0714e2 [REM] calnedar: remove commented leftover of 4a59f93d15
It way to hot here. Forgot to remove commented views.
2018-05-31 16:54:06 +02:00
Barad Mahendra 4a59f93d15 [IMP] mail, calendar: add today meetings in systray
Purpose of this commit is to display today meetings in the systray. This will
help people in their daily job to have quickly access to their meetings.
It is displayed along with activities and reminders to have all current work
to do in the same place.

Displayed meetings are ongoing or not yet started ones of the current day.
All-day meetings of the current day are also shown. Done meetings are not
displayed to lessen noise.

Clicking on the systray will open the calendar view of meetings in a day
mode. This is done by a small modification in the calendar view allowing
to choose the display mode from context in addition to the mode attribute
of the action definition.

This commit is linked to task ID 60593. Closes #24438. Thanks to @ged-odoo
for quick reviewing.
2018-05-31 16:49:56 +02:00
Mahendra Barad 642970494e [REF] mail, note: rename systray method giving data for web client
As it becomes used to display more things than just counting activities let
us rename the method. Future commits will add new features in the systray
like meetings.

This commit is linked to task ID 60593.
2018-05-31 16:45:51 +02:00
Thibault Delavallée 3239c91766 [MERGE][REF] various: remove several settings allowing to (un)install modules
Unticking options linked to modules lead to applications being removed
without clear notification for the user doing it. Impact of installing
and uninstalling modules is too heavy to be hidden in simple checkboxes
in some settings. This merge therefore removes some of options linked to
modules installation.

This merge is linked to task ID 1841221. Closes #24649.
2018-05-31 15:05:36 +02:00
Hiral Bhavsar 0a5a3c5d72 [REF] hr_timesheet, sale_timesheet: remove settings to (un)install sale_timesheet module
Purpose is to limit the uninstallation of modules without being clearly
notified of it. We therefore decided to remove those options from settings
to prevent users from uninstalling it.

Description of sale_timesheet features and options are now all moved to
sale_timesheet. A Billing section should only be visible if sales installed.
We therefore move Billing section from hr_timesheet to sale_timesheet. A
priority is used to ensure sequence of various settings related to billing
and timesheet.

This commit is related to task ID 1841221.
2018-05-31 14:58:48 +02:00
Hiral Bhavsar 49c3f91e04 [REF] website_sale: hide settings to install account_invoicing
Purpose is to limit the uninstallation of modules without being clearly
notified of it. In website_sale we choose to hide the field allowing to
(un)install invoicing. Options linked to invoicing are now hidden if the
module is not installed.

This commit is related to task ID 1841221.
2018-05-31 14:58:45 +02:00
Hiral Bhavsar 7215064c33 [REF] hr_expense: remove settings to (un)install sale_expense module
Purpose is to limit the uninstallation of modules without being clearly
notified of it. In expense ticking sale_expense repair / maintenance install
and uninstall sale modules and its dependencies.

We therefore decided to remove those options from settings to prevent
users from uninstalling it.

This commit is related to task ID 1841221.
2018-05-31 14:58:43 +02:00
Hiral Bhavsar 9cabc3170e [REF] project: remove settings to (un)install timesheet
Purpose is to limit the uninstallation of modules without being clearly
notified of it. In project ticking timesheet may have a great impact
depending on modules already installed: sale_timesheet, timesheet_grid,
...

We therefore decided to remove those options from settings to prevent
users from uninstalling it.

This commit is related to task ID 1841221.
2018-05-31 14:58:40 +02:00
Hiral Bhavsar 000ecb046c [REF] mrp: remove settings to (un)install repair and maintenance modules
Purpose is to limit the uninstallation of modules without being clearly
notified of it. In MRP ticking repair / maintenance install and uninstall
modules like stock, sale_management, mrp_workorder, ...

We therefore decided to remove those options from settings to prevent
users from uninstalling it.

This commit is related to task ID 1841221.
2018-05-31 14:58:38 +02:00
Géry Debongnie 5b19d05a9a [DOC] add documentation for the new cohort view 2018-05-31 10:36:58 +02:00
Christophe Matthieu 241e67b788 [FIX] qweb: Field type monetary use the record context
Before this fix, the _convert method use the context of the qweb rendering
instead of use the record context.

'date' and 'company' are automatically set as option for the field. The
template who use t-esc with the widget monetary must define the options.

The bug is introduce by https://github.com/odoo/odoo/commit/7a282c99655d4f154ac1808fcb8a70339dc70930
2018-05-31 10:26:52 +02:00
Fabien Pinckaers 361070a45e [IMP] web, crm: minor copywriting in Kanban and CRM flow 2018-05-30 20:42:17 +02:00
Fabien Pinckaers 8169134715 [IMP] project: list and pivot are not grouped by default in tasks 2018-05-30 20:25:36 +02:00
Fabien Pinckaers 84c1ed4c26 [IMP] web: better copy for adding a column in kanban views 2018-05-30 20:16:14 +02:00
Laurent Smet dfde326e75 [IMP] account: add account.fiscalyear model
In order to improve the fiscal year management, we allow the user to define custom fiscal years
    using the account.fiscalyear model.

Was task: https://www.odoo.com/web#id=39878&view_type=form&model=project.task&menu_id=
Was PR #20936
2018-05-30 18:28:13 +02:00
jem-odoo 075cafa828 [IMP] purchase: move settings for purchase requisition
purchase_requisition install stock, but when doing services you might
still want the option. This option was only display when stock
is installed. This commit changes this to make it visible when
purchase is installed.
The option is better visible and installing a new apps, then
hidden (or difficult to find).
2018-05-30 16:17:38 +02:00
Thibault Delavallée 7657150135 [MERGE][IMP] web, mail: add and use a badge based widget for selection fields
Purpose of this merge is to improve usability of activities by using a
new widget for selection field used to propose next activities. It
displays valid choices using badges instead of radio buttons (radio) or
a classic list (selection).

This merge is linked to task ID 1844575. Closes #24791.
2018-05-30 15:40:10 +02:00
Siddarth GajjarandMohammed Shekha 517f6d7246 [IMP] mail: improve recommended activities usability
When scheduling an activity after closing one, do not force a default
activity. Having the proposed activities is sufficient.

This commit also uses the newly-introduced selection badge widget to display
proposed activities as badges.

Co-authored-by: Siddarth Gajjar <sga@odoo.com>
Co-authored-by: Mohammed Shekha <msh@openerp.com>
2018-05-30 15:39:20 +02:00
Siddarth GajjarandMohammed Shekha c75c2fa9e3 [IMP] web: add a badge based widget for selection fields
This commit introduces a new widget to be used for selection-based fields.
Valid choices are displayed using rectangular badges and not like the
standard list. This widget is valid for selection and many2one fields
like selection or radio widgets.

Co-authored-by: Siddarth Gajjar <sga@odoo.com>
Co-authored-by: Mohammed Shekha <msh@openerp.com>
2018-05-30 15:39:15 +02:00
Olivier Colson cda8bdc8b3 [FIX] base: res.currency: use company_id context value as an integer id (not as a model reference) as it used to be before refactoring.
The use of id and model reference was inconsistent for this variable, depending on the content of the context. Doing this caused a failure when trying to load some financial reports (> Balance Sheet, Spanish reports, ...) of accounting in multi company, if both companies had not the same currency.
2018-05-30 15:01:01 +02:00
Thibault Delavallée fbec51f476 [IMP] mail: improve default channel picture
Purpose is to avoid having void image in systray when there are notifications
linked to channels that have no picture. Two small improvements are done on
channel model
 * change default picture for channel to be more inline with Odoo design
   guidelines;
 * override create to ensure there is a default image when creating the
   channel through the discuss interface;

This commit is linked to task ID 48228.
2018-05-30 15:00:01 +02:00
Thibault Delavallée 7558dfe4e9 [REF] product: remove unused icon, add a new one
Purpose is to avoid having void images in the systray when there are
notifications linked to products. Solving that issue require to put an
icon on the product module. The old one that was badly named is replaced
by a new one more in line with Odoo guidelines.

This commit is linked to task ID 48228.
2018-05-30 15:00:01 +02:00
Géry Debongnie fccd8ede10 [FIX] im_support: convert less file to scss
was not changed in forward-port
2018-05-30 14:03:52 +02:00
Christophe Simonis e008ef302a [MERGE] forward port branch saas-11.3 up to 53300648ed 2018-05-30 12:18:52 +02:00