添加埋点
This commit is contained in:
@@ -90,6 +90,12 @@
|
||||
[KBHUD showInfo:KBLocalized(@"Please Enter The Content")];
|
||||
return;
|
||||
}
|
||||
NSDictionary *extra = @{@"content_len": @(content.length)};
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_feedback_commit_btn"
|
||||
pageId:@"feedback"
|
||||
elementId:@"commit_btn"
|
||||
extra:extra
|
||||
completion:nil];
|
||||
__weak typeof(self) weakSelf = self;
|
||||
[self.viewModel submitFeedbackWithContent:content completion:^(BOOL success, NSError * _Nullable error) {
|
||||
if (!success) { return; }
|
||||
|
||||
@@ -257,6 +257,11 @@ static NSString * const kKBMyKeyboardCellId = @"kKBMyKeyboardCellId";
|
||||
|
||||
- (void)onSave {
|
||||
// 点击底部保存按钮时,调用更新用户人设排序接口
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_my_keyboard_save_btn"
|
||||
pageId:@"my_keyboard"
|
||||
elementId:@"save_btn"
|
||||
extra:nil
|
||||
completion:nil];
|
||||
[self kb_updateUserCharacterSortWithShowHUD:YES];
|
||||
}
|
||||
|
||||
|
||||
@@ -257,9 +257,21 @@
|
||||
|
||||
#pragma mark - Actions
|
||||
|
||||
- (void)onTapAvatarEdit { [self presentImagePicker]; }
|
||||
- (void)onTapAvatarEdit {
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_person_avatar_edit"
|
||||
pageId:@"person_info"
|
||||
elementId:@"avatar_edit"
|
||||
extra:nil
|
||||
completion:nil];
|
||||
[self presentImagePicker];
|
||||
}
|
||||
|
||||
- (void)onTapLogout {
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_person_logout_btn"
|
||||
pageId:@"person_info"
|
||||
elementId:@"logout_btn"
|
||||
extra:nil
|
||||
completion:nil];
|
||||
[self.myVM logout];
|
||||
}
|
||||
|
||||
|
||||
@@ -111,6 +111,13 @@ static NSString * const kMySkinCellId = @"kMySkinCellId";
|
||||
- (void)onToggleEdit {
|
||||
self.editingMode = !self.editingMode;
|
||||
|
||||
NSDictionary *extra = @{@"editing": @(self.isEditingMode)};
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_my_skin_toggle_edit"
|
||||
pageId:@"my_skin"
|
||||
elementId:@"toggle_edit"
|
||||
extra:extra
|
||||
completion:nil];
|
||||
|
||||
// 更新顶部按钮
|
||||
[self.kb_rightButton setTitle:(self.isEditingMode ? KBLocalized(@"Cancel") : KBLocalized(@"Editor"))
|
||||
forState:UIControlStateNormal];
|
||||
@@ -154,6 +161,13 @@ static NSString * const kMySkinCellId = @"kMySkinCellId";
|
||||
NSArray<NSIndexPath *> *selectedIndexPaths = [[self.collectionView indexPathsForSelectedItems] sortedArrayUsingSelector:@selector(compare:)];
|
||||
if (selectedIndexPaths.count == 0) return;
|
||||
|
||||
NSDictionary *preExtra = @{@"selected_count": @(selectedIndexPaths.count)};
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_my_skin_delete_btn"
|
||||
pageId:@"my_skin"
|
||||
elementId:@"delete_btn"
|
||||
extra:preExtra
|
||||
completion:nil];
|
||||
|
||||
NSMutableArray<NSString *> *themeIds = [NSMutableArray arrayWithCapacity:selectedIndexPaths.count];
|
||||
for (NSIndexPath *ip in selectedIndexPaths) {
|
||||
if (ip.item >= self.data.count) { continue; }
|
||||
@@ -245,6 +259,16 @@ static NSString * const kMySkinCellId = @"kMySkinCellId";
|
||||
// 非编辑态:可在此进入详情,当前示例不处理
|
||||
KBMyTheme *theme = self.data[indexPath.item];
|
||||
[collectionView deselectItemAtIndexPath:indexPath animated:YES];
|
||||
NSMutableDictionary *extra = [NSMutableDictionary dictionary];
|
||||
if ([theme.themeId isKindOfClass:NSString.class] && theme.themeId.length > 0) {
|
||||
extra[@"theme_id"] = theme.themeId;
|
||||
}
|
||||
extra[@"index"] = @(indexPath.item);
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_my_skin_theme_card"
|
||||
pageId:@"my_skin"
|
||||
elementId:@"theme_card"
|
||||
extra:extra.copy
|
||||
completion:nil];
|
||||
KBSkinDetailVC *vc = [[KBSkinDetailVC alloc] init];
|
||||
vc.themeId = theme.themeId;
|
||||
[self.navigationController pushViewController:vc animated:true];
|
||||
|
||||
@@ -120,6 +120,19 @@
|
||||
[tableView deselectRowAtIndexPath:indexPath animated:YES];
|
||||
NSDictionary *info = self.data[indexPath.section][indexPath.row];
|
||||
NSString *itemID = info[@"id"];
|
||||
NSMutableDictionary *extra = [NSMutableDictionary dictionary];
|
||||
if ([itemID isKindOfClass:NSString.class] && itemID.length > 0) {
|
||||
extra[@"item_id"] = itemID;
|
||||
}
|
||||
NSString *title = info[@"title"];
|
||||
if ([title isKindOfClass:NSString.class] && title.length > 0) {
|
||||
extra[@"item_title"] = title;
|
||||
}
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_my_menu_item"
|
||||
pageId:@"my"
|
||||
elementId:@"menu_item"
|
||||
extra:extra.copy
|
||||
completion:nil];
|
||||
if ([itemID isEqualToString:@"1"]) {
|
||||
[self.navigationController pushViewController:[KBNoticeVC new] animated:true];
|
||||
|
||||
@@ -159,6 +172,11 @@
|
||||
popover.permittedArrowDirections = 0;
|
||||
}
|
||||
UIPasteboard.generalPasteboard.string = textToCopy;
|
||||
[[KBMaiPointReporter sharedReporter] reportClickWithEventName:@"click_my_invite_copy"
|
||||
pageId:@"my"
|
||||
elementId:@"invite_copy"
|
||||
extra:nil
|
||||
completion:nil];
|
||||
[self presentViewController:activityVC animated:YES completion:nil];
|
||||
});
|
||||
}];
|
||||
|
||||
Reference in New Issue
Block a user