- fixed problem with multisite;

- fixed problem with members directory search;
- fixed admin bar;
This commit is contained in:
yura_nalivaiko
2018-05-31 13:14:21 +03:00
parent d4188290d3
commit 01630c9385
4 changed files with 42 additions and 23 deletions
+20 -5
View File
@@ -88,14 +88,14 @@ if ( ! class_exists( 'um\core\Members' ) ) {
return $string;
}
/**
* Show filter
/**
* Prepare filter data
*
* @param $filter
* @return array
*/
function show_filter( $filter ) {
$fields = UM()->builtin()->all_user_fields;
function prepare_filter( $filter ) {
$fields = UM()->builtin()->all_user_fields;
if ( isset( $fields[ $filter ] ) ) {
$attrs = $fields[ $filter ];
@@ -222,6 +222,21 @@ if ( ! class_exists( 'um\core\Members' ) ) {
$attrs = apply_filters( 'um_search_select_fields', $attrs );
}
return compact( 'type', 'attrs' );
}
/**
* Show filter
*
* @param $filter
*/
function show_filter( $filter ) {
/**
* @var $type
* @var $attrs
*/
extract( $this->prepare_filter( $filter ) );
switch ( $type ) {
case 'select':