I did it and no luck.
I did it and no luck.
Hello! You have some problem with app logic. In listinsurance service in where parameter you pass userId, but there is no userId field in DB (there is just acl with such user, but it's hard to sort using it). You would need to add userId field in Insurance collection and use it to sort in where parameter of listinsurance service instead _id field.
Thank you for the help!
So just to make sure I understand. Must the user fill in his name on every screen with the other fields?
What if I create a ID field at registration where the user must give his indetification number. then I sort with that?
Hi Johnny,
Appery.io will create a unique ID field for each user. You get this value when user login to your application.
You should:
a) add another field 'userId' to the collection 'Insurance'
b) save there the ID of user logged into the application (you can do it directly from localStorage, displaying it is not necessary)
Thank you, I will update the app and let you know how it works thank you for the help
I done like you told me. It looks like that it is storing it correctly. But Im stuck at the list and update. How do I show only that user using the field I created in your step a.
Hello! Use where parameter in http://docs.appery.io/documentation/b... request. Do sorting using this field pre{"userId" : "xxxxxxxxxx"}/pre you have userId stored in localStorage, so you need to retrieve it from localStorage
Sorry for my stupidity but how do I inpliment that examples like curl -X GET
-H "X-Appery-Database-Id: 526fdbd8e4b07c3286b537f1"
-G --data-urlencode 'where={"studentId": {"$lt": 50}}'
https://api.appery.io/1/db/collection...
Hello! It would be GET request with the following URL https://api.appery.io/1/db/collection... and two request parameters parameters.