Commit Graph

196 Commits

Author SHA1 Message Date
Sheldan
3fa5edf67a addressed sonar code smells 2020-05-27 19:38:43 +02:00
Sheldan
175a92408c addressed some sonar issues 2020-05-27 18:41:31 +02:00
Sheldan
10b3b647e3 fixed build 2020-05-27 15:59:21 +02:00
Sheldan
de4eeeacca added serverInfo help
added userInfo command
added offsetDateTime to the custom date formatter
2020-05-27 15:10:54 +02:00
Sheldan
a682428028 merged exceptions for setup steps to one common exception, which contains the concrete exception
added exception handling for incorrect mod mail category id
2020-05-26 11:48:12 +02:00
Sheldan
213f42ffbd added current values to post post target
added support for custom setup steps for each feature
added mod mail category setup step
2020-05-25 23:11:44 +02:00
Sheldan
3714fd2582 added default value handling to setup wizard
added table to store the default values of the whole system, to not require the property files
added ability to cancel setup wizard
2020-05-22 20:13:24 +02:00
Sheldan
992357b2cb added setup command which includes an interactive process in order to setup features
the current supported features are post targets and system config
the wizard includes a summary step where the user can confirm the changes
removed some unnecessary validators, which were basically just validating the system config from some features
fixed post target name
2020-05-22 17:25:44 +02:00
Sheldan
e2f71ef7a3 added possibility to define the text which is used for notifying the user when closing a thread 2020-05-20 01:13:45 +02:00
Sheldan
1e667686d3 introduced *all* intents abstracto requires in order to function...., because with the new version the guild members intent was not used, and various features were not functioning
added initial message also to be send
2020-05-20 00:31:43 +02:00
Sheldan
3bb6620cbe added a condition to check for the correct feature mode
merged mod mail logging back into the mod mail feature and set it up as a mode
2020-05-16 22:40:11 +02:00
Sheldan
d2264937b2 added the concept of feature modes, these are the modes in which a feature can operate, its basically a separate way how the feature does it jobs, for example mod mail might log or it might not. bot of these are different modes
refactored services for feature flag and feature config
2020-05-16 20:55:13 +02:00
Sheldan
cd80d27795 added command to completely silently close a mod mail thread (no logging, no notification)
this is part of the mod mai logging feature, because without logging the normal closeSilently behaves the same way by default
2020-05-16 11:06:48 +02:00
Sheldan
ddb540ccfe added columns for tracking created/updated 2020-05-16 00:21:53 +02:00
Sheldan
82c63d4825 added validation for emotes to features 2020-05-15 20:31:16 +02:00
Sheldan
b984129df6 added check for existing system config when a feature is enabled 2020-05-15 18:53:51 +02:00
Sheldan
f11232de05 moved post targets to an enum, in order to have more type safety, this might be changed in the future
added validation check when a feature is enabled, in order to notify which configuration is missing for this feature to function properly
2020-05-15 17:43:39 +02:00
Sheldan
e4efc26740 added templates parameters for help 2020-05-14 18:53:09 +02:00
Sheldan
b591ae497d added more specific exceptions 2020-05-13 23:46:58 +02:00
Sheldan
cb1abaed7d moved some more templates to template config
fixed usage of post target exceptions
2020-05-13 17:45:55 +02:00
Sheldan
80505d1014 migrated some exceptions to use templates
fixed missed hard coded value in template
fixed listing of channels in channel groups
fixed template loading
2020-05-13 17:04:21 +02:00
Sheldan
c429aa882b refactored channel exception to have a unified interface to form the exception message
replaced getOne with findById in order to get optionals and handle those
some places still have the general abstracto run time exception
2020-05-13 12:49:08 +02:00
Sheldan
5755d033eb fixed command and feature mapping
added a bunch of java doc to moderation interface
added check in case the text channel on the server was deleted while the mod mail thread was still open
This now returns an error to the user side and prompts to message the bot again in order to create a new mod mail thread
2020-05-12 22:44:44 +02:00
Sheldan
b13309a026 Split the logging of mod mail threads to a separate feature
fixed the default values of features in properties files
2020-05-11 16:15:02 +02:00
Sheldan
9197fe0268 removed decay feature boolean from myWarnings, because only automatic decay is an additional feature
fixed post target for kicking
fixed casing for mod mail post targets
added initial version of the ascii doctor documentation
2020-05-11 15:00:00 +02:00
Sheldan
ba032194ce added bean configuration for event waiter to be used for paginator
fixed initial setup for server
fixed command in a server configuration
2020-05-10 20:29:32 +02:00
Sheldan
aba98ef0c6 fixed jpa annotations for one to many 2020-05-09 16:21:48 +02:00
Sheldan
da8fea34da replaced a bunch of places where the database loaded objects were referenced across threads, this might have lead to problems when lazy loading them
fixed starboard post template
fixed starboard post deletion
2020-05-09 16:15:07 +02:00
Sheldan
8db1cead57 fixed some catch blocks to include all exceptions
fixed message sending undo action
2020-05-09 01:32:09 +02:00
Sheldan
0e7add826b added undo logic to mod mail logging
added some more logging when closing the mod mail thread
2020-05-09 01:10:46 +02:00
Sheldan
379db1ff73 added concept of undo actions
used undo actions to delete the mod mail thread channel, if it already reached a certain state when initially setting up the mod mail thread
2020-05-09 00:19:19 +02:00
Sheldan
271ea7364a fixed initial setup for mod mail category
fixed setup for locking
added exception message in case the modmail post target is not defined
2020-05-08 23:22:23 +02:00
Sheldan
d1f307837d added initial setting for the mod mail category in a listener, so it can be configured via command 2020-05-08 18:27:04 +02:00
Sheldan
1c67d96887 added subscribe and unsubscribe command 2020-05-08 17:02:22 +02:00
Sheldan
5ace3e2abb restructured templates for mod mail a bit 2020-05-08 12:27:08 +02:00
Sheldan
9fdca52005 added command to remove the role from mod mail configuration again
added convenience method to disallow a whole feature for a role
2020-05-08 12:11:35 +02:00
Sheldan
7699075b33 added mod mail thread notification, if a user initiates a mod mail thread
added the concept of a mod mail role, these are roles being pinged when a thread is opened, and they also are able to execute mod mail related commands
fixed past thread count in mod mail header
added convenience method to allow a role to execute a whole feature
2020-05-08 10:49:06 +02:00
Sheldan
ea6fe240f4 added anonymous message handling to modmail 2020-05-08 00:58:05 +02:00
Sheldan
c03788a065 added closesilently command for modmail
largely refactored modmail future handling and error handling in case:
no permission, unable to contact user
fixed help command template
2020-05-08 00:20:20 +02:00
Sheldan
95733c9b98 moved default close note to template, added notification if there are no servers available which have mod mail enabled, added check to only present the servers which have the feature mod mail enabled. 2020-05-07 20:20:40 +02:00
Sheldan
6cf69af438 added header message containing information about the user the mod mail thread has been opened for 2020-05-07 00:26:19 +02:00
Sheldan
cb1a14e46b added user facing message in case the initial modmail creation fails 2020-05-06 23:41:35 +02:00
Sheldan
feb9ce07ee fixed using the correct parameter for reply and anon reply (not the whole message, so we dont need to parse out the actual reply again)
added optional note parameter for close
fixed state not being saved in database for mod mail thread
changed logging of mod mail to be templated, instead of replaying the messages
added reaction to indicate the user, that the message was processes by modmail
fixed future handling for user message replies (we blocked)
added header for initial information about the user when he opens a thread
fixed duration formater resulting in new lines
2020-05-06 23:22:43 +02:00
Sheldan
ad1cbb54fd refactored the naming in channel service
added initial version of closing and logging the thread
2020-05-06 18:32:08 +02:00
Sheldan
54327c3e58 implemented contact command and added check if the thread already exists
added anon reply command
2020-05-06 15:36:13 +02:00
Sheldan
a06006d763 added jda utilities dependency
added modmail with some simple features (chat between user and moderator), and initial server selection (currently allows all servers, and does not consider the modmail feature)
added the initial commands, not all of them hold logic currently
added some checks to not crash when a command has null configuration
changed systemconfig to also have a long value, because double is not fit for all cases
added locking mechanism, to effectively lock the whole table without using the ... proper locking mechanism (needs to be reviewed)
changed interface in channel service to be a message channel instead of a textChannel
changed starboard post to be a user in a server instead of only user
2020-05-06 14:17:44 +02:00