IncInfo.php 645 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: Jun.peng
  5. * Date: 2019/6/19
  6. * Time: 10:37
  7. */
  8. namespace app\admin\model;
  9. use think\Model;
  10. //企业信息
  11. class IncInfo extends Model
  12. {
  13. protected $name = 'inc_info';
  14. /**
  15. * 更新信息
  16. *
  17. * @param array $param 更新数据
  18. * @return bool 布尔类型的返回结果
  19. */
  20. public static function updateIncInfo($param)
  21. {
  22. if (empty($param)) {
  23. return false;
  24. }
  25. if (is_array($param)) {
  26. $result = self::where('id', 1)->update($param);
  27. return true;
  28. } else {
  29. return false;
  30. }
  31. }
  32. }