Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Fedex
/
iClear-api
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
wei.zhou
2021-06-29 16:21:08 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
453bd6d9cd6b255dac2c33733cc0b52d25ec12eb
453bd6d9
1 parent
6c704c4c
提交代码
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
39 additions
and
0 deletions
src/main/java/com/erry/iclear/dateInterface/service/ChmConsignmentService.java
src/main/java/com/erry/iclear/dateInterface/service/ChmConsignmentService.java
View file @
453bd6d
...
...
@@ -66,27 +66,39 @@ public class ChmConsignmentService {
result
.
setCustomsNo
(
mawb
.
getCustomMaster
());
//征免性质
DictionaryEntries
levyTypeDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
NATURE_EXEMPTION
+
mawb
.
getCutMode
());
if
(!
Objects
.
equals
(
levyTypeDictionaryEntries
,
null
)){
result
.
setTaxNatureDic
(
levyTypeDictionaryEntries
);
result
.
setTaxNature
(
levyTypeDictionaryEntries
.
getChineseName
());
}
//报关/转关关系标志:固定值0 ,但数据字典里没有0
//经停港/指运港
ChmCarryPort
chmCarryPort
=
Constant
.
chmCarryPortCache
.
get
(
mawb
.
getDistinatePort
());
if
(!
Objects
.
equals
(
chmCarryPort
,
null
)){
result
.
setThroughStopPortDic
(
chmCarryPort
);
result
.
setThroughStopPort
(
chmCarryPort
.
getPortNo
());
}
//TODO 报关标志【待确认】
DictionaryEntries
declaredDocTypeDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
DECLARED_DOC_TYPE
+
mawb
.
getEdiId
());
if
(!
Objects
.
equals
(
declaredDocTypeDictionaryEntries
,
null
)){
result
.
setDeclaredDocTypeDic
(
declaredDocTypeDictionaryEntries
);
result
.
setDeclaredDocType
(
declaredDocTypeDictionaryEntries
.
getChineseName
());
}
//海关编号
result
.
setCustomsNo
(
mawb
.
getEntryId
());
//运费币制
DictionaryEntries
currencyDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
CURRENCY_SYSTEM
+
mawb
.
getFeeCurr
());
if
(!
Objects
.
equals
(
currencyDictionaryEntries
,
null
)){
result
.
setTransCurrencyDic
(
currencyDictionaryEntries
);
result
.
setTransCurrency
(
currencyDictionaryEntries
.
getChineseName
());
}
//TODO 运费标记:固定值 3 【iclear中, 和成交方式相关,只有成交方式 1、2 时,才能传 3 】
...
...
@@ -100,8 +112,11 @@ public class ChmConsignmentService {
//保险费币制
DictionaryEntries
insuranceDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
CURRENCY_SYSTEM
+
mawb
.
getInsurCurr
());
if
(!
Objects
.
equals
(
insuranceDictionaryEntries
,
null
)){
result
.
setInsuranceCostCurrencyDic
(
insuranceDictionaryEntries
);
result
.
setInsuranceCostCurrency
(
insuranceDictionaryEntries
.
getChineseName
());
}
//保险费标记 ,根据transMode决定
...
...
@@ -113,8 +128,11 @@ public class ChmConsignmentService {
result
.
setNetWeight
(
mawb
.
getNetWt
());
//杂费币制
DictionaryEntries
otherDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
CURRENCY_SYSTEM
+
mawb
.
getOtherCurr
());
if
(!
Objects
.
equals
(
otherDictionaryEntries
,
null
)){
result
.
setOtherCurrencyDic
(
otherDictionaryEntries
);
result
.
setOtherCurrency
(
otherDictionaryEntries
.
getChineseName
());
}
//杂费/率
result
.
setOtherCost
(
mawb
.
getOtherRate
());
//杂费标志
...
...
@@ -130,34 +148,49 @@ public class ChmConsignmentService {
result
.
setEnteringNo
(
mawb
.
getPreEntryId
());
//启运国/运抵国
DictionaryEntries
fromCountryDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
COUNTRY
+
mawb
.
getTradeCountry
());
if
(!
Objects
.
equals
(
fromCountryDictionaryEntries
,
null
)){
result
.
setFromCountryDic
(
fromCountryDictionaryEntries
);
result
.
setFromCountry
(
fromCountryDictionaryEntries
.
getChineseName
());
}
//监管方式
DictionaryEntries
tradeModeDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
SUPERVISION_MODE
+
mawb
.
getTradeMode
());
if
(!
Objects
.
equals
(
tradeModeDictionaryEntries
,
null
)){
result
.
setTradeModeDic
(
tradeModeDictionaryEntries
);
result
.
setTradeMode
(
tradeModeDictionaryEntries
.
getChineseName
());
}
//境内收发货人编号
result
.
setTradeCoSCC
(
mawb
.
getTradeCode
());
//运输方式代码
DictionaryEntries
vehicleWayDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
VEHICLE_WAY_CODE
+
mawb
.
getTrafMode
());
if
(!
Objects
.
equals
(
vehicleWayDictionaryEntries
,
null
)){
result
.
setVehicleWay
(
vehicleWayDictionaryEntries
);
result
.
setVehicleWayCode
(
vehicleWayDictionaryEntries
.
getCode
());
}
//境内收发货人名称
result
.
setOperateUnitName
(
mawb
.
getTradeName
());
//成交方式
DictionaryEntries
dealModeDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
CLINCH_TYPE
+
mawb
.
getTransMode
());
if
(!
Objects
.
equals
(
dealModeDictionaryEntries
,
null
)){
result
.
setDealModeDic
(
dealModeDictionaryEntries
);
result
.
setDealMode
(
dealModeDictionaryEntries
.
getChineseName
());
}
//包装种类
DictionaryEntries
packageTypeDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
NEW_PACKAGE_TYPE
+
mawb
.
getWrapType
());
if
(!
Objects
.
equals
(
packageTypeDictionaryEntries
,
null
)){
result
.
setPackageTypeDic
(
packageTypeDictionaryEntries
);
result
.
setPackageType
(
packageTypeDictionaryEntries
.
getChineseName
());
}
//TODO 生产核销单位统一信用代码---报关形式类型
...
...
@@ -170,8 +203,11 @@ public class ChmConsignmentService {
//贸易国别
DictionaryEntries
tradeAreaCodeDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
COUNTRY
+
mawb
.
getTradeAreaCode
());
if
(!
Objects
.
equals
(
tradeAreaCodeDictionaryEntries
,
null
)){
result
.
setTradeAreaCodeDic
(
tradeAreaCodeDictionaryEntries
);
result
.
setTradeAreaCode
(
tradeAreaCodeDictionaryEntries
.
getChineseName
());
}
//标记及号码
result
.
setDeclaredRemark
(
mawb
.
getMarkNo
());
...
...
@@ -192,8 +228,11 @@ public class ChmConsignmentService {
//运单状态: 待申报海关
DictionaryEntries
transferWaybillStatusDictionaryEntries
=
Constant
.
dictionaryEntriesCache
.
get
(
Constant
.
TRANSFER_WAY_BILL_STATUS
+
"5"
);
if
(!
Objects
.
equals
(
transferWaybillStatusDictionaryEntries
,
null
)){
result
.
setConsStatusDic
(
transferWaybillStatusDictionaryEntries
);
result
.
setConsStatus
(
transferWaybillStatusDictionaryEntries
.
getChineseName
());
}
//推送时间作为创建时间,可以用来校验数据的有序性,如果新的推送时间小于已有的创建时间,就不更新数据
result
.
setCreateTime
(
new
Date
());
result
.
setUpdateTime
(
pushTime
);
...
...
Please
register
or
login
to post a comment