? ? ?
avatar joomdonation
joomdonation
31 Mar 2021

Pull Request for Issue # .

Summary of Changes

PR #32771 allows users without core.manage permission to edit their own accounts directly via com_users instead of via view profile of com_admin (view profile later was removed via PR #32933)

However, it causes some changes when a manager edit his account:

  • He can now change username even if Change Username parameter in com_users set to No
  • He can see and changes some settings which he should not be allowed to change like Receiving System Emails, User Status...

This PR fixes that behavior. Basically, for users without core.manager permission, editing his account (now via com_users) should work the same as before (via com_admin)

Testing Instructions

  1. Apply Patch
  2. Login to administrator area of your site using a manager user account
  3. Access to Edit Account link from User Menu at the top right
  4. Before patch:
  • You can change username (when Change Username parameter in com_users set to No - default Joomla 4 setting)
  • You can see some fields: Last Reset Date, Password Reset Count, Receive System Emails, User Status
  1. After patch:
  • You are not allowed to change username when Change Username parameter in com_users set to No
  • You won't see the fields Last Reset Date, Password Reset Count, Receive System Emails, User Status anymore
avatar joomdonation joomdonation - open - 31 Mar 2021
avatar joomdonation
joomdonation - comment - 31 Mar 2021

Ping @ceford since you reported the issue at #32933 (comment)

avatar joomdonation joomdonation - change - 31 Mar 2021
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 31 Mar 2021
Category Administration com_users Language & Strings
avatar ceford
ceford - comment - 31 Mar 2021

For some reason this PR has no Test or diff buttons when accessed from Patchtester. And I don't know how return test result another way.

I am happy and it is a pass. But I am not sure an Administrator should be allowed to set his own Status to blocked.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/32947.

avatar joomdonation
joomdonation - comment - 1 Apr 2021

For some reason this PR has no Test or diff buttons when accessed from Patchtester. And I don't know how return test result another way

Maybe you will have to click on Fetch Data to have Patch Tester fetches the new PRs. I still see the PRs listed (see the attached screenshot)
PRs

There is another way to test if you cannot use patch tester. Just download the update package for this PR https://ci.joomla.org/artifacts/joomla/joomla-cms/4.0-dev/32947/downloads/41449/Joomla_4.0.0-beta8-dev+pr.32947-Development-Update_Package.zip , go to System -> Update -> Joomla (the URL of that page looks like http://localhost/joomla4/administrator/index.php?option=com_joomlaupdate ), upload and install this update package. Then you can test it.

I am happy and it is a pass. But I am not sure an Administrator should be allowed to set his own Status to blocked.

I have same question for this myself. I'm unsure if a user should be able to change his Status to Blocked. However, that's the current behavior of Joomla! and I don't want to touch it. For this PR, I just want to address the issue which you reported (make sense BTW).

avatar ceford
ceford - comment - 1 Apr 2021

On submitting test result - in Patchtester I have done Reset and Fetch Data (twice). For this PR in the Joomla Issue Tracker I see this:

screen shot 2021-04-01 at 06 02 34

In comparison to other PRs such as this:

screen shot 2021-04-01 at 06 03 16

In the first example (this PR) the Diff link and Test this button are missing so I can't submit a test result. I have applied the patch and tested it but I don't know another way to return a result.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/32947.

avatar joomdonation
joomdonation - comment - 1 Apr 2021

@ceford Ah, Yes. I see. I could not see submit test result button in issue tracker, too, so strange. So have you tested this PR yet? If it is a success, maybe you can leave a comment here so that maintainer knows about it.

avatar infograf768
infograf768 - comment - 1 Apr 2021

? Works fine. (Submit test is not available in https://issues.joomla.org/tracker/joomla-cms/32947 )


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/32947.

avatar ceford
ceford - comment - 1 Apr 2021

? Works fine. Count this as a test Pass.

avatar joomdonation
joomdonation - comment - 1 Apr 2021

Thanks @ceford and @infograf768 for testing.

avatar infograf768 infograf768 - change - 1 Apr 2021
Status Pending Ready to Commit
avatar infograf768
infograf768 - comment - 1 Apr 2021

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/32947.

avatar wilsonge wilsonge - change - 1 Apr 2021
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2021-04-01 12:53:43
Closed_By wilsonge
Labels Added: ? ? ?
avatar wilsonge wilsonge - close - 1 Apr 2021
avatar wilsonge wilsonge - merge - 1 Apr 2021
avatar wilsonge
wilsonge - comment - 1 Apr 2021

Thanks!

Add a Comment

Login with GitHub to post a comment