我收到一个 JSON 响应
apiResponse =
{ Appointment = 4;
Goals = 0;
Holiday = 0;
LessonPlan = 0;
ServiceLevel = 0;
SiteSetup = 0;
Student = 2;
TherapyLog = 0;
Worksite = 0;
};
我曾经获得价值
NSMutableDictionary* resultTables=[result objectForKey:@"apiResponse"];
int countVals=[[result objectForKey:tablename] intValue] ;
当我检查时
if (countVals>=0)
{
NSLog(@"Tables Names:%@",tablename);
[updatedTables addObject:tablename];
}else
{
NSLog(@"Tables Names:%@",tablename);
NSLog(@"no data to update");
}
表名未添加到 updateTables ARRAY。我的错是什么...