fixed del pager. todo stuff

This commit is contained in:
2021-09-27 17:34:13 +01:00
parent 379e488f7a
commit 6b5d6ae288
7 changed files with 126 additions and 168 deletions

View File

@ -174,7 +174,7 @@ INSERT IGNORE INTO roles (role, name, guild_id) VALUES (?, \"Role\", (SELECT id
let _ = component
.create_interaction_response(&ctx, move |r| {
*r = resp;
r
r.kind(InteractionResponseType::UpdateMessage)
})
.await;
}
@ -195,7 +195,7 @@ INSERT IGNORE INTO roles (role, name, guild_id) VALUES (?, \"Role\", (SELECT id
let _ = component
.create_interaction_response(&ctx, move |r| {
*r = resp;
r
r.kind(InteractionResponseType::UpdateMessage)
})
.await;
}

View File

@ -186,8 +186,8 @@ impl Pager for DelPager {
}
impl DelPager {
pub fn new(timezone: Tz) -> Self {
Self { page: 0, action: PageAction::First, timezone }
pub fn new(page: usize, timezone: Tz) -> Self {
Self { page, action: PageAction::Refresh, timezone }
}
pub fn buttons(