修复下拉滚动样式问题
This commit is contained in:
@@ -8,8 +8,8 @@
|
||||
xmSelect.render({
|
||||
//...
|
||||
filterable: true,
|
||||
create: function(val){
|
||||
//返回一个创建成功的对象, val是搜索的数据
|
||||
create: function(val, arr){
|
||||
//返回一个创建成功的对象, val是搜索的数据, arr是搜索后的当前页面数据
|
||||
return {
|
||||
name: '创建-' + val,
|
||||
value: val
|
||||
@@ -26,10 +26,12 @@ xmSelect.render({
|
||||
var demo1 = xmSelect.render({
|
||||
el: '#demo1',
|
||||
filterable: true,
|
||||
create: function(val){
|
||||
return {
|
||||
name: '创建-' + val,
|
||||
value: val
|
||||
create: function(val, arr){
|
||||
if(arr.length === 0){
|
||||
return {
|
||||
name: '创建-' + val,
|
||||
value: val
|
||||
}
|
||||
}
|
||||
},
|
||||
data: [
|
||||
@@ -55,10 +57,12 @@ var demo1 = xmSelect.render({
|
||||
radio: true,
|
||||
clickClose: true,
|
||||
filterable: true,
|
||||
create: function(val){
|
||||
return {
|
||||
name: '创建-' + val,
|
||||
value: val
|
||||
create: function(val, arr){
|
||||
if(arr.length === 0){
|
||||
return {
|
||||
name: '创建-' + val,
|
||||
value: val
|
||||
}
|
||||
}
|
||||
},
|
||||
model: {
|
||||
|
||||
@@ -7,11 +7,8 @@
|
||||
<script>
|
||||
var demo1 = xmSelect.render({
|
||||
el: '#demo1',
|
||||
model: {
|
||||
type: 'relative',
|
||||
},
|
||||
filterable: true,
|
||||
tree: {
|
||||
cascader: {
|
||||
show: true,
|
||||
showFolderIcon: true,
|
||||
showLine: true,
|
||||
|
||||
@@ -79,9 +79,6 @@
|
||||
{name: '自定义', children: [...], click: function(item){
|
||||
alert('自定义的, 想干嘛干嘛');
|
||||
}},
|
||||
|
||||
|
||||
|
||||
```
|
||||
|
||||
|
||||
@@ -150,7 +147,6 @@ model: {
|
||||
> 自定义方式
|
||||
|
||||
```
|
||||
|
||||
list: [ "ALL", "CLEAR",
|
||||
{
|
||||
//显示图标, 可以是layui内置的图标, 也可以是自己引入的图标
|
||||
@@ -165,8 +161,6 @@ list: [ "ALL", "CLEAR",
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
|
||||
```
|
||||
|
||||
### tree
|
||||
|
||||
Reference in New Issue
Block a user