Page 1 of 3
Mapping item_add service
Posted: Tue Oct 22, 2013 12:03 pm
by Johnny
I did this tutorial http://docs.appery.io/tutorials/build...
But when I create the service no "acl" is created. So when I add the parameter manually it still not working.
It stores the data but it does not connect the data to a user.
Mapping item_add service
Posted: Tue Oct 22, 2013 12:28 pm
by Maryna Brodina
Hello! Could you clarify what code you've added to mapping?
Mapping item_add service
Posted: Tue Oct 22, 2013 12:34 pm
by Johnny
ok in the acl I added this code
var acl = {};
acl[value]= { "read": true, "write": true };
return acl;
Mapping item_add service
Posted: Tue Oct 22, 2013 12:52 pm
by Maryna Brodina
Should be working if userId and localStorage are correct.Please check on back-end admin console if the record was saved. Could you also clarify what do you mean on "not connect the data to a user"? How do you check that?
Mapping item_add service
Posted: Tue Oct 22, 2013 1:05 pm
by Johnny
When I login with a user i registered and want to display the data. It does not give me the data. When I check on the database after registration i see the acl on my data collection is empty.
Mapping item_add service
Posted: Tue Oct 22, 2013 1:51 pm
by Maryna Brodina
Do you send rest of feelds correctly? Please check what service returns - on service Complete event add the following code:
preconsole.log(jqXHR.responseText);/pre and check console
Mapping item_add service
Posted: Tue Oct 22, 2013 2:13 pm
by Johnny
Ok I will do this. And to answer the previous question. It stores the id in local storage.
Mapping item_add service
Posted: Wed Oct 23, 2013 7:04 am
by Johnny
it only show [] and then on the left in the console I click on login.js line 815 and it go to console.log(jqXHR.responseText);
other code:
listins = new Appery.DataSource(person_login_ShothtermInsurance_list_service, {
'onComplete': function(jqXHR, textStatus) {
console.log(jqXHR.responseText);
Mapping item_add service
Posted: Wed Oct 23, 2013 7:19 am
by Johnny
I can add again, my local storage is working and do change when i login with different users. But still no data is list after invoking the service on the page show event.
Don't what i am missing...
Mapping item_add service
Posted: Wed Oct 23, 2013 12:22 pm
by Maryna Brodina
Hello! Should be working. Could you give us your public app link?