From 5af788d37ba2da0da9707ab8c7f5d43ea7126bab Mon Sep 17 00:00:00 2001 From: maxim Date: Mon, 13 Sep 2021 12:19:25 +0300 Subject: [PATCH 1/2] =?UTF-8?q?=D1=83=D0=B1=D1=80=D0=B0=D0=BB=20=D0=BB?= =?UTF-8?q?=D0=B8=D1=88=D0=BD=D0=B5=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/modules/calendar/controllers/CalendarController.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/backend/modules/calendar/controllers/CalendarController.php b/backend/modules/calendar/controllers/CalendarController.php index 78ed1ec..352efac 100644 --- a/backend/modules/calendar/controllers/CalendarController.php +++ b/backend/modules/calendar/controllers/CalendarController.php @@ -43,8 +43,6 @@ class CalendarController extends Controller * @return string */ public function actionCalendar(){ - $searchModel = new UserCardSearch(); - $dataProvider = $searchModel->search(['month'=>date('m', strtotime('2019-07-03'))]); return $this->render('calendar'); } From 73e331bbc6cce51fe2a146832f9761ed8b7bb343 Mon Sep 17 00:00:00 2001 From: maxim Date: Mon, 13 Sep 2021 12:23:44 +0300 Subject: [PATCH 2/2] =?UTF-8?q?=D1=83=D0=B4=D0=B0=D0=BB=D0=B8=D0=BB=20?= =?UTF-8?q?=D0=BB=D0=B8=D1=88=D0=BD=D0=B5=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../calendar/views/calendar/alternative.php | 80 ------------------- 1 file changed, 80 deletions(-) delete mode 100644 backend/modules/calendar/views/calendar/alternative.php diff --git a/backend/modules/calendar/views/calendar/alternative.php b/backend/modules/calendar/views/calendar/alternative.php deleted file mode 100644 index 4b20d21..0000000 --- a/backend/modules/calendar/views/calendar/alternative.php +++ /dev/null @@ -1,80 +0,0 @@ -title = 'Календарь ДР'; -?> - Html::a(' Назад', - Yii::$app->request->referrer, ['class' => 'btn btn-primary',]), - 'runBuild' => "function (date, content){ - this.build(date, content) - }", - 'updateContent' => "function(date){ - let monthNumber = date.substr(5, 2); - return fetch('../ajax/get-birthday-by-month?' + - 'month=' + monthNumber) - .then((res) => { - return res.json() - }) - }", - 'getColor' => "function (date, dates = null) { - for (let contentDate of dates) { - if (contentDate['dob'].substr(8, 2) == DateHelper.intToDate(date.getDate())) { - return 'success'; - } - } - }", - 'getHtmlContentForDate' => 'function (content, date) { - let flag = false - let html = ` - - - - - - - - `; - for (let i = 1; i <= content.length; i++) { - let model = content[i - 1]; - if (model["dob"].substr(8, 2) == date.substr(8, 2)) { - flag = true; - html += `` - html += `` - html += `` - html += `` - html += `` - html += `` - } - } - html += `
#ФИОДата рождения 
${i}${model["fio"]}${model["dob"]} - - - - - - -
` - if (flag) return html; - return "empty" - }' -]) ?> - -