2022-08-30 14:59:15 +01:00
const { MessageEmbed , MessageActionRow , MessageButton } = require ( "discord.js" ) ;
2022-05-12 00:01:18 +01:00
module . exports = {
2022-05-12 01:03:23 +01:00
name : "paidmember" ,
2022-05-12 00:01:18 +01:00
aliases : [ '' ] ,
/ * *
*
* @ param { Client } client
* @ param { Message } message
* @ param { String [ ] } args
* /
run : async ( client , message , args ) => {
2022-07-01 18:46:51 +01:00
if ( ! message . member . permissions . has ( Permissions . FLAGS . BAN _MEMBERS , Permissions . FLAGS . ADMINISTRATOR ) ) return message . channel . send ( "You don't have permission to use that command." )
2022-08-30 14:59:15 +01:00
const embed = new MessageEmbed ( )
2022-05-12 00:01:18 +01:00
. setColor ( 'GREEN' )
2022-07-01 18:46:51 +01:00
. setFooter ( { text : ` Called By: ${ message . author . tag } ` } )
2022-05-12 00:01:18 +01:00
. setTimestamp ( )
. setTitle ( "Paid Member!" )
. setDescription ( ` Press the button below to get access to the paid member role. ` )
2022-05-12 01:19:15 +01:00
. addField ( 'Benefits?' , 'Come to every event\r\n Vote in AGMs and EGMs\r\n Access a special area, just for paid members\r\n Access our archive of previous events and guest talks\r\n\r\nAnd support the society you are apart of!' )
. addField ( 'Pay for a membership' , 'Press the grey button below!' )
2022-05-12 00:01:18 +01:00
. setThumbnail ( 'https://i.imgur.com/ww6wKwJ.png' )
2022-08-30 14:59:15 +01:00
const row = new MessageActionRow ( )
2022-05-12 01:19:15 +01:00
. addComponents (
2022-08-30 14:59:15 +01:00
new MessageButton ( )
2022-05-12 01:19:15 +01:00
. setURL ( 'https://hulluniunion.com/shop?aid=304' )
. setEmoji ( '' )
. setLabel ( 'Pay for a membership!' )
. setStyle ( 'LINK' )
)
2022-07-01 18:46:51 +01:00
. addComponents (
2022-08-30 14:59:15 +01:00
new MessageButton ( )
2022-05-12 01:03:23 +01:00
. setCustomId ( 'paidModal' )
2022-05-12 01:19:15 +01:00
. setLabel ( 'Paid Member Request' )
2022-05-12 01:03:23 +01:00
. setStyle ( 'PRIMARY' )
2022-05-12 00:01:18 +01:00
)
message . channel . send ( { embeds : [ embed ] , components : [ row ] } )
} ,
} ;