notification_hub 0.1.6 → 0.1.7

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
  SHA1:
3
- metadata.gz: 5067d62595f0af5c45a6c8157068fc49cd2e3cd0
4
- data.tar.gz: e75fdf19d41797cb7db3de3b5e72d68ad5f39308
3
+ metadata.gz: 708615fe63cf8fd32c073bfa9d01ba4bfd541d4d
4
+ data.tar.gz: debf3903c4c72d983900b0da0dc6d10503d6e8d9
5
5
  SHA512:
6
- metadata.gz: 0f32c44be47a4bf76c345e415135b6ed9ee2e4e29b5d20f056b96d77923d6eeeb7b5739b5ffd90f81708c479167f7317eda61243c55c3e0f94fef8cbc85eca0b
7
- data.tar.gz: 1d8796d5c84622043aadf205d2047cc84ffd3962a171f008d781dd09fe3cd3247f8a0d285a482d05f06f518a11b202e1183e860fbaa3c73be2ee5355e13cbe18
6
+ metadata.gz: f6617c56ac4edf20a9235a91241c41cc016e91aee25e0aff271920344249cbea3f446cd832a885a505fae2c6d48e56c002478af6a52b0c4eb53c523e33de3fa1
7
+ data.tar.gz: 384fe49ca00b06de86b1dfbee51091525dee71e8fc3afd29aaf990045f8d21a98a03fb9bf3ed629ff061df35d7f5c886161421977b8a8b6e7a61395104299b58
@@ -5,8 +5,8 @@ class NotificationHubJob < ActiveJob::Base
5
5
  channel_code=nil, gateway_code=nil)
6
6
  if method == "deliver"
7
7
  NotificationHub.send_message(association_model_id, event_code, data)
8
- elsif method == "deliver_direct"
9
- NotificationHub.send_direct_message(event_code, data, device_details,
8
+ elsif method == "deliver_global"
9
+ NotificationHub.send_global_message(event_code, data, device_details,
10
10
  channel_code, gateway_code)
11
11
  end
12
12
  end
@@ -6,8 +6,8 @@ class NotificationHubJob
6
6
  channel_code=nil, gateway_code=nil)
7
7
  if method == "deliver"
8
8
  NotificationHub.send_message(association_model_id, event_code, data)
9
- elsif method == "deliver_direct"
10
- NotificationHub.send_direct_message(event_code, data, device_details,
9
+ elsif method == "deliver_global"
10
+ NotificationHub.send_global_message(event_code, data, device_details,
11
11
  channel_code, gateway_code)
12
12
  end
13
13
  end
@@ -41,15 +41,15 @@ module NotificationHub
41
41
  end
42
42
  end
43
43
 
44
- def deliver_direct_now(event_code, data, device_details, channel_code, gateway_code=nil)
45
- send_direct_message(event_code, data, device_details, channel_code, gateway_code)
44
+ def deliver_global_now(event_code, data, device_details, channel_code, gateway_code=nil)
45
+ send_global_message(event_code, data, device_details, channel_code, gateway_code)
46
46
  end
47
47
 
48
- def deliver_direct(event_code, data, device_details, channel_code, gateway_code=nil)
48
+ def deliver_global(event_code, data, device_details, channel_code, gateway_code=nil)
49
49
  if NotificationHubJob.respond_to?("perform_later".to_sym)
50
- NotificationHubJob.perform_later("deliver_direct", nil, event_code, data, device_details, channel_code, gateway_code)
50
+ NotificationHubJob.perform_later("deliver_global", nil, event_code, data, device_details, channel_code, gateway_code)
51
51
  elsif NotificationHubJob.respond_to?("perform_async".to_sym)
52
- NotificationHubJob.perform_async("deliver_direct", nil, event_code, data, device_details, channel_code, gateway_code)
52
+ NotificationHubJob.perform_async("deliver_global", nil, event_code, data, device_details, channel_code, gateway_code)
53
53
  end
54
54
  end
55
55
 
@@ -93,7 +93,7 @@ module NotificationHub
93
93
  end
94
94
  end
95
95
 
96
- def send_direct_message(event_code, data_wrapper, device_details, channel_code, gateway_code=nil)
96
+ def send_global_message(event_code, data_wrapper, device_details, channel_code, gateway_code=nil)
97
97
 
98
98
  # Fetch data from the database if record id is passed.
99
99
  data = {}
@@ -1,3 +1,3 @@
1
1
  module NotificationHub
2
- VERSION = "0.1.6"
2
+ VERSION = "0.1.7"
3
3
  end
@@ -9,8 +9,14 @@ Gem::Specification.new do |spec|
9
9
  spec.authors = ["Viduranga Wijesooriya"]
10
10
  spec.email = ["vpowerrc@gmail.com"]
11
11
 
12
- spec.summary = %q{Write a short summary, because Rubygems requires one.}
13
- spec.description = %q{Write a longer description or delete this line.}
12
+ spec.summary = "This gem can be used to centralize the notification dispatching of an application."
13
+ spec.description = "Currently, this gem supports 5 notification channels.
14
+
15
+ Email
16
+ Webhook
17
+ SMS
18
+ Mobile Push Notifications
19
+ Browser Push Notifications"
14
20
  spec.homepage = "http://mygemserver.com"
15
21
  spec.license = "MIT"
16
22
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: notification_hub
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Viduranga Wijesooriya
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-06-05 00:00:00.000000000 Z
11
+ date: 2017-06-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -66,7 +66,14 @@ dependencies:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
68
  version: '2'
69
- description: Write a longer description or delete this line.
69
+ description: |-
70
+ Currently, this gem supports 5 notification channels.
71
+
72
+ Email
73
+ Webhook
74
+ SMS
75
+ Mobile Push Notifications
76
+ Browser Push Notifications
70
77
  email:
71
78
  - vpowerrc@gmail.com
72
79
  executables: []
@@ -163,5 +170,5 @@ rubyforge_project:
163
170
  rubygems_version: 2.5.1
164
171
  signing_key:
165
172
  specification_version: 4
166
- summary: Write a short summary, because Rubygems requires one.
173
+ summary: This gem can be used to centralize the notification dispatching of an application.
167
174
  test_files: []