@include('components.input', [
'id' => 'name',
'name' => 'name',
'label' => 'Material Name',
'type' => 'text',
'mandatory' => true,
'value' => isset($materials->name) ? $materials->name : '',
'placeholder' => 'Enter Material Name',
])
@include('components.select', [
'id' => 'reading',
'name' => 'reading',
'class' => 'materialType',
'mandatory' => true,
'label' => 'Material Type',
'options' => config('constants.materialTypes'),
'selected' => isset($materials->reading) ? $materials->reading : '',
])
@include('components.input', [
'id' => 'duration',
'name' => 'duration',
'label' => 'Duration (In Minutes)',
'type' => 'number',
'mandatory' => true,
'readonly' => isset($materials->reading) && !$materials->reading,
'value' => isset($materials->duration) ? $materials->duration : '',
'placeholder' => 'Enter Duration in Minutes',
])