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
f6ca4161
Commit
f6ca4161
authored
Dec 12, 2023
by
gechengyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交业务要素转ISO的测试程序
parent
04e2731d
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
42 additions
and
4 deletions
+42
-4
pom.xml
swiftCore/pom.xml
+1
-0
DateUtil.java
...ore/src/main/java/com/brilliance/swift/util/DateUtil.java
+16
-0
Pacs00800108.xml
swiftCore/src/main/resources/swiftXml/Pacs00800108.xml
+1
-0
pacs008001.properties
swiftCore/src/main/resources/template/pacs008001.properties
+20
-3
pacs009001.properties
swiftCore/src/main/resources/template/pacs009001.properties
+2
-0
Element2MxTest.java
swiftCore/src/test/java/com/brilliance/Element2MxTest.java
+0
-0
Mx2ElementTest.java
swiftCore/src/test/java/com/brilliance/Mx2ElementTest.java
+2
-1
No files found.
swiftCore/pom.xml
View file @
f6ca4161
...
...
@@ -40,6 +40,7 @@
<exclude>
**/swiftJson/**
</exclude>
<exclude>
**/swiftTxt/**
</exclude>
<exclude>
**/swiftXml/**
</exclude>
<exclude>
**/mxjson/**
</exclude>
</excludes>
</configuration>
</plugin>
...
...
swiftCore/src/main/java/com/brilliance/swift/util/DateUtil.java
View file @
f6ca4161
...
...
@@ -13,6 +13,7 @@ import java.text.SimpleDateFormat;
import
java.util.Calendar
;
import
java.util.Date
;
import
java.util.GregorianCalendar
;
import
java.util.TimeZone
;
public
class
DateUtil
{
...
...
@@ -198,6 +199,21 @@ public class DateUtil {
return
xgc
;
}
public
static
XMLGregorianCalendar
parseXMLGregorianCalendarOfUTC
(
Date
date
)
throws
ParseException
,
DatatypeConfigurationException
{
GregorianCalendar
gc
=
new
GregorianCalendar
();
// 获取当前默认时区
TimeZone
defaultTimezone
=
TimeZone
.
getDefault
();
System
.
out
.
println
(
"当前默认时区:"
+
defaultTimezone
);
// 将时区设置为零(UTC)
gc
.
setTimeZone
(
TimeZone
.
getTimeZone
(
"Etc/UTC"
));
gc
.
setTime
(
date
);
XMLGregorianCalendar
xgc
=
DatatypeFactory
.
newInstance
().
newXMLGregorianCalendar
(
gc
);
return
xgc
;
}
/**
* 数据库Date类型转化为XML时间
*
...
...
swiftCore/src/main/resources/swiftXml/Pacs00800108.xml
View file @
f6ca4161
...
...
@@ -42,6 +42,7 @@ Change Log
<SttlmInf>
<SttlmMtd>
INDA
</SttlmMtd>
</SttlmInf>
</GrpHdr>
<CdtTrfTxInf>
<PmtId>
...
...
swiftCore/src/main/resources/template/pacs008001.properties
View file @
f6ca4161
...
...
@@ -7,14 +7,15 @@ bizSvc=appHdr.bizSvc
creDt
=
fiToFICstmrCdtTrf.grpHdr.creDtTm?appHdr.creDt
priority
=
appHdr.prty
#BODY
instrId
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtId.instrId
endToEndId
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtId.endToEndId
uetr
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtId.uetr
clrSysRef
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtId.clrSysRef
clrChanl
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.clrChanl
svcLvl
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.svcLvl
lclInstrm
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.lclInstrm.cd
lclInstrm
Cd
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.lclInstrm.cd
lclInstrmPrtry
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.lclInstrm.prtry
ctgyPurp
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.ctgyPurp.cd
ctgyPurp
Cd
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.ctgyPurp.cd
ctgyPurpPrtry
=
fiToFICstmrCdtTrf.cdtTrfTxInf.pmtTpInf.ctgyPurp.prtry
sttlmMtd
=
fiToFICstmrCdtTrf.grpHdr.sttlmInf.sttlmMtd
sttlmAcctIdIban
=
fiToFICstmrCdtTrf.grpHdr.sttlmInf.sttlmAcct.id.iban
...
...
@@ -429,6 +430,11 @@ prvsInstgAgt1BrnchPstlAdrCtrySubDvsn=fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt1
prvsInstgAgt1BrnchPstlAdrDstrctNm
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt1.brnchId.pstlAdr.dstrctNm
prvsInstgAgt1BrnchPstlAdrTwnLctnNm
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt1.brnchId.pstlAdr.twnLctnNm
prvsInstgAgt1BrnchAdrLines
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt1.brnchId.pstlAdr.adrLine
prvsInstgAgt1Acctiban
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt1Acct.id.iban
prvsInstgAgt1AcctTpCd
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt1Acct.tp.cd
prvsInstgAgt1AcctCcy
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt1Acct.ccy
prvsInstgAgt2Bicfi
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2.finInstnId.bicfi
prvsInstgAgt2ClrSysId
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2.finInstnId.clrSysMmbId.mmbId
prvsInstgAgt2ClrSysIdType
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2.finInstnId.clrSysMmbId.clrSysId.cd
...
...
@@ -473,6 +479,12 @@ prvsInstgAgt2BrnchPstlAdrCtrySubDvsn=fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2
prvsInstgAgt2BrnchPstlAdrDstrctNm
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2.brnchId.pstlAdr.dstrctNm
prvsInstgAgt2BrnchPstlAdrTwnLctnNm
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2.brnchId.pstlAdr.twnLctnNm
prvsInstgAgt2BrnchAdrLines
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2.brnchId.pstlAdr.adrLine
prvsInstgAgt2Acctiban
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2Acct.id.iban
prvsInstgAgt2AcctTpCd
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2Acct.tp.cd
prvsInstgAgt2AcctCcy
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt2Acct.ccy
prvsInstgAgt3Bicfi
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3.finInstnId.bicfi
prvsInstgAgt3ClrSysId
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3.finInstnId.clrSysMmbId.mmbId
prvsInstgAgt3ClrSysIdType
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3.finInstnId.clrSysMmbId.clrSysId.cd
...
...
@@ -517,6 +529,11 @@ prvsInstgAgt3BrnchPstlAdrCtrySubDvsn=fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3
prvsInstgAgt3BrnchPstlAdrDstrctNm
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3.brnchId.pstlAdr.dstrctNm
prvsInstgAgt3BrnchPstlAdrTwnLctnNm
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3.brnchId.pstlAdr.twnLctnNm
prvsInstgAgt3BrnchAdrLines
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3.brnchId.pstlAdr.adrLine
prvsInstgAgt3Acctiban
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3Acct.id.iban
prvsInstgAgt3AcctTpCd
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3Acct.tp.cd
prvsInstgAgt3AcctCcy
=
fiToFICstmrCdtTrf.cdtTrfTxInf.prvsInstgAgt3Acct.ccy
intrmyAgt1Bicfi
=
fiToFICstmrCdtTrf.cdtTrfTxInf.intrmyAgt1.finInstnId.bicfi
intrmyAgt1ClrSysId
=
fiToFICstmrCdtTrf.cdtTrfTxInf.intrmyAgt1.finInstnId.clrSysMmbId.mmbId
intrmyAgt1ClrSysIdType
=
fiToFICstmrCdtTrf.cdtTrfTxInf.intrmyAgt1.finInstnId.clrSysMmbId.clrSysId.cd
...
...
@@ -719,7 +736,7 @@ ultmtCdtrFaxNb=fiToFICstmrCdtTrf.cdtTrfTxInf.ultmtCdtr.ctctDtls.faxNb
ultmtCdtrEmailAdr
=
fiToFICstmrCdtTrf.cdtTrfTxInf.ultmtCdtr.ctctDtls.emailAdr
instrForCdtrAgt
=
fiToFICstmrCdtTrf.cdtTrfTxInf.instrForCdtrAgt
instrForNxtAgt
=
fiToFICstmrCdtTrf.cdtTrfTxInf.instrForNxtAgt
purp
=
fiToFICstmrCdtTrf.cdtTrfTxInf.purp.cd
purp
Cd
=
fiToFICstmrCdtTrf.cdtTrfTxInf.purp.cd
purpPrtry
=
fiToFICstmrCdtTrf.cdtTrfTxInf.purp.prtry
rgltryRptg
=
@buildRgltryRptg
rltdRmtInf
=
fiToFICstmrCdtTrf.cdtTrfTxInf.rltdRmtInf#rmtId
...
...
swiftCore/src/main/resources/template/pacs009001.properties
View file @
f6ca4161
...
...
@@ -7,6 +7,7 @@ bizSvc=appHdr.bizSvc
creDt
=
fiCdtTrf.grpHdr.creDtTm?appHdr.creDt
priority
=
appHdr.prty
#BODY
instrId
=
fiCdtTrf.cdtTrfTxInf.pmtId.instrId
endToEndId
=
fiCdtTrf.cdtTrfTxInf.pmtId.endToEndId
uetr
=
fiCdtTrf.cdtTrfTxInf.pmtId.uetr
clrSysRef
=
fiCdtTrf.cdtTrfTxInf.pmtId.clrSysRef
...
...
@@ -573,6 +574,7 @@ purpPrtry=fiCdtTrf.cdtTrfTxInf.purp.prtry
rmtInfUstrd
=
fiCdtTrf.cdtTrfTxInf.rmtInf.ustrd
instrForCdtrAgt
=
fiCdtTrf.cdtTrfTxInf.instrForCdtrAgt
instrForNxtAgt
=
fiCdtTrf.cdtTrfTxInf.instrForNxtAgt
#??202COV??
undrlygCstmrCdtTrf
=
fiCdtTrf.cdtTrfTxInf.undrlygCstmrCdtTrf#undrlygCstmrCdtTrf
dbtrAgtBicfi
=
fiCdtTrf.cdtTrfTxInf.dbtrAgt.finInstnId.bicfi
dbtrAgtClrSysId
=
fiCdtTrf.cdtTrfTxInf.dbtrAgt.finInstnId.clrSysMmbId.mmbId
...
...
swiftCore/src/test/java/com/brilliance/Element2MxTest.java
View file @
f6ca4161
This diff is collapsed.
Click to expand it.
swiftCore/src/test/java/com/brilliance/Mx2ElementTest.java
View file @
f6ca4161
...
...
@@ -18,8 +18,9 @@ public class Mx2ElementTest {
@Test
public
void
testMx2Map
()
throws
IOException
{
File
file
=
FileUtils
.
toFile
(
Mx2MtTest
.
class
.
getResource
(
"/swiftXml/Pacs00800108.xml"
));
// File file = FileUtils.toFile(Mx2MtTest.class.getResource("/swiftXml/MxPacs00800108.xml"));
File
file
=
FileUtils
.
toFile
(
Mx2MtTest
.
class
.
getResource
(
"/swiftXml/MxPacs00900108_COV.xml"
));
//
File file = FileUtils.toFile(Mx2MtTest.class.getResource("/swiftXml/MxPacs00900108_COV.xml"));
//File file = FileUtils.toFile(Mx2MtTest.class.getResource("/swiftXml/MxPacs00900108.xml"));
//File file = FileUtils.toFile(Mx2MtTest.class.getResource("/swiftXml/MxPacs00900108_COV.xml"));
//File file = FileUtils.toFile(Mx2MtTest.class.getResource("/swiftXml/MxCamt05300108_950.xml"));
...
...
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