[buddypress-trac] [BuddyPress Trac] #8186: xprofile field type display_filter method should provide more data

buddypress-trac noreply at wordpress.org
Thu Dec 26 23:18:31 UTC 2019


#8186: xprofile field type display_filter method should provide more data
-------------------------+-----------------------------
 Reporter:  sbrajesh     |      Owner:  (none)
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  Core         |    Version:  5.0.0
 Severity:  normal       |   Keywords:
-------------------------+-----------------------------
 Hi,
 I have a custom field type(file) and I am trying to use cloud storage for
 the files.
 In order to do that, I am storing a meta key with the data id(not field id
 as field ids are not unique per instance of data).

 To fetch, I need to filter on the value in my display_filter method. The
 data provided in this method are only value and field id.

 We need either field id & user id to find the profile data or we need the
 data id.

 I checked and I can see that the callback is being used by


 {{{
 xprofile_filter_format_field_value_by_type( $field_value, $field_type =
 '', $field_id = '' )
 }}}

 This function itself does not have any idea about the context it is being
 used.

 Looking further, It seems 'xprofile_filter_format_field_value_by_type' is
 being used by
 the filter

 {{{
 bp_get_the_profile_field_value
 }}}

 and the function

 {{{
 xprofile_filter_format_field_value_by_field_id()
 xprofile_format_profile_field()
 }}}


 Is there anyway to resolve it in upcoming release.

-- 
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/8186>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list