XoopsCore25 icon indicating copy to clipboard operation
XoopsCore25 copied to clipboard

The "Edit Profile" and "Delete" buttons on user pages do not work

Open Andrew-Staves-Activ opened this issue 2 years ago • 1 comments

Admin users are shown the following button on user pages (I'm not sure which of these files is actually used for this or how they relate): https://github.com/XOOPS/XoopsCore25/blob/dfc2ef634c69db8ff337098021faa2c822aed547/htdocs/modules/system/templates/system_userinfo.html#L27-L28

https://github.com/XOOPS/XoopsCore25/blob/dfc2ef634c69db8ff337098021faa2c822aed547/htdocs/modules/system/templates/system_userinfo.tpl#L27-L28

Clicking the button takes the admin user to (e.g.): modules/system/admin.php?fct=users&uid=1234&op=modifyUser

However, the "modifyUser" value for op does not seem to be recognised, so the admin user will find themselves on modules/system/admin.php?fct=users

It looks like the edit member button (from that user management area) goes to (e.g.): modules/system/admin.php?fct=users&uid=1234&op=users_edit

Should the "modifyUser" value for op simply be replaced with "users_edit" now?

If so, I can put a pull request together to make that change in the template and HTML file mentioned above.

For reference, the only other instance of "modifyuser" (case insensitive) I could find was: https://github.com/XOOPS/XoopsCore25/blob/dfc2ef634c69db8ff337098021faa2c822aed547/htdocs/modules/system/language/english/admin/users.php#L96

Andrew-Staves-Activ avatar Jul 26 '22 13:07 Andrew-Staves-Activ

I've subsequently realised that a similar situation applies to the delete button (on the same page): https://github.com/XOOPS/XoopsCore25/blob/dfc2ef634c69db8ff337098021faa2c822aed547/htdocs/modules/system/templates/system_userinfo.html#L29-L30 https://github.com/XOOPS/XoopsCore25/blob/dfc2ef634c69db8ff337098021faa2c822aed547/htdocs/modules/system/templates/system_userinfo.tpl#L29-L30

The "delUser" value for op does not exist.

I've submitted a pull request (#1245) which replaces both the edit and delete op values with the ones that the user admin page uses. Hopefully that's what the buttons should be doing.

Andrew-Staves-Activ avatar Jul 29 '22 12:07 Andrew-Staves-Activ

Thanks for the feedback and correction, this issue can be closed.

fix: https://github.com/XOOPS/XoopsCore25/pull/1245

GregMage avatar Mar 06 '23 19:03 GregMage