imperituroard 0.4.1 → 0.4.2
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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 582cdc4f1d5c749bdf4b12a441e7e8fe09cf5d66
|
4
|
+
data.tar.gz: 1b3394fdc5a658fdcecf4d4ffb74af2de304c561
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 14f19d10c8952b58a5f99350298ff365d575cf284733e7c4dccf86870ff1bfcf5470602732d6fa8bce031629e4a82b6aef80d42361430346cf4158143fc63f69
|
7
|
+
data.tar.gz: 68b532bfa41a5c207f53a6d1b3ea7f814ce526aaa490c21aaa924c0966a6dda751201ceb17dece54110eff59a349100c7887d905afcb3b8170bcdcc894db7ab3
|
@@ -3,7 +3,7 @@ require 'imperituroard/projects/iot/internal_functions'
|
|
3
3
|
|
4
4
|
class Crm_1
|
5
5
|
|
6
|
-
attr_accessor :crm_callback_url, :crm_login, :crm_password
|
6
|
+
attr_accessor :crm_callback_url, :crm_login, :crm_password, :internal_func
|
7
7
|
|
8
8
|
def initialize(crm_callback_url, crm_login, crm_password)
|
9
9
|
@crm_callback_url = crm_callback_url
|
@@ -75,8 +75,8 @@ end
|
|
75
75
|
{
|
76
76
|
|
77
77
|
# "bulkId": "9a410cb0-091e-41cf-a640-5d37bee14d9a",
|
78
|
-
"messageId": hub_report[
|
79
|
-
"to": hub_report[
|
78
|
+
"messageId": hub_report[:report][:message_id],
|
79
|
+
"to": hub_report[:report][:number],
|
80
80
|
# "sentAt": "2020-05-05T20:00:00.000+0000",
|
81
81
|
# "doneAt": "2020-05-05T20:00:00.000+0000",
|
82
82
|
"status": {
|
data/lib/imperituroard.rb
CHANGED
@@ -14,6 +14,7 @@ require "imperituroard/projects/iot/internal_functions"
|
|
14
14
|
require 'imperituroard/projects/mhub/infobip'
|
15
15
|
require 'imperituroard/projects/mhub/sk'
|
16
16
|
require 'imperituroard/projects/mhub/subs/dabrab/dabrab_proced'
|
17
|
+
require 'imperituroard/projects/mhub/subs/dabrab/dabrab_platform'
|
17
18
|
require 'json'
|
18
19
|
require 'ipaddr'
|
19
20
|
require 'date'
|
@@ -875,13 +876,13 @@ class Mhub_2
|
|
875
876
|
msisdn2 = dabrab_connecter.num_formatter(params["destinations"], params["notifyUrl"].split(":")[2])
|
876
877
|
|
877
878
|
if null_statement.include?(params["viber"]) && !null_statement.include?(params["sms"])
|
878
|
-
hub_resp = mhub_connector.sk_send_sms_list(msisdn2,
|
879
|
+
hub_resp = mhub_connector.sk_send_sms_list(msisdn2, static_callback, params["sms"]["text"], "TEST")
|
879
880
|
elsif !null_statement.include?(params["viber"]) && null_statement.include?(params["sms"])
|
880
|
-
hub_resp = mhub_connector.sk_send_viber_list(msisdn2,
|
881
|
+
hub_resp = mhub_connector.sk_send_viber_list(msisdn2, static_callback, params["viber"]["text"])
|
881
882
|
elsif !null_statement.include?(params["viber"]) && !null_statement.include?(params["sms"])
|
882
883
|
p "vibersms"
|
883
884
|
p msisdn2
|
884
|
-
hub_resp = mhub_connector.sk_send_viber_sms_list(msisdn2,
|
885
|
+
hub_resp = mhub_connector.sk_send_viber_sms_list(msisdn2, static_callback, params["sms"]["text"], params["viber"]["text"], "TEST")
|
885
886
|
else
|
886
887
|
output_params = {"code": 502, "result": "Invalid input data st2", "body": {"answer": {}, "sender": {"ip_src": ip_src, "ip_real": ip_real, "ip_vip": ip_vip}}}
|
887
888
|
end
|
@@ -912,7 +913,6 @@ class Mhub_2
|
|
912
913
|
|
913
914
|
begin
|
914
915
|
|
915
|
-
|
916
916
|
mes_report = dabrab_connecter.delivery_report_transform(params)[:body][:report_to_recip]
|
917
917
|
|
918
918
|
result = crm_connector.crm_status_1(mes_report)
|