Skip to content

Commit 7e58e47

Browse files
committed
意见反馈提交到iOS项目,评论@别人不加冒号
1 parent 3e17a04 commit 7e58e47

9 files changed

Lines changed: 17 additions & 10 deletions

File tree

Coding_iOS/AppDelegate.m

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,13 @@ - (void)customizeInterface {
211211

212212
#pragma mark URL Schemes
213213
- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url sourceApplication:(NSString *)sourceApplication annotation:(id)annotation{
214+
NSMutableDictionary *params = [[NSMutableDictionary alloc] init];
215+
for (NSString *param in [[url query] componentsSeparatedByString:@"&"]) {
216+
NSArray *elts = [param componentsSeparatedByString:@"="];
217+
if([elts count] < 2) continue;
218+
[params setObject:elts[1] forKey:elts[0]];
219+
}
220+
NSLog(@"path: %@, params: %@", [url path], params);
214221
return YES;
215222
}
216223

Coding_iOS/Controllers/EditTaskViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ - (void)deleteTask:(Task *)toDelete{
263263
#pragma mark Comment To Task
264264
- (void)sendCommentMessage:(id)obj{
265265
if (_toComment) {
266-
_myCopyTask.nextCommentStr = [NSString stringWithFormat:@"@%@ : %@", _toComment.owner.name, obj];
266+
_myCopyTask.nextCommentStr = [NSString stringWithFormat:@"@%@ %@", _toComment.owner.name, obj];
267267
}else{
268268
_myCopyTask.nextCommentStr = obj;
269269
}

Coding_iOS/Controllers/RootControllers/Tweet_RootViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,7 @@ - (void)hideToolBar:(BOOL)hide{
463463
#pragma mark Comment To Tweet
464464
- (void)sendCommentMessage:(id)obj{
465465
if (_commentIndex >= 0) {
466-
_commentTweet.nextCommentStr = [NSString stringWithFormat:@"@%@ : %@", _commentToUser.name, obj];
466+
_commentTweet.nextCommentStr = [NSString stringWithFormat:@"@%@ %@", _commentToUser.name, obj];
467467
}else{
468468
_commentTweet.nextCommentStr = obj;
469469
}

Coding_iOS/Controllers/TopicDetailViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ - (void)deleteTopic:(ProjectTopic *)curTopic isComment:(BOOL)isC{
330330
- (void)sendCommentMessage:(id)obj{
331331
__weak typeof(self) weakSelf = self;
332332
if (_toComment) {
333-
_curTopic.nextCommentStr = [NSString stringWithFormat:@"@%@ : %@", _toComment.owner.name, obj];
333+
_curTopic.nextCommentStr = [NSString stringWithFormat:@"@%@ %@", _toComment.owner.name, obj];
334334
}else{
335335
_curTopic.nextCommentStr = obj;
336336
}

Coding_iOS/Controllers/TweetDetailViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@ - (void)doCommentToComment:(Comment *)toComment sender:(id)sender{
344344

345345
- (void)sendCommentMessage:(id)obj{
346346
if (_toComment) {
347-
_curTweet.nextCommentStr = [NSString stringWithFormat:@"@%@ : %@", _toComment.owner.name, obj];
347+
_curTweet.nextCommentStr = [NSString stringWithFormat:@"@%@ %@", _toComment.owner.name, obj];
348348
}else{
349349
_curTweet.nextCommentStr = obj;
350350
}

Coding_iOS/Controllers/UserTweetsViewController.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ - (void)scrollViewWillBeginDragging:(UIScrollView *)scrollView{
319319
#pragma mark Comment To Tweet
320320
- (void)sendCommentMessage:(id)obj{
321321
if (_commentIndex >= 0) {
322-
_commentTweet.nextCommentStr = [NSString stringWithFormat:@"@%@ : %@", _commentToUser.name, obj];
322+
_commentTweet.nextCommentStr = [NSString stringWithFormat:@"@%@ %@", _commentToUser.name, obj];
323323
}else{
324324
_commentTweet.nextCommentStr = obj;
325325
}

Coding_iOS/Models/ProjectTopic.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ - (void)setContent:(NSString *)content{
3737

3838
+ (ProjectTopic *)feedbackTopic{
3939
ProjectTopic *topic = [[ProjectTopic alloc] init];
40-
topic.project_id = [NSNumber numberWithInteger:182];
4140
topic.project = [Project project_FeedBack];
41+
topic.project_id = topic.project.id;
4242
return topic;
4343
}
4444

Coding_iOS/Models/Projects.m

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,6 @@ +(Project *)project_All{
114114

115115
+ (Project *)project_FeedBack{
116116
Project *pro = [[Project alloc] init];
117-
// pro.id = [NSNumber numberWithInteger:182];//网页反馈项目
118117
pro.id = [NSNumber numberWithInteger:38894];//iOS公开项目
119118
pro.is_public = [NSNumber numberWithBool:YES];
120119
return pro;

Coding_iOS/Util/Manager/Coding_NetAPIManager.m

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -720,11 +720,12 @@ - (void)request_ModifyProjectTpoic:(ProjectTopic *)proTopic andBlock:(void (^)(i
720720
}];
721721
}
722722
- (void)request_AddProjectTpoic:(ProjectTopic *)proTopic andBlock:(void (^)(id data, NSError *error))block{
723-
[MobClick event:kUmeng_Event_Request label:(proTopic.project_id && proTopic.project_id.integerValue == 182)? @"发送反馈" : @"添加讨论"];
724-
[self showStatusBarQueryStr:(proTopic.project_id && proTopic.project_id.integerValue == 182)? @"正在发送反馈信息": @"正在添加讨论"];
723+
NSInteger feedbackId = 38894;
724+
[MobClick event:kUmeng_Event_Request label:(proTopic.project_id && proTopic.project_id.integerValue == feedbackId)? @"发送反馈" : @"添加讨论"];
725+
[self showStatusBarQueryStr:(proTopic.project_id && proTopic.project_id.integerValue == feedbackId)? @"正在发送反馈信息": @"正在添加讨论"];
725726
[[CodingNetAPIClient sharedJsonClient] requestJsonDataWithPath:[proTopic toAddTopicPath] withParams:[proTopic toAddTopicParams] withMethodType:Post andBlock:^(id data, NSError *error) {
726727
if (data) {
727-
[self showStatusBarSuccessStr:(proTopic.project_id && proTopic.project_id.integerValue == 182)? @"反馈成功": @"添加讨论成功"];
728+
[self showStatusBarSuccessStr:(proTopic.project_id && proTopic.project_id.integerValue == feedbackId)? @"反馈成功": @"添加讨论成功"];
728729
id resultData = [data valueForKeyPath:@"data"];
729730
ProjectTopic *resultT = [NSObject objectOfClass:@"ProjectTopic" fromJSON:resultData];
730731
block(resultT, nil);

0 commit comments

Comments
 (0)