Commit 5b458ecd307dbe41f899048265c612b009b1dc90
1 parent
1c6cde67
优化表格按钮颜色功能;
Showing
1 changed file
with
2 additions
and
2 deletions
src/components/Common/CommonTable/index.js
| @@ -4744,7 +4744,7 @@ class CommonTableRc extends React.Component { | @@ -4744,7 +4744,7 @@ class CommonTableRc extends React.Component { | ||
| 4744 | }} | 4744 | }} |
| 4745 | > | 4745 | > |
| 4746 | {tableBtnsConfig.map(config => { | 4746 | {tableBtnsConfig.map(config => { |
| 4747 | - const { showName, btnBgColor, sDefault: str } = config; | 4747 | + const { showName, btnBgColor, sColor, sDefault: str } = config; |
| 4748 | const disabled = props.getBtnDisabled({ | 4748 | const disabled = props.getBtnDisabled({ |
| 4749 | str, | 4749 | str, |
| 4750 | defaultValue: false, | 4750 | defaultValue: false, |
| @@ -4766,7 +4766,7 @@ class CommonTableRc extends React.Component { | @@ -4766,7 +4766,7 @@ class CommonTableRc extends React.Component { | ||
| 4766 | width: 90, | 4766 | width: 90, |
| 4767 | height: 36, | 4767 | height: 36, |
| 4768 | borderRadius: 5, | 4768 | borderRadius: 5, |
| 4769 | - backgroundColor: disabled ? "#AAA" : btnBgColor, | 4769 | + backgroundColor: disabled ? "#AAA" : (btnBgColor || sColor) , |
| 4770 | color: "#FFF" | 4770 | color: "#FFF" |
| 4771 | }} | 4771 | }} |
| 4772 | loading={bLoading} | 4772 | loading={bLoading} |