import React, { Component } from "react"; import styles from "./index.less"; import { normalVal,timestampToTime } from '@utils/tools'; import { InspectCommon, Calendar} from '@commonComp'; import slideUp from "@common/images/slide-up.png"; import slideDown from "@common/images/slide-down.png"; import date1 from '../img/date1.png'; import close from '../img/close.png'; class SlideSelect extends Component { constructor(props) { super(props); this.state = { show:false }; this.toTime = this.toTime.bind(this) this.handleSlide = this.handleSlide.bind(this) } toTime(time){ let tmpTim = time.split(',').join('')-0 if(time && tmpTim.toString() != 'NaN'){ let date = new Date('1900-01-01'); let dateTim = date.getTime(); let times = (tmpTim-2)*24*60*60*1000; let result = timestampToTime(dateTim+times).split(' ')[0] return result; }else{ return time; } } handleSlide(){ let tmpShow = this.state.show this.setState({ show:!tmpShow }) } render() { const {handleConfirm,changeActivePart,handleDelClick,getItemList,date,item,idx,handleFillShow,showDetails,handleLabelSub,showFill,changeShowFill,handlePush,dateTime,currentIdx,currentData,fillActive,handleShowDate,handleChangeDate} = this.props; const {show} = this.state; return (
{ handleLabelSub(e, item.questionId,idx); handleFillShow(e,idx) }}>{item.name}
:{ handleLabelSub(e,item.questionId,idx); handleFillShow(e,idx) }}>{item.name}
} { item.show ?{val.name} | {showDetails(val)}{normalVal(val.minValue,val.maxValue)} | {'化验时间:'+item.time} |
{val.name} | {showDetails(val)}{normalVal(val.minValue,val.maxValue)} | {'化验时间:'+item.time} |
{ dateTime }