New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[REV] website: revert commit ability to restrict groups on website menu #83505
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does and use the big menu
refers to?
This is just reverting b5091c7, that should be indicated in the commit message. Also, this is a task not an opw?
I am obviously not going to be excited about this. This was an awaited feature from the community (and website team).
The goal of this feature is to be able to allow a controller like /shop to be hidden from visitor for instance:
- You add the group on the view from the controller
- You add the group on the menu
Do you confirm it was decided to remove this for "the future"?
To put
Ok, I will change the message by a revert message.
It's an fp request, he says it has no use and needs to be removed, and it annoys him because he can't cache the whole menu because of it. |
d21eeb1
to
9bf5d4f
Compare
I will try to do a quick summary here, as I think this is wrong (not too wrong tho, but more wrong that good). This feature was requested by the community, and is now used by the PS Tech. You suggest an alternative by using a mega menu, I guess to write
As a reminder, this is the only way to hide a menu from a controller, like /shop. On top of that, note that this is also partly reverting what was done at 49d64a8 in slides -> Hide a forum if you don't have access to it. Also, worth mentionning that it will still work for website.page's menu, as for a menu (linked to a page) to be visible, its page need to also be visible, which checks if the page's view has a group. On the other hand, I have to admit and be coherent with how I generally think when it comes to the website builder: we aim to provide the best solution for "le boucher du coin", for which this feature has no benefit. Why don't we keep this (very) advanced feature (I admit), alongside your incoming menu cache system, with something like:
I'll r+ once I got @fpodoo confirmation given this summary |
The rationale is the following:
|
@fpodoo Regarding performance, for the menu, I saw no change by removing the group_ids, since there is no group in base, and otherwise the accesses are cached. |
It is not? Everything is cached and regardless of the menu complexity (having groups, having multiple nested level etc), there will only be one and only one sql query regarding the As far as I understand this one, this is for "future perf improvement" for when we will have the qweb t-cache and we will avoid that query on I am just waiting for PDE's feedback before r+ to see if something else should be shipped alongside this one.
-> If you set both, it doesn't makes sense after this PR as you have unreachable menus leading to 403 for non authorized user. |
@robodoo r+
|
Staging failed: ci/upgrade_enterprise on 3882eb049fd647fbaee3062822d729d0b5131638 (view more at http://runbot.odoo.com/runbot/build/12516236) |
Do not forget to open (and r+) the PR of the corresponding upgrade branch (that's why the runbot is green here) |
When removing fields, always have upgrade branches and reviewed PR... you just ate 3 mergebot builds in a freeze period -_-' . |
9bf5d4f
to
69832d3
Compare
Whoops, sorry. I made sure there was an upgrade branch the first time I reviewed this PR, which there was.
Thank you @Feyensv that explains why it went through despite having a green runbot (and an upgrade branch) indeed 👍 Anyway, @Gorash I rebased both your branches and opened the upgrade PR (not sure why it wasn't tho..), we can merge this after the freeze, it can wait another version, I'd not want to slow down or block a bit more @tde-banana-odoo during this freeze period in case something else goes wrong 😨 |
There was a branch and it was merged ? Weird ... |
Yup, created 6 days ago Edit: Gotta admit, I saw the warning about mismatch but I thought it could only introduce more error and not "avoid"/"remove" some error from the builds. I thought it could only makes the build red if it was supposed to be green (with rebased branch), not the other way around. I'll know, now :) |
Well that's strange it was built based on a branch without pr and tried to merge it ... I suppose he does not know the branch contains commits not present on stable, something like that. Funny one. |
69832d3
to
0abc6c1
Compare
bcbd0b9
to
b579638
Compare
Waiting for upgrade PR to be ready |
@Gorash Don't forget https://github.com/odoo/upgrade/pull/3208#issuecomment-1034888824 so we can ship this one |
b579638
to
baaf739
Compare
group_ids
feature from website.menu
Build is red, most likely due to branches not sync'd, can you rebase both together with updated master so we can r+? |
revert odoo@b5091c7 fp asks to remove the groups on the menus to simplify the model and allow the menu to be cached in the future. The user can change the templates, use the big menu, add custom t-if, groups... task-2737973
baaf739
to
fc00170
Compare
I fixed the remaining ci issues in the upgrade PR, should be good. @robodoo r+ (copy paste from previous r+)
|
Linked pull request(s) odoo/upgrade#3208 not ready. Linked PRs are not staged until all of them are ready. |
revert b5091c7 fp asks to remove the groups on the menus to simplify the model and allow the menu to be cached in the future. The user can change the templates, use the big menu, add custom t-if, groups... task-2737973 closes #83505 Related: odoo/upgrade#3208 Signed-off-by: Romain Derie (rde) <rde@odoo.com>
[REV] website: revert commit ability to restrict groups on website menu
revert b5091c7
fp asks to remove the groups on the menus to simplify the
model and allow the menu to be cached in the future. The user can change
the templates, use the big menu, add custom t-if, groups...
task-2737973