固定列和checkbox一起使用
This commit is contained in:
parent
a1d039fc51
commit
6714dbce76
|
@ -19,4 +19,9 @@
|
||||||
|
|
||||||
.selected{
|
.selected{
|
||||||
background: rgb(227,242,253);
|
background: rgb(227,242,253);
|
||||||
|
}
|
||||||
|
|
||||||
|
.demo25{
|
||||||
|
width: 500px;
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
|
@ -114,12 +114,12 @@ class Demo25 extends Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
return <DragColumnTable columns={columns25} data={data25}
|
return <div className="demo25"><DragColumnTable columns={columns25} data={data25}
|
||||||
bordered
|
bordered
|
||||||
dragborder={true}
|
dragborder={true}
|
||||||
scroll={{x:700}}
|
scroll={{x:700}}
|
||||||
multiSelect={{type: "checkbox"}}
|
multiSelect={{type: "checkbox"}}
|
||||||
/>;
|
/></div>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Demo25.defaultProps = defaultProps25;
|
Demo25.defaultProps = defaultProps25;
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -475,8 +475,7 @@ class Table extends Component{
|
||||||
</div>);
|
</div>);
|
||||||
}
|
}
|
||||||
|
|
||||||
getLeftFixedTable() {
|
getLeftFixedTable() {
|
||||||
debugger;
|
|
||||||
return this.getTable({
|
return this.getTable({
|
||||||
columns: this.columnManager.leftColumns(),
|
columns: this.columnManager.leftColumns(),
|
||||||
fixed: 'left',
|
fixed: 'left',
|
||||||
|
|
|
@ -39,7 +39,6 @@ class TableHeader extends Component{
|
||||||
let newItem = item.key != "checkbox"?ObjectAssign(item):item;
|
let newItem = item.key != "checkbox"?ObjectAssign(item):item;
|
||||||
_row.push(newItem);
|
_row.push(newItem);
|
||||||
});
|
});
|
||||||
debugger;
|
|
||||||
this.drag.data = _row;//JSON.parse(JSON.stringify(this.props.rows[0]));
|
this.drag.data = _row;//JSON.parse(JSON.stringify(this.props.rows[0]));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -110,7 +109,7 @@ class TableHeader extends Component{
|
||||||
//"u-table-drag-hide-table"
|
//"u-table-drag-hide-table"
|
||||||
let currentHideDom = document.getElementById("u-table-drag-hide-table-"+dragborderKey).getElementsByTagName("div")[this.drag.currIndex];
|
let currentHideDom = document.getElementById("u-table-drag-hide-table-"+dragborderKey).getElementsByTagName("div")[this.drag.currIndex];
|
||||||
currentHideDom.style.left = (this.drag.initPageLeftX+x-grap)+"px";
|
currentHideDom.style.left = (this.drag.initPageLeftX+x-grap)+"px";
|
||||||
|
|
||||||
//获取最小宽度,不让拖动
|
//获取最小宽度,不让拖动
|
||||||
// let minWidth = 0;
|
// let minWidth = 0;
|
||||||
// for(let i=0;i<=this.drag.currIndex;i++){
|
// for(let i=0;i<=this.drag.currIndex;i++){
|
||||||
|
|
Loading…
Reference in New Issue