From b10158134fecdd0dd8f80f0e12fffc1b3adf7268 Mon Sep 17 00:00:00 2001 From: s-nakajima Date: Tue, 27 Dec 2016 22:55:33 +0900 Subject: [PATCH] =?UTF-8?q?=E3=82=A4=E3=83=B3=E3=82=B9=E3=83=88=E3=83=BC?= =?UTF-8?q?=E3=83=AB=E6=99=82=E3=80=81=E5=8D=98=E8=A8=80=E8=AA=9E=E3=81=A7?= =?UTF-8?q?=E7=99=BB=E9=8C=B2=E3=81=99=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Config/Migration/1472409223_records.php | 2 +- Model/Language.php | 30 ++++++++++++------------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/Config/Migration/1472409223_records.php b/Config/Migration/1472409223_records.php index ed157b6..3cc4890 100644 --- a/Config/Migration/1472409223_records.php +++ b/Config/Migration/1472409223_records.php @@ -46,7 +46,7 @@ class Records extends NetCommonsMigration { 'id' => '1', 'code' => 'en', 'weight' => '2', - 'is_active' => true, + 'is_active' => false, ), array( 'id' => '2', diff --git a/Model/Language.php b/Model/Language.php index be64062..7ed0943 100644 --- a/Model/Language.php +++ b/Model/Language.php @@ -44,24 +44,24 @@ class Language extends M17nAppModel { */ public function beforeValidate($options = array()) { $this->validate = Hash::merge($this->validate, array( - 'code' => array( - 'notBlank' => array( - 'rule' => array('notBlank'), - 'message' => __d('net_commons', 'Invalid request.'), + 'code' => array( + 'notBlank' => array( + 'rule' => array('notBlank'), + 'message' => __d('net_commons', 'Invalid request.'), + ), ), - ), - 'weight' => array( - 'numeric' => array( - 'rule' => array('numeric'), - 'message' => __d('net_commons', 'Invalid request.'), + 'weight' => array( + 'numeric' => array( + 'rule' => array('numeric'), + 'message' => __d('net_commons', 'Invalid request.'), + ), ), - ), - 'is_active' => array( - 'boolean' => array( - 'rule' => array('boolean'), - 'message' => __d('net_commons', 'Invalid request.'), + 'is_active' => array( + 'boolean' => array( + 'rule' => array('boolean'), + 'message' => __d('net_commons', 'Invalid request.'), + ), ), - ), )); return parent::beforeValidate($options);