测试修改
This commit is contained in:
+10
-2
@@ -29,6 +29,8 @@
|
||||
UIView *hengLine=[[UIView alloc] initWithFrame:CGRectMake(0,self.frame.size.height -1,self.frame.size.width, 1)];
|
||||
hengLine.backgroundColor = shuLine.backgroundColor = JWUIColorFromRGB(0xdddddd);
|
||||
[self addSubview:hengLine];
|
||||
[self bringSubviewToFront:self.factoryIcon];
|
||||
self.factoryIcon.hidden=NO;
|
||||
|
||||
}
|
||||
|
||||
@@ -38,12 +40,18 @@
|
||||
|
||||
-(void)intiFactoryImgWith:(DeviceModel *)devicemodel{
|
||||
|
||||
[self.factoryIcon sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@",kGetLogUrl,devicemodel.logo]] placeholderImage:[UIImage imageNamed:@""]];
|
||||
|
||||
if (!self.factoryIcon.image) {
|
||||
self.factoryIcon.image = [UIImage imageNamed:@"brandLogo_hold"];
|
||||
}
|
||||
[self.factoryIcon sd_setImageWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"%@%@",kGetLogUrl,devicemodel.logo]] placeholderImage:[UIImage imageNamed:@"brandLogo_hold"]];
|
||||
if (!self.factoryIcon) {
|
||||
self.factoryIcon.image = [UIImage imageNamed:@"greenbtn_big"];
|
||||
}
|
||||
|
||||
|
||||
[self bringSubviewToFront:self.factoryIcon];
|
||||
self.factoryIcon.hidden=NO;
|
||||
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
+39
-1
@@ -7,6 +7,7 @@
|
||||
//
|
||||
|
||||
#import "FishControlFourthCell.h"
|
||||
#import "xuanduo3fModel.h"
|
||||
|
||||
@implementation FishControlFourthCell
|
||||
- (instancetype)initWithFrame:(CGRect)frame{
|
||||
@@ -258,6 +259,10 @@
|
||||
atIndex:(NSIndexPath *)indexPath
|
||||
addBackModel:(Xuanduo2Model*)model {
|
||||
|
||||
if ([model isKindOfClass:[Xuanduo2Model class]])
|
||||
{
|
||||
|
||||
|
||||
NSInteger index = indexPath.row - 3;
|
||||
if (index == 0) {
|
||||
|
||||
@@ -307,7 +312,40 @@
|
||||
addOffArr:imgOffArr];
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
else if ([model isKindOfClass:[Xuanduo3fModel class]])
|
||||
{
|
||||
|
||||
Xuanduo3fModel*xuan3fmodel=model;
|
||||
NSInteger index = indexPath.row - 3;
|
||||
if (index == 0) {
|
||||
|
||||
NSString*stateString=[xuan3fmodel.light substringWithRange:NSMakeRange(2, IFISH_LIGHTBTN_BYTE)];
|
||||
[self btnImgAtIndex:indexPath withStr:stateString addWithOnImg:imgOnArr
|
||||
addOffArr:imgOffArr];
|
||||
}else if (index == 1){
|
||||
|
||||
NSString*stateString=[xuan3fmodel.gasPump substringWithRange:NSMakeRange(2, IFISH_LIGHTBTN_BYTE)];
|
||||
[self btnImgAtIndex:indexPath withStr:stateString addWithOnImg:imgOnArr
|
||||
addOffArr:imgOffArr];
|
||||
|
||||
}else if (index == 2){
|
||||
|
||||
NSString*stateString=[xuan3fmodel.uvLamp substringWithRange:NSMakeRange(2, IFISH_LIGHTBTN_BYTE)];
|
||||
[self btnImgAtIndex:indexPath withStr:stateString addWithOnImg:imgOnArr
|
||||
addOffArr:imgOffArr];
|
||||
|
||||
}else if (index == 3){
|
||||
|
||||
NSString*stateString=[xuan3fmodel.constTmep substringWithRange:NSMakeRange(2, IFISH_LIGHTBTN_BYTE)];
|
||||
[self btnImgAtIndex:indexPath withStr:stateString addWithOnImg:imgOnArr
|
||||
addOffArr:imgOffArr];
|
||||
|
||||
}else
|
||||
{
|
||||
NSLog(@"index=%ld",indexPath.row);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user