Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
红
红星美凯龙管理在线APP IOS
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张杰
红星美凯龙管理在线APP IOS
Commits
ddab2987
Commit
ddab2987
authored
9 years ago
by
admin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
完成sop主界面
parent
88f94923
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
581 additions
and
26 deletions
+581
-26
project.pbxproj
redstar.xcodeproj/project.pbxproj
+50
-0
UserInterfaceState.xcuserstate
...userdata/admin.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
Url.h
redstar/Classes/Macro/Url.h
+3
-0
AttachmentTableViewCell.h
...le/Announce/AnnounceDetail/Cell/AttachmentTableViewCell.h
+14
-0
AttachmentTableViewCell.m
...le/Announce/AnnounceDetail/Cell/AttachmentTableViewCell.m
+71
-0
AnnoDetailViewController.m
.../AnnounceDetail/ViewController/AnnoDetailViewController.m
+43
-16
SOPTableView.h
.../Module/Function/Standar/SOPCategarys/View/SOPTableView.h
+22
-0
SOPTableView.m
.../Module/Function/Standar/SOPCategarys/View/SOPTableView.m
+81
-0
SOPViewController.h
...n/Standar/SOPCategarys/ViewController/SOPViewController.h
+13
-0
SOPViewController.m
...n/Standar/SOPCategarys/ViewController/SOPViewController.m
+253
-0
StandardViewController.m
.../Function/Standar/ViewController/StandardViewController.m
+13
-6
HomeViewController.m
...r/Classes/Module/Home/ViewController/HomeViewController.m
+4
-4
HttpClient.h
redstar/Classes/Tools/HttpClient/HttpClient.h
+3
-0
HttpClient.m
redstar/Classes/Tools/HttpClient/HttpClient.m
+11
-0
No files found.
redstar.xcodeproj/project.pbxproj
View file @
ddab2987
...
...
@@ -120,6 +120,9 @@
84CEB1721C2946EC0072ED0A
/* StoreDetailModel.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84CEB1711C2946EC0072ED0A
/* StoreDetailModel.m */
;
};
84CF0F1E1BE9B40400C855CE
/* InspectDetailFooterView.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84CF0F1D1BE9B40400C855CE
/* InspectDetailFooterView.m */
;
};
84CF0FA21BE9EDA900C855CE
/* TakePhotoView.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84CF0FA11BE9EDA900C855CE
/* TakePhotoView.m */
;
};
84D2F5171C2CD3D400651EFB
/* SOPViewController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84D2F5161C2CD3D400651EFB
/* SOPViewController.m */
;
};
84D2F51A1C2CE67500651EFB
/* SOPTableView.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84D2F5191C2CE67500651EFB
/* SOPTableView.m */
;
};
84D2F5201C2D213400651EFB
/* AttachmentTableViewCell.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84D2F51F1C2D213400651EFB
/* AttachmentTableViewCell.m */
;
};
84D3E5F01C04BC8C001FF1DD
/* InspectUploadedViewController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84D3E5EF1C04BC8C001FF1DD
/* InspectUploadedViewController.m */
;
};
84D3E5F31C04BCD3001FF1DD
/* InspectNotUploadViewController.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84D3E5F21C04BCD3001FF1DD
/* InspectNotUploadViewController.m */
;
};
84D3E5F91C04BD8E001FF1DD
/* InspectNotUpLoadCell.m in Sources */
=
{
isa
=
PBXBuildFile
;
fileRef
=
84D3E5F81C04BD8E001FF1DD
/* InspectNotUpLoadCell.m */
;
};
...
...
@@ -405,6 +408,12 @@
84CF0F1D1BE9B40400C855CE
/* InspectDetailFooterView.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
InspectDetailFooterView.m
;
sourceTree
=
"<group>"
;
};
84CF0FA01BE9EDA900C855CE
/* TakePhotoView.h */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
TakePhotoView.h
;
sourceTree
=
"<group>"
;
};
84CF0FA11BE9EDA900C855CE
/* TakePhotoView.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
TakePhotoView.m
;
sourceTree
=
"<group>"
;
};
84D2F5151C2CD3D400651EFB
/* SOPViewController.h */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
SOPViewController.h
;
sourceTree
=
"<group>"
;
};
84D2F5161C2CD3D400651EFB
/* SOPViewController.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
SOPViewController.m
;
sourceTree
=
"<group>"
;
};
84D2F5181C2CE67500651EFB
/* SOPTableView.h */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
SOPTableView.h
;
sourceTree
=
"<group>"
;
};
84D2F5191C2CE67500651EFB
/* SOPTableView.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
SOPTableView.m
;
sourceTree
=
"<group>"
;
};
84D2F51E1C2D213400651EFB
/* AttachmentTableViewCell.h */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
AttachmentTableViewCell.h
;
sourceTree
=
"<group>"
;
};
84D2F51F1C2D213400651EFB
/* AttachmentTableViewCell.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
AttachmentTableViewCell.m
;
sourceTree
=
"<group>"
;
};
84D3E5EE1C04BC8C001FF1DD
/* InspectUploadedViewController.h */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
InspectUploadedViewController.h
;
sourceTree
=
"<group>"
;
};
84D3E5EF1C04BC8C001FF1DD
/* InspectUploadedViewController.m */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.objc
;
path
=
InspectUploadedViewController.m
;
sourceTree
=
"<group>"
;
};
84D3E5F11C04BCD3001FF1DD
/* InspectNotUploadViewController.h */
=
{
isa
=
PBXFileReference
;
fileEncoding
=
4
;
lastKnownFileType
=
sourcecode.c.h
;
path
=
InspectNotUploadViewController.h
;
sourceTree
=
"<group>"
;
};
...
...
@@ -721,6 +730,7 @@
8426A4AD1BDF0CD600E5FDF5
/* Standard */
=
{
isa
=
PBXGroup
;
children
=
(
84D2F5111C2CD3C300651EFB
/* SOPCategarys */
,
84CC34D91C09538E002F10E2
/* StandardHandout */
,
84CC34D51C094557002F10E2
/* Cell */
,
8426A4AE1BDF0CD600E5FDF5
/* View */
,
...
...
@@ -1464,6 +1474,8 @@
children
=
(
849B2F6F1C0CA22F005D809F
/* AnnoContentTableViewCell.h */
,
849B2F701C0CA22F005D809F
/* AnnoContentTableViewCell.m */
,
84D2F51E1C2D213400651EFB
/* AttachmentTableViewCell.h */
,
84D2F51F1C2D213400651EFB
/* AttachmentTableViewCell.m */
,
);
path
=
Cell
;
sourceTree
=
"<group>"
;
...
...
@@ -1869,6 +1881,41 @@
path
=
View
;
sourceTree
=
"<group>"
;
};
84D2F5111C2CD3C300651EFB
/* SOPCategarys */
=
{
isa
=
PBXGroup
;
children
=
(
84D2F5121C2CD3C300651EFB
/* Cell */
,
84D2F5131C2CD3C300651EFB
/* View */
,
84D2F5141C2CD3C300651EFB
/* ViewController */
,
);
path
=
SOPCategarys
;
sourceTree
=
"<group>"
;
};
84D2F5121C2CD3C300651EFB
/* Cell */
=
{
isa
=
PBXGroup
;
children
=
(
);
path
=
Cell
;
sourceTree
=
"<group>"
;
};
84D2F5131C2CD3C300651EFB
/* View */
=
{
isa
=
PBXGroup
;
children
=
(
84D2F5181C2CE67500651EFB
/* SOPTableView.h */
,
84D2F5191C2CE67500651EFB
/* SOPTableView.m */
,
);
path
=
View
;
sourceTree
=
"<group>"
;
};
84D2F5141C2CD3C300651EFB
/* ViewController */
=
{
isa
=
PBXGroup
;
children
=
(
84D2F5151C2CD3D400651EFB
/* SOPViewController.h */
,
84D2F5161C2CD3D400651EFB
/* SOPViewController.m */
,
);
path
=
ViewController
;
sourceTree
=
"<group>"
;
};
84DB9BC11BDCD49900822CC4
/* CustomDropMenu */
=
{
isa
=
PBXGroup
;
children
=
(
...
...
@@ -2269,6 +2316,7 @@
8474A01C1BE368D700315F30
/* HomeCellItem.m in Sources */
,
8409BDFD1C281ACD00354460
/* TreeView.m in Sources */
,
8409BDFB1C281ACD00354460
/* TreeNodeModel.m in Sources */
,
84D2F5171C2CD3D400651EFB
/* SOPViewController.m in Sources */
,
84CC34D11C093C5E002F10E2
/* LookOnLineViewController.m in Sources */
,
84D863731C11923F00E4F4CC
/* AddQuestionTableCell.m in Sources */
,
84D8257F1BDD2F7E00CC61F7
/* MineTableFooterView.m in Sources */
,
...
...
@@ -2289,6 +2337,7 @@
848A201D1C180C1900422FAB
/* OnLineCompleteDetailCell.m in Sources */
,
84CEB16F1C2946DB0072ED0A
/* OnLineDetailModel.m in Sources */
,
84F57C461BEC388A00DDEEB1
/* CommentView.m in Sources */
,
84D2F51A1C2CE67500651EFB
/* SOPTableView.m in Sources */
,
84ED5DD81BF2E64300A1BB6D
/* ScreenView.m in Sources */
,
8474C5831BE751A2007DCF19
/* CommonFunc.m in Sources */
,
84AD4F491BF4BC0600BFB37C
/* RankDetailTableCell.m in Sources */
,
...
...
@@ -2314,6 +2363,7 @@
8473E3881C1BBFF600960257
/* InspectTaskDetailCell.m in Sources */
,
84F57C9C1BECA73800DDEEB1
/* StarBar.m in Sources */
,
84F57C4C1BEC785E00DDEEB1
/* AddQuestionViewController.m in Sources */
,
84D2F5201C2D213400651EFB
/* AttachmentTableViewCell.m in Sources */
,
84C9729F1C1ADD17003A3276
/* PictureCommentTableCell.m in Sources */
,
849A18461C152EBA00071600
/* AddPictureTableCell.m in Sources */
,
84D80EB51BF714BE00A10EA4
/* GroupItems.m in Sources */
,
...
...
This diff is collapsed.
Click to expand it.
redstar.xcworkspace/xcuserdata/admin.xcuserdatad/UserInterfaceState.xcuserstate
View file @
ddab2987
No preview for this file type
This diff is collapsed.
Click to expand it.
redstar/Classes/Macro/Url.h
View file @
ddab2987
...
...
@@ -119,4 +119,7 @@
// 获取下级组织
#define kQueryLowerOrgsURL @"redstar-server/rest/organization/queryLowerOrgs"
// 口碑标注附件列表
#define kGetAttachmentsURL @"redstar-server/rest/standardpraise/get_attachments"
#endif
/* Url_h */
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Announce/AnnounceDetail/Cell/AttachmentTableViewCell.h
0 → 100644
View file @
ddab2987
//
// AttachmentTableViewCell.h
// redstar
//
// Created by admin on 15/12/25.
// Copyright © 2015年 ZWF. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface
AttachmentTableViewCell
:
UITableViewCell
@property
(
nonatomic
,
strong
)
UIButton
*
nameBtn
;
@property
(
nonatomic
,
strong
)
UIButton
*
downloadBtn
;
@end
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Announce/AnnounceDetail/Cell/AttachmentTableViewCell.m
0 → 100644
View file @
ddab2987
//
// AttachmentTableViewCell.m
// redstar
//
// Created by admin on 15/12/25.
// Copyright © 2015年 ZWF. All rights reserved.
//
#import "AttachmentTableViewCell.h"
@implementation
AttachmentTableViewCell
-
(
UIButton
*
)
nameBtn
{
if
(
!
_nameBtn
)
{
_nameBtn
=
[[
UIButton
alloc
]
init
];
_nameBtn
.
backgroundColor
=
[
UIColor
grayColor
];
_nameBtn
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
_nameBtn
.
layer
.
cornerRadius
=
4
.
0
;
[
self
.
contentView
addSubview
:
_nameBtn
];
NSLayoutConstraint
*
lineViewTop
=
[
NSLayoutConstraint
constraintWithItem
:
_nameBtn
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
5
];
[
self
.
contentView
addConstraint
:
lineViewTop
];
NSLayoutConstraint
*
lineViewRight
=
[
NSLayoutConstraint
constraintWithItem
:
_nameBtn
attribute
:
NSLayoutAttributeRight
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeCenterX
multiplier
:
1
.
0
constant
:-
20
];
[
self
.
contentView
addConstraint
:
lineViewRight
];
NSLayoutConstraint
*
lineViewBottom
=
[
NSLayoutConstraint
constraintWithItem
:
_nameBtn
attribute
:
NSLayoutAttributeBottom
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:-
5
];
[
self
.
contentView
addConstraint
:
lineViewBottom
];
NSLayoutConstraint
*
lineViewLeft
=
[
NSLayoutConstraint
constraintWithItem
:
_nameBtn
attribute
:
NSLayoutAttributeLeft
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeLeft
multiplier
:
1
.
0
constant
:
10
];
[
self
.
contentView
addConstraint
:
lineViewLeft
];
NSLayoutConstraint
*
lineViewHeight
=
[
NSLayoutConstraint
constraintWithItem
:
_nameBtn
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
35
];
[
self
.
contentView
addConstraint
:
lineViewHeight
];
}
return
_nameBtn
;
}
-
(
UIButton
*
)
downloadBtn
{
if
(
!
_downloadBtn
)
{
_downloadBtn
=
[[
UIButton
alloc
]
init
];
_downloadBtn
.
backgroundColor
=
[
UIColor
grayColor
];
_downloadBtn
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
_downloadBtn
.
layer
.
cornerRadius
=
4
.
0
;
[
self
.
contentView
addSubview
:
_downloadBtn
];
NSLayoutConstraint
*
lineViewTop
=
[
NSLayoutConstraint
constraintWithItem
:
_downloadBtn
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
5
];
[
self
.
contentView
addConstraint
:
lineViewTop
];
NSLayoutConstraint
*
lineViewRight
=
[
NSLayoutConstraint
constraintWithItem
:
_downloadBtn
attribute
:
NSLayoutAttributeRight
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeRight
multiplier
:
1
.
0
constant
:-
20
];
[
self
.
contentView
addConstraint
:
lineViewRight
];
NSLayoutConstraint
*
lineViewBottom
=
[
NSLayoutConstraint
constraintWithItem
:
_downloadBtn
attribute
:
NSLayoutAttributeBottom
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:-
5
];
[
self
.
contentView
addConstraint
:
lineViewBottom
];
NSLayoutConstraint
*
lineViewLeft
=
[
NSLayoutConstraint
constraintWithItem
:
_downloadBtn
attribute
:
NSLayoutAttributeLeft
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeCenterX
multiplier
:
1
.
0
constant
:
10
];
[
self
.
contentView
addConstraint
:
lineViewLeft
];
}
return
_downloadBtn
;
}
-
(
void
)
setSelected
:
(
BOOL
)
selected
animated
:
(
BOOL
)
animated
{
[
super
setSelected
:
selected
animated
:
animated
];
// Configure the view for the selected state
}
@end
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Announce/AnnounceDetail/ViewController/AnnoDetailViewController.m
View file @
ddab2987
...
...
@@ -15,8 +15,10 @@
#import "AnnounceDetailModel.h"
#
define kAnnounceContentCell @"AnnoContentTableViewCell
"
#
import "AttachmentTableViewCell.h
"
#define kAnnounceContentCell @"AnnoContentTableViewCell"
#define kAttachmentTableViewCell @"AttachmentTableViewCell"
@interface
AnnoDetailViewController
()
<
UITableViewDataSource
,
UITableViewDelegate
>
@property
(
nonatomic
,
strong
)
UITableView
*
tableView
;
...
...
@@ -43,7 +45,7 @@
NSString
*
url
=
[
NSString
stringWithFormat
:
@"%@%@%@"
,
kRedStarURL
,
kAnnounceDetailURL
,
self
.
affiche_uuid
];
HttpClient
*
httpCilent
=
[[
HttpClient
alloc
]
initWithUrl
:
url
];
[
httpCilent
getAnnounceDetailWithCompletion
:
^
(
id
response
,
NSError
*
error
)
{
NSLog
(
@"anno详情 = %@"
,
response
);
NSLog
(
@"anno
公告
详情 = %@"
,
response
);
NSDictionary
*
dict
=
response
[
@"data"
];
AnnounceDetailModel
*
annoDetail
=
[
AnnounceDetailModel
announceDetailModelWithDict
:
dict
];
_annoDetail
=
annoDetail
;
...
...
@@ -94,6 +96,15 @@
}
-
(
void
)
showFile
:
(
UIButton
*
)
sender
{
}
-
(
void
)
downloadFile
:
(
UIButton
*
)
sender
{
}
-
(
void
)
didReceiveMemoryWarning
{
[
super
didReceiveMemoryWarning
];
...
...
@@ -103,13 +114,13 @@
#pragma mark - UITableView Delegate/DataSource
-
(
NSInteger
)
tableView
:
(
UITableView
*
)
tableView
numberOfRowsInSection
:
(
NSInteger
)
section
{
return
1
;
return
1
+
_annoDetail
.
attachmentUrls
.
count
;
}
// cell显示的内容
-
(
UITableViewCell
*
)
tableView
:
(
UITableView
*
)
tableView
cellForRowAtIndexPath
:
(
NSIndexPath
*
)
indexPath
{
if
(
indexPath
.
row
==
0
)
{
AnnoContentTableViewCell
*
cell
=
[
tableView
dequeueReusableCellWithIdentifier
:
kAnnounceContentCell
];
if
(
!
cell
)
{
cell
=
[[
AnnoContentTableViewCell
alloc
]
initWithStyle
:
UITableViewCellStyleValue1
reuseIdentifier
:
kAnnounceContentCell
];
...
...
@@ -123,6 +134,22 @@
cell
.
backgroundColor
=
kAnnounceHeaderColor
;
cell
.
selectionStyle
=
UITableViewCellSelectionStyleNone
;
return
cell
;
}
else
{
AttachmentTableViewCell
*
cell
=
[
tableView
dequeueReusableCellWithIdentifier
:
kAttachmentTableViewCell
];
if
(
!
cell
)
{
cell
=
[[
AttachmentTableViewCell
alloc
]
initWithStyle
:
UITableViewCellStyleValue1
reuseIdentifier
:
kAttachmentTableViewCell
];
}
NSDictionary
*
dict
=
_annoDetail
.
attachmentUrls
[
indexPath
.
row
-
1
];
NSString
*
name
=
dict
[
@"fileName"
];
[
cell
.
nameBtn
setTitle
:
name
forState
:
UIControlStateNormal
];
[
cell
.
downloadBtn
setTitle
:
@"下载"
forState
:
UIControlStateNormal
];
[
cell
.
nameBtn
addTarget
:
self
action
:
@selector
(
showFile
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
[
cell
.
downloadBtn
addTarget
:
self
action
:
@selector
(
downloadFile
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
return
cell
;
}
}
...
...
@@ -140,7 +167,7 @@
_tableView
.
tableHeaderView
=
self
.
headerView
;
_tableView
.
tableFooterView
=
self
.
footerView
;
[
_tableView
registerClass
:[
AnnoContentTableViewCell
class
]
forCellReuseIdentifier
:
kAnnounceContentCell
];
[
_tableView
registerClass
:[
AttachmentTableViewCell
class
]
forCellReuseIdentifier
:
kAttachmentTableViewCell
];
[
self
.
view
addSubview
:
_tableView
];
NSLayoutConstraint
*
tableTop
=
[
NSLayoutConstraint
constraintWithItem
:
_tableView
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
view
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
0
];
...
...
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Function/Standar/SOPCategarys/View/SOPTableView.h
0 → 100644
View file @
ddab2987
//
// SOPTableView.h
// redstar
//
// Created by admin on 15/12/25.
// Copyright © 2015年 ZWF. All rights reserved.
//
#import <UIKit/UIKit.h>
@protocol
SOPTableViewDelegate
<
NSObject
>
-
(
void
)
selectRowWithDetailTitle
:
(
NSString
*
)
detailTitle
;
@end
@interface
SOPTableView
:
UITableView
@property
(
nonatomic
,
assign
)
id
<
SOPTableViewDelegate
>
sop_delegate
;
-
(
instancetype
)
initWithFrame
:(
CGRect
)
frame
style
:(
UITableViewStyle
)
style
titleArray
:(
NSArray
*
)
titleArray
;
-
(
instancetype
)
initWithTitleArray
:(
NSArray
*
)
titleArray
;
@end
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Function/Standar/SOPCategarys/View/SOPTableView.m
0 → 100644
View file @
ddab2987
//
// SOPTableView.m
// redstar
//
// Created by admin on 15/12/25.
// Copyright © 2015年 ZWF. All rights reserved.
//
#import "SOPTableView.h"
@interface
SOPTableView
()
<
UITableViewDelegate
,
UITableViewDataSource
>
@property
(
nonatomic
,
strong
)
NSArray
*
titleArray
;
@end
@implementation
SOPTableView
-
(
instancetype
)
initWithFrame
:(
CGRect
)
frame
style
:(
UITableViewStyle
)
style
titleArray
:(
NSArray
*
)
titleArray
{
self
=
[
super
initWithFrame
:
frame
style
:
style
];
if
(
self
)
{
_titleArray
=
titleArray
;
[
self
setup
];
}
return
self
;
}
-
(
instancetype
)
initWithTitleArray
:(
NSArray
*
)
titleArray
{
self
=
[
super
init
];
if
(
self
)
{
_titleArray
=
titleArray
;
[
self
setup
];
}
return
self
;
}
-
(
void
)
setup
{
self
.
delegate
=
self
;
self
.
dataSource
=
self
;
}
#pragma mark - UItableView Delegate/DataSource
-
(
NSInteger
)
tableView
:
(
UITableView
*
)
tableView
numberOfRowsInSection
:
(
NSInteger
)
section
{
return
_titleArray
.
count
;
}
-
(
UITableViewCell
*
)
tableView
:
(
UITableView
*
)
tableView
cellForRowAtIndexPath
:
(
NSIndexPath
*
)
indexPath
{
UITableViewCell
*
cell
=
[
tableView
dequeueReusableCellWithIdentifier
:
@"cell333"
];
if
(
!
cell
)
{
cell
=
[[
UITableViewCell
alloc
]
initWithStyle
:
UITableViewCellStyleValue1
reuseIdentifier
:
@"cell333"
];
}
cell
.
textLabel
.
text
=
_titleArray
[
indexPath
.
row
];
cell
.
textLabel
.
font
=
[
UIFont
systemFontOfSize
:
15
.
0
];
cell
.
textLabel
.
textColor
=
kLightBlack
;
cell
.
textLabel
.
numberOfLines
=
0
;
return
cell
;
}
-
(
CGFloat
)
tableView
:
(
UITableView
*
)
tableView
heightForHeaderInSection
:
(
NSInteger
)
section
{
return
CGFLOAT_MIN
;
}
-
(
CGFloat
)
tableView
:
(
UITableView
*
)
tableView
heightForFooterInSection
:
(
NSInteger
)
section
{
return
CGFLOAT_MIN
;
}
-
(
void
)
tableView
:
(
UITableView
*
)
tableView
didSelectRowAtIndexPath
:
(
NSIndexPath
*
)
indexPath
{
if
(
_sop_delegate
&&
[
_sop_delegate
respondsToSelector
:
@selector
(
selectRowWithDetailTitle
:)])
{
[
_sop_delegate
selectRowWithDetailTitle
:
_titleArray
[
indexPath
.
row
]];
}
}
@end
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Function/Standar/SOPCategarys/ViewController/SOPViewController.h
0 → 100644
View file @
ddab2987
//
// SOPViewController.h
// redstar
//
// Created by admin on 15/12/25.
// Copyright © 2015年 ZWF. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface
SOPViewController
:
UIViewController
@end
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Function/Standar/SOPCategarys/ViewController/SOPViewController.m
0 → 100644
View file @
ddab2987
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Function/Standar/ViewController/StandardViewController.m
View file @
ddab2987
...
...
@@ -9,6 +9,7 @@
#import "StandardViewController.h"
#import "StandardTableViewCell.h"
#import "HandOutViewController.h"
#import "SOPViewController.h"
#define kStandardTableViewCell @"standardTableViewCell"
@interface
StandardViewController
()
<
UITableViewDelegate
,
UITableViewDataSource
>
...
...
@@ -102,14 +103,20 @@
-
(
void
)
tableView
:
(
UITableView
*
)
tableView
didSelectRowAtIndexPath
:
(
NSIndexPath
*
)
indexPath
{
if
(
indexPath
.
section
==
0
)
{
SOPViewController
*
sopVC
=
[[
SOPViewController
alloc
]
init
];
[
self
.
navigationController
pushViewController
:
sopVC
animated
:
YES
];
}
else
if
(
indexPath
.
section
==
1
)
{
UIAlertView
*
alert
=
[[
UIAlertView
alloc
]
initWithTitle
:
@"提示"
message
:
@"该功能正在努力开发中!"
delegate
:
self
cancelButtonTitle
:
nil
otherButtonTitles
:
@"确定"
,
nil
];
[
alert
show
];
// if (indexPath.section == 1) {
// HandOutViewController *hoandOutVC = [[HandOutViewController alloc] init];
// [self.navigationController pushViewController:hoandOutVC animated:YES];
// }
}
else
{
UIAlertView
*
alert
=
[[
UIAlertView
alloc
]
initWithTitle
:
@"提示"
message
:
@"该功能正在努力开发中!"
delegate
:
self
cancelButtonTitle
:
nil
otherButtonTitles
:
@"确定"
,
nil
];
[
alert
show
];
}
}
#pragma mark - lazy laoding
...
...
This diff is collapsed.
Click to expand it.
redstar/Classes/Module/Home/ViewController/HomeViewController.m
View file @
ddab2987
...
...
@@ -495,12 +495,12 @@ typedef NSComparisonResult (^NSComparator)(id obj1, id obj2);
// [alert show];
// return;
LookOnLineViewController
*
lookOnLine
=
[[
LookOnLineViewController
alloc
]
init
];
nav
=
[[
UINavigationController
alloc
]
initWithRootViewController
:
lookOnLine
];
//
LookOnLineViewController *lookOnLine = [[LookOnLineViewController alloc] init];
//
nav = [[UINavigationController alloc] initWithRootViewController:lookOnLine];
//
StandardViewController *standardVC = [[StandardViewController alloc] init];
//
nav = [[UINavigationController alloc] initWithRootViewController:standardVC];
StandardViewController
*
standardVC
=
[[
StandardViewController
alloc
]
init
];
nav
=
[[
UINavigationController
alloc
]
initWithRootViewController
:
standardVC
];
}
else
if
([
item
.
titleLabel
.
text
isEqualToString
:
@"图说口碑"
])
{
PictureViewController
*
pictureVC
=
[[
PictureViewController
alloc
]
init
];
nav
=
[[
UINavigationController
alloc
]
initWithRootViewController
:
pictureVC
];
...
...
This diff is collapsed.
Click to expand it.
redstar/Classes/Tools/HttpClient/HttpClient.h
View file @
ddab2987
...
...
@@ -122,4 +122,7 @@ typedef void (^completionBlock) (id response, NSError *error);
// 查询下级参数
-
(
void
)
queryLowerOrgsWithParameters
:(
id
)
parameters
completion
:(
completionBlock
)
completion
;
// 获取口碑标准的附件列表
-
(
void
)
getAttachmentsWithParameters
:(
id
)
parameters
completion
:(
completionBlock
)
completion
;
@end
This diff is collapsed.
Click to expand it.
redstar/Classes/Tools/HttpClient/HttpClient.m
View file @
ddab2987
...
...
@@ -419,4 +419,15 @@
}];
}
// 获取口碑标准的附件列表
-
(
void
)
getAttachmentsWithParameters
:
(
id
)
parameters
completion
:
(
completionBlock
)
completion
{
[
self
postParameters
:
parameters
completion
:
^
(
id
response
,
NSError
*
error
)
{
if
(
completion
)
{
completion
(
response
,
error
);
}
}];
}
@end
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment