Before this commit, the view selected to be edited by the html editor was the wrong one
This was caused by the simplification brought about by commit a2ae219d4e
which transfered from python to js the decision to make a view a header for the [customize] menu (on the website
In this case, the first view in the return list of python was the header, and the second the actual view
Now that python just sends a list of unique views without any distinction whatsoever, the right view to pick when entering the html editor is the first one, at index 0
opw 760279
Closes#18603
Before this commit, the iframe tags were sanitized as the should, but never spawn back from JS.
Now, the iframe is actually created
opw 750830
Closes#18643
When clicking on the app website admin with the arabic language,
it raised an error because this.date_from.format('YYYY-MM-DD') in
function fetch_data returned an arabic date "٢٠١٧-٠٧-٠٥".
opw:751960
Uppercase style shouldn't be applied to all btns by default.
The usage should be set progressively, following an importance criteria.
If we design everything as important (uppercase), nothing will be
perceived as important anymore.
It is for example useful in the form builder with date-kind form field,
the translation of momentjs is done in french.
opw-707986
opw-749544
closes#17103
* mail_channel, mass_mailing, twitter, event
- t-install attribute holds the technical name of the module that
needs to be install to use a particular snippet.
- Disable the drag & drop feature for these dummy snippets.
- Move some images to website module.
- Installed snippets display at the top of the list.
- Hide not-installed module snippets if user don't have rights to install module.
* Set the blocking warning if the user enters a 'Client ID' without
any 'Tracking ID'.
* 'Google Analytics in Dashboard' field is visible only if
'Google Analytics' is checked in website settings.
* Get/Set the value of 'google_analytics_key' and
'google_management_client_id' from 'website' model instead of
'ir.config_parameter' on 'Google Analytics' wizard.
* If ID is set on 'Google Analytics' wizard then activated the related
features and populate fields in website settings.
It now update the website settings parameter use_google_analytics_dashboard
so that the settings are correctly updated with the user choice.
Implementation is changed so that the dashboard uses a jsonRpc call instead
of directly calling ir_config_parameter set_param.
- Change the info message "Add Images from Customize menu" to
"Add Images" and make it clickable
- Reorganize snippet options menu
- Improve the image dialog to be able to select/unselect
- Make sure previews are adapted when changing gallery images
Website content is not supposed to use flex as it is not supported by
some old browsers. This commit provides a way to use flex only for
browsers which support it. When designing a snippet, you can use flex
to design elements and then write other style for when flex is not
supported.
Using flex should however still be avoided when possible. But hopefully,
this commit will allow to build greater snippets whose ugly non-flex
style can be disabled on demand or dropped in a future odoo version.
The website is not ready. It is still too young to understand what the
beautiful `_rpc` function can bring to its life. Someday it will, but
for now, it can at least rely on the `rpc.query` function or to the
'Ace' menu which now understands the beauty of `_rpc`.
---
-> Replace website `_rpc` calls with deprecated `rpc.query` as the
website is not structured enough yet to handle 'trigger_up' events.
-> As the `_rpc` calls cannot be replaced for the ace editor because it
is also used and tested in the backend, promote the 'Ace' menu (which
instantiate the ace editor) to be a `ServiceProvider` so that the
`_rpc` method works in this particular case.
When cloning a snippet section thanks to the editor, the associated
snippet options' `on_clone` methods are called. Now these methods
receive a new argument `options`. The option this commit introduces
is the `isCurrent` one. It allows the method to know if the snippet
section it is associated to is the one that was cloned or if it is a
child of the one that was cloned.
This is useful to solve a known bug when cloning elements which have
bootstrap columns:
- When one column is cloned we want it to lose its col-*-offset-*
classes so that the offset is not duplicated (only the column).
- When a container with column children is cloned we do not want
these column' offsets to be removed (we want the whole cloned
container to be the same).
Introduce a new snippet to show the company team.
This commit also introduces a new classe "s_no_resize_cols" to put
on a .row element to prevent the size and margins options to be used
on the .col-* children. This allows to build some complex layout without
having a deep hierarchy of snippet options.
Fixed some issues with parralax image updates:
- Background updated without clicking
- Default wallpaper not coming back
- Background disappearring sometimes
In carousel snippet, the target element for background snippet option is
being changed manually. So for the new target, we have to rebind the
associated events that were bound in `start` function of the snippet
option. For that, some code is extracted from the `start` function and
is used to rebind necessary events for new targets.
In particular, this was preventing the carousel slides' backgrounds to
be automatically removed when a background-color was selected.