UserDownload.php 409 B

1234567891011121314151617
  1. <?php
  2. namespace app\common\model;
  3. use think\Model;
  4. // 会员下载
  5. class UserDownload extends Model
  6. {
  7. //
  8. public static function getDownLoadNum($first_id,$second_id,$type)
  9. {
  10. $where = [];
  11. if($first_id) $where['first_id']=$first_id;
  12. if($second_id) $where['second_id']=$second_id;
  13. if($type) $where['type']=$type;
  14. return static::where($where)->count();
  15. }
  16. }