13.0.2 revise ignore to dismiss invoice
This commit is contained in:
5 files changed
+12
-12
No files matched your search
+6
-6
@@ -353,9 +353,9 @@ module.exports = {
|
||||
}]
|
||||
},
|
||||
{
|
||||
name: "can_ignore_invoices",
|
||||
description: "Allow users to ignore and delete invoices",
|
||||
value: "can_ignore_invoices",
|
||||
name: "can_dismiss_invoices",
|
||||
description: "Allow users to dismiss and delete invoices",
|
||||
value: "can_dismiss_invoices",
|
||||
type: 1,
|
||||
options: [{
|
||||
name: "true_or_false",
|
||||
@@ -868,8 +868,8 @@ module.exports = {
|
||||
|
||||
return interaction.send({ embeds: [prompt], components: [opt], flags: (1 << 6) });
|
||||
|
||||
} else if (args[0].name == 'can_ignore_invoices') {
|
||||
client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$set: {"server.canIgnoreInvoices": args[0].options[0].value}}, function(err, res) {
|
||||
} else if (args[0].name == 'can_dismiss_invoices') {
|
||||
client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$set: {"server.canDismissInvoices": args[0].options[0].value}}, function(err, res) {
|
||||
if (err) return client.sendInternalError(interaction, err);
|
||||
});
|
||||
|
||||
@@ -920,7 +920,7 @@ module.exports = {
|
||||
{ name: 'Has Disptach Role?', value: `\`\`\`diff\n${dispatchRoleColor}${client.exists(GuildDB.dispatcherRole)}\`\`\`${dispatchRole}`, inline: true },
|
||||
{ name: 'Has Dispatch Channel?', value: `\`\`\`diff\n${dispatchChannelColor}${client.exists(GuildDB.dispatchChannel)}\`\`\`${dispatchChannel}`, inline: true },
|
||||
{ name: 'Has bot admin role?', value: `\`\`\`diff\n${botAdminRoleColor}${client.exists(GuildDB.botAdmin)}\`\`\`${botAdminRole}`, inline: true },
|
||||
{ name: 'Can Ignore Invoices?', value: `\`\`\`diff\n${GuildDB.canIgnoreInvoices ? '+ ' : '- '}${GuildDB.canIgnoreInvoices}\`\`\``, inline: true },
|
||||
{ name: 'Can Dismiss Invoices?', value: `\`\`\`diff\n${GuildDB.canDismissInvoices ? '+ ' : '- '}${GuildDB.canDismissInvoices}\`\`\``, inline: true },
|
||||
);
|
||||
|
||||
return interaction.send({ embeds: [settingsEmbed] });
|
||||
|
||||
+2
-2
@@ -244,7 +244,7 @@ module.exports = {
|
||||
opt.addComponents(
|
||||
new ButtonBuilder()
|
||||
.setCustomId(`DeleteInvoice-${invoice.id}`)
|
||||
.setLabel("Ignore and Delete")
|
||||
.setLabel("Dismiss & Delete")
|
||||
.setStyle(ButtonStyle.Secondary)
|
||||
);
|
||||
}
|
||||
@@ -320,7 +320,7 @@ module.exports = {
|
||||
|
||||
let successEmbed = new EmbedBuilder()
|
||||
.setColor(client.config.Colors.Green)
|
||||
.setTitle(`Ignored and deleted invoice #${invoice.id}`);
|
||||
.setTitle(`Dismissed and Deleted invoice #${invoice.id}`);
|
||||
|
||||
return interaction.update({ embeds: [successEmbed], components: [] });
|
||||
}
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ require('dotenv').config();
|
||||
|
||||
module.exports = {
|
||||
Dev: "PROD.",
|
||||
Version: "13.0.1", // (major).(feature).(revision/bug/refactoring)
|
||||
Version: "13.0.2", // (major).(feature).(revision/bug/refactoring)
|
||||
Admins: ["362791661274660874", "329371697570381824"], // Admins of the bot
|
||||
DefaultPrefix: "?",
|
||||
ServerID: "955668596745461830",
|
||||
|
||||
@@ -101,9 +101,9 @@ module.exports = {
|
||||
`
|
||||
},
|
||||
{
|
||||
name: "can_ignore_invoices",
|
||||
name: "can_dismiss_invoices",
|
||||
description: `
|
||||
This configurations allows users who have been given an invoice to \`Ignore and Delete\` an invoice they choose rather than pay. This can be set to false, so users must pay their invoice.\n\n**Note:** Invoices are paid from a users bank balance, and not with their cash balance.
|
||||
This configurations allows users who have been given an invoice to \`Dismiss & Delete\` an invoice they choose rather than pay. This can be set to false, so users must pay their invoice.\n\n**Note:** Invoices are paid from a users bank balance, and not with their cash balance.
|
||||
`
|
||||
},
|
||||
{
|
||||
|
||||
@@ -200,7 +200,7 @@ class QuarksBot extends Client {
|
||||
onlyOfficersSearch: guild.server.onlyOfficersSearch,
|
||||
botAdmin: guild.server.botAdmin,
|
||||
casinoMultiplier: guild.server.casinoMultiplier,
|
||||
canIgnoreInvoices: guild.server.canIgnoreInvoices,
|
||||
canDismissInvoices: guild.server.canDismissInvoices,
|
||||
}
|
||||
return guildData;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user