summaryrefslogtreecommitdiff
path: root/addons/web/static/src/xml/base.xml
AgeCommit message (Collapse)Author
2017-07-07[FIX] web: explicit color attribute for m2m_tagsMartin Geubelle
Before this fix, the field 'color' was hardcoded in the m2m_tags widget, which means that: - one couldn't specify another field (problem for custom models, with x_...) - if the related model didn't have the field 'color', a warning was raised by the server Now, the color attribute needs to be specified on the widget options if one wants to display colored tags. If the color is not specified, the tags will be displayed in grey.
2017-06-29[FIX] web: handle 'domain' key returned by onchangesAaron Bohy
Onchange RPCs return an object that may contain a 'domain' key. When it does, its value is an object whose keys are field names and values are the new domain for the corresponding field. Before this rev., the 'domain' key was totally ignored by the BasicModel. This feature is used for example in the account.payment form view (go to an open invoice, click on 'Register payment'): the domain of field payment_method_id is updated by the onchanges (e.g. when changing the journal_id). As the domain was ignored, it always displayed all possible payment methods.
2017-06-28[FIX] web: deal with reference fieldsMartin Geubelle
The reference fields haven't been correctly implemented with the new views. This commit restores their behaviour. Note that an small improvement has been introduced in this commit. Before saas-16, a `name_get` was done for each record (so 80 if the field was displayed in a full list view), which is not optimal. The calls are now batched by model (so one `name_get` by model appearing in the field values).
2017-06-19[FIX] web: use 'o_input' class on search view elementsqsm-odoo
Since the new views, the 'o_input' class has to be set explicitely on <input/> and <select/> elements to have the proper styling.
2017-06-09[MERGE] forward port branch saas-15 up to 49f819a7a79Christophe Simonis
2017-06-09[MERGE] forward port branch saas-14 up to b6c7d718995Christophe Simonis
2017-06-09[MERGE] forward port branch 10.0 up to cd1a8f62527Christophe Simonis
2017-06-08[FIX] web: CrashManager can crash if trying to show an empty messagexmo-odoo
If `d.message` is an empty string, `!!d.message` is false and the crashmanager will try to display `d.error.data.message`… which does not exist as it's a warning with an empty message not an upstream error. That causes the crashmanager itself to crash, and even the warning name/title to be lost.
2017-06-07[FIX] project: fix traceback while setting cover imageHarshad Modi
from project task kanban view (PR #17165)
2017-05-29[FIX] web: domain selector's inputs designqsm-odoo
Since the new views, the 'o_input' class has to be added on form elements for them to be correctly styled.
2017-05-22[FIX] web: FieldMany2ManyCheckBoxes: label not clickableAdrien Dieudonne
Before this commit, it was only possible to click on input to change the value of the many2many_checkboxes widget. For better consistency, we must allow to click on labels.
2017-05-18[FIX] web: FieldRadio with numerical keys encoded as stringsAaron Bohy
Before this rev., the FieldRadio didn't work on selection fields with keys like "0", "1"... i.e. strings that can be converted to numerical values. This was due to an automatic conversion of those keys to their numerical value by JQuery, so when the user changed the value, an unknow key was sent to the server (e.g. 1 instead of "1"), causing a crash. This rev. changes the logic a bit so that the keys are no more written in the DOM, but their index in the selection are.
2017-05-15[FIX] web: display a translation alert when saving the form viewChristophe Matthieu
In the form view, when the user saves a record (with a multilang instance), an alert is displayed to display all modified translatable fields.
2017-05-09[FIX] web: add `o_input` class on m2o dialog inputMartin Geubelle
Since the rev https://github.com/odoo/odoo/commit/250e716c3a12e88acb4a199b427dc47d4ec55d5d the class `o_input` needs to be set on an input to correctly style it.
2017-05-04[REF] web, *: restore views designqsm-odoo
Since the new views merge, a lot of design elements were broken. This was particularly impacting the fields in the editable list view; indeed the editable list view is not using an inline form view anymore so the fields in the list were not properly styled as the LESS was still defined assuming the form view environment (for example the invalid fields were red for o2m fields in form view but not in editable list view even though they got the right CSS class). This commit refactor the LESS following these rules: - No more division of non-layout and layout rules. Dividing LESS rules in x_layout.less and x.less was a mistake. Many rules can be considered to be layout and not layout at the same time, developers always have to switch from one file part to the other, many CSS selectors (and rules!) are duplicated for nothing, ... - Field style is extracted from x_view.less and put in the new fields.less file. As before, the fields_extra.less will contain the rules specific to community so that the enterprise repo can override those by replacing the whole file. - Many classes have been renamed so that o_form_x_y becomes o_x_y as many classes can now be applied outside of form view. These classes should not be used in templates anyway. The commit also changes the DOM of fields so that it is more minimalist (no useless parent div, etc). Input elements are not automatically styled anymore, they have to get the o_input class explicitely. This allows to fix lots of small style bugs of previous versions (required monetary field had not the proper style, readonly m2m tags appeared as editable, ...). This also improves the LESS code. The editable list view should also completely stop flickering on chrome and firefox. The commit also removes the orange outline on list view dirty cells. The commit also removes deprecated static xml, LESS and other code. Notice there are still styles to restore/fix and LESS to improve.
2017-05-03[FIX] web, document: adapt toolbar to the new viewsfwi-odoo
- Fix the toolbar behaviour since there is no more dataset in the widget. - Improve the communication beetwen the controller and the toolbar. - Move the code linked to the document upload in the right file. - Adapt the tests to mock the search_read done by ´document´ addon - Adapt the mock server to be able to give a custom toolbar action
2017-04-27[FIX] mrp: reintroduce pdf_viewer field widgetMartin Geubelle
This field widget has been adapted to the new views. This commit also introduces some tests.
2017-04-27[REF] web: relational fields: FieldStatusAaron Bohy
Moves back the mobile rendering part of the FieldStatus to enterprise, alongside all other tweaks to improve the UX in mobile. This part had been moved to community inadvertendly in the new views branch.
2017-04-24[FIX] web: reintroduce many2many_binary field widgetMartin Geubelle
The field has been adapated to the new views. This commit also introduces some tests.
2017-04-24[FIX] web: debugmanager view metadata should not crashGéry Debongnie
In general, I think that we can safely consider that crashes are not the intended behaviour. In this case, viewing metadata crashed because we tried to format a date which was not parsed (so, a string), instead of a moment object. We simply just parse the date before, and it works as intended.
2017-04-11[REF] barcode, *: update code to new JS frameworkChristophe Matthieu
With the new views, the barcode mechanisms were completely broken, because the view and widget JS code was totally changed. This commit update and refactor all that code to make it work with the new design philosophy. Also, it update the coding style.
2017-04-11[FIX] web: fix two small crashes in debug managerGéry Debongnie
- remove edit workflow link in debug manager. The workflow feature was removed, but there was still a link in the debug manager. Clicking on that link was a crash. - the rpc to fetch a view was wrongly updated, so the return value was not properly used.
2017-04-11[IMP] web: domain & field selector usability (+ design)qsm-odoo
+ Document and refactor the files using the new guidelines * Now only non-technical names are used when building field chains and domains (technical names can be used in debug mode). * Better warnings are displayed when using the field and/or domain selector widgets (also checks domain validity in both domain field AND domain selector widget). Also improve design (thanks to original work of @stefanorigano): - Hovering 'remove' highlights the element that will be removed - Hovering 'add node' btns shows where the new node will be created - Restyle debug domain input field (make it similar to a text editor) - Improve design and layout - Resize inner fields
2017-04-11[FIX] web: restore FieldStatus behaviorqsm-odoo
FieldStatus was broken: - With a selection, the statusbar_visible attribute forces the choices to display, the discarded ones do not appear at all (even folded) - With a m2o, the fold_field option tells the field to check in the relation to know if the choice has to be folded or not, this was not properly supported - Changing a m2o value was broken as the parseMany2one function did not exist - The status were misordered - ... * Also refactor the way the rendering is handled. * Also modify all statusbar tests so that the statusbar widget is placed in the form header tag (as it is the common use case).
2017-04-11[REF] web,*: improve the way field_utils are doneGéry Debongnie
We replace a bunch of formatting and parsing functions by an object (parse or format) which can be used to dispatch on the correct type. It allows us to remove the format_field and parse_field functions. Also, we camelcase our new code and add some comments.
2017-04-11[IMP] web: adapt field domain to new APIqsm-odoo
Add the implementation of the "FieldDomain" (widget='domain') in basic fields file.
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
2017-03-01[MERGE] forward port branch saas-14 up to eddefc9948bChristophe Simonis
2017-02-23[MERGE] forward port branch 10.0 up to 387b2acfcbfChristophe Simonis
2017-02-23[MERGE] forward port branch saas-11 up to 1730dca1016Christophe Simonis
2017-02-14[FIX] web: set max width for image field in form viewAdrien Dieudonne
Before this commit, wide images were larger than the form view.
2017-02-10[MERGE] forward port branch saas-14 up to be9dfb331f9Christophe Simonis
2017-02-09[IMP] web: Separate personal and shared favorite filters in search viewMohammed Shekha
Purpose ======= When there are lots of shared filters then its difficult to differentiate personal and shared filters Specification ========== - Show all personal filters first as user will prefer his own filters to come first in list - Show all shared filters after personal filter in list - Add separator line between personal and shared filter
2017-02-07[FIX] web: simplify the datepicker templatefwi-odoo
The library needs to have a 'relative' positioned parent to place the datetimepicker correctly. We don't do that in the template anymore because it was not working in all the cases. The template which instantiates the datepicker should define a parent in position 'relative'.
2017-02-03[FIX] web: handle field selector closing/opening correctlyqsm-odoo
Ironically, clicking on the dropdown arrow of the field selector was the only way which was not opening the dropdown. It was indeed added as pure design element. This commit handles the opening and closing of the dropdown in a more robust way... while simplyfing the code too.
2017-02-02[MERGE] forward port branch 10.0 up to 8a0151b4bcdChristophe Simonis
2017-01-31[IMP] web: add options to field selector to filter the fieldsqsm-odoo
Before this commit, the field selector had an unique option to filter the fields it displays: filters.searchable, which tells the widget to only display the searchable fields (which is the default). Now there are two more options: - fields: an explicit list of the fields to use (if null, let the widget get the fields itself (this is the default)) - followRelations: a boolean which is true if the user can follow relation to build a field chain (default to true) These options are needed by Web Studio in enterprise where domain construction for form view attrs can only use fields which are in the view and do not follow relations.
2017-01-30[REF] web: update bootstrap-datetimepicker lib and adapt datepicker widgetfwi-odoo
from 3.0.3 to 4.17.42
2017-01-27[MERGE] forward port branch saas-11 up to e86983112ebChristophe Simonis
2017-01-27[MERGE] forward port branch 9.0 up to 838beb12de3Christophe Simonis
2017-01-27[FIX] web: provide correct autofill browser hintsOlivier Dony
Modern browser implement the autofill specs as described at https://html.spec.whatwg.org/multipage/forms.html#autofill This means that there is now a way to tell the browser when a password field is supposed to be filled with the user's own password (e.g. on a login field), and when it's supposed to be used to input a new secret value (e.g. when changing someone else's password). This can be distinguished by setting the autocomplete attribute to `current-password` or `new-password`. In addition, many browsers have decided to entirely disregard the autocomplete='off' attribute value, because it is felt that using a secure password manager (as provided by those browsers) is a net gain for security, allowing users to pick stron passwords. See also https://developer.mozilla.org/en-US/docs/Web/Security/Securing_your_site/Turning_off_form_autocompletion Based on this, the framework should generally consider that password fields in the backend are meant to be used for *setting* new values (autocomplete="new-password", i.e. no autocompletion!), whereas the password field on the login page can indeed be autofilled with the user's current password (autocomplete="current-password"). In addition to making the above changes, this patch also lets developer specify their own `autocomplete` attribute on text input fields.
2017-01-23[MERGE] forward port branch saas-14 up to 6c4389df41fChristophe Simonis
2017-01-12[FIX] web: better align domain selector elementsqsm-odoo
Mixing the use of btn-xs and btn-sm was not good for design. This commit use btn-xs for "add a filter" and "edit domain" buttons to improve elements alignment.
2017-01-12[FIX] web: handle the case of a field domain without set modelqsm-odoo
Some domain fields are initialized with a model which depends of another form field value. Sometimes, this value is False and the domain selector cannot be used during that time (and was even performing useless RPC). Now, in this case, the field domain is fully replaced by a message which explains that a model have to be set. If you don't want this message to be shown, you still have the possibility to not show the field domain when there is no model thanks to the "invisible" attrs.
2017-01-10[MERGE] forward port branch saas-14 up to 557feb950cbChristophe Simonis
2017-01-09[IMP] web: allow to upload multiple files in `many2many_binary` widgetYannick Tivisse
2017-01-06[IMP] web: add a dialog option to the FieldDomainqsm-odoo
Now, the form FieldDomain has an option "dialog" which allows to force the domain *edition* in a new dialog. This allows the field to be positioned in smaller area of the form view in some contexts.
2017-01-06[IMP] web: FieldDomain panel at top right instead of belowqsm-odoo
The FieldDomain is composed of a DomainSelector widget and a button which allows to see the records which match the domain (or an error message if the domain is wrong). The button was placed below the domain selector. Now, in edit mode, it is placed at the top-right of the domain selector, saving some vertical space.
2017-01-03[IMP] web, *: add new Domain and Field selection widgetsqsm-odoo
* base_action_rule, gamification, mass_mailing 1) Create the independant DomainSelector widget - Allow to build a prefix char domain 2) Replace old FieldCharDomain with a new FieldDomain which uses the new DomainSelector widget 3) Create the independant ModelFieldSelector widget - Allow to build a valid field chain for a specific model (e.g 'partner_id.name' for a 'res.users') - Used by DomainSelector widget --- The DomainSelector widget uses a tree-like representation with user-friendly buttons (ALL/ANY/+/-/...). Any domain can be built, except those containing the "!" (not) operator or some operators like "like", "child_of" (@see DomainSelector). However, if the user enters these in the debug input, the widget can handle them. Note: these widgets had to do unusual stuff the widget API does not allow to handle efficiently right now but it will be adapted to the new widget/field API in a further update. Note2: the widgets also have possibility of other improvements like supporting m2o input instantiation in DomainLeaf, etc. --- This work is an adaptation of the original code made by @pga-odoo.
2017-01-02[IMP] web: allows styling of the pager countersLeonardo Rochael Almeida
Before this commit, the pager counters and buttons were at the same level, and could not be styled independently (with some rules such as nowrap). Close PR #14865