12345678910111213141516171819202122232425262728293031323334353637383940 |
- //
- // YOUPAIHRSearchBannerCell.m
- // YOUQU
- //
- // Created by xiaohaoran on 2021/12/15.
- // Copyright © 2021 MS. All rights reserved.
- //
- #import "YOUPAIHRSearchBannerCell.h"
- @implementation YOUPAIHRSearchBannerCell
- -(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
- if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
- [self setupUI];
- }
- return self;
-
- }
- -(void)setupUI{
-
- UIImageView *vq_imageView = [UIImageView new];
- self.vq_banneriImageView = vq_imageView;
- [self addSubview:vq_imageView];
- [vq_imageView mas_makeConstraints:^(MASConstraintMaker *make) {
- make.left.mas_equalTo(14);
- make.top.mas_equalTo(8);
- make.bottom.mas_equalTo(-20);
- make.right.mas_equalTo(-14);
- }];
- vq_imageView.layer.cornerRadius = 5;
- vq_imageView.contentMode = UIViewContentModeScaleAspectFill;
- vq_imageView.clipsToBounds = YES;
- }
- -(void)setModel:(youpaipbannerModel *)model{
-
- _model = model;
- [self.vq_banneriImageView sd_setImageWithURL:[LCTools getImageUrlWithAddress:model.youpaipimage] placeholderImage:nil];
- }
- @end
|