Adding new display groups to the userfields

xf_phantom

Well-known member
How to do this?

i've extended the userfield model and datawriter, added it to the enum field in the database, but what's the best way to put this into an addon?
e.g. i can't just use this query

Code:
ALTER TABLE  `xf_user_field` CHANGE  `display_group`  `display_group` ENUM
(  'personal',  'contact',  'preferences',  'test1', 'test2' )
CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT  'personal';

because it would add test1 and test2 but remove e.g. all other custom enum values.
 
Hmm, an enumerated type like that isn't really made to be extended. It's probably better to create a new field for your custom categories, and implement them separately from the default categories.

Ideally the devs should create a proper category system for user fields.
 
It's probably better to create a new field for your custom categories, and implement them separately from the default categories.
hm?
Sorry, not sure how you mean this. I can't add a new userfield with a new display location (display_group) without changing the db structure.
 
Back
Top Bottom