Dog*_*fee 20 ios parse-platform
这应该工作.
这是尝试解决这个问题的众多尝试之一
myTrainingSessions[indexPath.row].unpinInBackgroundWithBlock{ (succ, e) -> Void in
if succ == true {
// just remove from table view etc
self.myTrainingSessions[indexPath.row].deleteEventually()
self.myTrainingSessions.removeAtIndex(indexPath.row)
self.tableView.deleteRowsAtIndexPaths([indexPath], withRowAnimation: .Fade)
// Shows that my object is still in datastore!
// object should be UNPINNED - but appers in this result....
var query = PFQuery(className:TrainingSession.parseClassName())
query.whereKey(self.userType(), equalTo: PFUser.currentUser())
query.orderByDescending("createdAt")
query.fromLocalDatastore().ignoreACLs()
query.findObjectsInBackgroundWithBlock { (objects, error) -> Void in
if error != nil { return }
if let result = objects as? [TrainingSession] {
println("local results")
println(result)
}
}
}
}
Run Code Online (Sandbox Code Playgroud)
我取消固定后进行查询,对象仍在那里.
小智 3
我已就无法取消固定具有引用对象的对象的问题联系了支持团队,因此我为感兴趣的人共享该线程:
https://developers.facebook.com/bugs/138298746504630/
支持人员说这是按设计设计的,但在我要求改进此规范时,他告诉我他会告诉团队这件事。
| 归档时间: |
|
| 查看次数: |
3545 次 |
| 最近记录: |