User type of field fails on frontend form #909

Closed
opened 2022-04-28 15:33:24 +00:00 by eqwise-dev · 2 comments
eqwise-dev commented 2022-04-28 15:33:24 +00:00 (Migrated from github.com)

Steps to reproduce the issue

Create a component with an admin view containing a field of type "user". Then make the view available from frontend. Create a menu link to the edit view.

Expected result

You can use the field as normal, by clicking on it, a popup with selectable users will show on which can be used to add the desired user to the form.

Actual result

Works as expected in backed, fails in frontend with an error like:
404 View not found [name, type, prefix]: users, html, usersView
ROOT\libraries\src\MVC\Controller\BaseController.php:839
After some debug I find out, that the URL requested is like this:
https://mydomain.com/index.php?option=com_users&view=users&layout=modal&tmpl=component&required=0&field=jform_client_id&ismoo=0
and the problem is caused by the fact that the requested view/layout exist ONLY in the Admin side

System information (as much as possible)

  • OS Name & Version:
  • MySql Version:
  • Apache Version:
  • PHP Version:
  • Joomla Version:
  • JCB Version:
  • Browser:
    Latest Joomla 3, tested in various PHP/Apache versions and servers, all browsers - the error is related with the handling of the field of type "user"

Additional comments

### Steps to reproduce the issue Create a component with an admin view containing a field of type "user". Then make the view available from frontend. Create a menu link to the edit view. ### Expected result You can use the field as normal, by clicking on it, a popup with selectable users will show on which can be used to add the desired user to the form. ### Actual result Works as expected in backed, fails in frontend with an error like: 404 View not found [name, type, prefix]: users, html, usersView ROOT\libraries\src\MVC\Controller\BaseController.php:839 After some debug I find out, that the URL requested is like this: https://mydomain.com/index.php?option=com_users&view=users&layout=modal&tmpl=component&required=0&field=jform_client_id&ismoo=0 and the problem is caused by the fact that the requested view/layout exist ONLY in the Admin side ### System information (as much as possible) - OS Name & Version: - MySql Version: - Apache Version: - PHP Version: - Joomla Version: - JCB Version: - Browser: Latest Joomla 3, tested in various PHP/Apache versions and servers, all browsers - the error is related with the handling of the field of type "user" ### Additional comments
webgobe commented 2022-05-09 14:26:09 +00:00 (Migrated from github.com)

Anyone? I have the same issue.

Anyone? I have the same issue.

The field user is build by Joomla, JCB does not do anything to build the HTML of the edit view directly it just builds the XML that Joomla uses to load the form-fields.

So I have not looked at this field in a while now... so I quickly opened "create" an article front-end form and realize Joomla does not use the user field in that view. I will look around some more, but at this point it seems Joomla dropped the ball on this fields implementation on the front-end.

The field `user` is build by Joomla, JCB does not do anything to build the HTML of the edit view directly it just builds the XML that Joomla uses to load the form-fields. So I have not looked at this field in a while now... so I quickly opened "create" an article front-end form and realize Joomla does not use the user field in that view. I will look around some more, but at this point it seems Joomla dropped the ball on this fields implementation on the front-end.
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: joomla/Component-Builder#909
No description provided.