From a8e252f41e9017fa65879d589f97eb89cfc57196 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Fri, 12 Jul 2019 16:06:25 +0800 Subject: [PATCH] b --- .../PackageIndexNEIBannerConcent.js | 86 ++++++++++++------- .../PackageIndexNEISubmit.js | 2 +- .../PackageIndexNewandEditIndex.js | 9 +- 3 files changed, 61 insertions(+), 36 deletions(-) diff --git a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js index e42606e2..24ed3724 100644 --- a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js +++ b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEIBannerConcent.js @@ -144,22 +144,23 @@ class PackageIndexNEIBannerConcent extends Component { content: content, attachment_ids: attachment_ids, deadline_at:deadline_at._i, - min_price:parseInt(min_price).toFixed(2), - max_price:parseInt(max_price).toFixed(2), + min_price:min_price, + max_price:max_price, contact_name: contact_name, contact_phone: contact_phone, code:code, publish:types } ).then((response) => { - debugger + if(response.data.status===0){ + this.props.setPublicationfun(response.data.id) + } }).catch((error) => { console.log(error) }) - this.props.setPublicationfun() } modalCancel=()=>{ @@ -221,7 +222,7 @@ class PackageIndexNEIBannerConcent extends Component { } render() { - let {modalCancel,seconds,getverificationcodes, + let {modalCancel,seconds,getverificationcodes,attachments_url, category,title}=this.state; let categorylist=[ {name:"前端开发",value:"front"}, @@ -269,31 +270,52 @@ class PackageIndexNEIBannerConcent extends Component { {/* 请求status 422 */} -
- - - - { - debugger; - console.log(window.$('.file_selector')[0]) - window.addInputFiles(window.$('.file_selector')[0]) - }} - style={{'display': 'none'}} type="file"> - - + {/**/} + {/**/} + {/**/} + {/**/} + {/* {*/} + {/*debugger;*/} + {/*console.log(window.$('.file_selector')[0])*/} + {/*window.addInputFiles(window.$('.file_selector')[0])*/} + {/*}}*/} + {/*style={{'display': 'none'}} type="file">*/} + {/**/} + {/**/} + {/*
*/} + +
+ + { attachments_url && !!attachments_url.length && + this.renderAttachment() + } + + + {debugger;window.addInputFiles( window.$('.file_selector')[0] ) }} + style={{'display':'none'}} type="file"> + +
@@ -364,7 +386,7 @@ class PackageIndexNEIBannerConcent extends Component { onInput={this.onChangeContact_name} />

-

+ {modalCancel===false?

手机号: this.editmodels()}> -

+

:""} {modalCancel===true?

diff --git a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEISubmit.js b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEISubmit.js index 2113df48..dc702068 100644 --- a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEISubmit.js +++ b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNEISubmit.js @@ -34,7 +34,7 @@ class PackageIndexNEISubmit extends Component {

提交成功
平台正在审核您的申请,审核结果将以平台消息的形式通知您
- this.setageload(1)}>查看发布需求 + this.setageload(this.props.id)}>查看发布需求
diff --git a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNewandEditIndex.js b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNewandEditIndex.js index f36ae4d6..2e66bf7d 100644 --- a/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNewandEditIndex.js +++ b/public/react/src/modules/projectPackages/PackageIndexNewandEdit/PackageIndexNewandEditIndex.js @@ -12,16 +12,18 @@ class PackageIndexNewandEditIndex extends Component{ constructor(props) { super(props) this.state = { - setPublication:false + setPublication:false, + id:undefined } } componentDidMount(){ console.log(this.props) } - setPublicationfun=()=>{ + setPublicationfun=(ids)=>{ this.setState({ - setPublication:true + setPublication:true, + id:ids }) } render() { @@ -46,6 +48,7 @@ class PackageIndexNewandEditIndex extends Component{
}