redmine_nonproject_modules 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f3021f986ccdc1df38523dd127151dcac47bfa63a565eb8d1f1c8448129c704f
|
4
|
+
data.tar.gz: db420508c1647e3e1cdd19f5c7c3f5640d8b4760ed5f540023c39ca875c30188
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c142e394b73792e7ac5e743f6911f067722d7109ffe86a05cce2ce97f81101bd878518e4b7013ed1eb09e9cb90d0fa92604b6d9b3c237050cfc09b25222d2e9c
|
7
|
+
data.tar.gz: f0075df6cbaeb64f91189ce7af9ed06fe7dd5b746649d297b49f5e44d9c05c930be22fb09166f846230fb57f3cc7c584ff967cb5c4ea4a1b2886cc81163b263e
|
data/app/models/group_merge.rb
CHANGED
@@ -1,12 +1,8 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require '
|
4
|
-
|
5
|
-
class GroupMerge
|
6
|
-
include ActiveModel::Model
|
7
|
-
include Virtus.model
|
8
|
-
include ActiveModel::Associations
|
3
|
+
require 'eac_rails_utils/models/tableless'
|
9
4
|
|
5
|
+
class GroupMerge < ::EacRailsUtils::Models::Tableless
|
10
6
|
ONLY_ON_TARGET = :only_on_target
|
11
7
|
ONLY_ON_SOURCE = :only_on_source
|
12
8
|
ON_BOTH = :on_both
|
@@ -19,14 +15,6 @@ class GroupMerge
|
|
19
15
|
validates :source, presence: true
|
20
16
|
validates :target, presence: true
|
21
17
|
|
22
|
-
def [](attr)
|
23
|
-
send(attr)
|
24
|
-
end
|
25
|
-
|
26
|
-
def []=(attr, value)
|
27
|
-
send("#{attr}=", value)
|
28
|
-
end
|
29
|
-
|
30
18
|
def to_merge_elements
|
31
19
|
(target_elements + source_elements).uniq.map do |x|
|
32
20
|
[x[0], element_on_status(x)]
|
data/init.rb
CHANGED
@@ -4,18 +4,11 @@ module RedmineNonprojectModules
|
|
4
4
|
module Patches
|
5
5
|
module Redmine
|
6
6
|
module I18nPatch
|
7
|
-
def
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
module InstanceMethods
|
13
|
-
def l_with_active_scaffold(*args)
|
14
|
-
if (args.first.is_a?(Time) || args.first.is_a?(Date)) && args.last.is_a?(Hash)
|
15
|
-
::I18n.l(args.first, args.last)
|
16
|
-
else
|
17
|
-
l_without_active_scaffold(*args)
|
18
|
-
end
|
7
|
+
def l(*args)
|
8
|
+
if (args.first.is_a?(Time) || args.first.is_a?(Date)) && args.last.is_a?(Hash)
|
9
|
+
::I18n.l(args.first, args.last)
|
10
|
+
else
|
11
|
+
super(*args)
|
19
12
|
end
|
20
13
|
end
|
21
14
|
end
|
@@ -26,4 +19,4 @@ end
|
|
26
19
|
x = ::Redmine::I18n
|
27
20
|
y = ::RedmineNonprojectModules::Patches::Redmine::I18nPatch
|
28
21
|
|
29
|
-
x.send(:
|
22
|
+
x.send(:prepend, y) unless x.included_modules.include?(y)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redmine_nonproject_modules
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
-
- 0.3.
|
7
|
+
- 0.3.2
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-07-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: active_scaffold
|
@@ -17,9 +17,6 @@ dependencies:
|
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '3.5'
|
20
|
-
- - ">="
|
21
|
-
- !ruby/object:Gem::Version
|
22
|
-
version: 3.5.4
|
23
20
|
type: :runtime
|
24
21
|
prerelease: false
|
25
22
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -27,43 +24,54 @@ dependencies:
|
|
27
24
|
- - "~>"
|
28
25
|
- !ruby/object:Gem::Version
|
29
26
|
version: '3.5'
|
30
|
-
- - ">="
|
31
|
-
- !ruby/object:Gem::Version
|
32
|
-
version: 3.5.4
|
33
27
|
- !ruby/object:Gem::Dependency
|
34
|
-
name:
|
28
|
+
name: eac_rails_utils
|
35
29
|
requirement: !ruby/object:Gem::Requirement
|
36
30
|
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0.11'
|
37
34
|
- - ">="
|
38
35
|
- !ruby/object:Gem::Version
|
39
|
-
version:
|
36
|
+
version: 0.11.2
|
40
37
|
type: :runtime
|
41
38
|
prerelease: false
|
42
39
|
version_requirements: !ruby/object:Gem::Requirement
|
43
40
|
requirements:
|
41
|
+
- - "~>"
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: '0.11'
|
44
44
|
- - ">="
|
45
45
|
- !ruby/object:Gem::Version
|
46
|
-
version:
|
46
|
+
version: 0.11.2
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: eac_ruby_utils
|
49
49
|
requirement: !ruby/object:Gem::Requirement
|
50
50
|
requirements:
|
51
51
|
- - "~>"
|
52
52
|
- !ruby/object:Gem::Version
|
53
|
-
version: '0.
|
54
|
-
- - ">="
|
55
|
-
- !ruby/object:Gem::Version
|
56
|
-
version: 0.10.1
|
53
|
+
version: '0.33'
|
57
54
|
type: :runtime
|
58
55
|
prerelease: false
|
59
56
|
version_requirements: !ruby/object:Gem::Requirement
|
60
57
|
requirements:
|
61
58
|
- - "~>"
|
62
59
|
- !ruby/object:Gem::Version
|
63
|
-
version: '0.
|
64
|
-
|
60
|
+
version: '0.33'
|
61
|
+
- !ruby/object:Gem::Dependency
|
62
|
+
name: jquery-rails
|
63
|
+
requirement: !ruby/object:Gem::Requirement
|
64
|
+
requirements:
|
65
|
+
- - "~>"
|
66
|
+
- !ruby/object:Gem::Version
|
67
|
+
version: '4.4'
|
68
|
+
type: :runtime
|
69
|
+
prerelease: false
|
70
|
+
version_requirements: !ruby/object:Gem::Requirement
|
71
|
+
requirements:
|
72
|
+
- - "~>"
|
65
73
|
- !ruby/object:Gem::Version
|
66
|
-
version:
|
74
|
+
version: '4.4'
|
67
75
|
- !ruby/object:Gem::Dependency
|
68
76
|
name: virtus
|
69
77
|
requirement: !ruby/object:Gem::Requirement
|