diff --git a/client/components/ReplenishComponent/ReplenishSkuPage/ReplenishSkuPage.jsx b/client/components/ReplenishComponent/ReplenishSkuPage/ReplenishSkuPage.jsx index 0956a12..e6f765b 100644 --- a/client/components/ReplenishComponent/ReplenishSkuPage/ReplenishSkuPage.jsx +++ b/client/components/ReplenishComponent/ReplenishSkuPage/ReplenishSkuPage.jsx @@ -131,9 +131,11 @@ export default class ReplenishSkuPage extends React.Component{ <div className={"skuInfo"}> <div className={"skuImg"}> <img src={taskList.skuImage || UTILPATH.localImg.defaultImg} alt=""/> + <div className={"skuImgText font20"}>货品图片</div> </div> <div className={"areaImg"}> <img src={taskList.areaImage || UTILPATH.localImg.defaultImg} alt=""/> + <div className={"skuImgText font20"}>摆放方式</div> </div> <div className={"skuPos col333 font30"}> <ul> diff --git a/client/containers/HomePageContainer/HomePageContainer.jsx b/client/containers/HomePageContainer/HomePageContainer.jsx index 7a0ab3f..158e13f 100644 --- a/client/containers/HomePageContainer/HomePageContainer.jsx +++ b/client/containers/HomePageContainer/HomePageContainer.jsx @@ -7,11 +7,30 @@ export default class HomePageContainer extends React.Component{ constructor(props){ super(props); this.state = { + text : '' } } componentWillMount(){ - + let text = ''; + let hour = parseInt(new Date().getHours()); + switch (true){ + case hour >= 0 && hour < 11: + text = '上午好,'; + break; + case hour >= 11 && hour < 13: + text = '中午好,'; + break; + case hour >= 13 && hour < 18: + text = '下午好,'; + break; + case hour >= 18 && hour < 24: + text = '晚上好,'; + break; + } + this.setState({ + text:text + }) } render(){ @@ -37,7 +56,7 @@ export default class HomePageContainer extends React.Component{ taskInfo.area ? <div className={'homeWelcom font30 clo333'} style={{marginTop:marginTop50}}>欢迎来到<span className="homeArea font50 colff775c" style={{padding:`0 ${padding}`}}>{taskInfo.area || ''}</span>区</div> : null } - <div className={"homeText font42"} style={{fontWeight:'800',marginTop:marginTop20}}>下午好, 你辛苦了!</div> + <div className={"homeText font42"} style={{fontWeight:'800',marginTop:marginTop20}}>{this.state.text}你辛苦了!</div> <Button text={'开始工作'} btnContainer={'colfff font30'} style={buttonStyle} option={this.start.bind(this)}/> </div> </div> diff --git a/client/containers/ReplenishContainer/index.css b/client/containers/ReplenishContainer/index.css index f7f32db..ab2400b 100644 --- a/client/containers/ReplenishContainer/index.css +++ b/client/containers/ReplenishContainer/index.css @@ -1,4 +1,5 @@ -/*.replenishContainer{ +/* +.replenishContainer{ position: relative; width: 100%; height: 100%; @@ -36,19 +37,32 @@ } .replenishSkuInfo .skuInfo .skuImg{ width: 200px; - height: 200px; - border: 1px solid #e5e5e5; + height: 260px; + position: relative; + text-align: center; } .replenishSkuInfo .skuInfo .areaImg{ width: 200px; - height: 200px; - border: 1px solid #e5e5e5; + height: 260px; + position: relative; margin: 0 60px 0 60px; + text-align: center; } -.replenishSkuInfo .skuInfo img{ +.replenishSkuInfo .skuInfo .skuImgText{ + position: absolute; + white-space: nowrap; + bottom: 0; width: 100%; - height: 100%; +} + +.replenishSkuInfo .skuInfo img{ + width: 200px; + height: 200px; + border: 1px solid #e5e5e5; + position: absolute; + left: 0; + top: 0; } @@ -67,7 +81,8 @@ } .replenishSkuInfo .skuInfo .skuPos ul>li .showAreaImg{ margin-left: 10px; -}*/ +} +*/ /*---------px rem 分割线-----------*/ @@ -94,7 +109,7 @@ position: relative; left: 50%; -webkit-transform: translateX(-50%); - transform: translateX(-50%); + transform: translateX(-50%); } .replenishSkuInfo .skuName{ text-align: left; @@ -107,18 +122,30 @@ } .replenishSkuInfo .skuInfo .skuImg{ width: 1.6666666666666667rem; - height: 1.6666666666666667rem; - border: 1px solid #e5e5e5; + height: 2.1666666666666665rem; + position: relative; + text-align: center; } .replenishSkuInfo .skuInfo .areaImg{ width: 1.6666666666666667rem; - height: 1.6666666666666667rem; - border: 1px solid #e5e5e5; + height: 2.1666666666666665rem; + position: relative; margin: 0 0.5rem 0 0.5rem; + text-align: center; } -.replenishSkuInfo .skuInfo img{ +.replenishSkuInfo .skuInfo .skuImgText{ + position: absolute; + white-space: nowrap; + bottom: 0; width: 100%; - height: 100%; +} +.replenishSkuInfo .skuInfo img{ + width: 1.6666666666666667rem; + height: 1.6666666666666667rem; + border: 1px solid #e5e5e5; + position: absolute; + left: 0; + top: 0; } .replenishSkuInfo .skuInfo .skuPos{ line-height: 0.38333333333333336rem;