AppService.php 339 B

1234567891011121314151617181920212223242526
  1. <?php
  2. declare (strict_types = 1);
  3. namespace app;
  4. use library\utils\Json;
  5. use think\Service;
  6. /**
  7. * 应用服务类
  8. */
  9. class AppService extends Service
  10. {
  11. public function register()
  12. {
  13. // 服务注册
  14. $this->app->bind('json', Json::class);
  15. }
  16. public function boot()
  17. {
  18. // 服务启动
  19. }
  20. }