diff --git a/src/components/activity/treasure-box/myTreasure/index.js b/src/components/activity/treasure-box/myTreasure/index.js index 5e1c9da..902f209 100755 --- a/src/components/activity/treasure-box/myTreasure/index.js +++ b/src/components/activity/treasure-box/myTreasure/index.js @@ -357,9 +357,9 @@ class MyTreasure extends Component { handleToInvite = (treasure_code) => { const {history} = this.props if (getParam('version')) { - window.location.assign(`https://h5.julyedu.com/activity/newyear-2019/landing?treasure_code=${treasure_code}&origin=1&version=${getParam('version')}`) + window.location.assign(`https://h5.julyedu.com/activity/treasure-box/landing?treasure_code=${treasure_code}&origin=1&version=${getParam('version')}`) } else { - window.location.assign(`https://h5.julyedu.com/activity/newyear-2019/landing?treasure_code=${treasure_code}&origin=1`) + window.location.assign(`https://h5.julyedu.com/activity/treasure-box/landing?treasure_code=${treasure_code}&origin=1`) } } diff --git a/src/components/activity/treasure-box/myTreasure/prize.js b/src/components/activity/treasure-box/myTreasure/prize.js index f762e65..8c0f0f7 100755 --- a/src/components/activity/treasure-box/myTreasure/prize.js +++ b/src/components/activity/treasure-box/myTreasure/prize.js @@ -86,7 +86,7 @@ export default (props) => { {/* 第三:奖品,任意线上课程兑换券 */} { (!bind_phone && !bind_address && prize_type === 5) && - <a className="team-result">关注公众号“七月在线实验室” 回复“领课” + <a className="team-result">请按上图提示领取奖品 </a> } </> diff --git a/src/components/activity/treasure-box/myTreasure/team.js b/src/components/activity/treasure-box/myTreasure/team.js index ae8d5b1..3070e4c 100755 --- a/src/components/activity/treasure-box/myTreasure/team.js +++ b/src/components/activity/treasure-box/myTreasure/team.js @@ -140,11 +140,11 @@ class TreasureTeam extends Component { { getParam('version') ? is_captain - ? <a className="team-button" href={`https://h5.julyedu.com/activity/newyear-2019/landing?treasure_code=${treasure_code}&origin=1&version=${getParam('version')}`}>继续邀请队友</a> - : <a className="team-button" href={`https://h5.julyedu.com/activity/newyear-2019/landing?treasure_code=${treasure_code}&origin=2&version=${getParam('version')}`}>帮好友完成组队</a> + ? <a className="team-button" href={`https://h5.julyedu.com/activity/treasure-box/landing?treasure_code=${treasure_code}&origin=1&version=${getParam('version')}`}>继续邀请队友</a> + : <a className="team-button" href={`https://h5.julyedu.com/activity/treasure-box/landing?treasure_code=${treasure_code}&origin=2&version=${getParam('version')}`}>帮好友完成组队</a> : is_captain - ? <a className="team-button" href={`https://h5.julyedu.com/activity/newyear-2019/landing?treasure_code=${treasure_code}&origin=1`}>继续邀请队友</a> - : <a className="team-button" href={`https://h5.julyedu.com/activity/newyear-2019/landing?treasure_code=${treasure_code}&origin=2`}>帮好友完成组队</a> + ? <a className="team-button" href={`https://h5.julyedu.com/activity/treasure-box/landing?treasure_code=${treasure_code}&origin=1`}>继续邀请队友</a> + : <a className="team-button" href={`https://h5.julyedu.com/activity/treasure-box/landing?treasure_code=${treasure_code}&origin=2`}>帮好友完成组队</a> } </> } diff --git a/src/components/activity/treasure-box/preheat/YearCourse/index.js b/src/components/activity/treasure-box/preheat/YearCourse/index.js index cbcbafe..67dd079 100755 --- a/src/components/activity/treasure-box/preheat/YearCourse/index.js +++ b/src/components/activity/treasure-box/preheat/YearCourse/index.js @@ -433,9 +433,9 @@ class YearCourse extends Component { } if (isLogin) { if (!getParam('version')) { - this.props.history.push(`/year/yearTreasure${search}`) + this.props.history.push(`/box/yearTreasure${search}`) } else { - this.props.history.push(`/year/yearTreasure${search}?version=${getParam('version')}`) + this.props.history.push(`/box/yearTreasure${search}?version=${getParam('version')}`) } } else { this.toLogin() @@ -608,41 +608,6 @@ class YearCourse extends Component { const { stage,treasureStage } = this.props return ( <div className={'year-index-course'}> - - {/*浮框*/} - {/*{*/} - {/*Number(treasureStage) === 1 &&*/} - {/*<div className='nav-right'>*/} - {/*<span onClick={this.toBoxList} className='nav-right__link'>*/} - {/*未开宝箱*/} - {/*{*/} - {/*removable > 0 &&*/} - {/*<i className="nav-right__number">{removable}</i>*/} - {/*}*/} - {/*</span>*/} - {/*<a onClick={() => this.toYearWish()} className='nav-right__link'>*/} - {/*心愿单*/} - {/*{*/} - {/*sum > 0 &&*/} - {/*<i className="nav-right__number">{sum}</i>*/} - {/*}*/} - {/*</a>*/} - {/*</div>*/} - {/*}*/} - - {/*{*/} - {/*Number(treasureStage) === 0 &&*/} - {/*<div className='nav-right-wish nav-right'>*/} - {/*<a onClick={() => this.toYearWish()} className='nav-right__link'>*/} - {/*心愿单*/} - {/*{*/} - {/*sum > 0 &&*/} - {/*<i className="nav-right__number">{sum}</i>*/} - {/*}*/} - {/*</a>*/} - {/*</div>*/} - {/*}*/} - <div className='nav-right-wish nav-right'> <span onClick={this.toBoxList} className='nav-right__link'>未开宝箱 { @@ -651,976 +616,6 @@ class YearCourse extends Component { } </span> </div> - - - <CommonContainer title='驰援武汉 注册即送' id='year-wuhan'> - <div className="course-box course-conter"> - <div className="course-item"> - <span>注册即送</span> - <a href="/detail?id=224"> - <img - src="http://julyedu-img-public.oss-cn-beijing.aliyuncs.com/Public/Image/75d1c3cef5.png" - alt=""/> - </a> - </div> - <div className="course-item"> - <span>注册即送</span> - <a href="/detail?id=206"> - <img - src="https://julyedu-img-public.oss-cn-beijing.aliyuncs.com/Public/Image/b001fac23f.png" - alt=""/> - </a> - </div> - <div className="course-item"> - <span>注册即送</span> - <a href="/detail?id=230"> - <img - src="https://julyedu-img-public.oss-cn-beijing.aliyuncs.com/Public/Image/d0fb0a479b.png" - alt=""/> - </a> - </div> - </div> - </CommonContainer> - - - {/* 重磅好课 */} - <CommonContainer title='重磅好课限时免费试听' id='year-course'> - { - (bigcourse.course && bigcourse.course.length > 0) && - <> - <div className='bigcourse course-box'> - { - bigcourse.course.map(item => ( - <CourseItem - image={item.image_name} - key={item.course_id} - id={item.course_id} - toCourse={this.toCourse} - > - <div className="coupon-course__footer"> - { - item.is_vip == 1 && - <a className="btn big-course" onClick={() => this.toQQque()}> - 首购¥99起 - </a> - } - - { - item.is_vip == 0 && - <> - { - item.is_buy == 1 && - <a - onClick={() => this.toCourse(item.course_id)} - className="btn to-study" - >开始学习</a> - } - { - item.is_buy == 0 && - <a - onClick={() => this.toQQque()} - className="btn big-course" - >{item.is_audition == 1 ? '免费试听': '抢团报名额'}</a> - } - </> - } - </div> - </CourseItem> - )) - } - </div> - {/* { - (bigcourse.courseList && bigcourse.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore('bigcourse')} - >{bigcourse.isMore ? '查看更多' : '收起'}</button> - } */} - </> - } - </CommonContainer> - - {/* 人气好课免费学 */} - {/*{*/} - {/*Number(stage) !== 3 &&*/} - {/*<CommonContainer title='人气好课免费学' id='year-free'>*/} - {/*<a className='boss__add' href="/active/givecourse?activename=shuangdan">更有42本技术书籍免费送</a>*/} - {/*{*/} - {/*(freecourse.course && freecourse.course.length > 0) &&*/} - {/*<>*/} - {/*<div className='freecourse course-box'>*/} - {/*{*/} - {/*freecourse.course.map(item => (*/} - {/*<CourseItem*/} - {/*image={item.image_name}*/} - {/*key={item.course_id}*/} - {/*id={item.course_id}*/} - {/*toCourse={this.toCourse}*/} - {/*>*/} - {/*<div className="coupon-course__footer">*/} - {/*{*/} - {/*item.is_buy == 1 &&*/} - {/*<a*/} - {/*onClick={() => this.toCourse(item.course_id)}*/} - {/*className="btn to-study"*/} - {/*>开始学习</a>*/} - {/*}*/} - {/*{*/} - {/*item.is_buy == 0 &&*/} - {/*<a*/} - {/*onClick={() => this.freeStudy()}*/} - {/*className="btn free-study"*/} - {/*>点击免费学</a>*/} - {/*}*/} - {/*<p className="free-course-num">*/} - {/*已送出<span>{item.act_num}</span>个课程*/} - {/*</p>*/} - {/*</div>*/} - {/*</CourseItem>*/} - {/*))*/} - {/*}*/} - {/*</div>*/} - {/*{*/} - {/*(freecourse.courseList && freecourse.courseList.length > 4) &&*/} - {/*<button*/} - {/*className="more-button"*/} - {/*onClick={() => this.handleToMore('freecourse')}*/} - {/*>{freecourse.isMore ? '查看更多' : '收起'}</button>*/} - {/*}*/} - {/*</>*/} - {/*}*/} - {/*</CommonContainer>*/} - {/*}*/} - - {/* stage,活动阶段 0-不在活动时间 1-预热 2-正式 3-返场 */} - { - Number(stage) !== 1 && - <> - {/* 精品好课1分开抢 */} - <CommonContainer title='精品好课1分秒' id='year-group'> - { - (groupcourse.course && groupcourse.course.length > 0) && - <> - <div className='groupcourse course-box' data-stage="2"> - { - groupcourse.course.map(item => ( - <CourseItem - image={item.image_name} - key={item.course_id} - id={item.course_id} - time={this.isCountDown(item.is_assemble === 1, item.add_time)} - toCourse={this.toCourse} - > - <div className="coupon-course__footer"> - - {/* is_assemble 0 未拼团 1 正在拼团 2 已购买 */} - { - item.is_assemble == 2 && - <> - <p className={'course-title text-overflow-1'}> - {item.course_title} - </p> - <div className="status"> - <a - onClick={() => this.toCourse(item.course_id)} - className="btn to-group" - data-status="study" - >开始学习</a> - </div> - </> - } - { - item.is_assemble != 2 && - <> - <div className="type"> - <span className="tag" data-color="green">拼团价</span> - </div> - <div className="price price-group"> - <span className="price-label">¥</span> - <span className="new-price">0.01</span> - <span className="old-price"> - <s>¥{item.price1}</s> - </span> - </div> - { - item.is_assemble == 0 && - <div className="progree-and-sale"> - <div className="progress"> - <i - className="progress_bar" - style={{ - width: `${item.progress}%` - }} - ></i> - </div> - <p className="sale-sum"> - {Number(item.sum <= 285) ? `已抢${item.sum}个` : '即将售罄'} - </p> - </div> - } - <div className="status"> - { - item.is_assemble == 0 && - <a - onClick={() => this.toCourse(item.course_id)} - className="status-btn to-group" - >马上抢>></a> - } - { - item.is_assemble == 1 && - <a - onClick={() => this.toInviteFriends(item.order_id, { - number: item.number, - course_title: item.course_title, - image_name: item.image_name, - price: 0.01 - })} - className="status-btn to-group" - data-status="done" - >已参团,邀请好友参团</a> - } - </div> - </> - } - </div> - </CourseItem> - )) - } - </div> - { - (groupcourse.courseList && groupcourse.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore('groupcourse')} - >{groupcourse.isMore ? '查看更多' : '收起'}</button> - } - </> - } - </CommonContainer> - - {/* 好课价到,等你抄底 */} - <CommonContainer title='“薪”年价到,等你抄底!' id='year-discount'> - { - [1, 2, 3, 4].map(item => { - const keys = this.formatTitleAndKey(item); - const data = this.formatCourseData(item); - return ( - <React.Fragment key={item}> - <h4 className="ai-course__subtitle">{keys.title}</h4> - { - (data.course && data.course.length > 0) && - <> - <div className='groupcourse course-box'> - { - data.course.map(val => { - return ( - <CourseItem - image={val.image_name} - key={val.course_id} - id={val.course_id} - time={this.isCountDown(val.type === 2, val.end_time)} - toCourse={this.toCourse} - > - <div className="coupon-course__footer"> - - {/* type 1 立即参团 2 已参团 3 我要砍价 4 已参加砍价 可以继续砍价 5 马上抢 6 开始学习 7 已参加一分钱拼团 8 砍价待支付 */} - - { - (val.type === 4 || val.type === 8) && - <div className="bargain-price">已砍{val.already_bargain}元</div> - } - - { - val.type === 0 && - <> - <div className="type"> - <span className="tag" data-color="green">活动价</span> - </div> - <div className="price price-group"> - <span className="price-label">¥</span> - <span className="new-price">{val.original_price}</span> - <span className="old-price"> - <s>¥{val.price1}</s> - </span> - </div> - </> - } - { - (val.type === 1 || val.type === 2) && - <> - <div className="type"> - <span className="tag" data-color="green">拼团价</span> - </div> - <div className="price price-group"> - <span className="price-label">¥</span> - <span className="new-price">{val.pdd_price}</span> - <span className="old-price"> - <s>¥{val.original_price}</s> - </span> - </div> - </> - } - { - (val.type === 3 || val.type === 4 || val.type === 8) && - <> - <div className="type"> - <span className="tag" data-color="green">好友帮帮砍</span> - </div> - <div className="price price-group"> - <span className="price-label">到手最低:¥</span> - <span className="new-price">{val.low_prize}</span> - <span className="old-price"> - <s>¥{val.original_price}</s> - </span> - </div> - </> - } - { - val.type === 6 && - <p className={'course-title text-overflow-1'}> - {val.course_title} - </p> - } - - <div className="status" data-layout={val.type ===4? 'row': '' }> - { - val.type === 0 && - <a - onClick={() => this.toCart(val.course_id)} - className="status-btn to-group" - >立即购买</a> - } - { - val.type === 1 && - <a - onClick={() => this.toCourse(val.course_id)} - className="status-btn to-group" - >立即参与拼团</a> - } - { - val.type === 2 && - <a - onClick={() => this.toInviteFriends(val.order_id, { - number: val.number, - course_title: val.course_title, - image_name: val.image_name, - price: val.pdd_price - })} - className="status-btn to-group" - data-status="done" - >已参团,邀请好友参团</a> - } - { - val.type === 3 && - <a - onClick={() => this.toCourse(val.course_id)} - className="status-btn to-group" - >我要砍价</a> - } - { - val.type === 4 && - <> - <a - onClick={() => this.toContinueBargain(val.course_id, val.already_bargain, val.bargain_code, val.image_name)} - className="status-btn to-group" - >继续砍价</a> - <a - onClick={() => this.bargainToOrder(val.course_id)} - className="status-btn to-group" - >支付{val.actual_payment}元</a> - </> - } - { - val.type === 8 && - <a - onClick={() => this.bargainToOrder(val.course_id)} - className="status-btn to-group" - >支付{val.actual_payment}元</a> - } - { - val.type === 6 && - <a - onClick={() => this.toCourse(val.course_id)} - className="btn to-group" - data-status="study" - >开始学习</a> - } - </div> - </div> - </CourseItem> - ) - }) - } - </div> - { - (data.courseList && data.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore(keys.key)} - >{data.isMore ? '查看更多' : '收起'}</button> - } - </> - } - </React.Fragment> - ) - }) - } - </CommonContainer> - </> - } - { - Number(stage) === 1 && - <> - {/* 精品好课1分开抢 */} - <CommonContainer title='精品好课1分开抢' id='year-group'> - { - (groupcourse.course && groupcourse.course.length > 0) && - <> - <div className='groupcourse course-box'> - { - groupcourse.course.map(item => ( - <CourseItem - image={item.image_name} - key={item.course_id} - id={item.course_id} - toCourse={this.toCourse} - > - <div className="group-num">限量300个</div> - <div className="coupon-course__footer"> - { - item.is_buy == 1 && - <> - <p className={'course-title text-overflow-1'}> - {item.course_title} - </p> - <a - onClick={() => this.toCourse(item.course_id)} - className="btn to-study" - >开始学习</a> - </> - } - { - item.is_buy == 0 && - <> - <div className="type"> - <span className="tag">拼团价</span> - <span className="time">12月23日开团</span> - </div> - <div className="price"> - ¥ - <span className="new-price">0.01</span> - <span className="old-price"> - 现价:<s>¥{item.price1}</s> - </span> - </div> - <div className="status"> - <a - onClick={() => this.toCourse(item.course_id)} - className="status-btn to-buy" - >直接购买</a> - { - item.is_join == 1 && - <a className="status-btn add-wish"> - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/add-success.png" - alt="" - /> - 已加心愿单 - </a> - } - { - item.is_join == 0 && - <a - onClick={() => this.addWishList(item.course_id, 'group')} - className="status-btn add-wish-success" - > - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/like_icon.png" - alt="" - /> - 加入心愿单 - </a> - } - </div> - </> - } - </div> - </CourseItem> - )) - } - </div> - { - (groupcourse.courseList && groupcourse.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore('groupcourse')} - >{groupcourse.isMore ? '查看更多' : '收起'}</button> - } - </> - } - </CommonContainer> - - {/* 好课价到,等你抄底 */} - <CommonContainer title='好课价到,等你抄底' id='year-discount'> - <h4 className="ai-course__subtitle">基础</h4> - { - (basic.course && basic.course.length > 0) && - <> - <div className='groupcourse course-box'> - { - basic.course.map(item => ( - <CourseItem - image={item.image_name} - key={item.course_id} - id={item.course_id} - toCourse={this.toCourse} - > - <div className="coupon-course__footer"> - { - item.is_buy == 1 && - <> - <p className={'course-title text-overflow-1'}> - {item.course_title} - </p> - <a - onClick={() => this.toCourse(item.course_id)} - className="btn to-study" - >开始学习</a> - </> - } - { - item.is_buy == 0 && - <> - <div className="type"> - { - item.type == 0 && - <> - <span className="tag">活动价</span> - <span className="time">12.23开始</span> - </> - } - { - item.type == 1 && - <> - <span className="tag">拼团价</span> - <span className="time">12.23开团</span> - </> - } - { - item.type == 2 && - <> - <span className="tag">好友帮帮砍</span> - <span className="time">12.23开砍</span> - </> - } - </div> - <div className="price"> - {item.type == 2 ? '到手最低:¥' : '¥'} - <span className="new-price">{item.price2}</span> - <span className="old-price"> - {item.type == 2 ? '' : '现价:'} - <s>¥{item.price1}</s> - </span> - </div> - <div className="status"> - <a - onClick={() => this.toCourse(item.course_id)} - className="status-btn to-buy" - >直接购买</a> - { - item.is_join == 1 && - <a className="status-btn add-wish"> - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/add-success.png" - alt="" - /> - 已加心愿单 - </a> - } - { - item.is_join == 0 && - <a - onClick={() => this.addWishList(item.course_id, '1')} - className="status-btn add-wish-success" - > - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/like_icon.png" - alt="" - /> - 加入心愿单 - </a> - } - </div> - </> - } - </div> - </CourseItem> - )) - } - </div> - { - (basic.courseList && basic.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore('basic')} - >{basic.isMore ? '查看更多' : '收起'}</button> - } - </> - } - <h4 className="ai-course__subtitle">进阶</h4> - { - (advanced.course && advanced.course.length > 0) && - <> - <div className='groupcourse course-box'> - { - advanced.course.map(item => ( - <CourseItem - image={item.image_name} - key={item.course_id} - id={item.course_id} - toCourse={this.toCourse} - > - <div className="coupon-course__footer"> - { - item.is_buy == 1 && - <> - <p className={'course-title text-overflow-1'}> - {item.course_title} - </p> - <a - onClick={() => this.toCourse(item.course_id)} - className="btn to-study" - >开始学习</a> - </> - } - { - item.is_buy == 0 && - <> - <div className="type"> - { - item.type == 0 && - <> - <span className="tag">活动价</span> - <span className="time">12.23开始</span> - </> - } - { - item.type == 1 && - <> - <span className="tag">拼团价</span> - <span className="time">12.23开团</span> - </> - } - { - item.type == 2 && - <> - <span className="tag">好友帮帮砍</span> - <span className="time">12.23开砍</span> - </> - } - </div> - <div className="price"> - {item.type == 2 ? '到手最低:¥' : '¥'} - <span className="new-price">{item.price2}</span> - <span className="old-price"> - {item.type == 2 ? '' : '现价:'} - <s>¥{item.price1}</s> - </span> - </div> - <div className="status"> - <a - onClick={() => this.toCourse(item.course_id)} - className="status-btn to-buy" - >直接购买</a> - { - item.is_join == 1 && - <a className="status-btn add-wish"> - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/add-success.png" - alt="" - /> - 已加心愿单 - </a> - } - { - item.is_join == 0 && - <a - onClick={() => this.addWishList(item.course_id, '2')} - className="status-btn add-wish-success" - > - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/like_icon.png" - alt="" - /> - 加入心愿单 - </a> - } - </div> - </> - } - </div> - </CourseItem> - )) - } - </div> - { - (advanced.courseList && advanced.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore('advanced')} - > - {advanced.isMore ? '查看更多' : '收起'} - </button> - } - </> - } - <h4 className="ai-course__subtitle">高阶</h4> - { - (higher.course && higher.course.length > 0) && - <> - <div className='groupcourse course-box'> - { - higher.course.map(item => ( - <CourseItem - image={item.image_name} - key={item.course_id} - id={item.course_id} - toCourse={this.toCourse} - > - <div className="coupon-course__footer"> - { - item.is_buy == 1 && - <> - <p className={'course-title text-overflow-1'}> - {item.course_title} - </p> - <a - onClick={() => this.toCourse(item.course_id)} - className="btn to-study" - >开始学习</a> - </> - } - { - item.is_buy == 0 && - <> - <div className="type"> - { - item.type == 0 && - <> - <span className="tag">活动价</span> - <span className="time">12.23开始</span> - </> - } - { - item.type == 1 && - <> - <span className="tag">拼团价</span> - <span className="time">12.23开团</span> - </> - } - { - item.type == 2 && - <> - <span className="tag">好友帮帮砍</span> - <span className="time">12.23开砍</span> - </> - } - </div> - <div className="price"> - {item.type == 2 ? '到手最低:¥' : '¥'} - <span className="new-price">{item.price2}</span> - <span className="old-price"> - {item.type == 2 ? '' : '现价:'} - <s>¥{item.price1}</s> - </span> - </div> - <div className="status"> - <a - onClick={() => this.toCourse(item.course_id)} - className="status-btn to-buy" - >直接购买</a> - { - item.is_join == 1 && - <a className="status-btn add-wish"> - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/add-success.png" - alt="" - /> - 已加心愿单 - </a> - } - { - item.is_join == 0 && - <a - onClick={() => this.addWishList(item.course_id, '3')} - className="status-btn add-wish-success" - > - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/like_icon.png" - alt="" - /> - 加入心愿单 - </a> - } - </div> - </> - } - </div> - </CourseItem> - )) - } - </div> - { - (higher.courseList && higher.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore('higher')} - >{higher.isMore ? '查看更多' : '收起'}</button> - } - </> - } - <h4 className="ai-course__subtitle">扩展</h4> - { - (expand.course && expand.course.length > 0) && - <> - <div className='groupcourse course-box'> - { - expand.course.map(item => ( - <CourseItem - image={item.image_name} - key={item.course_id} - id={item.course_id} - toCourse={this.toCourse} - > - <div className="coupon-course__footer"> - { - item.is_buy == 1 && - <> - <p className={'course-title text-overflow-1'}> - {item.course_title} - </p> - <a - onClick={() => this.toCourse(item.course_id)} - className="btn to-study" - >开始学习</a> - </> - } - { - item.is_buy == 0 && - <> - <div className="type"> - { - item.type == 0 && - <> - <span className="tag">活动价</span> - <span className="time">12.23开始</span> - </> - } - { - item.type == 1 && - <> - <span className="tag">拼团价</span> - <span className="time">12.23开团</span> - </> - } - { - item.type == 2 && - <> - <span className="tag">好友帮帮砍</span> - <span className="time">12.23开砍</span> - </> - } - - </div> - <div className="price"> - {item.type == 2 ? '到手最低:¥' : '¥'} - <span className="new-price">{item.price2}</span> - <span className="old-price"> - {item.type == 2 ? '' : '现价:'} - <s>¥{item.price1}</s> - </span> - </div> - <div className="status"> - <a - onClick={() => this.toCourse(item.course_id)} - className="status-btn to-buy" - >直接购买</a> - { - item.is_join == 1 && - <a className="status-btn add-wish"> - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/PC/add-success.png" - alt="" - /> - 已加心愿单 - </a> - } - { - item.is_join == 0 && - <a - onClick={() => this.addWishList(item.course_id, '4')} - className="status-btn add-wish-success" - > - <img - src="https://julyedu-cdn.oss-cn-beijing.aliyuncs.com/newyear20/H5/like_icon.png" - alt="" - /> - 加入心愿单 - </a> - } - </div> - </> - } - </div> - </CourseItem> - )) - } - </div> - { - (expand.courseList && expand.courseList.length > 4) && - <button - className="more-button" - onClick={() => this.handleToMore('expand')} - >{expand.isMore ? '查看更多' : '收起'}</button> - } - </> - } - </CommonContainer> - </> - } - - { - this.state.tofreeStudy && - <CommonPopup top={100} closePopup={this.closePopup} mark={false}> - <div className='sub__code_container'> - <p className='sub__title'>提醒服务</p> - <p className='sub__tip'>进入服务号回复<i>77</i>免费领取课程</p> - <img className='sub__qr_code' id={'live-qr-code'} - src='//julyedu-cdn.oss-cn-beijing.aliyuncs.com/2018christyear/h5/qrcode.jpg' alt="" /> - { - browser.isAndroidApp ? ( - <button className={'save-image'} onClick={this.saveImage2}>保存二维码</button> - ) : <p className='sub__tip'>长按识别/扫码 关注【七月在线】服务号</p> - } - </div> - </CommonPopup> - } - { - this.state.isshowFollow && - <CommonPopup top={100} closePopup={this.closePopupWish} mark={false}> - <div className='sub__code_container'> - <p className='sub__title'>提醒服务</p> - <p className='sub__tip'>课程开售立即提醒,不错过任何优惠哦!</p> - <img className='sub__qr_code' id={'live-qr-code'} - src={this.state.followBarcode} alt="" /> - { - browser.isAndroidApp ? ( - <button className={'save-image'} onClick={this.saveImage}>保存二维码</button> - ) : <p className='sub__tip'>长按识别/扫码 关注【七月在线】服务号</p> - } - </div> - </CommonPopup> - } </div> ) } diff --git a/src/components/activity/treasure-box/preheat/index.js b/src/components/activity/treasure-box/preheat/index.js index b1e6d48..6b59083 100755 --- a/src/components/activity/treasure-box/preheat/index.js +++ b/src/components/activity/treasure-box/preheat/index.js @@ -146,14 +146,14 @@ export default class index extends Component { <div className="banner-treasure"> <div id="banner" className="banner-treasure__header" style={{backgroundImage: `url(${banner})`}}></div> - <div className="banner-treasure__nav"> + {/* <div className="banner-treasure__nav"> <TreasureNav id="banner" treasure_stage={treasure_stage} activeStage={activity_stage}/> - </div> + </div> */} <div className="banner-treasure__decorate"></div> </div> {/* 大咖直播 */} - <LiveRoom isAppUpdate={this.state.isAppUpdate}/> + {/* <LiveRoom isAppUpdate={this.state.isAppUpdate}/> */} {/* 组队开宝箱 */} { @@ -185,7 +185,7 @@ export default class index extends Component { <div className='sub__code_container'> <p className='sub__title'>组队开宝箱活动规则</p> <p className='sub__rule'> - 1. 活动期间(12月18日-12月31日)可随时参与开宝箱;<br/> + 1. 活动期间(3月26日-3月31日)可随时参与开宝箱;<br/> 2. 当前队伍满员后可继续创建新队伍;<br/> 3. 每人有一次机会加入好友的队伍;<br/> 4. 队伍满员后所有成员均可随机获得宝箱内奖品,队长奖励更丰厚哦~<br/> diff --git a/src/components/activity/treasure-box/treasure-box/index.js b/src/components/activity/treasure-box/treasure-box/index.js index b7a0a85..dd2f36e 100755 --- a/src/components/activity/treasure-box/treasure-box/index.js +++ b/src/components/activity/treasure-box/treasure-box/index.js @@ -3,8 +3,8 @@ import { withRouter } from 'react-router-dom'; import CommonContainer from './../common/commonContainer/index'; import TreasureRank from './rank'; import TeamInfo from './team' -import Prizes from "@components/activity/newyear-2019/common/prizes" -import UserBulletScreen from "@components/activity/newyear-2019/common/user-bullet-screen" +import Prizes from "@components/activity/treasure-box/common/prizes" +import UserBulletScreen from "@components/activity/treasure-box/common/user-bullet-screen" class TreasureBox extends Component { constructor(props) { diff --git a/src/components/activity/treasure-box/treasure-box/team.js b/src/components/activity/treasure-box/treasure-box/team.js index 687ff96..00786a7 100755 --- a/src/components/activity/treasure-box/treasure-box/team.js +++ b/src/components/activity/treasure-box/treasure-box/team.js @@ -105,7 +105,7 @@ class TeamInfo extends Component { this.props.history.push('/activity/newyear-2019/landing?origin=1&treasure_code=' + treasure_code); // window.location.assign('https://h5.julyedu.com/activity/newyear-2019/landing?origin=1&treasure_code=' + treasure_code); } else { - window.location.assign('https://h5.julyedu.com/activity/newyear-2019/landing?origin=1&treasure_code=' + treasure_code + '&version='+ getParam('version')); + window.location.assign('https://h5.julyedu.com/activity/treasure-box/landing?origin=1&treasure_code=' + treasure_code + '&version='+ getParam('version')); } }else{ // 没自己的队伍 @@ -115,10 +115,9 @@ class TeamInfo extends Component { if (code === 200) { const { treasure_code } = data; if (!getParam('version')) { - // this.props.history.push('/activity/newyear-2019/landing?origin=1&treasure_code=' + treasure_code); - window.location.assign('https://h5.julyedu.com/activity/newyear-2019/landing?origin=1&treasure_code=' + treasure_code); + window.location.assign('https://h5.julyedu.com/activity/treasure-box/landing?origin=1&treasure_code=' + treasure_code); } else { - window.location.assign('https://h5.julyedu.com/activity/newyear-2019/landing?origin=1&treasure_code=' + treasure_code + '&version='+ getParam('version')); + window.location.assign('https://h5.julyedu.com/activity/treasure-box/landing?origin=1&treasure_code=' + treasure_code + '&version='+ getParam('version')); } } else { Toast.info(msg); diff --git a/src/router/router-config.js b/src/router/router-config.js index 2edd2da..2416f70 100755 --- a/src/router/router-config.js +++ b/src/router/router-config.js @@ -305,30 +305,19 @@ export default [ exact: true, component: loadable(() => import(/*limit-free*/'@/components/limit-free')) }, - - - //拆宝箱 + // 新的开宝箱活动-活动页 { - path: '/activity/treasure/landing', - component: loadable(() => import(/* webpackChunkName: 'newyear-2019-landing'*/ '@components/activity/treasure-box/landing/index')) + path: '/box/boxActive', + component: loadable(() => import(/* webpackChunkName: 'treasure-box' */ '@components/activity/treasure-box/preheat/index')) }, - - // 双旦活动预热页面 - { - path: '/treasureIndex', - component: loadable(() => import(/* webpackChunkName: 'newyear-yearIndex' */ '@components/activity/treasure-box/preheat/index')) - }, - - // 我的宝箱 + // 新的开宝箱活动-我的宝箱 { - path: '/year/yearTreasure', + path: '/box/yearTreasure', component: loadable(() => import(/* webpackChunkName: 'newyear-yearIndex' */ '@components/activity/treasure-box/myTreasure/index')) - } - , - // 双旦心愿单 + }, + // 新的开宝箱活动-扫码、分享页 { - path: '/year/yearWish', - component: loadable(() => import(/* webpackChunkName: 'newyear-yearIndex' */ '@components/activity/treasure-box/year-wish/index')) + path: '/box/landing', + component: loadable(() => import(/* webpackChunkName: 'newyear-2019-landing'*/ '@components/activity/treasure-box/landing/index')) }, - ]