Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
华
华夏模拟理财_20250701
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
SparkProjects
华夏模拟理财_20250701
Commits
b3a3612c
Commit
b3a3612c
authored
Jul 07, 2025
by
俞嘉婷
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 领奖banner
parent
72fbaab1
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
36 additions
and
7 deletions
+36
-7
main.ts
mock/main.ts
+1
-1
App.tsx
src/App.tsx
+1
-1
prize_banner.png
src/assets/homePage/prize_banner.png
+0
-0
prize_btn.png
src/assets/homePage/prize_btn.png
+0
-0
HomePage.less
src/pages/HomePage/HomePage.less
+16
-0
HomePage.tsx
src/pages/HomePage/HomePage.tsx
+18
-5
No files found.
mock/main.ts
View file @
b3a3612c
...
...
@@ -51,7 +51,7 @@ export default [
data
:
{
actStartTime
:
Date
.
now
()
-
1
*
24
*
60
*
60
*
1000
,
actEndTime
:
Date
.
now
()
+
3
*
24
*
60
*
60
*
1000
,
myEndTime
:
Date
.
now
()
+
1
*
24
*
60
*
60
*
1000
,
myEndTime
:
Date
.
now
()
-
1
*
24
*
60
*
60
*
1000
,
endPop
:
false
,
uid
:
'234234'
,
ruleText
:
'rulerulerulerulerulerulerule'
,
...
...
src/App.tsx
View file @
b3a3612c
...
...
@@ -30,7 +30,7 @@ class App extends Component {
const
defaultPage
=
{
myPrize
:
MyPrize
,
// TODO 举例子 新宿台奖品页
index
:
HomePage
,
}[
skinId
]
||
Res
Page
;
}[
skinId
]
||
Home
Page
;
PageCtrl
.
changePage
(
defaultPage
);
}
...
...
src/assets/homePage/prize_banner.png
0 → 100644
View file @
b3a3612c
197 KB
src/assets/homePage/prize_btn.png
0 → 100644
View file @
b3a3612c
19.9 KB
src/pages/HomePage/HomePage.less
View file @
b3a3612c
...
...
@@ -73,6 +73,22 @@
}
}
}
.prize_banner {
width: 707px;
height: 316px;
left: 22px;
// top: 1060px;
position: relative;
.sparkBg("homePage/prize_banner.png");
.prize_btn {
width: 270px;
height: 98px;
left: 218px;
top: 210px;
position: absolute;
.sparkBg("homePage/prize_btn.png");
}
}
.virtual_assets {
width: 712px;
height: 440px;
...
...
src/pages/HomePage/HomePage.tsx
View file @
b3a3612c
...
...
@@ -12,6 +12,7 @@ import RecordPage from '../RecordPage/RecordPage';
import
{
diffJump
}
from
'@/AppTools'
;
import
API
from
'@/api'
;
import
DetailPage
from
'../DetailPage/DetailPage'
;
import
ResPage
from
'../ResPage/ResPage'
;
@
observer
class
HomePage
extends
React
.
Component
<
any
,
any
>
{
...
...
@@ -61,6 +62,12 @@ class HomePage extends React.Component<any, any> {
ModalCtrl
.
showModal
(
Rulepop
)
})
/** 跳转结果页 */
prizeHandle
=
_asyncThrottle
(()
=>
{
if
(
!
store
.
judgeActTime
(
true
,
false
))
return
PageCtrl
.
changePage
(
ResPage
)
})
/** 已签到 */
signedHandle
=
_asyncThrottle
(
async
()
=>
{
if
(
!
store
.
judgeActTime
())
return
...
...
@@ -107,14 +114,15 @@ class HomePage extends React.Component<any, any> {
}
render
()
{
const
{
curTab
}
=
this
.
state
;
const
{
bigStartConfig
,
virtualAssets
,
checkIn
,
recommendProductConfig
}
=
store
.
indexData
const
{
bigStartConfig
,
virtualAssets
,
checkIn
,
recommendProductConfig
,
myEndTime
,
currentTime
}
=
store
.
indexData
const
isReachEndT
=
myEndTime
<=
currentTime
return
(
<
div
className=
"com_Container"
ref=
{
(
el
)
=>
this
.
root
=
el
}
>
<
div
className=
"homePage"
>
<
span
className=
"bg"
></
span
>
<
span
className=
"title"
></
span
>
{
/* 理财大明星 */
}
<
div
className=
"lc_bigstar"
>
{
isReachEndT
?
null
:
<
div
className=
"lc_bigstar"
>
<
span
className=
"lc_bigstar_bg"
></
span
>
<
div
className=
"hongBao"
>
{
bigStartConfig
?.
map
((
item
,
index
)
=>
(
...
...
@@ -124,7 +132,11 @@ class HomePage extends React.Component<any, any> {
</
div
>
))
}
</
div
>
</
div
>
</
div
>
}
{
/* 领奖banner */
}
{
isReachEndT
&&
<
div
className=
"prize_banner"
>
<
span
className=
"prize_btn"
onClick=
{
this
.
prizeHandle
}
></
span
>
</
div
>
}
{
/* 模拟资产 */
}
<
div
className=
{
`virtual_assets ${!virtualAssets?.realBuyJumpUrl ? 'short_height' : ''}`
}
>
<
span
className=
"yesterday_label"
>
昨日收益(元)
</
span
>
...
...
@@ -154,7 +166,7 @@ class HomePage extends React.Component<any, any> {
{
!!
virtualAssets
?.
realBuyJumpUrl
&&
<
Button
className=
"realbuy_btn"
onClick=
{
this
.
realBuyHandle
}
>
真实买入
</
Button
>
}
</
div
>
{
/* 签到区 */
}
<
div
className=
"sign_section"
>
{
isReachEndT
?
null
:
<
div
className=
"sign_section"
>
<
span
className=
"sign_section_bg"
></
span
>
<
span
className=
"sign_tips"
>
累计签到,最高可得
{
((
checkIn
?.
totalExperienceNum
||
0
)
/
10000
).
toFixed
(
0
)
}
万资金
</
span
>
{
checkIn
?.
todayCheckIn
...
...
@@ -181,7 +193,8 @@ class HomePage extends React.Component<any, any> {
)
})
}
</
div
>
</
div
>
</
div
>
}
{
/* 推荐产品 */
}
<
div
className=
"recommend_products"
>
<
span
className=
"r_products_title"
></
span
>
<
div
className=
"r_products_list"
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment