新建标签

This commit is contained in:
caishi 2021-02-23 11:00:05 +08:00
parent b8476cec1a
commit ad3c9f837f
1 changed files with 19 additions and 18 deletions

View File

@ -46,7 +46,7 @@ class NewTags extends Component {
description: "",
id: "",
modelname: "",
isSpin: false,
isSpin: true,
};
}
componentDidUpdate=(prevPros)=>{
@ -60,6 +60,9 @@ class NewTags extends Component {
};
getList = (page, order_name, order_type) => {
this.setState({
isSpin:true
})
const { projectsId , owner } = this.props.match.params;
const { limit } = this.state;
const url = `/${owner}/${projectsId}/labels.json`;
@ -76,6 +79,7 @@ class NewTags extends Component {
if (result) {
this.setState({
data: result.data,
isSpin:false
});
}
})
@ -247,7 +251,6 @@ class NewTags extends Component {
render() {
const { data, limit, page, isSpin } = this.state;
const { projectsId } = this.props.match.params;
const { getFieldDecorator } = this.props.form;
const menu = (
@ -409,8 +412,8 @@ class NewTags extends Component {
</div>
</div>
);
} else {
return <NoneData _html="暂时还没有相关数据!" />;
} else if(data && data.issue_tags && data.issue_tags.length === 0) {
return <NoneData _html="暂时还没有相关数据!" />
}
};
@ -473,25 +476,23 @@ class NewTags extends Component {
) : null}
</div>
<div className="fr" style={{ marginTop: 5 }}>
<Spin spinning={isSpin}>
<Button
type="primary"
onClick={this.createtagpost}
className="fr"
>
创建标签
</Button>
{/* <a onClick={this.createtagpost} className="topWrapper_btn fr" >创建标签</a> */}
<a onClick={this.newclose} className="a_btn cancel_btn fr">
取消
</a>
</Spin>
<Button
type="primary"
onClick={this.createtagpost}
className="fr"
>
创建标签
</Button>
{/* <a onClick={this.createtagpost} className="topWrapper_btn fr" >创建标签</a> */}
<a onClick={this.newclose} className="a_btn cancel_btn fr">
取消
</a>
</div>
</div>
</Form>
</div>
<div className="padding20-30">
{renderList()}
<Spin spinning={isSpin}><div style={{minHeight:"350px"}}>{renderList()}</div></Spin>
{Paginations}
</div>
</div>