Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
swiftISOEditor
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
swift
swiftISOEditor
Commits
6aeeb14f
Commit
6aeeb14f
authored
9 months ago
by
pengbao666
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改AmountCips类型校验bug
parent
22d07e25
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
7 deletions
+12
-7
MsgValidator.js
editor_vue/src/iso/script/MsgValidator.js
+12
-7
No files found.
editor_vue/src/iso/script/MsgValidator.js
View file @
6aeeb14f
...
...
@@ -2,8 +2,8 @@ import { isEmptyMsg } from "./MsgJson/MsgHander";
export
function
amountValidator
(
isM
,
desc
,
sca
)
{
return
(
rule
,
value
,
callback
)
=>
{
const
amtValue
=
value
.
value
+
""
;
const
amtCcy
=
value
.
c
cy
;
const
amtValue
=
value
.
amount
+
""
;
const
amtCcy
=
value
.
C
cy
;
if
(
amtValue
===
undefined
||
amtValue
===
null
||
amtValue
.
trim
()
===
""
)
{
if
(
isM
)
{
callback
(
new
Error
(
desc
+
" Cannot be null"
));
...
...
@@ -43,15 +43,20 @@ export function amountValidator(isM, desc, sca) {
export
function
amountCIPSValidator
(
isM
,
desc
,
sca
)
{
return
(
rule
,
value
,
callback
)
=>
{
const
amtValue
=
value
.
amount
+
""
;
const
amtCcy
=
value
.
ccy
;
const
amtValue
=
value
.
amount
;
const
amtCcy
=
value
.
Ccy
;
var
flag
=
false
;
if
(
amtCcy
===
undefined
||
amtCcy
===
null
||
amtCcy
.
trim
()
===
""
){
flag
=
true
;
if
(
isM
)
{
callback
(
new
Error
(
desc
+
" Cannot be null"
));
}
}
if
(
amtValue
===
undefined
||
amtValue
===
null
||
amtValue
.
trim
()
===
""
)
{
if
(
isM
)
{
callback
(
new
Error
(
desc
+
" Cannot be null"
));
}
else
if
(
amtCcy
!=
''
){
}
else
if
(
!
flag
){
callback
(
new
Error
(
"Amount Cannot be null"
));
}
else
{
callback
();
}
}
else
if
(
sca
.
length
===
2
)
{
const
totalDig
=
sca
[
0
];
...
...
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