// // RAEditLabelCell.m // Apex And Drivers // // Created by Jack on 2018/6/4. // Copyright © 2018年 USAI. All rights reserved. // #import "RAEditLabelCell.h" #import "RAEditLabelModel.h" @interface RAEditLabelCell () @property (strong, nonatomic) IBOutlet UILabel *titleLaebl; @property (strong, nonatomic) IBOutlet UITextView *valueLabel; @end @implementation RAEditLabelCell - (void)awakeFromNib { [super awakeFromNib]; // Initialization code self.valueLabel.textContainerInset = UIEdgeInsetsMake(0, -5, 0, -5); self.model = nil; } - (void)prepareForReuse { [super prepareForReuse]; self.model = nil; } - (void)setSelected:(BOOL)selected animated:(BOOL)animated { [super setSelected:selected animated:animated]; // Configure the view for the selected state } - (void)setModel:(RAEditLabelModel *)model { _model = model; self.titleLaebl.text = _model.title; self.valueLabel.text = _model.value; if (model.detectTel) { self.valueLabel.dataDetectorTypes = UIDataDetectorTypePhoneNumber; } else { self.valueLabel.dataDetectorTypes = UIDataDetectorTypeNone; } } @end