Skip to content
Snippets Groups Projects
Unverified Commit b07dfedb authored by Robot Odoo's avatar Robot Odoo Committed by GitHub
Browse files

[FIX] lunch: make it work on mobile


This module didn't worked on mobile: user cannot select the products or
see their cart.

This commit reworks the LunchKanbanWidget template and introduces a
dedicated template for mobile. This template introduces a button at the
bottom of the screen to toggle the "cart" widget on mobile (hiding it by
default).

It tries to make the best use of the existing Bootstrap classes allowing
to have a more responsive layout and reducing the custom CSS required by
this module (both in desktop and in mobile).

This commit adds a decent JS tests-suite (mobile & desktop) to this
module as the existing one left substential parts of the UI untested
(opening wizard when clicking on a kanban record, cart's lines content,
clear cart button, widget structure and content based on the state...).
Those tests are also less based on DOM nodes order/tag names and use
instead dedicated classnames.

It also modifies the LunchKanbanRecord click handling to had a dedicated
event handler instead of overriding the default _onGlobalClick() and
make it more testable.

Finally this commit also remove unused code.

Task ID: 1945032

closes odoo/odoo#31428

Signed-off-by: default avatarAdrien Dieudonné (adr) <adr@odoo.com>
parents 7e35c40c bdc0b4b8
Branches
Tags
No related merge requests found
Showing
with 1335 additions and 429 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment