From 1865072b73fc5c157f1f80fb03c6da48f79d3246 Mon Sep 17 00:00:00 2001 From: osaajani Date: Mon, 4 Nov 2019 17:12:52 +0100 Subject: [PATCH] Update methods names --- controllers/internals/Command.php | 6 +++--- controllers/internals/Contact.php | 10 +++++----- controllers/internals/Event.php | 6 +++--- controllers/internals/Group.php | 10 +++++----- controllers/internals/Received.php | 10 +++++----- controllers/internals/Scheduled.php | 10 +++++----- controllers/internals/Sended.php | 10 +++++----- controllers/internals/SmsStop.php | 10 +++++----- controllers/publics/Command.php | 27 +++++++-------------------- controllers/publics/Contact.php | 6 +++--- controllers/publics/Discussion.php | 2 +- controllers/publics/Event.php | 2 +- controllers/publics/Group.php | 6 +++--- controllers/publics/Received.php | 2 +- controllers/publics/Scheduled.php | 4 ++-- controllers/publics/Sended.php | 2 +- controllers/publics/SmsStop.php | 2 +- models/Command.php | 6 +++--- models/Contact.php | 8 ++++---- models/Event.php | 8 ++++---- models/Group.php | 8 ++++---- models/Received.php | 8 ++++---- models/Scheduled.php | 8 ++++---- models/Sended.php | 8 ++++---- models/SmsStop.php | 8 ++++---- todo.txt | 2 +- 26 files changed, 88 insertions(+), 101 deletions(-) diff --git a/controllers/internals/Command.php b/controllers/internals/Command.php index 4807869..6cb0a77 100755 --- a/controllers/internals/Command.php +++ b/controllers/internals/Command.php @@ -46,10 +46,10 @@ namespace controllers\internals; * * @return array : La liste des commandes */ - public function get_by_ids($ids) + public function gets($ids) { //Recupération des commandes - return $this->model_command->get_by_ids($ids); + return $this->model_command->gets($ids); } /** @@ -71,7 +71,7 @@ namespace controllers\internals; */ public function delete($id) { - return $this->model_command->delete_by_id($id); + return $this->model_command->delete($id); } /** diff --git a/controllers/internals/Contact.php b/controllers/internals/Contact.php index e4a279f..ddfdbc4 100755 --- a/controllers/internals/Contact.php +++ b/controllers/internals/Contact.php @@ -34,10 +34,10 @@ namespace controllers\internals; * * @return array : La liste des contactes */ - public function get_list($nb_entry = false, $page = false) + public function list($nb_entry = false, $page = false) { //Recupération des contactes - return $this->model_contact->get_list($nb_entry, $nb_entry * $page); + return $this->model_contact->list($nb_entry, $nb_entry * $page); } /** @@ -47,10 +47,10 @@ namespace controllers\internals; * * @return array : La liste des contactes */ - public function get_by_ids($ids) + public function gets($ids) { //Recupération des contactes - return $this->model_contact->get_by_ids($ids); + return $this->model_contact->gets($ids); } /** @@ -98,7 +98,7 @@ namespace controllers\internals; */ public function delete($id) { - return $this->model_contact->delete_by_id($id); + return $this->model_contact->delete($id); } /** diff --git a/controllers/internals/Event.php b/controllers/internals/Event.php index 7fa5780..feb4555 100755 --- a/controllers/internals/Event.php +++ b/controllers/internals/Event.php @@ -33,10 +33,10 @@ namespace controllers\internals; * * @return array : La liste des events */ - public function get_list($nb_entry = false, $page = false) + public function list($nb_entry = false, $page = false) { //Recupération des events - return $this->model_event->get_list($nb_entry, $nb_entry * $page); + return $this->model_event->list($nb_entry, $nb_entry * $page); } /** @@ -61,7 +61,7 @@ namespace controllers\internals; */ public function delete($id) { - return $this->model_event->delete_by_id($id); + return $this->model_event->delete($id); } /** diff --git a/controllers/internals/Group.php b/controllers/internals/Group.php index a391d1f..a219a2c 100755 --- a/controllers/internals/Group.php +++ b/controllers/internals/Group.php @@ -34,10 +34,10 @@ namespace controllers\internals; * * @return array : La liste des groups */ - public function get_list($nb_entry = false, $page = false) + public function list($nb_entry = false, $page = false) { //Recupération des groups - return $this->model_group->get_list($nb_entry, $nb_entry * $page); + return $this->model_group->list($nb_entry, $nb_entry * $page); } /** @@ -47,10 +47,10 @@ namespace controllers\internals; * * @return array : La liste des groups */ - public function get_by_ids($ids) + public function gets($ids) { //Recupération des groups - return $this->model_group->get_by_ids($ids); + return $this->model_group->gets($ids); } /** @@ -85,7 +85,7 @@ namespace controllers\internals; */ public function delete($ids) { - return $this->model_group->delete_by_ids($ids); + return $this->model_group->deletes($ids); } /** diff --git a/controllers/internals/Received.php b/controllers/internals/Received.php index 33d341e..96a56d7 100755 --- a/controllers/internals/Received.php +++ b/controllers/internals/Received.php @@ -32,10 +32,10 @@ class Received extends \descartes\InternalController * * @return array : La liste des receivedes */ - public function get_list($nb_entry = false, $page = false) + public function list($nb_entry = false, $page = false) { //Recupération des receivedes - return $this->model_received->get_list($nb_entry, $nb_entry * $page); + return $this->model_received->list($nb_entry, $nb_entry * $page); } /** @@ -45,10 +45,10 @@ class Received extends \descartes\InternalController * * @return array : La liste des receivedes */ - public function get_by_ids($ids) + public function gets($ids) { //Recupération des receivedes - return $this->model_received->get_by_ids($ids); + return $this->model_received->gets($ids); } /** @@ -110,7 +110,7 @@ class Received extends \descartes\InternalController */ public function delete($id) { - return $this->model_received->delete_by_id($id); + return $this->model_received->delete($id); } /** diff --git a/controllers/internals/Scheduled.php b/controllers/internals/Scheduled.php index 900fc18..fd352e7 100755 --- a/controllers/internals/Scheduled.php +++ b/controllers/internals/Scheduled.php @@ -34,10 +34,10 @@ namespace controllers\internals; * * @return array : La liste des scheduledes */ - public function get_list($nb_entry = false, $page = false) + public function list($nb_entry = false, $page = false) { //Recupération des scheduledes - return $this->model_scheduled->get_list($nb_entry, $nb_entry * $page); + return $this->model_scheduled->list($nb_entry, $nb_entry * $page); } /** @@ -47,10 +47,10 @@ namespace controllers\internals; * * @return array : La liste des scheduledes */ - public function get_by_ids($ids) + public function gets($ids) { //Recupération des scheduledes - return $this->model_scheduled->get_by_ids($ids); + return $this->model_scheduled->gets($ids); } /** @@ -85,7 +85,7 @@ namespace controllers\internals; */ public function delete($id) { - return $this->model_scheduled->delete_by_id($id); + return $this->model_scheduled->delete($id); } /** diff --git a/controllers/internals/Sended.php b/controllers/internals/Sended.php index 3895b82..69ee791 100755 --- a/controllers/internals/Sended.php +++ b/controllers/internals/Sended.php @@ -32,10 +32,10 @@ namespace controllers\internals; * * @return array : La liste des sendedes */ - public function get_list($nb_entry = false, $page = false) + public function list($nb_entry = false, $page = false) { //Recupération des sendedes - return $this->model_sended->get_list($nb_entry, $nb_entry * $page); + return $this->model_sended->list($nb_entry, $nb_entry * $page); } /** @@ -45,10 +45,10 @@ namespace controllers\internals; * * @return array : La liste des sendedes */ - public function get_by_ids($ids) + public function gets($ids) { //Recupération des sendedes - return $this->model_sended->get_by_ids($ids); + return $this->model_sended->gets($ids); } /** @@ -86,7 +86,7 @@ namespace controllers\internals; */ public function delete($id) { - return $this->model_sended->delete_by_id($id); + return $this->model_sended->delete($id); } /** diff --git a/controllers/internals/SmsStop.php b/controllers/internals/SmsStop.php index 143887d..1704061 100755 --- a/controllers/internals/SmsStop.php +++ b/controllers/internals/SmsStop.php @@ -32,10 +32,10 @@ namespace controllers\internals; * * @return array : La liste des smsstopes */ - public function get_list($nb_entry = false, $page = false) + public function list($nb_entry = false, $page = false) { //Recupération des smsstopes - return $this->model_sms_stop->get_list($nb_entry, $nb_entry * $page); + return $this->model_sms_stop->list($nb_entry, $nb_entry * $page); } /** @@ -45,10 +45,10 @@ namespace controllers\internals; * * @return array : La liste des smsstopes */ - public function get_by_ids($ids) + public function gets($ids) { //Recupération des smsstopes - return $this->model_sms_stop->get_by_ids($ids); + return $this->model_sms_stop->gets($ids); } /** @@ -84,7 +84,7 @@ namespace controllers\internals; */ public function delete($id) { - return $this->model_sms_stop->delete_by_id($id); + return $this->model_sms_stop->delete($id); } /** diff --git a/controllers/publics/Command.php b/controllers/publics/Command.php index ce91e84..f3b1630 100755 --- a/controllers/publics/Command.php +++ b/controllers/publics/Command.php @@ -66,9 +66,7 @@ namespace controllers\publics; $this->internal_command->delete($id); } - $this->redirect(\descartes\Router::url('Command', 'list')); - - return true; + return $this->redirect(\descartes\Router::url('Command', 'list')); } /** @@ -89,7 +87,7 @@ namespace controllers\publics; global $db; $ids = $_GET['ids'] ?? []; - $commands = $this->internal_command->get_by_ids($ids); + $commands = $this->internal_command->gets($ids); $this->render('command/edit', [ 'commands' => $commands, @@ -111,31 +109,26 @@ namespace controllers\publics; if (!$this->verify_csrf($csrf)) { \modules\DescartesSessionMessages\internals\DescartesSessionMessages::push('danger', 'Jeton CSRF invalid !'); - $this->redirect(\descartes\Router::url('Command', 'list')); - - return false; + return $this->redirect(\descartes\Router::url('Command', 'list')); } $name = $_POST['name'] ?? false; $script = $_POST['script'] ?? false; - $admin = (isset($_POST['admin']) ? $_POST['admin'] : false); + $admin = $_POST['admin'] ?? false; if (!$name || !$script) { \modules\DescartesSessionMessages\internals\DescartesSessionMessages::push('danger', 'Renseignez au moins un nom et un script.'); - return $this->redirect(\descartes\Router::url('Command', 'list')); } if (!$this->internal_command->create($name, $script, $admin)) { \modules\DescartesSessionMessages\internals\DescartesSessionMessages::push('danger', 'Impossible créer cette commande.'); - return $this->redirect(\descartes\Router::url('commands', 'add')); } \modules\DescartesSessionMessages\internals\DescartesSessionMessages::push('success', 'La commande a bien été crée.'); - return $this->redirect(\descartes\Router::url('Command', 'list')); } @@ -152,9 +145,7 @@ namespace controllers\publics; if (!$this->verify_csrf($csrf)) { \modules\DescartesSessionMessages\internals\DescartesSessionMessages::push('danger', 'Jeton CSRF invalid !'); - $this->redirect(\descartes\Router::url('Command', 'list')); - - return false; + return $this->redirect(\descartes\Router::url('Command', 'list')); } $nb_commands_update = 0; @@ -167,14 +158,10 @@ namespace controllers\publics; if ($nb_commands_update !== \count($_POST['commands'])) { \modules\DescartesSessionMessages\internals\DescartesSessionMessages::push('danger', 'Certaines commandes n\'ont pas pu êtres mises à jour.'); - $this->redirect(\descartes\Router::url('Command', 'list')); - - return false; + return $this->redirect(\descartes\Router::url('Command', 'list')); } \modules\DescartesSessionMessages\internals\DescartesSessionMessages::push('success', 'Toutes les commandes ont été modifiées avec succès.'); - $this->redirect(\descartes\Router::url('Command', 'list')); - - return true; + return $this->redirect(\descartes\Router::url('Command', 'list')); } } diff --git a/controllers/publics/Contact.php b/controllers/publics/Contact.php index cce7f5c..5a9baa7 100755 --- a/controllers/publics/Contact.php +++ b/controllers/publics/Contact.php @@ -44,7 +44,7 @@ namespace controllers\publics; public function list($page = 0) { $page = (int) $page; - $contacts = $this->internal_contact->get_list(25, $page); + $contacts = $this->internal_contact->list(25, $page); $this->render('contact/list', ['contacts' => $contacts]); } @@ -94,7 +94,7 @@ namespace controllers\publics; global $db; $ids = $_GET['ids'] ?? []; - $contacts = $this->internal_contact->get_by_ids($ids); + $contacts = $this->internal_contact->gets($ids); $this->render('contact/edit', [ 'contacts' => $contacts, @@ -189,6 +189,6 @@ namespace controllers\publics; public function json_list() { header('Content-Type: application/json'); - echo json_encode($this->internal_contact->get_list()); + echo json_encode($this->internal_contact->list()); } } diff --git a/controllers/publics/Discussion.php b/controllers/publics/Discussion.php index cee6e71..0d97452 100755 --- a/controllers/publics/Discussion.php +++ b/controllers/publics/Discussion.php @@ -200,7 +200,7 @@ namespace controllers\publics; { $_SESSION['discussion_wait_progress'] = isset($_SESSION['discussion_wait_progress']) ? $_SESSION['discussion_wait_progress'] : []; - $scheduleds = $this->internal_scheduled->get_by_ids($_SESSION['discussion_wait_progress']); + $scheduleds = $this->internal_scheduled->gets($_SESSION['discussion_wait_progress']); //On va chercher à chaque fois si on a trouvé le sms. Si ce n'est pas le cas c'est qu'il a été envoyé $sendeds = []; diff --git a/controllers/publics/Event.php b/controllers/publics/Event.php index 0f0bb15..e8bc2a5 100755 --- a/controllers/publics/Event.php +++ b/controllers/publics/Event.php @@ -43,7 +43,7 @@ namespace controllers\publics; { $page = (int) $page; $limit = 25; - $events = $this->internal_event->get_list($limit, $page); + $events = $this->internal_event->list($limit, $page); $this->render('event/list', ['events' => $events, 'limit' => $limit, 'page' => $page, 'nb_results' => \count($events)]); } diff --git a/controllers/publics/Group.php b/controllers/publics/Group.php index 5820b08..eeba52a 100755 --- a/controllers/publics/Group.php +++ b/controllers/publics/Group.php @@ -46,7 +46,7 @@ namespace controllers\publics; public function list($page = 0) { $page = (int) $page; - $groups = $this->internal_group->get_list(25, $page); + $groups = $this->internal_group->list(25, $page); foreach ($groups as $key => $group) { @@ -100,7 +100,7 @@ namespace controllers\publics; { $ids = $_GET['ids'] ?? []; - $groups = $this->internal_group->get_by_ids($ids); + $groups = $this->internal_group->gets($ids); foreach ($groups as $key => $group) { @@ -195,6 +195,6 @@ namespace controllers\publics; public function json_list() { header('Content-Type: application/json'); - echo json_encode($this->internal_group->get_list()); + echo json_encode($this->internal_group->list()); } } diff --git a/controllers/publics/Received.php b/controllers/publics/Received.php index 68a73ea..d019c48 100755 --- a/controllers/publics/Received.php +++ b/controllers/publics/Received.php @@ -44,7 +44,7 @@ namespace controllers\publics; { $page = (int) $page; $limit = 25; - $receiveds = $this->internal_received->get_list($limit, $page); + $receiveds = $this->internal_received->list($limit, $page); foreach ($receiveds as $key => $received) { diff --git a/controllers/publics/Scheduled.php b/controllers/publics/Scheduled.php index 183e051..7ec081b 100755 --- a/controllers/publics/Scheduled.php +++ b/controllers/publics/Scheduled.php @@ -41,7 +41,7 @@ namespace controllers\publics; public function list($page = 0) { $page = (int) $page; - $scheduleds = $this->internal_scheduled->get_list(25, $page); + $scheduleds = $this->internal_scheduled->list(25, $page); $this->render('scheduled/list', ['scheduleds' => $scheduleds]); } @@ -94,7 +94,7 @@ namespace controllers\publics; { $ids = $_GET['ids'] ?? []; - $scheduleds = $this->internal_scheduled->get_by_ids($ids); + $scheduleds = $this->internal_scheduled->gets($ids); //Pour chaque message on ajoute les numéros, les contacts & les groups foreach ($scheduleds as $key => $scheduled) diff --git a/controllers/publics/Sended.php b/controllers/publics/Sended.php index a86b4d1..194a941 100755 --- a/controllers/publics/Sended.php +++ b/controllers/publics/Sended.php @@ -42,7 +42,7 @@ namespace controllers\publics; { $page = (int) $page; $limit = 25; - $sendeds = $this->internal_sended->get_list($limit, $page); + $sendeds = $this->internal_sended->list($limit, $page); $this->render('sended/list', ['sendeds' => $sendeds, 'page' => $page, 'limit' => $limit, 'nb_results' => \count($sendeds)]); } diff --git a/controllers/publics/SmsStop.php b/controllers/publics/SmsStop.php index 4af4f02..0beb6f9 100755 --- a/controllers/publics/SmsStop.php +++ b/controllers/publics/SmsStop.php @@ -42,7 +42,7 @@ namespace controllers\publics; { $page = (int) $page; $limit = 25; - $smsstops = $this->internal_sms_stop->get_list($limit, $page); + $smsstops = $this->internal_sms_stop->list($limit, $page); $this->render('smsstop/list', ['page' => $page, 'smsstops' => $smsstops, 'limit' => $limit, 'nb_results' => \count($smsstops)]); } diff --git a/models/Command.php b/models/Command.php index fd75d50..6c59e10 100755 --- a/models/Command.php +++ b/models/Command.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $commands = $this->_select('command', ['id' => $id]); @@ -49,7 +49,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM command @@ -70,7 +70,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_id($id) + public function delete($id) { $query = ' DELETE FROM command diff --git a/models/Contact.php b/models/Contact.php index c703aa8..e4e1cf2 100755 --- a/models/Contact.php +++ b/models/Contact.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $contacts = $this->_select('contact', ['id' => $id]); @@ -65,7 +65,7 @@ namespace models; * @param int $limit : Nombre de résultat maximum à retourner * @param int $offset : Nombre de résultat à ingnorer */ - public function get_list($limit, $offset) + public function list($limit, $offset) { return $this->_select('contact', [], '', false, $limit, $offset); } @@ -77,7 +77,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM contact @@ -98,7 +98,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_id($id) + public function delete($id) { $query = ' DELETE FROM contact diff --git a/models/Event.php b/models/Event.php index ff0c707..00031b4 100755 --- a/models/Event.php +++ b/models/Event.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $events = $this->_select('event', ['id' => $id]); @@ -37,7 +37,7 @@ namespace models; * @param int $limit : Nombre de résultat maximum à retourner * @param int $offset : Nombre de résultat à ingnorer */ - public function get_list($limit, $offset) + public function list($limit, $offset) { return $this->_select('event', [], '', false, $limit, $offset); } @@ -61,7 +61,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM event @@ -83,7 +83,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_id($id) + public function delete($id) { $query = ' DELETE FROM event diff --git a/models/Group.php b/models/Group.php index c3b70ed..4848cb6 100755 --- a/models/Group.php +++ b/models/Group.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $groups = $this->_select('group', ['id' => $id]); @@ -51,7 +51,7 @@ namespace models; * @param int $limit : Nombre de résultat maximum à retourner * @param int $offset : Nombre de résultat à ingnorer */ - public function get_list($limit, $offset) + public function list($limit, $offset) { return $this->_select('group', [], '', false, $limit, $offset); } @@ -63,7 +63,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM group @@ -84,7 +84,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_ids($ids) + public function deletes($ids) { $query = ' DELETE FROM group diff --git a/models/Received.php b/models/Received.php index a78c08a..c853cdb 100755 --- a/models/Received.php +++ b/models/Received.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $receiveds = $this->_select('received', ['id' => $id]); @@ -37,7 +37,7 @@ namespace models; * @param int $limit : Nombre de résultat maximum à retourner * @param int $offset : Nombre de résultat à ingnorer */ - public function get_list($limit, $offset) + public function list($limit, $offset) { return $this->_select('received', [], '', false, $limit, $offset); } @@ -73,7 +73,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM received @@ -95,7 +95,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_id($id) + public function delete($id) { $query = ' DELETE FROM received diff --git a/models/Scheduled.php b/models/Scheduled.php index 77faa4c..c0e583c 100755 --- a/models/Scheduled.php +++ b/models/Scheduled.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $scheduleds = $this->_select('scheduled', ['id' => $id]); @@ -37,7 +37,7 @@ namespace models; * @param int $limit : Nombre de résultat maximum à retourner * @param int $offset : Nombre de résultat à ingnorer */ - public function get_list($limit, $offset) + public function list($limit, $offset) { return $this->_select('scheduled', [], '', false, $limit, $offset); } @@ -49,7 +49,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM scheduled @@ -124,7 +124,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_id($id) + public function delete($id) { $query = ' DELETE FROM scheduled diff --git a/models/Sended.php b/models/Sended.php index 080828f..56e9148 100755 --- a/models/Sended.php +++ b/models/Sended.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $sendeds = $this->_select('sended', ['id' => $id]); @@ -37,7 +37,7 @@ namespace models; * @param int $limit : Nombre de résultat maximum à retourner * @param int $offset : Nombre de résultat à ingnorer */ - public function get_list($limit, $offset) + public function list($limit, $offset) { return $this->_select('sended', [], '', false, $limit, $offset); } @@ -49,7 +49,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM sended @@ -95,7 +95,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_id($id) + public function delete($id) { $query = ' DELETE FROM sended diff --git a/models/SmsStop.php b/models/SmsStop.php index 0b68359..89aa7de 100755 --- a/models/SmsStop.php +++ b/models/SmsStop.php @@ -24,7 +24,7 @@ namespace models; * * @return array : L'entrée */ - public function get_by_id($id) + public function get($id) { $smsstops = $this->_select('smsstop', ['id' => $id]); @@ -51,7 +51,7 @@ namespace models; * @param int $limit : Nombre de résultat maximum à retourner * @param int $offset : Nombre de résultat à ingnorer */ - public function get_list($limit, $offset) + public function list($limit, $offset) { return $this->_select('smsstop', [], '', false, $limit, $offset); } @@ -63,7 +63,7 @@ namespace models; * * @return array : La liste des entrées */ - public function get_by_ids($ids) + public function gets($ids) { $query = ' SELECT * FROM smsstop @@ -85,7 +85,7 @@ namespace models; * * @return int : Le nombre de lignes supprimées */ - public function delete_by_id($id) + public function delete($id) { $query = ' DELETE FROM smsstop diff --git a/todo.txt b/todo.txt index f2c7e1e..eb525ec 100644 --- a/todo.txt +++ b/todo.txt @@ -1,6 +1,6 @@ Migrate to latest version of descartes. Remove all useless functions y Account.php (almost done need to do user after) -p Command.php +y Command.php Connect.php Contact.php Dashboard.php