Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
swiftMtMx
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
isc-v3.1-tmp
swiftMtMx
Commits
d55b01d6
Commit
d55b01d6
authored
Jun 27, 2023
by
wuzhe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
camt10700101修改50A换行
parent
c2a1a717
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
18 deletions
+21
-18
Field50aGenerate.java
...m/brilliance/swift/mx2mt/mt110/impl/Field50aGenerate.java
+15
-13
camt10700101.xml
swiftCore/src/main/resources/swiftXml/camt10700101.xml
+6
-5
No files found.
swiftCore/src/main/java/com/brilliance/swift/mx2mt/mt110/impl/Field50aGenerate.java
View file @
d55b01d6
...
...
@@ -23,29 +23,31 @@ public class Field50aGenerate extends AbstractMx2MtTagsGenerate {
context
.
set
(
Mx2MtContextIdentifier
.
MX_TO_MT_ERROR_LOCATION
,
"Block4/50a"
);
SwiftMessage
swiftMessage
=
context
.
get
(
SwiftMessage
.
class
);
List
<
Tag
>
tags
=
swiftMessage
.
getBlock4
().
getTags
();
String
cheBIC
=
getXmlNodeValue
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.Id.OrgId.AnyBIC"
);
String
chePyerAcct
=
bodyHdrParentElementName
+
".Chq.PyerAcct"
;
String
chePyerPstCtry
=
getXmlNodeValue
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.PstlAdr.Ctry"
);
int
cheBIC
=
getXmlNodeCounts
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.Id.OrgId.AnyBIC"
);
int
chePyerAcct
=
getXmlNodeCounts
(
bodyHdrParentElementName
,
document
,
"Chq.PyerAcct"
)
;
int
chePyerPstCtry
=
getXmlNodeCounts
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.PstlAdr.Ctry"
);
String
payerPath
=
bodyHdrParentElementName
+
".Chq.Pyer"
;
String
orgidOthr
=
getXmlNodeValue
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.Id.OrgId.Othr"
);
String
prvtidOthr
=
getXmlNodeValue
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.Id.PrvtId.Othr"
);
int
addressLineCount
=
getXmlNodeCounts
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.PstlAdr.AdrLine"
);
String
pstladrAdrline
=
""
;
String
pyerNm
=
getXmlNodeValue
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.Nm"
);
int
pyerNm
=
getXmlNodeCounts
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.Nm"
);
String
account
=
""
;
String
nameAddress
=
""
;
if
(
addressLineCount
>
0
){
pstladrAdrline
=
getXmlNodeValue
(
bodyHdrParentElementName
,
document
,
"Chq.Pyer.PstlAdr.AdrLine(0)"
);
}
if
(
StringUtil
.
isNotEmpty
(
cheBIC
)
)
{
if
(
cheBIC
>
0
)
{
String
bicCode
=
mx_to_mtAnyBIC
(
payerPath
);
if
(
StringUtil
.
isNotEmpty
(
chePyerAcct
)
){
if
(
chePyerAcct
>
0
){
account
=
mx_to_mtAccount
(
bodyHdrParentElementName
+
".Chq.PyerAcct"
);
}
tags
.
add
(
new
Tag
(
name_50A
,
account
+
Mx2MtConstants
.
NEW_LINE
+
bicCode
));
}
else
if
(
StringUtil
.
isNotEmpty
(
chePyerPstCtry
)){
}
else
{
tags
.
add
(
new
Tag
(
name_50A
,
bicCode
));
}
}
else
if
(
chePyerPstCtry
>
0
){
nameAddress
=
mx_to_mtFATFNameAndAddress
(
payerPath
);
if
(
StringUtil
.
isNotEmpty
(
chePyerAcct
)
)
{
if
(
chePyerAcct
>
0
)
{
account
=
mx_to_mtAccount
(
bodyHdrParentElementName
+
".Chq.PyerAcct"
);
}
else
if
(
StringUtil
.
isNotEmpty
(
orgidOthr
)
||
StringUtil
.
isNotEmpty
(
prvtidOthr
)){
account
=
mx_to_mtFATFIdentification
(
payerPath
,
false
);
...
...
@@ -61,7 +63,7 @@ public class Field50aGenerate extends AbstractMx2MtTagsGenerate {
boolean
structuredAddressIndicator
=
mx_to_mtAddressLineType
(
payerPath
);
if
(
structuredAddressIndicator
)
{
nameAddress
=
mx_to_mtFATFNameAndAddress2
(
payerPath
);
if
(
StringUtil
.
isNotEmpty
(
chePyerAcct
)
)
{
if
(
chePyerAcct
>
0
)
{
account
=
mx_to_mtAccount
(
bodyHdrParentElementName
+
".Chq.PyerAcct"
);
}
else
if
(
StringUtil
.
isNotEmpty
(
orgidOthr
)
||
StringUtil
.
isNotEmpty
(
prvtidOthr
)){
account
=
mx_to_mtFATFIdentification
(
payerPath
,
true
);
...
...
@@ -75,14 +77,14 @@ public class Field50aGenerate extends AbstractMx2MtTagsGenerate {
tags
.
add
(
new
Tag
(
name_50F
,
account
+
Mx2MtConstants
.
NEW_LINE
+
nameAddress
));
}
else
{
nameAddress
=
mx_to_mtPartyNameAndUnstructuredAddress
(
payerPath
);
if
(
StringUtil
.
isNotEmpty
(
chePyerAcct
)
){
if
(
chePyerAcct
>
0
){
account
=
mx_to_mtAccount
(
bodyHdrParentElementName
+
".Chq.PyerAcct"
);
}
tags
.
add
(
new
Tag
(
name_50K
,
account
+
Mx2MtConstants
.
NEW_LINE
+
nameAddress
));
}
}
else
if
(
StringUtil
.
isNotEmpty
(
pyerNm
)
){
}
else
if
(
pyerNm
>
0
){
nameAddress
=
mx_to_mtPartyNameAndUnstructuredAddress
(
payerPath
);
if
(
StringUtil
.
isNotEmpty
(
chePyerAcct
)
){
if
(
chePyerAcct
>
0
){
account
=
mx_to_mtAccount
(
bodyHdrParentElementName
+
".Chq.PyerAcct"
);
}
tags
.
add
(
new
Tag
(
name_50K
,
account
+
Mx2MtConstants
.
NEW_LINE
+
nameAddress
));
...
...
swiftCore/src/main/resources/swiftXml/camt10700101.xml
View file @
d55b01d6
...
...
@@ -52,11 +52,12 @@
<!-- <Ctry>WEQWE</Ctry>-->
<!-- </PstlAdr>-->
</Pyer>
<PyerAcct>
<Id>
<IBAN>
SSSS
</IBAN>
</Id>
</PyerAcct>
<!--50A account-->
<!-- <PyerAcct>-->
<!-- <Id>-->
<!-- <IBAN>SSSS</IBAN>-->
<!-- </Id>-->
<!-- </PyerAcct>-->
<DrwrAgt>
<FinInstnId>
QWERTYOII
</FinInstnId>
</DrwrAgt>
...
...
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