mirror of
https://github.com/YMFE/yapi.git
synced 2025-01-30 13:20:24 +08:00
opti: Errmsg组件
This commit is contained in:
parent
42afd5a23f
commit
d2e2c486a4
@ -37,17 +37,19 @@ class ErrMsg extends Component {
|
||||
|
||||
render () {
|
||||
let { type, title, desc, opration } = this.props;
|
||||
switch (type) {
|
||||
case 'noProject':
|
||||
title = '该分组还没有项目呢';
|
||||
desc = <span>请点击右上角 “<Icon type="plus-circle" />” 按钮新建项目</span>;
|
||||
break;
|
||||
case 'noData':
|
||||
title = '暂无数据';
|
||||
desc = '先去别处逛逛吧';
|
||||
break;
|
||||
default:
|
||||
console.log('default');
|
||||
if (type) {
|
||||
switch (type) {
|
||||
case 'noProject':
|
||||
title = '该分组还没有项目呢';
|
||||
desc = <span>请点击右上角 “<Icon type="plus-circle" />” 按钮新建项目</span>;
|
||||
break;
|
||||
case 'noData':
|
||||
title = '暂无数据';
|
||||
desc = '先去别处逛逛吧';
|
||||
break;
|
||||
default:
|
||||
console.log('default');
|
||||
}
|
||||
}
|
||||
return (
|
||||
<div className="err-msg">
|
||||
|
Loading…
Reference in New Issue
Block a user