On tablet, the call-to-action to install the app shouldn't show the QR
code... to be scanned by the tablet itself.
This commit fixes it by using the platform detection instead of the
screen size.
Steps to reproduce:
- Open "Expenses" on tablet
- ensure no records are listed (use filters if needed)
- click on the call-to-action to one of the app store
=> opens the QR code's modal instead of going directly to the store
task-2349194
closesodoo/odoo#79514
X-original-commit: e7cbced2ffff189f6aed9ce0b0ab8eb819dbd088
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
This commit removes all the 'extend' initially introduced to avoid code
repetition and ensure visual consistency across Bootstrap and Owl dropdowns.
Despite achieving the desired results, using 'extend' in this context
was seriously impacting the bundle generation time, probably due to an
underestimated amount of Apps' legacy-code applied on these elements.
In order to achieve the same results, the chosen strategy is to add
Bootstrap default classes directly into Owl dropdowns.
Also, it moves code related to bootstrap dropdown in 'webclient.scss',
leaving 'core/dropdown/dropdown.scss' for Owl code only.
Due to the discrepancies between Bootstrap and Owl html
structure, the '.dropdown-item' class could not have been added
directly to Owl's '.o_dropdown_item' itself, without refactoring
the Dropdown component structure.
// ==== Bootstrap 4.6 default Structure ================================
<div class="dropdown-menu">
<button class="dropdown-item" type="button">Action</button>
<a class="dropdown-item" href="#">Another action</a>
</div>
// ==== OWL default Structure before this commit =======================
<ul class="o_dropdown_menu">
<li class="o_dropdown_item">
<span>Action</span>
</li>
<li class="o_dropdown_item">
<a href="#">Another action</a>
</li>
</ul>
// ==== OWL Structure after this commit ================================
<div class="o-dropdown--menu dropdown-menu">
<span class="dropdown-item">Action</span>
<a class="dropdown-item" href="#">Another action</a>
</div>
// ==== web.assets_backend.css Bundle Generation Comparison ============
With all modules installed (enterprise edition over runbot):
Before this commit, bundle took ~2.5s and ~4s to generate and weighted ~322kB (~2.5MB uncompressed)
After this commit, it takes between ~1.2s and ~1.6s and weights ~257kB (~1.6MB uncompressed)
closesodoo/odoo#77649
X-original-commit: 84715436d87bb05b421bc9ccaacda67d07571690
Related: odoo/enterprise#21370
Signed-off-by: Géry Debongnie (ged) <ged@openerp.com>
Co-authored-by: Stefano Rigano <sri@odoo.com>
Co-authored-by: François Georis <fge@odoo.com>
Co-authored-by: Bruno Boi <boi@odoo.com>
Requires markup every markup-using tip content as Markup. Would be a
nice occasion to migrate everything to a markup-safe markdown I think,
especially if we could migrate the translations so we don't lose them.
Force a small margin to the left of the upload button in the expense
list view.
Previously the create and upload button would be stuck to each other.
Task ID: 2582448
closesodoo/odoo#72951
Related: odoo/upgrade#2602
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Currently, in the expense module, demo expense products are more
specific to the expenses and label tooltip of the cost field doesn't
convey proper difference between fixed and variable cost of
expense products.
So in this commit, replace old expense products with new expense
products and recreate expenses and reports using these
categories(products). it will provide better experience on demo.
overwrite label tooltip of cost field in expense app to convey proper
difference between fixed and variable cost of expense products.
closesodoo/odoo#68955
Task-id: 2491238
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Display a confirmation dialog when a user creates duplicate expenses.
Two expenses (or more) are considered duplicates when they share the same
date, amount, product, employee, company and currency.
closesodoo/odoo#64190
Taskid: 2368636
Related: odoo/upgrade#2061
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
In the expense list and kanban views, there is always a vertical
scrollbar. This is due to the presence of a custom statusbar
displayed above the view. This commit overrides the 'height: 100%'
and 'min-height: 100%' rules set on those views to remove the
scrollbar.
task-2334044
closesodoo/odoo#63681
X-original-commit: d544e584c38f27f8a43f8939d51118f6bf2e0bdc
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
purpose of task is to solve the design issue on hr expense banner
when there is horizontal scrolling on tree view then the banner on
top will not adapt it so there is empty space at last.
So in this commit, Fix the position of the expense header so it should
not scroll with the tree.
closesodoo/odoo#60105
Taskid: 2336309
X-original-commit: 7ba0bc47d1404d5ac4bbf8cb5dcca7937558bd1a
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
When there is no expense, a messages is shown: "Did you try the mobile app?"
When clicking on the "Download on the App Store"
or on the "Get it on Google Play" buttons, generated QR codes have some invalid data before it:
- 002
- 1
- <the url>
This commit removes datas that are before the url so only the url is displayed.
closesodoo/odoo#60104
Taskid: 2326303
X-original-commit: a130784131c84326b2482ab3c4eea6e0bb3d881c
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
The kanban view was not properly using the custom javascript class.
closesodoo/odoo#58567
Taskid: 2340951
X-original-commit: dbc3785f5057a784104c434d6f0a06f2e9097208
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Expense header was displayed in all tree & kanban views.
This commit removes the header in other views than 'My Expenses' menus
because the expense header should only be visible in the 'My Expenses' menu
Task id: 2341766
closesodoo/odoo#58040
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
PURPOSE
Review the tips and digest layout design to make sure they have a WOW effect
and increase trial conversion/retention.
SPECIFICATIONS
“Snap pictures of your receipts with the remote app”
See code for specifications.
LINKS
Task ID-2274264
COM PR: odoo/odoo#53580
ENT PR: odoo/enterprise#1139
X-original-commit: 48bc75d340fa3a6d3c98bdd4b9f978036109f403
Currently, when a user created with default access rights,
but doesn't have employee linked with user then it will generate a
traceback because if user is not linked with employee then
it will return null so due to that while rednering the template
error was generated.
So in this commit, fix the treaceback by returning default values
if the current user had no employee
closes odoo/odoo#53161
Taskid: 2262636
Closes: #51687
X-original-commit: 96de35eda1a8e6e5086eb8221e939f3f737a9a6c
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
The nocontent helper now shows a more descriptive image and a link to
the mobile application.
closesodoo/odoo#52972
Taskid: 2277641
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
This commit moves some step utils in a dedicated file and add new ones.
These steps will be very useful for the Main Flow Tour to avoid
duplicated code.
To do this, we also had to transform it into functions to allow
utils to call each other. Existing one are converted for
standardization purpose.
Note that 'WEBSITE_NEW_PAGE' wasn't considered as an util.
This is a very simple step only used twice.
- if checked in settings, OCR can be used to get infos from the attached receipt image
- set default product to EXP_GEN when created from picture
- use "register_as_main attachment" when expenses are created from receipt images
- Add the upload button to the kanban view to see it immediately in the mobile version
and use it to create expenses from pictures. (with or without OCR installed)
closesodoo/odoo#39559
Related: odoo/enterprise#6493
Signed-off-by: Florian Daloze (fda) <fda@odoo.com>
Purpose of the task is to improve the mobile user experience of
the Expenses app by adding the upload button to the Expenses
kanban view.
Task ID: 2152155
closes odoo/odoo#41839
Closes: #41839
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
For better user experience, there should be a 'UPLOAD' button on'hr.expense'
through which user can directly upload a single or multiple documents and
according to the number of documents, blank expense record with attached
document should be generated. These records should be in 'draft' state.
TaskID: 2040887
closesodoo/odoo#35400
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
As we now have a new debug mode 'tests' which load a new asset bundle
containing tour-test files, we moved those files to a new folder hierarchy.
That will clean the .js files trees.
Also, those files should be included in the new asset.
Basically, the .js tour files (not test) should be inside /static/src/js/tours
while .js tour test files (test=true) should be inside /static/tests/tours next
to QUnit tests, inside a tours folder.
+ test_new_api: don't run the test in debug assets
task-1934445
Comes with https://github.com/odoo/enterprise/pull/4281Closes#33213
*: crm,
hr_expense,
hr_recruitment,
point_of_sale,
project,
sale,
stock,
web_tour,
test_main_flows,
test_new_api
To sum up:
- Click on "Apps Menu" then the app item.
(previously: click on '+' then the app item).
- Click on navbar section menu item.
(previously: click on sidebar section menu item).
Several applications have an index.html file that is used to fill the html
description of the module. However those descriptions are generally not
up to date: they contain outdated screenshots, feature descriptions are
not maintained, ...
Instead we just rely on the discover button that redirects on the application
website. It has more chance being up to date. Moreover updating a website
is easier than updating the index.html of a module.
This commit is related to task ID 47179 and 1861544. Related PR are #22689
and #25556. First one is about classic applications while second one is about
website applications.
Co-Authored-By: Nimesh Jethva <nje@odoo.com>
Before this commit, Odoo used checkboxes in three different ways:
- A simple <input type="checkbox"/>, mainly in the frontend. The style
is browser dependant.
- Same as above but with the BS3, checkbox structure. The style is still
the same, but the alignement is supposed to be better (which is not
always the case).
- The Odoo official structure:
```
<div class="o_checkbox">
<input type="checkbox"/>
<span/>
</div>
```
which allows to have a cross-browser checkbox style and correct
alignements.
The goal after this commit is to only use the BS4 *custom* checkbox
structure to achieve the same goal as our official structure (and
remove that one):
```
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" id="customCheck1">
<label class="custom-control-label" for="customCheck1">...</label>
</div>
```
/!\ Labels are now required (use a zero-width space if necessary)
PURPOSE
=======
1. Unified product demo data
2. Less demo: one per use case
3. Demo data for all models
Specification
=============
1. Refactor all the brol in the demo data
2. Adapt the tests to make them green, as some products are
renamed, removed, created in python instead of as demo data
...
We need to be able to change an expense report before submitting it, for
this we add a new step in the expense process (a draft state for the
expense sheets).
Task #41700Closes#24806
- Change the differents states of hr.expense to have
ToSubmit, submitted, approved, refused and paid.
- Add a responsible field on employee model. The responsible is a res.user that belong to the group "hr_expense.group_hr_expense_manager"
The commit change too a "vals" variable that changed in a git rebase operation.
- Make the other_info tab invisible if the user doesn't belong to account.group_account_user.
- Make expense wizard (for expense lines) editable if expense is in reported mode, so when the sheet is in To submit state.
- Move a tour from expense form to expense_sheet form
- rename two fields (attachments and manager)
- The buttons "approve" and "expense" must be hidden if the user isn't the expense responsible.
- The description field of expense line must be editable in draft, reported and refused state
- Add a subtype to follow responsible changes on expenses sheets
- subscribe responsibles of an expense to followers of that expense
- hr_expense requires sale_expense instead of sale_management
- remove one tour step and change texts of some others
- remove header from expense line wizard
- add tax field in form view for expense
- change the display name of some fields and other titles.
- remove the expense report and improve search bar for expenses in report.
Purpose
=======
User tests have been made by the Product Owners team. It showed that the planners are not used by new users on Odoo due to several reasons (They are too static, too heavy to use,...)
Specification
=============
Remove the module and its different applications. The onboarding on the business flow will be improvement in the weeks to come.
Steps:
- In home, expense app icon: "Go to the expense
to attach a receipt"
- In list, on create button : "Click here to create
your first expense and add it to below."
- In form, on save button : "Once your Expense is
ready, you can save it."
- In form, point out the chatter "Attach your
receipt here."
- In list, point out record selection: "Select
expenses to submit them to your manager"
- Point out "Action": "Click on Action Submit To
Manager to submit selected expenses to your manager"
- In expense sheet point out approve “Approve the
sheet here. Tip: if you refuse, don’t forget to
give the reason thanks to the hereunder message
tool".
Change color #a24689 to #875A7B
Commit https://github.com/odoo/enterprise/commit/8ac1c19fac7615fecd51e670f798d13158a4e53c
changed the odoo interface violet by changing the main LESS variable
but forgot there was many direct occurences in XML/HTML/... (for
example for the mobile browser color).
Even if it's community the odoo interface violet is used at many places
(module description, XML demo data, ...).
1/ Modify the no content help message for hr_expense with a dynamic part
which describe how to create a new expense by mail
2/ Mail gateway mechanism. New customizable email alias expense@domain
that creates a new expense by sending an email to it. Check several things
- Check that the email_from is the same than one of the employees or than
on of the related users to employees. If not, send back an email to say that
the expense will not be created.
- If the email address is valid, check if something is between brackets '[]'
If it is the case, check if it is linked to a product internal reference
and set it accordingly. If nothing is found, use a default product
'Fixed Cost'
- If one/several float(s) are found in the mail subject, take the last
occurence and set it as the expense total amount.
3/ If a product template is created, to not add taxes on it. We don't expect it
to have additional taxes
4/ Under Expenses -> Configuration -> Expense Product, use a simplified product
view with only the needed fields.
5/ When generating the account move lines, use the account defined on the expense
line, not the sheet
6/ When creating a payment, make a reconciliation on the payable account move lines
That way, if the total amount on the expense is paid, the expense will be set to
paid automatically when registering a payment
7/ Add a one-page planner to explain how to use the email alias
8/ The field account_id on the expense sheet was informative. After some tests, it
seems that it's more confusing than helping. So we removed it
9/ Add a domain on the field 'bank_journal_id' to select journals of
type 'cash' or 'bank'
10/ If the number of expense lines is equal to 1, the expense summary on the expense
sheet should be the same name the line. So the process can be done in one click