Userinfo.php 423 B

123456789101112131415161718192021222324252627
  1. <?php
  2. namespace app\admin\model;
  3. use think\Model;
  4. class Userinfo extends Model
  5. {
  6. public function updateUserInfo($condition, $data)
  7. {
  8. $result = $this
  9. ->where($condition)
  10. ->update($data);
  11. return $result;
  12. }
  13. public function getUserInfo($condition)
  14. {
  15. $result = $this
  16. ->where($condition)
  17. ->find();
  18. return $result;
  19. }
  20. }