家政小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

ProductOrder.php 754B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. namespace App\Models;
  3. /**
  4. * Class ProductOrder
  5. * @package App\Models
  6. * 产品订单
  7. */
  8. class ProductOrder extends Order
  9. {
  10. function __construct() {
  11. parent::__construct("产品", "产品", "product_order");
  12. $fillable = [
  13. 'product_id', // 产品名称
  14. 'product_name', // 产品信息
  15. 'color', // 产品颜色款色
  16. 'unit', // 产品单格
  17. 'amount', // 产品数量
  18. 'remark', // 买家备注
  19. 'info', // 卖家信息
  20. ];
  21. parent::mergeFillable(parent::getFillable(), $fillable);
  22. }
  23. /**
  24. * 获取博客文章的评论
  25. */
  26. public function comments()
  27. {
  28. return $this->hasMany('App\Comment');
  29. }
  30. }