소스 검색

para cambiar de branch

para Oniel poder cambiar de branch, necesita commit y merge estos files
onielm 3 년 전
부모
커밋
459ece87af
4개의 변경된 파일281개의 추가작업 그리고 159개의 파일을 삭제
  1. 2
    2
      app/config/app.php
  2. 11
    0
      app/controllers/CriteriaController.php
  3. 224
    155
      app/controllers/OutcomesController.php
  4. 44
    2
      app/routes.php

+ 2
- 2
app/config/app.php 파일 보기

@@ -27,7 +27,7 @@ return array(
27 27
 	|
28 28
 	*/ //$_ENV['APP_URL'] ?:
29 29
 
30
-	'url' =>  'https://localhost',
30
+	'url' =>  'http://localhost',
31 31
 
32 32
 	/*
33 33
 	|--------------------------------------------------------------------------
@@ -125,7 +125,7 @@ return array(
125 125
 		'Illuminate\Workbench\WorkbenchServiceProvider',
126 126
 		'Way\Generators\GeneratorsServiceProvider',
127 127
 		'Barryvdh\DomPDF\ServiceProvider',
128
-		//'Cornford\Backup\Providers\BackupServiceProvider',
128
+		// 'Cornford\Backup\Providers\BackupServiceProvider',
129 129
 		'Zizaco\Entrust\EntrustServiceProvider'
130 130
 
131 131
 	),

+ 11
- 0
app/controllers/CriteriaController.php 파일 보기

@@ -572,13 +572,24 @@ class CriteriaController extends \BaseController
572 572
 
573 573
         $title = "Learning Outcomes and Criteria";
574 574
         $outcomes = Outcome::orderBy('name', 'ASC')->get();
575
+        // $outcomes = DB::table('outcomes')
576
+        //     ->orderBy('name', 'asc')
577
+        //     ->get();
575 578
         $schools = School::orderBy('name', 'ASC')->get();
579
+        // $schools = DB::table('schools')
580
+        //     ->orderBy('name', 'asc')
581
+        //     ->get();
576 582
         $criteria = Criterion::withTrashed()->orderBy('name', 'ASC')->get();
583
+        // $criteria = DB::table('criteria')
584
+        //     ->orderBy('name', 'asc')
585
+        //     ->get();
577 586
 
578 587
         // se annadio la nueva variable
579 588
         return View::make('global.view-learning-outcomes-criteria', compact('title', 'outcomes', 'schools', 'criteria', 'semesters'));
589
+
580 590
     }
581 591
 
592
+
582 593
     // copie index() y lo edite
583 594
     public function objectivesIndex()
584 595
     {

+ 224
- 155
app/controllers/OutcomesController.php 파일 보기

@@ -43,164 +43,169 @@ class OutcomesController extends \BaseController
43 43
         $undergradResults = array("names" => array(), "schools" => array(), "achieved" => array(), "attempted" => array(), "successRate" => array());
44 44
         $gradResults = array("names" => array(), "schools" => array(), "achieved" => array(), "attempted" => array(), "successRate" => array());
45 45
         foreach ($programs as $program_id) {
46
-            //        	var_dump($program_id);
47
-            //         	exit();
48
-            $program = Program::where('id', '=', $program_id->id)->first();
49
-            $school = School::where('id', '=', $program->school_id)->first();
50
-            if ($program->is_graduate) {
51
-                $gradResults['names'][] = $program->name;
52
-                $gradResults['schools'][] = $school->name;
53
-                $attempted = $program->attempted_criteria_by_outcome($id, $selected_semesters);
54
-                $gradResults['attempted'][] = $attempted;
55
-                $achieved = $program->achieved_criteria_by_outcome($id, $selected_semesters);
56
-                $gradResults['achieved'][] = $achieved;
57
-                $gradResults['successRate'][] = sprintf("%.2f", 100 * $achieved / $attempted);
58
-            } else {
59
-                $undergradResults['names'][] = $program->name;
60
-                $undergradResults['schools'][] = $school->name;
61
-                $attempted = $program->attempted_criteria_by_outcome($id, $selected_semesters);
62
-                $undergradResults['attempted'][] = $attempted;
63
-                $achieved = $program->achieved_criteria_by_outcome($id, $selected_semesters);
64
-                $undergradResults['achieved'][] = $achieved;
65
-                $undergradResults['successRate'][] = sprintf("%.2f", 100 * $achieved / $attempted);
66
-            }
46
+ //        	var_dump($program_id);
47
+//         	exit();
48
+        	$program = Program::where('id', '=', $program_id->id)->first();
49
+        	$school = School::where('id', '=', $program->school_id)->first();
50
+        	if($program->is_graduate)
51
+        	{
52
+        		$gradResults['names'][] = $program->name;
53
+        		$gradResults['schools'][] = $school->name;
54
+        		$attempted = $program->attempted_criteria_by_outcome($id, $selected_semesters);
55
+        		$gradResults['attempted'][] = $attempted;
56
+        		$achieved = $program->achieved_criteria_by_outcome($id, $selected_semesters);
57
+        		$gradResults['achieved'][] = $achieved;
58
+        		$gradResults['successRate'][] = sprintf("%.2f",100*$achieved/$attempted);
59
+
60
+        	}
61
+        	else
62
+        	{
63
+        		$undergradResults['names'][] = $program->name;
64
+        		$undergradResults['schools'][] = $school->name;
65
+        		$attempted = $program->attempted_criteria_by_outcome($id,$selected_semesters);
66
+        		$undergradResults['attempted'][] = $attempted;
67
+        		$achieved = $program->achieved_criteria_by_outcome($id,$selected_semesters);
68
+        		$undergradResults['achieved'][] = $achieved;
69
+        		$undergradResults['successRate'][] = sprintf("%.2f",100*$achieved/$attempted);
70
+        	}
71
+
67 72
         }
68 73
 
69
-        $title = "Outcome Results: " . $outcome->name;
74
+	   	$title = "Outcome Results: ".$outcome->name;
70 75
 
71 76
 
72
-        //  		$undergradResults["successRate"]
77
+//  		$undergradResults["successRate"]
73 78
 
74 79
         return View::make('local.managers.admins.learning-outcome_new', compact('title', 'outcome', 'undergradResults', 'gradResults'));
75 80
     }
76 81
 
77
-    //     public function show($id)
78
-    //     {
79
-    //         DB::disableQueryLog();
80
-    //         $outcome = Outcome::find($id);
81
-    // 
82
-    //         $undergradResults=array("names"=>array(), "schools"=>array(), "achieved"=>array(), "attempted"=>array(), "successRate"=>array());
83
-    //         $gradResults = array("names"=>array(), "schools"=>array(), "achieved"=>array(), "attempted"=>array(), "successRate"=>array());
84
-    // 
85
-    //         //Calculate performance for this outcome for each undergrad program
86
-    //         $undergradPrograms = Program::where('is_graduate','=', 0)
87
-    //             ->where(function($query)
88
-    //             {
89
-    //                 if(Auth::user()->school_id)
90
-    //                 {
91
-    //                     $query->where('school_id', Auth::user()->school_id);
92
-    //                 }
93
-    //             })
94
-    //             ->with('courses')
95
-    //             ->orderBy('name', 'asc')->get();
96
-    // 
97
-    //         foreach($undergradPrograms as $program)
98
-    //         {
99
-    //             $undergradResults["names"][$program->id]=$program->name;
100
-    //             $undergradResults["schools"][$program->id]=$program->school->name;
101
-    //             $programAssessed=false;
102
-    // 
103
-    //             $undergradResults["attempted"][$program->id]=0;
104
-    //             $undergradResults["achieved"][$program->id]=0;
105
-    // 
106
-    //             foreach($program->courses as $course)
107
-    //             {
108
-    //                 $course_outcomes_achieved = json_decode($course->outcomes_achieved, true);
109
-    //                 $course_outcomes_attempted = json_decode($course->outcomes_attempted, true);
110
-    // 
111
-    //                 $attemptedCriteriaCount=0;
112
-    //                 $achievedCriteriaCount=0;
113
-    // 
114
-    //                 // If this outcome was evaluated
115
-    //                 if(
116
-    //                     $course_outcomes_attempted
117
-    //                     && array_key_exists($outcome->id, $course_outcomes_attempted)
118
-    //                     && $course_outcomes_attempted[$outcome->id]!=0)
119
-    //                 {
120
-    //                     // Count +1 for attempted and achieved in the program
121
-    //                     $attemptedCriteriaCount+=$course_outcomes_attempted[$outcome->id];
122
-    //                     $achievedCriteriaCount+=$course_outcomes_achieved[$outcome->id];
123
-    //                     $programAssessed=true;
124
-    // 
125
-    //                     if($attemptedCriteriaCount>0  &&(float)$achievedCriteriaCount/$attemptedCriteriaCount*100 > $outcome->expected_outcome)
126
-    //                     {
127
-    //                         $undergradResults["achieved"][$program->id]+=1;
128
-    //                     }
129
-    //                     $undergradResults["attempted"][$program->id]+=1;
130
-    //                 }
131
-    //             }
132
-    // 
133
-    //             // Calculate success rate for this program
134
-    //             if($programAssessed && $undergradResults["attempted"][$program->id]>0)
135
-    //                 $undergradResults["successRate"][$program->id]= round((float)$undergradResults["achieved"][$program->id]/$undergradResults["attempted"][$program->id]*100, 2).'%';
136
-    //             else
137
-    //                 $undergradResults["successRate"][$program->id]= 'N/M';
138
-    //         }
139
-    // 
140
-    // 
141
-    //         //Calculate performance for this outcome for each grad program
142
-    //         $gradPrograms = Program::where('is_graduate','=', 1)
143
-    //             ->where(function($query)
144
-    //             {
145
-    //                 if(Auth::user()->school_id)
146
-    //                 {
147
-    //                     $query->where('school_id', Auth::user()->school_id);
148
-    //                 }
149
-    //             })
150
-    //             ->with(array('courses'=>function($query)
151
-    //             {
152
-    //                 $query->whereNotNull('outcomes_attempted');
153
-    //             }))
154
-    //             ->orderBy('name', 'asc')->get();
155
-    // 
156
-    //         foreach($gradPrograms as $program)
157
-    //         {
158
-    //             $gradResults["names"][$program->id]=$program->name;
159
-    //             $gradResults["schools"][$program->id]=$program->school->name;
160
-    // 
161
-    //             $programAssessed=false;
162
-    // 
163
-    //             $gradResults["attempted"][$program->id]=0;
164
-    //             $gradResults["achieved"][$program->id]=0;
165
-    // 
166
-    //             foreach($program->courses as $course)
167
-    //             {
168
-    //                 $course_outcomes_achieved = json_decode($course->outcomes_achieved, true);
169
-    //                 $course_outcomes_attempted = json_decode($course->outcomes_attempted, true);
170
-    // 
171
-    //                 $attemptedCriteriaCount=0;
172
-    //                 $achievedCriteriaCount=0;
173
-    // 
174
-    //                 // If this outcome was evaluated
175
-    //                 if(
176
-    //                     $course_outcomes_attempted
177
-    //                     && array_key_exists($outcome->id, $course_outcomes_attempted)
178
-    //                     && $course_outcomes_attempted[$outcome->id]!=0)
179
-    //                 {
180
-    //                     // Count +1 for attempted and achieved in the program
181
-    //                     $attemptedCriteriaCount+=$course_outcomes_attempted[$outcome->id];
182
-    //                     $achievedCriteriaCount+=$course_outcomes_achieved[$outcome->id];
183
-    //                     $programAssessed=true;
184
-    // 
185
-    //                     if($attemptedCriteriaCount>0  &&(float)$achievedCriteriaCount/$attemptedCriteriaCount*100 > $outcome->expected_outcome)
186
-    //                     {
187
-    //                         $gradResults["achieved"][$program->id]+=1;
188
-    //                     }
189
-    //                     $gradResults["attempted"][$program->id]+=1;
190
-    //                 }
191
-    //             }
192
-    // 
193
-    //             // Calculate success rate for this program
194
-    //             if($programAssessed && $gradResults["attempted"][$program->id]>0)
195
-    //                 $gradResults["successRate"][$program->id]= round((float)$gradResults["achieved"][$program->id]/$gradResults["attempted"][$program->id]*100, 2).'%';
196
-    //             else
197
-    //                 $gradResults["successRate"][$program->id]= 'N/M';
198
-    //         }
199
-    // 
200
-    //         $title = "Outcome Results: ".$outcome->name;
201
-    // 
202
-    //         return View::make('local.managers.admins.learning-outcome', compact('title', 'outcome', 'undergradResults', 'gradResults'));
203
-    //     }
82
+//     public function show($id)
83
+//     {
84
+//         DB::disableQueryLog();
85
+//         $outcome = Outcome::find($id);
86
+//
87
+//         $undergradResults=array("names"=>array(), "schools"=>array(), "achieved"=>array(), "attempted"=>array(), "successRate"=>array());
88
+//         $gradResults = array("names"=>array(), "schools"=>array(), "achieved"=>array(), "attempted"=>array(), "successRate"=>array());
89
+//
90
+//         //Calculate performance for this outcome for each undergrad program
91
+//         $undergradPrograms = Program::where('is_graduate','=', 0)
92
+//             ->where(function($query)
93
+//             {
94
+//                 if(Auth::user()->school_id)
95
+//                 {
96
+//                     $query->where('school_id', Auth::user()->school_id);
97
+//                 }
98
+//             })
99
+//             ->with('courses')
100
+//             ->orderBy('name', 'asc')->get();
101
+//
102
+//         foreach($undergradPrograms as $program)
103
+//         {
104
+//             $undergradResults["names"][$program->id]=$program->name;
105
+//             $undergradResults["schools"][$program->id]=$program->school->name;
106
+//             $programAssessed=false;
107
+//
108
+//             $undergradResults["attempted"][$program->id]=0;
109
+//             $undergradResults["achieved"][$program->id]=0;
110
+//
111
+//             foreach($program->courses as $course)
112
+//             {
113
+//                 $course_outcomes_achieved = json_decode($course->outcomes_achieved, true);
114
+//                 $course_outcomes_attempted = json_decode($course->outcomes_attempted, true);
115
+//
116
+//                 $attemptedCriteriaCount=0;
117
+//                 $achievedCriteriaCount=0;
118
+//
119
+//                 // If this outcome was evaluated
120
+//                 if(
121
+//                     $course_outcomes_attempted
122
+//                     && array_key_exists($outcome->id, $course_outcomes_attempted)
123
+//                     && $course_outcomes_attempted[$outcome->id]!=0)
124
+//                 {
125
+//                     // Count +1 for attempted and achieved in the program
126
+//                     $attemptedCriteriaCount+=$course_outcomes_attempted[$outcome->id];
127
+//                     $achievedCriteriaCount+=$course_outcomes_achieved[$outcome->id];
128
+//                     $programAssessed=true;
129
+//
130
+//                     if($attemptedCriteriaCount>0  &&(float)$achievedCriteriaCount/$attemptedCriteriaCount*100 > $outcome->expected_outcome)
131
+//                     {
132
+//                         $undergradResults["achieved"][$program->id]+=1;
133
+//                     }
134
+//                     $undergradResults["attempted"][$program->id]+=1;
135
+//                 }
136
+//             }
137
+//
138
+//             // Calculate success rate for this program
139
+//             if($programAssessed && $undergradResults["attempted"][$program->id]>0)
140
+//                 $undergradResults["successRate"][$program->id]= round((float)$undergradResults["achieved"][$program->id]/$undergradResults["attempted"][$program->id]*100, 2).'%';
141
+//             else
142
+//                 $undergradResults["successRate"][$program->id]= 'N/M';
143
+//         }
144
+//
145
+//
146
+//         //Calculate performance for this outcome for each grad program
147
+//         $gradPrograms = Program::where('is_graduate','=', 1)
148
+//             ->where(function($query)
149
+//             {
150
+//                 if(Auth::user()->school_id)
151
+//                 {
152
+//                     $query->where('school_id', Auth::user()->school_id);
153
+//                 }
154
+//             })
155
+//             ->with(array('courses'=>function($query)
156
+//             {
157
+//                 $query->whereNotNull('outcomes_attempted');
158
+//             }))
159
+//             ->orderBy('name', 'asc')->get();
160
+//
161
+//         foreach($gradPrograms as $program)
162
+//         {
163
+//             $gradResults["names"][$program->id]=$program->name;
164
+//             $gradResults["schools"][$program->id]=$program->school->name;
165
+//
166
+//             $programAssessed=false;
167
+//
168
+//             $gradResults["attempted"][$program->id]=0;
169
+//             $gradResults["achieved"][$program->id]=0;
170
+//
171
+//             foreach($program->courses as $course)
172
+//             {
173
+//                 $course_outcomes_achieved = json_decode($course->outcomes_achieved, true);
174
+//                 $course_outcomes_attempted = json_decode($course->outcomes_attempted, true);
175
+//
176
+//                 $attemptedCriteriaCount=0;
177
+//                 $achievedCriteriaCount=0;
178
+//
179
+//                 // If this outcome was evaluated
180
+//                 if(
181
+//                     $course_outcomes_attempted
182
+//                     && array_key_exists($outcome->id, $course_outcomes_attempted)
183
+//                     && $course_outcomes_attempted[$outcome->id]!=0)
184
+//                 {
185
+//                     // Count +1 for attempted and achieved in the program
186
+//                     $attemptedCriteriaCount+=$course_outcomes_attempted[$outcome->id];
187
+//                     $achievedCriteriaCount+=$course_outcomes_achieved[$outcome->id];
188
+//                     $programAssessed=true;
189
+//
190
+//                     if($attemptedCriteriaCount>0  &&(float)$achievedCriteriaCount/$attemptedCriteriaCount*100 > $outcome->expected_outcome)
191
+//                     {
192
+//                         $gradResults["achieved"][$program->id]+=1;
193
+//                     }
194
+//                     $gradResults["attempted"][$program->id]+=1;
195
+//                 }
196
+//             }
197
+//
198
+//             // Calculate success rate for this program
199
+//             if($programAssessed && $gradResults["attempted"][$program->id]>0)
200
+//                 $gradResults["successRate"][$program->id]= round((float)$gradResults["achieved"][$program->id]/$gradResults["attempted"][$program->id]*100, 2).'%';
201
+//             else
202
+//                 $gradResults["successRate"][$program->id]= 'N/M';
203
+//         }
204
+//
205
+//         $title = "Outcome Results: ".$outcome->name;
206
+//
207
+//         return View::make('local.managers.admins.learning-outcome', compact('title', 'outcome', 'undergradResults', 'gradResults'));
208
+//     }
204 209
 
205 210
     // TODO: Clean up and verify relationships are correct
206 211
     public function newShow($id)
@@ -513,14 +518,78 @@ class OutcomesController extends \BaseController
513 518
 
514 519
     public function fetchOutcome()
515 520
     {
516
-        $id = Input::get('id');
521
+        // original code using models
522
+        // TODO: models have to be updated because of the database update
517 523
 
518
-        $outcome = Outcome::find($id);
524
+        $id = Input::get('id');
519 525
 
520
-        $outcome->criteria;
526
+        $outcome_info = DB::table('outcomes')
527
+            ->where('outcomes.id', $id)
528
+            ->get();
529
+        $outcome = $outcome_info[0];
530
+
531
+        $diferent_levels = DB::table('criterion_objective_outcome')
532
+            ->join('new_criteria', 'new_criteria.id', '=', 'criterion_objective_outcome.criterion_id')
533
+            ->join('objectives', 'objectives.id', '=', 'criterion_objective_outcome.objective_id')
534
+            ->where('criterion_objective_outcome.outcome_id', $id)
535
+            ->distinct('new_criteria.number_of_scales')
536
+            ->select('new_criteria.number_of_scales as levels')
537
+            ->orderBy('new_criteria.number_of_scales', 'asc')
538
+            ->get();
521 539
 
522
-        return array(
523
-            'outcome' => $outcome
540
+        $criteria_array = array();
541
+
542
+        $outcome->criteria = array();
543
+        foreach ($diferent_levels as $level) {
544
+          $level = $level->levels;
545
+
546
+          // buscar todos los criterios con el level y ponerlos en un array
547
+          $outcome_criterias = DB::table('criterion_objective_outcome')
548
+              ->join('new_criteria', 'new_criteria.id', '=', 'criterion_objective_outcome.criterion_id')
549
+              ->join('objectives', 'objectives.id', '=', 'criterion_objective_outcome.objective_id')
550
+              ->where('criterion_objective_outcome.outcome_id', $id)
551
+              ->where('new_criteria.number_of_scales', $level)
552
+              ->whereNull('new_criteria.deleted_at')
553
+              ->select('new_criteria.id','new_criteria.name')
554
+              ->orderBy('new_criteria.name', 'asc')
555
+              ->get();
556
+          $outcome_criterias = $outcome_criterias;
557
+
558
+          foreach ($outcome_criterias as $criteria_id) {
559
+
560
+            $scales =
561
+              DB::select(
562
+                  DB::raw("
563
+                  SELECT *
564
+                  FROM (
565
+                    SELECT new_criteria.id as criterion_id,
566
+                      ROW_NUMBER() OVER(PARTITION BY scales.id) rn,
567
+                      scales.position,
568
+                      scales.title, scales.description,
569
+                      criterion_objective_outcome.outcome_id,criterion_objective_outcome.objective_id,
570
+                      criterion_scale.scale_id
571
+                    FROM new_criteria,criterion_scale,scales, criterion_objective_outcome, objectives
572
+                    where new_criteria.id=criterion_scale.criterion_id
573
+                      and scales.id = criterion_scale.scale_id
574
+                      and new_criteria.id = criterion_objective_outcome.criterion_id
575
+                      and objectives.id = criterion_objective_outcome.objective_id
576
+                      and criterion_objective_outcome.outcome_id = $id
577
+                      and new_criteria.id = $criteria_id->id
578
+                    ORDER BY new_criteria.name ASC) a
579
+                  WHERE rn = 1
580
+                  ORDER BY `a`.`position` ASC
581
+                      ")
582
+              );
583
+              // insertar la informacion de los criterios con N niveles en el arreglo de arreglos
584
+              $criteria_id->scales = $scales;
585
+              // $i++;
586
+            }//ends foreach criteria_id
587
+            array_push($outcome->criteria, array($outcome_criterias,'amount_of_levels'=>$level));
588
+        }//ends foreach level
589
+
590
+        return array
591
+        (
592
+            'outcome' => $outcome,
524 593
         );
525 594
     }
526 595
 

+ 44
- 2
app/routes.php 파일 보기

@@ -53,7 +53,8 @@ View::composer(array(
53 53
     'local.managers.shared.program',
54 54
     'local.managers.shared.rubrics',
55 55
     'global.view-learning-outcomes-criteria',
56
-    'global.view-learning-outcomes-criteria'
56
+    'global.view-learning-outcomes-criteria',
57
+    'global.view-three-year-plan'
57 58
 ), function ($view) {
58 59
     $view->with('role', Auth::user()->role);
59 60
 });
@@ -186,6 +187,10 @@ Route::group(array('before' => 'auth|has_access'), function () {
186 187
         'as' => 'delete',
187 188
         'uses' => 'CriteriaController@delete'
188 189
     ));
190
+    Route::post('delete', array(
191
+        'as' => 'delete',
192
+        'uses' => 'TransformativeActionsController@deleteTA'
193
+    ));
189 194
     // Fetch a criterion for a rubric
190 195
     Route::post('fetchCriterionWithTrashed', array(
191 196
         'as' => 'fetchCriterionWithTrashed',
@@ -238,6 +243,14 @@ Route::group(array('before' => 'auth|has_access'), function () {
238 243
     Route::get('my-assessment-reports', 'OutcomesController@professorAssessmentReports');
239 244
     Route::post('objectives/fetch', array('before' => 'csrf', 'uses' => 'ObjectivesController@fetch'));
240 245
 
246
+    // Transformative Actions for p-coordinators and professors
247
+    Route::get('transformativeAction', array('uses' => 'TransformativeActionsController@editTA'));
248
+    Route::post('transformativeAction/createTA', array('before' => 'csrf', 'uses' => 'TransformativeActionsController@createTA'));
249
+    Route::post('transformativeAction/selectTA', array('before' => 'csrf', 'uses' => 'TransformativeActionsController@selectTA'));
250
+    Route::post('transformativeAction/updateTA', array('before' => 'csrf', 'uses'=>'TransformativeActionsController@updateTA'));
251
+    Route::post('transformativeAction/filterTA', array('before' => 'csrf', 'uses'=>'TransformativeActionsController@filterTA'));
252
+    Route::post('transformativeAction/objectivesFromOutcome', array('before' => 'csrf', 'uses'=>'TransformativeActionsController@objectivesFromOutcome'));
253
+
241 254
     /**
242 255
      * Administrator Routes
243 256
      */
@@ -258,7 +271,6 @@ Route::group(array('before' => 'auth|has_access'), function () {
258 271
 
259 272
         Route::post('learning-outcomes/update', array('before' => 'csrf', 'uses' => 'OutcomesController@updateMore'));
260 273
         Route::post('learning-outcomes/update', array('before' => 'csrf', 'uses' => 'OutcomesController@update'));
261
-        Route::post('learning-outcomes/update', array('before' => 'csrf', 'uses' => 'OutcomesController@updateMore'));
262 274
         Route::post('crtiteria/update', array('before' => 'csrf', 'uses' => 'CriteriaController@update'));
263 275
         Route::delete('crtiteria/delete', array('before' => 'csrf', 'uses' => 'CriteriaController@destroy'));
264 276
 
@@ -295,6 +307,7 @@ Route::group(array('before' => 'auth|has_access'), function () {
295 307
         Route::get('school/{id}', 'SchoolsController@show');
296 308
         Route::get('program/{id}', 'ProgramsController@show');
297 309
         Route::post('programs/report', 'ProgramsController@showReport');
310
+        // Route::post('storeTypInfo', 'OutcomesController@storeCycleInfo'); //TODO: where is this route supposed to be placed?
298 311
         Route::get('programs', 'ProgramsController@index');
299 312
         Route::get('template-list', 'TemplatesController@schoolCoordinatorIndex');
300 313
         Route::post('deleteObjective', 'Objective2Controller@delete');
@@ -307,6 +320,19 @@ Route::group(array('before' => 'auth|has_access'), function () {
307 320
         // Gabriel added this, so the school coordinator can add criterias and objectives
308 321
         Route::get('school-objective', 'Objective2Controller@editSchool');
309 322
         Route::get('school-criteria', 'CriteriaController@editSchool');
323
+
324
+        // Show users plan de tres a~nos
325
+        Route::get('three-years-plan', 'ThreeYearPlanController@threeYearsReport');
326
+        Route::post('fetchThreeYears', array('before' => 'csrf', 'uses'=>'ThreeYearPlanController@fetchThreeYears'));
327
+        Route::post('typ/lookUp', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@lookup_typ_semester_outcome'));
328
+        Route::post('section2_arrive', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section2_arrive'));
329
+        Route::post('section2_on_change', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section2_on_change'));
330
+        Route::post('section3_arrive', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section3_arrive'));
331
+        Route::post('section3_on_change', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section3_on_change'));
332
+        Route::post('typ/getObjectives', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@getObjectivesForTYP'));
333
+        Route::post('typ/updateOutcomeSemsters', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@typ_update_outcomes_semesters'));
334
+        Route::post('typ/update', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@update_typ_outcomes_semesters'));
335
+
310 336
     });
311 337
 
312 338
 
@@ -379,6 +405,22 @@ Route::group(array('before' => 'auth|has_access'), function () {
379 405
         Route::get('new-report/{id}', 'OutcomesController@newReport');
380 406
         Route::get('new-report-all', 'OutcomesController@newReportAll');
381 407
         Route::get('courses/{id}', 'CoursesController@newShow');
408
+
409
+        // Transformative Actions
410
+        Route::post('transformativeAction/approveTA', array('before' => 'csrf', 'uses'=>'TransformativeActionsController@approveTA'));
411
+
412
+        // Show users plan de tres a~nos
413
+        Route::get('three-years-plan', 'ThreeYearPlanController@threeYearsReport');
414
+        Route::post('fetchThreeYears', array('before' => 'csrf', 'uses'=>'ThreeYearPlanController@fetchThreeYears'));
415
+        Route::post('typ/lookUp', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@lookup_typ_semester_outcome'));
416
+        Route::post('section2_arrive', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section2_arrive'));
417
+        Route::post('section2_on_change', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section2_on_change'));
418
+        Route::post('section3_arrive', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section3_arrive'));
419
+        Route::post('section3_on_change', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@section3_on_change'));
420
+        Route::post('typ/getObjectives', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@getObjectivesForTYP'));
421
+        Route::post('typ/updateOutcomeSemsters', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@typ_update_outcomes_semesters'));
422
+        Route::post('typ/update', array('before' => 'csrf', 'uses' => 'ThreeYearPlanController@update_typ_outcomes_semesters'));
423
+
382 424
     });
383 425
 
384 426