From 1fe3b252ff9843260c705514429d0fe85e2b30cb Mon Sep 17 00:00:00 2001 From: soufiane Date: Tue, 11 Apr 2023 18:23:43 +0200 Subject: [PATCH] wip #5858 @1:00 --- app/Models/Command.php | 27 +++++++++++++++++++++++++++ app/Models/CommandPanierSchema.php | 29 +++++++++++++++++++++++++++++ app/Models/Panier.php | 27 +++++++++++++++++++++++++++ 3 files changed, 83 insertions(+) create mode 100644 app/Models/Command.php create mode 100644 app/Models/CommandPanierSchema.php create mode 100644 app/Models/Panier.php diff --git a/app/Models/Command.php b/app/Models/Command.php new file mode 100644 index 0000000..1c43883 --- /dev/null +++ b/app/Models/Command.php @@ -0,0 +1,27 @@ + 'command', + 'singular' => 'Commande', + 'plural' => 'Commandes']; + + public function setFields() + { + parent::setFields(); + + $this->addField(['name' => 'status', + 'type' => 'Text', + 'label' => 'Statut', + 'column' => true, + 'tab' => 'Informations' + ]); + + foreach ($this->fields as $fields) { + $this->addField($fields); + } + } +} diff --git a/app/Models/CommandPanierSchema.php b/app/Models/CommandPanierSchema.php new file mode 100644 index 0000000..8299a22 --- /dev/null +++ b/app/Models/CommandPanierSchema.php @@ -0,0 +1,29 @@ + 'user_id', + 'label' => 'user_id', + 'type' => 'Text', + 'column' => true + ], + [ + 'name' => 'addresses', + 'label' => 'Adresses', + 'type' => 'Text', + 'column' => true + ], + [ + 'name' => 'products', + 'label' => 'Produits', + 'type' => 'Text', + 'column' => true + ] + ]; +} diff --git a/app/Models/Panier.php b/app/Models/Panier.php new file mode 100644 index 0000000..80d1dc1 --- /dev/null +++ b/app/Models/Panier.php @@ -0,0 +1,27 @@ + 'selection', + 'singular' => 'Panier', + 'plural' => 'Paniers']; + + public function setFields() + { + parent::setFields(); + + $this->addField(['name' => 'name', + 'type' => 'Text', + 'label' => 'Nom', + 'column' => true + ]); + + foreach ($this->fields as $fields) { + $this->addField($fields); + } + } +} -- 2.39.5