suer / redmine_webhook

147 stars 81 forks source link

Redmine 4.x can not works #26

Open sazus opened 4 years ago

sazus commented 4 years ago

When I installed 9acb46708 in my Redmine4.0.4stable, webhook settings could not looked in project setting.

Dose it possible to work in the below environment?

Environment:
  Redmine version                4.0.4.stable
  Ruby version                   2.5.5-p157 (2019-03-15) [x64-mingw32]
  Rails version                  5.2.3
  Environment                    production
  Database adapter               Mysql2
  Mailer queue                   ActiveJob::QueueAdapters::AsyncAdapter
  Mailer delivery                smtp
SCM:
  Subversion                     1.12.2
  Git                            2.19.1
  Filesystem                     
Redmine plugins:
・・・
  redmine_webhook                0.0.5
suer commented 4 years ago

It works for me in Redmine 4.0.4. Would you like to check any error logs?

sazus commented 4 years ago

Thank for your response.

I confirmed production.log. When view the setup screen, it seems that the settings screen of webhook is not loaded.

if possible, I would like several advice.

Completed 200 OK in 6ms (Views: 0.3ms | ActiveRecord: 2.7ms)
Started GET "/projects/Mycomponents/settings/webhook" for 127.0.0.1 at 2019-08-07 10:39:48 +0900
Processing by ProjectsController#settings as HTML
  Parameters: {"id"=>"Mycomponents", "tab"=>"webhook"}
  Current user: admin (id=1)
  Rendering projects/settings.html.erb within layouts/base
  Rendered projects/_form.html.erb (5.0ms)
  Rendered projects/_edit.html.erb (5.5ms)
  Rendered projects/settings/_members.html.erb (4.2ms)
  Rendered projects/settings/_issues.html.erb (4.8ms)
  Rendered projects/settings/_versions.html.erb (3.2ms)
  Rendered projects/settings/_issue_categories.html.erb (0.7ms)
  Rendered projects/settings/_repositories.html.erb (1.5ms)
  Rendered plugins/redmine_code_review/app/views/code_review_settings/_filters.html.erb (0.5ms)
  Rendered plugins/redmine_code_review/app/views/code_review_settings/_show.html.erb (4.9ms)
  Rendered plugins/redmine_issue_templates/app/views/common/_nodata.html.erb (0.0ms)
  Rendered plugins/redmine_issue_templates/app/views/issue_templates_settings/_show.html.erb (1.7ms)
  Rendered common/_tabs.html.erb (28.7ms)
  Rendered projects/settings.html.erb within layouts/base (30.1ms)
  Rendered plugins/redmine_code_review/app/views/code_review/_html_header.html.erb (0.7ms)
  Rendered plugins/redmine_wiki_extensions/app/views/wiki_extensions/_html_header.html.erb (0.8ms)
  Rendered plugins/clipboard_image_paste/app/views/clipboard_image_paste/_headers.html.erb (0.3ms)
  Rendering plugins/redmine_checklists/doc/LICENSE
  Rendered plugins/redmine_checklists/doc/LICENSE (0.0ms)
  Rendered plugins/redmine_agile/app/views/bitnami/_license_popup.html.erb (0.5ms)
  Rendered plugins/redmine_code_review/app/views/code_review/_body_bottom.html.erb (0.5ms)
  Rendered plugins/redmine_wiki_extensions/app/views/wiki_extensions/_body_bottom.html.erb (0.0ms)
  Rendered plugins/clipboard_image_paste/app/views/clipboard_image_paste/_add_form.html.erb (1.3ms)
Completed 200 OK in 57ms (Views: 43.0ms | ActiveRecord: 9.4ms)
suer commented 4 years ago

According to the log, you could find webhook tab, but empty page was loaded.

The tab is loaded when user is admin or "manage webhook" permission of the user is enabled.

In your log, you accessed the tab by admin (user_id = 1), so setting page should be displayed...

Anyway, please check "manage hook" permission. The permission setting will be found in "Role and Permission" setting page.

qmotas commented 4 years ago

I had the same problem on same environment.

In my case, the cause of the problem is loading https://github.com/akiko-pusu/redmine_issue_templates plugin before this plugin. It seems that ProjectsHelper.prepend() doesn't work after using ProjectsController.helper() to override ProjectsHelper.project_settings_tabs.

Workaround(quite dirty): change plugin directory name and the plugin name defined in init.rb to ensure that Redmine loads this plugin before other plugins causing this problem.

lazydao commented 4 years ago

According to the log, you could find webhook tab, but empty page was loaded.

The tab is loaded when user is admin or "manage webhook" permission of the user is enabled.

In your log, you accessed the tab by admin (user_id = 1), so setting page should be displayed...

Anyway, please check "manage hook" permission. The permission setting will be found in "Role and Permission" setting page.

I tried it, still not work,so sad. Can you help me. please.

image

I use Bitnami Redmine

Environment:
  Redmine version                4.0.4.stable
  Ruby version                   2.5.5-p157 (2019-03-15) [x86_64-linux]
  Rails version                  5.2.3
  Environment                    production
  Database adapter               Mysql2
  Mailer queue                   ActiveJob::QueueAdapters::AsyncAdapter
  Mailer delivery                smtp
SCM:
  Subversion                     1.12.0
  Git                            2.19.1
  Filesystem                     
Redmine plugins:
  easy_gantt                     1.12
  periodictask                   4.1.0
  redmine_agreement              0.1.1
  redmine_banner                 0.2.0
  redmine_checklists             3.1.16
  redmine_ckeditor               1.2.2
  redmine_code_review            1.0.0
  redmine_contacts               4.2.5
  redmine_dmsf                   2.0.0
  redmine_favorite_projects      2.1.0
  redmine_issue_dynamic_edit     0.6.7
  redmine_lightbox2              0.5.0
  redmine_products               2.1.0
  redmine_tags                   4.0.0
  redmine_webhook                0.0.5
  redmine_work_time              0.4.0
  select_to_select2              0.1.0

when i open project setting,there was nothing about webhook in the logs.

Started GET "/redmine/projects/zero/settings" for **.**.**.158 at 2020-02-26 10:33:04 +0800
Processing by ProjectsController#settings as HTML
  Parameters: {"id"=>"zero"}
  Current user: *** (id=23)
  Rendering projects/settings.html.erb within layouts/base
  Rendered plugins/redmine_dmsf/app/views/hooks/redmine_dmsf/_view_projects_form.html.erb (0.0ms)
  Rendered plugins/redmine_favorite_projects/app/views/projects/_tags.html.erb (1.8ms)
  Rendered projects/_form.html.erb (9.3ms)
  Rendered projects/_edit.html.erb (10.1ms)
  Rendered projects/settings/_members.html.erb (23.4ms)
  Rendered projects/settings/_issues.html.erb (14.1ms)
  Rendered projects/settings/_versions.html.erb (6.0ms)
  Rendered projects/settings/_issue_categories.html.erb (1.1ms)
  Rendered projects/settings/_repositories.html.erb (0.9ms)
  Rendered projects/settings/_boards.html.erb (1.0ms)
  Rendered projects/settings/_activities.html.erb (4.8ms)
  Rendered common/_tabs.html.erb (65.9ms)
  Rendered projects/settings.html.erb within layouts/base (67.8ms)
  Rendered plugins/redmine_code_review/app/views/code_review/_html_header.html.erb (0.1ms)
  Rendered plugins/redmine_contacts/app/views/contacts_issues/_additional_assets.html.erb (0.4ms)
  Rendered plugins/redmine_tags/app/views/tags/_header_assets.html.erb (0.3ms)
  Rendered plugins/redmine_favorite_projects/app/views/favorite_projects/_additional_assets.html.erb (0.1ms)
  Rendered plugins/redmine_code_review/app/views/code_review/_body_bottom.html.erb (0.1ms)
  Rendered plugins/redmine_contacts/app/views/common/_contacts_select2_data.html.erb (0.5ms)
  Rendered plugins/redmine_favorite_projects/app/views/favorite_projects/_select2_transformation_rules.html.erb (0.1ms)
  Rendered plugins/redmine_products/app/views/products/_select2_transformation_rules.html.erb (0.3ms)
Completed 200 OK in 103ms (Views: 81.9ms | ActiveRecord: 12.1ms)