|
@@ -75,6 +75,18 @@ class SelectTable extends Field
|
|
|
return $this;
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * @param array $options
|
|
|
+ *
|
|
|
+ * @return $this
|
|
|
+ */
|
|
|
+ public function options($options = [])
|
|
|
+ {
|
|
|
+ $this->options = $options;
|
|
|
+
|
|
|
+ return $this;
|
|
|
+ }
|
|
|
+
|
|
|
/**
|
|
|
* 设置选中数据显示.
|
|
|
*
|
|
@@ -95,18 +107,6 @@ class SelectTable extends Field
|
|
|
});
|
|
|
}
|
|
|
|
|
|
- /**
|
|
|
- * 转化为数组格式保存.
|
|
|
- *
|
|
|
- * @param mixed $value
|
|
|
- *
|
|
|
- * @return array|mixed
|
|
|
- */
|
|
|
- public function prepareInputValue($value)
|
|
|
- {
|
|
|
- return Helper::array($value, true);
|
|
|
- }
|
|
|
-
|
|
|
protected function formatOptions()
|
|
|
{
|
|
|
$value = Helper::array(old($this->column, $this->value()));
|