Page 1 of 2

api URL parameter dynamic

Posted: Tue Jun 07, 2016 11:49 am
by Billy Williams

I have added the rest service and my REST url is
https://agwebv01.ag.utk.edu/silorest/...

i have added that as a request parameter and it even says that it will replace that in the url and not add as the GET parameter.
but in my code I have tried to set that id parameter

requestData.params.id = sessionStorage.getItem("PERNR");

but when it runs and tries to execute it. I can see in the browser console its trying to call

https://agwebv01.ag.utk.edu/silorest/...
instead of the proper

https://agwebv01.ag.utk.edu/silorest/...

how do i make this work?


api URL parameter dynamic

Posted: Wed Jun 08, 2016 7:46 am
by Serhii Kulibaba

Hello Billy,

Please send us screenshots of service settings and JS code, which you exactly use to execute that service


api URL parameter dynamic

Posted: Wed Jun 08, 2016 11:39 am
by Billy Williams

api URL parameter dynamic

Posted: Wed Jun 08, 2016 11:39 am
by Billy Williams

api URL parameter dynamic

Posted: Wed Jun 08, 2016 1:35 pm
by Serhii Kulibaba

It looks correct. Please provide us with a public app link (https://devcenter.appery.io/documenta...) and exact steps to reproduce this problem.


api URL parameter dynamic

Posted: Wed Jun 08, 2016 3:51 pm
by Billy Williams

http://appery.io/app/mobile-frame?src...

when you go there just type in "wil" for last name
click on the first one
in the console.log you will see where it makes the incorrect REST call

angular.js:10514 OPTIONS https://agwebv01.ag.utk.edu/silorest/...


api URL parameter dynamic

Posted: Fri Jun 10, 2016 9:08 am
by Serhii Kulibaba

Please delete edited (blue colored) files on Source tab and click Undo all source changes on folder with edited files.

Please note that functionality added via Source tab will be lost and you would need to edit source files again in order to add it back, thus we would recommend that you save project backup before that.

[Here] (http://devcenter.appery.io/tutorials/...) is more information about Source files editing.


api URL parameter dynamic

Posted: Fri Jun 10, 2016 12:14 pm
by Billy Williams

ok i did that
now i get this in the URL

https://agwebv01.ag.utk.edu/silorest/...

its not dropping the {id} just changing it to %7Bid%7D


api URL parameter dynamic

Posted: Mon Jun 13, 2016 4:37 pm
by Serhii Kulibaba

What I'm doing wrong? Image
Please provice the URL, which you need to use exactly fo that request


api URL parameter dynamic

Posted: Mon Jun 13, 2016 4:44 pm
by Billy Williams

if i put in the id it should be https://agwebv01.ag.utk.edu/silorest/...

that

https://agwebv01.ag.utk.edu/silorest/...
the {id} should drop off when setting id = 208277