mirror of
https://github.com/anteo/redmine_custom_workflows.git
synced 2026-01-26 00:04:20 +00:00
Removal of unnnecessary files
This commit is contained in:
parent
e7dc9b7ba8
commit
9ff21d929b
4
.github/workflows/rubyonrails.yml
vendored
4
.github/workflows/rubyonrails.yml
vendored
@ -20,9 +20,9 @@
|
|||||||
name: "GitHub CI"
|
name: "GitHub CI"
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: ["devel"]
|
branches: ["cleanup"]
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: ["devel"]
|
branches: ["cleanup"]
|
||||||
jobs:
|
jobs:
|
||||||
plugin_tests:
|
plugin_tests:
|
||||||
strategy:
|
strategy:
|
||||||
|
|||||||
@ -1,38 +0,0 @@
|
|||||||
# frozen_string_literal: true
|
|
||||||
|
|
||||||
# Redmine plugin for Custom Workflows
|
|
||||||
#
|
|
||||||
# Anton Argirov, Karel Pičman <karel.picman@kontron.com>
|
|
||||||
#
|
|
||||||
# This file is part of Redmine OAuth plugin.
|
|
||||||
#
|
|
||||||
# Redmine Custom Workflows plugin is free software: you can redistribute it and/or modify it under the terms of the GNU
|
|
||||||
# General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your
|
|
||||||
# option) any later version.
|
|
||||||
#
|
|
||||||
# Redmine Custom Workflows plugin is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without
|
|
||||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
||||||
# for more details.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License along with Redmine Custom Workflows plugin. If not,
|
|
||||||
# see <https://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
require 'redmine'
|
|
||||||
require "#{File.dirname(__FILE__)}/lib/redmine_custom_workflows"
|
|
||||||
|
|
||||||
def custom_workflows_init
|
|
||||||
# Administration menu extension
|
|
||||||
Redmine::MenuManager.map :admin_menu do |menu|
|
|
||||||
menu.push :custom_workflows, { controller: 'custom_workflows', action: 'index' },
|
|
||||||
caption: :label_custom_workflow_plural, icon: 'workflows',
|
|
||||||
html: { class: 'icon icon-workflows workflows' }
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
|
||||||
ActiveSupport.on_load(:easyproject, yield: true) do
|
|
||||||
custom_workflows_init
|
|
||||||
end
|
|
||||||
else
|
|
||||||
custom_workflows_init
|
|
||||||
end
|
|
||||||
10
init.rb
10
init.rb
@ -17,6 +17,9 @@
|
|||||||
# You should have received a copy of the GNU General Public License along with Redmine Custom Workflows plugin. If not,
|
# You should have received a copy of the GNU General Public License along with Redmine Custom Workflows plugin. If not,
|
||||||
# see <https://www.gnu.org/licenses/>.
|
# see <https://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
require 'redmine'
|
||||||
|
require "#{File.dirname(__FILE__)}/lib/redmine_custom_workflows"
|
||||||
|
|
||||||
Redmine::Plugin.register :redmine_custom_workflows do
|
Redmine::Plugin.register :redmine_custom_workflows do
|
||||||
name 'Redmine Custom Workflow plugin'
|
name 'Redmine Custom Workflow plugin'
|
||||||
url 'https://www.redmine.org/plugins/redmine_custom_workflows'
|
url 'https://www.redmine.org/plugins/redmine_custom_workflows'
|
||||||
@ -30,4 +33,9 @@ Redmine::Plugin.register :redmine_custom_workflows do
|
|||||||
permission :manage_project_workflow, {}, require: :member
|
permission :manage_project_workflow, {}, require: :member
|
||||||
end
|
end
|
||||||
|
|
||||||
require_relative 'after_init' unless Redmine::Plugin.installed?('easy_extensions')
|
# Administration menu extension
|
||||||
|
Redmine::MenuManager.map :admin_menu do |menu|
|
||||||
|
menu.push :custom_workflows, { controller: 'custom_workflows', action: 'index' },
|
||||||
|
caption: :label_custom_workflow_plural, icon: 'workflows',
|
||||||
|
html: { class: 'icon icon-workflows workflows' }
|
||||||
|
end
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module AttachmentsControllerPatch
|
module AttachmentsControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module GroupsControllerPatch
|
module GroupsControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module IssueRelationsControllerPatch
|
module IssueRelationsControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module IssuesControllerPatch
|
module IssuesControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module MembersControllerPatch
|
module MembersControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module ProjectsControllerPatch
|
module ProjectsControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module TimelogControllerPatch
|
module TimelogControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module UsersControllerPatch
|
module UsersControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module VersionsControllerPatch
|
module VersionsControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -24,7 +24,6 @@ module RedmineCustomWorkflows
|
|||||||
module WikiControllerPatch
|
module WikiControllerPatch
|
||||||
################################################################################################################
|
################################################################################################################
|
||||||
# New methods
|
# New methods
|
||||||
#
|
|
||||||
|
|
||||||
def self.prepended(base)
|
def self.prepended(base)
|
||||||
base.class_eval do
|
base.class_eval do
|
||||||
|
|||||||
@ -40,10 +40,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
ProjectsController.send :helper, RedmineCustomWorkflows::Patches::Helpers::ProjectsHelperPatch
|
||||||
RedmineExtensions::PatchManager.register_helper_patch 'ProjectsHelper',
|
|
||||||
'RedmineCustomWorkflows::Patches::Helpers::ProjectsHelperPatch',
|
|
||||||
prepend: true
|
|
||||||
else
|
|
||||||
ProjectsController.send :helper, RedmineCustomWorkflows::Patches::Helpers::ProjectsHelperPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -69,9 +69,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
Attachment.prepend RedmineCustomWorkflows::Patches::Models::AttachmentPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'Attachment',
|
|
||||||
'RedmineCustomWorkflows::Patches::Models::AttachmentPatch'
|
|
||||||
else
|
|
||||||
Attachment.prepend RedmineCustomWorkflows::Patches::Models::AttachmentPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -89,8 +89,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
Group.prepend RedmineCustomWorkflows::Patches::Models::GroupPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'Group', 'RedmineCustomWorkflows::Patches::Models::GroupPatch'
|
|
||||||
else
|
|
||||||
Group.prepend RedmineCustomWorkflows::Patches::Models::GroupPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -103,8 +103,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
Issue.prepend RedmineCustomWorkflows::Patches::Models::IssuePatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'Issue', 'RedmineCustomWorkflows::Patches::Models::IssuePatch'
|
|
||||||
else
|
|
||||||
Issue.prepend RedmineCustomWorkflows::Patches::Models::IssuePatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -87,9 +87,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
IssueRelation.prepend RedmineCustomWorkflows::Patches::Models::IssueRelationPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'IssueRelation',
|
|
||||||
'RedmineCustomWorkflows::Patches::Models::IssueRelationPatch'
|
|
||||||
else
|
|
||||||
IssueRelation.prepend RedmineCustomWorkflows::Patches::Models::IssueRelationPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -69,8 +69,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
Member.prepend RedmineCustomWorkflows::Patches::Models::MemberPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'Member', 'RedmineCustomWorkflows::Patches::Models::MemberPatch'
|
|
||||||
else
|
|
||||||
Member.prepend RedmineCustomWorkflows::Patches::Models::MemberPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -97,9 +97,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
Project.prepend RedmineCustomWorkflows::Patches::Models::ProjectPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'Project',
|
|
||||||
'RedmineCustomWorkflows::Patches::Models::ProjectPatch'
|
|
||||||
else
|
|
||||||
Project.prepend RedmineCustomWorkflows::Patches::Models::ProjectPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -69,9 +69,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
TimeEntry.prepend RedmineCustomWorkflows::Patches::Models::TimeEntryPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'TimeEntry',
|
|
||||||
'RedmineCustomWorkflows::Patches::Models::TimeEntryPatch'
|
|
||||||
else
|
|
||||||
TimeEntry.prepend RedmineCustomWorkflows::Patches::Models::TimeEntryPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -69,8 +69,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
User.prepend RedmineCustomWorkflows::Patches::Models::UserPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'User', 'RedmineCustomWorkflows::Patches::Models::UserPatch'
|
|
||||||
else
|
|
||||||
User.prepend RedmineCustomWorkflows::Patches::Models::UserPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -69,9 +69,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
Version.prepend RedmineCustomWorkflows::Patches::Models::VersionPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'Version',
|
|
||||||
'RedmineCustomWorkflows::Patches::Models::VersionPatch'
|
|
||||||
else
|
|
||||||
Version.prepend RedmineCustomWorkflows::Patches::Models::VersionPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -69,9 +69,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
WikiContent.prepend RedmineCustomWorkflows::Patches::Models::WikiContentPatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'WikiContent',
|
|
||||||
'RedmineCustomWorkflows::Patches::Models::WikiContentPatch'
|
|
||||||
else
|
|
||||||
WikiContent.prepend RedmineCustomWorkflows::Patches::Models::WikiContentPatch
|
|
||||||
end
|
|
||||||
|
|||||||
@ -58,9 +58,4 @@ module RedmineCustomWorkflows
|
|||||||
end
|
end
|
||||||
|
|
||||||
# Apply the patch
|
# Apply the patch
|
||||||
if Redmine::Plugin.installed?('easy_extensions')
|
WikiPage.prepend RedmineCustomWorkflows::Patches::Models::WikiPagePatch
|
||||||
RedmineExtensions::PatchManager.register_model_patch 'WikiPage',
|
|
||||||
'RedmineCustomWorkflows::Patches::Models::WikiPagePatch'
|
|
||||||
else
|
|
||||||
WikiPage.prepend RedmineCustomWorkflows::Patches::Models::WikiPagePatch
|
|
||||||
end
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user