effective_committees 0.3.2 → 0.3.4

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: 273a03d9378d41c45a5db4debbf70f1df6ff9c2d5cb8030e29ec5cd96aba3b7a
4
- data.tar.gz: 7f2a77350d8ad99f96af0ce67fb0c158f3af25285b856df803447b5c1accfc07
3
+ metadata.gz: 2dbf5431951175c003067b688990bab70bed951ce3ce3789aced0cd086582860
4
+ data.tar.gz: 21df5777b6941e57da909d5052eab66cd000b4f24ee7c1cc2bac03bbf943372b
5
5
  SHA512:
6
- metadata.gz: db9ed1a1c1e46673948c6ded274884fc4d29ad3338ebef7dba0f63a23d0b95b7487cc77243d935b1ae0c89cb54f9520fdfa077566498dca67071081b28383e5e
7
- data.tar.gz: 7a8d34ba7fdd401d4ce4af0319e459ad06e732927e8d0cddad374c125176fd730990e05269427069b56451661ab34975590d0d646ca9d87704ca55135471a1aa
6
+ metadata.gz: d468e614bebd4783bfe3ba8a794d0581e6e41936f86a1480dfdd7ca5316068436cfc22d3f53b935fe2d64e43f753916f7ee8305ae2f5f61caa275b931f4e7410
7
+ data.tar.gz: d19d8a0f10d252b32ce11bbd3346e07c7e33c993862af462d35160a8000eb845861a982402a625d6c91ca04ef692c84c55975c0a00e51be0d016f551b1fd2f96
@@ -4,8 +4,8 @@ module Admin
4
4
  col :id, visible: false
5
5
  col :user_id, visible: false
6
6
 
7
- col :committee
8
- col :user
7
+ col :committee, search: :string
8
+ col :user, search: :string
9
9
 
10
10
  unless attributes[:user_id]
11
11
  col :email do |committee_member|
@@ -7,7 +7,7 @@ class EffectiveCommitteesDatatable < Effective::Datatable
7
7
 
8
8
  col :title, label: 'Committee'
9
9
 
10
- col :committee_members, search: :string, label: 'Members'
10
+ col :committee_members, search: :string, label: 'Members', visible: false
11
11
 
12
12
  col :committee_folders, search: :string, label: 'Folders'
13
13
 
@@ -30,7 +30,7 @@ module Effective
30
30
  end
31
31
 
32
32
  scope :sorted, -> { order(:title) }
33
- scope :deep, -> { includes(:committee_members, committee_folders: [:committee_files, :rich_text_body]) }
33
+ scope :deep, -> { includes(committee_members: [:user], committee_folders: [:committee_files, :rich_text_body]) }
34
34
 
35
35
  validates :title, presence: true, uniqueness: true, length: { maximum: 255 }
36
36
 
@@ -26,7 +26,7 @@ module Effective
26
26
  self.title ||= file.filename.to_s
27
27
  end
28
28
 
29
- scope :deep, -> { with_attached_file }
29
+ scope :deep, -> { with_attached_file.includes(:committee, :committee_folder) }
30
30
  scope :sorted, -> { order(:title) }
31
31
 
32
32
  validates :title, presence: true
@@ -26,7 +26,7 @@ module Effective
26
26
  self.position ||= (committee.committee_folders.map { |obj| obj.position }.compact.max || -1) + 1
27
27
  end
28
28
 
29
- scope :deep, -> { includes(:committee, :committee_files) }
29
+ scope :deep, -> { includes(:rich_text_body, :committee, :committee_files) }
30
30
  scope :sorted, -> { order(:position) }
31
31
 
32
32
  validates :title, presence: true, length: { maximum: 250 },
@@ -1,10 +1,8 @@
1
1
  %h2 Committees
2
2
 
3
3
  - if current_user.committees.present?
4
- %p You are a member of #{pluralize(current_user.committees.length, 'committee')}.
5
-
6
4
  - datatable = EffectiveResources.best('EffectiveCommitteesDatatable').new(self, namespace: :effective)
7
5
  = render_datatable(datatable, simple: true)
8
6
 
9
7
  - else
10
- %p You are not a committee member. When you join a committee, we'll show it here.
8
+ %p You aren't assigned to any committees. When you are, we'll show them here.
@@ -1,3 +1,3 @@
1
1
  module EffectiveCommittees
2
- VERSION = '0.3.2'.freeze
2
+ VERSION = '0.3.4'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: effective_committees
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.2
4
+ version: 0.3.4
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: 2023-11-10 00:00:00.000000000 Z
11
+ date: 2023-11-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails