svnno****@sourc*****
svnno****@sourc*****
2012年 5月 30日 (水) 02:00:23 JST
Revision: 107 http://sourceforge.jp/projects/smartupload/scm/svn/commits/107 Author: hryksbt Date: 2012-05-30 02:00:23 +0900 (Wed, 30 May 2012) Log Message: ----------- ユーザ更新Model作成 Modified Paths: -------------- trunk/Database/SmartEngineDB.sql trunk/Documents/DBテーブル定義(ユーザ管理DB).xlsx trunk/src/Engine/app/config/core.php Added Paths: ----------- trunk/src/Engine/app/app_controller.php trunk/src/Engine/app/app_helper.php trunk/src/Engine/app/app_model.php trunk/src/Engine/app/models/user_modify.php trunk/src/Engine/app/tests/fixtures/user_modify_fixture.php trunk/src/Engine/app/views/pages/home.ctp -------------- next part -------------- Modified: trunk/Database/SmartEngineDB.sql =================================================================== --- trunk/Database/SmartEngineDB.sql 2012-05-07 05:55:37 UTC (rev 106) +++ trunk/Database/SmartEngineDB.sql 2012-05-29 17:00:23 UTC (rev 107) @@ -1,118 +1,151 @@ --- MySQL dump 10.13 Distrib 5.1.62, for apple-darwin10.3.0 (i386) --- --- Host: localhost Database: SmartEngineDB --- ------------------------------------------------------ --- Server version 5.1.62 - -/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; -/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; -/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; -/*!40101 SET NAMES utf8 */; -/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; -/*!40103 SET TIME_ZONE='+00:00' */; -/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; -/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; -/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; -/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; - --- --- Table structure for table `credit_campanies` --- - -DROP TABLE IF EXISTS `credit_campanies`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!40101 SET character_set_client = utf8 */; -CREATE TABLE `credit_campanies` ( - `id` int(11) NOT NULL, - `campany_name` varchar(64) NOT NULL, - `delete_flag` int(11) NOT NULL, - `regist_date` datetime NOT NULL, - `modify_date` datetime NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; -/*!40101 SET character_set_client = @saved_cs_client */; - --- --- Dumping data for table `credit_campanies` --- - -LOCK TABLES `credit_campanies` WRITE; -/*!40000 ALTER TABLE `credit_campanies` DISABLE KEYS */; -/*!40000 ALTER TABLE `credit_campanies` ENABLE KEYS */; -UNLOCK TABLES; - --- --- Table structure for table `new_table` --- - -DROP TABLE IF EXISTS `new_table`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!40101 SET character_set_client = utf8 */; -CREATE TABLE `new_table` ( - `id` int(11) NOT NULL, - `country_name` varchar(64) NOT NULL, - `delete_flag` int(11) NOT NULL, - `regist_date` datetime NOT NULL, - `modify_date` datetime NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; -/*!40101 SET character_set_client = @saved_cs_client */; - --- --- Dumping data for table `new_table` --- - -LOCK TABLES `new_table` WRITE; -/*!40000 ALTER TABLE `new_table` DISABLE KEYS */; -/*!40000 ALTER TABLE `new_table` ENABLE KEYS */; -UNLOCK TABLES; - --- --- Table structure for table `users` --- - -DROP TABLE IF EXISTS `users`; -/*!40101 SET @saved_cs_client = @@character_set_client */; -/*!40101 SET character_set_client = utf8 */; -CREATE TABLE `users` ( - `id` int(11) NOT NULL, - `account` varchar(64) NOT NULL, - `password` varchar(64) NOT NULL, - `name` varchar(64) NOT NULL, - `address` varchar(128) NOT NULL, - `campany` varchar(64) DEFAULT NULL, - `country_id` int(11) NOT NULL, - `mail_address` varchar(64) NOT NULL, - `delete_flag` int(11) NOT NULL, - `accounting_flag` int(11) NOT NULL, - `credit_number` int(11) DEFAULT NULL, - `credit_expire` datetime DEFAULT NULL, - `credit_campany_id` int(11) DEFAULT NULL, - `bank_id` int(11) DEFAULT NULL, - `bank_account_number` int(11) DEFAULT NULL, - `create_date` datetime NOT NULL, - `modify_date` datetime DEFAULT NULL, - `application_date` datetime NOT NULL, - PRIMARY KEY (`id`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1; -/*!40101 SET character_set_client = @saved_cs_client */; - --- --- Dumping data for table `users` --- - -LOCK TABLES `users` WRITE; -/*!40000 ALTER TABLE `users` DISABLE KEYS */; -/*!40000 ALTER TABLE `users` ENABLE KEYS */; -UNLOCK TABLES; -/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; - -/*!40101 SET SQL_MODE=@OLD_SQL_MODE */; -/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; -/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; -/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; -/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; -/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; -/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; - --- Dump completed on 2012-05-07 0:13:25 +-- MySQL dump 10.13 Distrib 5.5.16, for Win32 (x86) +-- +-- Host: localhost Database: SmartEngineDB +-- ------------------------------------------------------ +-- Server version 5.5.16 + +/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; +/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; +/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; +/*!40101 SET NAMES utf8 */; +/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; +/*!40103 SET TIME_ZONE='+00:00' */; +/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; +/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; +/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; +/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; + +-- +-- Table structure for table `credit_campanies` +-- + +DROP TABLE IF EXISTS `credit_campanies`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `credit_campanies` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `campany_name` varchar(64) NOT NULL, + `delete_flag` int(11) NOT NULL, + `regist_date` datetime NOT NULL, + `modify_date` datetime NOT NULL, + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=latin1; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `credit_campanies` +-- + +LOCK TABLES `credit_campanies` WRITE; +/*!40000 ALTER TABLE `credit_campanies` DISABLE KEYS */; +/*!40000 ALTER TABLE `credit_campanies` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `nationalities` +-- + +DROP TABLE IF EXISTS `nationalities`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `nationalities` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `country_name` varchar(64) NOT NULL, + `delete_flag` int(11) NOT NULL, + `regist_date` datetime NOT NULL, + `modify_date` datetime NOT NULL, + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=latin1; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `nationalities` +-- + +LOCK TABLES `nationalities` WRITE; +/*!40000 ALTER TABLE `nationalities` DISABLE KEYS */; +/*!40000 ALTER TABLE `nationalities` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `user_modifies` +-- + +DROP TABLE IF EXISTS `user_modifies`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `user_modifies` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `user_id` int(11) NOT NULL, + `password` varchar(64) DEFAULT NULL, + `name` varchar(64) DEFAULT NULL, + `address` varchar(256) DEFAULT NULL, + `country_id` int(11) DEFAULT NULL, + `mail_address` varchar(64) DEFAULT NULL, + `credit_number` int(11) DEFAULT NULL, + `credit_expire` datetime DEFAULT NULL, + `credit_id` int(11) DEFAULT NULL, + `URL` varchar(128) DEFAULT NULL, + `apprication_date` datetime NOT NULL, + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=latin1; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `user_modifies` +-- + +LOCK TABLES `user_modifies` WRITE; +/*!40000 ALTER TABLE `user_modifies` DISABLE KEYS */; +/*!40000 ALTER TABLE `user_modifies` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `users` +-- + +DROP TABLE IF EXISTS `users`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `users` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `account` varchar(64) NOT NULL, + `password` varchar(64) NOT NULL, + `name` varchar(64) NOT NULL, + `address` varchar(128) NOT NULL, + `campany` varchar(64) DEFAULT NULL, + `country_id` int(11) NOT NULL, + `mail_address` varchar(64) NOT NULL, + `delete_flag` int(11) NOT NULL, + `accounting_flag` int(11) NOT NULL, + `credit_number` int(11) DEFAULT NULL, + `credit_expire` datetime DEFAULT NULL, + `credit_campany_id` int(11) DEFAULT NULL, + `bank_id` int(11) DEFAULT NULL, + `bank_account_number` int(11) DEFAULT NULL, + `create_date` datetime NOT NULL, + `modify_date` datetime DEFAULT NULL, + `application_date` datetime NOT NULL, + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=latin1; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `users` +-- + +LOCK TABLES `users` WRITE; +/*!40000 ALTER TABLE `users` DISABLE KEYS */; +/*!40000 ALTER TABLE `users` ENABLE KEYS */; +UNLOCK TABLES; +/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; + +/*!40101 SET SQL_MODE=@OLD_SQL_MODE */; +/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; +/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; +/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; +/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; +/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; +/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; + +-- Dump completed on 2012-05-30 2:04:58 Modified: trunk/Documents/DB?\227?\131?\134?\227?\131?\188?\227?\131?\150?\227?\131?\171?\229?\174?\154?\231?\190?\169(?\227?\131?\166?\227?\131?\188?\227?\130?\182?\231?\174?\161?\231?\144?\134DB).xlsx =================================================================== (Binary files differ) Added: trunk/src/Engine/app/app_controller.php =================================================================== --- trunk/src/Engine/app/app_controller.php (rev 0) +++ trunk/src/Engine/app/app_controller.php 2012-05-29 17:00:23 UTC (rev 107) @@ -0,0 +1,34 @@ +<?php +/** + * Application level Controller + * + * This file is application-wide controller file. You can put all + * application-wide controller-related methods here. + * + * PHP versions 4 and 5 + * + * CakePHP(tm) : Rapid Development Framework (http://cakephp.org) + * Copyright 2005-2012, Cake Software Foundation, Inc. (http://cakefoundation.org) + * + * Licensed under The MIT License + * Redistributions of files must retain the above copyright notice. + * + * @copyright Copyright 2005-2012, Cake Software Foundation, Inc. (http://cakefoundation.org) + * @link http://cakephp.org CakePHP(tm) Project + * @package cake + * @subpackage cake.app + * @since CakePHP(tm) v 0.2.9 + * @license MIT License (http://www.opensource.org/licenses/mit-license.php) + */ + +/** + * Application Controller + * + * Add your application-wide methods in the class below, your controllers + * will inherit them. + * + * @package cake + * @subpackage cake.app + */ +class AppController extends Controller { +} Added: trunk/src/Engine/app/app_helper.php =================================================================== --- trunk/src/Engine/app/app_helper.php (rev 0) +++ trunk/src/Engine/app/app_helper.php 2012-05-29 17:00:23 UTC (rev 107) @@ -0,0 +1,36 @@ +<?php +/** + * Application level View Helper + * + * This file is application-wide helper file. You can put all + * application-wide helper-related methods here. + * + * PHP versions 4 and 5 + * + * CakePHP(tm) : Rapid Development Framework (http://cakephp.org) + * Copyright 2005-2012, Cake Software Foundation, Inc. (http://cakefoundation.org) + * + * Licensed under The MIT License + * Redistributions of files must retain the above copyright notice. + * + * @copyright Copyright 2005-2012, Cake Software Foundation, Inc. (http://cakefoundation.org) + * @link http://cakephp.org CakePHP(tm) Project + * @package cake + * @subpackage cake.cake + * @since CakePHP(tm) v 0.2.9 + * @license MIT License (http://www.opensource.org/licenses/mit-license.php) + */ +App::import('Helper', 'Helper', false); + +/** + * This is a placeholder class. + * Create the same file in app/app_helper.php + * + * Add your application-wide methods in the class below, your helpers + * will inherit them. + * + * @package cake + * @subpackage cake.cake + */ +class AppHelper extends Helper { +} Added: trunk/src/Engine/app/app_model.php =================================================================== --- trunk/src/Engine/app/app_model.php (rev 0) +++ trunk/src/Engine/app/app_model.php 2012-05-29 17:00:23 UTC (rev 107) @@ -0,0 +1,34 @@ +<?php +/** + * Application model for Cake. + * + * This file is application-wide model file. You can put all + * application-wide model-related methods here. + * + * PHP versions 4 and 5 + * + * CakePHP(tm) : Rapid Development Framework (http://cakephp.org) + * Copyright 2005-2012, Cake Software Foundation, Inc. (http://cakefoundation.org) + * + * Licensed under The MIT License + * Redistributions of files must retain the above copyright notice. + * + * @copyright Copyright 2005-2012, Cake Software Foundation, Inc. (http://cakefoundation.org) + * @link http://cakephp.org CakePHP(tm) Project + * @package cake + * @subpackage cake.app + * @since CakePHP(tm) v 0.2.9 + * @license MIT License (http://www.opensource.org/licenses/mit-license.php) + */ + +/** + * Application model for Cake. + * + * Add your application-wide methods in the class below, your models + * will inherit them. + * + * @package cake + * @subpackage cake.app + */ +class AppModel extends Model { +} Modified: trunk/src/Engine/app/config/core.php =================================================================== --- trunk/src/Engine/app/config/core.php 2012-05-07 05:55:37 UTC (rev 106) +++ trunk/src/Engine/app/config/core.php 2012-05-29 17:00:23 UTC (rev 107) @@ -201,12 +201,12 @@ /** * A random string used in security hashing methods. */ - Configure::write('Security.salt', '_DYhG93b0qyJfIxfs2guVoUubWwvniR2G0FgaC9mi'); + Configure::write('Security.salt', 'b03a457cb957e9551f68f547246bdaa7d89536d6'); /** * A random numeric string (digits only) used to encrypt/decrypt strings. */ - Configure::write('Security.cipherSeed', '_76859309657453542496749683645'); + Configure::write('Security.cipherSeed', '376665646235383030323365386262'); /** * Apply timestamps with the last modified time to static assets (js, css, images). Added: trunk/src/Engine/app/models/user_modify.php =================================================================== --- trunk/src/Engine/app/models/user_modify.php (rev 0) +++ trunk/src/Engine/app/models/user_modify.php 2012-05-29 17:00:23 UTC (rev 107) @@ -0,0 +1,122 @@ +<?php +class UserModify extends AppModel { + var $name = 'UserModify'; + var $displayField = 'name'; + var $validate = array( + 'user_id' => array( + 'numeric' => array( + 'rule' => array('numeric'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'name' => array( + 'alphanumeric' => array( + 'rule' => array('alphanumeric'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'country_id' => array( + 'numeric' => array( + 'rule' => array('numeric'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'mail_address' => array( + 'email' => array( + 'rule' => array('email'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'credit_number' => array( + 'cc' => array( + 'rule' => array('cc'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'credit_expire' => array( + 'date' => array( + 'rule' => array('date'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'credit_id' => array( + 'numeric' => array( + 'rule' => array('numeric'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'URL' => array( + 'url' => array( + 'rule' => array('url'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + 'apprication_date' => array( + 'date' => array( + 'rule' => array('date'), + //'message' => 'Your custom message here', + //'allowEmpty' => false, + //'required' => false, + //'last' => false, // Stop validation after this rule + //'on' => 'create', // Limit validation to 'create' or 'update' operations + ), + ), + ); + //The Associations below have been created with all possible keys, those that are not needed can be removed + + var $belongsTo = array( + 'User' => array( + 'className' => 'User', + 'foreignKey' => 'user_id', + 'conditions' => '', + 'fields' => '', + 'order' => '' + ), + 'Country' => array( + 'className' => 'Country', + 'foreignKey' => 'country_id', + 'conditions' => '', + 'fields' => '', + 'order' => '' + ), + 'Credit' => array( + 'className' => 'Credit', + 'foreignKey' => 'credit_id', + 'conditions' => '', + 'fields' => '', + 'order' => '' + ) + ); +} Added: trunk/src/Engine/app/tests/fixtures/user_modify_fixture.php =================================================================== --- trunk/src/Engine/app/tests/fixtures/user_modify_fixture.php (rev 0) +++ trunk/src/Engine/app/tests/fixtures/user_modify_fixture.php 2012-05-29 17:00:23 UTC (rev 107) @@ -0,0 +1,39 @@ +<?php +/* UserModify Fixture generated on: 2012-05-29 19:03:03 : 1338310983 */ +class UserModifyFixture extends CakeTestFixture { + var $name = 'UserModify'; + + var $fields = array( + 'id' => array('type' => 'integer', 'null' => false, 'default' => NULL, 'key' => 'primary'), + 'user_id' => array('type' => 'integer', 'null' => false, 'default' => NULL), + 'password' => array('type' => 'string', 'null' => true, 'default' => NULL, 'length' => 64, 'collate' => 'latin1_swedish_ci', 'charset' => 'latin1'), + 'name' => array('type' => 'string', 'null' => true, 'default' => NULL, 'length' => 64, 'collate' => 'latin1_swedish_ci', 'charset' => 'latin1'), + 'address' => array('type' => 'string', 'null' => true, 'default' => NULL, 'length' => 256, 'collate' => 'latin1_swedish_ci', 'charset' => 'latin1'), + 'country_id' => array('type' => 'integer', 'null' => true, 'default' => NULL), + 'mail_address' => array('type' => 'string', 'null' => true, 'default' => NULL, 'length' => 64, 'collate' => 'latin1_swedish_ci', 'charset' => 'latin1'), + 'credit_number' => array('type' => 'integer', 'null' => true, 'default' => NULL), + 'credit_expire' => array('type' => 'datetime', 'null' => true, 'default' => NULL), + 'credit_id' => array('type' => 'integer', 'null' => true, 'default' => NULL), + 'URL' => array('type' => 'string', 'null' => true, 'default' => NULL, 'length' => 128, 'collate' => 'latin1_swedish_ci', 'charset' => 'latin1'), + 'apprication_date' => array('type' => 'datetime', 'null' => false, 'default' => NULL), + 'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => 1)), + 'tableParameters' => array('charset' => 'latin1', 'collate' => 'latin1_swedish_ci', 'engine' => 'InnoDB') + ); + + var $records = array( + array( + 'id' => 1, + 'user_id' => 1, + 'password' => 'Lorem ipsum dolor sit amet', + 'name' => 'Lorem ipsum dolor sit amet', + 'address' => 'Lorem ipsum dolor sit amet', + 'country_id' => 1, + 'mail_address' => 'Lorem ipsum dolor sit amet', + 'credit_number' => 1, + 'credit_expire' => '2012-05-29 19:03:03', + 'credit_id' => 1, + 'URL' => 'Lorem ipsum dolor sit amet', + 'apprication_date' => '2012-05-29 19:03:03' + ), + ); +} Added: trunk/src/Engine/app/views/pages/home.ctp =================================================================== --- trunk/src/Engine/app/views/pages/home.ctp (rev 0) +++ trunk/src/Engine/app/views/pages/home.ctp 2012-05-29 17:00:23 UTC (rev 107) @@ -0,0 +1,101 @@ + +<iframe src="http://cakephp.org/bake-banner" width="830" height="160" style="overflow:hidden; border:none;"> + <p>For updates and important announcements, visit http://cakefest.org</p> +</iframe> +<h2>Sweet, "App" got Baked by CakePHP!</h2> + +<?php +if (Configure::read() > 0): + Debugger::checkSecurityKeys(); +endif; +?> +<p> +<?php + if (is_writable(TMP)): + echo '<span class="notice success">'; + __('Your tmp directory is writable.'); + echo '</span>'; + else: + echo '<span class="notice">'; + __('Your tmp directory is NOT writable.'); + echo '</span>'; + endif; +?> +</p> +<div id="url-rewriting-warning" style="background-color:#e32; color:#fff; padding:3px; margin: 20px 0"> + <?php __('URL rewriting is not properly configured on your server. '); ?> + <ol style="padding-left:20px"> + <li> + <a target="_blank" href="http://book.cakephp.org/view/917/Apache-and-mod_rewrite-and-htaccess" style="color:#fff;"> + <?php __('Help me configure it')?> + </a> + </li> + <li> + <a target="_blank" href="http://book.cakephp.org/view/931/CakePHP-Core-Configuration-Variables" style="color:#fff;"> + <?php __('I don\'t / can\'t use URL rewriting')?> + </a> + </li> + </ol> +</div> +<p> +<?php + $settings = Cache::settings(); + if (!empty($settings)): + echo '<span class="notice success">'; + printf(__('The %s is being used for caching. To change the config edit APP/config/core.php ', true), '<em>'. $settings['engine'] . 'Engine</em>'); + echo '</span>'; + else: + echo '<span class="notice">'; + __('Your cache is NOT working. Please check the settings in APP/config/core.php'); + echo '</span>'; + endif; +?> +</p> +<p> +<?php + $filePresent = null; + if (file_exists(CONFIGS . 'database.php')): + echo '<span class="notice success">'; + __('Your database configuration file is present.'); + $filePresent = true; + echo '</span>'; + else: + echo '<span class="notice">'; + __('Your database configuration file is NOT present.'); + echo '<br/>'; + __('Rename config/database.php.default to config/database.php'); + echo '</span>'; + endif; +?> +</p> +<?php +if (!empty($filePresent)): + if (!class_exists('ConnectionManager')) { + require LIBS . 'model' . DS . 'connection_manager.php'; + } + $db = ConnectionManager::getInstance(); + $connected = $db->getDataSource('default'); +?> +<p> +<?php + if ($connected->isConnected()): + echo '<span class="notice success">'; + __('Cake is able to connect to the database.'); + echo '</span>'; + else: + echo '<span class="notice">'; + __('Cake is NOT able to connect to the database.'); + echo '</span>'; + endif; +?> +</p> +<?php endif;?> +<h3><?php __('Editing this Page') ?></h3> +<p> +<?php + printf(__('To change the content of this page, edit: %s + To change its layout, edit: %s + You can also add some CSS styles for your pages at: %s', true), + APP . 'views' . DS . 'pages' . DS . 'home.ctp.<br />', APP . 'views' . DS . 'layouts' . DS . 'default.ctp.<br />', APP . 'webroot' . DS . 'css'); +?> +</p>