Commit de0f741b authored by 满振华's avatar 满振华

修改数据传递

parent e09c80d6
...@@ -309,13 +309,13 @@ export default class DataView extends React.Component { ...@@ -309,13 +309,13 @@ export default class DataView extends React.Component {
const newPage = const newPage =
page.total > 0 page.total > 0
? { ? {
current: page.pageNum, current: page.pageNum,
total: page.total, total: page.total,
} }
: { : {
current: PAGINATION.current, current: PAGINATION.current,
total: PAGINATION.total, total: PAGINATION.total,
}; };
const newData = _.assign({}, data, { origin: list }); const newData = _.assign({}, data, { origin: list });
this.setState({ this.setState({
pagination: _.assign({}, pagination, newPage), pagination: _.assign({}, pagination, newPage),
...@@ -639,10 +639,10 @@ export default class DataView extends React.Component { ...@@ -639,10 +639,10 @@ export default class DataView extends React.Component {
// 渲染顶部tips // 渲染顶部tips
_renderTips() { _renderTips() {
const { tips } = this.props; const { tips, tipsClassName } = this.props;
if (tips) { if (tips) {
return ( return (
<div className={styles.tips}> <div className={`${styles.tips} ${tipsClassName}`}>
{tips} {tips}
{this._renderBtns()} {this._renderBtns()}
</div> </div>
...@@ -674,21 +674,21 @@ export default class DataView extends React.Component { ...@@ -674,21 +674,21 @@ export default class DataView extends React.Component {
{type === 'download' ? ( {type === 'download' ? (
download() download()
) : ( ) : (
<BIButton <BIButton
style={style} style={style}
key={i} key={i}
className={styles.btn} className={styles.btn}
onClick={item.type === 'del' ? this.del.bind(this, label, onClick) : onClick} onClick={item.type === 'del' ? this.del.bind(this, label, onClick) : onClick}
{...antiAssign(item, 'label,onClick,type,iconBtnSrc')} {...antiAssign(item, 'label,onClick,type,iconBtnSrc')}
> >
{iconBtnSrc && iconBtnSrc !== '' ? ( {iconBtnSrc && iconBtnSrc !== '' ? (
<IconFont className={styles.iconCls} type={iconBtnSrc} /> <IconFont className={styles.iconCls} type={iconBtnSrc} />
) : ( ) : (
<IconFont className={styles.iconCls} type="iconxinzeng" /> <IconFont className={styles.iconCls} type="iconxinzeng" />
)} )}
<span className={styles.titleCls}>{label}</span> <span className={styles.titleCls}>{label}</span>
</BIButton> </BIButton>
)} )}
</ButtonAuth> </ButtonAuth>
); );
})} })}
......
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