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.
 
 
 
 
 
 

246 lines
7.7 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. `plugin` varchar(180) DEFAULT NULL,
  102. `autoname` varchar(180) DEFAULT NULL,
  103. `name_case` varchar(180) DEFAULT NULL,
  104. `description` text,
  105. `colour` varchar(180) DEFAULT NULL,
  106. `read_only` int(1) DEFAULT NULL,
  107. `in_create` int(1) DEFAULT NULL,
  108. `show_in_menu` int(1) DEFAULT NULL,
  109. `menu_index` int(11) DEFAULT NULL,
  110. `parent_node` varchar(180) DEFAULT NULL,
  111. `smallicon` varchar(180) DEFAULT NULL,
  112. `allow_print` int(1) DEFAULT NULL,
  113. `allow_email` int(1) DEFAULT NULL,
  114. `allow_copy` int(1) DEFAULT NULL,
  115. `allow_rename` int(1) DEFAULT NULL,
  116. `allow_import` int(1) DEFAULT NULL,
  117. `hide_toolbar` int(1) DEFAULT NULL,
  118. `hide_heading` int(1) DEFAULT NULL,
  119. `allow_attach` int(1) DEFAULT NULL,
  120. `use_template` int(1) DEFAULT NULL,
  121. `max_attachments` int(11) DEFAULT NULL,
  122. `section_style` varchar(180) DEFAULT NULL,
  123. `client_script` mediumtext,
  124. `client_script_core` mediumtext,
  125. `server_code` mediumtext,
  126. `server_code_core` mediumtext,
  127. `server_code_compiled` mediumtext,
  128. `client_string` mediumtext,
  129. `server_code_error` varchar(180) DEFAULT NULL,
  130. `print_outline` varchar(180) DEFAULT NULL,
  131. `dt_template` mediumtext,
  132. `is_transaction_doc` int(1) DEFAULT NULL,
  133. `change_log` mediumtext,
  134. `read_only_onload` int(1) DEFAULT NULL,
  135. `allow_trash` int(1) DEFAULT NULL,
  136. `in_dialog` int(1) DEFAULT NULL,
  137. `document_type` varchar(180) DEFAULT NULL,
  138. `icon` varchar(180) DEFAULT NULL,
  139. `tag_fields` varchar(180) DEFAULT NULL,
  140. `subject` varchar(180) DEFAULT NULL,
  141. `_last_update` varchar(32) DEFAULT NULL,
  142. `default_print_format` varchar(180) DEFAULT NULL,
  143. `is_submittable` int(1) DEFAULT NULL,
  144. `_user_tags` varchar(180) DEFAULT NULL,
  145. `custom` int(1) DEFAULT NULL,
  146. PRIMARY KEY (`name`),
  147. KEY `parent` (`parent`)
  148. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  149. /*!40101 SET character_set_client = @saved_cs_client */;
  150. --
  151. -- Table structure for table `tabSeries`
  152. --
  153. DROP TABLE IF EXISTS `tabSeries`;
  154. /*!40101 SET @saved_cs_client = @@character_set_client */;
  155. /*!40101 SET character_set_client = utf8 */;
  156. CREATE TABLE `tabSeries` (
  157. `name` varchar(100) DEFAULT NULL,
  158. `current` int(10) DEFAULT NULL
  159. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  160. /*!40101 SET character_set_client = @saved_cs_client */;
  161. --
  162. -- Table structure for table `tabSessions`
  163. --
  164. DROP TABLE IF EXISTS `tabSessions`;
  165. /*!40101 SET @saved_cs_client = @@character_set_client */;
  166. /*!40101 SET character_set_client = utf8 */;
  167. CREATE TABLE `tabSessions` (
  168. `user` varchar(40) DEFAULT NULL,
  169. `sid` varchar(120) DEFAULT NULL,
  170. `sessiondata` longtext,
  171. `ipaddress` varchar(16) DEFAULT NULL,
  172. `lastupdate` datetime DEFAULT NULL,
  173. `status` varchar(20) DEFAULT NULL,
  174. KEY `sid` (`sid`)
  175. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  176. /*!40101 SET character_set_client = @saved_cs_client */;
  177. --
  178. -- Table structure for table `tabSingles`
  179. --
  180. DROP TABLE IF EXISTS `tabSingles`;
  181. /*!40101 SET @saved_cs_client = @@character_set_client */;
  182. /*!40101 SET character_set_client = utf8 */;
  183. CREATE TABLE `tabSingles` (
  184. `doctype` varchar(40) DEFAULT NULL,
  185. `field` varchar(40) DEFAULT NULL,
  186. `value` text,
  187. KEY `singles_doctype_field_index` (`doctype`, `field`)
  188. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  189. --
  190. -- Table structure for table `__Auth`
  191. --
  192. DROP TABLE IF EXISTS `__Auth`;
  193. /*!40101 SET @saved_cs_client = @@character_set_client */;
  194. /*!40101 SET character_set_client = utf8 */;
  195. CREATE TABLE `__Auth` (
  196. `user` VARCHAR(180) NOT NULL PRIMARY KEY,
  197. `password` VARCHAR(180) NOT NULL,
  198. KEY `user` (`user`)
  199. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
  200. --
  201. -- Table structure for table `tabFile Data`
  202. --
  203. DROP TABLE IF EXISTS `tabFile Data`;
  204. CREATE TABLE `tabFile Data` (
  205. `name` varchar(120) NOT NULL,
  206. `creation` datetime DEFAULT NULL,
  207. `modified` datetime DEFAULT NULL,
  208. `modified_by` varchar(40) DEFAULT NULL,
  209. `owner` varchar(40) DEFAULT NULL,
  210. `docstatus` int(1) DEFAULT '0',
  211. `parent` varchar(120) DEFAULT NULL,
  212. `parentfield` varchar(120) DEFAULT NULL,
  213. `parenttype` varchar(120) DEFAULT NULL,
  214. `idx` int(8) DEFAULT NULL,
  215. `file_name` varchar(180) DEFAULT NULL,
  216. `file_url` varchar(180) DEFAULT NULL,
  217. `module` varchar(180) DEFAULT NULL,
  218. `attached_to_name` varchar(180) DEFAULT NULL,
  219. `file_size` int(11) DEFAULT NULL,
  220. `attached_to_doctype` varchar(180) DEFAULT NULL,
  221. PRIMARY KEY (`name`),
  222. KEY `parent` (`parent`),
  223. KEY `attached_to_name` (`attached_to_name`),
  224. KEY `attached_to_doctype` (`attached_to_doctype`)
  225. ) ENGINE=InnoDB DEFAULT CHARSET=utf8;