I am new to angularjs and phonegap. In my application I am using sqlitedatabase by using sqlite plugin. I am able to create and insert values into tables but I am not able retrieve those values. Please find the below code.
self.fetchAll = function(result) {
var output = [];
for(var i = 0; i < result.rows.length; i++) {
output.push(result.rows.item(i));
}
return output;
};
self.isTermsVisited = function(){
alert('doSomething');
return DB.query('SELECT * FROM Others').then(function(result) {
return DB.fetchAll(result);
});
};
the above method not returning any values.
Please help me.
Aucun commentaire:
Enregistrer un commentaire