Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gxpt_ht
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
pseer
gxpt_ht
Commits
50b2df96
Commit
50b2df96
authored
Oct 19, 2023
by
吕明尚
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
工具类更改Impl类
parent
720140e5
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
67 additions
and
53 deletions
+67
-53
pom.xml
share-admin/pom.xml
+0
-41
application-dev.yml
share-admin/src/main/resources/application-dev.yml
+4
-0
pom.xml
share-system/pom.xml
+43
-0
MtOpJavaSDK-1.0-SNAPSHOT-sources.jar
.../src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT-sources.jar
+0
-0
MtOpJavaSDK-1.0-SNAPSHOT.jar
...e-system/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT.jar
+0
-0
README.md
share-system/src/lib/MtOpJavaSDK/README.md
+0
-0
MTService.java
...-system/src/main/java/share/system/service/MTService.java
+7
-0
MTServiceImpl.java
...rc/main/java/share/system/service/impl/MTServiceImpl.java
+13
-12
No files found.
share-admin/pom.xml
View file @
50b2df96
...
...
@@ -66,47 +66,6 @@
<artifactId>
hutool-all
</artifactId>
<version>
5.8.16
</version>
</dependency>
<!--美团SDK引入加相关依赖开始-->
<dependency>
<groupId>
MtOpJavaSDK
</groupId>
<artifactId>
MtOpJavaSDK
</artifactId>
<version>
1.0
</version>
<scope>
system
</scope>
<systemPath>
${project.basedir}/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT.jar
</systemPath>
</dependency>
<dependency>
<groupId>
MtOpJavaSDK-sources
</groupId>
<artifactId>
MtOpJavaSDK-sources
</artifactId>
<version>
1.0
</version>
<scope>
system
</scope>
<systemPath>
${project.basedir}/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT-sources.jar
</systemPath>
</dependency>
<dependency>
<groupId>
com.google.code.gson
</groupId>
<artifactId>
gson
</artifactId>
<version>
2.8.9
</version>
</dependency>
<dependency>
<groupId>
javax.validation
</groupId>
<artifactId>
validation-api
</artifactId>
<version>
2.0.1.Final
</version>
</dependency>
<dependency>
<groupId>
org.hibernate
</groupId>
<artifactId>
hibernate-validator
</artifactId>
<version>
6.1.0.Final
</version>
</dependency>
<dependency>
<groupId>
org.glassfish
</groupId>
<artifactId>
javax.el
</artifactId>
<version>
3.0.1-b11
</version>
</dependency>
<dependency>
<groupId>
org.slf4j
</groupId>
<artifactId>
slf4j-api
</artifactId>
<version>
1.7.25
</version>
</dependency>
<!--美团SDK引入加相关依赖结束-->
</dependencies>
<build>
...
...
share-admin/src/main/resources/application-dev.yml
View file @
50b2df96
...
...
@@ -170,3 +170,7 @@ xss:
excludes
:
/system/notice
# 匹配链接
urlPatterns
:
/system/*,/monitor/*,/tool/*
meituan
:
developerId
:
123456
signKey
:
abcdefghijklmnopqrstuvwxyz
appAuthToken
:
abcdefghijklmnopqrstuvwxyz
share-system/pom.xml
View file @
50b2df96
...
...
@@ -58,6 +58,48 @@
<version>
0.7
</version>
</dependency>
<!--美团SDK引入加相关依赖开始-->
<dependency>
<groupId>
MtOpJavaSDK
</groupId>
<artifactId>
MtOpJavaSDK
</artifactId>
<version>
1.0
</version>
<scope>
system
</scope>
<systemPath>
${project.basedir}/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT.jar
</systemPath>
</dependency>
<dependency>
<groupId>
MtOpJavaSDK-sources
</groupId>
<artifactId>
MtOpJavaSDK-sources
</artifactId>
<version>
1.0
</version>
<scope>
system
</scope>
<systemPath>
${project.basedir}/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT-sources.jar
</systemPath>
</dependency>
<dependency>
<groupId>
com.google.code.gson
</groupId>
<artifactId>
gson
</artifactId>
<version>
2.8.9
</version>
</dependency>
<dependency>
<groupId>
javax.validation
</groupId>
<artifactId>
validation-api
</artifactId>
<version>
2.0.1.Final
</version>
</dependency>
<dependency>
<groupId>
org.hibernate
</groupId>
<artifactId>
hibernate-validator
</artifactId>
<version>
6.1.0.Final
</version>
</dependency>
<dependency>
<groupId>
org.glassfish
</groupId>
<artifactId>
javax.el
</artifactId>
<version>
3.0.1-b11
</version>
</dependency>
<dependency>
<groupId>
org.slf4j
</groupId>
<artifactId>
slf4j-api
</artifactId>
<version>
1.7.25
</version>
</dependency>
<!--美团SDK引入加相关依赖结束-->
</dependencies>
</project>
\ No newline at end of file
share-
admin
/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT-sources.jar
→
share-
system
/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT-sources.jar
View file @
50b2df96
File moved
share-
admin
/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT.jar
→
share-
system
/src/lib/MtOpJavaSDK/MtOpJavaSDK-1.0-SNAPSHOT.jar
View file @
50b2df96
File moved
share-
admin
/src/lib/MtOpJavaSDK/README.md
→
share-
system
/src/lib/MtOpJavaSDK/README.md
View file @
50b2df96
File moved
share-system/src/main/java/share/system/service/MTService.java
0 → 100644
View file @
50b2df96
package
share
.
system
.
service
;
public
interface
MTService
{
public
String
VerificationVouchers
(
String
code
,
int
num
);
public
String
revoke
(
String
ERPId
,
String
ERPName
,
String
couponCode
);
}
share-
admin/src/main/java/share/utils/MTUti
l.java
→
share-
system/src/main/java/share/system/service/impl/MTServiceImp
l.java
View file @
50b2df96
package
share
.
utils
;
package
share
.
system
.
service
.
impl
;
import
com.meituan.sdk.DefaultMeituanClient
;
import
com.meituan.sdk.MeituanClient
;
...
...
@@ -11,17 +9,19 @@ import com.meituan.sdk.model.tuangouNg.coupon.couponCancel.CouponCancelResponse;
import
com.meituan.sdk.model.tuangouNg.coupon.msSuperConsume.MsSuperConsumeRequest
;
import
com.meituan.sdk.model.tuangouNg.coupon.msSuperConsume.MsSuperConsumeResponse
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.stereotype.Service
;
import
share.system.service.MTService
;
public
class
MTUtil
{
@Value
(
"${meituan.developerId}"
)
private
Long
developerId
;
@Service
public
class
MTServiceImpl
implements
MTService
{
@Value
(
"${meituan.signKey}"
)
private
String
signKey
;
@Value
(
"${meituan.appAuthToken}"
)
private
String
appAuthToken
;
//执行验券
public
String
VerificationVouchers
(
String
code
,
int
num
){
@Value
(
"${meituan.developerId}"
)
private
Long
developerId
;
@Override
public
String
VerificationVouchers
(
String
code
,
int
num
)
{
//developerId 服务商身份标识 signKey 服务商签名密钥
MeituanClient
meituanClient
=
DefaultMeituanClient
.
builder
(
developerId
,
signKey
).
build
();
MsSuperConsumeRequest
msSuperConsumeRequest
=
new
MsSuperConsumeRequest
();
...
...
@@ -43,9 +43,10 @@ public class MTUtil {
}
return
null
;
}
//
public
String
revoke
(
String
ERPId
,
String
ERPName
,
String
couponCode
){
MeituanClient
meituanClient
=
DefaultMeituanClient
.
builder
(
developerId
,
signKey
).
build
();
@Override
public
String
revoke
(
String
ERPId
,
String
ERPName
,
String
couponCode
)
{
MeituanClient
meituanClient
=
DefaultMeituanClient
.
builder
(
developerId
,
signKey
).
build
();
CouponCancelRequest
couponCancelRequest
=
new
CouponCancelRequest
();
couponCancelRequest
.
setEId
(
ERPId
);
couponCancelRequest
.
setEName
(
ERPName
);
...
...
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