Browse Source

Annual PLans bug

parent
commit
7fb59795f5

+ 7
- 2
app/controllers/AnnualPlansController.php View File

150
     //Dame los annual plans que esten dentro del three year plan
150
     //Dame los annual plans que esten dentro del three year plan
151
 
151
 
152
 
152
 
153
-    $annual_plans = DB::select("
153
+    $annual_plans = DB::table('annual_cycle')
154
+      ->join('annual_plans', 'annual_cycle_id', '=', 'annual_cycle.id')
155
+      ->where('program_id', $program_id)
156
+      ->orderBy('semester_start')
157
+      ->get();
158
+    /*$annual_plans = DB::select("
154
     
159
     
155
     select 
160
     select 
156
       academic_year, 
161
       academic_year, 
173
         join typ_program on typ_semester_outcome.typ_program_id = typ_program.id 
178
         join typ_program on typ_semester_outcome.typ_program_id = typ_program.id 
174
         where program_id = {$program_id} )
179
         where program_id = {$program_id} )
175
       )
180
       )
176
-      order by semester_start desc");
181
+      order by semester_start desc");*/
177
     // $annual_plans = DB::select("select academic_year, semester_start, semester_end, program_id, annual_plans.id as id from annual_plans, annual_cycle where program_id = {$program_id} and annual_cycle.id = annual_plans.annual_cycle_id order by annual_plans.id desc ");
182
     // $annual_plans = DB::select("select academic_year, semester_start, semester_end, program_id, annual_plans.id as id from annual_plans, annual_cycle where program_id = {$program_id} and annual_cycle.id = annual_plans.annual_cycle_id order by annual_plans.id desc ");
178
     // Log::info($annual_plans);
183
     // Log::info($annual_plans);
179
     $outcomes = array();
184
     $outcomes = array();

+ 2
- 1
app/controllers/CoursesController.php View File

46
             $active_semesters[] = $active_semester->id;
46
             $active_semesters[] = $active_semester->id;
47
         }
47
         }
48
 
48
 
49
+
49
         return View::make('local.professors.course', compact('title', 'course', 'activities', 'students', 'outcomes', 'outcomes_achieved', 'outcomes_attempted', 'active_semesters'));
50
         return View::make('local.professors.course', compact('title', 'course', 'activities', 'students', 'outcomes', 'outcomes_achieved', 'outcomes_attempted', 'active_semesters'));
50
     }
51
     }
51
 
52
 
506
         } else {
507
         } else {
507
         }
508
         }
508
     }
509
     }
509
-}
510
+}

+ 2
- 2
app/views/local/professors/course.blade.php View File

142
                   <div class="modal-body">
142
                   <div class="modal-body">
143
                                            
143
                                            
144
           
144
           
145
-                          <p>Vas a seleccionar dos actividades para comparar y presentar los datos de las actividades</p>
145
+                          <p></p>
146
                           
146
                           
147
-                          <h5>Escoge dos actividades para comparar <br></h5>
147
+                          <h5>Select two activities to compare and present their data. <br></h5>
148
           
148
           
149
                           <div class="form-group">
149
                           <div class="form-group">
150
           
150