Skip to content

[10.0][IMP][website_multi_theme] make customize_show views part of multi-theme - #443

Merged
pedrobaeza merged 1 commit into
OCA:10.0from
yelizariev:10.0-website_multi_company-multi-customize
Apr 23, 2018
Merged

pedrobaeza merged 1 commit into
OCA:10.0from
yelizariev:10.0-website_multi_company-multi-customize

Conversation

@yelizariev

Copy link
Copy Markdown
Member

The PR allows making customization independently per website
multi-customization

@yelizariev yelizariev left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some explanation of the updates

License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html). -->
<odoo>
<!-- Default theme. It's basically a workaround for "Multi-customization"
feature which requires theme be set -->

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see other solution. At least until we make refactoring discussed #409

string="Copied from",
help="View from where this one was copied for multi-website"
)
copy_ids = fields.One2many(

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Those two fields are left after initial draft of this update, but I think it could useful later

Comment thread website_multi_theme/models/website.py Outdated
xmlid,
self.display_name,
),
"name": '%s (Multi-Website)' % pattern.name,

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's renamed, because this name is used in Customize menu (grayed text)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe, the name can be changed to '%s (Website #%s)' % (pattern.name, self.id) , because Multi-website sounds like the same per different websites

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't want to use self.display_name, because website could be renamed

),
"name": '%s (Multi-Website)' % pattern.name,
"website_id": self.id,
"origin_view_id": pattern.id,

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's kind of replacement to removed data in name

# used
copied_parent = self._find_duplicate_view_for_website(
parent_view, website
)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not directly part of this update, though there is a theoretical situation when several Customized views inherit each other, so they need to use a copied view too. But I need to make real multi-footer in my module website_multi_company to apply some extension to make website.footer_custom copyable too


if refs or one.asset_ids:
# add common_refs only for installed themes
refs += common_refs

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the key idea of the update

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general I recommend to use |=, to avoid duplicates in the recordsets.

id="layout_pattern"
inherit_id="website.layout"
name="Template for replacing assets_frontend"
name="Main layout"

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's renamed because it's used in Customize menu

result = pattern.copy({
"active": pattern.was_active,
"arch_fs": False,
"customize_show": False,

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yajo is there any reason why this was set to False? Do you remember the case when it's required?

* If you install any of the supported themes after installing this addon, you
will have to press *Reload* in the website config wizard to make it notice
the change.
the change. The same is true when you install any module with ``customize_show="True"``

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests are not passed in travis due to this new requirement: Reload must be done after installing website_blog_category https://github.com/OCA/website/blob/10.0/website_blog_category/templates/website_blog_template.xml#L25

What can we do here? @yajo @pedrobaeza

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about calling reload from the last demo data file read?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mean demo file of website_blog_category?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd prefer to Reload after creating new ir.ui.view record with customize_show (via extending create method). What do you think, @pedrobaeza ?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That would make sense, yes.

I was talking about demo data file included in this addon. Or even maybe a normal data file.

result = pattern.copy({
"active": pattern.was_active,
"arch_fs": False,
"customize_show": False,

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copied message to don't miss it:

@yajo is there any reason why this was set to False? Do you remember the case when it's required?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't remember, honestly 🙄

@yelizariev

Copy link
Copy Markdown
Member Author

When you review PR yourself

dog-walking-itself-1

@yajo yajo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, let me know if I understand what you are doing here:

  1. Now all websites have a theme, even if it must be the default one. I like this approach, it reduces variability 😊

  2. Converted assets inherit the customize_show attribute independently.

  3. All views with customize_show=True are considered multiwebsite views. I'm not sure if we should instead duplicate all views belonging to addons that depend on website; after all, a user usually can customize any view in a website... 🤔

Some comments below. Thanks!

result = pattern.copy({
"active": pattern.was_active,
"arch_fs": False,
"customize_show": False,

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't remember, honestly 🙄

Comment thread website_multi_theme/models/website.py Outdated

parent_view = copied_view.inherit_id
parent_view_module = parent_view.model_data_id.module
copied_parent = None

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line makes no sense now, isn't it?

class IrUiView(models.Model):
_inherit = 'ir.ui.view'

multi_theme_generated = fields.Boolean(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need a migration script to fill origin_view_id from preexisting views that had this boolean set to true.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll do that

inverse_name="website_id",
domain=[("multi_theme_generated", "=", True),
domain=[("origin_view_id", "!=", False),
"|", ("active", "=", True), ("active", "=", False)],

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should replace this by context={"active_test": True}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I cannot find an example of using such trick. Are you sure that context is used when we read the field in python via .multi_theme_view_ids and other cases? I'd prefer to keep as it's now

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK no problem, it was just an idea


if refs or one.asset_ids:
# add common_refs only for installed themes
refs += common_refs

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general I recommend to use |=, to avoid duplicates in the recordsets.

])
existing = frozenset(one.mapped("asset_ids.name"))

common_refs = self.env["ir.model.data"]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line is not needed; the next sentence will return an empty recordset when nothing is found.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idea was to allow in possible next updates don't change git blame much.

For example,

Version1

common_refs = self.env["ir.model.data"]
common_refs |= A

Version 2

common_refs = self.env["ir.model.data"]
common_refs |= A
common_refs |= B

Version 3

common_refs = self.env["ir.model.data"]
common_refs |= A1
common_refs |= B
common_refs |= C

Version 5

common_refs = self.env["ir.model.data"]
common_refs |= B
common_refs |= C

"website, and disabled otherwise. Usually used to load assets.",
)

auto = fields.Boolean(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move fields above, just like explained here.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mean above _sql_constraints? It's actually not explained in the guidelines. It mentions only constrain methods. While _sql_constraints seems to be part of

Private attributes (_name, _description, _inherit, ...)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yikes! forget this. I think I didn't expand the diff in between 😆

<separator string="Copies"/>
<field name="copy_ids"/>
</page>
<page string="Multi-website" attrs="{'invisible': [('origin_view_id', '=', False)]}">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 pages called the same?

Better 1 page and 2 groups.

Remember to add a name="multiwebsite", to enable possible inheritance.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idea is don't pass attributes twice in each node here:

                <separator string="Copies"/>
                <field name="copy_ids"/>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can add different names, if it's the concern

name="multiwebsite_origin_view"
name="multiwebsite_copied_view"

<label for="multi_theme_id"/>
<div>
<field name="multi_theme_id" class="oe_inline"/>
<field name="multi_theme_id" class="oe_inline" required="1"/>

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not require it in the model?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because we have default website, which doesn't have multi_theme_id on installation and we cannot set it on installation, because Default theme is created after loading python files

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It makes sense. Could you add a note here then please? It's not obvious...

* Rafael Blasco <rafael.blasco@tecnativa.com>
* Antonio Espinosa <antonio.espinosa@tecnativa.com>
* Jairo Llopis <jairo.llopis@tecnativa.com>
* Ivan Yelizariev <https://it-projects.info/team/yelizariev>

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't believe you weren't here before!

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from b21031f to 8aa5f94 Compare April 12, 2018 16:55
@yelizariev

yelizariev commented Apr 12, 2018

Copy link
Copy Markdown
Member Author

Rebased and added some fixes. Few comments from @yajo's review are subject to discuss. I'll squash commits once we close all concerns or one can do it on merging (just fist commit message has to be keeped: [IMP] make customize_show views part of multi-theme)

@yelizariev

yelizariev commented Apr 12, 2018

Copy link
Copy Markdown
Member Author

About this idea:

All views with customize_show=True are considered multiwebsite views. I'm not sure if we should instead duplicate all views belonging to addons that depend on website; after all, a user usually can customize any view in a website... 🤔

The possible problem here is that those changes will be destroyed after switching a website to new theme. So, it's better to share them, than letting user face data lost

@yelizariev

yelizariev commented Apr 12, 2018

Copy link
Copy Markdown
Member Author

I'll do this later

  • a migration script to fill origin_view_id from preexisting views that had this boolean set to true.

@rafaelbn rafaelbn changed the title [IMP] make customize_show views part of multi-theme [10.0][IMP][website_multi_theme] make customize_show views part of multi-theme Apr 13, 2018
@rafaelbn rafaelbn added this to the 10.0 milestone Apr 13, 2018
@rafaelbn

Copy link
Copy Markdown
Member

Thank you @yelizariev for this great contribution! 😄 👏 👏 👏

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch 2 times, most recently from 8fb65b0 to c5836fc Compare April 14, 2018 01:26
@yelizariev

Copy link
Copy Markdown
Member Author

I added migration scripts and squashed the PR

Previous history:
https://github.com/yelizariev/website/commits/10.0-website_multi_company-multi-customize-before-squashing

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from c5836fc to b97a462 Compare April 14, 2018 01:39
@yelizariev

Copy link
Copy Markdown
Member Author

And another commit yelizariev@1984fbf
(squashed)

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from b97a462 to 0252aee Compare April 16, 2018 23:46
@yelizariev

Copy link
Copy Markdown
Member Author

One more update from @yajo's review yelizariev@0fd0ad3

and there is still the question about travis tests. Can we do something about it or just left it as is

@ilmir-k

ilmir-k commented Apr 17, 2018

Copy link
Copy Markdown

@yelizariev
During the tests I found out wrong behavior. When we use Default theme or Multiwebsite Demo Theme for websites everything is ok, but if we install and set Bootswatch Theme we miss the options for Customize

missed_options

@yelizariev

Copy link
Copy Markdown
Member Author

I think the error was introduced in a4ed42f#diff-93d51900ef6c23af9b0a13e1278dfad5R45 by @yajo

How to reproduce without this updates:

  • Install Bootswatch Theme
  • Click reload twice
  • RESULT: Multi-theme Bootswatch Theme is disappeared from the list

@yelizariev

Copy link
Copy Markdown
Member Author

@yajo could you check and fix?

@yajo

yajo commented Apr 18, 2018

Copy link
Copy Markdown
Member

See #447

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from 0252aee to 64c5033 Compare April 18, 2018 15:06
@yelizariev

Copy link
Copy Markdown
Member Author

Rebased


ivann@ivann-360:/mnt/files/odoo/odoo-10.0/website$ git fetch OCA  pull/443/head
De https://github.com/OCA/website
 * branch            refs/pull/443/head -> FETCH_HEAD
ivann@ivann-360:/mnt/files/odoo/odoo-10.0/website$ git diff FETCH_HEAD..HEAD
diff --git a/website_multi_theme/models/website_theme.py b/website_multi_theme/models/website_theme.py
index 45f3ea4..a0190f2 100644
--- a/website_multi_theme/models/website_theme.py
+++ b/website_multi_theme/models/website_theme.py
@@ -65,10 +65,11 @@ class WebsiteTheme(models.Model):
                 # add common_refs only for installed themes
                 refs |= common_refs
 
-            views = self.env["ir.ui.view"].search([
-                ("id", "in", refs.mapped("res_id")),
-                ("type", "=", "qweb"),
-            ])
+            views = self.env["ir.ui.view"].with_context(active_test=False) \
+                .search([
+                    ("id", "in", refs.mapped("res_id")),
+                    ("type", "=", "qweb"),
+                ])
             existing = frozenset(
                 one
                 .mapped("asset_ids")

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from 64c5033 to a3c2d6a Compare April 19, 2018 02:04
@yelizariev

Copy link
Copy Markdown
Member Author

Update for the last question: yelizariev@3b61c5d

It took more time than I thought

@yajo your review is very needed

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from a3c2d6a to f0bb1c1 Compare April 19, 2018 02:28
@yelizariev

Copy link
Copy Markdown
Member Author

Other updates

LINT: yelizariev@52b962f
CI fix: yelizariev@6c5a852

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from f0bb1c1 to e9d2100 Compare April 19, 2018 02:33
@rafaelbn

Copy link
Copy Markdown
Member

Please @yajo could you review here? Thank you!

@yajo yajo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Amazing work, now just minor details

help="Indicates if the view was originally active before converting "
"the single website theme that owns it to multi website mode.",
)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd remove this white line

)
website.multi_theme_view_ids.unlink()
continue
if not default_theme:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I'm not wrong, this if will never pass because the above call to ref() doesn't have a raise_if_not_found=False.

OTOH I'd use the try-except-else option instead.

("model", "=", "ir.ui.view"),
])

common_refs = self.env["ir.model.data"]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can delete this, the search below will return an empty recordset on his own if no results are found.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My explanation is here: #443 (comment)
You probably miss it. What do you think about it?

@yelizariev

Copy link
Copy Markdown
Member Author

Tiny updates yelizariev@e028b32

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from e9d2100 to d6cd84a Compare April 19, 2018 20:31
@yelizariev

Copy link
Copy Markdown
Member Author

@pedrobaeza ?

@ilmir-k ilmir-k left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Comment thread website_multi_theme/__manifest__.py Outdated
"version": "10.0.1.2.0",
"category": "Website",
"website": "https://www.tecnativa.com",
"author": "Tecnativa, Odoo Community Association (OCA)",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yelizariev your company deserves to be here

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from d6cd84a to 62eabef Compare April 23, 2018 14:54
def create(self, vals):
res = super(IrModelData, self).create(vals)
if vals.get('model') == 'ir.ui.view' \
and not self.env.context.get('duplicate_view_for_website'):

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Incorrect indendation and line split

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Multi-line if-block is my weak side 😞

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The best is to enclose in parenthesis and always indent second line 2 levels more:

if (vals.get('model') == 'ir.ui.view' and
        not self.env.context.get('duplicate_view_for_website')):

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd prefer to put logical operator at the beginning of the line

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, it's W503 requirement. OK

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not the only one who thinks so.

W503 is ignored by default in latest version of pycodestyle.

OCA/maintainer-quality-tools#545

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I said wrong. W504 is ignored by default

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But people say that W504 is more logical

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, we can discuss about that in the issue, but right now it's W503 what is used.

"origin_view_id",
string="Copies",
readonly=True,
help="Duplicates of this view"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would prefer a more explicit name: multitheme_copy_ids and a longer explanation in help.

and not self.env.context.get('duplicate_view_for_website'):
view = self.env['ir.ui.view'].browse(vals.get('res_id'))
if view.customize_show:
# Reload theme to make new customize_show available right after

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Put this explanation in the method docstring instead of here, as it's the purpose of the override.

views = super(IrUiView, self)._customize_template_get_views(
key, full=full, bundles=bundles
)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These empty lines don't add anything useful and PEP8 discourages its use. Better to strip them.

Comment thread website_multi_theme/models/website.py Outdated
comodel_name='website.theme',
domain=[("asset_ids.view_id", "!=", False)],
help="Multiwebsite-compatible theme for this website",
require=True,

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please don't add require fields in inherited classes, as this will make that tests that create records from this model fail when this dependent module is not loaded. Instead, put the require on the view.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe it's true for existing fields only, while here we create a new field.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, it's the same. The sequence is the following in MQT:

  • This module is installed along with all the testable ones and its dependencies.
  • Then the SQL NOT NULL constrained is added.
  • On the second pass, modules are being tested while being loaded.
  • Any module adding a website will have the not null error until this module is loaded.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I got it. You are right.
It seems to be an odoo framework issue. Is there a way to fix it in odoo core?

('website_id', '=', False),
('customize_show', '=', True),
]).mapped('model_data_id')

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't add too much empty lines...

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from 62eabef to ca86676 Compare April 23, 2018 15:38
@yelizariev

Copy link
Copy Markdown
Member Author

New updates: yelizariev@3a24f70

@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from ca86676 to 3b9f640 Compare April 23, 2018 15:51
@yelizariev

Copy link
Copy Markdown
Member Author

And update about required=True yelizariev@b70f910

@yelizariev

Copy link
Copy Markdown
Member Author

I suppose this is the last question here:

website_multi_theme/models/ir_model_data.py:33:17: W503 line break before binary operator

I made an issue in MQT OCA/maintainer-quality-tools#545

@pedrobaeza

Copy link
Copy Markdown
Member

But that's because you haven't put the and in the previous line.

@yelizariev

Copy link
Copy Markdown
Member Author

I know, but I'd prefer to put and at the beginning of the line.
why

@pedrobaeza

Copy link
Copy Markdown
Member

Yeah, but if you want this merged before discussing about the change, you have to fix it. If not, we have to wait until the discussion is solved.

New field "auto" in "website.theme.asset" to distinguish assets
created from theme and ones created in xml. It's needed, for example,
for non-module themes (like Demo theme) be handled in _convert_assets
(before this update such themes were skipped)

[REF] field multi_theme_generated is replaced with origin_view_id

[IMP] apply default theme after installation

[IMP] reload themes on installing new modules with customize_show

[CI] Website always have Multi-Theme now. Also, increase default
timeout (10 sec) to 60 sec, because it may take more time now
@yelizariev
yelizariev force-pushed the 10.0-website_multi_company-multi-customize branch from 3b9f640 to 73d6a72 Compare April 23, 2018 17:49
@yelizariev

Copy link
Copy Markdown
Member Author

I'd prefer to merge it now.
(Travis is green now)

@pedrobaeza
pedrobaeza merged commit 082c66c into OCA:10.0 Apr 23, 2018
@rafaelbn

Copy link
Copy Markdown
Member

Thanks @yelizariev ! 👏 👏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants