Opened 7 years ago
Last modified 3 years ago
#8186 new enhancement
xprofile field type display_filter method should provide more data
| Reported by: | sbrajesh | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Awaiting Contributions |
| Component: | Core | Version: | 5.0.0 |
| Severity: | normal | Keywords: | needs-patch |
| Cc: | sbrajesh |
Description
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.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Sorry we were not able to work on this during 12.0, I'd be happy to review a patch about it though :)