Data binding concepts #13013
Unanswered
beppo-ivel
asked this question in
Q&A
Replies: 1 comment
-
https://wiki.appcelerator.org/display/guides2/Alloy+Data+Binding#AlloyDataBinding-Backbonebinding |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
My index.xml contains a label. The text of this label should be initialized by the last record of my table. Alloy and Backbone offers to use fetch to query the table. Fetch is async and if I want to do some further calculations on the result I have to deal with callbacks or come up with my own promise. I can see the advantage to use alloy/backbone by defining my model and connect it with the view, but it looks like a disadvantage if you want to query data and do further operations on the result. What I want to know is, which pattern is recommended using the async fetch/promise or should I use titanium db-connect where I can execute queries in a sync way (https://docs.axway.com/bundle/Titanium_SDK_allOS_en/page/working_with_a_sqlite_database.html)? Or can I combine both, defining the model via alloy and query it with a titanium db-connector.
index.js
index.xml
models/test.js
Beta Was this translation helpful? Give feedback.
All reactions