You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

Framework.sql 8.7 KiB

14 years ago
14 years ago
14 years ago
14 years ago
12 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276
  1. -- Core Elements to install WNFramework
  2. -- To be called from install.py
  3. --
  4. -- Table structure for table `tabDocField`
  5. --
  6. DROP TABLE IF EXISTS `tabDocField`;
  7. CREATE TABLE `tabDocField` (
  8. `name` varchar(120) NOT NULL,
  9. `creation` datetime DEFAULT NULL,
  10. `modified` datetime DEFAULT NULL,
  11. `modified_by` varchar(40) DEFAULT NULL,
  12. `owner` varchar(40) DEFAULT NULL,
  13. `docstatus` int(1) DEFAULT '0',
  14. `parent` varchar(120) DEFAULT NULL,
  15. `parentfield` varchar(120) DEFAULT NULL,
  16. `parenttype` varchar(120) DEFAULT NULL,
  17. `idx` int(8) DEFAULT NULL,
  18. `fieldname` varchar(180) DEFAULT NULL,
  19. `label` varchar(180) DEFAULT NULL,
  20. `oldfieldname` varchar(180) DEFAULT NULL,
  21. `fieldtype` varchar(180) DEFAULT NULL,
  22. `oldfieldtype` varchar(180) DEFAULT NULL,
  23. `options` text,
  24. `search_index` int(1) DEFAULT NULL,
  25. `hidden` int(1) DEFAULT NULL,
  26. `print_hide` int(1) DEFAULT NULL,
  27. `report_hide` int(1) DEFAULT NULL,
  28. `reqd` int(1) DEFAULT NULL,
  29. `no_copy` int(1) DEFAULT NULL,
  30. `allow_on_submit` int(1) DEFAULT NULL,
  31. `trigger` varchar(180) DEFAULT NULL,
  32. `depends_on` varchar(180) DEFAULT NULL,
  33. `permlevel` int(11) DEFAULT '0',
  34. `ignore_restrictions` int(1) DEFAULT NULL,
  35. `width` varchar(180) DEFAULT NULL,
  36. `print_width` varchar(180) DEFAULT NULL,
  37. `default` text,
  38. `description` text,
  39. `in_filter` int(1) DEFAULT NULL,
  40. `in_list_view` int(1) DEFAULT NULL,
  41. `no_column` int(1) DEFAULT NULL,
  42. `read_only` int(1) DEFAULT NULL,
  43. PRIMARY KEY (`name`),
  44. KEY `parent` (`parent`),
  45. KEY `label` (`label`),
  46. KEY `fieldtype` (`fieldtype`),
  47. KEY `fieldname` (`fieldname`)
  48. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  49. --
  50. -- Table structure for table `tabDocPerm`
  51. --
  52. DROP TABLE IF EXISTS `tabDocPerm`;
  53. /*!40101 SET @saved_cs_client = @@character_set_client */;
  54. /*!40101 SET character_set_client = utf8 */;
  55. CREATE TABLE `tabDocPerm` (
  56. `name` varchar(120) NOT NULL,
  57. `creation` datetime DEFAULT NULL,
  58. `modified` datetime DEFAULT NULL,
  59. `modified_by` varchar(40) DEFAULT NULL,
  60. `owner` varchar(40) DEFAULT NULL,
  61. `docstatus` int(1) DEFAULT '0',
  62. `parent` varchar(120) DEFAULT NULL,
  63. `parentfield` varchar(120) DEFAULT NULL,
  64. `parenttype` varchar(120) DEFAULT NULL,
  65. `idx` int(8) DEFAULT NULL,
  66. `permlevel` int(11) DEFAULT '0',
  67. `role` varchar(180) DEFAULT NULL,
  68. `match` varchar(180) DEFAULT NULL,
  69. `read` int(1) DEFAULT NULL,
  70. `write` int(1) DEFAULT NULL,
  71. `create` int(1) DEFAULT NULL,
  72. `submit` int(1) DEFAULT NULL,
  73. `cancel` int(1) DEFAULT NULL,
  74. `delete` int(1) DEFAULT NULL,
  75. `amend` int(1) DEFAULT NULL,
  76. `report` int(1) DEFAULT NULL,
  77. `export` int(1) DEFAULT NULL,
  78. `import` int(1) DEFAULT NULL,
  79. `print` int(1) DEFAULT NULL,
  80. `email` int(1) DEFAULT NULL,
  81. `restrict` int(1) DEFAULT NULL,
  82. PRIMARY KEY (`name`),
  83. KEY `parent` (`parent`)
  84. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  85. /*!40101 SET character_set_client = @saved_cs_client */;
  86. --
  87. -- Table structure for table `tabDocType`
  88. --
  89. DROP TABLE IF EXISTS `tabDocType`;
  90. /*!40101 SET @saved_cs_client = @@character_set_client */;
  91. /*!40101 SET character_set_client = utf8 */;
  92. CREATE TABLE `tabDocType` (
  93. `name` varchar(180) NOT NULL DEFAULT '',
  94. `creation` datetime DEFAULT NULL,
  95. `modified` datetime DEFAULT NULL,
  96. `modified_by` varchar(40) DEFAULT NULL,
  97. `owner` varchar(180) DEFAULT NULL,
  98. `docstatus` int(1) DEFAULT '0',
  99. `parent` varchar(120) DEFAULT NULL,
  100. `parentfield` varchar(120) DEFAULT NULL,
  101. `parenttype` varchar(120) DEFAULT NULL,
  102. `idx` int(8) DEFAULT NULL,
  103. `search_fields` varchar(180) DEFAULT NULL,
  104. `issingle` int(1) DEFAULT NULL,
  105. `istable` int(1) DEFAULT NULL,
  106. `version` int(11) DEFAULT NULL,
  107. `module` varchar(180) DEFAULT NULL,
  108. `plugin` varchar(180) DEFAULT NULL,
  109. `autoname` varchar(180) DEFAULT NULL,
  110. `name_case` varchar(180) DEFAULT NULL,
  111. `title_field` varchar(180) DEFAULT NULL,
  112. `description` text,
  113. `colour` varchar(180) DEFAULT NULL,
  114. `read_only` int(1) DEFAULT NULL,
  115. `in_create` int(1) DEFAULT NULL,
  116. `show_in_menu` int(1) DEFAULT NULL,
  117. `menu_index` int(11) DEFAULT NULL,
  118. `parent_node` varchar(180) DEFAULT NULL,
  119. `smallicon` varchar(180) DEFAULT NULL,
  120. `allow_print` int(1) DEFAULT NULL,
  121. `allow_email` int(1) DEFAULT NULL,
  122. `allow_copy` int(1) DEFAULT NULL,
  123. `allow_rename` int(1) DEFAULT NULL,
  124. `allow_import` int(1) DEFAULT NULL,
  125. `hide_toolbar` int(1) DEFAULT NULL,
  126. `hide_heading` int(1) DEFAULT NULL,
  127. `allow_attach` int(1) DEFAULT NULL,
  128. `use_template` int(1) DEFAULT NULL,
  129. `max_attachments` int(11) DEFAULT NULL,
  130. `section_style` varchar(180) DEFAULT NULL,
  131. `client_script` mediumtext,
  132. `client_script_core` mediumtext,
  133. `server_code` mediumtext,
  134. `server_code_core` mediumtext,
  135. `server_code_compiled` mediumtext,
  136. `client_string` mediumtext,
  137. `server_code_error` varchar(180) DEFAULT NULL,
  138. `print_outline` varchar(180) DEFAULT NULL,
  139. `dt_template` mediumtext,
  140. `is_transaction_doc` int(1) DEFAULT NULL,
  141. `change_log` mediumtext,
  142. `read_only_onload` int(1) DEFAULT NULL,
  143. `allow_trash` int(1) DEFAULT NULL,
  144. `in_dialog` int(1) DEFAULT NULL,
  145. `document_type` varchar(180) DEFAULT NULL,
  146. `icon` varchar(180) DEFAULT NULL,
  147. `tag_fields` varchar(180) DEFAULT NULL,
  148. `subject` varchar(180) DEFAULT NULL,
  149. `_last_update` varchar(32) DEFAULT NULL,
  150. `default_print_format` varchar(180) DEFAULT NULL,
  151. `is_submittable` int(1) DEFAULT NULL,
  152. `_user_tags` varchar(180) DEFAULT NULL,
  153. `custom` int(1) DEFAULT NULL,
  154. PRIMARY KEY (`name`),
  155. KEY `parent` (`parent`)
  156. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  157. /*!40101 SET character_set_client = @saved_cs_client */;
  158. --
  159. -- Table structure for table `tabSeries`
  160. --
  161. DROP TABLE IF EXISTS `tabSeries`;
  162. /*!40101 SET @saved_cs_client = @@character_set_client */;
  163. /*!40101 SET character_set_client = utf8 */;
  164. CREATE TABLE `tabSeries` (
  165. `name` varchar(100) DEFAULT NULL,
  166. `current` int(10) DEFAULT NULL
  167. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  168. /*!40101 SET character_set_client = @saved_cs_client */;
  169. --
  170. -- Table structure for table `tabSessions`
  171. --
  172. DROP TABLE IF EXISTS `tabSessions`;
  173. /*!40101 SET @saved_cs_client = @@character_set_client */;
  174. /*!40101 SET character_set_client = utf8 */;
  175. CREATE TABLE `tabSessions` (
  176. `user` varchar(40) DEFAULT NULL,
  177. `sid` varchar(120) DEFAULT NULL,
  178. `sessiondata` longtext,
  179. `ipaddress` varchar(16) DEFAULT NULL,
  180. `lastupdate` datetime DEFAULT NULL,
  181. `status` varchar(20) DEFAULT NULL,
  182. KEY `sid` (`sid`)
  183. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  184. /*!40101 SET character_set_client = @saved_cs_client */;
  185. --
  186. -- Table structure for table `tabSingles`
  187. --
  188. DROP TABLE IF EXISTS `tabSingles`;
  189. /*!40101 SET @saved_cs_client = @@character_set_client */;
  190. /*!40101 SET character_set_client = utf8 */;
  191. CREATE TABLE `tabSingles` (
  192. `doctype` varchar(40) DEFAULT NULL,
  193. `field` varchar(40) DEFAULT NULL,
  194. `value` text,
  195. KEY `singles_doctype_field_index` (`doctype`, `field`)
  196. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  197. --
  198. -- Table structure for table `__Auth`
  199. --
  200. DROP TABLE IF EXISTS `__Auth`;
  201. /*!40101 SET @saved_cs_client = @@character_set_client */;
  202. /*!40101 SET character_set_client = utf8 */;
  203. CREATE TABLE `__Auth` (
  204. `user` VARCHAR(180) NOT NULL PRIMARY KEY,
  205. `password` VARCHAR(180) NOT NULL,
  206. KEY `user` (`user`)
  207. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  208. --
  209. -- Table structure for table `tabFile Data`
  210. --
  211. DROP TABLE IF EXISTS `tabFile Data`;
  212. CREATE TABLE `tabFile Data` (
  213. `name` varchar(120) NOT NULL,
  214. `creation` datetime DEFAULT NULL,
  215. `modified` datetime DEFAULT NULL,
  216. `modified_by` varchar(40) DEFAULT NULL,
  217. `owner` varchar(40) DEFAULT NULL,
  218. `docstatus` int(1) DEFAULT '0',
  219. `parent` varchar(120) DEFAULT NULL,
  220. `parentfield` varchar(120) DEFAULT NULL,
  221. `parenttype` varchar(120) DEFAULT NULL,
  222. `idx` int(8) DEFAULT NULL,
  223. `file_name` varchar(180) DEFAULT NULL,
  224. `file_url` varchar(180) DEFAULT NULL,
  225. `module` varchar(180) DEFAULT NULL,
  226. `attached_to_name` varchar(180) DEFAULT NULL,
  227. `file_size` int(11) DEFAULT NULL,
  228. `attached_to_doctype` varchar(180) DEFAULT NULL,
  229. PRIMARY KEY (`name`),
  230. KEY `parent` (`parent`),
  231. KEY `attached_to_name` (`attached_to_name`),
  232. KEY `attached_to_doctype` (`attached_to_doctype`)
  233. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  234. --
  235. -- Table structure for table `tabDefaultValue`
  236. --
  237. DROP TABLE IF EXISTS `tabDefaultValue`;
  238. CREATE TABLE `tabDefaultValue` (
  239. `name` varchar(120) NOT NULL,
  240. `creation` datetime DEFAULT NULL,
  241. `modified` datetime DEFAULT NULL,
  242. `modified_by` varchar(40) DEFAULT NULL,
  243. `owner` varchar(40) DEFAULT NULL,
  244. `docstatus` int(1) DEFAULT '0',
  245. `parent` varchar(120) DEFAULT NULL,
  246. `parentfield` varchar(120) DEFAULT NULL,
  247. `parenttype` varchar(120) DEFAULT NULL,
  248. `idx` int(8) DEFAULT NULL,
  249. `defvalue` text,
  250. `defkey` varchar(180) DEFAULT NULL,
  251. PRIMARY KEY (`name`),
  252. KEY `parent` (`parent`),
  253. KEY `defaultvalue_parent_defkey_index` (`parent`,`defkey`)
  254. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;