Product.php 431 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. namespace app\user\model;
  3. use think\Model;
  4. /**
  5. * 用户管理
  6. */
  7. class Product extends Model
  8. {
  9. public function getProduct()
  10. {
  11. $result = $this
  12. ->where(['product_pid' => 0])
  13. ->select();
  14. return $result;
  15. }
  16. public function getProductWhere($condition)
  17. {
  18. $result = $this
  19. ->where($condition)
  20. ->find();
  21. return $result;
  22. }
  23. }