pictcode / lib / Cake / Test / test_app / Model / Extract.php @ 0b1b8047
履歴 | 表示 | アノテート | ダウンロード (1.18 KB)
1 |
<?php
|
---|---|
2 |
/**
|
3 |
* Test App Extract Model
|
4 |
*
|
5 |
* CakePHP : Rapid Development Framework (http://cakephp.org)
|
6 |
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
|
7 |
*
|
8 |
* Licensed under The MIT License
|
9 |
* For full copyright and license information, please see the LICENSE.txt
|
10 |
* Redistributions of files must retain the above copyright notice.
|
11 |
*
|
12 |
* @copyright Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
|
13 |
* @link http://cakephp.org CakePHP Project
|
14 |
* @package Cake.Test.TestApp.Model
|
15 |
* @since CakePHP v 2.4
|
16 |
* @license http://www.opensource.org/licenses/mit-license.php MIT License
|
17 |
*/
|
18 |
|
19 |
/**
|
20 |
* Class Extract
|
21 |
*
|
22 |
* For testing Console i18n validation message extraction with quotes
|
23 |
*
|
24 |
* @package Cake.Test.TestApp.Model
|
25 |
*/
|
26 |
class Extract extends AppModel { |
27 |
|
28 |
public $useTable = false; |
29 |
|
30 |
public $validate = array( |
31 |
'title' => array( |
32 |
'custom' => array( |
33 |
'rule' => array('custom', '.*'), |
34 |
'allowEmpty' => true, |
35 |
'required' => false, |
36 |
'message' => 'double "quoted" validation' |
37 |
), |
38 |
'between' => array( |
39 |
'rule' => array('lengthBetween', 5, 15), |
40 |
'message' => "single 'quoted' validation" |
41 |
) |
42 |
), |
43 |
); |
44 |
|
45 |
} |