=$form->field($patient, 'hospital_id')->widget(Select2::classname(), [
'data' => ArrayHelper::map(ConstHospital::find()->where('id > 1')->orderBy(['name' => SORT_ASC])->all(), 'id', 'name'),
'options' => ['placeholder' => 'เลือกโรงพยาบาล'],
'theme' => Select2::THEME_BOOTSTRAP,
'pluginOptions' => [
'allowClear' => true,
],
])?>
= $form->field($patient, 'title_id')->dropDownList(ArrayHelper::map(PatientTitle::find()->orderBy(['name' => SORT_ASC])->all(), 'id', 'name')) ?>
= $form->field($patient, 'name') ?>
= $form->field($patient, 'gender')->dropDownList([3 => '', 0 => 'ชาย', 1 => 'หญิง']) ?>
= $form->field($patient, 'race') ?>
= $form->field($patient, 'id_card')->widget(MaskedInput::className(), [
'mask' => '9-9999-99999-99-9'
]) ?>
= $form->field($patient, 'birthdate')->widget(MaskedInput::className(), [
'mask' => '99/99/9999'
])->textInput() ?>
= $form->field($patient, 'age') ?>
= $form->field($patient, 'age_unit')->dropDownList(['ปี' => 'ปี', 'เดือน' => 'เดือน', 'วัน' => 'วัน']) ?>
= $form->field($patient, 'h_n') ?>
= $form->field($case_fish, 'a_n') ?>
= $form->field($case_fish, 'ward_id')/*->widget(Select2::classname(), [
'data' => ArrayHelper::map(PatientWard::find()->orderBy(['name' => SORT_ASC])->all(), 'id', 'name'),
'options' => ['placeholder' => ''],
'pluginOptions' => [
'allowClear' => true,
//'tags' => true,
],
])*/ ?>
= $form->field($case_fish, 'clinician') ?>
= $form->field($case_fish, 'collect_at')->widget(MaskedInput::className(), [
'mask' => '99/99/9999',
]) ?>
= $form->field($case_fish, 'specimen') ?>
= $form->field($case_fish, 'block_no') ?>
= $form->field($fish_test, 'fish_type_id')->dropDownList(ArrayHelper::map(ConstServiceCharge::find()->where(['lab' => 'fish'])->all(), 'id', function ($model) {
return '(' . $model->code . ') ' . $model->name . ' ' . $model->price . ' บาท';
})) ?>
= $form->field($finance, 'is_cash')->checkbox() ?>
= $form->field($case_fish, 'clinical_diagnosis')->textarea() ?>
= $form->field($fish_test, 'note')->textarea() ?>
= $form->field($fish_test, 'fish_file[]')->fileInput(['multiple' => true]) ?>
getFiles() as $file => $val) {
?>
= Html::a($val, Yii::getAlias('@web') . '/uploads/fish/file/' . $val, ['target' => '_blank']); ?>
$val,
'id' => $fish_test->id,
'id_case' => $case_fish->id_case
], [
'class' => 'btn btn-xs btn-danger',
'data-confirm' => 'ต้องการลบ?'
]);
?>