0
從解析雲功能調用時,如何從專用函數返回Sequence對象。解析返回對象
function getNextMemberId() {
var id = -1;
var Zseq = Parse.Object.extend("ZSeqMember");
var query = new Parse.Query(Zseq);
var IncObj;
query.get("lcnm8AZWFK", {
success: function (object) {
object.increment("Seq");
object.save(null,
{
success: function (object) { },
error: function (object, error) { return Parse.Promise.error(error); }
}
);
}, error: function (object, error) {
console.log(error);
return Parse.Promise.error(error);
}
});
//I want to return the Object, which contains "Seq" column.
}