Fix missing routes incompatible with a subpath

This commit is contained in:
Sebastian Serth
2021-11-03 16:02:21 +01:00
parent 7bda3f1950
commit eb69697b9a
8 changed files with 20 additions and 18 deletions

View File

@ -41,4 +41,4 @@ h2.mt-4
= collection_select({}, :error_template_attribute_id,
ErrorTemplateAttribute.where.not(id: @error_template.error_template_attributes.select(:id).to_a).order('important DESC', :key),
:id, :key, {include_blank: false}, class: '')
button.btn.btn-outline-primary = t('error_templates.add_attribute')
button.btn.btn-outline-primary data-template-id=@error_template.id = t('error_templates.add_attribute')

View File

@ -12,7 +12,7 @@ h4.mt-4 = link_to(t('.exercise_statistics'), statistics_external_user_path(@user
- if current_user.admin?
h4.mt-4 = t('.tag_statistics')
#loading
#loading data-user-id=@user.id
.spinner
= t('.loading_tag_statistics')
#no-elements

View File

@ -109,7 +109,7 @@ javascript:
$.ajax({
dataType: 'json',
method: 'GET',
url: '//' + location.host + location.pathname + '/mark_as_solved'
url: '#{ mark_as_solved_request_for_comment_path(@request_for_comment) }'
}).done(function(response){
if(response.solved){
solvedButton.removeClass('btn-primary');
@ -127,7 +127,7 @@ javascript:
$.ajax({
dataType: 'json',
method: 'POST',
url: '//' + location.host + location.pathname + '/set_thank_you_note',
url: '#{ set_thank_you_note_request_for_comment_path(@request_for_comment) }',
data: {
note: value
}