diff --git a/automate.php b/automate.php
index d6f33d7..ee352b7 100755
--- a/automate.php
+++ b/automate.php
@@ -304,4 +304,7 @@
}//editUser();
+
+ echo ResourceDispatcher::getResource('f/svg/search/st/sub-menu-side/#b1b1b1');
+
?>
\ No newline at end of file
diff --git a/js/lib/api.js b/js/lib/api.js
old mode 100644
new mode 100755
diff --git a/js/lib/input-checker.js b/js/lib/input-checker.js
old mode 100644
new mode 100755
diff --git a/manager/ResourceDispatcher.php b/manager/ResourceDispatcher.php
index 66255f5..f6a6cd2 100755
--- a/manager/ResourceDispatcher.php
+++ b/manager/ResourceDispatcher.php
@@ -16,6 +16,7 @@
private $header;
private $path;
private $flags;
+ private $stylesheet;
public $error;
@@ -121,7 +122,7 @@
$correct = $correct && array_key_exists($serialFlags[0], self::$supported_extensions);
// Verification du filename
- $correct = $correct && preg_match('#^[\w_-]+$#i', $serialFlags[1]);
+ $correct = $correct && preg_match('/^[\w_-]+$/i', $serialFlags[1]);
// Verification du parent
$correct = $correct && array_key_exists($serialFlags[2], self::$supported_parents);
@@ -130,7 +131,14 @@
$opt_subParent = count($serialFlags) >= 4;
if( $opt_subParent )
- $correct = $correct && preg_match('#^[\w_-]+$#i', $serialFlags[3]);
+ $correct = $correct && preg_match('/^[\w_-]+$/i', $serialFlags[3]);
+
+ // Verification de la couleur (optionnel)
+ $opt_color = count($serialFlags) >= 5;
+
+ if( $opt_color )
+ $correct = $correct && preg_match('/^#[\da-f]{6}+$/i', $serialFlags[4]);
+
if( !$correct )
@@ -151,6 +159,10 @@
if( $opt_subParent )
$this->flags['subparent'] = $serialFlags[3];
+ // Ajout du color optionnel
+ if( $opt_color )
+ $this->flags['color'] = $serialFlags[4];
+
return true;
@@ -193,15 +205,31 @@
$opt_subParent = (isset($this->flags['subparent'])) ? $this->flags['subparent'].'/' : '';
- /* [4] On definit le header
+ /* [4] Gestion du color optionnel
+ =========================================================*/
+ $this->stylesheet = "";
+
+ // si le color est defini
+ if( isset($this->flags['color']) ){
+ $this->stylesheet = "\n";
+ }
+
+
+
+ /* [5] On definit le header
==========================================================*/
$this->header = $header;
- /* [5] On construit le chemin
+ /* [6] On construit le chemin
==========================================================*/
$this->path = __ROOT__.$parent.'/'.$opt_subParent.$this->flags['filename'].'.'.$this->flags['extension'];
- /* [6] On retourne si le fichier existe ou non
+ /* [7] On retourne si le fichier existe ou non
==========================================================*/
return @file_get_contents( $this->path ) != false;
@@ -223,6 +251,8 @@
// On inclut le contenu
echo file_get_contents($this->path);
+
+ echo $this->stylesheet;
}
@@ -237,7 +267,8 @@
// On inclut le contenu
- return file_get_contents($this->path);
+ return file_get_contents($this->path).$this->stylesheet;
+
}
diff --git a/manager/repo/machine.php b/manager/repo/machine.php
old mode 100644
new mode 100755
diff --git a/manager/sessionManager.php b/manager/sessionManager.php
old mode 100644
new mode 100755
diff --git a/phpunit/bootstrap.php b/phpunit/bootstrap.php
old mode 100644
new mode 100755
diff --git a/phpunit/tests/ManagerError.php b/phpunit/tests/ManagerError.php
old mode 100644
new mode 100755
diff --git a/phpunit/tests/sessionManager.php b/phpunit/tests/sessionManager.php
old mode 100644
new mode 100755
diff --git a/src/static/container/card.svg b/src/static/container/card.svg
old mode 100644
new mode 100755
index a43ea26..08fffbc
--- a/src/static/container/card.svg
+++ b/src/static/container/card.svg
@@ -46,20 +46,20 @@
id="g3154"
transform="matrix(0.07142857,0,0,0.07142857,-2.2857139,-2.2857144)">
\ No newline at end of file
+ id="stylisable" />
\ No newline at end of file
diff --git a/src/static/container/group.svg b/src/static/container/group.svg
old mode 100644
new mode 100755
index b0deef7..637b47a
--- a/src/static/container/group.svg
+++ b/src/static/container/group.svg
@@ -46,9 +46,9 @@
id="g3"
transform="matrix(0.08333202,0,0,0.08333202,-5.3354939,-5.3317337)">
\ No newline at end of file
diff --git a/src/static/container/mail.svg b/src/static/container/mail.svg
index 7d80a0c..3785090 100755
--- a/src/static/container/mail.svg
+++ b/src/static/container/mail.svg
@@ -63,7 +63,7 @@
style="fill:#000000">
diff --git a/src/static/menu-side/analytics.svg b/src/static/menu-side/analytics.svg
index 615aca0..4024b00 100755
--- a/src/static/menu-side/analytics.svg
+++ b/src/static/menu-side/analytics.svg
@@ -62,7 +62,7 @@
style="fill:#000000;fill-opacity:1">
@@ -70,13 +70,13 @@
+ id="stylisable" />
+ id="stylisable" />
+ id="stylisable" />
diff --git a/src/static/menu-side/dashboard.svg b/src/static/menu-side/dashboard.svg
index f097a71..143b1a3 100755
--- a/src/static/menu-side/dashboard.svg
+++ b/src/static/menu-side/dashboard.svg
@@ -50,7 +50,7 @@
id="g3934"
style="fill:#000000;fill-opacity:1"
transform="matrix(1.1423365,0,0,1.1423365,-2.2700952,-2.277384)">
\ No newline at end of file
diff --git a/src/static/menu-side/machines.svg b/src/static/menu-side/machines.svg
index ae8f022..12b1d28 100755
--- a/src/static/menu-side/machines.svg
+++ b/src/static/menu-side/machines.svg
@@ -50,7 +50,7 @@
id="g3"
transform="matrix(0.05944961,0,0,0.05944961,-5.12155e-7,2.921265e-5)">
\ No newline at end of file
diff --git a/src/static/sub-menu-side/analytics.svg b/src/static/sub-menu-side/analytics.svg
index 1d54037..3a97abd 100755
--- a/src/static/sub-menu-side/analytics.svg
+++ b/src/static/sub-menu-side/analytics.svg
@@ -47,8 +47,8 @@
id="g3"
transform="matrix(0.63920738,0,0,0.63920738,-4.4546362,-4.4546361)">
\ No newline at end of file
diff --git a/src/static/sub-menu-side/create.svg b/src/static/sub-menu-side/create.svg
index 622ee01..5063b61 100755
--- a/src/static/sub-menu-side/create.svg
+++ b/src/static/sub-menu-side/create.svg
@@ -65,7 +65,7 @@
diff --git a/src/static/sub-menu-side/edit.svg b/src/static/sub-menu-side/edit.svg
index 4e0a0fb..1e63c19 100755
--- a/src/static/sub-menu-side/edit.svg
+++ b/src/static/sub-menu-side/edit.svg
@@ -53,6 +53,6 @@
inkscape:current-layer="svg2985" />
diff --git a/src/static/sub-menu-side/filter.svg b/src/static/sub-menu-side/filter.svg
index 6061116..3072111 100755
--- a/src/static/sub-menu-side/filter.svg
+++ b/src/static/sub-menu-side/filter.svg
@@ -46,7 +46,7 @@
id="g2998"
transform="matrix(0.32000075,0,0,0.32000075,0.63991432,5.5033384e-5)">
\ No newline at end of file
diff --git a/src/static/sub-menu-side/remove.svg b/src/static/sub-menu-side/remove.svg
index 1cd55e8..373679a 100755
--- a/src/static/sub-menu-side/remove.svg
+++ b/src/static/sub-menu-side/remove.svg
@@ -54,8 +54,8 @@
inkscape:current-layer="svg3038" />
+ id="stylisable" />
+ id="stylisable" />
diff --git a/src/static/sub-menu-side/search.svg b/src/static/sub-menu-side/search.svg
index 59bbea0..8ee6cc2 100755
--- a/src/static/sub-menu-side/search.svg
+++ b/src/static/sub-menu-side/search.svg
@@ -45,6 +45,6 @@
inkscape:current-layer="Layer_1" />
\ No newline at end of file
diff --git a/src/static/sub-menu-side/sync.svg b/src/static/sub-menu-side/sync.svg
index e54a358..3fa17d6 100755
--- a/src/static/sub-menu-side/sync.svg
+++ b/src/static/sub-menu-side/sync.svg
@@ -46,10 +46,10 @@
id="g2991"
transform="matrix(1.0784002,0,0,1.0784002,-1.2543254,-0.92699409)">
\ No newline at end of file
diff --git a/src/static/sub-menu-side/view.svg b/src/static/sub-menu-side/view.svg
index dabe4ff..1d972d8 100755
--- a/src/static/sub-menu-side/view.svg
+++ b/src/static/sub-menu-side/view.svg
@@ -44,5 +44,5 @@
inkscape:window-maximized="1"
inkscape:current-layer="Layer_1" />
\ No newline at end of file
diff --git a/todo.md b/todo.md
index 3fdfa03..0204779 100755
--- a/todo.md
+++ b/todo.md
@@ -7,7 +7,6 @@
############
# EN COURS #
############
-- [ ] [ResourceDispatcher] Gestion de la coloration de svg
- [ ] [view/users][view/js/users.js] Suppression avec recherche comme pour la modification
- [ ] [view/machines][view/js/machines.js] Suppression avec recherche comme pour la modification
@@ -16,6 +15,8 @@
########
# FAIT #
########
+- [x] [ResourceDispatcher] Gestion de la coloration de svg
+ - [x] [src/*.svg] Modification des svg (attribution des ID)
- [x] [container.scss] Gestion des boutons "enabled"/"disabled" lorsqu'on doit faire une recherche
- [x] [view/users+machines] Suppression du sous-menu "Recherche"
- [x] [view/js/machines] Recherche instantanee
diff --git a/view.php b/view.php
index bcafa6c..b168cf0 100755
--- a/view.php
+++ b/view.php
@@ -22,7 +22,7 @@
-
+
diff --git a/view/js/machines.js b/view/js/machines.js
old mode 100644
new mode 100755
index 110659f..9d87320
--- a/view/js/machines.js
+++ b/view/js/machines.js
@@ -385,7 +385,4 @@ if( section.edit.element != null ){
-
-
-
}
\ No newline at end of file
diff --git a/view/js/users.js b/view/js/users.js
old mode 100644
new mode 100755