Subversion Repositories SmartDukaan

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
15403 manish.sha 1
<?php
2
/**
3
 * This is i18n Schema file
4
 *
5
 * Use it to configure database for i18n
6
 *
7
 * @link          http://cakephp.org CakePHP(tm) Project
8
 * @package       app.Config.Schema
9
 * @since         CakePHP(tm) v 0.2.9
10
 */
11
 
12
/**
13
 * Using the Schema command line utility
14
 *
15
 * Use it to configure database for i18n
16
 *
17
 * cake schema run create i18n
18
 */
19
class I18nSchema extends CakeSchema {
20
 
21
/**
22
 * The name property
23
 *
24
 * @var string
25
 */
26
	public $name = 'i18n';
27
 
28
/**
29
 * Before event.
30
 *
31
 * @param array $event The event data.
32
 * @return bool success
33
 */
34
	public function before($event = array()) {
35
		return true;
36
	}
37
 
38
/**
39
 * After event.
40
 *
41
 * @param array $event The event data.
42
 * @return void
43
 */
44
	public function after($event = array()) {
45
	}
46
 
47
/**
48
 * The i18n table property
49
 *
50
 * @var array
51
 */
52
	public $i18n = array(
53
		'id' => array('type' => 'integer', 'null' => false, 'default' => null, 'length' => 10, 'key' => 'primary'),
54
		'locale' => array('type' => 'string', 'null' => false, 'length' => 6, 'key' => 'index'),
55
		'model' => array('type' => 'string', 'null' => false, 'key' => 'index'),
56
		'foreign_key' => array('type' => 'integer', 'null' => false, 'length' => 10, 'key' => 'index'),
57
		'field' => array('type' => 'string', 'null' => false, 'key' => 'index'),
58
		'content' => array('type' => 'text', 'null' => true, 'default' => null),
59
		'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => 1), 'locale' => array('column' => 'locale', 'unique' => 0), 'model' => array('column' => 'model', 'unique' => 0), 'row_id' => array('column' => 'foreign_key', 'unique' => 0), 'field' => array('column' => 'field', 'unique' => 0))
60
	);
61
 
62
}