Skip to content

Instantly share code, notes, and snippets.

@samsoir
Created November 2, 2012 19:52
Show Gist options
  • Save samsoir/4003937 to your computer and use it in GitHub Desktop.
Save samsoir/4003937 to your computer and use it in GitHub Desktop.
- (void)configureTableCellForStatus:(UITableViewCell *)cell jobModel:(MSASitteratiJob *)job
{
NSString *statusString = NSLocalizedStringFromTable(@"Pending", @"MyJobs", @"Pending");
BOOL jobAccepted = (job.acceptedSitter != nil);
if (jobAccepted)
{
statusString = NSLocalizedStringFromTable(@"Accepted", @"MyJobs", @"Accepted");
}
cell.detailTextLabel.text = statusString;
cell.textLabel.text = [self.dateDecorator stringFromDate:job.startDateTime];
cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment