SMF icon indicating copy to clipboard operation
SMF copied to clipboard

custom profile fields showing on buddy list in profile

Open illori opened this issue 10 years ago • 14 comments

IMO the custom profile fields should not show on the buddy list unless they also show on the members list. currently all the fields show even if they are not on the members list. this can cause a lot of info to be loaded on that page that may not be important to see.

illori avatar May 24 '15 13:05 illori

i see no performance issue, since we load all fields information in one select and only maintained fields get a dataset.

Recommand to close until someone got a real performance issue with that.

albertlast avatar Dec 26 '17 13:12 albertlast

i dont agree with this being closed, i think this should still be looked into. the fields shown are not all necessary and should be limited. i dont think it is a performance issue at first look but what if you have 100 buddies? is it then a performance hit? not to mention that we dont need all this info shown here, what if you have 20 custom profile fields? why do you need them all shown here?

illori avatar Dec 28 '17 10:12 illori

actually looks like there is some code to not show disable the fields but i dont think it is working $context['custom_pf'] = array(); $disabled_fields = isset($modSettings['disabled_profile_fields']) ? array_flip(explode(',', $modSettings['disabled_profile_fields'])) : array(); while ($row = $smcFunc['db_fetch_assoc']($request)) if (!isset($disabled_fields[$row['col_name']])) $context['custom_pf'][$row['col_name']] = array( 'label' => $row['field_name'], 'type' => $row['field_type'], 'bbc' => !empty($row['bbc']), 'enclose' => $row['enclose'], );

`// Gotta disable the gender option.
if (isset($context['custom_pf']['cust_gender']) && $context['custom_pf']['cust_gender'] == 'Disabled')
	unset($context['custom_pf']['cust_gender']);

$smcFunc['db_free_result']($request);`

this is from profile-modify.php that should remove the fields that are set to not show on the memberlist right?

illori avatar Dec 28 '17 11:12 illori

Like I mention from performance point of view it's not critical. 100 Buddies with 20 customs fields (where not all are maintained) are literay 1k datarows -> 1k is nothing even when als fields a maintained by all user 2k rows keeps nothing.

When you got complains about the displaying, than i don't care.

albertlast avatar Dec 28 '17 11:12 albertlast

My thoughts are that your buddies list your more likely to want to see their information displayed. This differs from the generic memberlist which is just showing member information. Profile Fields allows showing/hiding on the memberlist.

I don't think a change is needed here.

jdarwood007 avatar Sep 02 '18 22:09 jdarwood007

The useful fields on the members list are likely not the same as the useful fields on the buddies list, so using the same setting to determine both lists isn't a good solution. But it is also problematic to assume, as the code currently does, that all custom profile fields belong on the buddies list. We should add another setting for the profile fields to specify whether they should be included on the buddies list. It'll just take another checkbox in the UI and another column in the table.

Sesquipedalian avatar Sep 19 '18 02:09 Sesquipedalian

First of all you say rc 1 bitin rc 2

betonkamil avatar Sep 19 '18 17:09 betonkamil

rc1 needs to be released, so this pr can wait.

albertlast avatar Sep 19 '18 17:09 albertlast

A beautiful dream, as if it were really rc1d rc 2

betonkamil avatar Sep 19 '18 17:09 betonkamil

especially a rc1

betonkamil avatar Sep 19 '18 17:09 betonkamil

So what is target of this issue?

albertlast avatar Feb 08 '19 14:02 albertlast

It is still marked for RC2 although I can argue this isn't a critical issue and while it needs to be done it can be easily be labeled for Final.

MissAllSunday avatar Feb 08 '19 16:02 MissAllSunday

well my question was, what is here do now?

albertlast avatar Feb 08 '19 16:02 albertlast

We should add another setting for the profile fields to specify whether they should be included on the buddies list. It'll just take another checkbox in the UI and another column in the table.

Since there aren't any other suggestions I suppose this still applies.

MissAllSunday avatar Feb 08 '19 16:02 MissAllSunday