lib/nds_api/url.rb in nds_api-0.1.7 vs lib/nds_api/url.rb in nds_api-0.1.8

- old
+ new

@@ -71,15 +71,12 @@ end ##### PROVIDERS ##### def search_providers(params=nil) - # stg_search = 'http://staging-nds-api-app.emrcsv38cq.us-east-1.elasticbeanstalk.com/providers/search/findByCriteriaObject' - # prod_search = 'http://staging-nds-api-app.emrcsv38cq.us-east-1.elasticbeanstalk.com/providers/search/findByCriteriaObject' - # @prod ? prod_search : stg_search params = URI.encode_www_form(params) if params - "http://staging-nds-api-app.emrcsv38cq.us-east-1.elasticbeanstalk.com/providers/search/findByCriteriaObject#{params ? "?#{params}" : ''}" + "#{providers}/search/findByCriteriaObject#{params ? "?#{params}" : ''}" end def providers "#{base_url}/providers" end @@ -151,10 +148,13 @@ def referral_search "#{referrals}/search" end def base_url - # sub_domain = @prod ? 'uatup' : 'developer.staging' - "https://uatup.naccrraware.net/nds-api" + if @prod + "https://uatup.naccrraware.net/nds-api" + else + "http://staging-nds-api-app.emrcsv38cq.us-east-1.elasticbeanstalk.com" + end end end end