Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
SambaEdu
sambaedu-wpkg
Commits
17f5e78b
Commit
17f5e78b
authored
Feb 08, 2022
by
Laurent Joly
Browse files
Update maintenance_gestion_poste.php : checkbox
parent
49d2ebc5
Changes
1
Hide whitespace changes
Inline
Side-by-side
sources/var/www/sambaedu/wpkg/maintenance_gestion_poste.php
View file @
17f5e78b
...
...
@@ -46,6 +46,21 @@ else
$page_id
=
1
;
include
(
"maintenance_top.php"
);
echo
"<script>
\n
"
;
echo
"function checkAll()
\n
"
;
echo
"{\n"
;
echo
" var checkboxes = document.getElementsByTagName('input'), val = null;
\n
"
;
echo
" for (var i = 0; i < checkboxes.length; i++)
\n
"
;
echo
" {\n"
;
echo
" if (checkboxes[i].type == 'checkbox')
\n
"
;
echo
" {\n"
;
echo
" if (val === null) val = checkboxes[i].checked;
\n
"
;
echo
" checkboxes[i].checked = val;
\n
"
;
echo
" }
\n
"
;
echo
" }
\n
"
;
echo
" }
\n
"
;
echo
"</script>
\n
"
;
function
maintenance_liste_poste
(
$config
,
$flag
,
$uuid
)
{
$wpkg_link
=
connexion_db_wpkg
(
$config
);
...
...
@@ -164,6 +179,7 @@ if ($liste_poste) {
echo
"<table cellspadding='2' cellspacing='1' border='0' align='center' bgcolor='black'>
\n
"
;
echo
"<tr style='color:white'>
\n
"
;
echo
"<th width='10' rowspan='2'></th>
\n
"
;
echo
"<th width='120' rowspan='2'><a href='?flag="
.
$get_flag
.
"&uuid="
.
$get_uuid
.
"&tri="
;
if
(
$tri
==
0
)
echo
"1"
;
...
...
@@ -249,6 +265,17 @@ echo "</tr>\n";
echo
"<input type='hidden' name='tri' value='"
.
$tri
.
"'>
\n
"
;
echo
"</form>
\n
"
;
echo
"<form method='post' action='?tri2="
.
$tri2
.
"&flag="
.
$get_flag
.
"&uuid="
.
$get_uuid
.
"'>
\n
"
;
echo
"<tr>
\n
"
;
echo
"<td colspan='4'>"
;
echo
"</td>
\n
"
;
echo
"<td colspan='3' style='color:white'>"
;
echo
"<input type='checkbox' onchange='checkAll()' name='chk[]' /> Tous/Aucun"
;
echo
"</td>
\n
"
;
echo
"<td colspan='3'>"
;
echo
"</td>
\n
"
;
echo
"</tr>
\n
"
;
foreach
(
$liste_poste
as
$nom_poste
=>
$lp
)
{
$affichage
=
0
;
...
...
@@ -275,6 +302,9 @@ foreach ($liste_poste as $nom_poste => $lp)
if
(
$affichage
==
1
)
{
echo
"<tr bgcolor='"
.
$bg
.
"' style='color: "
.
$txt
.
"'>"
;
echo
"<td align='center'>"
;
echo
"<input type='checkbox' id='poste_id[]' name='poste_id[]' value='"
.
$lp
[
"id_poste"
]
.
"' />"
;
echo
"</td>"
;
echo
"<td align='center'><a href='poste_statuts.php?id_host="
.
$nom_poste
.
"' style='color: "
.
$lnk
.
"'>"
.
$nom_poste
.
"</a></td>"
;
echo
"<td align='center' bgcolor='"
.
$wintype_txt
.
"'>"
;
echo
'<img src="images/'
;
...
...
@@ -319,6 +349,7 @@ foreach ($liste_poste as $nom_poste => $lp)
}
}
echo
"</table>
\n
"
;
echo
"</form>
\n
"
;
include
(
"pdp.inc.php"
);
?>
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment