issue #1265 user manager new design by @GitBluub and @MatthieuLP

Because we had a ghost page user_list_new, I didn't simply merged the feature branch, but I reproduced the new code in a single commit on master.
This commit is contained in:
plegall
2021-05-05 13:41:37 +02:00
parent d29da9f36a
commit fe3147d601
7 changed files with 4075 additions and 1217 deletions
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+19 -3
View File
@@ -1925,6 +1925,8 @@ h2:lang(en) { text-transform:capitalize; }
.infos .submit {margin-left:30px;}
.checkActions {text-align:left;padding:0;margin:0;}
#user-table-content #checkActions {margin:0; display:flex; flex-wrap:wrap; align-items:center;}
#user-table-content #checkActions a {padding:10px; margin: 0 4px};
#checkActions {text-align:left; margin:0 0 20px 0;}
.ActionUserList #checkActions {margin: 20px 0 20px 0;}
@@ -2688,20 +2690,27 @@ a#showPermissions:hover {text-decoration: none;}
overflow: hidden;
}
.user-list-checkbox .select-checkbox,
.tag-container .tag-box .select-checkbox {
display: none;
width: 15px;
height: 15px;
border-radius: 100%;
margin: 2px 0px;
/* margin: 2px 0px; */
margin-left: 3.4px;
border: solid #ffa646 2px;
}
.user-list-checkbox .select-checkbox {
display: inline-block;
}
.tag-container.selection .tag-box .select-checkbox {
display: block;
}
.user-list-checkbox:hover .select-checkbox,
.user-list-checkbox[data-selected='1'] .select-checkbox,
.tag-container .tag-box:hover .select-checkbox,
.tag-container .tag-box[data-selected='1'] .select-checkbox {
background-color: #ffa646;
@@ -2711,6 +2720,7 @@ a#showPermissions:hover {text-decoration: none;}
display: block;
}
.user-list-checkbox .select-checkbox i,
.tag-container .tag-box .select-checkbox i {
display: none;
font-size: 14px;
@@ -2722,6 +2732,7 @@ a#showPermissions:hover {text-decoration: none;}
animation-timing-function: ease-out;
}
.user-list-checkbox[data-selected='1'] .select-checkbox i,
.tag-container .tag-box[data-selected='1'] .select-checkbox i {
display: inline;
}
@@ -4616,18 +4627,23 @@ li.plupload_delete a:hover {background: url("images/cancelhover.svg")!important;
#action_delete_derivatives label, #action_generate_derivatives label {display: flex; margin-top: 4px; width: 50%;}
#action_delete_derivatives input[name="del_derivatives_type[]"], #action_generate_derivatives input[name="generate_derivatives_type[]"] {margin-right: 3px;}
.actionButtons:first-child::after,#filter_prefilter::before,#filter_category::before,#filter_level::before,
.permitActionListButton div::before, #action_level::after, .pictureLevels::before {
.permitActionListButton div::before, #action_level::after, .pictureLevels::before,
.user-action-select-container::before, .advanced-filter-select-container::before,
.user-property-select-container::before {
content: '\e835'; font-size: 17px; position: absolute; font-family: "fontello"; color: #6E6E6E; pointer-events: none;
}
.permitActionListButton div::before {margin-left: 250px; margin-top: 11px;}
.pictureLevels::before {margin-left: 216px; margin-top: 10px;}
.permitActionListButton div.hidden::after {display: none;}
.user-action-select-container::before {top: 5px; right:10px}
.user-property-select-container::before {margin-top: 10px; margin-left:270px;}
.advanced-filter-select-container::before {top: 5px; right:10px}
#filter_prefilter::before {margin-left: 257px; margin-top: 35px;}
#filter_category .selectize-control.single .selectize-input::after {content: none;}
#filter_category {width: 600px;}
#filter_category::before {margin-left: 565px;margin-top: 33px; z-index: 2;}
#filter_level::before {margin-top: 34px; margin-left: 260px;}
#action_level::after {margin-top: -56px; margin-left: 254px;}
#batchManagerGlobal #action_level::after {margin-top: -56px; margin-left: 254px;}
#filter_search input {width: 300px; box-sizing: border-box; padding: 11px 18px;}
#applyFilter, #addFilter,#filterList select, #filter_tags .selectize-input.items.not-full.has-options, .pictureLevels select, #permitAction select{
font-family: "Open Sans", "Lucida Grande",Verdana,Arial,"Bitstream Vera Sans",sans-serif;
+42
View File
@@ -43,11 +43,34 @@ while ($row = pwg_db_fetch_assoc($result))
$groups[$row['id']] = $row['name'];
}
// +-----------------------------------------------------------------------+
// | Dates for filtering |
// +-----------------------------------------------------------------------+
$query = '
SELECT DISTINCT
month(registration_date) as registration_month,
year(registration_date) as registration_year
FROM '.USER_INFOS_TABLE.'
ORDER BY registration_date
;';
$result = pwg_query($query);
$register_dates = array();
while ($row = pwg_db_fetch_assoc($result))
{
$register_dates[] = $row['registration_month'].' '.$row['registration_year'];
}
$template->assign('register_dates', implode(',' , $register_dates));
// +-----------------------------------------------------------------------+
// | template |
// +-----------------------------------------------------------------------+
$template->assign(
array(
'ADMIN_PAGE_TITLE' => l10n('Manage users'),
'ACTIVATE_COMMENTS' => $conf['activate_comments'],
'Double_Password' => $conf['double_password_type_in_admin']
)
@@ -97,6 +120,7 @@ $template->assign(
'password_protected_users' => implode(',', array_unique($password_protected_users)),
'guest_user' => $conf['guest_id'],
'filter_group' => (isset($_GET['group']) ? $_GET['group'] : null),
'connected_user' => $user["id"]
)
);
@@ -132,6 +156,24 @@ foreach ($conf['available_permission_levels'] as $level)
$template->assign('level_options', $level_options);
$template->assign('level_selected', $default_user['level']);
$query = '
SELECT id, name, is_default
FROM `'.GROUPS_TABLE.'`
ORDER BY name ASC
;';
$result = pwg_query($query);
$groups_arr_id = [];
$groups_arr_name = [];
while ($row = pwg_db_fetch_assoc($result))
{
$groups_arr_name[] = '"'.pwg_db_real_escape_string($row["name"]).'"';
$groups_arr_id[] = $row["id"];
}
$template->assign('groups_arr_id', implode(',', $groups_arr_id));
$template->assign('groups_arr_name', implode(',', $groups_arr_name));
$template->assign('guest_id', $conf["guest_id"]);
// +-----------------------------------------------------------------------+
// | html code display |