Subversion Repositories SmartDukaan

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
15051 manas 1
<?php
2
App::uses('AppModel', 'Model');
3
/**
4
 * PlayStoreLink Model
5
 *
6
 * @property Agent $Agent
7
 * @property Call $Call
8
 */
9
class PlayStoreLink extends AppModel {
10
 
11
/**
12
 * Display field
13
 *
14
 * @var string
15
 */
16
	public $displayField = 'id';
17
 
18
/**
19
 * Validation rules
20
 *
21
 * @var array
22
 */
23
	public $validate = array(
24
		'agent_id' => array(
25
			'numeric' => array(
26
				'rule' => array('numeric'),
27
				//'message' => 'Your custom message here',
28
				//'allowEmpty' => false,
29
				//'required' => false,
30
				//'last' => false, // Stop validation after this rule
31
				//'on' => 'create', // Limit validation to 'create' or 'update' operations
32
			),
33
		),
34
		'retailer_id' => array(
35
			'numeric' => array(
36
				'rule' => array('numeric'),
37
				//'message' => 'Your custom message here',
38
				//'allowEmpty' => false,
39
				//'required' => false,
40
				//'last' => false, // Stop validation after this rule
41
				//'on' => 'create', // Limit validation to 'create' or 'update' operations
42
			),
43
		),
44
		'call_id' => array(
45
			'numeric' => array(
46
				'rule' => array('numeric'),
47
				//'message' => 'Your custom message here',
48
				//'allowEmpty' => false,
49
				//'required' => false,
50
				//'last' => false, // Stop validation after this rule
51
				//'on' => 'create', // Limit validation to 'create' or 'update' operations
52
			),
53
		),
54
	);
55
 
56
	//The Associations below have been created with all possible keys, those that are not needed can be removed
57
 
58
/**
59
 * belongsTo associations
60
 *
61
 * @var array
62
 */
63
	public $belongsTo = array(
64
		'Agent' => array(
65
			'className' => 'Agent',
66
			'foreignKey' => 'agent_id',
67
			'conditions' => '',
68
			'fields' => '',
69
			'order' => ''
70
		),
71
		'Call' => array(
72
			'className' => 'Call',
73
			'foreignKey' => 'call_id',
74
			'conditions' => '',
75
			'fields' => '',
76
			'order' => ''
77
		)
78
	);
79
}