Guest User

Untitled

a guest
Jan 24th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. public function curso($id)
  2. {
  3.  
  4. $this->loadModel('ProgramaDisciplinaCurso');
  5. $this->set('id', $id);
  6. if (!empty($this->data)) {
  7.  
  8.  
  9. $this->ProgramaDisciplinaCurso->set(array(
  10. 'curso' => $this->data['ProgramaDisciplinaCurso']['curso'],
  11. 'programa' => $id
  12. ));
  13. if ($this->ProgramaDisciplinaCurso->save()) {
  14. $this->redirect(array('action' => 'index'));
  15. }
  16.  
  17. if ($this->canceled()) {
  18. $this->redirect('/reitoria/programa_disciplina/');
  19. }
  20. }
  21. }
Add Comment
Please, Sign In to add comment