Commit 57e30e56 authored by admin's avatar admin

修复bug

parent 7cf61ae6
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
buildForAnalyzing = "YES"> buildForAnalyzing = "YES">
<BuildableReference <BuildableReference
BuildableIdentifier = "primary" BuildableIdentifier = "primary"
BlueprintIdentifier = "06233FDD99F2013F83A398F3" BlueprintIdentifier = "F12B2171281EA12FCDCF6619"
BuildableName = "libAFNetworking.a" BuildableName = "libAFNetworking.a"
BlueprintName = "AFNetworking" BlueprintName = "AFNetworking"
ReferencedContainer = "container:Pods.xcodeproj"> ReferencedContainer = "container:Pods.xcodeproj">
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
buildForAnalyzing = "YES"> buildForAnalyzing = "YES">
<BuildableReference <BuildableReference
BuildableIdentifier = "primary" BuildableIdentifier = "primary"
BlueprintIdentifier = "9AD3B25BF8427F9674B17662" BlueprintIdentifier = "C5D55DF90ED8050F150B42AE"
BuildableName = "libPods.a" BuildableName = "libPods.a"
BlueprintName = "Pods" BlueprintName = "Pods"
ReferencedContainer = "container:Pods.xcodeproj"> ReferencedContainer = "container:Pods.xcodeproj">
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
buildForAnalyzing = "YES"> buildForAnalyzing = "YES">
<BuildableReference <BuildableReference
BuildableIdentifier = "primary" BuildableIdentifier = "primary"
BlueprintIdentifier = "10477AB8861E6E46A25DFBCD" BlueprintIdentifier = "DB55FBD64C69FF1FF7B30398"
BuildableName = "libSDWebImage.a" BuildableName = "libSDWebImage.a"
BlueprintName = "SDWebImage" BlueprintName = "SDWebImage"
ReferencedContainer = "container:Pods.xcodeproj"> ReferencedContainer = "container:Pods.xcodeproj">
......
...@@ -37,32 +37,32 @@ ...@@ -37,32 +37,32 @@
</dict> </dict>
<key>SuppressBuildableAutocreation</key> <key>SuppressBuildableAutocreation</key>
<dict> <dict>
<key>5352D432641F0656C90741034E32F31E</key> <key>36E0C26ABF9E779513C15F592498F0FB</key>
<dict> <dict>
<key>primary</key> <key>primary</key>
<true/> <true/>
</dict> </dict>
<key>8421FA013F6234E416E9E5363CB99DDB</key> <key>51EDC086645F9E7589BB11AE18ACFB07</key>
<dict> <dict>
<key>primary</key> <key>primary</key>
<true/> <true/>
</dict> </dict>
<key>BB58AC6D7CE35348B874113DF4C0EF45</key> <key>5352D432641F0656C90741034E32F31E</key>
<dict> <dict>
<key>primary</key> <key>primary</key>
<true/> <true/>
</dict> </dict>
<key>BB698F8AC1978892388DCBBBB644ACFB</key> <key>576BBB327C3C746F9E69571B8760534A</key>
<dict> <dict>
<key>primary</key> <key>primary</key>
<true/> <true/>
</dict> </dict>
<key>CB31271C2921A12D89FFCA121A02166F</key> <key>BB58AC6D7CE35348B874113DF4C0EF45</key>
<dict> <dict>
<key>primary</key> <key>primary</key>
<true/> <true/>
</dict> </dict>
<key>F6EBA2C87F0A4CB70AF517C3E99C2E16</key> <key>BB698F8AC1978892388DCBBBB644ACFB</key>
<dict> <dict>
<key>primary</key> <key>primary</key>
<true/> <true/>
......
...@@ -30,6 +30,7 @@ ...@@ -30,6 +30,7 @@
841D24F81BEB473C0005CC9F /* CheckPicViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 841D24F71BEB473C0005CC9F /* CheckPicViewController.m */; }; 841D24F81BEB473C0005CC9F /* CheckPicViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 841D24F71BEB473C0005CC9F /* CheckPicViewController.m */; };
841D24FB1BEB75CA0005CC9F /* QuestionDetailFooterView.m in Sources */ = {isa = PBXBuildFile; fileRef = 841D24FA1BEB75CA0005CC9F /* QuestionDetailFooterView.m */; }; 841D24FB1BEB75CA0005CC9F /* QuestionDetailFooterView.m in Sources */ = {isa = PBXBuildFile; fileRef = 841D24FA1BEB75CA0005CC9F /* QuestionDetailFooterView.m */; };
842547FC1BF03977006C79C5 /* QuestionModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 842547FB1BF03977006C79C5 /* QuestionModel.m */; }; 842547FC1BF03977006C79C5 /* QuestionModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 842547FB1BF03977006C79C5 /* QuestionModel.m */; };
842E21DD1C3286D400455F3F /* PictureTextTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 842E21DC1C3286D400455F3F /* PictureTextTableViewCell.m */; };
843D1B9E1C0B3F7600E30002 /* SpotCheckOnLineViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 843D1B9D1C0B3F7600E30002 /* SpotCheckOnLineViewController.m */; }; 843D1B9E1C0B3F7600E30002 /* SpotCheckOnLineViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 843D1B9D1C0B3F7600E30002 /* SpotCheckOnLineViewController.m */; };
8442BA5C1BDB8FDB005E5657 /* MineTableHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 8442BA5B1BDB8FDB005E5657 /* MineTableHeaderView.m */; }; 8442BA5C1BDB8FDB005E5657 /* MineTableHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 8442BA5B1BDB8FDB005E5657 /* MineTableHeaderView.m */; };
846206B51C06AF700015C456 /* RankListHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 846206B41C06AF700015C456 /* RankListHeaderView.m */; }; 846206B51C06AF700015C456 /* RankListHeaderView.m in Sources */ = {isa = PBXBuildFile; fileRef = 846206B41C06AF700015C456 /* RankListHeaderView.m */; };
...@@ -231,6 +232,8 @@ ...@@ -231,6 +232,8 @@
841D24FA1BEB75CA0005CC9F /* QuestionDetailFooterView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = QuestionDetailFooterView.m; sourceTree = "<group>"; }; 841D24FA1BEB75CA0005CC9F /* QuestionDetailFooterView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = QuestionDetailFooterView.m; sourceTree = "<group>"; };
842547FA1BF03977006C79C5 /* QuestionModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = QuestionModel.h; sourceTree = "<group>"; }; 842547FA1BF03977006C79C5 /* QuestionModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = QuestionModel.h; sourceTree = "<group>"; };
842547FB1BF03977006C79C5 /* QuestionModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = QuestionModel.m; sourceTree = "<group>"; }; 842547FB1BF03977006C79C5 /* QuestionModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = QuestionModel.m; sourceTree = "<group>"; };
842E21DB1C3286D400455F3F /* PictureTextTableViewCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PictureTextTableViewCell.h; sourceTree = "<group>"; };
842E21DC1C3286D400455F3F /* PictureTextTableViewCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PictureTextTableViewCell.m; sourceTree = "<group>"; };
843D1B9C1C0B3F7600E30002 /* SpotCheckOnLineViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SpotCheckOnLineViewController.h; sourceTree = "<group>"; }; 843D1B9C1C0B3F7600E30002 /* SpotCheckOnLineViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SpotCheckOnLineViewController.h; sourceTree = "<group>"; };
843D1B9D1C0B3F7600E30002 /* SpotCheckOnLineViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SpotCheckOnLineViewController.m; sourceTree = "<group>"; }; 843D1B9D1C0B3F7600E30002 /* SpotCheckOnLineViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SpotCheckOnLineViewController.m; sourceTree = "<group>"; };
8442BA5A1BDB8FDB005E5657 /* MineTableHeaderView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MineTableHeaderView.h; sourceTree = "<group>"; }; 8442BA5A1BDB8FDB005E5657 /* MineTableHeaderView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MineTableHeaderView.h; sourceTree = "<group>"; };
...@@ -1160,6 +1163,8 @@ ...@@ -1160,6 +1163,8 @@
84C9729B1C1ADC5B003A3276 /* PictureTextTableCell.m */, 84C9729B1C1ADC5B003A3276 /* PictureTextTableCell.m */,
84C9729D1C1ADD17003A3276 /* PictureCommentTableCell.h */, 84C9729D1C1ADD17003A3276 /* PictureCommentTableCell.h */,
84C9729E1C1ADD17003A3276 /* PictureCommentTableCell.m */, 84C9729E1C1ADD17003A3276 /* PictureCommentTableCell.m */,
842E21DB1C3286D400455F3F /* PictureTextTableViewCell.h */,
842E21DC1C3286D400455F3F /* PictureTextTableViewCell.m */,
); );
path = Cell; path = Cell;
sourceTree = "<group>"; sourceTree = "<group>";
...@@ -2285,10 +2290,9 @@ ...@@ -2285,10 +2290,9 @@
TargetAttributes = { TargetAttributes = {
84970DE91BD8DD8A00C1728A = { 84970DE91BD8DD8A00C1728A = {
CreatedOnToolsVersion = 7.0.1; CreatedOnToolsVersion = 7.0.1;
DevelopmentTeam = W54V2VB863;
SystemCapabilities = { SystemCapabilities = {
com.apple.BackgroundModes = { com.apple.BackgroundModes = {
enabled = 0; enabled = 1;
}; };
com.apple.Push = { com.apple.Push = {
enabled = 0; enabled = 0;
...@@ -2411,6 +2415,7 @@ ...@@ -2411,6 +2415,7 @@
84A6738E1C0BE2D0000F828E /* OnLineCompleteCell.m in Sources */, 84A6738E1C0BE2D0000F828E /* OnLineCompleteCell.m in Sources */,
84CEB1671C28E8970072ED0A /* SpotCheckModel.m in Sources */, 84CEB1671C28E8970072ED0A /* SpotCheckModel.m in Sources */,
84CC34D41C094476002F10E2 /* StandardViewController.m in Sources */, 84CC34D41C094476002F10E2 /* StandardViewController.m in Sources */,
842E21DD1C3286D400455F3F /* PictureTextTableViewCell.m in Sources */,
84FD8A0A1BDA01D1006E442A /* MineViewController.m in Sources */, 84FD8A0A1BDA01D1006E442A /* MineViewController.m in Sources */,
84C972991C1ADB9C003A3276 /* PictureDetailTableCell.m in Sources */, 84C972991C1ADB9C003A3276 /* PictureDetailTableCell.m in Sources */,
848A20271C183FCB00422FAB /* OnLineResultViewController.m in Sources */, 848A20271C183FCB00422FAB /* OnLineResultViewController.m in Sources */,
......
...@@ -10,10 +10,10 @@ ...@@ -10,10 +10,10 @@
#define Url_h #define Url_h
// url 测试环境 // url 测试环境
// #define kRedStarURL @"http://218.244.151.129:7580/" #define kRedStarURL @"http://218.244.151.129:7580/"
// 正式环境 // 正式环境
#define kRedStarURL @"http://219.235.234.225:7580/" // #define kRedStarURL @"http://219.235.234.225:7580/"
// 检查更新 // 检查更新
......
...@@ -65,9 +65,7 @@ ...@@ -65,9 +65,7 @@
// 右边 // 右边
NSLayoutConstraint *titleRight = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.dateLabel attribute:NSLayoutAttributeLeft multiplier:1.0 constant:-10]; NSLayoutConstraint *titleRight = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.dateLabel attribute:NSLayoutAttributeLeft multiplier:1.0 constant:-10];
[self.contentView addConstraint:titleRight]; [self.contentView addConstraint:titleRight];
// 高度 // 高度
NSLayoutConstraint *titleBottom = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeBottom relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-10]; NSLayoutConstraint *titleBottom = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeBottom relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-10];
[self.contentView addConstraint:titleBottom]; [self.contentView addConstraint:titleBottom];
......
...@@ -15,6 +15,14 @@ ...@@ -15,6 +15,14 @@
_bigImageView = [[UIImageView alloc] init]; _bigImageView = [[UIImageView alloc] init];
_bigImageView.translatesAutoresizingMaskIntoConstraints = NO; _bigImageView.translatesAutoresizingMaskIntoConstraints = NO;
_bigImageView.userInteractionEnabled = YES; _bigImageView.userInteractionEnabled = YES;
// _bigImageView.contentMode = UIViewContentModeScaleAspectFit;
// _bigImageView.autoresizesSubviews = YES;
// _bigImageView.autoresizingMask =
// UIViewAutoresizingFlexibleLeftMargin | UIViewAutoresizingFlexibleTopMargin | UIViewAutoresizingFlexibleHeight | UIViewAutoresizingFlexibleWidth;
[_bigImageView setContentScaleFactor:[[UIScreen mainScreen] scale]];
_bigImageView.contentMode = UIViewContentModeScaleAspectFill;
_bigImageView.autoresizingMask = UIViewAutoresizingFlexibleHeight;
_bigImageView.clipsToBounds = YES;
[self.contentView addSubview:_bigImageView]; [self.contentView addSubview:_bigImageView];
// 顶端 // 顶端
...@@ -71,6 +79,7 @@ ...@@ -71,6 +79,7 @@
_descriptionLabel.translatesAutoresizingMaskIntoConstraints = NO; _descriptionLabel.translatesAutoresizingMaskIntoConstraints = NO;
_descriptionLabel.font = [UIFont systemFontOfSize:15.0]; _descriptionLabel.font = [UIFont systemFontOfSize:15.0];
_descriptionLabel.textColor = kLightBlack; _descriptionLabel.textColor = kLightBlack;
_descriptionLabel.numberOfLines = 0;
[self.contentView addSubview:_descriptionLabel]; [self.contentView addSubview:_descriptionLabel];
// 顶端 // 顶端
...@@ -86,7 +95,7 @@ ...@@ -86,7 +95,7 @@
[self.contentView addConstraint:titleRight]; [self.contentView addConstraint:titleRight];
// 高度 // 高度
NSLayoutConstraint *titleBottom = [NSLayoutConstraint constraintWithItem:_descriptionLabel attribute:NSLayoutAttributeBottom relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-10]; NSLayoutConstraint *titleBottom = [NSLayoutConstraint constraintWithItem:_descriptionLabel attribute:NSLayoutAttributeBottom relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-0];
[self.contentView addConstraint:titleBottom]; [self.contentView addConstraint:titleBottom];
} }
return _descriptionLabel; return _descriptionLabel;
......
//
// PictureTextTableViewCell.h
// redstar
//
// Created by admin on 15/12/29.
// Copyright © 2015年 ZWF. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface PictureTextTableViewCell : UITableViewCell
@property (nonatomic, strong) UILabel *descriptionLabel;
@end
//
// PictureTextTableViewCell.m
// redstar
//
// Created by admin on 15/12/29.
// Copyright © 2015年 ZWF. All rights reserved.
//
#import "PictureTextTableViewCell.h"
@implementation PictureTextTableViewCell
- (UILabel *)descriptionLabel
{
if (!_descriptionLabel) {
_descriptionLabel = [[UILabel alloc] init];
_descriptionLabel.translatesAutoresizingMaskIntoConstraints = NO;
_descriptionLabel.font = [UIFont systemFontOfSize:15.0];
_descriptionLabel.textColor = kLightBlack;
_descriptionLabel.numberOfLines = 0;
[self.contentView addSubview:_descriptionLabel];
// 顶端
NSLayoutConstraint *titleTop = [NSLayoutConstraint constraintWithItem:_descriptionLabel attribute:NSLayoutAttributeTop relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeTop multiplier:1.0 constant:2];
[self.contentView addConstraint:titleTop];
// 左边
NSLayoutConstraint *titleLeft = [NSLayoutConstraint constraintWithItem:_descriptionLabel attribute:NSLayoutAttributeLeft relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeLeft multiplier:1.0 constant:20];
[self.contentView addConstraint:titleLeft];
// 右边
NSLayoutConstraint *titleRight = [NSLayoutConstraint constraintWithItem:_descriptionLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeRight multiplier:1.0 constant:-20];
[self.contentView addConstraint:titleRight];
// 高度
NSLayoutConstraint *titleBottom = [NSLayoutConstraint constraintWithItem:_descriptionLabel attribute:NSLayoutAttributeBottom relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-2];
[self.contentView addConstraint:titleBottom];
}
return _descriptionLabel;
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
[super setSelected:selected animated:animated];
// Configure the view for the selected state
}
@end
...@@ -12,6 +12,7 @@ ...@@ -12,6 +12,7 @@
#import "PictureDetailTableCell.h" #import "PictureDetailTableCell.h"
#import "PictureTextTableCell.h" #import "PictureTextTableCell.h"
#import "PictureCommentTableCell.h" #import "PictureCommentTableCell.h"
#import "PictureTextTableViewCell.h"
#import "CheckPicViewController.h" #import "CheckPicViewController.h"
...@@ -26,7 +27,7 @@ ...@@ -26,7 +27,7 @@
#define kPictureDetailTableCell @"PictureDetailTableViewCell" #define kPictureDetailTableCell @"PictureDetailTableViewCell"
#define kPictureTextTableCell @"PictureTextTableViewCell" #define kPictureTextTableCell @"PictureTextTableViewCell"
#define kPictureCommentTableCell @"pictureCommentTableViewCell" #define kPictureCommentTableCell @"pictureCommentTableViewCell"
#define kPictureTextTableViewCell @"pictureTextTAbleTableCell"
@interface PictureStoryViewController () <UITableViewDelegate, UITableViewDataSource, UITextViewDelegate> @interface PictureStoryViewController () <UITableViewDelegate, UITableViewDataSource, UITextViewDelegate>
@property (nonatomic, strong) UITableView *tableView; @property (nonatomic, strong) UITableView *tableView;
@property (nonatomic, assign) int clickNumber; @property (nonatomic, assign) int clickNumber;
...@@ -310,31 +311,41 @@ ...@@ -310,31 +311,41 @@
cell.selectionStyle = UITableViewCellSelectionStyleNone; cell.selectionStyle = UITableViewCellSelectionStyleNone;
return cell; return cell;
} else if (indexPath.section == 1) { } else if (indexPath.section == 1) {
PictureTextTableCell *cell=[tableView dequeueReusableCellWithIdentifier:kPictureTextTableCell];
if (!cell) {
cell = [[PictureTextTableCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kPictureTextTableCell];
}
PicTextModel *picText = _picTextArray[indexPath.row];
NSURL *imageUrl = [NSURL URLWithString:[NSString stringWithFormat:@"%@%@", kRedStarURL ,picText.fileUrl]];
UIImageView *imageView = [[UIImageView alloc] init];
[imageView sd_setImageWithURL:imageUrl placeholderImage:[UIImage imageNamed:@"default_pic"]];
cell.bigImageView.contentMode = UIViewContentModeScaleAspectFit;
// [cell.bigImageView sd_setImageWithURL:imageUrl forState:UIControlStateNormal placeholderImage:[UIImage imageNamed:@"default_pic"]];
[cell.bigImageView sd_setImageWithURL:imageUrl placeholderImage:[UIImage imageNamed:@"default_pic"]];
UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tapClick:)]; PicTextModel *picText = _picTextArray[indexPath.row];
[cell.bigImageView addGestureRecognizer:tap]; if (picText.fileName.length == 0) {
PictureTextTableViewCell *cell=[tableView dequeueReusableCellWithIdentifier:kPictureTextTableViewCell];
NSString *str = [NSString stringWithFormat:@"%@", picText.descriptionText]; if (!cell) {
if (picText.descriptionText == nil || picText.descriptionText == NULL || [picText.descriptionText isEqual:[NSNull null]]) { cell = [[PictureTextTableViewCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kPictureTextTableViewCell];
cell.descriptionLabel.text = @""; }
cell.descriptionLabel.text = [NSString stringWithFormat:@"%@", picText.descriptionText];
return cell;
} else { } else {
cell.descriptionLabel.text = str; PictureTextTableCell *cell=[tableView dequeueReusableCellWithIdentifier:kPictureTextTableCell];
if (!cell) {
cell = [[PictureTextTableCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kPictureTextTableCell];
}
NSURL *imageUrl = [NSURL URLWithString:[NSString stringWithFormat:@"%@%@", kRedStarURL ,picText.fileUrl]];
// [cell.bigImageView sd_setImageWithURL:imageUrl placeholderImage:[UIImage imageNamed:@"default_pic"]];
[cell.bigImageView sd_setImageWithURL:imageUrl];
NSLog(@"cell.size = %@", NSStringFromCGSize(cell.bigImageView.image.size));
UITapGestureRecognizer *tap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(tapClick:)];
[cell.bigImageView addGestureRecognizer:tap];
NSString *str = [NSString stringWithFormat:@"%@", picText.descriptionText];
if (picText.descriptionText == nil || picText.descriptionText == NULL || [picText.descriptionText isEqual:[NSNull null]]) {
cell.descriptionLabel.text = @"";
} else {
cell.descriptionLabel.text = str;
}
cell.selectionStyle = UITableViewCellSelectionStyleNone;
return cell;
} }
cell.selectionStyle = UITableViewCellSelectionStyleNone;
return cell;
} else { } else {
// 评论
PictureCommentTableCell *cell=[tableView dequeueReusableCellWithIdentifier:kPictureCommentTableCell]; PictureCommentTableCell *cell=[tableView dequeueReusableCellWithIdentifier:kPictureCommentTableCell];
if (!cell) { if (!cell) {
cell = [[PictureCommentTableCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kPictureCommentTableCell]; cell = [[PictureCommentTableCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kPictureCommentTableCell];
...@@ -564,6 +575,7 @@ ...@@ -564,6 +575,7 @@
[_tableView registerClass:[PictureDetailTableCell class] forCellReuseIdentifier:kPictureDetailTableCell]; [_tableView registerClass:[PictureDetailTableCell class] forCellReuseIdentifier:kPictureDetailTableCell];
[_tableView registerClass:[PictureTextTableCell class] forCellReuseIdentifier:kPictureTextTableCell]; [_tableView registerClass:[PictureTextTableCell class] forCellReuseIdentifier:kPictureTextTableCell];
[_tableView registerClass:[PictureCommentTableCell class] forCellReuseIdentifier:kPictureCommentTableCell]; [_tableView registerClass:[PictureCommentTableCell class] forCellReuseIdentifier:kPictureCommentTableCell];
[_tableView registerClass:[PictureTextTableViewCell class] forCellReuseIdentifier:kPictureTextTableViewCell];
[self.view addSubview:_tableView]; [self.view addSubview:_tableView];
NSLayoutConstraint *tableTop = [NSLayoutConstraint constraintWithItem:_tableView attribute:NSLayoutAttributeTop relatedBy:NSLayoutRelationEqual toItem:self.view attribute:NSLayoutAttributeTop multiplier:1.0 constant:0]; NSLayoutConstraint *tableTop = [NSLayoutConstraint constraintWithItem:_tableView attribute:NSLayoutAttributeTop relatedBy:NSLayoutRelationEqual toItem:self.view attribute:NSLayoutAttributeTop multiplier:1.0 constant:0];
......
...@@ -23,9 +23,9 @@ ...@@ -23,9 +23,9 @@
NSDictionary *dict = pictureList.attachments[0]; NSDictionary *dict = pictureList.attachments[0];
NSURL *imageUrl = [NSURL URLWithString:[NSString stringWithFormat:@"%@%@", kRedStarURL ,dict[@"fileUrl"]]]; NSURL *imageUrl = [NSURL URLWithString:[NSString stringWithFormat:@"%@%@", kRedStarURL ,dict[@"fileUrl"]]];
[self.titleImageView sd_setImageWithURL:imageUrl placeholderImage:[UIImage imageNamed:@"default_pic"]]; [self.titleImageView sd_setImageWithURL:imageUrl placeholderImage:[UIImage imageNamed:@"default_pic"]];
} else { } else {
self.titleImageView.image = [UIImage imageNamed:@"default_pic"]; self.titleImageView.image = [UIImage imageNamed:@"default_pic"];
} }
......
...@@ -12,6 +12,8 @@ ...@@ -12,6 +12,8 @@
@property (nonatomic, assign) NSInteger indexRow; @property (nonatomic, assign) NSInteger indexRow;
@property (nonatomic, copy) NSString *uuid; @property (nonatomic, copy) NSString *uuid;
@property (nonatomic, copy) NSString *store_uuid; @property (nonatomic, copy) NSString *store_uuid;
@property (nonatomic, copy) NSString *commentId;
@property (nonatomic, copy) NSString *storeAddress; @property (nonatomic, copy) NSString *storeAddress;
@property (nonatomic, strong) NSArray *storePictures; @property (nonatomic, strong) NSArray *storePictures;
......
...@@ -503,8 +503,9 @@ ...@@ -503,8 +503,9 @@
NSLog(@"url = %@", url); NSLog(@"url = %@", url);
HttpClient *httpClient = [[HttpClient alloc] initWithUrl:url]; HttpClient *httpClient = [[HttpClient alloc] initWithUrl:url];
NSDictionary *parameters = @{@"entityType":@"question", NSLog(@"selll = %@", self.commentId);
@"entityUuid":self.uuid, NSDictionary *parameters = @{@"entityType":@"praise",
@"entityUuid":self.commentId,
@"comment":_commentView.contentTextView.text}; @"comment":_commentView.contentTextView.text};
NSLog(@"parameters = %@", parameters); NSLog(@"parameters = %@", parameters);
[MBProgressHUD showHUDAddedTo:self.view animated:YES]; [MBProgressHUD showHUDAddedTo:self.view animated:YES];
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
NSLayoutConstraint *shoppingRight = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeCenterX multiplier:1.0 constant:-20]; NSLayoutConstraint *shoppingRight = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeCenterX multiplier:1.0 constant:-20];
[self.contentView addConstraint:shoppingRight]; [self.contentView addConstraint:shoppingRight];
NSLayoutConstraint *shoppingWidth = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeLeft relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeLeft multiplier:1.0 constant:30]; NSLayoutConstraint *shoppingWidth = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeLeft relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeLeft multiplier:1.0 constant:50];
[self.contentView addConstraint:shoppingWidth]; [self.contentView addConstraint:shoppingWidth];
NSLayoutConstraint *shoppingHeight = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeHeight relatedBy:NSLayoutRelationEqual toItem:nil attribute:NSLayoutAttributeNotAnAttribute multiplier:1.0 constant:25]; NSLayoutConstraint *shoppingHeight = [NSLayoutConstraint constraintWithItem:_peopleLabel attribute:NSLayoutAttributeHeight relatedBy:NSLayoutRelationEqual toItem:nil attribute:NSLayoutAttributeNotAnAttribute multiplier:1.0 constant:25];
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
NSLayoutConstraint *shoppingRight = [NSLayoutConstraint constraintWithItem:_dateLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeRight multiplier:1.0 constant:-20]; NSLayoutConstraint *shoppingRight = [NSLayoutConstraint constraintWithItem:_dateLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeRight multiplier:1.0 constant:-20];
[self.contentView addConstraint:shoppingRight]; [self.contentView addConstraint:shoppingRight];
NSLayoutConstraint *shoppingWidth = [NSLayoutConstraint constraintWithItem:_dateLabel attribute:NSLayoutAttributeLeft relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeCenterX multiplier:1.0 constant:-20]; NSLayoutConstraint *shoppingWidth = [NSLayoutConstraint constraintWithItem:_dateLabel attribute:NSLayoutAttributeLeft relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeCenterX multiplier:1.0 constant:-10];
[self.contentView addConstraint:shoppingWidth]; [self.contentView addConstraint:shoppingWidth];
NSLayoutConstraint *shoppingHeight = [NSLayoutConstraint constraintWithItem:_dateLabel attribute:NSLayoutAttributeHeight relatedBy:NSLayoutRelationEqual toItem:nil attribute:NSLayoutAttributeNotAnAttribute multiplier:1.0 constant:25]; NSLayoutConstraint *shoppingHeight = [NSLayoutConstraint constraintWithItem:_dateLabel attribute:NSLayoutAttributeHeight relatedBy:NSLayoutRelationEqual toItem:nil attribute:NSLayoutAttributeNotAnAttribute multiplier:1.0 constant:25];
...@@ -97,7 +97,7 @@ ...@@ -97,7 +97,7 @@
NSLayoutConstraint *shoppingRight = [NSLayoutConstraint constraintWithItem:_commentLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeRight multiplier:1.0 constant:-20]; NSLayoutConstraint *shoppingRight = [NSLayoutConstraint constraintWithItem:_commentLabel attribute:NSLayoutAttributeRight relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeRight multiplier:1.0 constant:-20];
[self.contentView addConstraint:shoppingRight]; [self.contentView addConstraint:shoppingRight];
NSLayoutConstraint *shoppingWidth = [NSLayoutConstraint constraintWithItem:_commentLabel attribute:NSLayoutAttributeLeft relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeLeft multiplier:1.0 constant:30]; NSLayoutConstraint *shoppingWidth = [NSLayoutConstraint constraintWithItem:_commentLabel attribute:NSLayoutAttributeLeft relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeLeft multiplier:1.0 constant:50];
[self.contentView addConstraint:shoppingWidth]; [self.contentView addConstraint:shoppingWidth];
NSLayoutConstraint *shoppingHeight = [NSLayoutConstraint constraintWithItem:_commentLabel attribute:NSLayoutAttributeBottom relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-5]; NSLayoutConstraint *shoppingHeight = [NSLayoutConstraint constraintWithItem:_commentLabel attribute:NSLayoutAttributeBottom relatedBy:NSLayoutRelationEqual toItem:self.contentView attribute:NSLayoutAttributeBottom multiplier:1.0 constant:-5];
......
...@@ -66,6 +66,8 @@ ...@@ -66,6 +66,8 @@
UIImageView *arrowIMView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"grey-trilateral_right"]]; UIImageView *arrowIMView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"grey-trilateral_right"]];
[self addSubview:arrowIMView]; [self addSubview:arrowIMView];
_arrowImageView = arrowIMView; _arrowImageView = arrowIMView;
_arrowImageView.frame = CGRectMake(20, 19.5, 8, 11);
UILabel *scoreLabel = [[UILabel alloc] init]; UILabel *scoreLabel = [[UILabel alloc] init];
scoreLabel.textAlignment = NSTextAlignmentCenter; scoreLabel.textAlignment = NSTextAlignmentCenter;
...@@ -136,15 +138,22 @@ ...@@ -136,15 +138,22 @@
- (void)didMoveToSuperview - (void)didMoveToSuperview
{ {
if (_rankListModel.isOpened) { if (_rankListModel.isOpened) {
[UIView animateWithDuration:0.2 animations:^{ [UIView animateWithDuration:0.01 animations:^{
_arrowImageView.transform = CGAffineTransformIdentity;
_arrowImageView.transform = CGAffineTransformMakeRotation(M_PI / 2);
CGAffineTransform transform = CGAffineTransformMakeRotation(90 * M_PI/180.0);
[_arrowImageView setTransform:transform];
// _arrowImageView.transform = CGAffineTransformIdentity;
// _arrowImageView.transform = CGAffineTransformMakeRotation(M_PI / 2);
}]; }];
} else { } else {
[UIView animateWithDuration:0.2 animations:^{ [UIView animateWithDuration:0.01 animations:^{
_arrowImageView.transform = CGAffineTransformIdentity;
_arrowImageView.transform = CGAffineTransformMakeRotation(0); CGAffineTransform transform = CGAffineTransformMakeRotation(0 * M_PI/180.0);
[_arrowImageView setTransform:transform];
// _arrowImageView.transform = CGAffineTransformIdentity;
// _arrowImageView.transform = CGAffineTransformMakeRotation(0);
}]; }];
} }
} }
...@@ -154,7 +163,15 @@ ...@@ -154,7 +163,15 @@
[super layoutSubviews]; [super layoutSubviews];
_bgView.frame = self.bounds; _bgView.frame = self.bounds;
_bgButton.frame = CGRectMake(30, 0, 0.35 * kScreenWidth, self.bounds.size.height); _bgButton.frame = CGRectMake(30, 0, 0.35 * kScreenWidth, self.bounds.size.height);
_arrowImageView.frame = CGRectMake(20, (self.frame.size.height - 11) / 2, 9, 10);
// if (_rankListModel.isOpened) {
// _arrowImageView.frame = CGRectMake(19, (self.frame.size.height - 9) / 2, 11, 8);
//
// } else {
// _arrowImageView.frame = CGRectMake(20, (self.frame.size.height - 8) / 2, 8, 11);
// }
_scoreLabel.frame = CGRectMake(0.4 * kScreenWidth, 0, 0.25 * kScreenWidth, 50); _scoreLabel.frame = CGRectMake(0.4 * kScreenWidth, 0, 0.25 * kScreenWidth, 50);
if (_index <= 3) { if (_index <= 3) {
_gradeImageView.frame = CGRectMake(0.8 * kScreenWidth, 9, 36, 33); _gradeImageView.frame = CGRectMake(0.8 * kScreenWidth, 9, 36, 33);
......
...@@ -59,6 +59,8 @@ ...@@ -59,6 +59,8 @@
@property (nonatomic, assign) NSInteger statisMode; @property (nonatomic, assign) NSInteger statisMode;
@property (nonatomic, strong) NSString *selectName; @property (nonatomic, strong) NSString *selectName;
@property (nonatomic) BOOL isChoose; @property (nonatomic) BOOL isChoose;
@end @end
...@@ -386,8 +388,11 @@ ...@@ -386,8 +388,11 @@
if (!cell) { if (!cell) {
cell = [[RankCommentCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kRankingCell]; cell = [[RankCommentCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:kRankingCell];
} }
RankListModel *rankListModel = _rankData[indexPath.section]; RankListModel *rankListModel = _rankData[indexPath.section - 1];
RankCommentModel *commentModel = rankListModel.comments[indexPath.row]; NSLog(@"~~~~~ = %@", rankListModel.comments);
NSDictionary *dict = rankListModel.comments[indexPath.row];
RankCommentModel *commentModel = [[RankCommentModel alloc] init];
[commentModel setValuesForKeysWithDictionary:dict];
cell.rankComment = commentModel; cell.rankComment = commentModel;
return cell; return cell;
} }
...@@ -437,6 +442,7 @@ ...@@ -437,6 +442,7 @@
RankDetailViewController *rankDetailVC = [[RankDetailViewController alloc] init]; RankDetailViewController *rankDetailVC = [[RankDetailViewController alloc] init];
rankDetailVC.indexRow = rankList.index; rankDetailVC.indexRow = rankList.index;
rankDetailVC.uuid = rankList.uuid; rankDetailVC.uuid = rankList.uuid;
rankDetailVC.commentId = rankList.commentId;
rankDetailVC.store_uuid = rankList.store_uuid; rankDetailVC.store_uuid = rankList.store_uuid;
rankDetailVC.storeAddress = rankList.storeAddress; rankDetailVC.storeAddress = rankList.storeAddress;
rankDetailVC.storePictures = rankList.storePictures; rankDetailVC.storePictures = rankList.storePictures;
...@@ -491,6 +497,7 @@ ...@@ -491,6 +497,7 @@
rankDetailVC.indexRow = rankList.index; rankDetailVC.indexRow = rankList.index;
rankDetailVC.uuid = rankList.uuid; rankDetailVC.uuid = rankList.uuid;
rankDetailVC.store_uuid = rankList.store_uuid; rankDetailVC.store_uuid = rankList.store_uuid;
rankDetailVC.commentId = rankList.commentId;
rankDetailVC.storeAddress = rankList.storeAddress; rankDetailVC.storeAddress = rankList.storeAddress;
rankDetailVC.storePictures = rankList.storePictures; rankDetailVC.storePictures = rankList.storePictures;
[self.navigationController pushViewController:rankDetailVC animated:YES]; [self.navigationController pushViewController:rankDetailVC animated:YES];
......
...@@ -204,6 +204,7 @@ typedef NSComparisonResult (^NSComparator)(id obj1, id obj2); ...@@ -204,6 +204,7 @@ typedef NSComparisonResult (^NSComparator)(id obj1, id obj2);
[tempArray addObject:picList]; [tempArray addObject:picList];
} }
_allPraiseListArray = tempArray; _allPraiseListArray = tempArray;
[self.tableView reloadData]; [self.tableView reloadData];
[MBProgressHUD hideHUDForView:self.view animated:YES]; [MBProgressHUD hideHUDForView:self.view animated:YES];
[self.tableView.header endRefreshing]; [self.tableView.header endRefreshing];
...@@ -298,7 +299,6 @@ typedef NSComparisonResult (^NSComparator)(id obj1, id obj2); ...@@ -298,7 +299,6 @@ typedef NSComparisonResult (^NSComparator)(id obj1, id obj2);
[questionTempArr addObject:question]; [questionTempArr addObject:question];
} }
_allQuestionArray = questionTempArr; _allQuestionArray = questionTempArr;
NSLog(@"111quesssssssss.count === %ld", _allQuestionArray.count);
[self.tableView reloadData]; [self.tableView reloadData];
[MBProgressHUD hideHUDForView:self.view animated:YES]; [MBProgressHUD hideHUDForView:self.view animated:YES];
......
...@@ -32,6 +32,10 @@ ...@@ -32,6 +32,10 @@
<key>NSAllowsArbitraryLoads</key> <key>NSAllowsArbitraryLoads</key>
<true/> <true/>
</dict> </dict>
<key>UIBackgroundModes</key>
<array>
<string>remote-notification</string>
</array>
<key>UILaunchStoryboardName</key> <key>UILaunchStoryboardName</key>
<string>LaunchScreen</string> <string>LaunchScreen</string>
<key>UIRequiredDeviceCapabilities</key> <key>UIRequiredDeviceCapabilities</key>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment