Update 1.2.92

This commit is contained in:
ultimatemember
2015-05-02 02:49:05 +03:00
parent 3c960b187c
commit 77cde02dd8
43 changed files with 1184 additions and 111 deletions
+31 -1
View File
@@ -41,4 +41,34 @@
.um-admin-drag-fld-title, .um-admin-drag-fld-type {
float: right;
margin: 0 20px 0 0;
}
}
.redux-main {
margin-left: 0!important;
margin-right: 201px !important;
}
#redux-header h2 {
padding: 2px 0 4px 15px;
}
.redux-container #redux-header .display_header {float: right}
.admin-color-fresh .redux-sidebar .redux-group-menu li.hasSubSections a .extraIconSubsections {float: left}
.select2-container .select2-choice > .select2-chosen {
text-align: right !important;
}
.select2-container .select2-choice .select2-arrow {
border: none !important;
right: auto !important;
left: 0 !important;
}
.select2-container .select2-choice > .select2-chosen {
margin-right: 10px !important;
margin-left: 26px !important;
}
.redux-container-switch .switch-options {float: right;margin-right:0!important}
+52 -1
View File
@@ -13,6 +13,57 @@ class UM_Admin_Dashboard {
add_action('admin_menu', array(&$this, 'secondary_menu_items'), 1000);
add_action('admin_menu', array(&$this, 'extension_menu'), 9999);
add_action( 'admin_head', array( $this, 'menu_order_count' ) );
}
/**
* Get pending users (in queue)
*/
function get_pending_users_count() {
if ( get_option('um_cached_users_queue') > 0 ) {
return get_option('um_cached_users_queue');
}
$args = array( 'fields' => 'ID', 'number' => 20 );
$args['meta_query']['relation'] = 'OR';
$args['meta_query'][] = array(
'key' => 'account_status',
'value' => 'awaiting_email_confirmation',
'compare' => '='
);
$args['meta_query'][] = array(
'key' => 'account_status',
'value' => 'awaiting_admin_review',
'compare' => '='
);
$users = new WP_User_Query( $args );
delete_option('um_cached_users_queue');
add_option('um_cached_users_queue', count($users->results), '', 'no' );
return count($users->results);
}
/**
* Manage order of admin menu items
*/
public function menu_order_count() {
global $menu, $submenu;
$count = $this->get_pending_users_count();
foreach( $menu as $key => $menu_item ) {
if ( 0 === strpos( $menu_item[0], _x( 'Users', 'Admin menu name' ) ) ) {
$menu[ $key ][0] .= ' <span class="update-plugins count-'.$count.'"><span class="processing-count">'.$count.'</span></span>';
}
}
foreach ( $submenu['users.php'] as $key => $menu_item ) {
if ( 0 === strpos( $menu_item[0], _x( 'All Users', 'Admin menu name' ) ) ) {
$submenu['users.php'][ $key ][0] .= ' <span class="update-plugins count-'.$count.'"><span class="processing-count">'.$count.'</span></span>';
}
}
}
/***
@@ -51,7 +102,7 @@ class UM_Admin_Dashboard {
*** @extension menu
***/
function extension_menu() {
add_submenu_page( $this->slug, __('Extensions', $this->slug), '<span style="color: #3dc3e5">' .__('Extensions', $this->slug) . '</span>', 'manage_options', $this->slug . '-extensions', array(&$this, 'admin_page') );
add_submenu_page( $this->slug, __('Extensions', $this->slug), '<span style="color: #00B9EB">' .__('Extensions', $this->slug) . '</span>', 'manage_options', $this->slug . '-extensions', array(&$this, 'admin_page') );
}
/***
+8 -3
View File
@@ -117,12 +117,17 @@ class UM_Admin_Notices {
case 'confirm_delete':
$confirm_uri = urldecode($_REQUEST['_refer']);
$users = implode(', ', $_REQUEST['user']);
$users = '';
foreach( $_REQUEST['user'] as $user_id ) {
$user = get_userdata( $user_id );
$users .= '#' . $user_id . ': ' . $user->user_login . '<br />';
}
$ignore = admin_url('users.php');
$messages[0]['err_content'] = sprintf(__('Are you sure you want to delete the selected user(s)? The following users will be deleted: (%s) <strong>This cannot be undone!</strong>','ultimatemember'), $users);
$messages[0]['err_content'] .= '&nbsp;&nbsp;<a href="'.$confirm_uri.'" class="button-primary">' . __('Yes! Delete','ultimatemember') . '</a>&nbsp;&nbsp;<a href="'.$ignore.'" class="button">' . __('Cancel','ultimatemember') . '</a>';
$messages[0]['err_content'] = sprintf(__('Are you sure you want to delete the selected user(s)? The following users will be deleted: <p>%s</p> <strong>This cannot be undone!</strong>','ultimatemember'), $users);
$messages[0]['err_content'] .= '<p><a href="'.$confirm_uri.'" class="button-primary">' . __('Remove','ultimatemember') . '</a>&nbsp;&nbsp;<a href="'.$ignore.'" class="button">' . __('Undo','ultimatemember') . '</a></p>';
break;
+7
View File
@@ -1,5 +1,12 @@
<?php
$premium['followers'] = array(
'url' => 'https://ultimatemember.com/extensions/followers/',
'image' => 'https://ultimatemember.com/wp-content/uploads/2015/04/followers-01-copy.png',
'name' => 'Followers',
'desc' => ' With the followers extension you can increase user interaction on your site by allowing users to follow each other.',
);
$premium['profile-completeness'] = array(
'url' => 'https://ultimatemember.com/extensions/profile-completeness/',
'image' => 'https://ultimatemember.com/wp-content/uploads/2015/04/pc3-01-copy.png',