mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
#9506 Fixed show profiles
This commit is contained in:
parent
9b79ea7912
commit
29c06a17f7
@ -711,37 +711,35 @@ foreach ($info as $user_id => $user_info) {
|
|||||||
if ($user_profiles !== false) {
|
if ($user_profiles !== false) {
|
||||||
$total_profile = 0;
|
$total_profile = 0;
|
||||||
|
|
||||||
$data[4] .= '<div class="text_end" id="profiles_'.$user_profiles[0]['id_usuario'].'">';
|
$data[4] .= '<div class="text_end">';
|
||||||
foreach ($user_profiles as $row) {
|
foreach ($user_profiles as $row) {
|
||||||
if ($total_profile < 5) {
|
$data[4] .= "<div class='float-left'>";
|
||||||
$data[4] .= "<div class='float-left'>";
|
$data[4] .= profile_get_name($row['id_perfil']);
|
||||||
$data[4] .= profile_get_name($row['id_perfil']);
|
$data[4] .= ' / </div>';
|
||||||
$data[4] .= ' / </div>';
|
$data[4] .= "<div class='float-left pdd_l_5px'>";
|
||||||
$data[4] .= "<div class='float-left pdd_l_5px'>";
|
$data[4] .= groups_get_name($row['id_grupo'], true);
|
||||||
$data[4] .= groups_get_name($row['id_grupo'], true);
|
$data[4] .= '</div>';
|
||||||
$data[4] .= '</div>';
|
|
||||||
|
|
||||||
if ($total_profile == 0 && count($user_profiles) >= 5) {
|
if ($total_profile == 0 && count($user_profiles) >= 5) {
|
||||||
$data[4] .= '<span onclick="showGroups(`'.$row['id_usuario'].'`)" class="pdd_l_15px">'.html_print_image(
|
$data[4] .= '<span onclick="showGroups(`'.$row['id_usuario'].'`)">'.html_print_image(
|
||||||
'images/zoom.png',
|
'images/zoom.png',
|
||||||
true,
|
true,
|
||||||
[
|
[
|
||||||
'title' => __('Show'),
|
'title' => __('Show profiles'),
|
||||||
'class' => 'invert_filter',
|
'class' => 'invert_filter',
|
||||||
]
|
]
|
||||||
).'</span>';
|
).'</span>';
|
||||||
|
|
||||||
$data[4] .= html_print_input_hidden(
|
$data[4] .= html_print_input_hidden(
|
||||||
'show_groups_'.$row['id_usuario'],
|
'show_groups_'.$row['id_usuario'],
|
||||||
-1,
|
-1,
|
||||||
true
|
true
|
||||||
);
|
);
|
||||||
}
|
|
||||||
|
|
||||||
$data[4] .= '<br/>';
|
|
||||||
$data[4] .= '<br/>';
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$data[4] .= '<br/>';
|
||||||
|
$data[4] .= '<br/>';
|
||||||
|
|
||||||
$total_profile++;
|
$total_profile++;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -754,6 +752,8 @@ foreach ($info as $user_id => $user_info) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$data[4] .= '</div>';
|
$data[4] .= '</div>';
|
||||||
|
$data[4] .= '<div class="invisible" id="profiles_'.$user_profiles[0]['id_usuario'].'">';
|
||||||
|
$data[4] .= '</div>';
|
||||||
} else {
|
} else {
|
||||||
$data[4] .= __('The user doesn\'t have any assigned profile/group');
|
$data[4] .= __('The user doesn\'t have any assigned profile/group');
|
||||||
}
|
}
|
||||||
@ -946,14 +946,13 @@ enterprise_hook('close_meta_frame');
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
$(`#hidden-show_groups_${id_user}`).val('1');
|
$(`#hidden-show_groups_${id_user}`).val('1');
|
||||||
|
$(`#profiles_${id_user}`).show();
|
||||||
} else if ($(`#hidden-show_groups_${id_user}`).val() === '1') {
|
} else if ($(`#hidden-show_groups_${id_user}`).val() === '1') {
|
||||||
$(`#hidden-show_groups_${id_user}`).val('0');
|
$(`#hidden-show_groups_${id_user}`).val('0');
|
||||||
$(`div[id^=left_${id_user}_]`).hide();
|
$(`#profiles_${id_user}`).hide();
|
||||||
$(`div[id^=right_${id_user}_]`).hide();
|
|
||||||
} else {
|
} else {
|
||||||
$(`#hidden-show_groups_${id_user}`).val('1');
|
$(`#hidden-show_groups_${id_user}`).val('1');
|
||||||
$(`div[id^=left_${id_user}_]`).show();
|
$(`#profiles_${id_user}`).show();
|
||||||
$(`div[id^=right_${id_user}_]`).show();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user