-
Notifications
You must be signed in to change notification settings - Fork 1.3k
/
Copy pathMRPR.h
55 lines (47 loc) · 1.62 KB
/
MRPR.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
//
// MRPR.h
// Coding_iOS
//
// Created by Ease on 15/5/29.
// Copyright (c) 2015年 Coding. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "Depot.h"
typedef NS_ENUM(NSInteger, MRPRStatus) {
MRPRStatusCanMerge = 0,
MRPRStatusCannotMerge,
MRPRStatusAccepted,
MRPRStatusRefused,
MRPRStatusCancel
};
@interface MRPR : NSObject
@property (strong, nonatomic) NSNumber *id, *iid, *srcExist, *comment_count, *granted;
@property (strong, nonatomic) NSString *title, *path, *srcBranch, *desBranch, *merge_status, *src_owner_name,*source_branch,*target_branch;
@property (strong, nonatomic) NSString *des_owner_name, *des_project_name;
@property (strong, nonatomic) User *author, *action_author;
@property (strong, nonatomic) NSDate *created_at, *action_at;
@property (strong, nonatomic) Depot *source_depot;
@property (assign, nonatomic) MRPRStatus status;
@property (assign, nonatomic) BOOL isLoading;
//Post
@property (assign, nonatomic) BOOL del_source_branch, can_edit_src_branch;
@property (strong, nonatomic) NSString *message;
@property (strong, nonatomic) NSArray *body;
@property (readwrite, nonatomic, strong) NSDictionary *propertyArrayMap;
+ (MRPR *)mrprWithPath:(NSString *)path;
- (NSString *)statusDisplay;
- (BOOL)isMR;
- (BOOL)isPR;
- (NSString *)toPrePath;
- (NSString *)toBasePath;
- (NSString *)toReviewersPath;
- (NSString *)toCommitsPath;
- (NSString *)toFileChangesPath;
- (NSString *)toFileLineChangesPath;
- (NSString *)toAcceptPath;
- (NSDictionary *)toAcceptParams;
- (NSString *)toRefusePath;
- (NSString *)toCancelPath;
- (NSString *)toCancelMRPath;
- (NSString *)toAuthorizationPath;
@end