diff --git a/js/jsadd.php b/js/jsadd.php
new file mode 100644
index 0000000..41a5db8
--- /dev/null
+++ b/js/jsadd.php
@@ -0,0 +1,47 @@
+
+
diff --git a/model/oversight.php b/model/oversight.php
index 1e48c8c..4fe9960 100644
--- a/model/oversight.php
+++ b/model/oversight.php
@@ -6,7 +6,7 @@
function getPlayer()
{
global $db;
- $result = $db->sql_query("SELECT id_player, name_player , status FROM " . TABLE_SPA_PLAYERS);
+ $result = $db->sql_query("SELECT id_player, name_player , status FROM " . TABLE_SPA_PLAYERS." order by name_player ASC");
$Tretour=array();
while ($tPlayer = $db->sql_fetch_row($result))
@@ -16,4 +16,22 @@ function getPlayer()
}
return $Tretour;
+}
+
+
+
+
+function getStatus()
+{
+ global $db;
+ $result = $db->sql_query("SELECT distinct(status)FROM " . TABLE_SPA_PLAYERS ." order by status ASC ");
+ $tRetour=array();
+
+ while ($tStatus = $db->sql_fetch_row($result))
+ {
+ $tRetour[] = $tStatus["status"];
+
+ }
+ return $tRetour;
+
}
\ No newline at end of file
diff --git a/oversight.php b/oversight.php
index 840259e..a6d5a9a 100644
--- a/oversight.php
+++ b/oversight.php
@@ -10,6 +10,7 @@
$data["players"] = getPlayer();
+
// vue par defaut
switch ($pub_page) {
case "list":
@@ -21,7 +22,9 @@
break;
case "add":
$data["menuactif"]="add";
+ $data["playerStatus"]=getStatus();
include_once(FOLDER_VIEW . "header.php");
+ include_once(FOLDER_JS . "jsadd.php");
include_once(FOLDER_VIEW . "menu.php");
include_once(FOLDER_VIEW . "add.php");
include_once(FOLDER_VIEW . "footer.php");
diff --git a/view/add.php b/view/add.php
index aaa4f4f..26033a8 100644
--- a/view/add.php
+++ b/view/add.php
@@ -1,54 +1,37 @@
AJOUT
-
-
+
+
+
+ Filtre Status:
|
+
+
+
+ |
+
-
+
diff --git a/view/menu.php b/view/menu.php
index 87febc7..0fba987 100644
--- a/view/menu.php
+++ b/view/menu.php
@@ -8,12 +8,12 @@
-
+
|
">
-
+
|