-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[#32717] Front End Module Editing #2521
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
Conversation
This reverts commit 0c1136d.
message and redirect added to save controller
JHtml::_('behavior.combobox'); | ||
JHtml::_('formbehavior.chosen', 'select'); | ||
|
||
$hasContent = empty($this->item['module']) || $this->item['module'] == 'custom' || $this->item['module'] == 'mod_custom'; |
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.
Why a check against a specific module? How would that work with similar 3rd party modules?
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.
Hi, This check is to add 'content' field (text editor). Not every module needs that. This is a similar implementation to B/E view. 3rd party modules can contain 'content' fields and they'll be shown in respective sections.
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.
ok, thanks
@test again: I think we should use here a green message as all is ok :) |
Please ignore my last post. The implementation here is correct see here: EDIT: I will send a new Tracker for this. |
Just a note: It's actually the Isis template which has some funny overrides for the messages. Protostar does not have any overrides here. This is why coloring is different in front- and backend. |
Issue message for the alert issue can be finde here: http://issues.joomla.org/tracker/joomla-cms/3273 |
I have some questions:
If this is frontend editing I think frontend has to contain the required code to be able to customise each behavior correctly for frontend /backend About using com_config I think each component has to contain its own stuff. Otherwise we will face the chaos when we want to create the lite core. Also it seems that we have some trailing whitespaces/codestyle errors. This is what I get when applying the PR as patch:
|
Hi Roberto, |
Sorry but I don't agree. For the same reason we could merge all the components into a single one. You are doing 2 things here:
|
2 questions
|
Hi Brian,
Again, thank you very much for having experience with this. |
Sorry but for me at least this isnt ready yet as its incomplete |
tested working as Described by the dev. |
Thank you @parthlawate for testing this. @brianteeman , I think still you didn't get the idea about what I was explaining.
Thank You! |
It just seems wrong to me to use a generic ACL as you have described for a specific function. |
Agree with @brianteeman on frontend editting should not be connected to 'Access Administration interface'. Adding something like 'Access Frontend Administration' is not complicating ACL, abusing it is! |
I have been looking into this pull request, and in general it looks good. But the ACL implementation is indeed missing. I expect the ACL for the frontend module editing is working similar to the Joomla Articles frontend editing. So in line with the articles concept I did the following test which works for the Joomla articles, but then for this module feature: Article Manager Test
Result: able to see the edit icon, edit the article and save it Module Manager Test (A)
Result: edit buttons are not visible, can't edit modules I also tested the Module Manager by allowing the "Access Administration Interface" action, in that case the test is as follow: Module Manager Test (B)
Result: able to see the edit icon, edit the module but saving results in "You are not authorized to view this resource." error. General ACL suggestionsI strongly recommend to follow the frontend ACL concept of the article manager for now, or have at least the same behavior for the frontend articles and module editing around ACL settings. This means that a group with the "Site Login" and "Edit" action allowed should be able to edit the modules on the frontend. If a site owner doesn't want the modules editable on the frontend they shouldn't allow the edit action for the module manager or for the specific module(s). I'm not sure there is a big need for difference in what a user can edit based on the ACL settings between te frontend and backend. So if you allow modules to be editable and a group has backend and frontend access they can edit it on both places. I can only think of situations where people would allow people to edit articles/modules in the backend, but not in the frontend. A general "Disable frontend editing" option would be enough for that. But that would be another pull request. Anyway, thanks for your work on the frontend module editing, if the module ACL is following the article manager concept it looks good to me around ACL. |
"This means that a group with the "Site Login" and "Edit" action allowed should be able to edit the modules on the frontend. If a site owner doesn't want the modules editable on the frontend they shouldn't allow the edit action for the module manager or for the specific module(s). " The issue here is that we would not be B/C: A default "Editor" or "Publisher" (used only as of today for articles) would be able to edit modules in the frontend. A big surprise for a site admin... |
That's indeed true. However Sander is right in how the ACL should be used. The fact that we use stupid default rules here doesn't change that.
In my own extension I have such a parameter to enable frontend editing (disabled by default). I think that would be a good parameter to add to com_modules. Then it doesn't matter anymore that we have messed up default ACL rules. |
Hi Sander, |
tested fine on bluehost (i figure enough people are testing on rochen), PHP 5.4.27. |
Changed ACL works for me. Thanks for that! |
Merged to 3.4-dev, thanks! |
Joomla tooltip says: The template has to support this feature. Beez3 obviously does not support this. How can I implement this in a template? |
Hi All,
With latest Joomla! release, super users can access module settings(back end) directly from front end.
But that can be done as front-end com_config does.
Along with this PR, I've created a system which can do almost all the essential settings for a module without switching to back end. Because of that, super user can see the changes easily.
Feature Tracker: http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=32717&start=0
Thank You !