$this->crud->addField([
'name' => 'status',
'label' => 'Featured item',
'type' => 'checkbox',
]);
The generated code is following:
<div class="form-group col-md-12">
<div class="checkbox">
<label>
<input type="hidden" value="0" name="status">
<input type="checkbox" name="status" value="1"> Featured item
</label>
</div>
</div>
Using the above code for checkbox, Everything works fine, value is saving correctly in database and fetched correctly. But checkbox is not checked.
from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2m6JWPR
via IFTTT
Aucun commentaire:
Enregistrer un commentaire