Skip to content

Commit

Permalink
Fix dashboard
Browse files Browse the repository at this point in the history
  • Loading branch information
lpil committed Jun 25, 2024
1 parent 9b897dc commit 75f9a81
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 12 deletions.
10 changes: 5 additions & 5 deletions src/puck/payment.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,10 @@ pub fn unmatched(conn: database.Connection) -> Result(List(Payment), Error) {
reference
from
payments
left join applications on
payments.reference = applications.payment_reference
left join users on
payments.reference = users.payment_reference
where
applications.id is null
users.id is null
"

database.query(sql, conn, [], decoder)
Expand Down Expand Up @@ -206,8 +206,8 @@ pub fn per_day(
payments.created_at
from
payments
inner join applications on
payments.reference = applications.payment_reference
inner join users on
payments.reference = users.payment_reference
)
select
Expand Down
6 changes: 1 addition & 5 deletions src/puck/user.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -282,11 +282,7 @@ pub fn count_users_with_payments(
from
users
join
applications on users.id = applications.user_id
join
payments on payments.reference = applications.payment_reference
where
applications.id is not null
payments on payments.reference = users.payment_reference
"
let arguments = []
database.one(sql, conn, arguments, dy.element(0, dy.int))
Expand Down
4 changes: 2 additions & 2 deletions src/puck/web/event.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ fn field_html(question: Question) -> html.Node(a) {
pub fn application_form(ctx: Context) -> Response {
html.main([Attr("role", "main"), attrs.class("content")], [
web.flamingo(),
html.h1_text([], "Midsummer Night's Tea Party 2024"),
html.h1_text([], "Midsummer Night's Tea Party 2025"),
web.page_nav(ctx.current_user),
web.p(
"One person per submission please! We need to know about everyone who is coming.",
Expand Down Expand Up @@ -344,7 +344,7 @@ fn attendance_html(ctx: Context) -> html.Node(a) {
html.div([attrs.class("content")], [
web.flamingo(),
html.Element("hgroup", [], [
html.h1_text([], "Midsummer Night's Tea Party 2024"),
html.h1_text([], "Midsummer Night's Tea Party 2025"),
html.p_text([attrs.class("center")], "Welcome, friend!"),
]),
]),
Expand Down

0 comments on commit 75f9a81

Please sign in to comment.