2016-12-02 07:38:54 +00:00
CREATE TABLE ` users_groups ` (
` gid ` int not null AUTO_INCREMENT ,
` name ` varchar ( 100 ) not null ,
` permissions ` text not null ,
Added the Social Groups plugin. This is still under construction.
Made a few improvements to the ForumStore, including bringing it's API closer in line with the other datastores, adding stubs for future subforum functionality, and improving efficiency in a few places.
The auth interface now handles all the authentication stuff.
Renamed the debug config variable to debug_mode.
Added the PluginPerms API.
Internal Errors will now dump the stack trace in the console.
Added support for installable plugins.
Refactored the routing logic so that the router now handles the common PreRoute logic(exc. /static/)
Added the CreateTable method to the query generator. It might need some tweaking to better support other database systems.
Added the same CreateTable method to the query builder.
Began work on PostgreSQL support.
Added the string-string hook type
Added the pre_render hook type.
Added the ParentID and ParentType fields to forums.
Added the get_forum_url_prefix function.
Added a more generic build_slug function.
Added the get_topic_url_prefix function.
Added the override_perms and override_forum_perms functions for bulk setting and unsetting permissions.
Added more ExtData fields in a few structs and removed them on the Perms struct as the PluginPerms API supersedes them there.
Plugins can now see the router instance.
The plugin initialisation handlers can now throw errors.
Plugins are now initialised after all the forum's subsystems are.
Refactored the unit test logic. For instance, we now use the proper .Log method rather than fmt.Println in many cases.
Sorry, we'll have to break Github's generated file detection, as the build instructions aren't working, unless I put them at the top, and they're far, far more important than getting Github to recognise the generated code as generated code.
Fixed an issue with mysql.go's _init_database() overwriting the dbpassword variable. Not a huge issue, but it is a "gotcha" for those not expecting a ':' at the start.
Fixed an issue with forum creation where the forum permissions didn't get cached.
Fixed a bug in plugin_bbcode where negative numbers in rand would crash Gosora.
Made the outputs of plugin_markdown and plugin_bbcode more compliant with the tests.
Revamped the phrase system to make it easier for us to add language pack related features in the future.
Added the WidgetMenu widget type.
Revamped the theme again. I'm experimenting to see which approach I like most.
- Excuse the little W3C rage. Some things about CSS drive me crazy :p
Tests:
Added 22 bbcode_full_parse tests.
Added 19 bbcode_regex_parse tests.
Added 27 markdown_parse tests.
Added four UserStore tests. More to come when the test database functionality is added.
Added 18 name_to_slug tests.
Hooks:
Added the pre_render hook.
Added the pre_render_forum_list hook.
Added the pre_render_view_forum hook.
Added the pre_render_topic_list hook.
Added the pre_render_view_topic hook.
Added the pre_render_profile hook.
Added the pre_render_custom_page hook.
Added the pre_render_overview hook.
Added the pre_render_create_topic hook.
Added the pre_render_account_own_edit_critical hook.
Added the pre_render_account_own_edit_avatar hook.
Added the pre_render_account_own_edit_username hook.
Added the pre_render_account_own_edit_email hook.
Added the pre_render_login hook.
Added the pre_render_register hook.
Added the pre_render_ban hook.
Added the pre_render_panel_dashboard hook.
Added the pre_render_panel_forums hook.
Added the pre_render_panel_delete_forum hook.
Added the pre_render_panel_edit_forum hook.
Added the pre_render_panel_settings hook.
Added the pre_render_panel_setting hook.
Added the pre_render_panel_plugins hook.
Added the pre_render_panel_users hook.
Added the pre_render_panel_edit_user hook.
Added the pre_render_panel_groups hook.
Added the pre_render_panel_edit_group hook.
Added the pre_render_panel_edit_group_perms hook.
Added the pre_render_panel_themes hook.
Added the pre_render_panel_mod_log hook.
Added the pre_render_error hook.
Added the pre_render_security_error hook.
Added the create_group_preappend hook.
Added the intercept_build_widgets hook.
Added the simple_forum_check_pre_perms hook.
Added the forum_check_pre_perms hook.
2017-07-09 12:06:04 +00:00
` plugin_perms ` text not null ,
2016-12-07 13:46:14 +00:00
` is_mod ` tinyint DEFAULT 0 not null ,
2016-12-02 07:38:54 +00:00
` is_admin ` tinyint DEFAULT 0 not null ,
2016-12-03 10:25:39 +00:00
` is_banned ` tinyint DEFAULT 0 not null ,
2016-12-07 09:34:09 +00:00
` tag ` varchar ( 50 ) DEFAULT ' ' not null ,
2016-12-02 07:38:54 +00:00
primary key ( ` gid ` )
2016-12-08 14:11:18 +00:00
) CHARSET = utf8mb4 COLLATE utf8mb4_general_ci ;
2016-12-02 07:38:54 +00:00
2017-01-03 07:47:31 +00:00
CREATE TABLE ` emails ` (
` email ` varchar ( 200 ) not null ,
` uid ` int not null ,
` validated ` tinyint DEFAULT 0 not null ,
` token ` varchar ( 200 ) DEFAULT ' ' not null
) ;
2016-12-03 13:45:08 +00:00
CREATE TABLE ` forums ` (
` fid ` int not null AUTO_INCREMENT ,
` name ` varchar ( 100 ) not null ,
2017-06-05 11:57:27 +00:00
` desc ` varchar ( 200 ) not null ,
2016-12-07 09:34:09 +00:00
` active ` tinyint DEFAULT 1 not null ,
2017-01-26 13:37:50 +00:00
` topicCount ` int DEFAULT 0 not null ,
2017-02-04 15:49:24 +00:00
` preset ` varchar ( 100 ) DEFAULT ' ' not null ,
2017-09-10 16:57:22 +00:00
` parentID ` int DEFAULT 0 not null , /* TODO: Add support for subforums */
Added the Social Groups plugin. This is still under construction.
Made a few improvements to the ForumStore, including bringing it's API closer in line with the other datastores, adding stubs for future subforum functionality, and improving efficiency in a few places.
The auth interface now handles all the authentication stuff.
Renamed the debug config variable to debug_mode.
Added the PluginPerms API.
Internal Errors will now dump the stack trace in the console.
Added support for installable plugins.
Refactored the routing logic so that the router now handles the common PreRoute logic(exc. /static/)
Added the CreateTable method to the query generator. It might need some tweaking to better support other database systems.
Added the same CreateTable method to the query builder.
Began work on PostgreSQL support.
Added the string-string hook type
Added the pre_render hook type.
Added the ParentID and ParentType fields to forums.
Added the get_forum_url_prefix function.
Added a more generic build_slug function.
Added the get_topic_url_prefix function.
Added the override_perms and override_forum_perms functions for bulk setting and unsetting permissions.
Added more ExtData fields in a few structs and removed them on the Perms struct as the PluginPerms API supersedes them there.
Plugins can now see the router instance.
The plugin initialisation handlers can now throw errors.
Plugins are now initialised after all the forum's subsystems are.
Refactored the unit test logic. For instance, we now use the proper .Log method rather than fmt.Println in many cases.
Sorry, we'll have to break Github's generated file detection, as the build instructions aren't working, unless I put them at the top, and they're far, far more important than getting Github to recognise the generated code as generated code.
Fixed an issue with mysql.go's _init_database() overwriting the dbpassword variable. Not a huge issue, but it is a "gotcha" for those not expecting a ':' at the start.
Fixed an issue with forum creation where the forum permissions didn't get cached.
Fixed a bug in plugin_bbcode where negative numbers in rand would crash Gosora.
Made the outputs of plugin_markdown and plugin_bbcode more compliant with the tests.
Revamped the phrase system to make it easier for us to add language pack related features in the future.
Added the WidgetMenu widget type.
Revamped the theme again. I'm experimenting to see which approach I like most.
- Excuse the little W3C rage. Some things about CSS drive me crazy :p
Tests:
Added 22 bbcode_full_parse tests.
Added 19 bbcode_regex_parse tests.
Added 27 markdown_parse tests.
Added four UserStore tests. More to come when the test database functionality is added.
Added 18 name_to_slug tests.
Hooks:
Added the pre_render hook.
Added the pre_render_forum_list hook.
Added the pre_render_view_forum hook.
Added the pre_render_topic_list hook.
Added the pre_render_view_topic hook.
Added the pre_render_profile hook.
Added the pre_render_custom_page hook.
Added the pre_render_overview hook.
Added the pre_render_create_topic hook.
Added the pre_render_account_own_edit_critical hook.
Added the pre_render_account_own_edit_avatar hook.
Added the pre_render_account_own_edit_username hook.
Added the pre_render_account_own_edit_email hook.
Added the pre_render_login hook.
Added the pre_render_register hook.
Added the pre_render_ban hook.
Added the pre_render_panel_dashboard hook.
Added the pre_render_panel_forums hook.
Added the pre_render_panel_delete_forum hook.
Added the pre_render_panel_edit_forum hook.
Added the pre_render_panel_settings hook.
Added the pre_render_panel_setting hook.
Added the pre_render_panel_plugins hook.
Added the pre_render_panel_users hook.
Added the pre_render_panel_edit_user hook.
Added the pre_render_panel_groups hook.
Added the pre_render_panel_edit_group hook.
Added the pre_render_panel_edit_group_perms hook.
Added the pre_render_panel_themes hook.
Added the pre_render_panel_mod_log hook.
Added the pre_render_error hook.
Added the pre_render_security_error hook.
Added the create_group_preappend hook.
Added the intercept_build_widgets hook.
Added the simple_forum_check_pre_perms hook.
Added the forum_check_pre_perms hook.
2017-07-09 12:06:04 +00:00
` parentType ` varchar ( 50 ) DEFAULT ' ' not null ,
2016-12-03 13:45:08 +00:00
` lastTopic ` varchar ( 100 ) DEFAULT ' ' not null ,
` lastTopicID ` int DEFAULT 0 not null ,
` lastReplyer ` varchar ( 100 ) DEFAULT ' ' not null ,
` lastReplyerID ` int DEFAULT 0 not null ,
` lastTopicTime ` datetime not null ,
primary key ( ` fid ` )
2016-12-08 14:11:18 +00:00
) CHARSET = utf8mb4 COLLATE utf8mb4_general_ci ;
2016-12-03 13:45:08 +00:00
2017-01-31 05:13:38 +00:00
CREATE TABLE ` forums_permissions ` (
` fid ` int not null ,
` gid ` int not null ,
2017-02-04 06:19:55 +00:00
` preset ` varchar ( 100 ) DEFAULT ' ' not null ,
2017-06-06 08:47:33 +00:00
` permissions ` text not null ,
primary key ( fid , gid )
2017-01-31 05:13:38 +00:00
) ;
2016-12-02 07:38:54 +00:00
CREATE TABLE ` topics ` (
` tid ` int not null AUTO_INCREMENT ,
` title ` varchar ( 100 ) not null ,
` content ` text not null ,
2016-12-03 05:00:21 +00:00
` parsed_content ` text not null ,
2016-12-02 07:38:54 +00:00
` createdAt ` datetime not null ,
` lastReplyAt ` datetime not null ,
2017-08-06 15:22:18 +00:00
` lastReplyBy ` int not null ,
2016-12-02 07:38:54 +00:00
` createdBy ` int not null ,
` is_closed ` tinyint DEFAULT 0 not null ,
` sticky ` tinyint DEFAULT 0 not null ,
2017-02-05 14:41:53 +00:00
` parentID ` int DEFAULT 2 not null ,
2016-12-18 12:56:06 +00:00
` ipaddress ` varchar ( 200 ) DEFAULT ' 0.0.0.0.0 ' not null ,
2017-01-21 18:16:27 +00:00
` postCount ` int DEFAULT 1 not null ,
2017-02-10 13:39:13 +00:00
` likeCount ` int DEFAULT 0 not null ,
` words ` int DEFAULT 0 not null ,
2017-06-05 11:57:27 +00:00
` css_class ` varchar ( 100 ) DEFAULT ' ' not null ,
2016-12-11 16:06:17 +00:00
` data ` varchar ( 200 ) DEFAULT ' ' not null ,
2016-12-02 07:38:54 +00:00
primary key ( ` tid ` )
2016-12-08 14:11:18 +00:00
) CHARSET = utf8mb4 COLLATE utf8mb4_general_ci ;
2016-12-02 07:38:54 +00:00
CREATE TABLE ` replies ` (
` rid ` int not null AUTO_INCREMENT ,
` tid ` int not null ,
` content ` text not null ,
2016-12-03 05:00:21 +00:00
` parsed_content ` text not null ,
2016-12-02 07:38:54 +00:00
` createdAt ` datetime not null ,
` createdBy ` int not null ,
` lastEdit ` int not null ,
2017-07-29 10:36:39 +00:00
` lastEditBy ` int not null , /* Do we need this? */
/* `editIndex` int not null, */ /* For append edits, e.g. auto-merges? Is this enough for this feature? */
` lastUpdated ` datetime not null ,
2016-12-18 12:56:06 +00:00
` ipaddress ` varchar ( 200 ) DEFAULT ' 0.0.0.0.0 ' not null ,
2017-02-10 13:39:13 +00:00
` likeCount ` int DEFAULT 0 not null ,
` words ` int DEFAULT 1 not null ,
2017-04-02 13:00:40 +00:00
` actionType ` varchar ( 20 ) DEFAULT ' ' not null ,
2016-12-02 07:38:54 +00:00
primary key ( ` rid ` )
2016-12-08 14:11:18 +00:00
) CHARSET = utf8mb4 COLLATE utf8mb4_general_ci ;
2016-12-02 07:38:54 +00:00
2017-03-15 08:34:14 +00:00
CREATE TABLE ` revisions ` (
` index ` int not null ,
` content ` text not null ,
` contentID ` int not null ,
` contentType ` varchar ( 100 ) DEFAULT ' replies ' not null
) CHARSET = utf8mb4 COLLATE utf8mb4_general_ci ;
2016-12-07 09:34:09 +00:00
CREATE TABLE ` users_replies ` (
` rid ` int not null AUTO_INCREMENT ,
` uid ` int not null ,
` content ` text not null ,
` parsed_content ` text not null ,
` createdAt ` datetime not null ,
` createdBy ` int not null ,
` lastEdit ` int not null ,
` lastEditBy ` int not null ,
2017-06-14 07:09:44 +00:00
` ipaddress ` varchar ( 200 ) DEFAULT ' 0.0.0.0.0 ' not null ,
2016-12-07 09:34:09 +00:00
primary key ( ` rid ` )
2016-12-08 14:11:18 +00:00
) CHARSET = utf8mb4 COLLATE utf8mb4_general_ci ;
2016-12-07 09:34:09 +00:00
2017-01-10 06:51:28 +00:00
CREATE TABLE ` likes ` (
2017-01-12 02:55:08 +00:00
` weight ` tinyint DEFAULT 1 not null ,
2017-02-28 09:27:28 +00:00
/* `type` tinyint not null, /* Regular Post: 1, Big Post: 2, Mega Post: 3, etc. */
2017-01-10 06:51:28 +00:00
` targetItem ` int not null ,
2017-02-10 13:39:13 +00:00
` targetType ` varchar ( 50 ) DEFAULT ' replies ' not null ,
2017-01-10 06:51:28 +00:00
` sentBy ` int not null ,
` recalc ` tinyint DEFAULT 0 not null
) ;
2017-02-28 09:27:28 +00:00
CREATE TABLE ` activity_stream_matches ` (
` watcher ` int not null ,
` asid ` int not null
) ;
CREATE TABLE ` activity_stream ` (
` asid ` int not null AUTO_INCREMENT ,
` actor ` int not null , /* the one doing the act */
` targetUser ` int not null , /* the user who created the item the actor is acting on, some items like forums may lack a targetUser field */
` event ` varchar ( 50 ) not null , /* mention, like, reply (as in the act of replying to an item, not the reply item type, you can "reply" to a forum by making a topic in it), friend_invite */
` elementType ` varchar ( 50 ) not null , /* topic, post (calling it post here to differentiate it from the 'reply' event), forum, user */
` elementID ` int not null , /* the ID of the element being acted upon */
primary key ( ` asid ` )
) ;
CREATE TABLE ` activity_subscriptions ` (
` user ` int not null ,
2017-03-03 16:28:49 +00:00
` targetID ` int not null , /* the ID of the element being acted upon */
` targetType ` varchar ( 50 ) not null , /* topic, post (calling it post here to differentiate it from the 'reply' event), forum, user */
2017-03-05 07:53:41 +00:00
` level ` tinyint DEFAULT 0 not null /* 0: Mentions (aka the global default for any post), 1: Replies To You, 2: All Replies */
2017-02-28 09:27:28 +00:00
) ;
2017-07-12 11:05:18 +00:00
/* Due to MySQL's design, we have to drop the unique keys for table settings, plugins, and themes down from 200 to 180 or it will error */
2016-12-09 13:46:29 +00:00
CREATE TABLE ` settings ` (
2017-07-12 11:05:18 +00:00
` name ` varchar ( 180 ) not null ,
2016-12-09 13:46:29 +00:00
` content ` varchar ( 250 ) not null ,
` type ` varchar ( 50 ) not null ,
2016-12-16 10:37:42 +00:00
` constraints ` varchar ( 200 ) DEFAULT ' ' not null ,
2016-12-09 13:46:29 +00:00
unique ( ` name ` )
) ;
2016-12-11 16:06:17 +00:00
CREATE TABLE ` plugins ` (
2017-07-12 11:05:18 +00:00
` uname ` varchar ( 180 ) not null ,
2016-12-11 16:06:17 +00:00
` active ` tinyint DEFAULT 0 not null ,
Added the Social Groups plugin. This is still under construction.
Made a few improvements to the ForumStore, including bringing it's API closer in line with the other datastores, adding stubs for future subforum functionality, and improving efficiency in a few places.
The auth interface now handles all the authentication stuff.
Renamed the debug config variable to debug_mode.
Added the PluginPerms API.
Internal Errors will now dump the stack trace in the console.
Added support for installable plugins.
Refactored the routing logic so that the router now handles the common PreRoute logic(exc. /static/)
Added the CreateTable method to the query generator. It might need some tweaking to better support other database systems.
Added the same CreateTable method to the query builder.
Began work on PostgreSQL support.
Added the string-string hook type
Added the pre_render hook type.
Added the ParentID and ParentType fields to forums.
Added the get_forum_url_prefix function.
Added a more generic build_slug function.
Added the get_topic_url_prefix function.
Added the override_perms and override_forum_perms functions for bulk setting and unsetting permissions.
Added more ExtData fields in a few structs and removed them on the Perms struct as the PluginPerms API supersedes them there.
Plugins can now see the router instance.
The plugin initialisation handlers can now throw errors.
Plugins are now initialised after all the forum's subsystems are.
Refactored the unit test logic. For instance, we now use the proper .Log method rather than fmt.Println in many cases.
Sorry, we'll have to break Github's generated file detection, as the build instructions aren't working, unless I put them at the top, and they're far, far more important than getting Github to recognise the generated code as generated code.
Fixed an issue with mysql.go's _init_database() overwriting the dbpassword variable. Not a huge issue, but it is a "gotcha" for those not expecting a ':' at the start.
Fixed an issue with forum creation where the forum permissions didn't get cached.
Fixed a bug in plugin_bbcode where negative numbers in rand would crash Gosora.
Made the outputs of plugin_markdown and plugin_bbcode more compliant with the tests.
Revamped the phrase system to make it easier for us to add language pack related features in the future.
Added the WidgetMenu widget type.
Revamped the theme again. I'm experimenting to see which approach I like most.
- Excuse the little W3C rage. Some things about CSS drive me crazy :p
Tests:
Added 22 bbcode_full_parse tests.
Added 19 bbcode_regex_parse tests.
Added 27 markdown_parse tests.
Added four UserStore tests. More to come when the test database functionality is added.
Added 18 name_to_slug tests.
Hooks:
Added the pre_render hook.
Added the pre_render_forum_list hook.
Added the pre_render_view_forum hook.
Added the pre_render_topic_list hook.
Added the pre_render_view_topic hook.
Added the pre_render_profile hook.
Added the pre_render_custom_page hook.
Added the pre_render_overview hook.
Added the pre_render_create_topic hook.
Added the pre_render_account_own_edit_critical hook.
Added the pre_render_account_own_edit_avatar hook.
Added the pre_render_account_own_edit_username hook.
Added the pre_render_account_own_edit_email hook.
Added the pre_render_login hook.
Added the pre_render_register hook.
Added the pre_render_ban hook.
Added the pre_render_panel_dashboard hook.
Added the pre_render_panel_forums hook.
Added the pre_render_panel_delete_forum hook.
Added the pre_render_panel_edit_forum hook.
Added the pre_render_panel_settings hook.
Added the pre_render_panel_setting hook.
Added the pre_render_panel_plugins hook.
Added the pre_render_panel_users hook.
Added the pre_render_panel_edit_user hook.
Added the pre_render_panel_groups hook.
Added the pre_render_panel_edit_group hook.
Added the pre_render_panel_edit_group_perms hook.
Added the pre_render_panel_themes hook.
Added the pre_render_panel_mod_log hook.
Added the pre_render_error hook.
Added the pre_render_security_error hook.
Added the create_group_preappend hook.
Added the intercept_build_widgets hook.
Added the simple_forum_check_pre_perms hook.
Added the forum_check_pre_perms hook.
2017-07-09 12:06:04 +00:00
` installed ` tinyint DEFAULT 0 not null ,
2016-12-11 16:06:17 +00:00
unique ( ` uname ` )
) ;
2017-01-01 15:45:43 +00:00
CREATE TABLE ` themes ` (
2017-07-12 11:05:18 +00:00
` uname ` varchar ( 180 ) not null ,
2017-01-01 15:45:43 +00:00
` default ` tinyint DEFAULT 0 not null ,
unique ( ` uname ` )
) ;
2017-06-19 08:06:54 +00:00
CREATE TABLE ` widgets ` (
` position ` int not null ,
` side ` varchar ( 100 ) not null ,
` type ` varchar ( 100 ) not null ,
` active ` tinyint ( 1 ) DEFAULT 0 not null ,
` location ` varchar ( 100 ) not null ,
` data ` text DEFAULT ' ' not null
) ;
2017-04-05 14:05:37 +00:00
CREATE TABLE ` moderation_logs ` (
` action ` varchar ( 100 ) not null ,
` elementID ` int not null ,
` elementType ` varchar ( 100 ) not null ,
` ipaddress ` varchar ( 200 ) not null ,
2017-04-06 17:37:32 +00:00
` actorID ` int not null ,
` doneAt ` datetime not null
2017-04-05 14:05:37 +00:00
) ;
CREATE TABLE ` administration_logs ` (
` action ` varchar ( 100 ) not null ,
` elementID ` int not null ,
` elementType ` varchar ( 100 ) not null ,
` ipaddress ` varchar ( 200 ) not null ,
2017-04-06 17:37:32 +00:00
` actorID ` int not null ,
` doneAt ` datetime not null
2017-04-05 14:05:37 +00:00
) ;
2017-09-10 16:57:22 +00:00
INSERT INTO sync ( ` last_update ` ) VALUES ( UTC_TIMESTAMP ( ) ) ;
2017-06-14 09:55:47 +00:00
2016-12-09 13:46:29 +00:00
INSERT INTO settings ( ` name ` , ` content ` , ` type ` ) VALUES ( ' url_tags ' , ' 1 ' , ' bool ' ) ;
2017-01-10 06:51:28 +00:00
INSERT INTO settings ( ` name ` , ` content ` , ` type ` , ` constraints ` ) VALUES ( ' activation_type ' , ' 1 ' , ' list ' , ' 1-3 ' ) ;
2017-06-10 07:58:15 +00:00
INSERT INTO settings ( ` name ` , ` content ` , ` type ` ) VALUES ( ' bigpost_min_words ' , ' 250 ' , ' int ' ) ;
INSERT INTO settings ( ` name ` , ` content ` , ` type ` ) VALUES ( ' megapost_min_words ' , ' 1000 ' , ' int ' ) ;
2017-01-01 15:45:43 +00:00
INSERT INTO themes ( ` uname ` , ` default ` ) VALUES ( ' tempra-simple ' , 1 ) ;
2017-01-03 07:47:31 +00:00
INSERT INTO emails ( ` email ` , ` uid ` , ` validated ` ) VALUES ( ' admin@localhost ' , 1 , 1 ) ;
2016-12-08 14:11:18 +00:00
2016-12-21 02:30:32 +00:00
/*
The Permissions :
BanUsers
ActivateUsers
2016-12-23 12:35:22 +00:00
EditUser
EditUserEmail
EditUserPassword
EditUserGroup
EditUserGroupSuperMod
EditUserGroupAdmin
2017-03-18 07:23:02 +00:00
EditGroup
EditGroupLocalPerms
EditGroupGlobalPerms
EditGroupSuperMod
EditGroupAdmin
2016-12-21 02:30:32 +00:00
ManageForums
EditSettings
2017-01-01 15:45:43 +00:00
ManageThemes
2016-12-21 02:30:32 +00:00
ManagePlugins
2017-04-12 10:10:36 +00:00
ViewAdminLogs
2016-12-21 02:30:32 +00:00
ViewIPs
ViewTopic
2017-02-10 13:39:13 +00:00
LikeItem
2016-12-21 02:30:32 +00:00
CreateTopic
EditTopic
DeleteTopic
CreateReply
EditReply
DeleteReply
PinTopic
CloseTopic
* /
Added the Social Groups plugin. This is still under construction.
Made a few improvements to the ForumStore, including bringing it's API closer in line with the other datastores, adding stubs for future subforum functionality, and improving efficiency in a few places.
The auth interface now handles all the authentication stuff.
Renamed the debug config variable to debug_mode.
Added the PluginPerms API.
Internal Errors will now dump the stack trace in the console.
Added support for installable plugins.
Refactored the routing logic so that the router now handles the common PreRoute logic(exc. /static/)
Added the CreateTable method to the query generator. It might need some tweaking to better support other database systems.
Added the same CreateTable method to the query builder.
Began work on PostgreSQL support.
Added the string-string hook type
Added the pre_render hook type.
Added the ParentID and ParentType fields to forums.
Added the get_forum_url_prefix function.
Added a more generic build_slug function.
Added the get_topic_url_prefix function.
Added the override_perms and override_forum_perms functions for bulk setting and unsetting permissions.
Added more ExtData fields in a few structs and removed them on the Perms struct as the PluginPerms API supersedes them there.
Plugins can now see the router instance.
The plugin initialisation handlers can now throw errors.
Plugins are now initialised after all the forum's subsystems are.
Refactored the unit test logic. For instance, we now use the proper .Log method rather than fmt.Println in many cases.
Sorry, we'll have to break Github's generated file detection, as the build instructions aren't working, unless I put them at the top, and they're far, far more important than getting Github to recognise the generated code as generated code.
Fixed an issue with mysql.go's _init_database() overwriting the dbpassword variable. Not a huge issue, but it is a "gotcha" for those not expecting a ':' at the start.
Fixed an issue with forum creation where the forum permissions didn't get cached.
Fixed a bug in plugin_bbcode where negative numbers in rand would crash Gosora.
Made the outputs of plugin_markdown and plugin_bbcode more compliant with the tests.
Revamped the phrase system to make it easier for us to add language pack related features in the future.
Added the WidgetMenu widget type.
Revamped the theme again. I'm experimenting to see which approach I like most.
- Excuse the little W3C rage. Some things about CSS drive me crazy :p
Tests:
Added 22 bbcode_full_parse tests.
Added 19 bbcode_regex_parse tests.
Added 27 markdown_parse tests.
Added four UserStore tests. More to come when the test database functionality is added.
Added 18 name_to_slug tests.
Hooks:
Added the pre_render hook.
Added the pre_render_forum_list hook.
Added the pre_render_view_forum hook.
Added the pre_render_topic_list hook.
Added the pre_render_view_topic hook.
Added the pre_render_profile hook.
Added the pre_render_custom_page hook.
Added the pre_render_overview hook.
Added the pre_render_create_topic hook.
Added the pre_render_account_own_edit_critical hook.
Added the pre_render_account_own_edit_avatar hook.
Added the pre_render_account_own_edit_username hook.
Added the pre_render_account_own_edit_email hook.
Added the pre_render_login hook.
Added the pre_render_register hook.
Added the pre_render_ban hook.
Added the pre_render_panel_dashboard hook.
Added the pre_render_panel_forums hook.
Added the pre_render_panel_delete_forum hook.
Added the pre_render_panel_edit_forum hook.
Added the pre_render_panel_settings hook.
Added the pre_render_panel_setting hook.
Added the pre_render_panel_plugins hook.
Added the pre_render_panel_users hook.
Added the pre_render_panel_edit_user hook.
Added the pre_render_panel_groups hook.
Added the pre_render_panel_edit_group hook.
Added the pre_render_panel_edit_group_perms hook.
Added the pre_render_panel_themes hook.
Added the pre_render_panel_mod_log hook.
Added the pre_render_error hook.
Added the pre_render_security_error hook.
Added the create_group_preappend hook.
Added the intercept_build_widgets hook.
Added the simple_forum_check_pre_perms hook.
Added the forum_check_pre_perms hook.
2017-07-09 12:06:04 +00:00
INSERT INTO users_groups ( ` name ` , ` permissions ` , ` plugin_perms ` , ` is_mod ` , ` is_admin ` , ` tag ` ) VALUES ( ' Administrator ' , ' {"BanUsers":true,"ActivateUsers":true,"EditUser":true,"EditUserEmail":true,"EditUserPassword":true,"EditUserGroup":true,"EditUserGroupSuperMod":true,"EditUserGroupAdmin":false,"EditGroup":true,"EditGroupLocalPerms":true,"EditGroupGlobalPerms":true,"EditGroupSuperMod":true,"EditGroupAdmin":false,"ManageForums":true,"EditSettings":true,"ManageThemes":true,"ManagePlugins":true,"ViewAdminLogs":true,"ViewIPs":true,"ViewTopic":true,"LikeItem":true,"CreateTopic":true,"EditTopic":true,"DeleteTopic":true,"CreateReply":true,"EditReply":true,"DeleteReply":true,"PinTopic":true,"CloseTopic":true} ' , ' {} ' , 1 , 1 , " Admin " ) ;
INSERT INTO users_groups ( ` name ` , ` permissions ` , ` plugin_perms ` , ` is_mod ` , ` tag ` ) VALUES ( ' Moderator ' , ' {"BanUsers":true,"ActivateUsers":false,"EditUser":true,"EditUserEmail":false,"EditUserGroup":true,"ViewIPs":true,"ViewTopic":true,"LikeItem":true,"CreateTopic":true,"EditTopic":true,"DeleteTopic":true,"CreateReply":true,"EditReply":true,"DeleteReply":true,"PinTopic":true,"CloseTopic":true} ' , ' {} ' , 1 , " Mod " ) ;
INSERT INTO users_groups ( ` name ` , ` permissions ` , ` plugin_perms ` ) VALUES ( ' Member ' , ' {"ViewTopic":true,"LikeItem":true,"CreateTopic":true,"CreateReply":true} ' , ' {} ' ) ;
INSERT INTO users_groups ( ` name ` , ` permissions ` , ` plugin_perms ` , ` is_banned ` ) VALUES ( ' Banned ' , ' {"ViewTopic":true} ' , ' {} ' , 1 ) ;
INSERT INTO users_groups ( ` name ` , ` permissions ` , ` plugin_perms ` ) VALUES ( ' Awaiting Activation ' , ' {"ViewTopic":true} ' , ' {} ' ) ;
INSERT INTO users_groups ( ` name ` , ` permissions ` , ` plugin_perms ` , ` tag ` ) VALUES ( ' Not Loggedin ' , ' {"ViewTopic":true} ' , ' {} ' , ' Guest ' ) ;
2016-12-08 14:11:18 +00:00
2017-01-26 13:37:50 +00:00
INSERT INTO forums ( ` name ` , ` active ` ) VALUES ( ' Reports ' , 0 ) ;
2017-08-18 12:16:56 +00:00
INSERT INTO forums ( ` name ` , ` lastTopicTime ` , ` lastTopicID ` , ` lastReplyer ` , ` lastReplyerID ` , ` lastTopic ` ) VALUES ( ' General ' , UTC_TIMESTAMP ( ) , 1 , " Admin " , 1 , ' Test Topic ' ) ;
2017-01-31 05:13:38 +00:00
INSERT INTO forums_permissions ( ` gid ` , ` fid ` , ` permissions ` ) VALUES ( 1 , 1 , ' {"ViewTopic":true,"CreateReply":true,"CreateTopic":true,"PinTopic":true,"CloseTopic":true} ' ) ;
INSERT INTO forums_permissions ( ` gid ` , ` fid ` , ` permissions ` ) VALUES ( 2 , 1 , ' {"ViewTopic":true,"CreateReply":true,"CloseTopic":true} ' ) ;
INSERT INTO forums_permissions ( ` gid ` , ` fid ` , ` permissions ` ) VALUES ( 3 , 1 , ' {} ' ) ;
INSERT INTO forums_permissions ( ` gid ` , ` fid ` , ` permissions ` ) VALUES ( 4 , 1 , ' {} ' ) ;
INSERT INTO forums_permissions ( ` gid ` , ` fid ` , ` permissions ` ) VALUES ( 5 , 1 , ' {} ' ) ;
INSERT INTO forums_permissions ( ` gid ` , ` fid ` , ` permissions ` ) VALUES ( 6 , 1 , ' {} ' ) ;
2017-08-06 15:22:18 +00:00
INSERT INTO topics ( ` title ` , ` content ` , ` createdAt ` , ` lastReplyAt ` , ` lastReplyBy ` , ` createdBy ` , ` parentID ` )
VALUES ( ' Test Topic ' , ' A topic automatically generated by the software. ' , UTC_TIMESTAMP ( ) , UTC_TIMESTAMP ( ) , 1 , 1 , 2 ) ;
2016-12-02 07:38:54 +00:00
2017-06-05 11:57:27 +00:00
INSERT INTO replies ( ` tid ` , ` content ` , ` createdAt ` , ` createdBy ` , ` lastEdit ` , ` lastEditBy ` )
2017-07-17 10:23:42 +00:00
VALUES ( 1 , ' Reply 1 ' , UTC_TIMESTAMP ( ) , 1 , 0 , 0 ) ;