fix again

This commit is contained in:
TMA 2026-03-15 02:06:58 +01:00
parent 2c0c4a1a5a
commit 356b0d955e

View file

@ -179,15 +179,15 @@ ORDER BY vote_id" id)))
;; /admin/meeting/:id/vote
(define-resource (create-meeting-vote "admin" "meeting" id "vote" params)
(if (string=? (resource-context-method (current-resource-context)) "POST")
(let ((title (hash-ref params 'vote-title)))
(let ((title (param params 'vote-title)))
(query-db "SELECT brm.create_vote_and_init_status($1, $2)" id title)
(make-html-response
200
(layout
"Vote Created"
`@div{
@p{"Vote successfully created for meeting " (number->string id) "."}
@a[(href (string-append "/admin/meeting/" (number->string id)))]{Back to Meeting}
@p{Vote successfully created for meeting @,(identity id).}
@a[(href @,(string-append "/admin/meeting/" id))]{Back to Meeting}
})))
(make-error-response
405 "The access method used to request the document is not supported."