renamed External User Name Modal

cleaned up external users in RaidMessage
This commit is contained in:
Sarah Faey 2022-11-29 17:07:14 +01:00
parent 8280adaf49
commit 5d429ff90f
2 changed files with 9 additions and 2 deletions

View file

@ -11,7 +11,7 @@ namespace DiscordBot.Messages
public static Modal buildMessage(int raidId, int roleId)
{
var mb = new ModalBuilder()
.WithTitle("Create Account")
.WithTitle("User Name")
.WithCustomId($"{Constants.ComponentIds.SIGN_UP_EXTERNAL_MODAL}-{raidId}-{roleId}")
.AddTextInput("Name", Constants.ComponentIds.NAME_TEXT_BOX, placeholder: "Name", required: true);

View file

@ -120,8 +120,15 @@ namespace DiscordBot.Messages
foreach (ApiRaid.Role.User user in role.Users.OrderBy(u => u.Status))
{
string status = !string.IsNullOrWhiteSpace(user.Status) ? $" - {user.Status}" : string.Empty;
if(string.IsNullOrEmpty(user.AccountName))
{
rolesString += $"\t{user.UserName} {status}\n";
}
else
{
rolesString += $"\t{user.UserName} ({user.AccountName}) {status}\n";
}
}
return rolesString;
}