refactor issue create and update functionality
This commit is contained in:
parent
da265616a7
commit
8e5c0ec534
|
@ -7,7 +7,7 @@
|
|||
objects = {
|
||||
|
||||
/* Begin PBXBuildFile section */
|
||||
2B62D0DF1796498800AC3C19 /* OZLIssueCreateViewController.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2B62D0DE1796498800AC3C19 /* OZLIssueCreateViewController.storyboard */; };
|
||||
2B62D0DF1796498800AC3C19 /* OZLIssueCreateOrUpdateViewController.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2B62D0DE1796498800AC3C19 /* OZLIssueCreateOrUpdateViewController.storyboard */; };
|
||||
2B62D0E1179649A800AC3C19 /* OZLIssueDetailViewController.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2B62D0E0179649A800AC3C19 /* OZLIssueDetailViewController.storyboard */; };
|
||||
2B62D0E31796A15C00AC3C19 /* OZLProjectInfoViewController.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2B62D0E21796A15C00AC3C19 /* OZLProjectInfoViewController.storyboard */; };
|
||||
2B62D0E81796A8D800AC3C19 /* OZLIssueFilterViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2B62D0E71796A8D800AC3C19 /* OZLIssueFilterViewController.m */; };
|
||||
|
@ -24,7 +24,7 @@
|
|||
2B8A11E217963CE500906D34 /* OZLIssueDetailViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2B8A11E117963CE500906D34 /* OZLIssueDetailViewController.m */; };
|
||||
2B9968AB1794F71B0086F115 /* OZLModelIssueCategory.m in Sources */ = {isa = PBXBuildFile; fileRef = 2B9968AA1794F71B0086F115 /* OZLModelIssueCategory.m */; };
|
||||
2B9968AF1794FC0A0086F115 /* OZLProjectInfoViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2B9968AD1794FC0A0086F115 /* OZLProjectInfoViewController.m */; };
|
||||
2B9968B417951A5C0086F115 /* OZLIssueCreateViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2B9968B217951A5C0086F115 /* OZLIssueCreateViewController.m */; };
|
||||
2B9968B417951A5C0086F115 /* OZLIssueCreateOrUpdateViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2B9968B217951A5C0086F115 /* OZLIssueCreateOrUpdateViewController.m */; };
|
||||
2BBE440F179E500E00FD9E20 /* OZLIssueLogtimeViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2BBE440E179E500E00FD9E20 /* OZLIssueLogtimeViewController.m */; };
|
||||
2BBE4411179E503100FD9E20 /* OZLIssueLogtimeViewController.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2BBE4410179E503100FD9E20 /* OZLIssueLogtimeViewController.storyboard */; };
|
||||
2BBE4414179E586B00FD9E20 /* OZLModelTimeEntryActivity.m in Sources */ = {isa = PBXBuildFile; fileRef = 2BBE4413179E586B00FD9E20 /* OZLModelTimeEntryActivity.m */; };
|
||||
|
@ -92,7 +92,7 @@
|
|||
/* End PBXContainerItemProxy section */
|
||||
|
||||
/* Begin PBXFileReference section */
|
||||
2B62D0DE1796498800AC3C19 /* OZLIssueCreateViewController.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = OZLIssueCreateViewController.storyboard; path = ViewControllers/OZLIssueCreateViewController.storyboard; sourceTree = "<group>"; };
|
||||
2B62D0DE1796498800AC3C19 /* OZLIssueCreateOrUpdateViewController.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = OZLIssueCreateOrUpdateViewController.storyboard; path = ViewControllers/OZLIssueCreateOrUpdateViewController.storyboard; sourceTree = "<group>"; };
|
||||
2B62D0E0179649A800AC3C19 /* OZLIssueDetailViewController.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = OZLIssueDetailViewController.storyboard; path = ViewControllers/OZLIssueDetailViewController.storyboard; sourceTree = "<group>"; };
|
||||
2B62D0E21796A15C00AC3C19 /* OZLProjectInfoViewController.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = OZLProjectInfoViewController.storyboard; path = ViewControllers/OZLProjectInfoViewController.storyboard; sourceTree = "<group>"; };
|
||||
2B62D0E61796A8D800AC3C19 /* OZLIssueFilterViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OZLIssueFilterViewController.h; path = ViewControllers/OZLIssueFilterViewController.h; sourceTree = "<group>"; };
|
||||
|
@ -114,8 +114,8 @@
|
|||
2B9968AA1794F71B0086F115 /* OZLModelIssueCategory.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OZLModelIssueCategory.m; path = Models/OZLModelIssueCategory.m; sourceTree = "<group>"; };
|
||||
2B9968AC1794FC0A0086F115 /* OZLProjectInfoViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OZLProjectInfoViewController.h; path = ViewControllers/OZLProjectInfoViewController.h; sourceTree = "<group>"; };
|
||||
2B9968AD1794FC0A0086F115 /* OZLProjectInfoViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OZLProjectInfoViewController.m; path = ViewControllers/OZLProjectInfoViewController.m; sourceTree = "<group>"; };
|
||||
2B9968B117951A5C0086F115 /* OZLIssueCreateViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OZLIssueCreateViewController.h; path = ViewControllers/OZLIssueCreateViewController.h; sourceTree = "<group>"; };
|
||||
2B9968B217951A5C0086F115 /* OZLIssueCreateViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OZLIssueCreateViewController.m; path = ViewControllers/OZLIssueCreateViewController.m; sourceTree = "<group>"; };
|
||||
2B9968B117951A5C0086F115 /* OZLIssueCreateOrUpdateViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OZLIssueCreateOrUpdateViewController.h; path = ViewControllers/OZLIssueCreateOrUpdateViewController.h; sourceTree = "<group>"; };
|
||||
2B9968B217951A5C0086F115 /* OZLIssueCreateOrUpdateViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OZLIssueCreateOrUpdateViewController.m; path = ViewControllers/OZLIssueCreateOrUpdateViewController.m; sourceTree = "<group>"; };
|
||||
2BBE440D179E500E00FD9E20 /* OZLIssueLogtimeViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = OZLIssueLogtimeViewController.h; path = ViewControllers/OZLIssueLogtimeViewController.h; sourceTree = "<group>"; };
|
||||
2BBE440E179E500E00FD9E20 /* OZLIssueLogtimeViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = OZLIssueLogtimeViewController.m; path = ViewControllers/OZLIssueLogtimeViewController.m; sourceTree = "<group>"; };
|
||||
2BBE4410179E503100FD9E20 /* OZLIssueLogtimeViewController.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = OZLIssueLogtimeViewController.storyboard; path = ViewControllers/OZLIssueLogtimeViewController.storyboard; sourceTree = "<group>"; };
|
||||
|
@ -329,9 +329,9 @@
|
|||
D5DB80A91792F6980081662A /* OZLProjectViewController.h */,
|
||||
D5DB80AA1792F6980081662A /* OZLProjectViewController.m */,
|
||||
D5DB80AB1792F6980081662A /* OZLProjectViewController.xib */,
|
||||
2B9968B117951A5C0086F115 /* OZLIssueCreateViewController.h */,
|
||||
2B9968B217951A5C0086F115 /* OZLIssueCreateViewController.m */,
|
||||
2B62D0DE1796498800AC3C19 /* OZLIssueCreateViewController.storyboard */,
|
||||
2B9968B117951A5C0086F115 /* OZLIssueCreateOrUpdateViewController.h */,
|
||||
2B9968B217951A5C0086F115 /* OZLIssueCreateOrUpdateViewController.m */,
|
||||
2B62D0DE1796498800AC3C19 /* OZLIssueCreateOrUpdateViewController.storyboard */,
|
||||
2B8A11E017963CE500906D34 /* OZLIssueDetailViewController.h */,
|
||||
2B8A11E117963CE500906D34 /* OZLIssueDetailViewController.m */,
|
||||
2B62D0E0179649A800AC3C19 /* OZLIssueDetailViewController.storyboard */,
|
||||
|
@ -620,7 +620,7 @@
|
|||
D5DB80A71792F4DE0081662A /* OZLProjectListViewController.xib in Resources */,
|
||||
D5DB80AD1792F6980081662A /* OZLProjectViewController.xib in Resources */,
|
||||
D5DB80B61793016B0081662A /* OZLAccountViewController.xib in Resources */,
|
||||
2B62D0DF1796498800AC3C19 /* OZLIssueCreateViewController.storyboard in Resources */,
|
||||
2B62D0DF1796498800AC3C19 /* OZLIssueCreateOrUpdateViewController.storyboard in Resources */,
|
||||
2B62D0E1179649A800AC3C19 /* OZLIssueDetailViewController.storyboard in Resources */,
|
||||
2B62D0E31796A15C00AC3C19 /* OZLProjectInfoViewController.storyboard in Resources */,
|
||||
2B6F382F1797A00A00D06F51 /* MLTableAlertBackground.png in Resources */,
|
||||
|
@ -697,7 +697,7 @@
|
|||
2BCF88301793F5CE006FC859 /* OZLModelUser.m in Sources */,
|
||||
2B9968AB1794F71B0086F115 /* OZLModelIssueCategory.m in Sources */,
|
||||
2B9968AF1794FC0A0086F115 /* OZLProjectInfoViewController.m in Sources */,
|
||||
2B9968B417951A5C0086F115 /* OZLIssueCreateViewController.m in Sources */,
|
||||
2B9968B417951A5C0086F115 /* OZLIssueCreateOrUpdateViewController.m in Sources */,
|
||||
2BCCA0541795312E00FA8B1A /* OZLConstants.m in Sources */,
|
||||
2B8A11E217963CE500906D34 /* OZLIssueDetailViewController.m in Sources */,
|
||||
2B62D0E81796A8D800AC3C19 /* OZLIssueFilterViewController.m in Sources */,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
//
|
||||
// OZLIssueCreateViewController.h
|
||||
// OZLIssueCreateOrUpdateViewController.h
|
||||
// RedmineMobile
|
||||
//
|
||||
// Created by lizhijie on 7/16/13.
|
||||
|
@ -32,12 +32,11 @@
|
|||
|
||||
typedef enum {
|
||||
OZLIssueInfoViewModeCreate,
|
||||
OZLIssueInfoViewModeDisplay,
|
||||
// OZLIssueInfoViewModeDisplay,
|
||||
OZLIssueInfoViewModeEdit
|
||||
} OZLIssueInfoViewMode;
|
||||
|
||||
|
||||
@interface OZLIssueCreateViewController : UITableViewController<UITextFieldDelegate,UIPickerViewDataSource,UIPickerViewDelegate>
|
||||
@interface OZLIssueCreateOrUpdateViewController : UITableViewController<UITextFieldDelegate,UIPickerViewDataSource,UIPickerViewDelegate>
|
||||
- (IBAction)onCancel:(id)sender;
|
||||
- (IBAction)onSave:(id)sender;
|
||||
|
||||
|
@ -63,7 +62,7 @@ typedef enum {
|
|||
@property(nonatomic,strong) OZLModelProject* parentProject;
|
||||
@property(nonatomic,strong) OZLModelIssue* parentIssue;
|
||||
@property(nonatomic, strong) OZLModelIssue* issueData;// used for update issue
|
||||
@property(nonatomic) int isUpdatingIssue;
|
||||
@property(nonatomic) OZLIssueInfoViewMode viewMode;
|
||||
|
||||
//@property(nonatomic,strong) NSArray* issueList;
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
//
|
||||
// OZLIssueCreateViewController.m
|
||||
// OZLIssueCreateOrUpdateViewController.m
|
||||
// RedmineMobile
|
||||
//
|
||||
// Created by lizhijie on 7/16/13.
|
||||
|
@ -26,7 +26,7 @@
|
|||
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
// THE SOFTWARE.
|
||||
|
||||
#import "OZLIssueCreateViewController.h"
|
||||
#import "OZLIssueCreateOrUpdateViewController.h"
|
||||
#import "OZLNetwork.h"
|
||||
#import "MBProgressHUD.h"
|
||||
#import "OZLModelIssuePriority.h"
|
||||
|
@ -36,7 +36,7 @@
|
|||
#import "MLTableAlert.h"
|
||||
#import "OZLSingleton.h"
|
||||
|
||||
@interface OZLIssueCreateViewController () {
|
||||
@interface OZLIssueCreateOrUpdateViewController () {
|
||||
|
||||
NSDate* _currentStartDate;
|
||||
NSDate* _currentDueDate;
|
||||
|
@ -47,7 +47,7 @@
|
|||
|
||||
@end
|
||||
|
||||
@implementation OZLIssueCreateViewController
|
||||
@implementation OZLIssueCreateOrUpdateViewController
|
||||
|
||||
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
|
||||
{
|
||||
|
@ -123,7 +123,7 @@
|
|||
|
||||
-(void)initializeViewValues
|
||||
{
|
||||
if (_isUpdatingIssue) { // initial values for ui elements
|
||||
if (_viewMode == OZLIssueInfoViewModeEdit) { // initial values for ui elements
|
||||
_subjectTextField.text = _issueData.subject;
|
||||
if (_issueData.tracker) {
|
||||
_trackerLabel.text = _issueData.tracker.name;
|
||||
|
@ -146,8 +146,7 @@
|
|||
_estimatedHoursLabel.text = [NSString stringWithFormat:@"%f",_issueData.estimatedHours];
|
||||
_doneProgressLabel.text = [NSString stringWithFormat:@"%d %%",(int)_issueData.doneRatio];
|
||||
|
||||
|
||||
}else {
|
||||
}else if(_viewMode == OZLIssueInfoViewModeCreate){
|
||||
_issueData = [[OZLModelIssue alloc] init];
|
||||
}
|
||||
|
||||
|
@ -201,9 +200,9 @@
|
|||
}else if(_parentProject){
|
||||
_issueData.projectId = _parentProject.index;
|
||||
}
|
||||
if (_isUpdatingIssue) {
|
||||
if (_viewMode == OZLIssueInfoViewModeEdit) {
|
||||
_issueData.notes = _descriptionTextview.text;
|
||||
}else {
|
||||
}else if(_viewMode == OZLIssueInfoViewModeCreate) {
|
||||
_issueData.description = _descriptionTextview.text;
|
||||
}
|
||||
_issueData.startDate = _startDateLabel.text;
|
||||
|
@ -214,7 +213,7 @@
|
|||
|
||||
|
||||
_HUD.mode = MBProgressHUDModeIndeterminate;
|
||||
if (_isUpdatingIssue) {
|
||||
if (_viewMode == OZLIssueInfoViewModeEdit) {
|
||||
_HUD.labelText = @"Updating Issue ...";
|
||||
[_HUD show:YES];
|
||||
[OZLNetwork updateIssue:_issueData withParams:nil andBlock:^(BOOL success, NSError *error){
|
||||
|
@ -232,7 +231,7 @@
|
|||
[self.navigationController popViewControllerAnimated:YES];
|
||||
}
|
||||
}];
|
||||
}else {
|
||||
}else if(_viewMode == OZLIssueInfoViewModeCreate){
|
||||
_HUD.labelText = @"Creating New Issue ...";
|
||||
[_HUD show:YES];
|
||||
[OZLNetwork createIssue:_issueData withParams:nil andBlock:^(BOOL success, NSError *error){
|
||||
|
@ -373,9 +372,9 @@
|
|||
{
|
||||
if (section == 0) {
|
||||
NSString* tip ;
|
||||
if (_isUpdatingIssue) {
|
||||
if (_viewMode == OZLIssueInfoViewModeEdit) {
|
||||
tip = [NSString stringWithFormat:@"Update issue #%d",_issueData.index];
|
||||
}else {
|
||||
}else if(_viewMode == OZLIssueInfoViewModeCreate){
|
||||
if (_parentIssue) {
|
||||
tip = [NSString stringWithFormat:@"Add sub issue to #%d",_parentIssue.index];
|
||||
}else {
|
||||
|
@ -384,9 +383,9 @@
|
|||
}
|
||||
return tip;
|
||||
}else if(section == 3) {
|
||||
if (_isUpdatingIssue) {
|
||||
if (_viewMode == OZLIssueInfoViewModeEdit) {
|
||||
return @"Notes";
|
||||
}else {
|
||||
}else if(_viewMode == OZLIssueInfoViewModeCreate){
|
||||
return @"Description";
|
||||
}
|
||||
}
|
|
@ -4,10 +4,10 @@
|
|||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="2083"/>
|
||||
</dependencies>
|
||||
<scenes>
|
||||
<!--Issue Create View Controller-->
|
||||
<!--Issue Create Or Update View Controller-->
|
||||
<scene sceneID="GEH-4c-FXE">
|
||||
<objects>
|
||||
<tableViewController storyboardIdentifier="OZLIssueCreateViewController" useStoryboardIdentifierAsRestorationIdentifier="YES" id="ttR-PV-prh" customClass="OZLIssueCreateViewController" sceneMemberID="viewController">
|
||||
<tableViewController storyboardIdentifier="OZLIssueCreateOrUpdateViewController" useStoryboardIdentifierAsRestorationIdentifier="YES" id="ttR-PV-prh" customClass="OZLIssueCreateOrUpdateViewController" sceneMemberID="viewController">
|
||||
<tableView key="view" opaque="NO" clipsSubviews="YES" clearsContextBeforeDrawing="NO" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="static" style="grouped" separatorStyle="singleLineEtched" rowHeight="44" sectionHeaderHeight="10" sectionFooterHeight="10" id="bcd-EK-AUb">
|
||||
<rect key="frame" x="0.0" y="64" width="320" height="504"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
|
@ -289,6 +289,25 @@
|
|||
<point key="canvasLocation" x="196" y="43"/>
|
||||
</scene>
|
||||
</scenes>
|
||||
<classes>
|
||||
<class className="OZLIssueCreateOrUpdateViewController" superclassName="UITableViewController">
|
||||
<source key="sourceIdentifier" type="project" relativePath="./Classes/OZLIssueCreateOrUpdateViewController.h"/>
|
||||
<relationships>
|
||||
<relationship kind="action" name="onCancel:"/>
|
||||
<relationship kind="action" name="onSave:"/>
|
||||
<relationship kind="outlet" name="assigneeLabel" candidateClass="UILabel"/>
|
||||
<relationship kind="outlet" name="descriptionTextview" candidateClass="UITextView"/>
|
||||
<relationship kind="outlet" name="doneProgressLabel" candidateClass="UITextField"/>
|
||||
<relationship kind="outlet" name="dueDateLabel" candidateClass="UITextField"/>
|
||||
<relationship kind="outlet" name="estimatedHoursLabel" candidateClass="UITextField"/>
|
||||
<relationship kind="outlet" name="priorityLabel" candidateClass="UILabel"/>
|
||||
<relationship kind="outlet" name="startDateLabel" candidateClass="UITextField"/>
|
||||
<relationship kind="outlet" name="statusLabel" candidateClass="UILabel"/>
|
||||
<relationship kind="outlet" name="subjectTextField" candidateClass="UITextField"/>
|
||||
<relationship kind="outlet" name="trackerLabel" candidateClass="UILabel"/>
|
||||
</relationships>
|
||||
</class>
|
||||
</classes>
|
||||
<simulatedMetricsContainer key="defaultSimulatedMetrics">
|
||||
<simulatedStatusBarMetrics key="statusBar"/>
|
||||
<simulatedOrientationMetrics key="orientation"/>
|
|
@ -30,7 +30,7 @@
|
|||
#import "OZLIssueHistoryViewController.h"
|
||||
#import "OZLIssueLogtimeViewController.h"
|
||||
#import "OZLSingleton.h"
|
||||
#import "OZLIssueCreateViewController.h"
|
||||
#import "OZLIssueCreateOrUpdateViewController.h"
|
||||
|
||||
@interface OZLIssueDetailViewController ()
|
||||
|
||||
|
@ -93,8 +93,8 @@
|
|||
[self.navigationController pushViewController:history animated:YES];
|
||||
}break;
|
||||
case 1:{// add sub task
|
||||
UIStoryboard *tableViewStoryboard = [UIStoryboard storyboardWithName:@"OZLIssueCreateViewController" bundle:nil];
|
||||
OZLIssueCreateViewController* creator = [tableViewStoryboard instantiateViewControllerWithIdentifier:@"OZLIssueCreateViewController"];
|
||||
UIStoryboard *tableViewStoryboard = [UIStoryboard storyboardWithName:@"OZLIssueCreateOrUpdateViewController" bundle:nil];
|
||||
OZLIssueCreateOrUpdateViewController* creator = [tableViewStoryboard instantiateViewControllerWithIdentifier:@"OZLIssueCreateOrUpdateViewController"];
|
||||
[creator setParentIssue:_issueData];
|
||||
[self.navigationController pushViewController:creator animated:YES];
|
||||
}break;
|
||||
|
@ -105,10 +105,10 @@
|
|||
[self.navigationController pushViewController:creator animated:YES];
|
||||
}break;
|
||||
case 3:{ // update
|
||||
UIStoryboard *tableViewStoryboard = [UIStoryboard storyboardWithName:@"OZLIssueCreateViewController" bundle:nil];
|
||||
OZLIssueCreateViewController* creator = [tableViewStoryboard instantiateViewControllerWithIdentifier:@"OZLIssueCreateViewController"];
|
||||
UIStoryboard *tableViewStoryboard = [UIStoryboard storyboardWithName:@"OZLIssueCreateOrUpdateViewController" bundle:nil];
|
||||
OZLIssueCreateOrUpdateViewController* creator = [tableViewStoryboard instantiateViewControllerWithIdentifier:@"OZLIssueCreateOrUpdateViewController"];
|
||||
[creator setIssueData:_issueData];
|
||||
[creator setIsUpdatingIssue:YES];
|
||||
[creator setViewMode:OZLIssueInfoViewModeEdit];
|
||||
[self.navigationController pushViewController:creator animated:YES];
|
||||
}break;
|
||||
default:
|
||||
|
|
|
@ -48,6 +48,6 @@ typedef enum {
|
|||
@property (nonatomic,strong) NSArray* projectList;
|
||||
|
||||
@property (nonatomic, strong) OZLModelProject* projectData;
|
||||
@property (nonatomic) int viewMode;
|
||||
@property (nonatomic) OZLProjectInfoViewMode viewMode;
|
||||
|
||||
@end
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
#import "MBProgressHUD.h"
|
||||
#import "OZLProjectInfoViewController.h"
|
||||
#import "OZLIssueDetailViewController.h"
|
||||
#import "OZLIssueCreateViewController.h"
|
||||
#import "OZLIssueCreateOrUpdateViewController.h"
|
||||
#import "OZLIssueFilterViewController.h"
|
||||
#import "OZLSingleton.h"
|
||||
|
||||
|
@ -357,10 +357,11 @@
|
|||
}
|
||||
|
||||
- (IBAction)onNewIssue:(id)sender {
|
||||
//OZLIssueCreateViewController* creator = [[OZLIssueCreateViewController alloc] initWithNibName:@"OZLIssueCreateViewController" bundle:nil];
|
||||
UIStoryboard *tableViewStoryboard = [UIStoryboard storyboardWithName:@"OZLIssueCreateViewController" bundle:nil];
|
||||
OZLIssueCreateViewController* creator = [tableViewStoryboard instantiateViewControllerWithIdentifier:@"OZLIssueCreateViewController"];
|
||||
//OZLIssueCreateOrUpdateViewController* creator = [[OZLIssueCreateOrUpdateViewController alloc] initWithNibName:@"OZLIssueCreateOrUpdateViewController" bundle:nil];
|
||||
UIStoryboard *tableViewStoryboard = [UIStoryboard storyboardWithName:@"OZLIssueCreateOrUpdateViewController" bundle:nil];
|
||||
OZLIssueCreateOrUpdateViewController* creator = [tableViewStoryboard instantiateViewControllerWithIdentifier:@"OZLIssueCreateOrUpdateViewController"];
|
||||
[creator setParentProject:_projectData];
|
||||
[creator setViewMode:OZLIssueInfoViewModeCreate];
|
||||
//[self.navigationController presentModalViewController:creator animated:YES];
|
||||
[self.navigationController pushViewController:creator animated:YES];
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue