Skip to content
Snippets Groups Projects
Commit 7ce7c648 authored by Matthieu Guffroy's avatar Matthieu Guffroy
Browse files

Avancement de la gestion du formulaire

parent bf3c994a
No related branches found
No related tags found
No related merge requests found
...@@ -9,7 +9,7 @@ class Form { ...@@ -9,7 +9,7 @@ class Form {
$this->fields = $this->object->getFields(); $this->fields = $this->object->getFields();
// Update or Insert // Update or Insert
if($this->object->{$this->object->primaryAttr}) { if($this->object->{$this->object->primaryAttr}()) {
$this->action = "Modifier"; $this->action = "Modifier";
} else { } else {
$this->action = "Ajouter"; $this->action = "Ajouter";
...@@ -19,7 +19,7 @@ class Form { ...@@ -19,7 +19,7 @@ class Form {
if(isset($_POST["submitForm"])) { if(isset($_POST["submitForm"])) {
$post = true; $post = true;
// Apply validators // Apply validators
// If all validators ok, commit // If all validators ok, commit
} else { } else {
$post = false; $post = false;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment