You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
1.1 KiB

2 years ago
<?php
namespace App\Forms;
use App\Models\Project;
use Kris\LaravelFormBuilder\Form;
use Kris\LaravelFormBuilder\Field;
class AskSubmitForm extends Form
{
public function buildForm()
{
$this->add("project_id", Field::HIDDEN, ["label" => "所属项目/医院", "rules" => "required"]);
2 years ago
$this->add("visit", Field::TEXT, ["label" => "拜访人员", "rules" => "required"]);
$this->add("date", Field::DATE, ["label" => "考核日期", "rules" => "required"]);
2 years ago
$this->add("department", Field::TEXT, ["label" => "科室", "rules" => "required"]);
2 years ago
$this->add("ask[]", Field::NUMBER, ["label" => "遵守医院各项规章制度,维持秩序。","rules" => "required",'attr' => ['placeholder' => 'Enter text here...']]);
2 years ago
2 years ago
2 years ago
$this->add("tip", Field::TEXTAREA, ["label" => "建议"]);
2 years ago
$this->add('buttons', 'buttongroup', ["splitted" => true, "buttons" => [
["label" => "保存", "attr" => ["class" => "btn btn-primary mr-1", "type" => "submit"]],
["label" => "返回", "attr" => ["class" => "btn btn-light btn-back", "type" => "button"]]
]]);
}
}