mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2024-11-13 23:53:08 +02:00
Pings
This commit is contained in:
parent
a0ec19faee
commit
1a8b86dee0
@ -52,6 +52,7 @@ module.exports = class SettingsCommand extends Command {
|
|||||||
cat_row.name_format = c.name_format;
|
cat_row.name_format = c.name_format;
|
||||||
cat_row.opening_message = c.opening_message;
|
cat_row.opening_message = c.opening_message;
|
||||||
cat_row.opening_questions = c.opening_questions;
|
cat_row.opening_questions = c.opening_questions;
|
||||||
|
cat_row.ping = c.ping;
|
||||||
cat_row.require_topic = c.require_topic;
|
cat_row.require_topic = c.require_topic;
|
||||||
cat_row.roles = c.roles;
|
cat_row.roles = c.roles;
|
||||||
cat_row.survey = c.survey;
|
cat_row.survey = c.survey;
|
||||||
@ -111,6 +112,7 @@ module.exports = class SettingsCommand extends Command {
|
|||||||
name_format: c.name_format,
|
name_format: c.name_format,
|
||||||
opening_message: c.opening_message,
|
opening_message: c.opening_message,
|
||||||
opening_questions: c.opening_questions,
|
opening_questions: c.opening_questions,
|
||||||
|
ping: c.ping,
|
||||||
require_topic: c.require_topic,
|
require_topic: c.require_topic,
|
||||||
roles: c.roles,
|
roles: c.roles,
|
||||||
survey: c.survey
|
survey: c.survey
|
||||||
@ -162,6 +164,7 @@ module.exports = class SettingsCommand extends Command {
|
|||||||
name_format: c.name_format,
|
name_format: c.name_format,
|
||||||
opening_message: c.opening_message,
|
opening_message: c.opening_message,
|
||||||
opening_questions: c.opening_questions,
|
opening_questions: c.opening_questions,
|
||||||
|
ping: c.ping,
|
||||||
require_topic: c.require_topic,
|
require_topic: c.require_topic,
|
||||||
roles: c.roles,
|
roles: c.roles,
|
||||||
survey: c.survey
|
survey: c.survey
|
||||||
|
@ -46,6 +46,10 @@ module.exports = ({ config }, sequelize) => {
|
|||||||
type: DataTypes.JSON,
|
type: DataTypes.JSON,
|
||||||
allowNull: true,
|
allowNull: true,
|
||||||
},
|
},
|
||||||
|
ping: {
|
||||||
|
type: DataTypes.JSON,
|
||||||
|
defaultValue: [],
|
||||||
|
},
|
||||||
require_topic: {
|
require_topic: {
|
||||||
type: DataTypes.BOOLEAN,
|
type: DataTypes.BOOLEAN,
|
||||||
defaultValue: false,
|
defaultValue: false,
|
||||||
|
@ -37,6 +37,16 @@ module.exports = class TicketManager extends EventEmitter {
|
|||||||
? this.client.cryptr.decrypt(t_row.topic)
|
? this.client.cryptr.decrypt(t_row.topic)
|
||||||
: '';
|
: '';
|
||||||
|
|
||||||
|
if (cat_row.ping instanceof Array) {
|
||||||
|
let mentions = cat_row.ping.map(id => id === 'everyone'
|
||||||
|
? '@everyone'
|
||||||
|
: id === 'here'
|
||||||
|
? '@here'
|
||||||
|
: `<@&${id}>`);
|
||||||
|
|
||||||
|
await t_channel.send(mentions.join(', '));
|
||||||
|
}
|
||||||
|
|
||||||
await t_channel.send(member.user.toString());
|
await t_channel.send(member.user.toString());
|
||||||
|
|
||||||
if (cat_row.image) {
|
if (cat_row.image) {
|
||||||
|
Loading…
Reference in New Issue
Block a user