forked from Gitlink/forgeplus-react
hover-issue delete
This commit is contained in:
parent
dbb5efdcd5
commit
b475edae74
|
@ -44,6 +44,7 @@ class OrderItem extends Component {
|
||||||
render() {
|
render() {
|
||||||
const { item , checkbox , mile , user_admin_or_member } = this.props;
|
const { item , checkbox , mile , user_admin_or_member } = this.props;
|
||||||
const { projectsId , owner } = this.props.match.params;
|
const { projectsId , owner } = this.props.match.params;
|
||||||
|
const { orderid , isdisplay } = this.state;
|
||||||
const { current_user } = this.props;
|
const { current_user } = this.props;
|
||||||
return (
|
return (
|
||||||
item &&
|
item &&
|
||||||
|
@ -91,12 +92,21 @@ class OrderItem extends Component {
|
||||||
<Link to={`/${owner}/${projectsId}/issues/${item.id}/detail`}><i className="iconfont icon-pinglun1 mr3 font-16"></i>{item.journals_count}</Link>
|
<Link to={`/${owner}/${projectsId}/issues/${item.id}/detail`}><i className="iconfont icon-pinglun1 mr3 font-16"></i>{item.journals_count}</Link>
|
||||||
{
|
{
|
||||||
user_admin_or_member ?
|
user_admin_or_member ?
|
||||||
<div id="hoverBox" style={{ display: this.state.orderid === item.id && this.state.isdisplay ? 'flex' : 'none' }}>
|
<div style={{ display: orderid === item.id && isdisplay ? 'flex' : 'none' }}>
|
||||||
<div className="mr8 ml8 color-grey-9">
|
<div className="mr8 ml8 color-grey-9">
|
||||||
<Link to={`/${owner}/${projectsId}/issues/${item.id}/updatedetail`} className="color-grey-9"><i className="iconfont icon-bianji3 font-14 mr5"></i></Link>
|
<Link to={`/${owner}/${projectsId}/issues/${item.id}/updatedetail`} className="color-grey-9">
|
||||||
|
<i className="iconfont icon-bianji3 font-14 mr5"></i>
|
||||||
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
<div className="color-grey-9">
|
<div className="color-grey-9">
|
||||||
<Popconfirm placement="bottom" overlayClassName="overlayBox" getPopupContainer={()=>document.getElementById("hoverBox")} title={'您确定要删除当前易修吗?'} okText="是" cancelText="否" onConfirm={() => this.deletedetail(item.id)}>
|
<Popconfirm
|
||||||
|
placement="bottom"
|
||||||
|
overlayClassName={orderid === item.id && isdisplay ? "overlayBox" : "overlayBox hideOverlay" }
|
||||||
|
title={'您确定要删除当前易修吗?'}
|
||||||
|
okText="是"
|
||||||
|
cancelText="否"
|
||||||
|
onConfirm={() => this.deletedetail(item.id)}
|
||||||
|
>
|
||||||
<i className="iconfont icon-yiguanbi1 font-14"></i>
|
<i className="iconfont icon-yiguanbi1 font-14"></i>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -20,6 +20,9 @@
|
||||||
.overlayBox{
|
.overlayBox{
|
||||||
width: 230px;
|
width: 230px;
|
||||||
}
|
}
|
||||||
|
.hideOverlay{
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
.topmilepost {
|
.topmilepost {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
Loading…
Reference in New Issue