no message

This commit is contained in:
giuseppenuc committed 2016-04-29 10:40:09 +02:00
1 parent def9c0fd06
commit a5550fb7c2
2 files changed
+25 -3

No files matched your search

+13 -1
View File
@@ -41,6 +41,10 @@ typedef NS_ENUM(NSInteger, PNInstallationType) {
*/
- (void) resetBadge;
- (void) setRegistered;
- (void) setUpdated;
///--------------------------------------
#pragma mark - PNInstallation Properties
///--------------------------------------
@@ -80,6 +84,14 @@ typedef NS_ENUM(NSInteger, PNInstallationType) {
/**
* <#Description#>
*/
@property (nonatomic, strong, readonly, nullable) NSDate *lastUpdate;
@property (nonatomic, strong, readonly, nullable) NSDate *registeredAt;
/**
* <#Description#>
*/
@property (nonatomic, strong, readonly, nullable) NSDate *updatedAt;
/**
* <#Description#>
*/
@property (nonatomic, strong, readonly, nullable) NSDate *lastTokenUpdate;
@end
+12 -2
View File
@@ -37,7 +37,9 @@ static bool isFirstAccess = YES;
@"oldDeviceToken":@"oldDeviceToken",
@"badge":@"badge",
@"localeIdentifier":@"localeIdentifier",
@"lastUpdate":@"lastUpdate",
@"registeredAt":@"registeredAt",
@"updatedAt":@"updatedAt",
@"lastTokenUpdate":@"lastTokenUpdate",
};
return mapping;
}
@@ -95,7 +97,7 @@ static bool isFirstAccess = YES;
_oldDeviceToken = _deviceToken;
_deviceToken = ptoken;
if (response != PNInstallationTypeNone) {
_lastUpdate = [NSDate date];
_lastTokenUpdate = [NSDate date];
}
return response;
@@ -113,6 +115,14 @@ static bool isFirstAccess = YES;
[[UIApplication sharedApplication] setApplicationIconBadgeNumber:0];
}
- (void) setRegistered {
_registeredAt = [NSDate date];
}
- (void) setUpdated {
_updatedAt = [NSDate date];
}
#pragma mark -
#pragma mark Private Methods