summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/web_client.js
AgeCommit message (Collapse)Author
2017-04-11[REF] web, *: redesign all JS viewsGéry Debongnie
This commit introduce a full redesign of all JS views. We started basically from scratch. The goal was to unify all the various views under a common framework, to make them testable, to make then usable in different conditions (in studio, or in the frontend), and to make our lives easier. Some important points are: - we introduced new coding guidelines (camelCase, 80 chars width, ...) - we have a brand new testing framework (still QUnit based) - kanban view moved to the web addon - calendar view (formerly web_calender) moved to web as well - the tree view was removed - all new code should be documented We hope that this code is the start of a new era for the Odoo web client, we want to have a high quality codebase, well documented, well tested, well designed. Work done by the framework team: mostly aab, ged, chm, dmo, qsm
2016-12-05[REM] *: remove ir.needaction mixinJérome Maes
ir.needaction_mixin is not used anymore by the webclient. From 9.0, the concept has changed: this feature is now available in mail module, with the mail.thread mixin, and message_neeadction field. Remove all code handeling needaction bullet and counter on ir.ui.menu, knowing that since 9.0 webclient does not display the counter anymore. This code was, thus, useless and some RPC calls were done for nothing, and adapt accounting reconcialiation widget.
2016-10-17[MERGE] forward port branch saas-12 up to e8e4145Christophe Simonis
2016-10-17[MERGE] forward port branch saas-11 up to ba6ca78Christophe Simonis
2016-10-17[MERGE] forward port branch 9.0 up to b14c8b3Christophe Simonis
2016-10-13[FIX] web: clear_uncommitted_changes on browser's back buttonSimon Lejeune
This is done by guarding the `on_hashchange` evant handler with the `clear_uncommitted_changes` function. Note that the url has already changed when we are in this handler, so we make sure to restore the old url when the user chose to continue its edition.
2016-09-14[MERGE] forward port branch saas-12 up to 13765b5Christophe Simonis
2016-09-14[MERGE] forward port branch saas-11 up to 19b4f5eChristophe Simonis
2016-09-08[FIX] web: company image not update when use 'Edit Company data' buttonChristophe Matthieu
Wrong class selector and must add '#' to force the browser to reload the picture because the picture is in the cache with the previous cache informations.
2016-09-08[FIX] web: traceback when click on 'Edit Company data' buttonChristophe Matthieu
Try to bind event without wait the action deferred
2016-08-31[FIX] openerp, web: make `execute` and `call_kw` invoke methods in the new APIRaphael Collet
Also refactor the test to prevent private methods to be remotely called.
2016-07-20[FIX] web: session_info: introduce `is_superuser` keySimon Lejeune
This is done in order to enable the tour service only for the superuser. Commit 6ef1644a7b3812 changed the meaning of `is_admin` to achieve this but broke the fact that some features of the debug manager are available to admin and not only to the superuser. Anyway a `is_admin` key should mean that the user is in the admin group. We could have checked client side that the uid is equal to 1 but adding a `is_superuser` key is more elegant and easier to grep. Also fix the only occurence of a uid check in the weblcient. This reverts commit 6ef1644a7b3812f4cc0d066ea74970791a4b4d54.
2016-07-05[FIX] web: allow `on_(attach|detach)_callback` callbacks to be calledSimon Lejeune
The `on_attach_callback` and `on_detach_callback` callbacks are called when an a widget is attached / detached according to the `is_in_DOM` variable. As the community's action manager cannot be detached from the DOM, we can hardcode this value to true. This allow to run these callbacks when needed.
2016-06-16[FIX] calendar,pos,web: show_application should return a deferredAaron Bohy
Also remove unused options dict from WebClient (especially action_post_login)
2016-04-22[IMP] base, web: add type=fullscreen to ir_actionsGéry Debongnie
With this commit, actions can have a type=fullscreen. This means that the navbar will be hidden, for the action and for all subsequent actions open in the breadcrumb There is no real security behind this, this is just a feature for convenience, so users can bookmark an url an open some action in a way that they are not distracted by anything. In short, this is some kind of light 'kiosk' mode.
2016-04-21[REF] web: stop duplicating webAaron Bohy
Avoid duplicating web addon in enterprise by extracting a common basis. Enterprise features stay in enterprise, but use that common basis. Mainly: - JS refactoring and linting - Conversion of .sass into .less split into multiple files - Templates cleaning and DOM simplification - Re-generation of web.pot, and update of .po files
2016-03-18[IMP] openerp,web: cache of actions, fields(_views) and filtersAaron Bohy
Introduction of 'data_manager' service which handles meta-data related to actions and views (fields_views, fields and filters). Ideally, all RPCs to get that kind of information should go through data_manager, as it holds an internal cache.
2015-09-30[FIX] web: web_client: do_action: add missing returnAaron Bohy
2015-08-21[REF] mail: model update for NewChatterThibault Delavallée
Main changes : - mail.notification model is removed. People do not receive notifications anymore. Instead two ways of following documents exist - using a channel; messages will be displayed on the channel itself in a near future commit - following with its partner; messages will all be considered as needaction, using a new m2m table. People should receive less needaction messages by following less records by themselves. There is no more read / unread state anymore. Instead only needaction messages are considered. Todo (Favorites) messages still exist, and are stores on a new m2m table instead of using decorated notifciations. - the main filter for documents is not message_unread anymore, but message_needaction. A lot of views and filters have been updated accordingly. - the vote feature has been removed
2015-07-30[REF] web: move barcode_events to module barcodesArthur Maniet
If the module barcodes is installed, a BarcodeEvents singleton is automatically instanciated. It listens to keypresses and, when a sequence of keys represents a barcode, it broadcasts a 'barcode_scanned' event on core.bus containing the barcode string.
2015-07-23[IMP] web: New notification systemqsm-odoo
Backport of the Notification system
2015-07-10[IMP] web: split model.js into model.js and data_model.js. Web js modules ↵Christophe Matthieu
must call web.DataModel.
2015-07-01[IMP] web,mail: use of Modals to confirm changes discardAaron Bohy
instead of the browser confirm dialogs, for the sake of uniformity.
2015-06-30[REVERT] web,point_of_sale: cordova integrationAaron Bohy
introduced by forwardport: a3041949364141eaa66b22ab0d72227b675df324 initial commit in 8.0: 19eda68547917cfabe923ea41edb8ac7beb141b6
2015-06-25[MERGE] forward port of branch saas-6 up to 81b5c60Christophe Simonis
2015-06-23[FIX] web: patch community client to use cssGéry Debongnie
this change allows every addons to convert their css to use the o_web_client class, which works in enterprise edition.
2015-05-29[FIX] barcode_events: set parent to WebClient during creationJoren Van Onder
2015-05-29[IMP] barcode_events: implement a new way of dealing with barcode eventsJoren Van Onder
Implement a new way of dealing with barcode events. This was necessary because the old way of dealing with input coming from barcode devices did not stop keyevents. This lead to all kinds of issues (eg. barcode reader output being inserted as tender in a paymentline). This new class inserts itself so that it handles all keyevents before everything else. This means that it has authority on what keypress events pass and which ones do not. It differentiates between 'real' keyboard input and input coming from devices by buffering events. When a certain amount of events come in fast enough, it is handled as a barcode and a 'barcode_scanned' event is emitted on core.bus. When buffered events are decided to not be a barcode, they are recreated and redispatched.
2015-05-04[IMP] web: add traceback to javascript error reports ( on Chrome and FF )Frédéric van der Essen
2015-04-30[IMP] web : replace timezone warning icon with a form widgetVidhin Mehta
2015-03-20[IMP] Web: views.js, view_editor.js: DebugManagerAaron Bohy
Creation of a widget for the DebugManager and move it from the ControlPanel to the Systray. Refactoring of the widget to improve/facilitate the way of adding options in the DebugManager as the view_editor does. Add a do_action() function in the WebClient that forwards the action to the main ActionManager so that widget that are not in the scope of the ActionManager (e.g. Menu) can performed actions as well. Note: The DebugManager is currently in the Systray but it will finally be moved to a dedicated spot above the ControlPanel.
2015-03-19[IMP] web_client.js: trigger `web_client_ready` on core.busSimon Lejeune
This way, any module requiring web.core has access to this hook. var core = require('web.core'); core.bus.on('web_client_ready', this, function() {console.log('ready')});
2015-03-18[IMP] web+addons: improvement to module systemGéry Debongnie
The module system needs to know the dependencies of a given module before executing the function. This is why the dependencies were defined once in an array, and then were described one more times in the call to require. But a trick can simplify this: the boot function can parse the string representation of the module and extract the calls to require from it. It is more work for the processor, but it leads to simpler module definitions.
2015-03-18[REF] web: add module system to the web clientGéry Debongnie
This commit introduces a new module system for the javascript code. Instead of using global (namespaced) variables everywhere (like openerp.web.whatever, ...), each file declare one (or more) module with its dependencies. Each module will be loaded after its dependencies, and will be given a reference to the return values. This change is a massive departure from the way the client worked previously. It will sadly break some/most history, but I am sure that the future git ecosystem will allow you to easily browse the history past this revision (one can dream). This commit feature: * main namespace is now odoo instead of openerp * a way to define modules and dependencies (inspired by requirejs) * many files have been splitted in simpler subfiles * basic support for debugging in odoo.__DEBUG__ * no global variable (i.e. nothing in window.openerp) * many bug fixes, many new bugs Future vision: this modularization should simplify future code development, simplify debugging and will allow a serious testing effort