lib/imperituroard.rb in imperituroard-0.3.9 vs lib/imperituroard.rb in imperituroard-0.4.0

- old
+ new

@@ -798,21 +798,22 @@ end class Mhub_2 - attr_accessor :sk_url, :sk_login, :sk_password, :mhub_connector, :internal_func, :dabrab_connecter + attr_accessor :sk_url, :sk_login, :sk_password, :mhub_connector, :internal_func, :dabrab_connecter, :static_callback - def initialize(sk_url_simple, sk_login, sk_password, telegram_api_url, telegram_chat_id, sk_url_broadcast) + def initialize(sk_url_simple, sk_login, sk_password, telegram_api_url, telegram_chat_id, sk_url_broadcast, static_callback) @sk_url = sk_url_simple @sk_login = sk_login @sk_password = sk_password @internal_func = InternalFunc.new @mhub_connector = Sksk_1.new(sk_url_simple, sk_login, sk_password, sk_url_broadcast) @internal_func = InternalFunc.new @dabrab_connecter = Dabrab.new @add_functions_connector = AdditionalFunc.new(telegram_api_url, telegram_chat_id) + @static_callback = static_callback end #{"destinations"=>[{"to"=>{"phoneNumber"=>"375297116638", "emailAddress"=>nil}}], # "scenarioKey"=>"1", "viber"=>nil, "sms"=>{"text"=>"карточка готова"}, @@ -868,9 +869,11 @@ if null_statement.include?(params["viber"]) && !null_statement.include?(params["sms"]) hub_resp = mhub_connector.sk_send_sms_list(msisdn2, params["notifyUrl"], params["sms"]["text"], "TEST") elsif !null_statement.include?(params["viber"]) && null_statement.include?(params["sms"]) hub_resp = mhub_connector.sk_send_viber_list(msisdn2, params["notifyUrl"], params["viber"]["text"]) elsif !null_statement.include?(params["viber"]) && !null_statement.include?(params["sms"]) + p "vibersms" + p msisdn2 hub_resp = mhub_connector.sk_send_viber_sms_list(msisdn2, params["notifyUrl"], params["sms"]["text"], params["viber"]["text"], "TEST") else output_params = {"code": 502, "result": "Invalid input data st2", "body": {"answer": {}, "sender": {"ip_src": ip_src, "ip_real": ip_real, "ip_vip": ip_vip}}} end else \ No newline at end of file