insert('plugin_materiels_entry', $data); } public function edit($id, $data = []) { $db = DB::getInstance(); $db->update('plugin_materiels_entry', $data, $db->where('id', $id)); } public function listAll() { return DB::getInstance()->get('SELECT * FROM plugin_materiels_entry ORDER BY date_of_entry DESC;'); } }