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
0b9ca0aa
Commit
0b9ca0aa
authored
Dec 31, 2015
by
admin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
首页添加了 优秀案例 巡店报告
parent
c102b2e0
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
175 additions
and
115 deletions
+175
-115
UserInterfaceState.xcuserstate
...userdata/admin.xcuserdatad/UserInterfaceState.xcuserstate
+0
-0
Breakpoints_v2.xcbkptlist
...ta/admin.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
+0
-16
AnnoDetailViewController.m
.../AnnounceDetail/ViewController/AnnoDetailViewController.m
+1
-4
AnnounceViewController.m
...unce/AnnounceList/ViewController/AnnounceViewController.m
+0
-1
SelectStoreViewController.m
...ne/SelectStore/ViewController/SelectStoreViewController.m
+2
-11
PictureStoryViewController.m
...PictureDetail/ViewController/PictureStoryViewController.m
+5
-41
AddQuestionTableCell.h
...Function/Question/AddQuestion/Cell/AddQuestionTableCell.h
+1
-0
AddQuestionTableCell.m
...Function/Question/AddQuestion/Cell/AddQuestionTableCell.m
+37
-6
AddQuestionFooterView.m
...unction/Question/AddQuestion/View/AddQuestionFooterView.m
+3
-2
AddQuestionViewController.m
...on/AddQuestion/ViewController/AddQuestionViewController.m
+10
-3
QuestionDetailCell.m
...unction/Question/QuestionDetail/Cell/QuestionDetailCell.m
+1
-2
SOPViewController.m
...n/Standar/SOPCategarys/ViewController/SOPViewController.m
+7
-10
InspectAddCell.m
...n/WordOfMouth/Inspect/InspectDetail/Cell/InspectAddCell.m
+2
-2
InspectNotUpLoadCell.m
...OfMouth/Inspect/InspectDetail/Cell/InspectNotUpLoadCell.m
+1
-1
InspectPicAddCell.m
...ordOfMouth/Inspect/InspectDetail/Cell/InspectPicAddCell.m
+2
-2
InspectUpLoadFootView.m
...fMouth/Inspect/InspectDetail/View/InspectUpLoadFootView.m
+7
-1
InspectUploadedViewController.m
...pectDetail/ViewController/InspectUploadedViewController.m
+0
-2
InspectTaskDetailCell.m
...dOfMouth/Inspect/InspectTask/Cell/InspectTaskDetailCell.m
+1
-1
InspectTaskViewController.m
...ct/InspectTask/ViewController/InspectTaskViewController.m
+6
-1
HomeViewController.m
...r/Classes/Module/Home/ViewController/HomeViewController.m
+89
-9
No files found.
redstar.xcworkspace/xcuserdata/admin.xcuserdatad/UserInterfaceState.xcuserstate
View file @
0b9ca0aa
No preview for this file type
redstar.xcworkspace/xcuserdata/admin.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist
View file @
0b9ca0aa
...
...
@@ -13,21 +13,5 @@
stopOnStyle =
"0"
>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID =
"Xcode.Breakpoint.FileBreakpoint"
>
<BreakpointContent
shouldBeEnabled =
"Yes"
ignoreCount =
"0"
continueAfterRunningActions =
"No"
filePath =
"redstar/Classes/Module/Function/Picture/PictureDetail/ViewController/PictureStoryViewController.m"
timestampString =
"473182309.370969"
startingColumnNumber =
"9223372036854775807"
endingColumnNumber =
"9223372036854775807"
startingLineNumber =
"81"
endingLineNumber =
"81"
landmarkName =
"-imageManager:transformDownloadedImage:withURL:"
landmarkType =
"5"
>
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>
redstar/Classes/Module/Announce/AnnounceDetail/ViewController/AnnoDetailViewController.m
View file @
0b9ca0aa
...
...
@@ -152,7 +152,6 @@
//检查本地文件是否已存在
NSString
*
fileName
=
[
NSString
stringWithFormat
:
@"%@/%@"
,
aSavePath
,
aFileName
];
//检查附件是否存在
if
([
fileManager
fileExistsAtPath
:
fileName
])
{
NSLog
(
@"存在了"
);
...
...
@@ -165,6 +164,7 @@
}
//下载附件
aUrl
=
[
aUrl
stringByAddingPercentEscapesUsingEncoding
:
NSUTF8StringEncoding
];
NSURL
*
url
=
[[
NSURL
alloc
]
initWithString
:
aUrl
];
NSURLRequest
*
request
=
[
NSURLRequest
requestWithURL
:
url
];
...
...
@@ -172,11 +172,9 @@
operation
.
inputStream
=
[
NSInputStream
inputStreamWithURL
:
url
];
operation
.
outputStream
=
[
NSOutputStream
outputStreamToFileAtPath
:
fileName
append
:
NO
];
//下载进度控制
//已完成下载
[
operation
setCompletionBlockWithSuccess
:
^
(
AFHTTPRequestOperation
*
operation
,
id
responseObject
)
{
UIAlertView
*
alert
=
[[
UIAlertView
alloc
]
initWithTitle
:
@"提示"
message
:
@"下载成功!"
delegate
:
self
cancelButtonTitle
:
nil
otherButtonTitles
:
@"确定"
,
nil
];
alert
.
tag
=
66690
;
[
alert
show
];
...
...
@@ -250,7 +248,6 @@
NSArray
*
paths
=
NSSearchPathForDirectoriesInDomains
(
NSDocumentDirectory
,
NSUserDomainMask
,
YES
);
NSString
*
path
=
paths
.
lastObject
;
NSString
*
url
=
[
NSString
stringWithFormat
:
@"%@/%@"
,
path
,
atta
.
fileName
];
NSFileManager
*
fileManager
=
[
NSFileManager
defaultManager
];
if
([
fileManager
fileExistsAtPath
:
url
])
{
cell
.
downloadBtn
.
selected
=
YES
;
...
...
redstar/Classes/Module/Announce/AnnounceList/ViewController/AnnounceViewController.m
View file @
0b9ca0aa
...
...
@@ -148,7 +148,6 @@
}
NSLog
(
@"22url ==== %@"
,
url
);
[
MBProgressHUD
showHUDAddedTo
:
self
.
view
animated
:
YES
];
HttpClient
*
httpClient
=
[[
HttpClient
alloc
]
initWithUrl
:
url
];
...
...
redstar/Classes/Module/Function/OnLine/SelectStore/ViewController/SelectStoreViewController.m
View file @
0b9ca0aa
...
...
@@ -40,17 +40,8 @@
self
.
navigationController
.
navigationBar
.
translucent
=
NO
;
}
self
.
view
.
backgroundColor
=
kFootViewBackGroundColor
;
// UIButton *rightButton = [[UIButton alloc] initWithFrame:CGRectMake(0, 0, 60, 20)];
// [rightButton setTitle:@"全部重置" forState:UIControlStateNormal];
// [rightButton addTarget:self action:@selector(resetClick:) forControlEvents:UIControlEventTouchUpInside];
// [rightButton setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
// rightButton.titleLabel.font = [UIFont systemFontOfSize:15];
// UIBarButtonItem *rightButtonItem = [[UIBarButtonItem alloc] initWithCustomView:rightButton];
// self.navigationItem.rightBarButtonItem = rightButtonItem;
UILabel
*
customLab
=
[[
UILabel
alloc
]
initWithFrame
:
CGRectMake
(
0
,
0
,
40
,
30
)];
[
customLab
setTextColor
:[
UIColor
whiteColor
]];
[
customLab
setText
:
@"选择商场"
];
...
...
@@ -70,7 +61,7 @@
UIBarButtonItem
*
backItem
=
[[
UIBarButtonItem
alloc
]
initWithCustomView
:
backBtn
];
self
.
navigationItem
.
leftBarButtonItem
=
backItem
;
self
.
treeView
.
backgroundColor
=
[
UIColor
whiteColor
];
[
self
requestQueryLowerOrgs
];
[
self
.
sureButton
addTarget
:
self
action
:
@selector
(
sureClick
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
...
...
@@ -163,7 +154,7 @@
}
self
.
treeView
.
nodeData
=
tree1
;
[
self
.
treeView
reloadData
];
}];
}
...
...
redstar/Classes/Module/Function/Picture/PictureDetail/ViewController/PictureStoryViewController.m
View file @
0b9ca0aa
...
...
@@ -25,8 +25,7 @@
#import <UIImageView+WebCache.h>
#import <UIButton+WebCache.h>
#import <SDWebImageManager.h>
#import <SDImageCache.h>
#define kPictureDetailTableCell @"PictureDetailTableViewCell"
#define kPictureTextTableCell @"PictureTextTableViewCell"
...
...
@@ -55,6 +54,8 @@
[
super
viewWillAppear
:
animated
];
self
.
navigationController
.
navigationBar
.
hidden
=
NO
;
self
.
tabBarController
.
tabBar
.
hidden
=
YES
;
}
-
(
void
)
viewDidLoad
{
...
...
@@ -70,16 +71,8 @@
_clickNumber
=
0
;
[
self
requestPicturePraiseDetail
];
}
-
(
UIImage
*
)
imageManager
:
(
SDWebImageManager
*
)
imageManager
transformDownloadedImage
:
(
UIImage
*
)
image
withURL
:
(
NSURL
*
)
imageURL
{
return
[
self
reSizeImage
:
image
toSize
:
CGSizeMake
(
kScreenWidth
-
40
,
170
)];
}
#pragma mark - Private Methods
...
...
@@ -354,37 +347,8 @@
NSURL
*
imageUrl
=
[
NSURL
URLWithString
:[
NSString
stringWithFormat
:
@"%@%@"
,
kRedStarURL
,
picText
.
fileUrl
]];
UIImage
*
defaultImage
=
[
UIImage
imageNamed
:
@"default_pic"
];
SDWebImageManager
*
manager
=
[
SDWebImageManager
sharedManager
];
manager
.
delegate
=
self
;
[
manager
downloadImageWithURL
:
imageUrl
options
:
0
progress
:
nil
completed
:^
(
UIImage
*
image
,
NSError
*
error
,
SDImageCacheType
cacheType
,
BOOL
finished
,
NSURL
*
imageURL
)
{
if
(
image
)
{
cell
.
bigImageView
.
image
=
image
;
}
}];
// [imageVview sd_setImageWithURL:imageUrl placeholderImage:defaultImage completed:^(UIImage *image, NSError *error, SDImageCacheType cacheType, NSURL *imageURL) {
// cacheType = SDImageCacheTypeDisk;
// // UIImage *image00 = [UIImage image:image fillSize:CGSizeMake(kScreenWidth - 40, 170)];
// UIImage *image00 = [self reSizeImage:image toSize:CGSizeMake(kScreenWidth - 40, 170)];
// // UIImage *image11 = [self scaleImage:image toScale:<#(float)#>]
//
//
// cell.bigImageView.image = image00;
// }];
// [cell.bigImageView sd_setImageWithURL:imageUrl placeholderImage:defaultImage];
[
cell
.
bigImageView
sd_setImageWithURL
:
imageUrl
placeholderImage
:
defaultImage
];
UITapGestureRecognizer
*
tap
=
[[
UITapGestureRecognizer
alloc
]
initWithTarget
:
self
action
:
@selector
(
tapClick
:
)];
[
cell
.
bigImageView
addGestureRecognizer
:
tap
];
...
...
redstar/Classes/Module/Function/Question/AddQuestion/Cell/AddQuestionTableCell.h
View file @
0b9ca0aa
...
...
@@ -16,4 +16,5 @@
@property
(
nonatomic
,
strong
)
UILabel
*
placeholderLabel1
;
@property
(
nonatomic
,
strong
)
UILabel
*
placeholderLabel2
;
@end
redstar/Classes/Module/Function/Question/AddQuestion/Cell/AddQuestionTableCell.m
View file @
0b9ca0aa
...
...
@@ -12,6 +12,9 @@
@property
(
nonatomic
,
strong
)
UIImageView
*
backImageView1
;
@property
(
nonatomic
,
strong
)
UIImageView
*
backImageView2
;
@property
(
nonatomic
,
strong
)
UILabel
*
pictureLabel
;
@end
@implementation
AddQuestionTableCell
...
...
@@ -44,7 +47,7 @@
NSLayoutConstraint
*
contentLabelRight
=
[
NSLayoutConstraint
constraintWithItem
:
contentLabel
attribute
:
NSLayoutAttributeRight
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeRight
multiplier
:
1
.
0
constant
:
0
];
[
self
.
contentView
addConstraint
:
contentLabelRight
];
NSLayoutConstraint
*
contentLabelHeight
=
[
NSLayoutConstraint
constraintWithItem
:
contentLabel
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
50
];
NSLayoutConstraint
*
contentLabelHeight
=
[
NSLayoutConstraint
constraintWithItem
:
contentLabel
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
45
];
[
self
.
contentView
addConstraint
:
contentLabelHeight
];
...
...
@@ -65,7 +68,7 @@
NSLayoutConstraint
*
titleRight
=
[
NSLayoutConstraint
constraintWithItem
:
titleLabel
attribute
:
NSLayoutAttributeRight
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeRight
multiplier
:
1
.
0
constant
:
0
];
[
self
.
contentView
addConstraint
:
titleRight
];
NSLayoutConstraint
*
titleHeight
=
[
NSLayoutConstraint
constraintWithItem
:
titleLabel
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
50
];
NSLayoutConstraint
*
titleHeight
=
[
NSLayoutConstraint
constraintWithItem
:
titleLabel
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
45
];
[
self
.
contentView
addConstraint
:
titleHeight
];
...
...
@@ -79,6 +82,8 @@
self
.
titleTextView
.
backgroundColor
=
[
UIColor
clearColor
];
self
.
placeholderLabel1
.
text
=
@"请输入文字..."
;
self
.
pictureLabel
.
text
=
@"现场照片"
;
}
#pragma mark - lazy loading
...
...
@@ -92,7 +97,7 @@
_backImageView2
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
[
self
.
contentView
addSubview
:
_backImageView2
];
NSLayoutConstraint
*
contentTop
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView2
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
50
];
NSLayoutConstraint
*
contentTop
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView2
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
45
];
[
self
.
contentView
addConstraint
:
contentTop
];
NSLayoutConstraint
*
contentLeft
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView2
attribute
:
NSLayoutAttributeLeft
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeLeft
multiplier
:
1
.
0
constant
:
20
];
...
...
@@ -139,7 +144,7 @@
_backImageView1
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
[
self
.
contentView
addSubview
:
_backImageView1
];
NSLayoutConstraint
*
contentTop
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView1
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
1
60
];
NSLayoutConstraint
*
contentTop
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView1
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
1
55
];
[
self
.
contentView
addConstraint
:
contentTop
];
NSLayoutConstraint
*
contentLeft
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView1
attribute
:
NSLayoutAttributeLeft
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeLeft
multiplier
:
1
.
0
constant
:
20
];
...
...
@@ -151,8 +156,6 @@
NSLayoutConstraint
*
contentHeight
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView1
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
120
];
[
self
.
contentView
addConstraint
:
contentHeight
];
NSLayoutConstraint
*
contentBottom
=
[
NSLayoutConstraint
constraintWithItem
:
_backImageView1
attribute
:
NSLayoutAttributeBottom
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:-
10
];
[
self
.
contentView
addConstraint
:
contentBottom
];
}
return
_backImageView1
;
}
...
...
@@ -232,6 +235,34 @@
return
_placeholderLabel1
;
}
-
(
UILabel
*
)
pictureLabel
{
if
(
!
_pictureLabel
)
{
_pictureLabel
=
[[
UILabel
alloc
]
init
];
_pictureLabel
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
_pictureLabel
.
font
=
[
UIFont
systemFontOfSize
:
16
.
0
];
_pictureLabel
.
textColor
=
kOnLineCellTitleColor
;
[
self
.
contentView
addSubview
:
_pictureLabel
];
NSLayoutConstraint
*
contentTop
=
[
NSLayoutConstraint
constraintWithItem
:
_pictureLabel
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
backImageView1
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:
0
];
[
self
.
contentView
addConstraint
:
contentTop
];
NSLayoutConstraint
*
contentLeft
=
[
NSLayoutConstraint
constraintWithItem
:
_pictureLabel
attribute
:
NSLayoutAttributeLeft
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeLeft
multiplier
:
1
.
0
constant
:
20
];
[
self
.
contentView
addConstraint
:
contentLeft
];
NSLayoutConstraint
*
contentHeight
=
[
NSLayoutConstraint
constraintWithItem
:
_pictureLabel
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
45
];
[
self
.
contentView
addConstraint
:
contentHeight
];
NSLayoutConstraint
*
contentBottom
=
[
NSLayoutConstraint
constraintWithItem
:
_pictureLabel
attribute
:
NSLayoutAttributeBottom
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:
0
];
[
self
.
contentView
addConstraint
:
contentBottom
];
}
return
_pictureLabel
;
}
-
(
void
)
touchesEnded
:
(
NSSet
*
)
touches
withEvent
:
(
UIEvent
*
)
event
{
[
self
.
contentView
endEditing
:
YES
];
}
...
...
redstar/Classes/Module/Function/Question/AddQuestion/View/AddQuestionFooterView.m
View file @
0b9ca0aa
...
...
@@ -34,6 +34,7 @@
-
(
void
)
setup
{
[
self
.
reportBtn
setTitle
:
@"上报问题"
forState
:
UIControlStateNormal
];
}
...
...
@@ -48,7 +49,7 @@
[
_reportBtn
setTitleColor
:[
UIColor
whiteColor
]
forState
:
UIControlStateNormal
];
[
self
addSubview
:
_reportBtn
];
NSLayoutConstraint
*
tableTop
=
[
NSLayoutConstraint
constraintWithItem
:
_reportBtn
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
1
0
];
NSLayoutConstraint
*
tableTop
=
[
NSLayoutConstraint
constraintWithItem
:
_reportBtn
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
attribute
:
NSLayoutAttributeTop
multiplier
:
1
.
0
constant
:
1
5
];
[
self
addConstraint
:
tableTop
];
NSLayoutConstraint
*
tableLeft
=
[
NSLayoutConstraint
constraintWithItem
:
_reportBtn
attribute
:
NSLayoutAttributeLeft
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
attribute
:
NSLayoutAttributeLeft
multiplier
:
1
.
0
constant
:
20
];
...
...
@@ -57,7 +58,7 @@
NSLayoutConstraint
*
tableRight
=
[
NSLayoutConstraint
constraintWithItem
:
_reportBtn
attribute
:
NSLayoutAttributeRight
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
attribute
:
NSLayoutAttributeRight
multiplier
:
1
.
0
constant
:-
20
];
[
self
addConstraint
:
tableRight
];
NSLayoutConstraint
*
tableHeight
=
[
NSLayoutConstraint
constraintWithItem
:
_reportBtn
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
40
];
NSLayoutConstraint
*
tableHeight
=
[
NSLayoutConstraint
constraintWithItem
:
_reportBtn
attribute
:
NSLayoutAttributeHeight
relatedBy
:
NSLayoutRelationEqual
toItem
:
nil
attribute
:
NSLayoutAttributeNotAnAttribute
multiplier
:
1
.
0
constant
:
35
];
[
self
addConstraint
:
tableHeight
];
}
return
_reportBtn
;
...
...
redstar/Classes/Module/Function/Question/AddQuestion/ViewController/AddQuestionViewController.m
View file @
0b9ca0aa
...
...
@@ -134,6 +134,7 @@
{
[
self
.
tableView
registerClass
:[
UITableViewCell
class
]
forCellReuseIdentifier
:
kAddQuestionCell
];
self
.
tableView
.
tableFooterView
=
self
.
footerView
;
_tableView
.
separatorStyle
=
UITableViewCellSeparatorStyleNone
;
}
-
(
void
)
createImagePicker
:
(
UIButton
*
)
sender
...
...
@@ -297,7 +298,6 @@
HttpClient
*
client
=
[[
HttpClient
alloc
]
initWithUrl
:
url
];
[
MBProgressHUD
showHUDAddedTo
:
self
.
view
animated
:
YES
];
[
client
uploadNewQuestionWithParameters
:
parameters
completion
:
^
(
id
response
,
NSError
*
error
)
{
NSLog
(
@"上传新问题 response= %@, error = %@"
,
response
,
error
);
if
(
response
[
@"success"
])
{
UIAlertView
*
alert
=
[[
UIAlertView
alloc
]
initWithTitle
:
@"提示"
message
:
@"新问题提报成功!"
delegate
:
self
cancelButtonTitle
:
@"确定"
otherButtonTitles
:
nil
,
nil
];
alert
.
tag
=
90393
;
...
...
@@ -334,6 +334,9 @@
cell
.
textLabel
.
textColor
=
kOnLineCellTitleColor
;
cell
.
selectionStyle
=
UITableViewCellSelectionStyleNone
;
cell
.
accessoryType
=
UITableViewCellAccessoryDisclosureIndicator
;
UIView
*
line
=
[[
UIView
alloc
]
initWithFrame
:
CGRectMake
(
15
,
49
,
kScreenWidth
,
1
)];
line
.
backgroundColor
=
kSeparateLineColor
;
[
cell
.
contentView
addSubview
:
line
];
if
(
indexPath
.
row
==
0
)
{
if
(
!
self
.
selectLabel
)
{
...
...
@@ -398,6 +401,8 @@
}
cell
.
titleTextView
.
delegate
=
self
;
cell
.
contentTextView
.
delegate
=
self
;
cell
.
selectionStyle
=
UITableViewCellSelectionStyleNone
;
return
cell
;
}
else
if
(
indexPath
.
row
==
_rowNumber
-
1
)
{
if
((
_imageNameArray
.
count
+
1
)
%
2
==
0
)
{
...
...
@@ -415,7 +420,7 @@
cell
.
photoButton2
.
tag
=
2201
;
[
cell
.
photoButton2
addTarget
:
self
action
:
@selector
(
createImagePicker
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
cell
.
selectionStyle
=
UITableViewCellSelectionStyleNone
;
return
cell
;
}
else
{
...
...
@@ -424,6 +429,8 @@
if
(
!
cell
)
{
cell
=
[[
InspectAddCell
alloc
]
initWithStyle
:
UITableViewCellStyleValue1
reuseIdentifier
:
identifier
];
}
cell
.
selectionStyle
=
UITableViewCellSelectionStyleNone
;
cell
.
photoButton
.
tag
=
2200
;
[
cell
.
photoButton
addTarget
:
self
action
:
@selector
(
createImagePicker
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
...
...
@@ -555,7 +562,7 @@
-
(
AddQuestionFooterView
*
)
footerView
{
if
(
!
_footerView
)
{
_footerView
=
[[
AddQuestionFooterView
alloc
]
initWithFrame
:
CGRectMake
(
0
,
0
,
kScreenWidth
,
50
)];
_footerView
=
[[
AddQuestionFooterView
alloc
]
initWithFrame
:
CGRectMake
(
0
,
0
,
kScreenWidth
,
65
)];
}
return
_footerView
;
}
...
...
redstar/Classes/Module/Function/Question/QuestionDetail/Cell/QuestionDetailCell.m
View file @
0b9ca0aa
...
...
@@ -38,7 +38,6 @@
[
questionNameAttr
addAttributes
:@{
NSForegroundColorAttributeName
:
kdetailCellTitleColor
,
NSFontAttributeName
:
[
UIFont
systemFontOfSize
:
15
.
0
f
]}
range
:
NSMakeRange
(
5
,
questionNameText
.
length
-
5
)];
[
self
.
questionName
setAttributedText
:
questionNameAttr
];
NSLog
(
@"questionDetail.state = %@"
,
questionDetail
.
state
);
// 状态
if
([
questionDetail
.
state
isEqualToString
:
@"resolved"
])
{
NSString
*
stateText
=
[
NSString
stringWithFormat
:
@"状态:已解决"
];
...
...
@@ -75,7 +74,7 @@
self
.
shopLabel
.
text
=
@"商场:"
;
self
.
shopLabel
.
textColor
=
kDetailCellDescribeTextColor
;
}
else
{
NSString
*
shopText
=
[
NSString
stringWithFormat
:
@"商场:%@"
,
questionDetail
.
store
Path
];
NSString
*
shopText
=
[
NSString
stringWithFormat
:
@"商场:%@"
,
questionDetail
.
store
_name
];
NSMutableAttributedString
*
shopAttr
=
[[
NSMutableAttributedString
alloc
]
initWithString
:
shopText
];
[
shopAttr
addAttributes
:@{
NSForegroundColorAttributeName
:
kDetailCellDescribeTextColor
,
NSFontAttributeName
:
[
UIFont
systemFontOfSize
:
15
.
0
f
]}
range
:
NSMakeRange
(
0
,
3
)];
[
shopAttr
addAttributes
:@{
NSForegroundColorAttributeName
:
kdetailCellTitleColor
,
NSFontAttributeName
:
[
UIFont
systemFontOfSize
:
15
.
0
f
]}
range
:
NSMakeRange
(
3
,
shopText
.
length
-
3
)];
...
...
redstar/Classes/Module/Function/Standar/SOPCategarys/ViewController/SOPViewController.m
View file @
0b9ca0aa
...
...
@@ -257,7 +257,6 @@
NSString
*
path
=
paths
.
lastObject
;
NSString
*
fileName
=
[
NSString
stringWithFormat
:
@"%@"
,
atta
.
fileName
];
fileName
=
[
fileName
stringByAddingPercentEscapesUsingEncoding
:
NSUTF8StringEncoding
];
[
self
downloadFileURL
:[
NSString
stringWithFormat
:
@"%@%@"
,
kRedStarURL
,
atta
.
fileUrl
]
savePath
:
path
fileName
:
fileName
];
}
...
...
@@ -267,7 +266,6 @@
//检查本地文件是否已存在
NSString
*
fileName
=
[
NSString
stringWithFormat
:
@"%@/%@"
,
aSavePath
,
aFileName
];
//检查附件是否存在
if
([
fileManager
fileExistsAtPath
:
fileName
])
{
NSLog
(
@"存在了"
);
...
...
@@ -278,11 +276,8 @@
if
(
!
[
fileManager
fileExistsAtPath
:
aSavePath
])
{
[
fileManager
createDirectoryAtPath
:
aSavePath
withIntermediateDirectories
:
YES
attributes
:
nil
error
:
nil
];
}
NSLog
(
@"aurlllll === %@"
,
aUrl
);
//下载附件
aUrl
=
[
aUrl
stringByAddingPercentEscapesUsingEncoding
:
NSUTF8StringEncoding
];
NSLog
(
@"aurlllll === %@"
,
aUrl
);
NSURL
*
url
=
[[
NSURL
alloc
]
initWithString
:
aUrl
];
NSURLRequest
*
request
=
[
NSURLRequest
requestWithURL
:
url
];
...
...
@@ -294,16 +289,19 @@
//已完成下载
[
operation
setCompletionBlockWithSuccess
:
^
(
AFHTTPRequestOperation
*
operation
,
id
responseObject
)
{
[
self
closeRedView
];
UIAlertView
*
alert
=
[[
UIAlertView
alloc
]
initWithTitle
:
@"提示"
message
:
@"下载成功!"
delegate
:
self
cancelButtonTitle
:
nil
otherButtonTitles
:
@"确定"
,
nil
];
alert
.
tag
=
66690
;
[
alert
show
];
}
failure
:
^
(
AFHTTPRequestOperation
*
operation
,
NSError
*
error
)
{
NSLog
(
@"error ==== %@"
,
error
);
[
self
.
tableView
reloadData
];
}
failure
:
^
(
AFHTTPRequestOperation
*
operation
,
NSError
*
error
)
{
[
self
closeRedView
];
UIAlertView
*
alert
=
[[
UIAlertView
alloc
]
initWithTitle
:
@"警告"
message
:
@"下载失败!"
delegate
:
self
cancelButtonTitle
:
nil
otherButtonTitles
:
@"确定"
,
nil
];
[
alert
show
];
[
self
.
tableView
reloadData
];
}];
[
operation
start
];
...
...
@@ -447,7 +445,7 @@
AttachmentModel
*
atta
=
_attachmentArray
[
indexPath
.
row
];
NSString
*
name
=
atta
.
fileName
;
[
cell
.
nameBtn
setTitle
:
name
forState
:
UIControlStateNormal
];
cell
.
nameBtn
.
titleLabel
.
numberOfLines
=
0
;
[
cell
.
nameBtn
addTarget
:
self
action
:
@selector
(
showFile
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
[
cell
.
downloadBtn
addTarget
:
self
action
:
@selector
(
downloadFile
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
...
...
@@ -457,7 +455,6 @@
NSArray
*
paths
=
NSSearchPathForDirectoriesInDomains
(
NSDocumentDirectory
,
NSUserDomainMask
,
YES
);
NSString
*
path
=
paths
.
lastObject
;
NSString
*
url
=
[
NSString
stringWithFormat
:
@"%@/%@"
,
path
,
atta
.
fileName
];
NSFileManager
*
fileManager
=
[
NSFileManager
defaultManager
];
if
([
fileManager
fileExistsAtPath
:
url
])
{
cell
.
downloadBtn
.
selected
=
YES
;
...
...
redstar/Classes/Module/Function/WordOfMouth/Inspect/InspectDetail/Cell/InspectAddCell.m
View file @
0b9ca0aa
...
...
@@ -23,7 +23,7 @@
#pragma mark - Private Methods
-
(
void
)
setup
{
self
.
contentView
.
backgroundColor
=
[
UIColor
colorWithRed
:
239
/
255
.
0
green
:
239
/
255
.
0
blue
:
239
/
255
.
0
alpha
:
239
/
255
.
0
]
;
self
.
contentView
.
backgroundColor
=
kFootViewBackGroundColor
;
}
...
...
@@ -83,7 +83,7 @@
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:-
5
];
constant
:-
10
];
[
self
.
contentView
addConstraint
:
overDateBottom
];
}
return
_photoButton
;
...
...
redstar/Classes/Module/Function/WordOfMouth/Inspect/InspectDetail/Cell/InspectNotUpLoadCell.m
View file @
0b9ca0aa
...
...
@@ -161,7 +161,7 @@
_pictureLabel
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
_pictureLabel
.
font
=
[
UIFont
systemFontOfSize
:
15
.
0
];
_pictureLabel
.
backgroundColor
=
[
UIColor
clearColor
];
_pictureLabel
.
textColor
=
kLight
Gray
;
_pictureLabel
.
textColor
=
kLight
Black
;
[
self
.
bgView
addSubview
:
_pictureLabel
];
...
...
redstar/Classes/Module/Function/WordOfMouth/Inspect/InspectDetail/Cell/InspectPicAddCell.m
View file @
0b9ca0aa
...
...
@@ -22,7 +22,7 @@
#pragma mark - Private Methods
-
(
void
)
setup
{
self
.
contentView
.
backgroundColor
=
[
UIColor
colorWithRed
:
239
/
255
.
0
green
:
239
/
255
.
0
blue
:
239
/
255
.
0
alpha
:
239
/
255
.
0
]
;
self
.
contentView
.
backgroundColor
=
kFootViewBackGroundColor
;
}
-
(
UIButton
*
)
photoButton1
...
...
@@ -79,7 +79,7 @@
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:-
5
];
constant
:-
10
];
[
self
.
contentView
addConstraint
:
overDateBottom
];
}
return
_photoButton1
;
...
...
redstar/Classes/Module/Function/WordOfMouth/Inspect/InspectDetail/View/InspectUpLoadFootView.m
View file @
0b9ca0aa
...
...
@@ -124,7 +124,13 @@
// textView
UITextView
*
textView
=
[[
UITextView
alloc
]
init
];
textView
.
text
=
[
NSString
stringWithFormat
:
@"%@"
,
remark
];
if
(
remark
==
nil
||
remark
==
NULL
||
[
remark
isEqual
:[
NSNull
null
]]
||
remark
==
Nil
||
[
remark
isEqualToString
:
@"(null)"
])
{
textView
.
text
=
[
NSString
stringWithFormat
:
@""
];
}
else
{
textView
.
text
=
[
NSString
stringWithFormat
:
@"%@"
,
remark
];
}
textView
.
backgroundColor
=
[
UIColor
clearColor
];
textView
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
[
bgImageView
addSubview
:
textView
];
...
...
redstar/Classes/Module/Function/WordOfMouth/Inspect/InspectDetail/ViewController/InspectUploadedViewController.m
View file @
0b9ca0aa
...
...
@@ -79,8 +79,6 @@
cell
.
titleLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@"
,
_taskModel
.
title
];
cell
.
titleDetailLabel
.
text
=
[
NSString
stringWithFormat
:
@"要求图片%d张"
,
_taskModel
.
attachmentNumber
];
cell
.
introLabel
.
text
=
@"参考说明"
;
cell
.
introDetailLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@"
,
_taskModel
.
reference
];
NSString
*
refrer
=
[
NSString
stringWithFormat
:
@"%@"
,
_taskModel
.
reference
];
if
(
refrer
==
nil
||
refrer
==
NULL
||
[
refrer
isEqual
:[
NSNull
null
]]
||
refrer
==
Nil
||
[
refrer
isEqualToString
:
@"(null)"
])
{
cell
.
introDetailLabel
.
text
=
@""
;
...
...
redstar/Classes/Module/Function/WordOfMouth/Inspect/InspectTask/Cell/InspectTaskDetailCell.m
View file @
0b9ca0aa
...
...
@@ -582,7 +582,7 @@
_arrowImageView
.
translatesAutoresizingMaskIntoConstraints
=
NO
;
[
self
.
contentView
addSubview
:
_arrowImageView
];
NSLayoutConstraint
*
Top
=
[
NSLayoutConstraint
constraintWithItem
:
_arrowImageView
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
allView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:
1
9
];
NSLayoutConstraint
*
Top
=
[
NSLayoutConstraint
constraintWithItem
:
_arrowImageView
attribute
:
NSLayoutAttributeTop
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
allView
attribute
:
NSLayoutAttributeBottom
multiplier
:
1
.
0
constant
:
1
8
];
[
self
.
contentView
addConstraint
:
Top
];
NSLayoutConstraint
*
Right
=
[
NSLayoutConstraint
constraintWithItem
:
_arrowImageView
attribute
:
NSLayoutAttributeRight
relatedBy
:
NSLayoutRelationEqual
toItem
:
self
.
contentView
attribute
:
NSLayoutAttributeRight
multiplier
:
1
.
0
constant
:-
20
];
...
...
redstar/Classes/Module/Function/WordOfMouth/Inspect/InspectTask/ViewController/InspectTaskViewController.m
View file @
0b9ca0aa
...
...
@@ -205,7 +205,12 @@
cell
.
selectionStyle
=
UITableViewCellSelectionStyleNone
;
[
cell
.
unfoldBtn
addTarget
:
self
action
:
@selector
(
unfoldCilck
:
)
forControlEvents
:
UIControlEventTouchUpInside
];
if
(
_isOpen
)
{
cell
.
introDetailLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@"
,
_taskDetail
.
remark
];
if
(
_taskDetail
.
remark
==
nil
||
_taskDetail
.
remark
==
NULL
||
[
_taskDetail
.
remark
isEqual
:[
NSNull
null
]]
||
_taskDetail
.
remark
==
Nil
||
[
_taskDetail
.
remark
isEqualToString
:
@"(null)"
])
{
cell
.
introDetailLabel
.
text
=
@""
;
cell
.
arrowImageView
.
transform
=
CGAffineTransformMakeRotation
(
M_PI
);
}
else
{
cell
.
introDetailLabel
.
text
=
[
NSString
stringWithFormat
:
@"%@"
,
_taskDetail
.
remark
];
}
}
else
{
cell
.
introDetailLabel
.
text
=
@""
;
}
...
...
redstar/Classes/Module/Home/ViewController/HomeViewController.m
View file @
0b9ca0aa
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