1 | <?php |
||
9 | class Select extends NamedElement |
||
10 | { |
||
11 | protected $type = 'select'; |
||
12 | |||
13 | protected $options = []; |
||
14 | |||
15 | protected $optionsLabelAttribute; |
||
16 | |||
17 | protected $optionsValueAttribute; |
||
18 | |||
19 | protected $size = ''; |
||
20 | |||
21 | public function __construct($name, $title, $options) |
||
26 | |||
27 | public function getSize() |
||
31 | |||
32 | public function setSize($value) |
||
38 | |||
39 | public function getValue() |
||
40 | { |
||
41 | return (string)parent::getValue(); |
||
42 | } |
||
43 | |||
44 | /** |
||
45 | * @return \Illuminate\Support\Collection |
||
46 | */ |
||
47 | public function getOptions() |
||
73 | |||
74 | /** |
||
75 | * @param mixed $options |
||
76 | * |
||
77 | * @return $this |
||
78 | */ |
||
79 | public function setOptions($options) |
||
85 | |||
86 | /** |
||
87 | * |
||
88 | * @return array |
||
89 | */ |
||
90 | protected function setOptionsFromModel() |
||
106 | |||
107 | /** |
||
108 | * @return Model |
||
109 | */ |
||
110 | public function getOptionsModel() |
||
129 | |||
130 | /** |
||
131 | * 获取 options 标题字段 |
||
132 | * |
||
133 | * @return string |
||
134 | */ |
||
135 | public function getOptionsLabelAttribute() |
||
139 | |||
140 | /** |
||
141 | * 设置 options 标题字段 |
||
142 | * |
||
143 | * @param string $value |
||
144 | * |
||
145 | * @return $this |
||
146 | */ |
||
147 | public function setOptionsLabelAttribute($value) |
||
153 | |||
154 | /** |
||
155 | * 获取 options value 字段 |
||
156 | * |
||
157 | * @return string |
||
158 | */ |
||
159 | public function getOptionsValueAttribute() |
||
163 | |||
164 | /** |
||
165 | * 设置 options value 字段 |
||
166 | * |
||
167 | * @param string $value |
||
168 | * |
||
169 | * @return $this |
||
170 | */ |
||
171 | public function setOptionsValueAttribute($value) |
||
177 | |||
178 | public function toArray() |
||
185 | } |
||
186 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..