Commit 96770aee by FE

pull

parent 42fa021b
......@@ -53,7 +53,7 @@ class FollowQRcode extends Component {
<p className="tip">长按二维码保存到相册</p>
</div>
<div className='close'>
<i className='iconfont iconiconfront-2'></i>
<i className='iconfont iconiconfront-2' onClick={this.props.toClose}></i>
</div>
</div>
</div>
......
.followQRcode-box {
position: fixed;
top: 0;
left: 0;
bottom: 0;
right: 0;
background: rgba(0, 0, 0, .6);
z-index: 1;
// position: fixed;
// top: 0;
// left: 0;
// bottom: 0;
// right: 0;
// background: rgba(0, 0, 0, .6);
// z-index: 1;
.followQRcode {
width: 290px;
......
......@@ -8,6 +8,7 @@ import { http, getParam, validateTel } from "@/utils";
import { Formik, withFormik, Form, Field } from 'formik';
import { Toast } from 'antd-mobile';
import Captcha from '@/common/Captcha';
import FollowQRcode from './../followQRcode';
import './index.scss';
class RedPacket extends PureComponent {
......@@ -104,6 +105,18 @@ class RedPacket extends PureComponent {
});
}
// 提示关注公众号
openTip = () => {
const { shareInfo } = this.state;
// is_follow 是否关注公众号,0否,1是
if(!shareInfo.is_follow) {
this.setState({
type: 11
});
}
}
handleToOpen = () => {
const { history } = this.props;
const { shareInfo: { share_code='' } } = this.state;
......@@ -462,6 +475,7 @@ class RedPacket extends PureComponent {
// const isClick =
return (
<>
<div className="red-packet">
<p className="red-packet__title">分享课程给好友,你和好友都可以领红包哦〜</p>
<button className="red-packet__button" onClick={this.handleToShare}>分享领红包</button>
......@@ -566,6 +580,7 @@ class RedPacket extends PureComponent {
handleToClose={() => {
const isShare = getParam('share_code')? true : false;
this.handleToClose(false, isShare);
this.openTip();
}}
/>
}
......@@ -588,6 +603,7 @@ class RedPacket extends PureComponent {
handleToClose={() => {
const isShare = getParam('share_code')? true : false;
this.handleToClose(false, isShare);
this.openTip();
}}
/>
}
......@@ -827,6 +843,12 @@ class RedPacket extends PureComponent {
/>
</div>
}
{/* 关注公众号 */}
{
type === 11 &&
<FollowQRcode toClose={() => this.handleToClose(false)} />
}
</div>
}
</>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment