// // SPVIPOrderRecordViewController.swift // MoviaBox // // Created by 佳尔 on 2025/4/29. // import UIKit class SPVIPOrderRecordViewController: SPViewController { //MARK: UI属性 private lazy var tableView: SPTableView = { let tableView = SPTableView(frame: .zero, style: .plain) tableView.delegate = self tableView.dataSource = self tableView.rowHeight = 74 SPVIPOrderRecordCell.registerCell(tableView: tableView) return tableView }() override func viewDidLoad() { super.viewDidLoad() setBackgroundView(isShowGradient: false, bgImage: nil, backgroundColor: .clear) _setupUI() } } extension SPVIPOrderRecordViewController { private func _setupUI() { view.addSubview(tableView) tableView.snp.makeConstraints { make in make.edges.equalToSuperview() } } } //MARK: -------------- UITableViewDelegate & UITableViewDataSource -------------- extension SPVIPOrderRecordViewController: UITableViewDelegate, UITableViewDataSource { func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { let cell = SPVIPOrderRecordCell.dequeueReusableCell(tableView: tableView, indexPath: indexPath) return cell } func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return 10 } }