Purpose of this commit is to clean a bit the test mode of surveys before
working a bit on ACLs and survey access. Currently when taking a survey
with a magic 'phantom' token it generates a test answer allowing to go
through the survey process. However it has several drawbacks :
* 'phantom' is not a real token. Token parameter should be used only for
real tokens and avoid having corner case when managing simple parameter;
* token should only be used to ensure people have been granted access to
answering surveys;
* it is currently available for every users;
* it is pure unwanted magic;
In this commit we add a separate route for testing surveys that create the
test answer and then redirects to the survey with this answer. It is now
also limited to survey managers or survey officers testing their own surveys.
Survey JS tour now uses the standard URL and not the testing one. Indeed as
testing is now limited to survey officers and managers tour should test
real life use cases.
This commit is linked to task ID 1916034 and PR #29339.
Purpose
=======
Survey assets were incorrectly overridden in the website_survey module and all copy/pasted.
This will correctly include the survey_assets template and get rid of these copy/pasted
assets references, while keeping the website style on survey pages.
Task: #1915790closes#29314
This branch introduces a large-scale reorganization of the
component tree generated by the web client. The short version is
that now, the control panel is a child of the view controller and
no longer a sibling. Graphically (and simplified), we go from
this:
webClient
/ | \
... ... actionManager
/ \
controlPanel viewController
/ \
to this:
webClient
/ | \
... ... actionManager
|
viewController
/ | \
ControlPanelController
/ \
CPRenderer CPModel
The motivation is that this work moves the code where it should be.
Before this commit, it was kind of weird to have code in the
controllers to render buttons outside of their root node (in
renderButtons). Also, the action manager had to take care of
coordinating search view states between view transitions.
So, this work simplifies the code. It also makes it easier to
extend. We see day after day that Odoo needs to take care of more
complex UI needs, and in many cases, these needs were quite
difficult to implement (we prefer spaghettis in our plates, not in
our code). The changes in this branch should open the way to
implement these features.
For example,
- it will now be easy to add the possibility of views (for example,
the search view or a new ControlPanel view) to add custom buttons
(of type action or object) in the control panel.
- Another need will be to serialize/ restore the state of the
search view across action boundaries (needed by the dashboard).
- Another example is the possibility for views to customize easily
the presence/absence of sub menus (filters/groupbys/favorites/
time range/...)
- Another need is an easier way for views/client action to customize
their control panel.
This commit also contains a large rewrite of the search view (so it
is more inline with our architecture and easier to maintain).
Part of task 1893568
Co-authored-by: Aaron Bohy <aab@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: Martin Geubelle <mge@odoo.com>
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
closesodoo/odoo#29106
=========
PURPOSE
=========
{Any employee can work on a PoS session, even if he has no user. This decreases the cost of PoS App.}
We are not competitive enough on the PoS Market because customers have to pay one user per cashier while they expect to pay one user per cash station.
===============
SPECIFICATIONS
===============
pos.config
- Add a checkbox : "Login with Employees"
- If set to TRUE, an "Allowed Employees" many2many appear
- If employees many2many is empty, all employees can log on this PoS
- If set to FALSE, can only log in with the currently logged user
hr.employee
- The barcode and pin fields were be moved to the hr.employee
- Set a barcode (not pin) by default at the creation of any employee
- No Employees module with PoS > dependency to hr
Open the PoS if "Log in with Employees" = FALSE
- Same behaviour than now, when I open the PoS, I'm logged in with the current user and can start working at once. The only difference is that it is not possible to switch users anymore.
- The button to close the session is visible
Open he PoS if "Log in with Employees" = TRUE
- When I open the PoS, the first screen I see is the login screen.
(a) I choose my employee and enter my pin code (if there is pin code on my employee, otherwise not required) (I can only see employees that have access to that PoS)
(b) I scan my barcode
(c) I scan my rfid card (future development)
- When I click on the employee name, I can log in with another employee
- If the employee is linked to a user that has the pos user/manager access right, I can see the button the close the session. Otherwise I cannot close the session (and thus cannot access backend).
- Add field employee on all records created by PoS (and replace the field user by that one) (on pos.orders)
Lock Screen
- Improve the PoS Interface
- Add a new feature to allow to "lock" the session. When a session has been locked, the user/employee has to re-log-in to access the PoS
- When I try to re-log-in, by default suggest the last employee logged in in the login screen
Migration
Plan a migration strategy > barcode and pin is now on the employee and not on the user anymore
closesodoo/odoo#28567
This commit adapts the code for the 'Add to Google Spreadsheet'
entry in the Favorites menu, according to the large refactoring of
the SearchView/ControlPanelView in web.
Part of task 1893568
This rev. adapts the code of the 'Add to Dashboard' entry of the
Favotires menu, according to the large SearchView refactoring. It
also does some tweaks for the dashboard app due to the move of the
ControlPanel from the ActionManager to the controllers.
Part of task 1893568
according to changes in web.
Some changes have been made to the webclient template (and widget)
in web, and the pos (using the webclient widget as well) needed to
be adapted.
Part of task 1893568
This rev. moves the backbone library from web to pos, as one of its
two usecases (the search view) has just been removed. From now on,
it is only used in the pos.
Part of task 1893568
to ControlPanel/Search view refactoring.
*: mail,sale,web_diagram
The ControlPanel being now inside the DOM of views' controller,
those existing widgets needed to be adapted (in the way they define
if and how they want a ControlPanel, and in the way the manipulate
their DOM as it slightly changed). Tests needed to be adapted as
well.
Part of task 1893568
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: Martin Geubelle <mge@odoo.com>
to ControlPanel/Search view refactoring.
The ControlPanel being now inside the DOM of client actions, those
existing widgets needed to be adapted (in the way they define if
and how they want a ControlPanel, and in the way the manipulate
their DOM as it slightly changed). Tests needed to be adapted as
well.
Part of task 1893568
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: Martin Geubelle <mge@odoo.com>
This branch introduces a large-scale reorganization of the
component tree generated by the web client. The short version is
that now, the control panel is a child of the view controller and
no longer a sibling. Graphically (and simplified), we go from
this:
webClient
/ | \
... ... actionManager
/ \
controlPanel viewController
/ \
to this:
webClient
/ | \
... ... actionManager
|
viewController
/ | \
ControlPanelController
/ \
CPRenderer CPModel
The motivation is that this work moves the code where it should be.
Before this commit, it was kind of weird to have code in the
controllers to render buttons outside of their root node (in
renderButtons). Also, the action manager had to take care of
coordinating search view states between view transitions.
So, this work simplifies the code. It also makes it easier to
extend. We see day after day that Odoo needs to take care of more
complex UI needs, and in many cases, these needs were quite
difficult to implement (we prefer spaghettis in our plates, not in
our code). The changes in this branch should open the way to
implement these features.
For example,
- it will now be easy to add the possibility of views (for example,
the search view or a new ControlPanel view) to add custom buttons
(of type action or object) in the control panel.
- Another need will be to serialize/ restore the state of the
search view across action boundaries (needed by the dashboard).
- Another example is the possibility for views to customize easily
the presence/absence of sub menus (filters/groupbys/favorites/
time range/...)
- Another need is an easier way for views/client action to customize
their control panel.
This commit also contains a large rewrite of the search view (so it
is more inline with our architecture and easier to maintain).
Part of task 1893568
Co-authored-by: Aaron Bohy <aab@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: Martin Geubelle <mge@odoo.com>
This rev. adds a factory class to generate MVC components, to
properly standardize the way MVC components should behave (in the
odoo way). The most popular MVC of the webclient concerns views
(Model, Controller, Renderer, for each view type). However, we
wanted to generalize the notion of MVC (and extract it from the
views), as we will use it in a future commit for the ControlPanel.
Part of task 1893568
Co-authored-by: Aaron Bohy <aab@odoo.com>
Purpose
=======
On a payslip rule computation you can return 3 parameters:
- result_qty
- result_rate
- result
From this, we compute the total amount as following:
tot_rule = amount * qty * rate / 100.0
If we set parameters result_qty=0 or result_rate=0 to force the tot_rule to
be equal to 0, then their values are set to the default one, which is ambiguous.
So
result_qty = 0
result_rate = 0
Become
qty=1
amount=100
We can't fix this in a stable release as this could imply unwanted
behavior changes for customers, and also quite difficult to spot.
closesodoo/odoo#29206
In order to facilitiate the configuration of a livechat on the website,
the first livechat channel that was demo data from im_livechat
is now set as data. Website is now using this first livechat channel
instead of creating a new one and using it.
Merge related to task ID 1912056.
closesodoo/odoo#29020
The first implementation of `documents` was based on `ir_attachment`,
adding fields only useful when the attachment was a document.
This task splits documents in a new model called documents.documents,
and clean the logic accordingly.
This task also recovers the "attachment" action button, to list attachments on a model
without chatter.
related to: odoo/enterprise#3048
task: #1908896closesodoo/odoo#28563
*: hr_recruitment, web, website_sale_digital
This commit replaces the references to 'document' by 'attachment_indexation'
following the rename of the module.
Task #1908896
This commit renames the module document into attachment_indexation
to provide a more descriptive name and avoid confusion with
enterprise's documents module.
task: #1908896
This reverts commit 1dbb555a
Bring the sidebar attachment dropdown feature back.
This feature was removed due to be considered as useless,
but since some models can have attachement without a mail_thread,
this feature is still necessary.
task: #1908896
*: tools, web, website, website_forum, mail, im_livechat
This commit refactors ir_http to make it more readable
and flexible.
Move the resize function of web/image to odoo.tools
Co-authored-by: XavierDo <xdo@odoo.com>
Co-authored-by: Antony Lesuisse <al@openerp.com>
closes: #28563
task: #1908896
Moved the field 'active', 'res_model_name' and 'thumbnail' from
ir.attachment to enterprise's documents.document.
Moved the pdf split feature to enterprise's Documents module.
task: #1908896
This commit adds the seen icon next to a message for all channels
except livechat.
It tracks received and seen messages for all members of the channel.
Icon is either 1 or 2 check(s) ('v' or 'vv').
Those are the different states of this 'seen' icon:
ICON: DESCRIPTION:
no check .................. no one has received the message.
1 check ................... some members have received the
message, no one has seen it.
2 checks (greyed-out) ..... some members have seen the message,
some or everyone has received it
2 checks (green) .......... all members have seen the message
This icon is not shown for messages preceding the last message seen
by everyone, in order to reduce visual noise.
Task-ID 1881001
The utility classes `Timer`, `Timers` and `CCThrottleFunction`
were only used by the feature 'is typing...', thus all those files
were in the same folder.
This commit moves the utility classes in a dedicated folder,
and introduces a folder for thread mixins, in preparation for
future features on threads that will be implemented as mixins.
This commit adds the possibility to customize the name
of a DM conversation. To do so, click on the gear icon
when hovering on a DM in the discuss sidebar.
This feature intentionally removes the access to the
settings of a DM, because the settings view only makes
sense for non-DM conversations.
Task-ID 1881001
Before this commit, when selecting an emoji from the composer,
the emoji was put at the end of the composer content.
With this commit, the selected emoji is now put in the composer
based on the position of the cursor. It also focuses the input
and set the cursor just after the newly inserted emoji.
Task-ID 1881001
With this commit, no push notification is sent to user when
to acknowledge that he just has accepted them. Also, on native
push notifications, the Odoo Bot icon now has a transparent
background.
Task-ID 1881001
Discuss sidebar now has a single category for public and
private channels called "Channels". Private channels are
prefixed with a keylock icon.
Task-ID 1881001
With this commit, the UI for "is typing..." notifications
has changed.
** before **:
In Discuss & chat windows, "is typing..." notification bar
at the bottom of the thread, inside the conversation.
** after **
In chat windows, animated '...' next to conversation name.
In Discuss, animated '...' next to conversation name in sidebar,
and text below the composer.
Task-ID 1881001
Before this commit, when accessing a channel after a page reload,
the list of members in a channel was not known until the composer
on this channel has the focus, either in the Discuss app or in a
chat window.
This was a good-enough condition when information about members
was limited to mention suggestions, which requires having the
focus on the composer. However, with the 'is typing' features
on channels, it requires being aware of the members of the channel
at the moment of the rendering in discuss or in a chat window.
This commit fixes the issue by providing the list of channel
members when retrieving information about the channel.
Without this fix, the 'is typing' notifications could sometimes
not determine the name(s) and email(s) of user(s) typing something.
To avoid having to configure the livechat channel when testing on runbot,
the admin is already set as operator of the livechat channel.
Task ID : 1912056
Closes PR #29020
Now forum only allow to post message of type 'question'.
New 'modern' UI with Bootstrap 4
New moderation modal for bulk spam
Co-authored-by: qha <qha@odoo.com>
Co-authored-by: qsm <qsm@odoo.com>
Co-authored-by: jke <jke@odoo.com>
Thanks to @qha-odoo for UI
Thanks to @qsm-odoo for reviewSsss
closesodoo/odoo#29235
Before this commit, the social media popover (used in forum but
available everywhere) may break over multiple rows if used on a relative
positioned small button. This however never occurred in standard <= 12.0
so we will consider this not a bug fix. This will however occur with
the upcoming forum refactoring, so we needed a fix for master.
This commit forces the social icons on one row and take the opportunity
to refactor the template to make a simpler and more beautiful popover
by using conventional icons and social media own colors.
closesodoo/odoo#29327
Again (and definitely?) completes https://github.com/odoo/odoo/pull/29253
As the mentioned PR forces a background on card bodies, that background
went over the card border corners as those are rounded. This commit
fixes that by adding the correct border radius on card bodies, the same
way bootstrap does it by default for card headers and card footers.
closesodoo/odoo#29325
Use a very very very light gray as body background color for
the website so that default white cards have some contrast with the
body. Also adapt the portal system to use the portal colors when the
body bg color is equal to that very very very light gray (while it was
compared to $white before).
closesodoo/odoo#29318
We now display a message informing the user that the statement line is matching a sent/to_invoice SO. The user can thus decide to follow the link and confirm the SO, create the invoice and come back on the reconciliation widget to reconcile the prepayment with the validated invoice (automatically detected).
Was task #1879015closesodoo/odoo#29312
Purpose of this merge is to update the demo data for surveys used in various
applications, notably the base one in survey.
It impacts survey (feedback survey to make coherent with odoo demo data and
remove references to odoo as a product in odoo), hr_recruitment_survey (sample
recruitment survey moved from data to demo and simplified).
This merge is linked to task ID 1912228 and PR #29303.
Several last cleaning in the product and product variant form :
- various labelling and design improvements
- sales, purchased and manufactured stat button (number of sales was
incorrect and click will now open normal sales analysis)
- now archiving related product.template if there is only one active product.product
Task-1880039 closes#28633
1/ hr_contract_salary: Remove hr.contract.advantage.template model
It was a failed attempt to make somethig generic. Sometimes we are not the only ones to choose.
Closes#28727
2/ hr_payroll: Retrieve localdict default value from a method
3/ l10n_be_hr_payroll: Merge both miscellaneous onss rules
This is useless to have 2 separate rules.
4/ l10n_be_hr_payroll: Move withholding tax reductions into the same rule
Compute the 'precompte professionnel' directly instead of having more than
10 rules just for that.
5/ l10n_be_hr_payroll: Update 'Bonus à l'emploi' up to 01/09/2018
See: https://www.socialsecurity.be/employer/instructions/dmfa/fr/latest/instructions/deductions/workers_reductions/workbonus.html
6/ l10n_be_hr_payroll: Remove duplicated salary rule
This rule is a reduction for the ONSS contribution, not a reduction for
the précompte professionnel.
The reduction for the ONSS contribution is already implemented.
7/ l10n_be_hr_payroll: Rename C.P. 218 into CP 200
The CP 218 is deprecated since 2015. See https://www.jesuisemployeur.be/banque-d-info/actualites/la-cp-218-devient-la-cp-200-qu-en-est-il-des-entreprises-qui-relevent-actuellement-des-cp-100-et-200
8/ l10n_be_hr_payroll: Use the magic formula for the PP computation
The 'Précompte Professionel' can be deducted from a formula if you're
patient enough to read https://finances.belgium.be/sites/default/files/downloads/700-formule-cle-20180101.pdf
This commit remove all the hr.salary.rules from the official tables
and use the formula instead. This should improve the performances too.
9/ hr_payroll: Show only localizations on res_config
10/ hr_payroll: Install the correct module when enabling accounting
Closes#29207
11/ l10n_br_hr_payroll_account: Remove useless dependency
12/ l10n_in_hr_payroll: Add dependency to l10n_in
13/ l10n_be_hr_payroll: Add dependency to l10n_be
TaskID: 1915125
closesodoo/odoo#29246
Purpose of this commit is to provide a new simpler survey as demo data in
survey application. Current survey is about Odoo use which is not coherent
with the demo data set used currently in Odoo. It is now a survey about
ecommerce use with an example of each different questions.
Survey tour is updated accordingly. It now uses a standard routing instead
of the test route. Indeed purpose of tests is to use real life use case
not corner case like testing capabilities of survey application.
This commit is linked to task ID 1912228 and PR #29303.
Purpose of this merge is to simplify demo survey in hr_recruitment_survey,
make it shorter, simpler and a bit more updated.
This commit is linked to task ID 1912228 and PR #29303.
It is absolutely not necessary to have a small recruitment survey as a
data. It should be a demo, notably because it is used in demo jobs in
order to have a sample survey available.
This commit is linked to task ID 1912228 and PR #29303.