|
@@ -27,6 +27,9 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
videoPlayView.assetURLString = self.videoItemMdl?.video
|
|
|
}
|
|
|
|
|
|
+ beanLabel.text = "\(self.videoItemMdl?.willCollectBean ?? 0)彩虹豆待收获"
|
|
|
+
|
|
|
+
|
|
|
personIconBtn.kf.setImage(with: kURLImage(name: self.videoItemMdl?.avatar ?? ""), for: .normal, placeholder: kImage(name: "default_avatar"))
|
|
|
personLabel.text = self.videoItemMdl?.username
|
|
|
|
|
@@ -49,9 +52,20 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
followButton.layer.borderColor = kffffffColor.cgColor
|
|
|
}
|
|
|
|
|
|
-// title string 标题
|
|
|
+ if !(self.videoItemMdl?.title == "" || self.videoItemMdl?.title == nil) {
|
|
|
+ // 有标题
|
|
|
+ videoTitleLabel.text = self.videoItemMdl?.title
|
|
|
+
|
|
|
+ } else {
|
|
|
+ // 无标题
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ topicView.topicArray = self.videoItemMdl?.topic
|
|
|
+ topicView.reloadData()
|
|
|
+
|
|
|
+
|
|
|
// content string 内容
|
|
|
-// topic array 话题数组,id=>name
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -125,6 +139,8 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
rainbowBeanView.addSubview(beanIconImageView)
|
|
|
rainbowBeanView.addSubview(beanLabel)
|
|
|
|
|
|
+ addSubview(videoTitleLabel)
|
|
|
+
|
|
|
|
|
|
addSubview(playStatusImageView)
|
|
|
|
|
@@ -240,6 +256,7 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
make.centerY.equalToSuperview()
|
|
|
make.width.equalTo(64)
|
|
|
make.height.equalTo(20)
|
|
|
+ make.right.equalToSuperview()
|
|
|
}
|
|
|
|
|
|
// 彩虹豆View
|
|
@@ -261,6 +278,14 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
make.right.equalTo(-6)
|
|
|
}
|
|
|
|
|
|
+ videoTitleLabel.snp.makeConstraints { (make) in
|
|
|
+ make.left.equalTo(14)
|
|
|
+ make.right.equalTo(-14)
|
|
|
+
|
|
|
+ // FIXME:待调整底约束
|
|
|
+ make.bottom.equalToSuperview().offset(-150)
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
|
|
|
//
|
|
@@ -407,13 +432,11 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
|
|
|
private lazy var topicView: CommunityVideoTopicView = {
|
|
|
let topicView = CommunityVideoTopicView()
|
|
|
- topicView.backgroundColor = UIColor.clear
|
|
|
return topicView
|
|
|
}()
|
|
|
|
|
|
private lazy var personBackView: UIView = {
|
|
|
let personBackView = UIView()
|
|
|
- personBackView.backgroundColor = UIColor.clear
|
|
|
return personBackView
|
|
|
}()
|
|
|
|
|
@@ -439,7 +462,7 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
private lazy var followButton: UIButton = {
|
|
|
let followButton = UIButton(type: UIButton.ButtonType.custom)
|
|
|
followButton.titleLabel?.font = kMediumFont13
|
|
|
- followButton.layer.cornerRadius = 13
|
|
|
+ followButton.layer.cornerRadius = 11
|
|
|
followButton.layer.masksToBounds = true
|
|
|
followButton.setTitleColor(kffffffColor, for: .normal)
|
|
|
followButton.rx.tap.subscribe(onNext: {[weak self] (data) in
|
|
@@ -466,7 +489,6 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
|
|
|
private lazy var beanLabel: UILabel = {
|
|
|
let beanLabel = UILabel()
|
|
|
- beanLabel.text = "xx彩虹豆待收获"
|
|
|
beanLabel.textColor = kffffffColor
|
|
|
beanLabel.font = kRegularFont13
|
|
|
return beanLabel
|
|
@@ -474,11 +496,10 @@ class CommunityVideoCoverCollectionCell: UICollectionViewCell {
|
|
|
|
|
|
private lazy var videoTitleLabel: UILabel = {
|
|
|
let videoTitleLabel = UILabel()
|
|
|
- videoTitleLabel.text = "我就是一个视频的Title"
|
|
|
videoTitleLabel.textColor = kffffffColor
|
|
|
videoTitleLabel.font = kMediumFont16
|
|
|
return videoTitleLabel
|
|
|
- }()
|
|
|
+ }()
|
|
|
|
|
|
|
|
|
// 播放暂停icon
|