effective_organizations 0.0.4 → 0.0.5
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: 1f978ab4fee3200d82c2f9c6858f707d35155c0da70f0f4a611e558597ea17e2
|
4
|
+
data.tar.gz: 67a3e163f691e3baeec1e48ce0687fcb649e491b65e4fb9a01cd03575726b59c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f07c62ddd2d61aa1f31c5abba3d5cd56b019b6fc58e474d1b063f3246416d077d357109b7c66fe9f514c1d263e18e23488662c9c2701fe52db5738ddba6ffe1
|
7
|
+
data.tar.gz: ea9ecd0a199c925c5ddd3550a83524d23fab81d48c4e91d620bee64970d7ae95238f561c8184bbeb4c43182db2e7b030e1afa97d663049c2c1b8c24b706f2a16
|
@@ -11,11 +11,24 @@ class EffectiveRepresentativesDatatable < Effective::Datatable
|
|
11
11
|
|
12
12
|
col :roles, search: roles_collection
|
13
13
|
|
14
|
-
|
14
|
+
unless attributes[:actions] == false
|
15
|
+
actions_col
|
16
|
+
end
|
17
|
+
|
15
18
|
end
|
16
19
|
|
17
20
|
collection do
|
18
|
-
Effective::Representative.deep.all.where(organization: current_user.organizations)
|
21
|
+
scope = Effective::Representative.deep.all.where(organization: current_user.organizations)
|
22
|
+
|
23
|
+
if attributes[:organization_id]
|
24
|
+
scope = scope.where(organization_id: attributes[:organization_id])
|
25
|
+
end
|
26
|
+
|
27
|
+
if attributes[:user_id]
|
28
|
+
scope = scope.where(user_id: attributes[:user_id])
|
29
|
+
end
|
30
|
+
|
31
|
+
scope
|
19
32
|
end
|
20
33
|
|
21
34
|
def roles_collection
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: effective_organizations
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Code and Effect
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-12-
|
11
|
+
date: 2021-12-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|