RepositoryServiceProvider.php 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. <?php
  2. /*
  3. * This file is part of the Jiannei/lumen-api-starter.
  4. *
  5. * (c) Jiannei <longjian.huang@foxmail.com>
  6. *
  7. * This source file is subject to the MIT license that is bundled
  8. * with this source code in the file LICENSE.
  9. */
  10. namespace App\Providers;
  11. use Prettus\Repository\Providers\LumenRepositoryServiceProvider;
  12. class RepositoryServiceProvider extends LumenRepositoryServiceProvider
  13. {
  14. /**
  15. * Bootstrap services.
  16. */
  17. public function boot()
  18. {
  19. //基础
  20. $this->app->bind(\App\Contracts\Repositories\Base\DepartmentRepository::class, \App\Repositories\Eloquent\Base\DepartmentRepositoryEloquent::class);
  21. $this->app->bind(\App\Contracts\Repositories\ResourceRepository::class, \App\Repositories\Eloquent\ResourceRepositoryEloquent::class);
  22. $this->app->bind(\App\Contracts\Repositories\Base\AdminRepository::class, \App\Repositories\Eloquent\Base\AdminRepositoryEloquent::class);
  23. $this->app->bind(\App\Contracts\Repositories\Base\RoleRepository::class, \App\Repositories\Eloquent\Base\RoleRepositoryEloquent::class);
  24. $this->app->bind(\App\Contracts\Repositories\Base\MenuRepository::class, \App\Repositories\Eloquent\Base\MenuRepositoryEloquent::class);
  25. $this->app->bind(\App\Contracts\Repositories\Base\BannerRepository::class, \App\Repositories\Eloquent\Base\BannerRepositoryEloquent::class);
  26. $this->app->bind(\App\Contracts\Repositories\Base\ShopRepository::class, \App\Repositories\Eloquent\Base\ShopRepositoryEloquent::class);
  27. $this->app->bind(\App\Contracts\Repositories\Base\CategoryRepository::class, \App\Repositories\Eloquent\Base\CategoryRepositoryEloquent::class);
  28. $this->app->bind(\App\Contracts\Repositories\Base\SettingRepository::class, \App\Repositories\Eloquent\Base\SettingRepositoryEloquent::class);
  29. // //api
  30. $this->app->bind(\App\Contracts\Repositories\User\UserRepository::class, \App\Repositories\Eloquent\User\UserRepositoryEloquent::class);
  31. // $this->app->bind(\App\Contracts\Repositories\User\StudentRepository::class, \App\Repositories\Eloquent\User\StudentRepositoryEloquent::class);
  32. //
  33. // //课程
  34. // $this->app->bind(\App\Contracts\Repositories\Course\CategoryRepository::class, \App\Repositories\Eloquent\Course\CategoryRepositoryEloquent::class);
  35. // $this->app->bind(\App\Contracts\Repositories\Course\CourseRepository::class, \App\Repositories\Eloquent\Course\CourseRepositoryEloquent::class);
  36. // $this->app->bind(\App\Contracts\Repositories\Course\ChapterRepository::class, \App\Repositories\Eloquent\Course\ChapterRepositoryEloquent::class);
  37. // $this->app->bind(\App\Contracts\Repositories\Course\VideoRepository::class, \App\Repositories\Eloquent\Course\VideoRepositoryEloquent::class);
  38. // $this->app->bind(\App\Contracts\Repositories\Course\AttachRepository::class, \App\Repositories\Eloquent\Course\AttachRepositoryEloquent::class);
  39. // $this->app->bind(\App\Contracts\Repositories\Course\CommentRepository::class, \App\Repositories\Eloquent\Course\CommentRepositoryEloquent::class);
  40. // $this->app->bind(\App\Contracts\Repositories\Course\OrganizationRepository::class, \App\Repositories\Eloquent\Course\OrganizationRepositoryEloquent::class);
  41. // //中医
  42. // $this->app->bind(\App\Contracts\Repositories\TCM\PatientRepository::class, \App\Repositories\Eloquent\TCM\PatientRepositoryEloquent::class);
  43. // $this->app->bind(\App\Contracts\Repositories\TCM\CategoryRepository::class, \App\Repositories\Eloquent\TCM\CategoryRepositoryEloquent::class);
  44. // $this->app->bind(\App\Contracts\Repositories\TCM\MedicalRecordRepository::class, \App\Repositories\Eloquent\TCM\MedicalRecordRepositoryEloquent::class);
  45. // $this->app->bind(\App\Contracts\Repositories\TCM\PrescriptionRepository::class, \App\Repositories\Eloquent\TCM\PrescriptionRepositoryEloquent::class);
  46. // $this->app->bind(\App\Contracts\Repositories\TCM\DrugRepository::class, \App\Repositories\Eloquent\TCM\DrugRepositoryEloquent::class);
  47. // //信息
  48. // $this->app->bind(\App\Contracts\Repositories\Inform\CategoryRepository::class, \App\Repositories\Eloquent\Inform\CategoryRepositoryEloquent::class);
  49. // $this->app->bind(\App\Contracts\Repositories\Inform\InformationRepository::class, \App\Repositories\Eloquent\Inform\InformationRepositoryEloquent::class);
  50. //
  51. // //笔记
  52. // $this->app->bind(\App\Contracts\Repositories\Note\NoteRepository::class, \App\Repositories\Eloquent\Note\NoteRepositoryEloquent::class);
  53. // $this->app->bind(\App\Contracts\Repositories\Note\CommentRepository::class, \App\Repositories\Eloquent\Note\CommentRepositoryEloquent::class);
  54. // //CMS
  55. // $this->app->bind(\App\Contracts\Repositories\CMS\CategoryRepository::class, \App\Repositories\Eloquent\CMS\CategoryRepositoryEloquent::class);
  56. // $this->app->bind(\App\Contracts\Repositories\CMS\ArticleRepository::class, \App\Repositories\Eloquent\CMS\ArticleRepositoryEloquent::class);
  57. // $this->app->bind(\App\Contracts\Repositories\CMS\BannerRepository::class, \App\Repositories\Eloquent\CMS\BannerRepositoryEloquent::class);
  58. // $this->app->bind(\App\Contracts\Repositories\CMS\SettingRepository::class, \App\Repositories\Eloquent\CMS\SettingRepositoryEloquent::class);
  59. // //试卷
  60. // $this->app->bind(\App\Contracts\Repositories\Exam\TopicRepository::class, \App\Repositories\Eloquent\Exam\TopicRepositoryEloquent::class);
  61. // $this->app->bind(\App\Contracts\Repositories\Exam\PaperRepository::class, \App\Repositories\Eloquent\Exam\PaperRepositoryEloquent::class);
  62. // $this->app->bind(\App\Contracts\Repositories\Exam\PaperResultRepository::class, \App\Repositories\Eloquent\Exam\PaperResultRepositoryEloquent::class);
  63. //区域网格
  64. // $this->app->bind(\App\Contracts\Repositories\Area\AreaRepository::class, \App\Repositories\Eloquent\Area\AreaRepositoryEloquent::class);
  65. // $this->app->bind(\App\Contracts\Repositories\Area\ProjectsRepository::class, \App\Repositories\Eloquent\Area\ProjectsRepositoryEloquent::class);
  66. //网址导航
  67. // $this->app->bind(\App\Contracts\Repositories\Navigation\OrganizationRepository::class, \App\Repositories\Eloquent\Navigation\OrganizationRepositoryEloquent::class);
  68. // $this->app->bind(\App\Contracts\Repositories\Navigation\CategoryRepository::class, \App\Repositories\Eloquent\Navigation\CategoryRepositoryEloquent::class);
  69. // $this->app->bind(\App\Contracts\Repositories\Navigation\WebsiteRepository::class, \App\Repositories\Eloquent\Navigation\WebsiteRepositoryEloquent::class);
  70. //去那里
  71. // $this->app->bind(\App\Contracts\Repositories\Qunali\OrganizationRepository::class, \App\Repositories\Eloquent\Qunali\OrganizationRepositoryEloquent::class);
  72. // $this->app->bind(\App\Contracts\Repositories\Qunali\PointRepository::class, \App\Repositories\Eloquent\Qunali\PointRepositoryEloquent::class);
  73. // $this->app->bind(\App\Contracts\Repositories\Qunali\PointEventRepository::class, \App\Repositories\Eloquent\Qunali\PointEventRepositoryEloquent::class);
  74. //高校模块
  75. // $this->app->bind(\App\Contracts\Repositories\School\TermRepository::class, \App\Repositories\Eloquent\School\TermRepositoryEloquent::class);
  76. // $this->app->bind(\App\Contracts\Repositories\School\TimeRepository::class, \App\Repositories\Eloquent\School\TimeRepositoryEloquent::class);
  77. // $this->app->bind(\App\Contracts\Repositories\School\TeacherRepository::class, \App\Repositories\Eloquent\School\TeacherRepositoryEloquent::class);
  78. // $this->app->bind(\App\Contracts\Repositories\School\StudentRepository::class, \App\Repositories\Eloquent\School\StudentRepositoryEloquent::class);
  79. // $this->app->bind(\App\Contracts\Repositories\School\RoomRepository::class, \App\Repositories\Eloquent\School\RoomRepositoryEloquent::class);
  80. // $this->app->bind(\App\Contracts\Repositories\School\LessonRepository::class, \App\Repositories\Eloquent\School\LessonRepositoryEloquent::class);
  81. // $this->app->bind(\App\Contracts\Repositories\School\CategoryRepository::class, \App\Repositories\Eloquent\School\CategoryRepositoryEloquent::class);
  82. // $this->app->bind(\App\Contracts\Repositories\School\LessonScheduleRepository::class, \App\Repositories\Eloquent\School\LessonScheduleRepositoryEloquent::class);
  83. // $this->app->bind(\App\Contracts\Repositories\School\ScheduleApproveRecordRepository::class, \App\Repositories\Eloquent\School\ScheduleApproveRecordRepositoryEloquent::class);
  84. // $this->app->bind(\App\Contracts\Repositories\School\LessonTeacherRepository::class, \App\Repositories\Eloquent\School\LessonTeacherRepositoryEloquent::class);
  85. // $this->app->bind(\App\Contracts\Repositories\School\GradeRepository::class, \App\Repositories\Eloquent\School\GradeRepositoryEloquent::class);
  86. //
  87. // //实验室模块
  88. // $this->app->bind(\App\Contracts\Repositories\Lab\ImportRecordRepository::class, \App\Repositories\Eloquent\Lab\ImportRecordRepositoryEloquent::class);
  89. // $this->app->bind(\App\Contracts\Repositories\Lab\MaintainRepository::class, \App\Repositories\Eloquent\Lab\MaintainRepositoryEloquent::class);
  90. // $this->app->bind(\App\Contracts\Repositories\Lab\ScheduleRepository::class, \App\Repositories\Eloquent\Lab\ScheduleRepositoryEloquent::class);
  91. // $this->app->bind(\App\Contracts\Repositories\Lab\OpenAppointmentRepository::class, \App\Repositories\Eloquent\Lab\OpenAppointmentRepositoryEloquent::class);
  92. // $this->app->bind(\App\Contracts\Repositories\Lab\AccountApplyRepository::class, \App\Repositories\Eloquent\Lab\AccountApplyRepositoryEloquent::class);
  93. //
  94. // //通知公告
  95. // $this->app->bind(\App\Contracts\Repositories\News\NoticeRepository::class, \App\Repositories\Eloquent\News\NoticeRepositoryEloquent::class);
  96. // $this->app->bind(\App\Contracts\Repositories\News\MessageRepository::class, \App\Repositories\Eloquent\News\MessageRepositoryEloquent::class);
  97. // //电力
  98. // $this->app->bind(\App\Contracts\Repositories\Dianli\TaskRepository::class, \App\Repositories\Eloquent\Dianli\TaskRepositoryEloquent::class);
  99. // //考试
  100. // $this->app->bind(\App\Contracts\Repositories\Exam\PaperRepository::class, \App\Repositories\Eloquent\Exam\PaperRepositoryEloquent::class);
  101. // $this->app->bind(\App\Contracts\Repositories\Exam\PaperResultRepository::class, \App\Repositories\Eloquent\Exam\PaperResultRepositoryEloquent::class);
  102. // $this->app->bind(\App\Contracts\Repositories\Exam\TopicRepository::class, \App\Repositories\Eloquent\Exam\TopicRepositoryEloquent::class);
  103. //课程
  104. $this->app->bind(\App\Contracts\Repositories\Course\CategoryRepository::class, \App\Repositories\Eloquent\Course\CategoryRepositoryEloquent::class);
  105. $this->app->bind(\App\Contracts\Repositories\Course\CourseRepository::class, \App\Repositories\Eloquent\Course\CourseRepositoryEloquent::class);
  106. $this->app->bind(\App\Contracts\Repositories\Course\ChapterRepository::class, \App\Repositories\Eloquent\Course\ChapterRepositoryEloquent::class);
  107. $this->app->bind(\App\Contracts\Repositories\Course\VideoRepository::class, \App\Repositories\Eloquent\Course\VideoRepositoryEloquent::class);
  108. $this->app->bind(\App\Contracts\Repositories\Course\AttachRepository::class, \App\Repositories\Eloquent\Course\AttachRepositoryEloquent::class);
  109. $this->app->bind(\App\Contracts\Repositories\Course\CommentRepository::class, \App\Repositories\Eloquent\Course\CommentRepositoryEloquent::class);
  110. }
  111. }