Allow random selection for ProxyExercise
This commit is contained in:
@ -6,6 +6,9 @@
|
||||
.mb-3
|
||||
= f.label(:description, class: 'form-label')
|
||||
= f.pagedown :description, input_html: { preview: true, rows: 10 }
|
||||
.mb-3
|
||||
= f.label(:algorithm, class: 'form-label')
|
||||
= f.collection_select(:algorithm, ProxyExercise.algorithms.map { |algorithm, _id| [t("activerecord.attributes.proxy_exercise.algorithm_type.#{algorithm}"), algorithm] }, :second, :first, {}, class: 'form-control form-control-sm')
|
||||
.form-check.mb-3
|
||||
label.form-check-label
|
||||
= f.check_box(:public, class: 'form-check-input')
|
||||
|
@ -5,6 +5,7 @@ h1
|
||||
= row(label: 'exercise.title', value: @proxy_exercise.title)
|
||||
= row(label: 'exercise.user', value: link_to_if(policy(@proxy_exercise.author).show?, @proxy_exercise.author, @proxy_exercise.author))
|
||||
= row(label: 'proxy_exercise.files_count', value: @exercises.count)
|
||||
= row(label: 'proxy_exercise.algorithm', value: t("activerecord.attributes.proxy_exercise.algorithm_type.#{@proxy_exercise.algorithm}"))
|
||||
= row(label: 'exercise.public', value: @proxy_exercise.public?)
|
||||
= row(label: 'exercise.description', value: @proxy_exercise.description)
|
||||
= row(label: 'exercise.embedding_parameters', class: 'mb-4') do
|
||||
|
Reference in New Issue
Block a user