Field Name | Data Type |
---|---|
id | int(PK) |
created_at | timestamp |
name | varchar(255) |
Field Name | Data Type |
---|---|
id | int(PK) |
created_at | timestamp |
name | varchar(255) |
provinces_id | int(11) |
$this->form[] = ['label'=>'Province','type'=>'select','name'=>'provinces_id','datatable'=>'provinces,name'];
$this->form[] = ['label'=>'City','type'=>'select','name'=>'cities_id','datatable'=>'cities,name','parent_select'=>'provinces_id'];
So you need to add parent_select
attribute and fill it with name of previous select name.