//自定义cell样式1
overrideinit(style:UITableViewCell.CellStyle, reuseIdentifier:String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
letdp =UILabel.init(frame:CGRect.init(x: 10, y: 5, width: 250, height: 40))
dp.text="随意吧什么鬼"
self.addSubview(dp)
letspck =UILabel.init(frame:CGRect.init(x: 300, y: 5, width: 100, height: 40))
spck.textColor=UIColor.red
spck.text="商品出库"
self.addSubview(spck)
letwlxx =UILabel.init(frame:CGRect.init(x: 30, y: 30, width: 350, height: 90))
wlxx.numberOfLines=0
wlxx.text="上来看到飞机奥数的金发少女胸围杀了多久佛瓷碗搜洒进来的佛琼儿"
self.addSubview(wlxx)
letsj =UILabel.init(frame:CGRect.init(x: 30, y: 90, width: 350, height: 40))
sj.text="2018年12月21日"
sj.textColor=UIColor.lightGray
self.addSubview(sj)
letimg =UIImageView.init(frame:CGRect.init(x: 20, y: 130, width: 70, height: 70))
img.image=UIImage.init(named:"07")
self.addSubview(img)
letxx =UILabel.init(frame:CGRect.init(x: 130, y: 120, width: 250, height: 90))
xx.numberOfLines=0
xx.text="上来看到飞机奥数的金发少女胸围杀了多久佛瓷碗搜洒进来的佛琼儿"
self.addSubview(xx)
letsp =UILabel.init(frame:CGRect.init(x: 180, y: 210, width: 100, height: 40))
sp.text="共计1件商品"
self.addSubview(sp)
letjp =UILabel.init(frame:CGRect.init(x: 280, y: 210, width: 120, height: 40))
jp.text="付款 $323.00"
self.addSubview(jp)
letbtn =UIButton.init(frame:CGRect.init(x: 200, y: 250, width: 90, height: 40))
btn.backgroundColor=UIColor.yellow
btn.setTitle("再次购买", for: UIControl.State.normal)
btn.setTitleColor(UIColor.black, for: UIControl.State.normal)
self.addSubview(btn)
letbtn1 =UIButton.init(frame:CGRect.init(x: 300, y: 250, width: 90, height: 40))
btn1.backgroundColor=UIColor.yellow
btn1.setTitle("查看物流", for: UIControl.State.normal)
btn1.setTitleColor(UIColor.black, for: UIControl.State.normal)
self.addSubview(btn1)
}
网友评论