Open ghost opened 7 years ago
Hello Carles,
I found out that the above feature request of Location mapping and drop down is already implemented in the Plugin User Plus+ by Rainlab.
In the profile page, the Plugin User Plus+ displays the real name of countries and states.
Whereas the Plugin User Profile shows their IDs.
Because this feature is already implemented in the User Plus+, it should not be a lot of work to implement this.
However, if - and when - you implement this, it would be really great if you could also consider implementing the feature of display + edit of other tables, not just Location plugin.
Because User Plus+ is static and provides pre-configured fields and your plugin has already taken a very generic approach to creating and updating fields, it would be helpful, if you could maintain this generic approach by mapping fields to tables in a generic manner, that is just not limited to Location table.
This means I want to create a drop down field. Then I choose the table. Thereafter, I could choose field. Then the Plugin User Profile saved the ID/Label to be generated in the create/update forms.
This method also applies to updating tables. If one could choose which table fields needs to be updated, then one could create new tables and update them directly from the User Profile table.
Thereafter, one could have separate tables, like for social profile, business profile, private profile, job profile, etc.
Hello SchneiderDe,
First, please forgive me for taking so long to answer your suggestions.
My comments on them:
X
(top right) of the field and Saving. On the other hand It is true that the field is not removed from the database. I'm not sure if it is best to add a checkbox to confirm database column removal on the delete dialog, or just remove the column directly. Any thoughts?users
table is a really bad idea). The User Profile data should be stored in its own table. I'm not sure if you are suggesting to have a separate table for each profile tab. If that is the case, I think it is a bit oversized. Just a separate table for all the profile fields data would be enough to me.id, name
as a convention. Then that approach would be compatible with the RainLab.Location tables or other already existing tables. As you suggested, that list of options would be always editable from User Profile. I guess for something as generic as this, allowing multiple selection drop-downs is desirable.Thanks a lot for your time.
Hello Carles,
Thank you for your fantastic User Profile plugin! It is so charming and generic that it belongs to core of OctoberCMS.
I have fields based on Location plugin having country, state and city fields in the users table that stores their respective IDs, like country_id, state_id and city_id of that user. Here, I have an extra Tab named Region. The same could be to have different other Tabs.
In the admin, these fields are directly populated, which means they are not relational. So, the data values are shown as the ID of that country/state/city. But these fields are dependent and needs to do the following:
1) It should create a drop down. 2) It should fetch the value from the location tables and display their Labels.
That means that your generic coding needs to be extended a little bit by adding a new field type with certain additional parameters and making it relational or dependent.
Further, the backend form to display the fields is a one page form that displays all the fields. If possible, it would be helpful to make an overview of all the additional fields created by Profile plugin and select only that particular field for making a change.
Also, deleting a field function is missing.
Another feature that would really make your plugin extra-ordinary would be to have different tables for each profile, like users_profile_private, users_profile_business, etc.
Would you be interested to have some of these modifications? These enhancement would be in the interest of the community.