Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
enterprise-serevice-platform-web
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
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
张伯涛
enterprise-serevice-platform-web
Commits
8b9e92e0
Commit
8b9e92e0
authored
Nov 01, 2022
by
高宇
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
关联企业 修复部分bug
parent
edd78e12
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
136 additions
and
63 deletions
+136
-63
thousand.js
src/utils/thousand.js
+10
-0
AffiliatedEnterprises.vue
...views/personalCenter/components/AffiliatedEnterprises.vue
+126
-63
No files found.
src/utils/thousand.js
View file @
8b9e92e0
...
...
@@ -39,6 +39,16 @@ const thousand = {
}
else
{
return
s
}
},
//用于会显示,带有小数点的数字转化为千分位
decimalFmoney
(
num
)
{
const
res
=
num
.
toString
().
replace
(
/
\d
+/
,
function
(
n
){
// 先提取小数点前后的整数部分
//(\d)(?=(\d{3})正则的意思是匹配连续三个数结尾的数字,例如1234,1后面有234连续三个数的数字,就可以匹配上,匹配的是1这个数字。如果是123,因为1后面是两位数,所以就匹配不上了
return
n
.
replace
(
/
(\d)(?=(\d{3})
+$
)
/g
,
function
(
$1
){
return
$1
+
","
;
});
})
return
res
;
}
}
export
default
thousand
src/views/personalCenter/components/AffiliatedEnterprises.vue
View file @
8b9e92e0
This diff is collapsed.
Click to expand it.
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