Commit 0dff9eba by Rune Madsen

Merge pull request #13 from Shopify/runmad.7-add-product-tags

Product tags
parents 7999156b bdcaf115
......@@ -89,6 +89,12 @@
@property (nonatomic, readonly, assign) BOOL available;
/**
* A categorization that a product can be tagged with, commonly used for filtering and searching.
* Each tag has a character limit of 255.
*/
@property (nonatomic, readonly, copy) NSSet *tags;
/**
* The product is published on the current sales channel
*/
@property (nonatomic, readonly, assign) BOOL published;
......
......@@ -53,6 +53,9 @@
_createdAtDate = [dateFormatter dateFromString:dictionary[@"created_at"]];
_updatedAtDate = [dateFormatter dateFromString:dictionary[@"updated_at"]];
_publishedAtDate = [dateFormatter dateFromString:dictionary[@"published_at"]];
NSArray *tagsArray = [dictionary[@"tags"] componentsSeparatedByString:@", "];
NSSet *tagsSet = [NSSet setWithArray:tagsArray];
_tags = [tagsSet copy];
}
@end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment