Authored by 李奇

次数提示修改

... ... @@ -27,6 +27,7 @@ export default class wheelSurf extends PureComponent {
startType: true,
isLogin: false,
dayLeftTimesTip: '',
conf: {
loading: ''
... ... @@ -109,6 +110,7 @@ export default class wheelSurf extends PureComponent {
conf: result.data.conf,
totalParts: result.data.prize,
remainCount: result.data.residueCount,
dayLeftTimesTip: result.data.conf.btm_tip_one,
startType: result.data.startType !== false,
startErrorMsg: result.data.errorMsg || ''
});
... ... @@ -326,7 +328,11 @@ export default class wheelSurf extends PureComponent {
};
render() {
const {conf, slowEnding, isLogin, startEnded, remainCount} = this.state;
let {conf, slowEnding, isLogin, startEnded, remainCount, dayLeftTimesTip} = this.state;
if (dayLeftTimesTip) {
dayLeftTimesTip = dayLeftTimesTip.replace(/\{\$1\}/ig, remainCount);
}
if (!conf.id) {
return (
... ... @@ -350,7 +356,7 @@ export default class wheelSurf extends PureComponent {
{
isLogin ?
(<div className="tips">
<p className="tip-1">今日剩余次数:{remainCount}</p>
<p className="tip-1">{dayLeftTimesTip}</p>
</div>) : ''
}
... ... @@ -364,7 +370,7 @@ export default class wheelSurf extends PureComponent {
<span onClick={this.setCanStart} className="try-again">确定</span>
</div>
) : ''}
{slowEnding ? (<span onClick={this.setCanStart} className="close-prize-hit-bg">关闭</span>) : ''}
{startEnded ? (<span onClick={this.setCanStart} className="close-prize-hit-bg">关闭</span>) : ''}
{slowEnding ? (<img className="prize-hit-start-bg" src={conf.prize_btn_bg}/>) : ''}
{
this.state.showTipModal ? <TipModal tip={this.state.modalTip} btnText={this.state.modalBtnText} confirm={() => {this.confirm()}} /> : ''
... ...