diff options
| author | LV-426 <lv-426@taproot.org.il> | 2014-12-03 15:08:50 +0200 |
|---|---|---|
| committer | LV-426 <lv-426@taproot.org.il> | 2014-12-03 15:23:22 +0200 |
| commit | e6d5472df95d551f9b7fd8bcf9824387736da833 (patch) | |
| tree | 4dae547e97474002ad4a1c3f2d31ffb3bb737dde /src/rz_api_backend.js | |
| parent | 591ea9d4a1f0b36c5caf062dbfaffbc7dbb348e9 (diff) | |
construct backend URL using rz_config
Diffstat (limited to 'src/rz_api_backend.js')
| -rw-r--r-- | src/rz_api_backend.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/rz_api_backend.js b/src/rz_api_backend.js index df162225..7acf5916 100644 --- a/src/rz_api_backend.js +++ b/src/rz_api_backend.js @@ -3,10 +3,12 @@ /** * API calls designed to execute against a local backend service */ -define([], function() { +define(['rz_config'], function(rz_config) { function RZ_API_Backend() { + var rz_server_url = 'http://' + rz_config.rz_server_host + ':' + rz_config.rz_server_port; + /** * issue rhizi server ajax call */ @@ -41,7 +43,7 @@ define([], function() { req_opts.timeout = 8000; // ms req_opts.crossDomain = true; - $.ajax('http://127.0.0.1:3000' + path, req_opts); + $.ajax(rz_server_url + path, req_opts); } /** |
