Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

疑问: Modules改变后的问题 #81

Closed
emonduora opened this issue Mar 8, 2024 · 4 comments
Closed

疑问: Modules改变后的问题 #81

emonduora opened this issue Mar 8, 2024 · 4 comments

Comments

@emonduora
Copy link

描述问题:

原来使用的nwidart/laravel-modules功能中有两个Provider,一个是RouteServiceProvider,一个是XXXServiceProvider
这些要自己写吗?文档太少,看不懂
$this->registerCommands();
$this->registerCommandSchedules();
$this->registerTranslations();
$this->registerConfig();
$this->registerViews();
$this->loadMigrationsFrom(module_path($this->moduleName, 'database/migrations'));

截图或视频:

可以的话,尽可能提供截图或视频来补充描述你的问题...

如何复现(请务必完整填写下面内容):

  1. owl-admin 版本是什么?

你是在哪个版本的 owl-admin 上遇到的问题?

  1. PHP & Laravel 版本是什么?

php8.3 & laravel: 10..

  1. 运行环境

eg: Win + Docker Mac + Sail Linux + BT

  1. 操作步骤

请简单描述一下复现的操作步骤...

@slowlyo
Copy link
Owner

slowlyo commented Mar 8, 2024

现在缺少什么功能吗

@emonduora
Copy link
Author

image

@emonduora
Copy link
Author

emonduora commented Mar 14, 2024

模块以apim为例:
1、原来模块中有config目录,有独立的配置文件譬如response.php,使用config('response.format')就可读取
2、原来使用多语言__('apim:menu.title')这样表达,现在如何表达?
3、原来route有web,api,route,这涉及到middleware,现在如何区分?
4、一个完整的模块应该很容易移植到一个完整的laravel应用,现模块的目录结构也不同于laravel原来的目录结构

@slowlyo
Copy link
Owner

slowlyo commented Mar 14, 2024

模块以apim为例: 1、原来模块中有config目录,有独立的配置文件譬如response.php,使用config('response.format')就可读取 2、原来使用多语言__('apim:menu.title')这样表达,现在如何表达? 3、原来route有web,api,route,这涉及到middleware,现在如何区分? 4、一个完整的模块应该很容易移植到一个完整的laravel应用,现模块的目录结构也不同于laravel原来的目录结构

你可以再装一个 nwidart/laravel-modules 😅

@slowlyo slowlyo closed this as completed Mar 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants