peoplegroup-connectors 0.1.13 → 0.1.19

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: 82e25996e920cfe64593a348342c127fa24a668edd0b3e9d42bfe3306c235ea1
4
- data.tar.gz: edf8d6e9f82c5aac0523ec56070d2e4f7d24d07c846f5f05fd85e57daf8a8bec
3
+ metadata.gz: bcb29839a61402ed9f1c2b5257b49113f6fc7f3ad5b2c84c6509caef42f7c554
4
+ data.tar.gz: d9afbe54f6d1b067d9d7f1a61034a14f43b7d00d15e42c39a4746d3c93060d0b
5
5
  SHA512:
6
- metadata.gz: a1bad958065dfb45ac92dbeb760abc7078f057fef82dd90fce95203a2f08a09a98f1bf5c403ec4b928fddb1f1b6b1ab37e6eeeda13dd6f59d947dceee1071064
7
- data.tar.gz: 30affe0fb75c7877c6cdfde690ddcaeb30193603971f8aab4824c88f6bad87bbb1f9075640a40a352be3049c2ce30dedd97adea97ba3f2c4cd0e75244f304794
6
+ metadata.gz: e769c0355df031230e4f6e265524a97504c941203be02796cdbf798f29c8a07f69d1c0c4b26c78b8794e679e6389eab7d3c4dc36d6bdb3f6ee681ba72b1125ad
7
+ data.tar.gz: 374483c462fbdf47246d19eaca31593fb9baca2985b99a078a0f8f01edd359d15f924a3afaa435b965fdd585d6bfec9fb33c9458fc766444d9c6e8edd40f80ec
@@ -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
@@ -78,7 +78,7 @@ module PeopleGroup
78
78
  action = {
79
79
  action: 'update',
80
80
  file_path: file[:file_path],
81
- content: file[:file_with_change]
81
+ content: File.read(file[:tmp_file_path])
82
82
  }
83
83
  actions << action
84
84
  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)
33
+ @client.chat_postMessage(channel: channel, text: text, as_user: true, attachments: attachments, unfurl_links: false, thread_ts: thread_ts)
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.13'
5
+ VERSION = '0.1.19'
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.13
4
+ version: 0.1.19
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-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gitlab