peoplegroup-connectors 0.1.14 → 0.1.20

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: ff078596371e7e0e9324604a6c2dc7d61707865468ec123667497e95b98d4351
4
- data.tar.gz: f13a2a16ffe994b7a5a5e2753860d11d640d4a25e42e8ed8ab0a8027de11184b
3
+ metadata.gz: f374626a4dca0d62ab5145ba533e740ba48538f697be1c8440da3cdd73b7f13a
4
+ data.tar.gz: 904486b6a8ebb27880cd9e488817e6f63960b45f24be27a4e836b5404a205d14
5
5
  SHA512:
6
- metadata.gz: 7b58df402d826a8388205eeafdd6c0f26babc7516a27edd92f0771bf32ef0858d458503ee3c6a7e49e209faa2cc9c025102f912f0cc728d4318f66ae1a4b85f3
7
- data.tar.gz: 818217d780930b5ee2a63ac232924f6d40a172471a220b8fe06101250f6686c0833f952c53f1563d07c8ffba03e9b3281e0da9c50e7c2f783310aa2669cf510b
6
+ metadata.gz: '087e74440af5d85784a4c2f03d5eb1e8193a8b32ae6a134f069375d50b1e849e802a9539ac9c491adb76a79922921e93faeb04f011165a11cc43ec5884ebb716'
7
+ data.tar.gz: d730fb512e67769c35f6240bb1ea0596a287edd699758003d06d68e5a742b9a4b2345478e828eae10396b94510ef33d41f1902557e19b424eda1760517a19372
@@ -82,6 +82,14 @@ module PeopleGroup
82
82
  end
83
83
  alias_method :active_team_members, :active_employees
84
84
 
85
+ def active_and_current_employees
86
+ today = Date.current
87
+ employees.select do |employee|
88
+ employee['status'] == 'Active' && Date.parse(employee['hireDate']) <= today
89
+ end
90
+ end
91
+ alias_method :active_and_current_team_members, :active_and_current_employees
92
+
85
93
  def add_stock_options(employee_id, data)
86
94
  @client.employee.add_table_row(employee_id, 'customEquity', data)
87
95
  end
@@ -29,12 +29,12 @@ module PeopleGroup
29
29
  channels.reject(&:is_private)&.map(:name)
30
30
  end
31
31
 
32
- def send_message(channel:, text:, as_user: true, attachments: [])
33
- @client.chat_postMessage(channel: channel, text: text, as_user: true, attachments: attachments, unfurl_links: false)
32
+ def send_message(channel:, text:, as_user: true, attachments: [], thread_ts: nil, reply_broadcast: false)
33
+ @client.chat_postMessage(channel: channel, text: text, as_user: true, attachments: attachments, unfurl_links: false, thread_ts: thread_ts, reply_broadcast: reply_broadcast)
34
34
  end
35
35
 
36
- def update_message(channel:, timestamp:, text:)
37
- @client.chat_update(channel: channel, text: text, ts: timestamp, as_user: true, attachments: [])
36
+ def update_message(channel:, timestamp:, text:, attachments: [])
37
+ @client.chat_update(channel: channel, text: text, ts: timestamp, as_user: true, attachments: attachments)
38
38
  end
39
39
 
40
40
  def send_modal_message(trigger:, view:)
@@ -2,6 +2,6 @@
2
2
 
3
3
  module PeopleGroup
4
4
  module Connectors
5
- VERSION = '0.1.14'
5
+ VERSION = '0.1.20'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: peoplegroup-connectors
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.14
4
+ version: 0.1.20
5
5
  platform: ruby
6
6
  authors:
7
7
  - lien van den steen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-02-08 00:00:00.000000000 Z
11
+ date: 2021-02-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gitlab