initial commit
[namibia] / module / Location / src / Location / Service / Town.php
1 <?php
2 namespace Location\Service;
3
4
5
6 /**
7  * Manage town data.
8  * @author andre.fourie
9  */
10 class Town extends \Workspace\Service\DataBin
11 {
12
13         /**
14          * @var array
15          */
16         protected $meta = array(
17                         'Base'        => 'Town',
18                         'DatasetName' => 'towns',
19                         'Entity'      => '\Location\Entity\Town',
20                         'References'  => array(
21                                 'region' => '\Location\Entity\Region'
22                         )
23         );
24         /**
25          * @var array
26         */
27         protected $metaList = array(
28                         'Contract'      => 'Recurring',
29                         'RequiredInput' => array(),
30                         'OptionalInput' => array(
31                                         'Filter' => array(
32                                                         'name'        => 'String100'
33                                         )
34                         ),
35                         'Filter' => array(),
36                         'Fields' => array(
37                                 'name'
38                         ),
39                         'Expand' => array()
40         );
41         /**
42          * @var array
43         */
44         protected $metaSelectList = array(
45                         'Type'          => 'SelectList',
46                         'Contract'      => 'Recurring',
47                         'RequiredInput' => array(),
48                         'OptionalInput' => array(
49                                         'Filter' => array(
50                                                         'name'        => 'String100',
51                                                         'region'      => 'Id'
52                                         )
53                         ),
54                         'Filter'   => array(),
55                         'Label'    => array(
56                                 'Format' => '[name]',
57                                 'Fields' => array('name')
58                         )
59         );
60         /**
61          * @var array
62          */
63         protected $metaCreate = array(
64                         'Contract' => 'Recurring',
65                         'RequiredInput' => array(
66                                 'Town' => array(
67                                         'region' => 'Id',
68                                         'name'   => 'String100'
69                                 )
70                         )
71         );
72         /**
73          * @var array
74          */
75         protected $metaUpdate = array(
76                         'Contract' => 'UseOnce',
77                         'RequiredInput' => array(
78                                 'Town' => array(
79                                         'region' => 'Id',
80                                         'name'   => 'String100'
81                                 )
82                         )
83         );
84         /**
85          * @var array
86          */
87         protected $metaDelete = array(
88                         'Contract' => 'UseOnce'
89         );
90
91 }