When valueField/textField are not explicitly set in opts, the auto-select logic (line 1140) and nullable empty-option creation (lines 1144-1145) used data[0][undefined] which returned undefined, causing: - Single-option selects to show blank (auto-select failed) - nullable empty options to have undefined keys Now extracts vf/tf local variables with ||'value'/||'text' fallback at the top of build_options(), used consistently throughout.
28 lines
615 B
Markdown
28 lines
615 B
Markdown
# Tabular
|
||
数据驱动的表格状数据展示控件,每行显示一条数据
|
||
|
||
## widgettype值
|
||
Tabular
|
||
|
||
## 父类
|
||
bricks.DynamicAccordion
|
||
|
||
## 构建参数
|
||
|
||
## 方法
|
||
### render
|
||
语法:
|
||
render(params)
|
||
#### params 参数
|
||
字典类型,以k,v形式提供获参数,提供Tabular获取后台数据的条件
|
||
|
||
## 事件
|
||
### toolbar中定义的事件
|
||
工具条上的工具在点击时, Tabular会触发所点击tool的name事件
|
||
### 编辑事件
|
||
当Tabular设置可编辑时,toolbar中会添加add, update, delete三个工具,点击后会触发相应的add, update和delete事件
|
||
|
||
## 使用例子
|
||
```
|
||
```
|