111
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.
 
 
 
 
 

33 line
713 B

  1. <?php
  2. /**
  3. * @copyright (C)2016-2099 Hnaoyun Inc.
  4. * @author XingMeng
  5. * @email hnxsh@foxmail.com
  6. * @date 2017年8月28日
  7. * 应用公共模型类
  8. */
  9. namespace app\common;
  10. use core\basic\Model;
  11. class AdminModel extends Model
  12. {
  13. // 获取配置参数
  14. public function getConfig()
  15. {
  16. return parent::table('ay_config')->column('value', 'name');
  17. }
  18. // 获取站点配置信息
  19. public function getSite()
  20. {
  21. return parent::table('ay_site')->where("acode='" . session('acode') . "'")->find();
  22. }
  23. // 获取公司配置信息
  24. public function getCompany()
  25. {
  26. return parent::table('ay_company')->where("acode='" . session('acode') . "'")->find();
  27. }
  28. }