Commit fcdce906 authored by chenshouchao's avatar chenshouchao

fix: 解决组件迁移造成的报错

parent 71901d71
......@@ -11681,7 +11681,7 @@
},
"webpack-dev-server": {
"version": "4.9.0",
"resolved": "https://registry.npmmirror.com/webpack-dev-server/-/webpack-dev-server-4.9.0.tgz",
"resolved": "https://registry.npmjs.org/webpack-dev-server/-/webpack-dev-server-4.9.0.tgz",
"integrity": "sha512-+Nlb39iQSOSsFv0lWUuUTim3jDQO8nhK3E68f//J2r5rIcp4lULHXz2oZ0UVdEeWXEh5lSzYUlzarZhDAeAVQw==",
"requires": {
"@types/bonjour": "^3.5.9",
......
......@@ -165,7 +165,7 @@ export default function EnhancedTable(props) {
style={{ width: CellWidth, textAlign: item.numeric ? "right" : "left", paddingRight: item.sort && item.numeric ? "40px" : "", boxSizing: "border-box" }}
scope="row"
rowSpan={(row[item.id] === 'merge') ? (rows.length - (index)) : 1}
padding={item.disablePadding ? "none" : "default"}
padding={item.disablePadding ? "none" : "normal"}
classes={{
body: bodyTableCellStyle || classes.bodyTableCell,
}}
......
......@@ -97,7 +97,7 @@ export default function EnhancedTable(props) {
<TableContainer style={{ ...tableContainerStyle }}>
<Table stickyHeader={stickyheader || false} className={classes.table} style={{ ...tableStyle }} aria-labelledby="tableTitle" size={size || "medium"} aria-label="cloudam table header" >
<EnhancedTableHeadComponent
classes={classes}
classes={classes()}
{...props}
numSelected={selected.length}
headTableCellCheckbox={headTableCellCheckbox}
......@@ -143,7 +143,7 @@ export default function EnhancedTable(props) {
role="checkbox"
aria-checked={isItemSelected}
tabIndex={-1}
key={row[param || "id"]}
key={row[param || "id"] || index}
selected={isItemSelected}
>
{
......@@ -158,7 +158,7 @@ export default function EnhancedTable(props) {
// align={}
style={{ width:CellWidth, textAlign: item.numeric ? "right" : "left", paddingRight: item.sort && item.numeric ? "40px" : "",border:tablecellstyle }}
scope="row"
padding={item.disablePadding ? "none" : "default"}
padding={item.disablePadding ? "none" : "normal"}
classes={{
body: props.bodyTableCell || classes.bodyTableCell
}}
......
......@@ -40,7 +40,7 @@ const EnhancedTableHead = (props) => {
<TableCell
key={headCell.id}
style={{ width: headCell.width ? headCell.width : "", textAlign: headCell.numeric ? "right" : "left", display: headCell.id !== "checkbox" ? "" : "none" }}
padding={headCell.disablePadding ? "none" : "default"}
padding={headCell.disablePadding ? "none" : "normal"}
sortDirection={orderBy === headCell.id ? order : false}
classes={{ head:( k && headTableCell) || classes.headTableCell }}
>
......
......@@ -248,7 +248,7 @@ export default function EnhancedTable(props) {
key={k} component="th" id={labelId + k}
style={{ width:item.width || '',maxWidth:item.width || '',textAlign: item.numeric ? "right" : "left", paddingRight: item.sort && item.numeric ? "40px" : "", boxSizing: "border-box", display: item.id !== "checkbox" ? "" : "none" }}
scope="row"
padding={item.disablePadding ? "none" : "default"}
padding={item.disablePadding ? "none" : "normal"}
classes={{ body: props.bodyTableCell || classes.bodyTableCell }}
> {row[item.id]} </TableCell>
)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment