From 367cbea7359502f6df24b010dae7bea1da3182eb Mon Sep 17 00:00:00 2001 From: cxz66666 <1092889706@qq.com> Date: Fri, 18 Sep 2020 20:26:48 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=A8=E6=B2=A1=E7=A9=BA=E7=9A=84=E8=81=94?= =?UTF-8?q?=E7=B3=BB=E4=BA=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/ChooseTime.js | 90 ++++++++++++++++++++++-------------- 1 file changed, 55 insertions(+), 35 deletions(-) diff --git a/src/components/ChooseTime.js b/src/components/ChooseTime.js index 2ef1bb2..614de2f 100644 --- a/src/components/ChooseTime.js +++ b/src/components/ChooseTime.js @@ -1,6 +1,17 @@ import React from "react"; import axios from "axios"; -import {Button,Form,Spin,message,Checkbox,Alert,BackTop,Layout,Card,List} from "antd"; +import { + Button, + Form, + Spin, + message, + Checkbox, + Alert, + BackTop, + Layout, + Card, + List, +} from "antd"; import "antd/dist/antd.css"; import { confirmAlert } from "react-confirm-alert"; import "react-confirm-alert/src/react-confirm-alert.css"; @@ -127,8 +138,11 @@ class TimePicker extends React.Component { this.setState({ info: result.data.data, }); - if(this.state.info.times.length !== 0){ - message.warning("你已选择过面试时间!重复提交面试时间可能导致场次排错,请谨慎重复提交!",0) + if (this.state.info.times.length !== 0) { + message.warning( + "你已选择过面试时间!重复提交面试时间可能导致场次排错,请谨慎重复提交!", + 0 + ); } } else { message.error("获取个人信息失败,请稍后重试"); @@ -147,7 +161,6 @@ class TimePicker extends React.Component { }, }; - const { getFieldDecorator } = this.props.form; if (this.state.confirmed) { return this.state.option_list ? ( @@ -309,50 +322,52 @@ class TimePicker extends React.Component { ); - } else if(this.state.info){ - return( this.state.info.times.length !== 0 ? + } else if (this.state.info) { + return this.state.info.times.length !== 0 ? ( -

重复提交面试时间可能导致场次排错,请谨慎重复提交,点击右上角关闭警告以继续

+
+

+ 重复提交面试时间可能导致场次排错,请谨慎重复提交,点击右上角关闭警告以继续 +

已选择的时间
} bordered dataSource={this.state.info.times} - renderItem={item => {item}} + renderItem={(item) => {item}} /> - } + } type="warning" showIcon closable - style={{ height: "700px", textAlign: "center"}} - afterClose = {()=>{ - const info = Object.assign({},this.state.info,{times: []}); - this.setState({info:info}) - } - } - />: + style={{ height: "700px", textAlign: "center" }} + afterClose={() => { + const info = Object.assign({}, this.state.info, { times: [] }); + this.setState({ info: info }); + }} + /> + ) : (
- - -

{this.state.info.name}

-
- -

{this.state.info.id_student}

-
- -

{this.state.info.firstWish}

-
- -

{this.state.info.secondWish}

-
- -

{this.state.info.thirdWish}

-
+ + +

{this.state.info.name}

+ +

{this.state.info.id_student}

+
+ +

{this.state.info.firstWish}

+
+ +

{this.state.info.secondWish}

+
+ +

{this.state.info.thirdWish}

+
+


- )}else{ - return( + ); + } else { + return (
浙江大学学生E志者协会2020年面试时间 +

+ 如果下列时间全部没空,请联系林同学:电话18768081099 + ,或加入qq纳新咨询群:1126888868 +