加密后的代码
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.

CommunitySearchRecord.php 493B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. namespace app\common\model\community;
  3. use app\common\basics\Models;
  4. /**
  5. * 种草社区搜索记录
  6. * Class CommunitySearchRecord
  7. * @package app\common\model\community
  8. */
  9. class CommunitySearchRecord extends Models
  10. {
  11. /**
  12. * @notes 增加搜索次数
  13. * @param $id
  14. * @return mixed
  15. * @author 段誉
  16. * @date 2022/5/9 16:18
  17. */
  18. public static function incCount($id)
  19. {
  20. return self::where(['id' => $id])->inc('count')->update();
  21. }
  22. }