记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
Project
Project
Details
Activity
Releases
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
董敬伟
liquidnet-bus-v1
Commits
179e7cae
Commit
179e7cae
authored
Dec 23, 2021
by
sunyuntian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
运费0元改为标快
parent
8c60f684
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
4 deletions
+22
-4
KylinFreightChargeMapper.java
...uidnet/service/kylin/mapper/KylinFreightChargeMapper.java
+1
-0
KylinFreightChargeMapper.xml
...quidnet.service.kylin.mapper/KylinFreightChargeMapper.xml
+3
-1
KylinFreightChargeServiceImpl.java
...orm/service/impl/kylin/KylinFreightChargeServiceImpl.java
+18
-3
No files found.
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/java/com/liquidnet/service/kylin/mapper/KylinFreightChargeMapper.java
View file @
179e7cae
...
@@ -9,4 +9,5 @@ import java.util.HashMap;
...
@@ -9,4 +9,5 @@ import java.util.HashMap;
public
interface
KylinFreightChargeMapper
extends
BaseMapper
<
KylinFreightChargeDao
>{
public
interface
KylinFreightChargeMapper
extends
BaseMapper
<
KylinFreightChargeDao
>{
int
setFreightCharge
(
KylinFreightChargeDao
kylinFreightCharge
);
int
setFreightCharge
(
KylinFreightChargeDao
kylinFreightCharge
);
void
delTableData
();
}
}
liquidnet-bus-do/liquidnet-service-kylin-do/src/main/resources/com.liquidnet.service.kylin.mapper/KylinFreightChargeMapper.xml
View file @
179e7cae
...
@@ -17,7 +17,9 @@
...
@@ -17,7 +17,9 @@
<if
test=
"businessType != null and businessType != ''"
>
#{businessType},
</if>
<if
test=
"businessType != null and businessType != ''"
>
#{businessType},
</if>
<if
test=
"businessTypeDesc != null and businessTypeDesc != ''"
>
#{businessTypeDesc}
</if>
<if
test=
"businessTypeDesc != null and businessTypeDesc != ''"
>
#{businessTypeDesc}
</if>
)
)
</insert>
</insert>
<delete
id=
"delTableData"
>
DELETE FROM kylin_freight_charge
</delete>
</mapper>
</mapper>
liquidnet-bus-service/liquidnet-service-platform/liquidnet-service-platform-impl/src/main/java/com/liquidnet/service/platform/service/impl/kylin/KylinFreightChargeServiceImpl.java
View file @
179e7cae
...
@@ -46,7 +46,8 @@ public class KylinFreightChargeServiceImpl {
...
@@ -46,7 +46,8 @@ public class KylinFreightChargeServiceImpl {
hBody
.
put
(
"jProvince"
,
jProvince
);
//寄件地址
hBody
.
put
(
"jProvince"
,
jProvince
);
//寄件地址
hBody
.
put
(
"jCity"
,
jCity
);
hBody
.
put
(
"jCity"
,
jCity
);
hBody
.
put
(
"jAddress"
,
jAddress
);
hBody
.
put
(
"jAddress"
,
jAddress
);
//清空表
kylinFreightChargeMapper
.
delTableData
();
String
fileName
=
KylinFreightChargeServiceImpl
.
class
.
getClassLoader
().
getResource
(
"city_2021.json"
).
getPath
();
String
fileName
=
KylinFreightChargeServiceImpl
.
class
.
getClassLoader
().
getResource
(
"city_2021.json"
).
getPath
();
String
s
=
jsonUtils
.
readJsonFile
(
fileName
);
String
s
=
jsonUtils
.
readJsonFile
(
fileName
);
List
<
HashMap
>
provinceListMap
=
JSONObject
.
parseArray
(
s
,
HashMap
.
class
);
List
<
HashMap
>
provinceListMap
=
JSONObject
.
parseArray
(
s
,
HashMap
.
class
);
...
@@ -66,8 +67,13 @@ public class KylinFreightChargeServiceImpl {
...
@@ -66,8 +67,13 @@ public class KylinFreightChargeServiceImpl {
String
productCode
=
kylinExpressModuleVo
.
getProductCode
().
toString
();
//快件类型码
String
productCode
=
kylinExpressModuleVo
.
getProductCode
().
toString
();
//快件类型码
String
adcode
=
(
String
)
adMap
.
get
(
"adcode"
);
String
adcode
=
(
String
)
adMap
.
get
(
"adcode"
);
String
dAddress
=
(
String
)
adMap
.
get
(
"name"
);
String
dAddress
=
(
String
)
adMap
.
get
(
"name"
);
hBody
.
put
(
"expressType"
,
productCode
);
// if (dProvince.equals("北京市") || dProvince.equals("天津市") || dProvince.equals("河北省")){
hBody
.
put
(
"dProvince"
,
dProvince
);
// hBody.put("expressType", "2");//快递类型
// }else {
// hBody.put("expressType", productCode);//快递类型
// }
hBody
.
put
(
"expressType"
,
productCode
);
//快递类型
hBody
.
put
(
"dProvince"
,
dProvince
);
//省
hBody
.
put
(
"dCity"
,
dCity
);
hBody
.
put
(
"dCity"
,
dCity
);
hBody
.
put
(
"dAddress"
,
dAddress
);
hBody
.
put
(
"dAddress"
,
dAddress
);
KylinFreightChargeDao
kylinFreightCharge
=
KylinFreightChargeDao
.
getNew
();
KylinFreightChargeDao
kylinFreightCharge
=
KylinFreightChargeDao
.
getNew
();
...
@@ -84,6 +90,15 @@ public class KylinFreightChargeServiceImpl {
...
@@ -84,6 +90,15 @@ public class KylinFreightChargeServiceImpl {
kylinFreightCharge
.
setAdname
(
dAddress
);
kylinFreightCharge
.
setAdname
(
dAddress
);
kylinFreightCharge
.
setAdcode
(
adcode
);
kylinFreightCharge
.
setAdcode
(
adcode
);
String
price
=
map
.
get
(
"price"
);
String
price
=
map
.
get
(
"price"
);
if
(
price
.
equals
(
"0元"
)){
hBody
.
put
(
"expressType"
,
"2"
);
//快递类型
// 生成签名并请求
String
SFresult
=
shunfengSignUtils
.
generateSignatureAndRequestNew
(
hBody
,
"/public/order/v1/getFreight"
);
hashMap
=
JsonUtils
.
fromJson
(
SFresult
,
HashMap
.
class
);
HashMap
<
String
,
String
>
SFmap
=
(
HashMap
<
String
,
String
>)
hashMap
.
get
(
"result"
);
price
=
SFmap
.
get
(
"price"
);
}
String
p
=
price
.
replace
(
"元"
,
".00"
);
String
p
=
price
.
replace
(
"元"
,
".00"
);
kylinFreightCharge
.
setPrice
(
p
);
kylinFreightCharge
.
setPrice
(
p
);
kylinFreightCharge
.
setBusinessType
(
map
.
get
(
"businessType"
));
kylinFreightCharge
.
setBusinessType
(
map
.
get
(
"businessType"
));
...
...
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