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.
 
 
 
 
 
 

244 lines
7.6 KiB

  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. `width` varchar(180) DEFAULT NULL,
  35. `print_width` varchar(180) DEFAULT NULL,
  36. `default` text,
  37. `description` text,
  38. `in_filter` int(1) DEFAULT NULL,
  39. `in_list_view` int(1) DEFAULT NULL,
  40. `no_column` int(1) DEFAULT NULL,
  41. `read_only` int(1) DEFAULT NULL,
  42. PRIMARY KEY (`name`),
  43. KEY `parent` (`parent`),
  44. KEY `label` (`label`),
  45. KEY `fieldtype` (`fieldtype`),
  46. KEY `fieldname` (`fieldname`)
  47. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  48. --
  49. -- Table structure for table `tabDocPerm`
  50. --
  51. DROP TABLE IF EXISTS `tabDocPerm`;
  52. /*!40101 SET @saved_cs_client = @@character_set_client */;
  53. /*!40101 SET character_set_client = utf8 */;
  54. CREATE TABLE `tabDocPerm` (
  55. `name` varchar(120) NOT NULL,
  56. `creation` datetime DEFAULT NULL,
  57. `modified` datetime DEFAULT NULL,
  58. `modified_by` varchar(40) DEFAULT NULL,
  59. `owner` varchar(40) DEFAULT NULL,
  60. `docstatus` int(1) DEFAULT '0',
  61. `parent` varchar(120) DEFAULT NULL,
  62. `parentfield` varchar(120) DEFAULT NULL,
  63. `parenttype` varchar(120) DEFAULT NULL,
  64. `idx` int(8) DEFAULT NULL,
  65. `permlevel` int(11) DEFAULT '0',
  66. `role` varchar(180) DEFAULT NULL,
  67. `match` varchar(180) DEFAULT NULL,
  68. `read` int(1) DEFAULT NULL,
  69. `write` int(1) DEFAULT NULL,
  70. `create` int(1) DEFAULT NULL,
  71. `submit` int(1) DEFAULT NULL,
  72. `cancel` int(1) DEFAULT NULL,
  73. `amend` int(1) DEFAULT NULL,
  74. `report` int(1) DEFAULT NULL,
  75. PRIMARY KEY (`name`),
  76. KEY `parent` (`parent`)
  77. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  78. /*!40101 SET character_set_client = @saved_cs_client */;
  79. --
  80. -- Table structure for table `tabDocType`
  81. --
  82. DROP TABLE IF EXISTS `tabDocType`;
  83. /*!40101 SET @saved_cs_client = @@character_set_client */;
  84. /*!40101 SET character_set_client = utf8 */;
  85. CREATE TABLE `tabDocType` (
  86. `name` varchar(180) NOT NULL DEFAULT '',
  87. `creation` datetime DEFAULT NULL,
  88. `modified` datetime DEFAULT NULL,
  89. `modified_by` varchar(40) DEFAULT NULL,
  90. `owner` varchar(180) DEFAULT NULL,
  91. `docstatus` int(1) DEFAULT '0',
  92. `parent` varchar(120) DEFAULT NULL,
  93. `parentfield` varchar(120) DEFAULT NULL,
  94. `parenttype` varchar(120) DEFAULT NULL,
  95. `idx` int(8) DEFAULT NULL,
  96. `search_fields` varchar(180) DEFAULT NULL,
  97. `issingle` int(1) DEFAULT NULL,
  98. `istable` int(1) DEFAULT NULL,
  99. `version` int(11) DEFAULT NULL,
  100. `module` varchar(180) DEFAULT NULL,
  101. `autoname` varchar(180) DEFAULT NULL,
  102. `name_case` varchar(180) DEFAULT NULL,
  103. `description` text,
  104. `colour` varchar(180) DEFAULT NULL,
  105. `read_only` int(1) DEFAULT NULL,
  106. `in_create` int(1) DEFAULT NULL,
  107. `show_in_menu` int(1) DEFAULT NULL,
  108. `menu_index` int(11) DEFAULT NULL,
  109. `parent_node` varchar(180) DEFAULT NULL,
  110. `smallicon` varchar(180) DEFAULT NULL,
  111. `allow_print` int(1) DEFAULT NULL,
  112. `allow_email` int(1) DEFAULT NULL,
  113. `allow_copy` int(1) DEFAULT NULL,
  114. `allow_rename` int(1) DEFAULT NULL,
  115. `allow_import` int(1) DEFAULT NULL,
  116. `hide_toolbar` int(1) DEFAULT NULL,
  117. `hide_heading` int(1) DEFAULT NULL,
  118. `allow_attach` int(1) DEFAULT NULL,
  119. `use_template` int(1) DEFAULT NULL,
  120. `max_attachments` int(11) DEFAULT NULL,
  121. `section_style` varchar(180) DEFAULT NULL,
  122. `client_script` mediumtext,
  123. `client_script_core` mediumtext,
  124. `server_code` mediumtext,
  125. `server_code_core` mediumtext,
  126. `server_code_compiled` mediumtext,
  127. `client_string` mediumtext,
  128. `server_code_error` varchar(180) DEFAULT NULL,
  129. `print_outline` varchar(180) DEFAULT NULL,
  130. `dt_template` mediumtext,
  131. `is_transaction_doc` int(1) DEFAULT NULL,
  132. `change_log` mediumtext,
  133. `read_only_onload` int(1) DEFAULT NULL,
  134. `allow_trash` int(1) DEFAULT NULL,
  135. `in_dialog` int(1) DEFAULT NULL,
  136. `document_type` varchar(180) DEFAULT NULL,
  137. `tag_fields` varchar(180) DEFAULT NULL,
  138. `subject` varchar(180) DEFAULT NULL,
  139. `_last_update` varchar(32) DEFAULT NULL,
  140. `default_print_format` varchar(180) DEFAULT NULL,
  141. `is_submittable` int(1) DEFAULT NULL,
  142. `_user_tags` varchar(180) DEFAULT NULL,
  143. `custom` int(1) DEFAULT NULL,
  144. PRIMARY KEY (`name`),
  145. KEY `parent` (`parent`)
  146. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  147. /*!40101 SET character_set_client = @saved_cs_client */;
  148. --
  149. -- Table structure for table `tabSeries`
  150. --
  151. DROP TABLE IF EXISTS `tabSeries`;
  152. /*!40101 SET @saved_cs_client = @@character_set_client */;
  153. /*!40101 SET character_set_client = utf8 */;
  154. CREATE TABLE `tabSeries` (
  155. `name` varchar(100) DEFAULT NULL,
  156. `current` int(10) DEFAULT NULL
  157. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  158. /*!40101 SET character_set_client = @saved_cs_client */;
  159. --
  160. -- Table structure for table `tabSessions`
  161. --
  162. DROP TABLE IF EXISTS `tabSessions`;
  163. /*!40101 SET @saved_cs_client = @@character_set_client */;
  164. /*!40101 SET character_set_client = utf8 */;
  165. CREATE TABLE `tabSessions` (
  166. `user` varchar(40) DEFAULT NULL,
  167. `sid` varchar(120) DEFAULT NULL,
  168. `sessiondata` longtext,
  169. `ipaddress` varchar(16) DEFAULT NULL,
  170. `lastupdate` datetime DEFAULT NULL,
  171. `status` varchar(20) DEFAULT NULL,
  172. KEY `sid` (`sid`)
  173. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  174. /*!40101 SET character_set_client = @saved_cs_client */;
  175. --
  176. -- Table structure for table `tabSingles`
  177. --
  178. DROP TABLE IF EXISTS `tabSingles`;
  179. /*!40101 SET @saved_cs_client = @@character_set_client */;
  180. /*!40101 SET character_set_client = utf8 */;
  181. CREATE TABLE `tabSingles` (
  182. `doctype` varchar(40) DEFAULT NULL,
  183. `field` varchar(40) DEFAULT NULL,
  184. `value` text,
  185. KEY `doctype` (`doctype`)
  186. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  187. --
  188. -- Table structure for table `__Auth`
  189. --
  190. DROP TABLE IF EXISTS `__Auth`;
  191. /*!40101 SET @saved_cs_client = @@character_set_client */;
  192. /*!40101 SET character_set_client = utf8 */;
  193. CREATE TABLE `__Auth` (
  194. `user` VARCHAR(180) NOT NULL PRIMARY KEY,
  195. `password` VARCHAR(180) NOT NULL,
  196. KEY `user` (`user`)
  197. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  198. --
  199. -- Table structure for table `tabFile Data`
  200. --
  201. DROP TABLE IF EXISTS `tabFile Data`;
  202. CREATE TABLE `tabFile Data` (
  203. `name` varchar(120) NOT NULL,
  204. `creation` datetime DEFAULT NULL,
  205. `modified` datetime DEFAULT NULL,
  206. `modified_by` varchar(40) DEFAULT NULL,
  207. `owner` varchar(40) DEFAULT NULL,
  208. `docstatus` int(1) DEFAULT '0',
  209. `parent` varchar(120) DEFAULT NULL,
  210. `parentfield` varchar(120) DEFAULT NULL,
  211. `parenttype` varchar(120) DEFAULT NULL,
  212. `idx` int(8) DEFAULT NULL,
  213. `file_name` varchar(180) DEFAULT NULL,
  214. `file_url` varchar(180) DEFAULT NULL,
  215. `module` varchar(180) DEFAULT NULL,
  216. `attached_to_name` varchar(180) DEFAULT NULL,
  217. `file_size` int(11) DEFAULT NULL,
  218. `attached_to_doctype` varchar(180) DEFAULT NULL,
  219. PRIMARY KEY (`name`),
  220. KEY `parent` (`parent`),
  221. KEY `attached_to_name` (`attached_to_name`),
  222. KEY `attached_to_doctype` (`attached_to_doctype`)
  223. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;