alphanodes / redmine_messenger

Messenger plugin for Redmine with Slack, Discord, Rocket.Chat and Mattermost support
https://www.redmine.org/plugins/redmine_messenger
Other
175 stars 59 forks source link

Internal error when opening Project Settings page #14

Closed iquiw closed 6 years ago

iquiw commented 6 years ago

Using the latest master 835174d8313a56c76262568613b1751586f6cfd2.

Steps to reproduce the problem;

  1. Login as Administrator user.
  2. Goto "Settings" page of any project.

Then "Internal error" happened and the following log was written.

Completed 500 Internal Server Error in 224ms (ActiveRecord: 37.7ms)

ActionView::Template::Error (undefined method `project_reporting_sla_path' for #<#<Class:0x00007fec552ee2c8>:0x00007fec5882ba08>Did you mean?  project_repositories_path):
    1: .box.tabular.messenger_settings
    2:   - @messenger_setting = MessengerSetting.find_or_create(@project.id)
    3:   = form_tag(project_reporting_sla_path(project_id: @project), method: :put, class: 'tabular') do
    4:   = labelled_form_for :setting,
    5:                       @messenger_setting,
    6:                       url: project_messenger_setting_path(project_id: @project),
  plugins/redmine_messenger/app/views/messenger_settings/_show.html.slim:3:in `_plugins_redmine_messenger_app_views_messenger_settings__show_html_slim__600017373728661577_70326533804140'
  app/views/common/_tabs.html.erb:17:in `block in _app_views_common__tabs_html_erb___544706548850458436_70326536941660'
  app/views/common/_tabs.html.erb:16:in `each'
  app/views/common/_tabs.html.erb:16:in `_app_views_common__tabs_html_erb___544706548850458436_70326536941660'
  app/helpers/application_helper.rb:345:in `render_tabs'
  app/views/projects/settings.html.erb:3:in `_app_views_projects_settings_html_erb___2919506661960189687_70326536981000'
  lib/redmine/sudo_mode.rb:63:in `sudo_mode'
alexandermeindl commented 6 years ago

Thanks for reporting this bug. The problem should be fixed with my last commit.

iquiw commented 6 years ago

Thank you!

kvbala commented 5 years ago

Having the same error at the following environment: Redmine version 4.0.4.stable Ruby version 2.5.5-p157 (2019-03-15) [x64-mingw32] Rails version 5.2.3

Following is the error message from the log.

  Rendered plugins/redmine_messenger/app/views/messenger_settings/_show.html.erb (51.3ms)
  Rendered common/_tabs.html.erb (153.8ms)
  Rendered projects/settings.html.erb within layouts/base (156.9ms)
Completed 500 Internal Server Error in 180ms (ActiveRecord: 24.9ms)

ActionView::Template::Error (No route matches {:action=>"save", :controller=>"messenger_settings"