Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hnyc-portrait
Overview
Overview
Details
Activity
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhaochengxiang
hnyc-portrait
Commits
3aec206a
Commit
3aec206a
authored
Apr 26, 2020
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
成长度保留两位小数
parent
56fe9935
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
Dashboard.jsx
src/view/Dashboard.jsx
+3
-3
mDashboard.jsx
src/view/mDashboard.jsx
+3
-3
No files found.
src/view/Dashboard.jsx
View file @
3aec206a
...
...
@@ -251,11 +251,11 @@ class Dashboard extends Component {
return
(
level
>
2
)?
`
${
level
}
A`
:
'B'
;
}
curDimensionConvert
=
(
data
,
dimension
)
=>
{
curDimensionConvert
=
(
data
,
dimension
,
isCZD
=
false
)
=>
{
var
validateDimension
=
[];
dimension
.
map
(
item
=>
{
if
(
data
[
item
.
key
]
!=
null
)
{
validateDimension
.
push
({
key
:
item
.
key
,
name
:
item
.
name
,
value
:
data
[
item
.
key
]});
validateDimension
.
push
({
key
:
item
.
key
,
name
:
item
.
name
,
value
:
(
isCZD
===
true
)?
parseFloat
(
data
[
item
.
key
]).
toFixed
(
2
):
data
[
item
.
key
]});
}
return
item
;
})
...
...
@@ -272,7 +272,7 @@ class Dashboard extends Component {
}
else
if
(
index
===
2
)
{
this
.
setState
({
curDegree
:
'配合度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
phdDimension
)});
}
else
if
(
index
===
3
)
{
this
.
setState
({
curDegree
:
'成长度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
czdDimension
)});
this
.
setState
({
curDegree
:
'成长度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
czdDimension
,
true
)});
}
else
if
(
index
===
4
)
{
this
.
setState
({
curDegree
:
'诚信度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
cxdDimension
)});
}
...
...
src/view/mDashboard.jsx
View file @
3aec206a
...
...
@@ -261,11 +261,11 @@ class mDashboard extends Component {
return
(
level
>
2
)?
`
${
level
}
A`
:
'B'
;
}
curDimensionConvert
=
(
data
,
dimension
)
=>
{
curDimensionConvert
=
(
data
,
dimension
,
isCZD
=
false
)
=>
{
var
validateDimension
=
[];
dimension
.
map
(
item
=>
{
if
(
data
[
item
.
key
]
!=
null
)
{
validateDimension
.
push
({
key
:
item
.
key
,
name
:
item
.
name
,
value
:
data
[
item
.
key
]});
validateDimension
.
push
({
key
:
item
.
key
,
name
:
item
.
name
,
value
:
(
isCZD
===
true
)?
parseFloat
(
data
[
item
.
key
]).
toFixed
(
2
):
data
[
item
.
key
]});
}
return
item
;
})
...
...
@@ -282,7 +282,7 @@ class mDashboard extends Component {
}
else
if
(
index
===
2
)
{
this
.
setState
({
curDegree
:
'配合度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
phdDimension
)});
}
else
if
(
index
===
3
)
{
this
.
setState
({
curDegree
:
'成长度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
czdDimension
)});
this
.
setState
({
curDegree
:
'成长度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
czdDimension
,
true
)});
}
else
if
(
index
===
4
)
{
this
.
setState
({
curDegree
:
'诚信度'
,
curDimension
:
this
.
curDimensionConvert
(
data
,
cxdDimension
)});
}
...
...
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