0
我正在嘗試創建一個應用程序,其中每個PFObject
的類別分別爲Verifications
和Verified_By
。解析 - PFObject不更新
Verifications
由許多,並且Verified_By
是一個字符串數組
當我嘗試更新的類別和保存PFObject
,該數據是正確的,並保存在本地,但是當我打電話saveInBackground
,它不在數據瀏覽器中不會更新。
這裏是我的更新代碼:
if (![verifiedBy containsObject:[ViewController getUserName]]) {
//havent verified
NSMutableArray *newArray = [NSMutableArray arrayWithArray:verifiedBy];
[newArray addObject:[ViewController getUserName]];
[toModify setObject:newArray forKey:@"Verified_By"];
[toModify incrementKey:@"Verifications"];
[toModify saveInBackground];
[[[UIAlertView alloc] initWithTitle:@"Verified!" message:@"You have successfully verified this" delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil, nil] show];
}
else {
[[[UIAlertView alloc] initWithTitle:@"Already Verified" message:@"You have already verified this" delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil, nil] show];
你試過' saveInBackgroundWithBlock'並檢查錯誤? – Wain
@所以我做了,我收到了輸出:'Error Domain = Parse Code = 101「無法完成操作(解析錯誤101。)」'以及找不到更新對象。我介紹了這一點,並且本地設備上的所有數據都是正確的。 – Jeeter
對象有什麼關係/角色? – Wain