Add team switch
Some checks are pending
CI / scan_ruby (push) Waiting to run
CI / scan_js (push) Waiting to run
CI / lint (push) Waiting to run
CI / test (push) Waiting to run

This commit is contained in:
sto
2025-03-15 12:44:58 +01:00
parent 1dbb495c3b
commit 1f0cbee9fd
8 changed files with 35 additions and 7 deletions

View File

@@ -1,8 +1,15 @@
= form_with model: contest do |form|
.row
.row.mb-3
.col
.form-floating
= form.text_field :name, autocomplete: "off", class: "form-control"
= form.label :name, class: "required"
.row
.col
.form-check.form-switch
= form.check_box :team, class: "form-check-input"
= form.label :team
| Team contest
.form-text For registration and UI display purposes
div.mt-3
= form.submit "Create", class: "btn btn-primary"
= form.submit submit_text, class: "btn btn-primary"

View File

@@ -0,0 +1 @@
= render "form", contest: @contest, submit_text: "Save"

View File

@@ -1 +1 @@
= render "form", contest: @contest
= render "form", contest: @contest, submit_text: "Create"

View File

@@ -0,0 +1,2 @@
a.btn.btn-primary href=edit_contest_path(@contest)
| Edit