This commit introduces a new badge report displayed on a full A4 page.
This report is meant to be printed for the attendee and contains more
detailed information that the existing "badge report", which is only meant to
be folded and used as a badge.
We use a lot of custom layout and classes to create a "ticket-feeling" to the
report and make it look good visually.
We also introduce a new field that allows easily customizing (outside of
studio) this report by adding "extra instructions" (how to use your ticket /
directions on how to get to the event / ...).
Side note: scss disclaimer
As the reporting engine does not allow complex class/rules building, we had to
implement this nice layout using very well placed background-image and
"pixel perfect" sized elements.
LINKS
ENT PR odoo/enterprise#19349
UPG PR odoo/upgrade#2599
Task-26779
PURPOSE
The event foldable badge is currently not very user-friendly in terms of usage
and style.
This commit aims to re-work it visually as well as getting rid of multiple
technical flows (unnecessary fields / no studio anchors / ...).
SPECS
Preliminary cleaning : Unify both foldable badge templates into one.
The "event badges" report can be printed from 2 different sources, from the
event.event itself as a preview and from the event.registration as an actual
badge for a specific attendee.
The implementation was done using two different templates, leading to a lot of
duplicated code and potential issues when editing one template that would not
modify the other accordingly.
This commit unifies both templates into one.
When the report is printed from the event as a "preview", we simply check that
the attendee variable is missing and print placeholders instead.
Main changes : Rework the whole foldable badge template
1. Get rid of unnecessary fields
The foldable badge template used several fields on the event.event model itself
that would allow customizing the report per event.
However, there were actually no way for the user to access and edit those
fields, as they are not part of any views.
We therefore removed them (badge_front, badge_back, badge_innerleft,
badge_innerright, event_logo).
And instead offer a single new field (ticket_extra_instructions), available on
the form view of the event, that allows to easily customize the foldable badge
and adding instructions specific to this event (how to come / what to bring /
...).
2. Visual changes
The report was re-worked to make it look a bit more recent, as the previous
look was very basic and was not very attractive.
This was done using a specific scss file that allows defining rules without
bloating the template with long style attributes.
In addition, we added some pictures that help the attendee understanding how to
correctly fold the printed A4 sheet into a badge and slide it into the holder.
All the information that were previously on the report should still be there.
3. Relocate action from website_event to event
As a bonus, we moved the reporting action from website_event to event, in order
to have everything that is related to this foldable badge in the same module.
Side note: scss disclaimer
As the reporting engine does not allow complex class/rules building, we had to
implement this nice layout using very well placed background-image and
"pixel perfect" sized elements.
You will see a lot of hardcoded numbers, mainly on heights, but it can't be
helped.
LINKS
ENT PR odoo/enterprise#19349
UPG PR odoo/upgrade#2599
Task-26779
Before this commit, trying to print a registration without a name
specified (not required), was failing
Fixesodoo/odoo#38564
Replace and closesodoo/odoo#38582
Courtesy of Swapnesh Shah
closesodoo/odoo#38821
X-original-commit: a21a81e98c569098d254781318b0030f30b02181
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
When printing the badge of an attendee, several information are not
shown. This is due to the BS4 migration.
Closes#29195
opw-1912074
closesodoo/odoo#29221
- Add a method for generating an image data URI, and expose it in QWeb context
- Fix reports, website templates or mail templates with data hardcoded
data URIs, to use the helper (Python cases), or the existing
kanban_image helper (for JS cases)
This will gracefully handle SVG support in addition to classical image
formats.
Closes#26635
Today, Odoo is really tricky to use without seeing the screen, it must be improved to be usable.
This PR forbid to use labels without a "for" attribute, add some title, rule and aria attributes in HTML. With that, Odoo will be fully usable with a screen reader.
* [IMP] Labels must have a for attribute. Improve accessibility.
* [IMP] Better error message when trying to read a missing cached value
* [FIX] Add some aria-label and title attributes for screen readers.
* [FIX] Template name is not included in the error message in case of SyntaxError in QWeb
* [FIX] Improve the Tour failed at step error message to be more explicit.
* [IMP] Add aria-labels
* [FIX] Add missing aria-label on failing test
* [IMP] aria-hidden means hidden. Fix all bad aria-hidden and hide aria-hidden for all.
* [IMP] Color names on kanban views and many2many tags
* [IMP] Add some checks on views for accessibility.
* [IMP] Add `alt` attribute on `img` tags.
* [IMP] Add aria-label and title on non-described icons
* [IMP] Add button role to widgets with btn class
* [IMP] Translate aria and formatted attributes.
* [IMP] Remove wrong aria-labelledby
* [IMP] Add menu role on dropdowns
* [IMP] Buttons must be focusable
* [IMP] Add aria attributes on progress bars
* [IMP] Improve accessibility of basic widgets
* [IMP] Change main layout to more semantic tags
* [IMP] Add menuitem role when missing
* [IMP] Remove wrong role='presentation'
* [IMP] Improve accessibility of tab panels
* [IMP] Add aria-invalid on invalid fields
* [IMP] Add aria-sort on ordered columns
* [IMP] Add role on alerts
* [IMP] Use dialog role, header, main and footer tags for modals
* [IMP] Add labels on o_status
* [IMP] Improve accessibility of kanban view with feeds and articles
* [IMP] Add alerts in case of new messages
* [IMP] Add widget, navigation or img role to aria-labelled items
Otherwise the time is printed using the timezone on the user printing
the badge. This fix is inspired by how the times are rendered by
website_event (e.g. website_event.index).
Using the date_{begin,end}_located fields was considered, but their
formatting is not configurable and they result in lines that don't fit
well on the badge.
opw-1853238
Purpose
=======
In python2 a binary field value is retrieved as a string. Example: company_id.logo = u'xyz'
In python3 a binary field value is retrieved as a binary. Example: company_id.logo = b'xyz'
When trying to render an image on a template, we should pass a stringified version of it.
Specification
=============
Pass the method to_text in the template rendering context and use it.
Purpose of this commit is to clean and uniformize report naming through
various addons. It has been chosen to name them using a formatting like
<report_name> - <object_name or suffix> .
- RML Reports
- Webkit Reports (most part already removed by 13b9982c62)
- LocalService in netsvc.py
- rename attributes like rml_% to report_%
- rename ir.actions.report.xml to ir.actions.report
- allow rendering directly on an ir.actions.report by calling render method
- remove 'controller' report_type
- remove unused res.font stuff
- remove print_report method in models.py (not used)
- restore removed call to pdftotext process in test_reports
* reporting: remove report.event.registration as it can be replaced by
pivot and graph views on event.registration model directly. The
custom SQL view does not add any valuable information;
* event: correctly take limitations from event category and check
minimum seats is lesser or equal to maximum seats;
* event: reorganize a bit the form view
* avoid some kind of random ordering of buttons;
* move seats availability directly in the form view;
* ticket page is now used only for ticketing purpose, not a mismatch
with seats;
* registration: attendees can be set as done only for confirmed events
to avoid confusion when working with draft events;
Misc usability
* event.type: rename event type to event category to have a unified
term across various event addons;
* event: stop tracking active field as it does not add interesting
information; it should not toggle everyday;
* event: track location as it does add valuable information;
* event: rename some labels to ease user experience;
* event.mail: add missing description and rec name;
Since 3d04e44880 [0], the class `article`
is used instead of `page`. As reports not using `external_layout` does
still manually used `page` class as wrapper, there were not rendered
properly. Force these reports to correctly wrap their content into an
`article` div by using a dedicated template.
Closes#15118
[0] more precisely https://git.io/vM58c
- Preserved explicit 3rd-party copyright notices
- Explicit boilerplate should not be necessary - copyright law applies
automatically in all countries thanks to Berne Convention + WTO rules,
and a reference to the applicable license is clear enough.
Now,
- event contains the HTML badge fields and the report (and report templates) to print badges
- event_sale add the ticket type on badges
- website_event allow the edition of badge throught website editor.
When the editor will be available in backend, event will be allow to edit badge report, so the action should be moved from website_Event to event module.
- Several Modules have been splitted into several apps
Examples :
Human Resources : Splitted into Leaves, Recruitment, Expenses, Appraisals, Timesheets, Employees, Payroll
Marketing : Mass Mailing, Events, ...
Messaging : Chat, Agenda, Notes, Address Book, ...
- Generally, the related reports have been moved in the apps, as last menu
- Also, configuration menu (no_one group) have been moved into a config root menu
exception made for the warehouse and lunch modules
- Configuration for typical frontend modules have been moved into the website settings
Related modules : Ecommerce, blog, slides, forum
- When they are present, menus like 'product' or 'customers' have been moved
ex : Customers in Sales menu, Product in POS menu
- A lot of sequences and xmlids have been added or modified in this commit
- List of apps :
1 Chat : Inbox, Channels
2 Agenda : Calendar
3 Notes
4 Address Book : The view contact is still laying in the mail module (1 app => 2 icons)
5 eCommerce : Still to define : Config + Orders Analysis + Shipping + incoming Amazon module
6 Sales : Dashboard (Sales Team Kanban), CRM, Sales (note that they are splitted into 2 submenus)
Assignation, After-Sales (Invoicing and Services), Reports
7 Point of Sale : Dashboard (POS status), Orders, Reports
8 Project : Dashboard (Project Kanban), Search (all tasks, issues), Incoming Forecasts module, Reports
Project.issue.version feature has been removed completely
9 Members : Dashboard (Members Kanban), Report, Config
10 Timesheets : Time Tracking, Approvals, Reports
11 Purchase : Purchase, Control (Products and Bills)
12 Warehouse : Dashboard (Warehouse Kanban), Operations, Inventory Control, Schedulers, Configuration
13 Manufacturing : Same menu structure
14 Mass Mailing : Mailings, Campaigns, Reports
15 Events : Events, Reports
16 Lead Automation : Campaigns, Reports
17 Surveys : Surveys, Reports
18 Human Resources : Dashboard (Departments Kanban), Employees, Contracts, Engagement (Gamification)
19 Recruitment : Job Positions, Applications, Resumes & Letters, Reports
20 Expenses : Expenses, Approvals, Reports
21 Leaves : My Leaves, Approvals, Reports
22 Appraisals : Appraisals, Interview, Reports --> Will probably be modified by the incoming refactoring
23 Payroll : Current Menu
24 Lunch : My Lunch, Manager, Configuration
25 Accounting : Same menus currently, waiting the new accounting to be merged
26 Fleet : Current menu
27 Sign : Incoming docusign module
28 No root menuitem with this sequence
29 Attendance : Attendance, Reports
Sign in/out by project feature has been removed completely
30 Link Tracker (group_no_one) : Link Tracker, UTMs
New view added : URL Shortner, which is the frontend view embedded in backend
31 Versionning : Website domain, Versions, Experiments
32 Slides (group_no_one) : Channels, Categories, Slides, Tags
33 No root menu item with this sequence
34 Livechat : Channels, History, Reports
35 Dashboards : My Boards, Configuration
36 App Store : Local Modules, Apps, Updates
Last Settings : Incoming Dashboard Settings, Sales, ...., Website Settings
General Pattern for all modules' settings :
| Module_name
|-- Settings : General Config view (checkbox screen)
|-- Record setting 1
|-- ...
|-- Record setting n
Example for Sale module
| Sales
|-- Settings : Checkbox screen
|-- Quotations
|---- Quotation Templates
|---- Report Layout Categories
|---- Contract Template
|---- Invoice Type
|-- Contract
|---- Deduplicate Contacts
|-- Delivery
|---- Delivery Methods
|---- Delivery Pricelist
event:
- added tip
- default subscription/reminder/thanks templates for registrations are now using
the reply_to defined on the event
- fixed check of available seats: use seats_availability field, unlimited events
should never trigger the constraint
- added a sequence on scheduled emails on events
- config: wording improvements
- various improvements in event, registration, event_mail and event_report views
event_sale:
- removed override of seats_max: should not depend on available seats in
tickets. Indeed you may have less available places than the sum of seats for
each ticket type, for example if you have 0-10 VIP and 0-20 Standard tickets
for a 20-seats event.
- removed a duplicated view override
- added a seats_availability field on tickets, same meaning as on event.
- improved event form view: registration tab is now replaced by the tickets tab
when tickets are used
website_event:
- better management of sold-out event in the front-end, when doing registrations
website_event_sale:
- removed register link on the event kanban view. There is no need to to from
the back-end to the front-end from the kanban view. The published button on the
event form view already allows to go to the front-end view on the event
- better management of sold-out event in the front-end, when doing registrations
- fixed a template that was in customize and should not
website_event_track:
- wording improvements
- small improvements in the front-end of tracks
This commit fixes lots of usability problems in the reporting views.
eg: missing fields in the reports, labelling inconsistencies, broken/outdated/unused filters and group bys...
Detailed changelist
-------------------
account/Invoice Analysis:
- "Product Category" vs "Category of Product": labelling consistency
- group by Analytic Account
account_voucher/Sales Receipt Analysis:
- remove filter on Pro-forma
crm/Lead & Opportunities Analysis:
- "Exp." vs "Expected": labelluing consistency
crm/Phone Calls Analysis:
- remove Todo and My Phone Call filters
- fix My Sales Team(s) filter
crm_claim/Claims Analysis
- remove My Case(s) filter
- fix My Company(s) filter
- remove group by Sales Team
- fix label Creation Month
crm_helpdesk/Helpdesk Analysis
- remove My Case(s) filter
event/Events Analysis
- remove My Events & Show Confirmed Registrations filters
- fix labelling of Attendee / Contact group by
hr_holidays/Leaves Analysis
- remove My Requests filter
hr_recruitment/Recruitment Analysis
- remove My filter
marketing_campaign/Campaign Analysis
- fix labelling
mrp_operations/Work Order Analysis
- add fields Product Template, Product Category, Responsible, Routing
and BoM
- fix labelling group by Planned Month
point_of_sale/Orders Analysis
- add fields Product Template, Invoiced, Point of Sale, Public Category,
Warehouse and Pricelist
- fix Year filter
project/Tasks Analysis:
- remove My Task filter
project/Issues Analysis:
- remove My Issues filter
- remove Task group by
purchase/Purchase Analysis:
- fix quantity field into float
- add fields Product Template, Product Category, Partner Country, Fiscal
Position, Analytic Account and Commercial Entity
- add group by Partner Country and Fiscal Position
- fix labelling "Product Category" vs "Category of product"
sale/Sales Analysis
- fix labelling "Product Category" vs "Category of product"
- add fields Product Template, Paid, # of Paid Lines, Partner Countru
and Commercial Entity
- remove filter My Sales
- add group by Partner Country
sale_stock/Sales Analysis
- fix label name of shipped_qty_1
Credits
-------
Analysis and code courtesy of Sébastien Versailles, Quentin De Coninck,
Yannick Tivisse and Richard Mathot {sve,qdc,yti,rim}@odoo.com
(congratulations if you've read this boring commit message)
Registration are now for one attendee only. When buying several seats for an event
you have now one registration for each attendee.
event: nb_register field is removed; as well as unnecessary user_id and it subscribe /
unsubscribe behavior. Also slighly cleaned some views.
event_sale: do not auto confirm registrations linked to a draft sale order. Note: strange
origin is a char field, not a sale_order_id. Added a small wizard to edit attendees
data when confirming a sale order containing event related lines.
website_event: when buying free tickets, ask for attendee details. Added template,
controllers to handle that behavior.
website_event_sale: when buying tickets, ask for attendee details. Events ecommerce
should be better integrated with online events, using inheritance to add details
instead of being very different.
Added two features in kanban view
- having a data-routing attribute on the oe_kanban_global_click
container allow to have a custom routing instead of only
'form view' / 'edit view'. This is used for example to go to
the website view of events.
- allow type=url along with object, action, ... to have some specific
urls for links.
* remove old 'day', 'month', 'field' and replace them by the actual
date/datetime field
* remove weird cast to char when creating the view to prevent crash
when grouping on them
* remove duplicates (such as 'creation_date' and 'create_date')
* fix typing errors (field type date defined as a datetime in the
postgres view)
* fix search view definition
A squashed merge is required as the conversion of the apiculture branch from
bzr to git was not correctly done. The git history contains irrelevant blobs
and commits. This branch brings a lot of changes and fixes, too many to list
exhaustively.
- New orm api, objects are now used instead of ids
- Environements to encapsulates cr uid context while maintaining backward compatibility
- Field compute attribute is a new object oriented way to define function fields
- Shared browse record cache
- New onchange protocol
- Optional copy flag on fields
- Documentation update
- Dead code cleanup
- Lots of fixes