模块ID没有出现在Gii中?

时间:2016-01-27 18:52:49

标签: yii2 yii-modules

我没有收到模块ID,如Youtube教程https://www.youtube.com/watch?v=GtHB58-JA38,7:33

所示

我是Yii的初学者,并会感谢你的回复。

enter image description here

我的意思是,我无法创建特定于模块的CRUD

创建模块后,如何使用Gii创建模块的CRUD?

6 个答案:

答案 0 :(得分:1)

您可以将视图设置为backend\modules\settings\views\companies。通过这样做,我得到了代码文件中提到的相同文件。

答案 1 :(得分:0)

如果您需要与crud中的设置模块相关,以创建正常的CRUD视图

在模块ID中你应该数字

 settings

答案 2 :(得分:0)

@ app / modules / settings / views /(查看名称)在视图路径中,我们将得到相同的结果

答案 3 :(得分:0)

我有同样的事情,您只是在视图路径的开头添加了一个“ @”:

const showGoogle = Boolean(localStorage.getItem('showGoogle'));
const win = doOpen(showGoogle ? 'https://google.com' : 'https://othersite.com');
localStorage.setItem('showGoogle', !showGoogle);

答案 4 :(得分:0)

对我有用

模型类:backend\modules\students\models\Pdf

搜索模型类:backend\modules\students\models\PdfSearch

控制器类:backend\modules\students\controllers\PdfController

查看路径:@backend\modules\students\views\pdf

You can use like this

This is my generated output folders

答案 5 :(得分:-1)

我认为您应该将View Path添加为: 的后端\模块\设置\观点