Skip to content
Snippets Groups Projects
Commit 8222d61a authored by xamgore's avatar xamgore
Browse files

Model_Teacher_Map moved to models folder

parent 9a79a290
Branches
Tags
No related merge requests found
......@@ -11,7 +11,7 @@ class Controller_DeanOffice_Index extends Controller_UserEnvi {
public function action_index()
{
$twig = Twig::factory('dean_office/index');
$model = new Model_Teacher_Map;
$model = new Model_Map;
$twig->GradesList = Model_Grades::toArray();
......
......@@ -23,7 +23,7 @@ class Controller_Handler_FileCreator extends Controller_Handler
// Шапка таблицы: структура УКД (модули и мероприятия)
$structure = Model_Teacher_Map::getMapForDiscipline($this->post->offsetGet('disciplineID'));
$structure = Model_Map::getMapForDiscipline($this->post->offsetGet('disciplineID'));
$structureHandled = array();
$maxRate = 0; $i = 0; $module = 0;
......
......@@ -2,11 +2,11 @@
class Controller_Handler_Map extends Controller_Handler {
/** @var Model_Teacher_Map */
/** @var Model_Map */
protected $model;
public function before() {
$this->model = new Model_Teacher_Map;
$this->model = new Model_Map;
$this->setAccessLevel(self::ACCESS_USER);
parent::before();
}
......
......@@ -5,7 +5,7 @@ class Controller_Teacher_Discipline extends Controller_UserEnvi {
public function action_CreateDiscipline()
{
$twig = Twig::factory('teacher/discipline/CreateDiscipline');
$db = new Model_Teacher_Map;
$db = new Model_Map;
$twig->User = $this->UserInfo;
$twig->FacultiesList = Model_Faculties::toArray();
$twig->SubjectsList = Model_Subjects::byFaculty($this->UserInfo['FacultyID']);
......@@ -17,7 +17,7 @@ class Controller_Teacher_Discipline extends Controller_UserEnvi {
public function action_EditSettings()
{
$id = $this->request->param('id');
$db = new Model_Teacher_Map;
$db = new Model_Map;
$twig = Twig::factory('teacher/discipline/EditSettings');
$twig->User = $this->UserInfo;
......@@ -31,7 +31,7 @@ class Controller_Teacher_Discipline extends Controller_UserEnvi {
public function action_EditStructure()
{
$id = $this->request->param('id');
$db = new Model_Teacher_Map;
$db = new Model_Map;
$twig = Twig::factory('teacher/discipline/EditStructure');
$twig->User = $this->UserInfo;
......@@ -44,7 +44,7 @@ class Controller_Teacher_Discipline extends Controller_UserEnvi {
public function action_EditGroups()
{
$id = $this->request->param('id');
$db = new Model_Teacher_Map;
$db = new Model_Map;
$twig = Twig::factory('teacher/discipline/EditGroups');
$twig->User = $this->UserInfo;
......@@ -59,7 +59,7 @@ class Controller_Teacher_Discipline extends Controller_UserEnvi {
public function action_EditStudents()
{
$id = $this->request->param('id');
$db = new Model_Teacher_Map;
$db = new Model_Map;
$twig = Twig::factory('teacher/discipline/EditStudents');
$twig->User = $this->UserInfo;
......@@ -137,7 +137,7 @@ class Controller_Teacher_Discipline extends Controller_UserEnvi {
public function action_EditTeachers()
{
$id = $this->request->param('id');
$db = new Model_Teacher_Map;
$db = new Model_Map;
$twig = Twig::factory('teacher/discipline/EditTeachers');
$twig->User = $this->UserInfo;
......
......@@ -4,14 +4,14 @@ class Controller_Teacher_Rating extends Controller_UserEnvi {
/** @var Model_Rating */
protected $model_rating;
/** @var Model_Teacher_Map */
/** @var Model_Map */
protected $model_discipline;
public function before() {
Cookie::set('fD', 'true'); // Ставим кук fD, чтоб иметь возможность скачать отчет TODO
$this->model_rating = new Model_Rating;
$this->model_discipline = new Model_Teacher_Map;
$this->model_discipline = new Model_Map;
parent::before();
}
......
<?php defined('SYSPATH') or die('No direct script access.');
class Model_Teacher_Map extends Model
class Model_Map extends Model
{
public static function addModuleBonus($teacherID, $disciplineID)
{
......
......@@ -50,7 +50,7 @@ class Kohana_Account {
/**
* Вовзращает экземпляр класса (singleton-паттерн)
*
* @return instance
* @return self
*/
public static function instance() {
if(!isset(self::$_instance))
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment