Umeditor.php 727 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. namespace addons\umeditor;
  3. use think\Addons;
  4. /**
  5. * 插件
  6. */
  7. class Umeditor extends Addons
  8. {
  9. /**
  10. * 插件安装方法
  11. * @return bool
  12. */
  13. public function install()
  14. {
  15. return true;
  16. }
  17. /**
  18. * 插件卸载方法
  19. * @return bool
  20. */
  21. public function uninstall()
  22. {
  23. return true;
  24. }
  25. /**
  26. * @param $params
  27. */
  28. public function configInit(&$params)
  29. {
  30. $config = $this->getConfig();
  31. $params['umeditor'] = [
  32. 'classname' => $config['classname'] ?? '.editor',
  33. 'baidumapkey' => $config['baidumapkey'] ?? '',
  34. 'baidumapcenter' => $config['baidumapcenter'] ?? ''
  35. ];
  36. }
  37. }