modtemplate.map.inc.php 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226
  1. <?php
  2. /**
  3. * @package modx
  4. * @subpackage sqlsrv
  5. */
  6. $xpdo_meta_map['modTemplate']= array (
  7. 'package' => 'modx',
  8. 'version' => '1.1',
  9. 'table' => 'site_templates',
  10. 'extends' => 'modElement',
  11. 'fields' =>
  12. array (
  13. 'templatename' => '',
  14. 'description' => 'Template',
  15. 'editor_type' => 0,
  16. 'category' => 0,
  17. 'icon' => '',
  18. 'template_type' => 0,
  19. 'content' => '',
  20. 'locked' => 0,
  21. 'properties' => NULL,
  22. 'static' => 0,
  23. 'static_file' => '',
  24. ),
  25. 'fieldMeta' =>
  26. array (
  27. 'templatename' =>
  28. array (
  29. 'dbtype' => 'nvarchar',
  30. 'precision' => '50',
  31. 'phptype' => 'string',
  32. 'null' => false,
  33. 'default' => '',
  34. 'index' => 'unique',
  35. ),
  36. 'description' =>
  37. array (
  38. 'dbtype' => 'nvarchar',
  39. 'precision' => '255',
  40. 'phptype' => 'string',
  41. 'null' => false,
  42. 'default' => 'Template',
  43. ),
  44. 'editor_type' =>
  45. array (
  46. 'dbtype' => 'int',
  47. 'phptype' => 'integer',
  48. 'null' => false,
  49. 'default' => 0,
  50. ),
  51. 'category' =>
  52. array (
  53. 'dbtype' => 'int',
  54. 'phptype' => 'integer',
  55. 'null' => false,
  56. 'default' => 0,
  57. 'index' => 'fk',
  58. ),
  59. 'icon' =>
  60. array (
  61. 'dbtype' => 'nvarchar',
  62. 'precision' => '255',
  63. 'phptype' => 'string',
  64. 'null' => false,
  65. 'default' => '',
  66. ),
  67. 'template_type' =>
  68. array (
  69. 'dbtype' => 'int',
  70. 'phptype' => 'integer',
  71. 'null' => false,
  72. 'default' => 0,
  73. ),
  74. 'content' =>
  75. array (
  76. 'dbtype' => 'nvarchar',
  77. 'precision' => 'max',
  78. 'phptype' => 'string',
  79. 'null' => false,
  80. 'default' => '',
  81. ),
  82. 'locked' =>
  83. array (
  84. 'dbtype' => 'bit',
  85. 'phptype' => 'boolean',
  86. 'null' => false,
  87. 'default' => 0,
  88. 'index' => 'index',
  89. ),
  90. 'properties' =>
  91. array (
  92. 'dbtype' => 'nvarchar',
  93. 'precision' => 'max',
  94. 'phptype' => 'array',
  95. 'null' => true,
  96. ),
  97. 'static' =>
  98. array (
  99. 'dbtype' => 'bit',
  100. 'phptype' => 'boolean',
  101. 'null' => false,
  102. 'default' => 0,
  103. 'index' => 'index',
  104. ),
  105. 'static_file' =>
  106. array (
  107. 'dbtype' => 'nvarchar',
  108. 'precision' => '255',
  109. 'phptype' => 'string',
  110. 'null' => false,
  111. 'default' => '',
  112. ),
  113. ),
  114. 'indexes' =>
  115. array (
  116. 'templatename' =>
  117. array (
  118. 'alias' => 'templatename',
  119. 'primary' => false,
  120. 'unique' => true,
  121. 'type' => 'BTREE',
  122. 'columns' =>
  123. array (
  124. 'templatename' =>
  125. array (
  126. 'length' => '',
  127. 'collation' => 'A',
  128. 'null' => false,
  129. ),
  130. ),
  131. ),
  132. 'category' =>
  133. array (
  134. 'alias' => 'category',
  135. 'primary' => false,
  136. 'unique' => false,
  137. 'type' => 'BTREE',
  138. 'columns' =>
  139. array (
  140. 'category' =>
  141. array (
  142. 'length' => '',
  143. 'collation' => 'A',
  144. 'null' => false,
  145. ),
  146. ),
  147. ),
  148. 'locked' =>
  149. array (
  150. 'alias' => 'locked',
  151. 'primary' => false,
  152. 'unique' => false,
  153. 'type' => 'BTREE',
  154. 'columns' =>
  155. array (
  156. 'locked' =>
  157. array (
  158. 'length' => '',
  159. 'collation' => 'A',
  160. 'null' => false,
  161. ),
  162. ),
  163. ),
  164. 'static' =>
  165. array (
  166. 'alias' => 'static',
  167. 'primary' => false,
  168. 'unique' => false,
  169. 'type' => 'BTREE',
  170. 'columns' =>
  171. array (
  172. 'static' =>
  173. array (
  174. 'length' => '',
  175. 'collation' => 'A',
  176. 'null' => false,
  177. ),
  178. ),
  179. ),
  180. ),
  181. 'composites' =>
  182. array (
  183. 'PropertySets' =>
  184. array (
  185. 'class' => 'modElementPropertySet',
  186. 'local' => 'id',
  187. 'foreign' => 'element',
  188. 'owner' => 'local',
  189. 'cardinality' => 'many',
  190. 'criteria' =>
  191. array (
  192. 'foreign' =>
  193. array (
  194. 'element_class' => 'modTemplate',
  195. ),
  196. ),
  197. ),
  198. 'TemplateVarTemplates' =>
  199. array (
  200. 'class' => 'modTemplateVarTemplate',
  201. 'local' => 'id',
  202. 'foreign' => 'templateid',
  203. 'cardinality' => 'many',
  204. 'owner' => 'local',
  205. ),
  206. ),
  207. 'aggregates' =>
  208. array (
  209. 'Category' =>
  210. array (
  211. 'class' => 'modCategory',
  212. 'local' => 'category',
  213. 'foreign' => 'id',
  214. 'cardinality' => 'one',
  215. 'owner' => 'foreign',
  216. ),
  217. 'Resources' =>
  218. array (
  219. 'class' => 'modResource',
  220. 'local' => 'id',
  221. 'foreign' => 'template',
  222. 'cardinality' => 'many',
  223. 'owner' => 'local',
  224. ),
  225. ),
  226. );