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
a44c6984
Commit
a44c6984
authored
Jan 03, 2023
by
zhanghou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改mx2mt的53A逻辑
parent
149ac0d9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
9 deletions
+10
-9
AbstractMx2MtTagsGenerate.java
...com/brilliance/swift/mx2mt/AbstractMx2MtTagsGenerate.java
+4
-4
Field53AGenerate.java
...m/brilliance/swift/mx2mt/mt103/impl/Field53AGenerate.java
+6
-5
No files found.
swiftCore/src/main/java/com/brilliance/swift/mx2mt/AbstractMx2MtTagsGenerate.java
View file @
a44c6984
...
...
@@ -990,13 +990,13 @@ public abstract class AbstractMx2MtTagsGenerate implements Mx2MtTagsGenerate {
mtInstruction
=
"/TEMPREC/"
+
mtInstruction
;
}
//提取 /GenericMax8c/
String
mtType
=
context
.
get
(
SwiftMessage
.
class
).
getBlock2
().
getMessageType
();
//
String mtType = context.get(SwiftMessage.class).getBlock2().getMessageType();
String
[]
mxInstrInfs
=
StringUtil
.
splitAndKeepSeparator
(
mtInstruction
,
"/[A-Z0-9]{1,8}/"
);
for
(
int
i
=
0
;
i
<
mxInstrInfs
.
length
;
i
++)
{
String
mxIns
=
mxInstrInfs
[
i
];
if
(
mxIns
.
startsWith
(
"/FIN53/"
))
{
String
bicCode
=
mxIns
.
substring
(
7
);
if
(
Mx2MtConstants
.
MT_TYPE_103
.
equals
(
mtType
))
{
//
if (Mx2MtConstants.MT_TYPE_103.equals(mtType)) {
String
acccount
=
mx_to_mtAccount
(
grpHdrParentElementName
+
".GrpHdr.SttlmInf.SttlmAcct"
);
if
(
StringUtil
.
isEmpty
(
acccount
))
{
String
senderBic
=
(
String
)
context
.
get
(
Mx2MtContextIdentifier
.
MX_SENDER_BIC
,
true
);
...
...
@@ -1008,9 +1008,9 @@ public abstract class AbstractMx2MtTagsGenerate implements Mx2MtTagsGenerate {
}
else
{
bicCode53
=
bicCode
;
}
}
else
{
/*
} else {
bicCode53 = bicCode;
}
}
*/
}
}
}
...
...
swiftCore/src/main/java/com/brilliance/swift/mx2mt/mt103/impl/Field53AGenerate.java
View file @
a44c6984
...
...
@@ -31,11 +31,12 @@ public class Field53AGenerate extends AbstractMx2MtTagsGenerate {
SwiftMessage
swiftMessage
=
context
.
get
(
SwiftMessage
.
class
);
List
<
Tag
>
tags
=
swiftMessage
.
getBlock4
().
getTags
();
String
settlementMethod
=
getXmlNodeValue
(
grpHdrParentElementName
,
document
,
"GrpHdr.SttlmInf.SttlmMtd"
);
if
(
SettlementMethodCode
.
INGA
.
value
().
equals
(
settlementMethod
)
||
SettlementMethodCode
.
INDA
.
value
().
equals
(
settlementMethod
))
{
String
value
=
""
;
String
bicCode
=
mx_to_mt53A
(
bodyHdrParentElementName
+
".CdtTrfTxInf.InstrForNxtAgt"
);
String
account
=
mx_to_mtSettlementAccount
(
settlementMethod
,
grpHdrParentElementName
+
".GrpHdr.SttlmInf.SttlmAcct"
);
String
account
=
mx_to_mtSettlementAccount
(
settlementMethod
,
grpHdrParentElementName
+
".GrpHdr.SttlmInf.SttlmAcct"
);
if
((
SettlementMethodCode
.
INGA
.
value
().
equals
(
settlementMethod
)
||
SettlementMethodCode
.
INDA
.
value
().
equals
(
settlementMethod
))
&&
StringUtil
.
isNotEmpty
(
account
))
{
String
value
=
""
;
String
bicCode
=
mx_to_mt53A
(
bodyHdrParentElementName
+
".CdtTrfTxInf.InstrForNxtAgt"
);
if
(
StringUtil
.
isNotEmpty
(
bicCode
))
{
if
(
StringUtil
.
isNotEmpty
(
account
))
{
value
=
account
+
Mx2MtConstants
.
NEW_LINE
+
bicCode
;
...
...
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