younger_times
2023-04-26 945655d9f53293d7da9d2d11363b3230f6e53bbe
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
//
//  HomeDetailAttachVC.swift
//  BrokerDriver
//
//  Created by 无故事王国 on 2023/4/25.
//
 
import UIKit
 
class HomeDetailAttachVC: BaseViewController {
 
    @IBOutlet weak var attachTableView: UITableView!
    override func viewDidLoad() {
        super.viewDidLoad()
 
        view.backgroundColor = UIColor(hexStr: "#F9FAFF")
        attachTableView.delegate = self
        attachTableView.dataSource = self
        attachTableView.separatorStyle = .none
        attachTableView.register(UINib(nibName: "AttachHeadView", bundle: nil), forHeaderFooterViewReuseIdentifier: "_AttachHeadView")
        attachTableView.register(UINib(nibName: "AttachTCell", bundle: nil), forCellReuseIdentifier: "_AttachTCell")
    }
}
 
extension HomeDetailAttachVC:UITableViewDelegate{
 
}
 
extension HomeDetailAttachVC:UITableViewDataSource{
    func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
        return 20
    }
 
    func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? {
        let headView = tableView.dequeueReusableHeaderFooterView(withIdentifier: "_AttachHeadView") as? AttachHeadView
        return headView
    }
 
    func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
        return 46
    }
 
    func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
        let cell = tableView.dequeueReusableCell(withIdentifier: "_AttachTCell") as! AttachTCell
        return cell
    }
 
    func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
        return 46
    }
}