mirror of
https://github.com/Sheldan/Sissi.git
synced 2026-09-12 18:12:04 +00:00
[SIS-3] adding meetup implementation
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<artifactId>module-templates</artifactId>
|
||||
<groupId>dev.sheldan.sissi.templates</groupId>
|
||||
<version>1.1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>meetup-templates</artifactId>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-assembly-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>package</phase>
|
||||
<goals>
|
||||
<goal>single</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<finalName>meetup-templates-${project.version}</finalName>
|
||||
<appendAssemblyId>false</appendAssemblyId>
|
||||
<descriptors>
|
||||
<descriptor>src/main/assembly/assembly.xml</descriptor>
|
||||
</descriptors>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
@@ -0,0 +1,15 @@
|
||||
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
|
||||
<id>zip</id>
|
||||
<includeBaseDirectory>false</includeBaseDirectory>
|
||||
<formats>
|
||||
<format>zip</format>
|
||||
</formats>
|
||||
<fileSets>
|
||||
<fileSet>
|
||||
<outputDirectory>.</outputDirectory>
|
||||
<directory>${project.basedir}/src/main/resources</directory>
|
||||
</fileSet>
|
||||
</fileSets>
|
||||
</assembly>
|
||||
@@ -0,0 +1,25 @@
|
||||
<#include "format_instant">
|
||||
{
|
||||
"embeds": [
|
||||
{
|
||||
<#include "abstracto_color">,
|
||||
"title": {
|
||||
"title": "${topic?json_string}"
|
||||
},
|
||||
"description": "<@format_instant_date_time instant=meetupTime/>
|
||||
${description?json_string}"
|
||||
}
|
||||
],
|
||||
"buttons": [
|
||||
{
|
||||
"label": "<@safe_include "createMeetup_confirm_button_label"/>",
|
||||
"id": "${confirmationId}",
|
||||
"buttonStyle": "success"
|
||||
},
|
||||
{
|
||||
"label": "<@safe_include "createMeetup_cancel_button_label"/>",
|
||||
"id": "${cancelId}",
|
||||
"buttonStyle": "danger"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
<#include "format_instant">
|
||||
{
|
||||
"embeds": [
|
||||
{
|
||||
<#include "abstracto_color">,
|
||||
"description": "<#list meetups as meetup><#assign meetup=meetup><#assign topic=meetup.topic><#assign time><@format_instant_date_time instant=meetup.meetupTime/></#assign><#assign timeRelative><@format_instant_relative instant=meetup.meetupTime/></#assign><#assign link=meetup.meetupMessage.jumpUrl><#include "meetup_list_meetup_display">
|
||||
<#else><#include "meetup_list_no_meetups"></#list>"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<#include "meetup_in_past_exception_message">
|
||||
@@ -0,0 +1 @@
|
||||
<#include "meetup_not_found_exception_message">
|
||||
@@ -0,0 +1,11 @@
|
||||
<#include "format_instant">
|
||||
{
|
||||
"embeds": [
|
||||
{
|
||||
<#include "abstracto_color">,
|
||||
<#assign time><@format_instant_date_time instant=meetupTime/></#assign>
|
||||
<#assign topicText>${topic?json_string}</#assign>
|
||||
"description": "<#include "meetup_cancel_notification_description">"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
<#include "format_instant">
|
||||
{
|
||||
<#assign roleMention="<@&371419588619141121>"/>
|
||||
"additionalMessage": "${roleMention?json_string}",
|
||||
"embeds": [
|
||||
{
|
||||
<#include "abstracto_color">,
|
||||
"title": {
|
||||
"title": "${topic?json_string}"
|
||||
},
|
||||
<#assign time><@format_instant_date_time instant=meetupTime/></#assign>
|
||||
<#assign timeRelative><@format_instant_relative instant=meetupTime/></#assign>
|
||||
<#assign descriptionText>${description?json_string}</#assign>
|
||||
<#assign participantsText><#list participants as member>${member.memberMention}<#else><#include "meetup_message_no_member"></#list></#assign>
|
||||
<#assign maybeParticipantsText><#list maybeParticipants as member>${member.memberMention}<#else><#include "meetup_message_no_member"></#list></#assign>
|
||||
<#assign declinedParticipantsText><#list declinedParticipants as member>${member.memberMention}<#else><#include "meetup_message_no_member"></#list></#assign>
|
||||
"description": "<#if cancelled>~~</#if><#include "meetup_display_description"><#if cancelled>~~</#if>"
|
||||
}
|
||||
],
|
||||
<#if yesId?has_content && noId?has_content && maybeId?has_content && !cancelled>
|
||||
"buttons": [
|
||||
{
|
||||
"label": "<@safe_include "meetup_message_yes_button_label"/>",
|
||||
"id": "${yesId}",
|
||||
"buttonStyle": "success"
|
||||
},
|
||||
{
|
||||
"label": "<@safe_include "meetup_message_maybe_button_label"/>",
|
||||
"id": "${maybeId}",
|
||||
"buttonStyle": "secondary"
|
||||
},
|
||||
{
|
||||
"label": "<@safe_include "meetup_message_no_button_label"/>",
|
||||
"id": "${noId}",
|
||||
"buttonStyle": "danger"
|
||||
},
|
||||
{
|
||||
"label": "<@safe_include "meetup_message_cancel_button_label"/>",
|
||||
"id": "${cancelId}",
|
||||
"buttonStyle": "danger"
|
||||
}
|
||||
],
|
||||
</#if>
|
||||
"messageConfig": {
|
||||
"allowsRoleMention": true
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
<#include "format_instant">
|
||||
{
|
||||
"embeds": [
|
||||
{
|
||||
<#include "abstracto_color">,
|
||||
<#assign time><@format_instant_date_time instant=meetupTime/></#assign>
|
||||
<#assign topicText>${topic?json_string}</#assign>
|
||||
"description": "<#include "meetup_reminder_notification_description">"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -11,6 +11,7 @@
|
||||
<packaging>pom</packaging>
|
||||
<modules>
|
||||
<module>quotes-templates</module>
|
||||
<module>meetup-templates</module>
|
||||
</modules>
|
||||
|
||||
</project>
|
||||
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<groupId>dev.sheldan.sissi.templates.translations</groupId>
|
||||
<artifactId>module-translations</artifactId>
|
||||
<version>1.1.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>meetup-translations</artifactId>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-assembly-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>package</phase>
|
||||
<goals>
|
||||
<goal>single</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<finalName>meetup-translations-${project.version}</finalName>
|
||||
<appendAssemblyId>false</appendAssemblyId>
|
||||
<descriptors>
|
||||
<descriptor>src/main/assembly/assembly.xml</descriptor>
|
||||
</descriptors>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
@@ -0,0 +1,15 @@
|
||||
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
|
||||
<id>zip</id>
|
||||
<includeBaseDirectory>false</includeBaseDirectory>
|
||||
<formats>
|
||||
<format>zip</format>
|
||||
</formats>
|
||||
<fileSets>
|
||||
<fileSet>
|
||||
<outputDirectory>.</outputDirectory>
|
||||
<directory>${project.basedir}/src/main/resources</directory>
|
||||
</fileSet>
|
||||
</fileSets>
|
||||
</assembly>
|
||||
@@ -0,0 +1 @@
|
||||
Cancel
|
||||
@@ -0,0 +1 @@
|
||||
OK
|
||||
@@ -0,0 +1 @@
|
||||
Creates a meetup
|
||||
@@ -0,0 +1,3 @@
|
||||
Command used to schedule a meetup.
|
||||
This creates a message which people can register (yes/no/maybe) themselves for a meetup.
|
||||
People will receive a notification at certain time periods before the meetup.
|
||||
@@ -0,0 +1 @@
|
||||
What the meetup should be.
|
||||
@@ -0,0 +1 @@
|
||||
Time of the meetup (https://www.unixtimestamp.com/)
|
||||
@@ -0,0 +1 @@
|
||||
Short description of the meetup
|
||||
@@ -0,0 +1 @@
|
||||
Lists all future meetups
|
||||
@@ -0,0 +1 @@
|
||||
This command can be used to list all future meetups and get information about them.
|
||||
@@ -0,0 +1,3 @@
|
||||
Time: ${time} ${timeRelative}
|
||||
Link: [here](${link})
|
||||
Meetup Topic: `${topic}`
|
||||
@@ -0,0 +1 @@
|
||||
No meetups found.
|
||||
@@ -0,0 +1 @@
|
||||
Meetup
|
||||
@@ -0,0 +1 @@
|
||||
Meetup is in the past. Not possible.
|
||||
@@ -0,0 +1 @@
|
||||
Meetup not found.
|
||||
@@ -0,0 +1 @@
|
||||
Meetup with topic ${topicText} at ${time} has been cancelled.
|
||||
@@ -0,0 +1,6 @@
|
||||
Time: ${time} ${timeRelative}
|
||||
<#if descriptionText?hasContent>Description: ${descriptionText}</#if>
|
||||
|
||||
Participants: ${participantsText}
|
||||
Maybe: ${maybeParticipantsText}
|
||||
Declined: ${declinedParticipantsText}
|
||||
@@ -0,0 +1 @@
|
||||
Cancel
|
||||
@@ -0,0 +1 @@
|
||||
Maybe
|
||||
@@ -0,0 +1 @@
|
||||
No
|
||||
@@ -0,0 +1 @@
|
||||
Nobody.
|
||||
@@ -0,0 +1 @@
|
||||
Yes
|
||||
@@ -0,0 +1 @@
|
||||
Meetup with topic ${topicText} is at ${time}.
|
||||
@@ -11,6 +11,7 @@
|
||||
<packaging>pom</packaging>
|
||||
<modules>
|
||||
<module>quote-translations</module>
|
||||
<module>meetup-translations</module>
|
||||
</modules>
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user