コード例 #1
0
 /**
  * Suppression d'un schéma sur une règle
  * @param unknown_type $rdgidrdg
  * @param unknown_type $schidsch
  */
 public function deleteschema($rdgidrdg, $schidsch, $prjidprj = null)
 {
     $rdg = RdG_model::getRdG($this->db, $rdgidrdg);
     $rdg->removeSchema($this->db, $schidsch);
     if ($prjidprj != null) {
         redirect('editrdg/index/' . $rdgidrdg . '/' . $prjidprj);
     } else {
         redirect('editrdg/index/' . $rdgidrdg);
     }
 }
コード例 #2
0
 /**
  * Ajout d'un schema
  */
 public function save()
 {
     $selectionSchidsch = $this->input->post('selectionSchidsch');
     $rdgidrdg = $this->input->post('rdgidrdg');
     $prjidprj = $this->input->post('prjidprj');
     $rdg = RdG_model::getRdG($this->db, $rdgidrdg);
     // Affectation des schemas en remplacement des anciens schémas
     $rdg->setSchemasIds($this->db, $selectionSchidsch);
     $this->session->set_flashdata('message', formatInfo('Modification enregistrée'));
     // Recharge la page avec les nouvelles infos
     if ($prjidprj != null && $prjidprj != '') {
         redirect('editrdg/index/' . $rdgidrdg . '/' . $prjidprj);
     } else {
         redirect('editrdg/index/' . $rdgidrdg);
     }
 }