Using Gii to generate CRUD
We introduced Gii in Chapter 5, Developing a Reservation System, to generate models. Now we want to use Gii to create CRUD actions with a controller and views.
Type http://hostname/basic/web/gii
in your browser to return to the Gii welcome page. Click on the Start button of the CRUD section. We have to fill out four fields:
Model Class: This is the ActiveRecord class associated with the table where CRUD will be built; this class should be provided using the fully qualified namespaced path, for example:
app\models\ModelClass
.Search Model Class: This is the name of the search model class to be generated and extended from the model class; this class will provide useful methods and extensions to be used when searching the record. This should be provided using the fully qualified namespaced path, for example:
app\models\ModelClassSearch
.Controller Class: This is the name of the controller class to be generated; this class should be provided using the fully qualified...