mirror of https://gitee.com/karson/fastadmin.git
CRUD复选框模板强制类型转换
parent
037570a866
commit
aee632be9d
|
|
@ -2,7 +2,7 @@
|
|||
public function {%methodName%}($value, $data)
|
||||
{
|
||||
$value = $value ?: ($data['{%field%}'] ?? '');
|
||||
$valueArr = explode(',', $value);
|
||||
$valueArr = explode(',', (string) $value);
|
||||
$list = $this->{%listMethodName%}();
|
||||
return implode(',', array_intersect_key($list, array_flip($valueArr)));
|
||||
}
|
||||
Loading…
Reference in New Issue