mirror of https://github.com/certd/certd
parent
3dec43d8d4
commit
fe9d443100
|
@ -45,6 +45,9 @@ function install(app: any, options: any = {}) {
|
||||||
},
|
},
|
||||||
conditionalRender: {
|
conditionalRender: {
|
||||||
match(scope) {
|
match(scope) {
|
||||||
|
if (scope.key === "__blank__") {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
//不能用 !scope.value , 否则switch组件设置为关之后就消失了
|
//不能用 !scope.value , 否则switch组件设置为关之后就消失了
|
||||||
const { value, key, props } = scope;
|
const { value, key, props } = scope;
|
||||||
return !value && key != "_index" && value != false;
|
return !value && key != "_index" && value != false;
|
||||||
|
@ -134,6 +137,20 @@ function install(app: any, options: any = {}) {
|
||||||
column: {
|
column: {
|
||||||
order: 1000
|
order: 1000
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
//最后一列空白,用于自动伸缩列宽
|
||||||
|
__blank__: {
|
||||||
|
title: "",
|
||||||
|
type: "text",
|
||||||
|
form: {
|
||||||
|
show: false
|
||||||
|
},
|
||||||
|
column: {
|
||||||
|
order: 99999,
|
||||||
|
width: -1,
|
||||||
|
columnSetShow: false,
|
||||||
|
resizable: false
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -346,10 +363,13 @@ function install(app: any, options: any = {}) {
|
||||||
if (!columnProps.column) {
|
if (!columnProps.column) {
|
||||||
columnProps.column = {};
|
columnProps.column = {};
|
||||||
}
|
}
|
||||||
columnProps.column.resizable = true;
|
if (columnProps.column.resizable == null) {
|
||||||
if (!columnProps.column.width) {
|
columnProps.column.resizable = true;
|
||||||
columnProps.column.width = 100;
|
if (!columnProps.column.width) {
|
||||||
|
columnProps.column.width = 200;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return columnProps;
|
return columnProps;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue