【发布时间】:2021-09-29 16:43:03
【问题描述】:
在此屏幕中如何在 tableview 行之间显示(蓝色视图)
代码: 在情节提要设计中,我已经在标签和图像中提供了所有静态数据,因此使用下面的代码,我得到了上面屏幕截图中的所有单元格,但是在三个单元格之后如何显示蓝框视图,请给我建议
import UIKit
class ViewController: UIViewController , UITableViewDataSource, UITableViewDelegate {
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
return 5
}
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCell(withIdentifier: "BidCell", for: indexPath)
return cell
}
【问题讨论】: