Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit bcbac61

Browse files
wanghenghengEase
authored and
Ease
committed
push代码,只有一个commit的,进入到对应的commit;多于一个的,进入到commit列表
1 parent 6219374 commit bcbac61

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

‎Coding_iOS/Controllers/ProjectMemberActivityListViewController.m

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -166,12 +166,21 @@ - (void)goToVCWithItem:(HtmlMediaItem *)clickedItem activity:(ProjectActivity *)
166166
}else{
167167
[NSObject showHudTipStr:@"没找到 Fork 到哪里去了~"];
168168
}
169+
}else if ([proAct.action isEqualToString:@"push"]){
170+
if (proAct.commits.count == 1) {
171+
Commit *firstCommit = [proAct.commits firstObject];
172+
NSString *request_path = [NSString stringWithFormat:@"%@/commit/%@", proAct.depot.path, firstCommit.sha];
173+
CommitFilesViewController *vc = [CommitFilesViewController vcWithPath:request_path];
174+
[self.navigationController pushViewController:vc animated:YES];
175+
}else{
176+
NSString *ref = proAct.ref? proAct.ref : @"master";
177+
ProjectCommitsViewController *vc = [ProjectCommitsViewController new];
178+
vc.curProject = project;
179+
vc.curCommits = [Commits commitsWithRef:ref Path:@""];
180+
[self.navigationController pushViewController:vc animated:YES];
181+
}
169182
}else{
170183
ProjectViewController *vc = [ProjectViewController codeVCWithCodeRef:proAct.ref andProject:project];
171-
// NSString *ref = proAct.ref? proAct.ref : @"master";
172-
// ProjectCommitsViewController *vc = [ProjectCommitsViewController new];
173-
// vc.curProject = project;
174-
// vc.curCommits = [Commits commitsWithRef:ref Path:@""];
175184
[self.navigationController pushViewController:vc animated:YES];
176185
}
177186
}else if ([target_type isEqualToString:@"PullRequestBean"] ||

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /