Commit 79b83181 authored by wildfirecode13's avatar wildfirecode13

1

parent c35b73ea
......@@ -5,7 +5,7 @@ export const homeInfo = {
"figures": [
{ "figureId": "1" }, { "figureId": "2" }, { "figureId": "3" }
],
"newUser": false,
"newUser": 0,
"userInfo": null
},
"message": null,
......@@ -28,7 +28,7 @@ export const signInfo = {
"code": null,
"data": {
"continuousDays": 0,
"needPopup": 1,
"needPopup": 0,
"signLists": [
{
"awardName": "欢趣豆",
......@@ -85,13 +85,35 @@ export const signInfo = {
"message": null,
"success": true
}
export const dosign = {
export const pagelist ={
"code": null,
"data": {
"result": true,
"type": "joyBean",
"awardName": "100欢趣豆"
"type": "daPaiCoupons",
"awardName": "大牌券",
"awardPic": "//yun.dui88.com/projectxh5/coupon-250-250.png"
},
"message": null,
"success": true
}
\ No newline at end of file
}
export const dosign ={
"code": null,
"data": {
"result": true,
"type": "daPaiCoupons",
"awardName": "大牌券",
"awardPic": "//yun.dui88.com/projectxh5/coupon-250-250.png"
},
"message": null,
"success": true
}
// export const dosign ={
// "code": null,
// "data": {
// "result": true,
// "type": "joyBean",
// "awardName": "100欢趣豆"
// },
// "message": null,
// "success": true
// }
\ No newline at end of file
......@@ -12,6 +12,7 @@ export default {
[`/projectx/${projectId}/e-family/share.do`]: efamily.doshare,
[`/projectx/${projectId}/e-family/signInfo.do`]: efamily.signInfo,
[`/projectx/${projectId}/e-family/sign.do`]: efamily.dosign,
[`/customActivity/icbcefamily/pageList`]: efamily.pagelist,
},
post: {
[`/projectx/${projectId}/join.do`]: collect_0722.join
......
......@@ -6,6 +6,7 @@ const apiCfg = {
doshare: `/projectx/${projectId}/e-family/share.do`,
signInfo:`/projectx/${projectId}/e-family/signInfo.do`,
dosign:`/projectx/${projectId}/e-family/sign.do`,
pageList:`/customActivity/icbcefamily/pageList`,
}
export default apiCfg;
......@@ -2,22 +2,31 @@
import React, { Component } from 'react';
import resList2 from '../../resconfig/resList2';
import { Aup, AUPOP, AUP_MBX_STATE } from '../../pop';
import { Aup } from '../../pop';
import './prize.less';
class Comprize extends Component {
constructor(props) {
super(props);
this.state = { resList: resList2 };
const {awardName,type,awardPic}=props.data;
this.state = { resList: resList2,
awardName,type,awardPic
};
}
onCloseCustom = () => {
Aup.clear()
}
render() {
const {awardName,type,awardPic}=this.state;
return (
<div className="prize ">
<img className="prize_bg " src={this.state.resList['27d97dbc-4f9f-4f3e-b064-1b6729dd8193'].url} />
<span className="prize_name ">恭喜你连续签到七天 获得e生活2元电子券奖励</span>
<span className="prize_tip ">请前往工银e生活app-我的- 优惠券-电子券中查看</span>
<img className="prize_img " src={this.state.resList['1dd8c28e-73c4-433d-9a49-d8ce3a0ca680'].url} />
<img className="prize_close " onClick={this.props.onClose} src={this.state.resList['b5b823ed-99a2-47fe-9512-1e3db73e8c89'].url} />
<img className="prize_ok " onClick={this.props.onClose} src={this.state.resList['1da83a0f-fa15-43c5-a36f-b696a6628303'].url} />
<span className="prize_name ">恭喜你连续签到七天<br/> 获得{awardName}</span>
{type !='daPaiCoupons' &&<span className="prize_tip ">请前往工银e生活app-我的-<br/>优惠券-电子券中查看</span>}
<img className="prize_img " src={awardPic} />
<img className="prize_close " onClick={this.onCloseCustom} src={this.state.resList['b5b823ed-99a2-47fe-9512-1e3db73e8c89'].url} />
<img className="prize_ok " onClick={this.onCloseCustom} src={this.state.resList['1da83a0f-fa15-43c5-a36f-b696a6628303'].url} />
</div>
);
}
......
......@@ -13,6 +13,7 @@
transform-origin: 0px 0px 0px;
}
.prize_name {
text-align: center;
width: 340px;
height: 78px;
opacity: 1;
......@@ -24,8 +25,9 @@
color: rgba(83, 83, 83, 1);
}
.prize_tip {
width: 298px;
height: 53px;
text-align: center;
// width: 298px;
// height: 53px;
opacity: 1;
left: 226px;
top: 1021px;
......@@ -35,10 +37,10 @@
color: rgba(83, 83, 83, 1);
}
.prize_img {
width: 471px;
width: 237px;
height: 237px;
opacity: 1;
left: 137px;
left: 254px;
top: 622px;
position: absolute;
transform-origin: 0px 0px 0px;
......
......@@ -10,10 +10,11 @@ import API from '../../api';
class Sign extends Component {
constructor(props) {
super(props);
const { todaySigned } = props.data;
const { todaySigned, continuousDays } = props.data;
this.state = {
resList: resList,
todaySigned,
continuousDays
};
}
......@@ -25,10 +26,11 @@ class Sign extends Component {
doSign = () => {
API.dosign().then((res) => {
Aup.show('PrizeRule', {}, this);
const continuousDays = this.state.continuousDays + 1;
this.setState({ todaySigned: true, continuousDays: continuousDays });
this.props.ctx.updateMoney();
if (res.data.type !== 'joyBean')
Aup.show('PrizeRule', res.data, this);
});
};
......
......@@ -4,7 +4,7 @@ import React, { Component } from 'react';
import resList from '../../resconfig/resList'; //import API from '../../api';
import './detail2.less';
import API from '../../api';
class Detail2 extends Component {
constructor(props) {
super(props);
......@@ -13,25 +13,30 @@ class Detail2 extends Component {
};
}
componentDidMount(){
componentDidMount() {
API.pageList({
pageNo:1,
pageSize:20
}).then((res) => {
console.log('pagelist ', res)
})
}
render() {
const arr = [];
for(let i=0; i < 30;i++) {
for (let i = 0; i < 30; i++) {
arr.push(i)
}
return (
<div className="detail2 " uuid="c5abc304-1a0b-4804-956a-d61c1d5b75ed">
<div className="detail2_wrapper" uuid="583667d9-e382-49d8-bfc9-50b6d800c794">
<img
className="detail2_bg"
uuid="2b6c5d97-e458-42a0-b49b-49e9efc6abbc"
src={this.state.resList['9d6135a5-469f-4293-b931-17786c977974'].url}
/>
<img onClick={()=>this.props.navigateTo('mainpage')} className="detail2_back" uuid="detail2_back" src="//yun.duiba.com.cn/spark/assets/805d9455ffa59e37f0f0f19249959c3a9c458f96.png"></img>
<img onClick={() => this.props.navigateTo('mainpage')} className="detail2_back" uuid="detail2_back" src="//yun.duiba.com.cn/spark/assets/805d9455ffa59e37f0f0f19249959c3a9c458f96.png"></img>
<div className="detail2_item_list" uuid="3804f60d-697f-4d68-98b5-ca8cf2e2d3ba">
{
arr.map((i) => (
......
......@@ -40,6 +40,9 @@ class Main3 extends Component {
onClick_shareBtn = () => {
console.log('onClick_shareBtn')
API.doshare().then(res=>{
console.log('doshare',res)
})
}
onClick_rulebtn = () => {
......@@ -53,12 +56,14 @@ class Main3 extends Component {
componentDidMount() {
this.initEvent();
if(!this.props.data.isnewUser) {
if( this.props.data &&!this.props.data.isnewUser) { //不是新用户
API.signInfo().then((res)=>{
const {needPopup} =res.data;
if(needPopup)
Aup.show('Sign', res.data, this);
})
Aup.show('Sign', res.data, this);
});
this.freshHomeInfo();
}
}
initEvent() {
......@@ -71,6 +76,7 @@ class Main3 extends Component {
//首页信息显示更新
freshHomeInfo() {
let homeinfo = dataCenter.getData(Store.homeinfo);
console.log('freshHomeInfo')
}
changeGuideShow() {
let needguide = dataCenter.getData(Store.needguide);
......
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