Commit 6688c270 authored by 王勇霞's avatar 王勇霞

feat: 虚拟盘调整

parent 56481042
......@@ -5,39 +5,4 @@
## 线上测试投放链接 线上测试项目:b区pf909ff04
1. 华夏理财
https://90548-activity.dexfu.cn/projectx/pf909ff04/auth.html?appID=90548&channel=1
2. 华夏银行
https://90548-activity.dexfu.cn/customShare/share?id=Did1NjE3MzU&projectId=pf909ff04&channel=2
## 线上正式投放链接 生产项目:x区 p927bc4a1
1. 渠道1-华夏理财(有免登,客户id):https://90548-activity.dexfu.cn/projectx/p927bc4a1/auth.html?appID=90548&channel=1
2. 渠道2-华夏银行(有免登,手机号、客户号):https://90548-activity.dexfu.cn/customShare/share?id=Did1NjE3MzU&channel=2
3. 渠道3-河北银行(无免登,app投放):https://90548-activity.dexfu.cn/projectx/p927bc4a1/index.html?appID=90548&channel=3
4. 渠道4-中原银行(无免登,app投放):https://90548-activity.dexfu.cn/projectx/p927bc4a1/index.html?appID=90548&channel=4
5. 渠道5-昆仑银行(无免登,app投放):https://90548-activity.dexfu.cn/projectx/p927bc4a1/index.html?appID=90548&channel=5
@后端
1.绑定手机号弹窗 需要展示当前渠道的协议标题和内容 哪个接口返回? -- 新加了接口
2.活动结束后 微信端扫码 绑定手机号时 拿不到uid origenUid怎么传? -- 只有华夏理财才必传
3.home/isWhiteUser.do 重定向地址不需要前端传吗? -- 后端写死
4.home/coop_checkCode.do 不需要加密吗?重定向地址不需要前端传吗? -- 不加密 后端写死
5.首页接口 home/index.do
5.1 codeList 返回的是需要查询的code么?已经查过的还会返回吗?需要返回产品类型 -- 已经查过的不会返回
5.2 缺少字段:活动结束通知弹窗是否展示 -- 补了
5.3 金额的相关字段 单位是分还是元? --分 签到那边是元
5.4 缺少字段:今日是否已签到、最高可得xx万资金、checkInConfig每个item的id和是否已领奖 -- 补了
5.5 缺少字段:底部产品列表、我的持仓列表 -- 补了
......@@ -4,7 +4,7 @@ export default [
{
url: '/projectRule.query',
method: 'get',
response: ({ query }) => {
response: () => {
return {
"data": "<p>以下是游戏规则:手速要快,点击红包雨。。333。。。。。。。。。。。。。。。。。。。。11111111111111sadasdadadsad5555555557777777777799999999999911111111111111111111111222222222222222222222222222222222222222222222222222222222222222333333333333333333333333333333333333333333333333333333333333311111111111111111111111111111111111111111111111111111111111111122222222222222222222222222222222222222222222222222222222222222233333333333333333333333333333333333333333333333333333333333331111111111111111111111111111111111111111111111111111111111111112222222222222222222222222222222222222222222222222222222222222223333333333333333333333333333333333333333333333333333333333333</p>",
"success": true
......@@ -14,13 +14,13 @@ export default [
{
url: '/coop_frontVariable.query',
method: 'get',
response: ({ query }) => {
response: () => {
return {
"success": true,
"message": "报错了~",
"code": null,
"data": {
virtualProjectId: 'p9ec985d9',
actualProjectId: 'p9ec985d9',
shareInfo: JSON.stringify({
"title": "万亿体验金狂欢节",
"content": "快来助我一臂之力,一起领百万理财体验金~",
......@@ -32,7 +32,7 @@ export default [
},
{
url: '/join.do',
response: ({ query }) => {
response: () => {
return {
"code": "code",
"success": true,
......@@ -46,7 +46,7 @@ export default [
},
},
{
url: '/real/prizeRecords.do',
url: '/virtual/prizeRecords.do',
response: () => {
return {
"code": "code",
......
export default [
{
url: '/home/isWhiteUser.do',
response: ({ query }) => {
return {
success: true,
code: "60002",
// code: "60001",
// code: "100001",
message: "",
timeStamp: Date.now(),
data: null
}
},
},
{
url: '/home/coop_codeUpdate.do',
response: ({ query }) => {
url: '/virtual/coop_codeUpdate.do',
response: () => {
return {
success: true,
code: "",
......@@ -27,7 +13,7 @@ export default [
},
{
url: '/home/coop_queryAgreement.do',
response: ({ query }) => {
response: () => {
return {
success: true,
code: "",
......@@ -41,7 +27,7 @@ export default [
},
},
{
url: '/real/index.do',
url: '/virtual/index.do',
response: () => {
return {
success: true,
......@@ -51,6 +37,10 @@ export default [
data: {
"actStartTime": 1764691200000,
"actEndTime": 1796227200000,
// "firstMoneyPop": {
// "agreementText": "协议文案anim dolore cillum elit voluptate协议文案",
// "experienceNum": 27126512
// },
"virtualAssets": {
"preDayIncome": 131300,
"availableFunds": 232400,
......@@ -71,9 +61,13 @@ export default [
"positionMoney": Math.random() * 1000000 >> 0, // 累计收益,mineProduct为true时有值,单位:分
"totalProfit": Math.random() * 1000000 >> 0, // 持仓金额,mineProduct为true时有值,单位:分
})),
"productEnd": true,
"lcGradeIcon": true, // true-展示
"endPoint": 85475240.69343245,
"codeList": new Array(7).fill(1).map((item, index) => ({
"code": index === 0 ? "23112008P" : "consectetur",
"type": index === 0 ? '0' : '1', // 产品类型(0-非现金,1-现金)
})),
"productEnd": false,
// (24 * 60 * 60 * 1000 * 3)
"endPoint": new Date().getTime() - 1000,
"giftPop": {
"actPrizeVO": new Array(6).fill(1).map((_, i) => {
return {
......@@ -86,7 +80,6 @@ export default [
"show": true
},
"lastMonthRankPop": false,
overallRankPop: null ,
// "overallRankPop": {
// "prizeId": "anim",
// "prizeImg": "officia velit dolor ex",
......@@ -96,15 +89,16 @@ export default [
"bannerImg": `http://xqtpl.com/bg/300/300/banner${index+1}?color=fff`,
"bannerLink": "http://xqtpl.com/bg/300/300?color=fff"
})),
"currentTime": 39452811.65979925,
"canJoinCurrentRank": false,
"currentTime": new Date().getTime(),
"isBlack": false,
"signInStatus": true
"lcGradeIcon": true,
}
}
},
},
{
url: '/real/receiveNewGift.do',
url: '/virtual/receiveNewGift.do',
response: () => {
return {
success: true,
......@@ -171,8 +165,8 @@ export default [
},
},
{
url: '/checkIn_1/doSign.do',
response: ({ query }) => {
url: '/checkIn_1/doCheckIn.do',
response: () => {
return {
success: true,
code: "",
......@@ -180,7 +174,7 @@ export default [
data: {
"otherPrizeInfo": {
"productName": "deserunt in aliquip",
"wealthAmount": 3174067.9120013267,
"prizeName": "culpa non dolore",
"link": "minim et commodo eu ullamco"
},
"extra": "tempor sunt ipsum",
......@@ -215,10 +209,74 @@ export default [
}
},
},
{
url: '/virtual/tradeRecords.do',
response: () => {
return {
success: true,
code: "",
message: "",
data: {
haveMore: true,
list: new Array(20).fill(1).map((_, i) => {
return {
desc: "模拟交易记录页--" + i,
gmtCreate: Date.now() + Math.random() * 1000000000,
amount: Math.random() * 10000000 >> 0,
/** 0-购买待确认,1-购买成功,2-赎回成功,3-购买失败) */
tradeStatus: Math.random() * 3 >> 0,
}
}),
}
}
},
},
{
url: '/product/index.do',
response: () => {
return {
success: true,
code: "",
message: "",
timeStamp: Date.now(),
data: {
productName: "productName",
totalProfit: Math.random() * 100000 >> 0,
tranche: 7660,
marketValue: Math.random() * 10000000 >> 0,
yesterdayProfit: Math.random() * 10000 >> 0,
availableFunds: 7690,
minBuyLimit: 1,
}
}
},
},
{
url: '/product/buy.do',
response: () => {
return {
success: true,
code: "",
message: "",
data: null,
}
},
},
{
url: '/product/redeem.do',
response: () => {
return {
success: true,
code: "",
message: "",
data: null,
}
},
},
{
url: '/home/coop_sendCode.do',
method: 'post',
response: ({ query }) => {
response: () => {
return {
"code": "magna laborum amet",
"data": {
......@@ -234,7 +292,7 @@ export default [
{
url: '/home/coop_checkCode.do',
method: 'post',
response: ({ query }) => {
response: () => {
return {
"code": "magna laborum amet",
"data": 'http://localhost:5173/?t=1',
......@@ -246,7 +304,7 @@ export default [
},
{
url: '/home/doCheckIn.do',
response: ({ query }) => {
response: () => {
return {
success: true,
code: "",
......@@ -257,7 +315,7 @@ export default [
},
{
url: '/home/doRewards.do',
response: ({ query }) => {
response: () => {
return {
success: true,
code: "",
......@@ -268,7 +326,7 @@ export default [
},
{
url: '/customActivity/hxlc/login',
response: ({ query }) => {
response: () => {
return {
success: true,
code: "",
......@@ -280,7 +338,7 @@ export default [
},
{
url: '/invite/coop_queryRecommand.do',
response: ({ query }) => {
response: () => {
return {
"success": true,
"data": {
......@@ -339,7 +397,7 @@ export default [
},
{
url: '/task/queryTasks.do',
response: ({ query }) => {
response: () => {
return {
"success": true,
"code": "sit velit ut cillum laboris",
......@@ -409,7 +467,7 @@ export default [
},
{
url: '/task/doCompleted.do',
response: ({ query }) => {
response: () => {
return {
"success": true,
"code": "sit velit ut cillum laboris",
......@@ -420,7 +478,7 @@ export default [
},
{
url: '/task/sendPrize.do',
response: ({ query }) => {
response: () => {
return {
"success": true,
"code": "sit velit ut cillum laboris",
......@@ -435,7 +493,7 @@ export default [
},
{
url: '/answer_1/query.do',
response: ({ query }) => {
response: () => {
return {
"code": null,
"data": {
......@@ -479,7 +537,7 @@ export default [
},
{
url: '/answer_1/start.do',
response: ({ query }) => {
response: () => {
return {
"code": null,
"data": {
......@@ -501,7 +559,7 @@ export default [
},
{
url: '/answer_1/getQuestion.do',
response: ({ query }) => {
response: () => {
return {
"code": null,
"data": {
......@@ -523,7 +581,7 @@ export default [
},
{
url: '/answer_1/submit.do',
response: ({ query }) => {
response: () => {
return {
"code": null,
"data": {
......@@ -548,7 +606,7 @@ export default [
},
{
url: '/answer_1/doCompleted.do',
response: ({ query }) => {
response: () => {
return {
"code": null,
"data": {
......@@ -575,8 +633,8 @@ export default [
},
},
{
url: '/home/queryWealthRecords.do',
response: ({ query }) => {
url: '/virtual/queryWealthRecords.do',
response: () => {
return {
success: true,
code: "",
......@@ -597,7 +655,7 @@ export default [
},
{
url: '/invite/coop_assist.do',
response: ({ query }) => {
response: () => {
return {
success: true,
code: "",
......
export default [
{
url: '/mncp/index.do',
response: ({ query }) => {
return {
success: true,
code: "",
message: "",
timeStamp: Date.now(),
data: {
productName: "productName",
totalProfit: Math.random() * 100000 >> 0,
tranche: 7660,
marketValue: Math.random() * 10000000 >> 0,
yesterdayProfit: Math.random() * 10000 >> 0,
availableFunds: 7690,
minBuyLimit: 1,
}
}
},
},
{
url: '/mncp/buy.do',
response: ({ query }) => {
return {
success: true,
code: "",
message: "",
data: null,
}
},
},
{
url: '/mncp/redeem.do',
response: ({ query }) => {
return {
success: true,
code: "",
message: "",
data: null,
}
},
},
{
url: '/mncp/tradeRecords.do',
response: ({ query }) => {
return {
success: true,
code: "",
message: "",
data: {
haveMore: true,
list: new Array(20).fill(1).map((_, i) => {
return {
desc: "模拟交易记录页--" + i,
gmtCreate: Date.now() + Math.random() * 1000000000,
amount: Math.random() * 10000000 >> 0,
tradeStatus: Math.random() * 3 >> 0,
}
}),
}
}
},
},
]
......@@ -7,19 +7,35 @@ const API = generateAPI({
getFrontVariable: 'coop_frontVariable.query',
// 首页
index: "real/index.do",
// 报名
signIn: "real/signIn.do",
index: "virtual/index.do",
// 领取新手礼包
receiveNewGift: "real/receiveNewGift.do",
receiveNewGift: "virtual/receiveNewGift.do",
// 奖品记录
records: "real/prizeRecords.do",
records: "virtual/prizeRecords.do",
// 查询签到数据
querySign: "checkIn_1/querySign.do",
// 完成签到
doSign: "checkIn_1/doSign.do",
doSign: "checkIn_1/doCheckIn.do",
// 完成签到浏览任务
completeSignView: "checkIn_1/completeSignView.do",
// 交易记录页面
tradeRecords: "virtual/tradeRecords.do",
// 模拟理财获取记录
queryWealthRecords: "virtual/queryWealthRecords.do",
// 首页-产品参数更新
coop_codeUpdate: {
uri: "virtual/coop_codeUpdate.do",
method: 'post',
headers: {
'Content-Type': 'application/json',
},
},
// 产品首页信息
productIndex: "product/index.do",
// 产品赎回
redeem: "product/redeem.do",
// 产品买入
buy: "product/buy.do",
......@@ -58,20 +74,6 @@ const API = generateAPI({
},
},
// 首页-产品参数更新
coop_codeUpdate: {
uri: "home/coop_codeUpdate.do",
method: 'post',
headers: {
'Content-Type': 'application/json',
},
},
// 首页-白名单限制弹窗
isWhiteUser: {
uri: "home/isWhiteUser.do",
showMsg: false,
},
// 首页-查询服务协议
coop_queryAgreement: "home/coop_queryAgreement.do",
// 首页-校验验证码并登录(渠道5-昆仑银行使用)
......@@ -93,13 +95,7 @@ const API = generateAPI({
doCheckIn: "home/doCheckIn.do",
// 签到-领奖
doRewards: "home/doRewards.do",
tradeRecords: "mncp/tradeRecords.do",
queryWealthRecords: "home/queryWealthRecords.do",
redeem: "mncp/redeem.do",
buy: "mncp/buy.do",
mncpIndex: "mncp/index.do",
drawIndex: "draw/index.do",
drawJoin: "draw/join.do",
......
src/assets/PrizePage/我的奖品.png

105 KB | W: | H:

src/assets/PrizePage/我的奖品.png

83.4 KB | W: | H:

src/assets/PrizePage/我的奖品.png
src/assets/PrizePage/我的奖品.png
src/assets/PrizePage/我的奖品.png
src/assets/PrizePage/我的奖品.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/blackPop/bg.png

128 KB | W: | H:

src/assets/blackPop/bg.png

127 KB | W: | H:

src/assets/blackPop/bg.png
src/assets/blackPop/bg.png
src/assets/blackPop/bg.png
src/assets/blackPop/bg.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/blackPop/know_btn.png

24.7 KB | W: | H:

src/assets/blackPop/know_btn.png

23.3 KB | W: | H:

src/assets/blackPop/know_btn.png
src/assets/blackPop/know_btn.png
src/assets/blackPop/know_btn.png
src/assets/blackPop/know_btn.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/firstPop/bg.png

15.8 KB | W: | H:

src/assets/firstPop/bg.png

327 KB | W: | H:

src/assets/firstPop/bg.png
src/assets/firstPop/bg.png
src/assets/firstPop/bg.png
src/assets/firstPop/bg.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/firstPop/check_bg.png

864 Bytes | W: | H:

src/assets/firstPop/check_bg.png

3.33 KB | W: | H:

src/assets/firstPop/check_bg.png
src/assets/firstPop/check_bg.png
src/assets/firstPop/check_bg.png
src/assets/firstPop/check_bg.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/firstPop/checked.png

580 Bytes | W: | H:

src/assets/firstPop/checked.png

3.12 KB | W: | H:

src/assets/firstPop/checked.png
src/assets/firstPop/checked.png
src/assets/firstPop/checked.png
src/assets/firstPop/checked.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/firstPop/happy_btn.png

7.96 KB | W: | H:

src/assets/firstPop/happy_btn.png

21.5 KB | W: | H:

src/assets/firstPop/happy_btn.png
src/assets/firstPop/happy_btn.png
src/assets/firstPop/happy_btn.png
src/assets/firstPop/happy_btn.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/homePage/record_list_btn.png

2.51 KB | W: | H:

src/assets/homePage/record_list_btn.png

2.13 KB | W: | H:

src/assets/homePage/record_list_btn.png
src/assets/homePage/record_list_btn.png
src/assets/homePage/record_list_btn.png
src/assets/homePage/record_list_btn.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/setupSuccessPop/bg.png

396 KB | W: | H:

src/assets/setupSuccessPop/bg.png

399 KB | W: | H:

src/assets/setupSuccessPop/bg.png
src/assets/setupSuccessPop/bg.png
src/assets/setupSuccessPop/bg.png
src/assets/setupSuccessPop/bg.png
  • 2-up
  • Swipe
  • Onion skin
src/assets/signPop/liulan_bg.png

313 KB | W: | H:

src/assets/signPop/liulan_bg.png

251 KB | W: | H:

src/assets/signPop/liulan_bg.png
src/assets/signPop/liulan_bg.png
src/assets/signPop/liulan_bg.png
src/assets/signPop/liulan_bg.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -54,7 +54,7 @@ class DetailPage extends React.Component<any, any> {
}
async updateInfo() {
const { success, data } = await API.mncpIndex({ code: this.props.code, });
const { success, data } = await API.productIndex({ code: this.props.code, });
if (!success) return;
this.setState({
productName: data.productName,
......
......@@ -6,8 +6,7 @@
left: 0px;
top: 0px;
position: relative;
background-color: #e86a3c;
// padding-top: 700px;
background-color: #d12b2d;
padding-top: 576px;
padding-bottom: 85px;
box-sizing: border-box;
......@@ -21,228 +20,7 @@
.sparkBg("homePage/bg.png");
background-size: 750px 779px;
}
.title {
width: 705px;
height: 316px;
left: 45px;
top: 0px;
position: absolute;
// .sparkBg("homePage/title.png");
}
.virtual_assets {
width: 712px;
height: 513px;
left: 19px;
position: relative;
margin-top: 18px;
.sparkBg("homePage/virtual_assets_bg_new.png");
&.short_height {
height: 412px;
.sparkBg("homePage/virtual_assets_bg_short.png");
}
.time_box {
width: 100%;
height: 40px;
position: absolute;
top: 20px;
left: 0;
display: flex;
align-items: center;
justify-content: flex-end;
color: rgb(153, 108, 0);
padding-right: 32px;
box-sizing: border-box;
font-size: 22px;
line-height: 40px;
.time_item {
width: 40px;
height: 40px;
border: 1px solid rgb(255, 255, 255);
box-sizing: border-box;
border-radius: 10px;
background-image: linear-gradient(0deg, rgb(237, 88, 29) 0%, rgb(255, 144, 65) 100%);
.flex_center();
color: rgb(255, 255, 255);
margin: 0 4px;
}
}
.time_box_over {
position: absolute;
right: 29px;
top: 26px;
width: 223px;
height: 40px;
.sparkBg("homePage/time_box_over_bg.png");
font-size: 22px;
color: rgb(255, 255, 255);
letter-spacing: 2px;
.flex_center();
}
.yesterday_label {
width: 153px;
height: 27px;
left: 30px;
top: 116px;
position: absolute;
opacity: 0.6;
font-size: 26px;
line-height: 27px;
padding-left: 20px;
color: rgba(0, 0, 0, 1);
}
.yesterday_amount {
width: 228px;
height: 56px;
left: 29px;
top: 171px;
position: absolute;
font-size: 66px;
line-height: 56px;
padding-left: 20px;
color: rgb(237, 10, 10);
font-weight: bold;
}
.record_btn {
width: 176px;
height: 24px;
left: 490px;
top: 116px;
position: absolute;
.sparkBg("homePage/record_list_btn.png");
// .record_btn_text {
// width: 162px;
// height: 24px;
// left: 0px;
// top: 0px;
// position: absolute;
// opacity: 0.6;
// font-size: 26px;
// line-height: 24px;
// color: rgba(24, 24, 24, 1);
// }
// .arrow_right {
// width: 13px;
// height: 24px;
// left: 163px;
// top: 0px;
// position: absolute;
// opacity: 0.6;
// .sparkBg("homePage/arrow_right.png");
// }
}
.other_assets {
width: 666px;
height: 70px;
left: 23px;
top: 268px;
position: absolute;
.other_assets1 {
width: 195px;
height: 70px;
left: 0;
top: 0px;
position: absolute;
}
.other_assets2 {
width: 195px;
height: 70px;
left: 236px;
top: 0px;
position: absolute;
}
.other_assets3 {
width: 195px;
height: 69px;
left: 471px;
top: 1px;
position: absolute;
}
.other_assets_label {
width: 100%;
height: 25px;
left: 0px;
top: 0px;
position: absolute;
opacity: 0.6;
font-size: 26px;
line-height: 25px;
color: rgba(0, 0, 0, 1);
text-align: center;
}
.other_assets_value {
width: 100%;
height: 26px;
left: 0;
top: 44px;
position: absolute;
font-size: 30px;
line-height: 26px;
color: rgb(28, 28, 28);
text-align: center;
font-weight: bold;
}
}
.canuse_popover {
width: 157px;
height: 39px;
left: 360px;
top: 221px;
position: absolute;
.canuse_popover_bg {
width: 157px;
height: 39px;
left: 0px;
top: 0px;
position: absolute;
opacity: 0.5;
// .sparkBg("homePage/canuse_popover_bg.png");
.sparkBg("homePage/canuse_popover_bg_left.png");
}
.canuse_popover_text {
width: 100%;
height: 21px;
left: 0px;
top: 9px;
position: absolute;
font-size: 22px;
line-height: 22px;
color: rgba(135, 76, 8, 1);
text-align: center;
}
}
.realbuy_btn {
width: 327px;
height: 83px;
left: 193px;
top: 380px;
position: absolute;
font-size: 35px;
line-height: 34px;
color: rgba(255, 255, 255, 1);
.sparkBg("homePage/realbuy_btn_bg.png");
.flex_center();
}
}
.ranking_list{
width: 732px;
height: 1071px;
......@@ -646,15 +424,25 @@
overflow-x: hidden !important;
overflow-y: auto !important;
}
.actual_assets {
width: 732px;
height: 459px;
height: 580px;
left: 15px;
position: relative;
padding-top: 147px;
box-sizing: border-box;
.sparkBg("homePage/actaul_assets_bg_new.png");
.exchange_record {
width: 148px;
height: 22px;
position: absolute;
left: 534px;
top: 42px;
.sparkBg("homePage/record_list_btn.png");
}
.rate_wrap {
display: flex;
align-items: center;
......@@ -784,17 +572,32 @@
}
}
.realbuy_btn {
width: 327px;
height: 83px;
left: 193px;
top: 380px;
.time_box {
width: 593px;
height: 73px;
position: absolute;
font-size: 35px;
line-height: 34px;
color: rgba(255, 255, 255, 1);
.sparkBg("homePage/realbuy_btn_bg.png");
.flex_center();
top: 419px;
left: 66px;
display: flex;
align-items: center;
justify-content: center;
color: #ffffff;
box-sizing: border-box;
font-size: 22px;
line-height: 73px;
.sparkBg("homePage/time_box_over_bg.png");
.time_item {
width: 46px;
height: 46px;
line-height: 46px;
.flex_center();
color: #e92836;
margin-left: 20px;
margin-right: 8px;
.sparkBg("homePage/dayblock.png");
}
}
}
......@@ -1048,9 +851,18 @@
.finance-achievement-icon {
width: 118px;
height: 111px;
left: 611px;
top: 557px;
left: 52px;
top: 392px;
position: absolute;
.sparkBg("homePage/financeAchievement.png");
}
.mnlcj-icon {
width: 177px;
height: 111px;
left: 562px;
top: 557px;
position: absolute;
.sparkBg("homePage/monilicaijin.png");
}
}
\ No newline at end of file
......@@ -144,10 +144,10 @@ class HomePage extends React.Component<any, any> {
}
/** 跳转模拟交易记录 */
// recordHadnle = _asyncThrottle(() => {
// if (!store.judgeActTime()) return
// PageCtrl.changePage(NewRecordPage, { tab: 1 });
// })
recordHadnle = _asyncThrottle(() => {
if (!store.judgeActTime()) return
PageCtrl.changePage(NewRecordPage, { tab: 1 });
})
/** 跳转“模拟”产品详情页 */
jumpVirtualDetailHandle = _asyncThrottle((item) => {
......@@ -155,15 +155,6 @@ class HomePage extends React.Component<any, any> {
PageCtrl.changePage(DetailPage, item)
})
/** 跳转“真实”产品详情页 */
// jumpRealDetailHandle = _asyncThrottle((item) => {
// if (!store.judgeActTime()) return
// const { curTab } = this.state
// if (curTab != 2) return false
// // 我的持仓才可以跳转
// diffJump(item.realBuyJumpUrl)
// })
/** 规则 */
ruleHandle = _asyncThrottle(() => {
if (!store.judgeActTime(true, false)) return
......@@ -228,41 +219,9 @@ class HomePage extends React.Component<any, any> {
componentWillUnmount(): void {
}
/*
getRedCountDown(redRainConfig) {
const now = new Date().getTime();
const today = dateFormatter(new Date(), 'yyyy-MM-dd');
const timeArr = redRainConfig.map(el => {
return {
...el,
start: new Date(today + " " + el.startTime).getTime(),
end: new Date(today + " " + el.endTime).getTime(),
}
})
// 按照开始时间排序
timeArr.sort((a, b) => {
return a.start - b.start;
})
const el = timeArr.find(el => {
return now >= el.start && now <= el.end;
})
if (el && !el.joinStatus) {
return 0;
} else {
const next = timeArr.find(el => {
return now < el.start;
});
if (!next) {
return 0
} else {
return next.start - now
}
}
}
*/
render() {
const { curTab, rankingTab, rankOptions, rankInfos, myRank } = this.state;
const { virtualAssets, recommendProductConfig, giftPop, bannerInfo, lcGradeIcon } = store.indexData
const { virtualAssets, recommendProductConfig, giftPop, bannerInfo, lcGradeIcon, endPoint, currentTime } = store.indexData
// 我的持仓
const mProductList = recommendProductConfig?.filter((item) => item.mineProduct)
// 当前tab的产品列表
......@@ -273,52 +232,6 @@ class HomePage extends React.Component<any, any> {
<div className="homePage">
<span className="bg"></span>
{/* {productEnd && <div className="prize_banner">
<span className="prize_btn" onClick={this.prizeHandle}></span>
</div>} */}
{/* 模拟资产 */}
{/* <div className="virtual_assets short_height">
{
endPoint > currentTime
? <Countdown
leftT={endPoint - currentTime}
renderText={data => {
const { day, hour, minute, second } = data
return <div className="time_box">
<span className="time_item">{day}</span>天
<span className="time_item">{hour}</span>时
<span className="time_item">{minute}</span>分
<span className="time_item">{second}</span>秒后失效
</div>
}}
countdownOver={() => store.updateIndex()}
/>
: <div className="time_box_over">理财体验金已失效</div>
}
<span className="yesterday_label">累计收益(元)</span>
<span className="yesterday_amount">{this.settleMoney(virtualAssets?.totalIncome || 0)}</span>
<div className="record_btn" onClick={this.recordHadnle}>
</div>
<div className="other_assets">
<div className="other_assets1">
<span className="other_assets_label">总资产</span>
<span className="other_assets_value">{this.settleMoney(virtualAssets?.totalMoney || 0)}</span>
</div>
<div className="other_assets2">
<span className="other_assets_label">可用资金</span>
<span className="other_assets_value">{this.settleMoney(virtualAssets?.availableFunds || 0)}</span>
</div>
<div className="other_assets3">
<span className="other_assets_label">昨日收益</span>
<span className="other_assets_value">{this.settleMoney(virtualAssets?.preDayIncome || 0)}</span>
</div>
</div>
<div className="canuse_popover">
<span className="canuse_popover_bg"></span>
<span className="canuse_popover_text"></span>
</div>
</div> */}
{/* 理财排行榜 */}
<div className={`ranking_list ${this.state.isExpand ? 'expandSty1' : ''}`}>
<div className="ranking_list_title">
......@@ -427,8 +340,9 @@ class HomePage extends React.Component<any, any> {
</div>
{/* 真实持仓 */}
{/* 模拟资产 */}
<div className="actual_assets">
<div className='exchange_record' onClick={this.recordHadnle}></div>
<div className="rate_wrap">
<div className="yield_rate">
<div className="yield_rate_label">收益率</div>
......@@ -458,6 +372,25 @@ class HomePage extends React.Component<any, any> {
<div className="canuse_popover">
<span className="canuse_popover_bg"></span>
</div>
{
endPoint > currentTime
? <Countdown
leftT={endPoint - currentTime}
renderText={data => {
const { day, hour, minute, second } = data
return <div className="time_box">
理财体验金
<span className="time_item">{day}</span>
<span className="time_item">{hour}</span>
<span className="time_item">{minute}</span>
<span className="time_item">{second}</span>秒后到期
</div>
}}
countdownOver={() => store.updateIndex()}
/>
: <div className="time_box">理财体验金已失效</div>
}
</div>
{/* banner */}
......@@ -520,7 +453,8 @@ class HomePage extends React.Component<any, any> {
<Button className="prize_btn" onClick={this.reallyPrizeHandle} />
{/* 其他icon */}
{giftPop?.show && <Button className="new-user-gift-icon" onClick={this.newUserFun}></Button>}
{lcGradeIcon &&<Button className="finance-achievement-icon" onClick={this.prizeHandle}></Button>}
<Button className="finance-achievement-icon" onClick={this.prizeHandle}></Button>
{lcGradeIcon && <Button className='mnlcj-icon'></Button>}
</div>
</div>
);
......
......@@ -13,7 +13,7 @@
top: 58px;
width: 18px;
height: 32px;
.sparkBg("RecordPage/backBtn.png");
.sparkBg("common/backBtn.png");
}
.bg {
......@@ -22,7 +22,7 @@
left: 0px;
top: 0px;
position: absolute;
.sparkBg("RecordPage/recordPageBg.png");
.sparkBg("newRecordPage/recordPageBg.png");
}
.bg-lachang {
......@@ -46,11 +46,11 @@
}
.tab-1 {
.sparkBg("RecordPage/tab1.png");
.sparkBg("newRecordPage/tab1.png");
}
.tab-2 {
.sparkBg("RecordPage/tab2.png");
.sparkBg("newRecordPage/tab2.png");
}
.tab-btn-1 {
......
......@@ -6,8 +6,6 @@ import './index.less';
import store from '../../store/store';
import { Button } from '@grace/ui';
import { _asyncThrottle } from "../../utils/utils";
import { ModalCtrl } from "@/core/ctrls/ModalCtrl";
import { Toast } from '@grace/ui';
@observer
class BlackPop extends React.Component {
......@@ -19,7 +17,7 @@ class BlackPop extends React.Component {
}
handleClose = _asyncThrottle(() => {
window.location.href = `${CFG.domain}/projectx/${store.frontVariable.virtualProjectId}/index.html?appID=${CFG.appID}&channel=${CFG.channel}`
window.location.href = `${CFG.domain}/projectx/${store.frontVariable.actualProjectId}/index.html?appID=${CFG.appID}&channel=${CFG.channel}`
})
render() {
......
......@@ -8,25 +8,21 @@
position: absolute;
.bg {
left: 82px;
left: 100px;
top: 320px;
width: 585px;
height: 861px;
width: 539px;
height: 875px;
position: absolute;
.sparkBg("firstPop/bg.png");
background-size: 585px 611px;
background-color: #ffffff;
border-radius: 36px;
}
.title {
width: 585px;
width: 539px;
position: absolute;
left: 82px;
top: 460px;
font-size: 36px;
color: rgba(1, 1, 1, 0.6);
left: 100px;
top: 610px;
font-size: 25px;
color: #7d7d7d;
text-align: center;
}
......@@ -34,12 +30,12 @@
width: 585px;
position: absolute;
left: 82px;
top: 520px;
top: 646px;
font-size: 90px;
color: rgb(211, 26, 25);
color: #f5504d;
font-weight: bold;
text-align: center;
line-height: 90px;
line-height: 82px;
.unit {
font-size: 40px;
......@@ -47,21 +43,21 @@
}
.happy_btn {
left: 120px;
top: 1010px;
width: 510px;
height: 138px;
position: absolute;
left: 159px;
top: 1050px;
width: 426px;
height: 86px;
.sparkBg("firstPop/happy_btn.png");
}
.check_box {
position: absolute;
left: 159px;
top: 640px;
left: 132px;
top: 754px;
line-height: 35px;
font-size: 24px;
color: rgb(155, 155, 155);
font-size: 20px;
color: #7d7d7d;
margin-bottom: 28px;
font-weight: bold;
display: flex;
......@@ -70,10 +66,10 @@
.check_icon {
flex-shrink: 0;
position: relative;
width: 34px;
height: 34px;
width: 33px;
height: 33px;
.sparkBg("firstPop/check_bg.png");
margin-right: 14px;
margin-right: 6px;
&.checked::after {
content: "";
......@@ -87,8 +83,8 @@
}
.check_text {
width: 400px;
height: 380px;
width: 420px;
height: 250px;
line-height: 30px;
overflow-y: auto;
font-weight: normal;
......@@ -105,5 +101,4 @@
position: absolute;
.sparkBg("common/close.png");
}
}
'use strict';
import React from 'react';
import { observer } from 'mobx-react';
import './index.less';
import { Button } from '@grace/ui';
import { _asyncThrottle } from "../../utils/utils";
import { ModalCtrl } from "@/core/ctrls/ModalCtrl";
import { Toast } from '@grace/ui';
import SetupSuccessPop from "../setupSuccessPop";
import API from '@/api';
@observer
class SetupPop extends React.Component {
constructor(props) {
super(props);
}
async componentDidMount() {
}
handleSetup = _asyncThrottle(async () => {
try {
await API.signIn()
Toast.show('报名成功');
ModalCtrl.closeModal();
ModalCtrl.showModal(SetupSuccessPop, {});
} catch (error) {
Toast.show(error.message || '报名失败');
}
})
// handleClose = _asyncThrottle(() => {
// ModalCtrl.closeModal();
// })
render() {
return (
<div className="setupPop modal_center">
<span className="bg"></span>
<Button className="know_btn" onClick={this.handleSetup} />
{/* <Button className="close" onClick={this.handleClose} /> */}
</div>
);
}
}
export default SetupPop;
@import "../../res.less";
.setupPop {
width: 750px;
height: 1624px;
left: 0px;
top: 0px;
position: absolute;
.bg {
left: 100px;
top: 588px;
width: 539px;
height: 310px;
position: absolute;
.sparkBg("setupPop/bg.png");
}
.know_btn {
position: absolute;
left: 159px;
top: 768px;
width: 426px;
height: 86px;
.sparkBg("setupPop/know_btn.png");
}
.close {
left: 346px;
top: 986px;
width: 58px;
height: 58px;
position: absolute;
.sparkBg("common/close.png");
}
}
......@@ -29,7 +29,7 @@ class SetupSuccessPop extends React.Component {
onStop = async() => {
this.btnStarting = false;
store.updateIndex();
// store.updateIndex();
if (this.drawResultInfo.prizeId == "thanks") {
ModalCtrl.showModal(NoPrizePanel, {type: 'final_turntable', ...this.drawResultInfo});
} else {
......
......@@ -8,7 +8,6 @@ import { Button, Toast } from '@grace/ui';
import { _asyncThrottle, formatThousand } from '@/utils/utils';
import store from '@/store/store';
import API from '@/api';
import TaskPanel from '@/panels/taskPanel/index.jsx';
import SignTaskPop from '@/panels/signTaskPop';
import { weekList } from "@/contants"
import classNames from 'classnames';
......@@ -79,7 +78,6 @@ class SignCom extends React.Component {
if(signInfo?.prizeDays?.includes(`${currentWeek}`)) {
ModalCtrl.showModal(SignTaskPop, {
otherPrizeInfo: data.otherPrizeInfo || {},
prizeInfo: data?.options?.[0] || {},
callback: () => {
this.jumpToSing();
}
......
......@@ -11,7 +11,7 @@
width: 539px;
position: absolute;
left: 100px;
top: 268px;
top: 398px;
}
.bg {
......
......@@ -23,12 +23,12 @@ class SignTaskPop extends React.Component {
})
render() {
const {otherPrizeInfo, prizeInfo} = this.props;
const {otherPrizeInfo} = this.props;
return (
<div className="signTaskPop modal_center">
<div className='center-box'>
<span className="bg"></span>
<div className='prize_remark'>浏览“{otherPrizeInfo?.productName}”产品,再得{prizeInfo?.optionName}元红包</div>
<div className='prize_remark'>浏览“{otherPrizeInfo?.productName}”产品,再得{otherPrizeInfo?.prizeName}</div>
<Button className="know_btn" onClick={this.handleToLink} />
{/* <Button className="close" onClick={this.handleClose} /> */}
</div>
......
......@@ -11,37 +11,35 @@
width: 539px;
position: absolute;
left: 100px;
top: 268px;
top: 398px;
}
.bg {
left: 0;
top: 0;
width: 539px;
height: 772px;
height: 623px;
position: absolute;
.sparkBg("signPop/liulan_bg.png");
}
.prize_remark {
width: 100%;
font-size: 25px;
font-size: 28px;
position: absolute;
left: 0;
top: 330px;
top: 125px;
padding: 0 10px;
box-sizing: border-box;
text-align: center;
color: #ff4d3c;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
color: #5b2200;
padding: 0 110px;
}
.know_btn {
position: absolute;
left: 60px;
top: 645px;
top: 486px;
width: 426px;
height: 86px;
.sparkBg("signPop/liulan_btn.png");
......
import { makeAutoObservable, } from 'mobx';
import { makeAutoObservable, toJS} from 'mobx';
import API from '../api/index';
import { Toast } from "@grace/ui";
import { initWx } from "@/built-in/share/weixin/weixin.ts";
......@@ -7,9 +7,11 @@ import { ModalCtrl } from '@/core/ctrls/ModalCtrl';
import { getDomain } from '@spark/dbdomain';
import { showShareGuide } from '@spark/share';
import BlackPop from '@/panels/blackPop/index';
import SetupPop from '@/panels/setupPop/index';
import { CHANNEL, queryAppFundDetail } from '@/AppTools';
import EndPop from '@/panels/endPop';
import { PrizePanel } from '@/panels/PrizePanel/PrizePanel';
import FirstPop from '@/panels/firstPop/firstPop';
import SetupSuccessPop from '@/panels/setupSuccessPop'
class Store {
......@@ -17,6 +19,8 @@ class Store {
makeAutoObservable(this);
}
homeRoot = null;
/** 前端开发配置 */
frontVariable: {
// 虚拟盘项目id
......@@ -56,6 +60,10 @@ class Store {
indexData: {
actStartTime: number,
actEndTime: number,
firstMoneyPop: {
agreementText: string,
experienceNum: number,
},
// 模拟资产
virtualAssets: {
preDayIncome: number,
......@@ -102,9 +110,57 @@ class Store {
}[],
currentTime: number,
isBlack: boolean,
signInStatus: boolean,
canJoinCurrentRank: boolean,
} = {} as any;
/**
* 更新某些基金信息
* @param fundcodeList 需要查询的基金code列表
*/
async updateFundInfo(fundcodeList) {
console.info('需要查询的基金code列表, ', fundcodeList.map(item => item.code))
// 调客户端方法 查询产品的收益率等信息
const adInfos = []
for (let len = fundcodeList.length, i = 0; i < len; i++) {
const res = await queryAppFundDetail(fundcodeList[i])
if (res) adInfos.push(res)
}
// 本地自测代码
// adInfos[0] = {
// fundcode: '23112008P',
// incomeRate: '1.78%',
// pernetValue: '1.0690',
// }
// 将客户端查到的收益率 更新到产品列表中
const _temp = JSON.parse(JSON.stringify(this.indexData))
_temp.recommendProductConfig = _temp.recommendProductConfig?.map(item => {
const _adInfo = adInfos.find(adInfo => adInfo.fundcode == item.code)
if (_adInfo) {
item.rate = (_adInfo.incomeRate.replace('%', '') || 0) * 10000 / 100
return item
}
return item
})
this.indexData = _temp;
console.info('基金产品收益率信息(客户端更新后的), ', toJS(this.indexData))
if (!adInfos?.length) return
// 将客户端查到的收益率 更新我们后端
const _codeList = adInfos.map(item => {
return {
code: item.fundcode, // 产品code
incomeRate: (item.incomeRate.replace('%', '') || 0) * 10000 / 100, // 年化率(单位:分),例如:1.78%传递178
netValue: (item.pernetValue || 0) * 1000000 / 100, // 净值(单位:分),例如:1.66传递16600
}
})
const params = {
codeList: _codeList,
}
console.info('coop_codeUpdate入参,', params)
API.coop_codeUpdate(params)
}
async updateIndex() {
const { success, data, timeStamp } = await API.index();
if (!success) {
......@@ -114,16 +170,29 @@ class Store {
resData.currentTime = timeStamp;
this.indexData = resData;
const { isBlack, giftPop, lastMonthRankPop, overallRankPop } = resData
const { isBlack, giftPop, lastMonthRankPop, overallRankPop, firstMoneyPop, codeList } = resData
// 更新产品信息
if (codeList?.length && CFG.channel == CHANNEL.HXLC) {
this.updateFundInfo(codeList)
}
// 非白名单名单拦截弹窗
if (isBlack) {
ModalCtrl.showModal(BlackPop);
}
// 立即报名弹窗
// 发放初始理财体验金弹窗
if (firstMoneyPop) {
ModalCtrl.showModal(FirstPop, {
notifyText: firstMoneyPop.agreementText,
experienceNum: firstMoneyPop.experienceNum,
})
}
// 新手礼包获得弹窗
if (giftPop?.pop) {
ModalCtrl.showModal(SetupPop);
ModalCtrl.showModal(SetupSuccessPop);
}
// 上月理财成绩弹窗
......@@ -155,10 +224,10 @@ class Store {
async initShare() {
const domain = await getDomain();
console.error('看下域名', domain);
let url = `${domain || location.origin}${CFG.index}`;
const url = `${domain || location.origin}${CFG.index}`;
const shareInfo = this.frontVariable?.shareInfo?.[0]
let option = {
const option = {
title: shareInfo?.title,
// 标题
desc: shareInfo?.desc || '',
......@@ -177,7 +246,7 @@ class Store {
let url = `${domain || location.origin}${CFG.index}`;
const shareInfo = this.frontVariable?.shareInfo?.[1]
let option = {
const option = {
title: shareInfo?.title,
// 标题
desc: shareInfo?.desc || '',
......@@ -195,7 +264,7 @@ class Store {
}
async doAssist() {
let inviteCode = getUrlParam('inviteCode')
const inviteCode = getUrlParam('inviteCode')
if (!inviteCode || inviteCode == 'null' || inviteCode == 'undefined') return false;
const { success, message, code } = await API.doAssist({ inviteCode: inviteCode });
history.replaceState({}, '', location.href.replace(new RegExp(`[?&]inviteCode=[^&]*`), ''));
......
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