|
|
|
@ -42,7 +42,6 @@ class MilepostDetail extends Component{
|
|
|
|
|
//设置选择高亮
|
|
|
|
|
openselect:1,
|
|
|
|
|
closeselect:undefined,
|
|
|
|
|
miledata:undefined,
|
|
|
|
|
// status_type: undefined
|
|
|
|
|
issue_tag_ids:'标签',
|
|
|
|
|
tracker_ids:'所有分类',
|
|
|
|
@ -57,36 +56,8 @@ class MilepostDetail extends Component{
|
|
|
|
|
componentDidMount=()=>{
|
|
|
|
|
this.getSelectList();
|
|
|
|
|
this.getIssueList();
|
|
|
|
|
this.getmeil();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
getmeil=()=>{
|
|
|
|
|
const { projectsId } = this.props.match.params;
|
|
|
|
|
const { meilid } = this.props.match.params;
|
|
|
|
|
const url = `/projects/${projectsId}/versions/${meilid}/edit.json`;
|
|
|
|
|
axios.get(url,{
|
|
|
|
|
params:{
|
|
|
|
|
projectsId,meilid
|
|
|
|
|
}
|
|
|
|
|
}).then((result)=>{
|
|
|
|
|
if(result){
|
|
|
|
|
this.setState({
|
|
|
|
|
miledata:result.data,
|
|
|
|
|
|
|
|
|
|
})
|
|
|
|
|
this.props.form.setFieldsValue({
|
|
|
|
|
name:result.data.name,
|
|
|
|
|
description:result.data.description
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}).catch((error)=>{
|
|
|
|
|
console.log(error);
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
getSelectList=()=>{
|
|
|
|
|
const { projectsId } = this.props.match.params;
|
|
|
|
@ -104,12 +75,12 @@ class MilepostDetail extends Component{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 获取列表数据
|
|
|
|
|
getIssueList=(page,limit,search,author_id,assigned_to_id,id,value,status_type)=>{
|
|
|
|
|
getIssueList=(page,limit,search,author_id,assigned_to_id,id,value,status_type,order_name, order_type)=>{
|
|
|
|
|
const { projectsId,meilid} = this.props.match.params;
|
|
|
|
|
const url = `/projects/${projectsId}/versions/${meilid}.json`;
|
|
|
|
|
axios.get(url,{
|
|
|
|
|
params:{
|
|
|
|
|
page,limit,search,author_id,assigned_to_id,status_type,
|
|
|
|
|
page,limit,search,author_id,assigned_to_id,status_type,order_name, order_type,
|
|
|
|
|
[id]:value
|
|
|
|
|
}
|
|
|
|
|
}).then((result)=>{
|
|
|
|
@ -190,15 +161,16 @@ class MilepostDetail extends Component{
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
this.setState({
|
|
|
|
|
[id]:e.key
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const { page,limit,search,author_id,assigned_to_id } = this.state;
|
|
|
|
|
if(e.key==="all"){
|
|
|
|
|
this.getIssueList(page,limit,search,author_id,assigned_to_id,id);
|
|
|
|
|
}else{
|
|
|
|
|
this.getIssueList(page,limit,search,author_id,assigned_to_id,id,e.key);
|
|
|
|
|
this.getIssueList(page,limit,search,author_id,assigned_to_id,id,undefined,undefined,e.key, e.item.props.value);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -265,7 +237,7 @@ class MilepostDetail extends Component{
|
|
|
|
|
|
|
|
|
|
render(){
|
|
|
|
|
|
|
|
|
|
const { issue_chosen , issues , limit , page , search_count , data , miledata , isSpin,openselect,closeselect } = this.state;
|
|
|
|
|
const { issue_chosen , issues , limit , page , search_count , data , isSpin,openselect,closeselect } = this.state;
|
|
|
|
|
const { projectsId,meilid } = this.props.match.params;
|
|
|
|
|
|
|
|
|
|
const menu = (
|
|
|
|
@ -289,13 +261,24 @@ class MilepostDetail extends Component{
|
|
|
|
|
)
|
|
|
|
|
return(
|
|
|
|
|
<div className="main">
|
|
|
|
|
<div className="topWrapper">
|
|
|
|
|
<p>{miledata&&miledata.name}</p>
|
|
|
|
|
<div className="miledetail">
|
|
|
|
|
<div className="topmilepost">
|
|
|
|
|
<p>{data&&data.name}</p>
|
|
|
|
|
<div className="milepostdiv">
|
|
|
|
|
<Link to={`/projects/${projectsId}/orders/${meilid}/meilpost`} className="topWrapper_btn" style={{marginRight:15}} >编辑里程碑</Link>
|
|
|
|
|
<Link to={`/projects/${projectsId}/orders/new`} className="topWrapper_btn">创建工单</Link>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div className="grid-item mr10">
|
|
|
|
|
<i className="iconfont icon-rili font-14 mr5">
|
|
|
|
|
</i>
|
|
|
|
|
{
|
|
|
|
|
data&&data.effective_date ?
|
|
|
|
|
<span >{data&&data.effective_date} {data&&data.percent.toFixed(2)}%完成</span>
|
|
|
|
|
:
|
|
|
|
|
<span >暂无截止时间 {data&&data.percent.toFixed(2)}%完成</span>
|
|
|
|
|
}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="topWrapper" style={{borderBottom:"none"}}>
|
|
|
|
|
{/* <p className="topWrapper_type">
|
|
|
|
|