effective_organizations 0.0.3 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1680db25ffadd9aedde1cda52429e5b4d42ee4b2c6c2a16a801631099b7e3db6
|
4
|
+
data.tar.gz: b0ba4cfb29be4714b411101f2c2a50e073a433458c69453f0f032d73b0bcbc4d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cbb3f71d72a698486a909e5c7cb418adb1862254d4d1b3868ab4be56ce6a14c4fc18e7e6f3d1c71649700a7186f3ceeb144ef7fe866f5d5a7e71fe7589bbace4
|
7
|
+
data.tar.gz: 4e3bd0d65a5b370d3f8ad1284dc660720af0bc5b39165c82b265ac421d75ddab6dc1246f63aeba5aebed32f6c77298f211073671420dcbbb9abf8dac3709615a
|
@@ -5,5 +5,5 @@
|
|
5
5
|
|
6
6
|
- if organization.persisted?
|
7
7
|
%h2 Representatives
|
8
|
-
- datatable = Admin::EffectiveRepresentativesDatatable.new(organization_id: organization.id)
|
8
|
+
- datatable = Admin::EffectiveRepresentativesDatatable.new(organization_id: organization.id, organization_type: organization.class.name)
|
9
9
|
= render_inline_datatable(datatable)
|
@@ -4,12 +4,13 @@
|
|
4
4
|
= f.hidden_field :user_id
|
5
5
|
= f.hidden_field :user_type
|
6
6
|
= f.hidden_field :organization_id
|
7
|
+
= f.hidden_field :organization_type
|
7
8
|
|
8
9
|
- if f.object.new_record?
|
9
10
|
- unless inline_datatable? && inline_datatable.attributes[:organization_id].present?
|
10
11
|
= f.select :organization, { 'Organizations' => EffectiveOrganizations.Organization.sorted }, polymorphic: true
|
11
12
|
|
12
|
-
= f.checks :roles, EffectiveRoles.roles_collection(f.object)
|
13
|
+
= f.checks :roles, EffectiveRoles.roles_collection(f.object, skip_disabled: true)
|
13
14
|
|
14
15
|
- unless inline_datatable? && inline_datatable.attributes[:user_id].present?
|
15
16
|
= f.radios :new_representative_user_action, ['Invite new user', 'Add existing user'], inline: true, label: 'Representative'
|
@@ -28,7 +29,7 @@
|
|
28
29
|
- unless inline_datatable? && inline_datatable.attributes[:user_id].present?
|
29
30
|
= f.static_field :user
|
30
31
|
|
31
|
-
= f.checks :roles, EffectiveRoles.roles_collection(f.object)
|
32
|
+
= f.checks :roles, EffectiveRoles.roles_collection(f.object, skip_disabled: true)
|
32
33
|
|
33
34
|
- unless inline_datatable? && inline_datatable.attributes[:user_id].present?
|
34
35
|
= f.fields_for :user, f.object.user do |fu|
|
@@ -10,7 +10,7 @@
|
|
10
10
|
- unless inline_datatable? && inline_datatable.attributes[:organization_id].present?
|
11
11
|
= f.select :organization, { 'Organizations' => EffectiveOrganizations.Organization.sorted }, polymorphic: true
|
12
12
|
|
13
|
-
= f.checks :roles, EffectiveRoles.roles_collection(f.object)
|
13
|
+
= f.checks :roles, EffectiveRoles.roles_collection(f.object, skip_disabled: true)
|
14
14
|
|
15
15
|
- unless inline_datatable? && inline_datatable.attributes[:user_id].present?
|
16
16
|
= f.hidden_field :new_representative_user_action, value: 'Invite new user'
|
@@ -25,7 +25,7 @@
|
|
25
25
|
- unless inline_datatable? && inline_datatable.attributes[:user_id].present?
|
26
26
|
= f.static_field :user
|
27
27
|
|
28
|
-
= f.checks :roles, EffectiveRoles.roles_collection(f.object)
|
28
|
+
= f.checks :roles, EffectiveRoles.roles_collection(f.object, skip_disabled: true)
|
29
29
|
|
30
30
|
= f.fields_for :user, f.object.user do |fu|
|
31
31
|
= render 'effective/representatives/user_fields', f: fu
|