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
94896913
Commit
94896913
authored
Jul 10, 2025
by
haiyoucuv
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
init
parent
6ea3effa
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
3 deletions
+22
-3
mncp.ts
mock/mncp.ts
+1
-0
DetailPage.module.less
src/pages/DetailPage/DetailPage.module.less
+8
-0
DetailPage.tsx
src/pages/DetailPage/DetailPage.tsx
+13
-3
No files found.
mock/mncp.ts
View file @
94896913
...
...
@@ -14,6 +14,7 @@ export default [
marketValue
:
Math
.
random
()
*
10000000
>>
0
,
yesterdayProfit
:
Math
.
random
()
*
10000
>>
0
,
availableFunds
:
Math
.
random
()
*
10000000
>>
0
,
minBuyLimit
:
100
,
}
}
},
...
...
src/pages/DetailPage/DetailPage.module.less
View file @
94896913
...
...
@@ -263,6 +263,14 @@
font-weight: bold;
}
.reallyBuy {
margin-top: 29px;
background-color: white;
color: #bc251c;
border: 1px solid #bc251c;
}
.simulateSell {
margin-top: 30px;
background-color: rgb(188, 37, 28);
...
...
src/pages/DetailPage/DetailPage.tsx
View file @
94896913
...
...
@@ -77,7 +77,9 @@ class DetailPage extends React.Component<any, any> {
clickSimulateBuy
=
_asyncThrottle
(
async
()
=>
{
const
{
buyInput
}
=
this
.
state
;
if
(
!
buyInput
||
buyInput
.
toString
().
trim
()
===
""
)
{
console
.
log
(
buyInput
);
if
(
!+
buyInput
||
buyInput
.
toString
().
trim
()
===
""
)
{
Toast
.
show
(
"请输入买入金额"
);
return
;
}
...
...
@@ -122,7 +124,9 @@ class DetailPage extends React.Component<any, any> {
clickSimulateSell
=
_asyncThrottle
(
async
()
=>
{
const
{
sellInput
}
=
this
.
state
;
if
(
!
sellInput
||
sellInput
.
toString
().
trim
()
===
""
)
{
console
.
log
(
sellInput
);
if
(
!+
sellInput
||
sellInput
.
toString
().
trim
()
===
""
)
{
Toast
.
show
(
"请输入赎回份额"
);
return
;
}
...
...
@@ -186,7 +190,7 @@ class DetailPage extends React.Component<any, any> {
<
motion
.
div
className=
{
styles
.
options
}
initial=
{
{
height
:
570
*
remScale
}
}
animate=
{
{
height
:
(
isBuy
?
570
:
400
)
*
remScale
}
}
//
animate={{ height: (isBuy ? 570 : 400) * remScale }}
>
<
div
className=
{
styles
.
tab
}
>
<
div
...
...
@@ -206,6 +210,7 @@ class DetailPage extends React.Component<any, any> {
</
div
>
<
motion
.
div
className=
{
styles
.
buy
}
transition=
{
{
type
:
"tween"
}
}
initial=
{
{
x
:
0
}
}
animate=
{
{
x
:
isBuy
?
0
:
750
*
remScale
}
}
>
...
...
@@ -234,6 +239,7 @@ class DetailPage extends React.Component<any, any> {
</
motion
.
div
>
<
motion
.
div
className=
{
styles
.
sell
}
transition=
{
{
type
:
"tween"
}
}
initial=
{
{
x
:
750
*
remScale
}
}
animate=
{
{
x
:
isBuy
?
750
*
remScale
:
0
}
}
>
...
...
@@ -259,6 +265,10 @@ class DetailPage extends React.Component<any, any> {
className=
{
classNames
(
styles
.
sellBtn
,
styles
.
simulateSell
,
"md13"
)
}
onClick=
{
this
.
clickSimulateSell
}
>
模拟赎回
</
Button
>
<
Button
className=
{
classNames
(
styles
.
sellBtn
,
styles
.
reallyBuy
,
"md10"
)
}
onClick=
{
this
.
clickReallyBuy
}
>
真实买入
</
Button
>
</
motion
.
div
>
</
motion
.
div
>
<
Button
...
...
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