From 5d57415b36c97f9f93545c3989a440b84dd5c602 Mon Sep 17 00:00:00 2001
From: s-nakajima
Date: Tue, 14 Jul 2020 19:44:21 +0900
Subject: [PATCH 1/5] =?UTF-8?q?change:=20=E5=AD=A6=E6=A0=A1=E3=82=A6?=
=?UTF-8?q?=E3=82=A7=E3=83=96=E3=82=B5=E3=82=A4=E3=83=88=E6=A7=8B=E7=AF=89?=
=?UTF-8?q?=E7=94=B3=E8=AB=8B=E7=94=BB=E9=9D=A2=E3=81=AE=E3=83=8A=E3=83=93?=
=?UTF-8?q?=E3=83=90=E3=83=BC=E3=81=B0=E6=94=B9=E8=A1=8C=E3=81=95=E3=82=8C?=
=?UTF-8?q?=E3=81=A6=E3=81=97=E3=81=BE=E3=81=86=E3=81=9F=E3=82=81width?=
=?UTF-8?q?=E3=82=92=E8=A8=AD=E5=AE=9A=E3=81=A7=E3=81=8D=E3=82=8B=E3=82=88?=
=?UTF-8?q?=E3=81=86=E3=81=AB=E4=BF=AE=E6=AD=A3=20https://github.com/eduma?=
=?UTF-8?q?p-jp/Edumap2/issues/49?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
View/Helper/WizardHelper.php | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/View/Helper/WizardHelper.php b/View/Helper/WizardHelper.php
index 0b1f0f35..24a5cc44 100644
--- a/View/Helper/WizardHelper.php
+++ b/View/Helper/WizardHelper.php
@@ -111,7 +111,7 @@ public function beforeRender($viewFile) {
public function navibar($activeKey, $small = false) {
$output = '';
- $stepWidth = ' style="width: ' . 100 / count($this->settings['navibar']) . '%;"';
+ $defaultStepWidth = ' style="width: ' . 100 / count($this->settings['navibar']) . '%;"';
if ($small) {
$smallCss = ' small';
@@ -127,6 +127,12 @@ public function navibar($activeKey, $small = false) {
foreach ($this->settings['navibar'] as $key => $step) {
$index++;
+ if (isset($step['width'])) {
+ $stepWidth = $step['width'];
+ } else {
+ $stepWidth = $defaultStepWidth;
+ }
+
$badge = '' . $index . '';
$currentClass = '';
if ($key === $activeKey) {
From fec7b7777cf09c4bca04a27610e7ec7826530b9c Mon Sep 17 00:00:00 2001
From: s-nakajima
Date: Fri, 31 Jul 2020 17:03:00 +0900
Subject: [PATCH 2/5] =?UTF-8?q?change:=20test:=20Travis=E3=81=8B=E3=82=89P?=
=?UTF-8?q?HP5.6=E3=82=92=E5=89=8A=E9=99=A4=20https://github.com/NetCommon?=
=?UTF-8?q?s3/NetCommons3/issues/1588?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.travis.yml | 1 -
phpunit.xml.dist | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index 392fa1c0..680e7f61 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,7 +1,6 @@
language: php
php:
- - 5.6
- 7.0
- 7.1
- 7.2
diff --git a/phpunit.xml.dist b/phpunit.xml.dist
index 249486ba..e46f109f 100644
--- a/phpunit.xml.dist
+++ b/phpunit.xml.dist
@@ -1,7 +1,7 @@
-
+
From 58f2dcdd0e4ca5bc74328f07a79b3497bb914281 Mon Sep 17 00:00:00 2001
From: s-nakajima
Date: Fri, 31 Jul 2020 18:28:20 +0900
Subject: [PATCH 3/5] =?UTF-8?q?revert:=20=E8=AA=A4=E3=81=A3=E3=81=A6?=
=?UTF-8?q?=E3=82=B3=E3=83=9F=E3=83=83=E3=83=88=E3=81=97=E3=81=A6=E3=81=97?=
=?UTF-8?q?=E3=81=BE=E3=81=A3=E3=81=9F=E3=81=9F=E3=82=81=E4=BF=AE=E6=AD=A3?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
View/Elements/common_footer.ctp | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/View/Elements/common_footer.ctp b/View/Elements/common_footer.ctp
index 26355500..03234090 100644
--- a/View/Elements/common_footer.ctp
+++ b/View/Elements/common_footer.ctp
@@ -10,7 +10,12 @@
?>
From a325a601f5572a62822e781f0033c47d8ec365b7 Mon Sep 17 00:00:00 2001
From: s-nakajima
Date: Fri, 13 Nov 2020 12:22:38 +0900
Subject: [PATCH 4/5] =?UTF-8?q?change:=20=E3=83=A1=E3=83=B3=E3=83=86?=
=?UTF-8?q?=E3=83=8A=E3=83=B3=E3=82=B9=E3=83=A2=E3=83=BC=E3=83=89=E3=81=AE?=
=?UTF-8?q?=E6=99=82=E3=80=81meta=E3=82=BF=E3=82=B0=E3=81=ABnoindex?=
=?UTF-8?q?=E7=AD=89=E3=82=92=E8=BF=BD=E5=8A=A0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
View/SiteClose/index.ctp | 1 +
1 file changed, 1 insertion(+)
diff --git a/View/SiteClose/index.ctp b/View/SiteClose/index.ctp
index 49a4f874..fd381512 100644
--- a/View/SiteClose/index.ctp
+++ b/View/SiteClose/index.ctp
@@ -8,6 +8,7 @@
* @license http://www.netcommons.org/license.txt NetCommons License
* @copyright Copyright 2014, NetCommons Project
*/
+$this->assign('meta', '');
?>
Date: Fri, 9 Apr 2021 11:49:22 +0900
Subject: [PATCH 5/5] =?UTF-8?q?change:=20=E3=83=9D=E3=83=BC=E3=82=BF?=
=?UTF-8?q?=E3=83=AB=E5=8C=96=E3=81=AB=E4=BC=B4=E3=81=84=E3=80=81=E5=85=AC?=
=?UTF-8?q?=E5=BC=8F=E3=82=B5=E3=82=A4=E3=83=88=E3=81=A7=E3=82=82IE?=
=?UTF-8?q?=E3=81=AE=E3=82=A2=E3=83=A9=E3=83=BC=E3=83=88=E3=82=92=E8=A1=A8?=
=?UTF-8?q?=E7=A4=BA=E3=81=99=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB=E4=BF=AE?=
=?UTF-8?q?=E6=AD=A3=20https://github.com/edumap-jp/Edumap2/issues/113=20h?=
=?UTF-8?q?ttps://github.com/edumap-jp/Edumap2/issues/118?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../Component/DeprecatedBrowserComponent.php | 77 +++++++++++++++++++
Controller/NetCommonsAppController.php | 10 +++
Locale/eng/LC_MESSAGES/net_commons.po | 3 +
Locale/jpn/LC_MESSAGES/net_commons.po | 3 +
4 files changed, 93 insertions(+)
create mode 100644 Controller/Component/DeprecatedBrowserComponent.php
diff --git a/Controller/Component/DeprecatedBrowserComponent.php b/Controller/Component/DeprecatedBrowserComponent.php
new file mode 100644
index 00000000..9d45414f
--- /dev/null
+++ b/Controller/Component/DeprecatedBrowserComponent.php
@@ -0,0 +1,77 @@
+
+ * @link http://www.netcommons.org NetCommons Project
+ * @license http://www.netcommons.org/license.txt NetCommons License
+ * @copyright Copyright 2014, NetCommons Project
+ */
+
+App::uses('Component', 'Controller');
+
+/**
+ * 非推奨ブラウザ関連 Component
+ *
+ * @property \SessionComponent $Session
+ *
+ * @author Shohei Nakajima
+ * @package NetCommons\Auth\Controller\Component
+ */
+class DeprecatedBrowserComponent extends Component {
+
+/**
+ * 使用するComponents
+ *
+ * @var array
+ */
+ public $components = [
+ 'Session',
+ ];
+
+/**
+ * コントローラ
+ *
+ * @var array
+ */
+ public $controller;
+
+/**
+ * Called before the Controller::beforeFilter().
+ *
+ * @param Controller $controller Instantiating controller
+ * @return void
+ */
+ public function initialize(Controller $controller) {
+ $this->controller = $controller;
+ }
+
+/**
+ * 非推奨ブラウザのチェック
+ *
+ * @return bool
+ */
+ public function isDeprecatedBrowser() {
+ $browser = strtolower(env('HTTP_USER_AGENT'));
+ return (strstr($browser , 'trident') || strstr($browser , 'msie'));
+ }
+
+/**
+ * 非推奨ブラウザエラーメッセージ
+ *
+ * @return void
+ */
+ public function setFlashNotification() {
+ if ($this->controller->Session->read('NetCommons.DeprecatedBrowser')) {
+ return;
+ }
+
+ $this->controller->NetCommons->setFlashNotification(
+ __d('net_commons', 'Internet Explorer(IE) is deprecated. ' .
+ 'If you are using IE, please change to the latest version such as Edge, Chrome, Firefox, etc.'),
+ ['class' => 'danger', 'interval' => 10000]
+ );
+ $this->controller->Session->write('NetCommons.DeprecatedBrowser', true);
+ }
+
+}
diff --git a/Controller/NetCommonsAppController.php b/Controller/NetCommonsAppController.php
index 01914da7..f231511e 100644
--- a/Controller/NetCommonsAppController.php
+++ b/Controller/NetCommonsAppController.php
@@ -197,6 +197,16 @@ private function __prepare() {
}
$this->request->params['named'] = $named;
}
+
+ if (empty($this->request->params['requested'])) {
+ //非推奨ブラウザチェック
+ /** @var \DeprecatedBrowserComponent $DeprecatedBrowser */
+ $DeprecatedBrowser = $this->Components->load('NetCommons.DeprecatedBrowser');
+ $DeprecatedBrowser->initialize($this);
+ if ($DeprecatedBrowser->isDeprecatedBrowser()) {
+ $DeprecatedBrowser->setFlashNotification();
+ }
+ }
}
/**
diff --git a/Locale/eng/LC_MESSAGES/net_commons.po b/Locale/eng/LC_MESSAGES/net_commons.po
index f1dd754f..6bcae6a0 100644
--- a/Locale/eng/LC_MESSAGES/net_commons.po
+++ b/Locale/eng/LC_MESSAGES/net_commons.po
@@ -2042,3 +2042,6 @@ msgstr ""
msgid "URL"
msgstr ""
+
+msgid "Internet Explorer(IE) is deprecated. If you are using IE, please change to the latest version such as Edge, Chrome, Firefox, etc."
+msgstr "Internet Explorer(IE) is deprecated.
If you are using IE, please change to the latest version such as Edge, Chrome, Firefox, etc."
diff --git a/Locale/jpn/LC_MESSAGES/net_commons.po b/Locale/jpn/LC_MESSAGES/net_commons.po
index 6ad3c6ef..ba54f05b 100644
--- a/Locale/jpn/LC_MESSAGES/net_commons.po
+++ b/Locale/jpn/LC_MESSAGES/net_commons.po
@@ -2086,3 +2086,6 @@ msgstr "権限が不正です。"
msgid "Date"
msgstr "日付"
+
+msgid "Internet Explorer(IE) is deprecated. If you are using IE, please change to the latest version such as Edge, Chrome, Firefox, etc."
+msgstr "お使いのブラウザがInternet Explorer(IE)のようです。
edumapではIEの利用を推奨していません。IEでの動作保証はできません。
お手数ですが、EdgeやChrome, Firefoxの最新版をご利用ください。"