|
@@ -1,82 +1,89 @@
|
|
|
-package cn.com.qmth.examcloud.task.api.client;
|
|
|
-
|
|
|
-import org.springframework.beans.factory.annotation.Autowired;
|
|
|
-import org.springframework.stereotype.Service;
|
|
|
-import org.springframework.web.client.RestTemplate;
|
|
|
-
|
|
|
-import cn.com.qmth.examcloud.commons.web.redis.RedisClient;
|
|
|
-import cn.com.qmth.examcloud.task.api.DataSyncCloudService;
|
|
|
-import cn.com.qmth.examcloud.task.api.request.SyncCourseReq;
|
|
|
-import cn.com.qmth.examcloud.task.api.request.SyncExamReq;
|
|
|
-import cn.com.qmth.examcloud.task.api.request.SyncExamStudentReq;
|
|
|
-import cn.com.qmth.examcloud.task.api.request.SyncOrgReq;
|
|
|
-import cn.com.qmth.examcloud.task.api.request.SyncSpecialtyReq;
|
|
|
-import cn.com.qmth.examcloud.task.api.request.SyncStudentReq;
|
|
|
-import cn.com.qmth.examcloud.task.api.response.SyncCourseResp;
|
|
|
-import cn.com.qmth.examcloud.task.api.response.SyncExamResp;
|
|
|
-import cn.com.qmth.examcloud.task.api.response.SyncExamStudentResp;
|
|
|
-import cn.com.qmth.examcloud.task.api.response.SyncOrgResp;
|
|
|
-import cn.com.qmth.examcloud.task.api.response.SyncSpecialtyResp;
|
|
|
-import cn.com.qmth.examcloud.task.api.response.SyncStudentResp;
|
|
|
-
|
|
|
-/**
|
|
|
- * 类注释
|
|
|
- *
|
|
|
- * @author WANGWEI
|
|
|
- * @date 2018年8月2日
|
|
|
- * @Copyright (c) 2018-? http://qmth.com.cn All Rights Reserved.
|
|
|
- */
|
|
|
-@Service
|
|
|
-public class DataSyncCloudServiceClient extends TaskCloudClientSupport
|
|
|
- implements
|
|
|
- DataSyncCloudService {
|
|
|
-
|
|
|
- private static final long serialVersionUID = -2880611326177571371L;
|
|
|
-
|
|
|
- @Autowired
|
|
|
- RestTemplate restTemplate;
|
|
|
-
|
|
|
- @Autowired
|
|
|
- private RedisClient redisClient;
|
|
|
-
|
|
|
- @Override
|
|
|
- protected RedisClient getRedisClient() {
|
|
|
- return redisClient;
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- protected RestTemplate getRestTemplate() {
|
|
|
- return restTemplate;
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public SyncCourseResp syncCourse(SyncCourseReq req) {
|
|
|
- return post("dataSync/syncCourse", req, SyncCourseResp.class);
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public SyncOrgResp syncOrg(SyncOrgReq req) {
|
|
|
- return post("dataSync/syncOrg", req, SyncOrgResp.class);
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public SyncStudentResp syncStudent(SyncStudentReq req) {
|
|
|
- return post("dataSync/syncStudent", req, SyncStudentResp.class);
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public SyncSpecialtyResp syncSpecialty(SyncSpecialtyReq req) {
|
|
|
- return post("dataSync/syncSpecialty", req, SyncSpecialtyResp.class);
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public SyncExamResp syncExam(SyncExamReq req) {
|
|
|
- return post("dataSync/syncExam", req, SyncExamResp.class);
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public SyncExamStudentResp syncExamStudent(SyncExamStudentReq req) {
|
|
|
- return post("dataSync/syncExamStudent", req, SyncExamStudentResp.class);
|
|
|
- }
|
|
|
-
|
|
|
-}
|
|
|
+package cn.com.qmth.examcloud.task.api.client;
|
|
|
+
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.stereotype.Service;
|
|
|
+import org.springframework.web.client.RestTemplate;
|
|
|
+
|
|
|
+import cn.com.qmth.examcloud.commons.web.redis.RedisClient;
|
|
|
+import cn.com.qmth.examcloud.task.api.DataSyncCloudService;
|
|
|
+import cn.com.qmth.examcloud.task.api.request.SyncCourseReq;
|
|
|
+import cn.com.qmth.examcloud.task.api.request.SyncExamReq;
|
|
|
+import cn.com.qmth.examcloud.task.api.request.SyncExamStudentReq;
|
|
|
+import cn.com.qmth.examcloud.task.api.request.SyncOrgReq;
|
|
|
+import cn.com.qmth.examcloud.task.api.request.SyncSpecialtyReq;
|
|
|
+import cn.com.qmth.examcloud.task.api.request.SyncStudentReq;
|
|
|
+import cn.com.qmth.examcloud.task.api.request.SyncUserReq;
|
|
|
+import cn.com.qmth.examcloud.task.api.response.SyncCourseResp;
|
|
|
+import cn.com.qmth.examcloud.task.api.response.SyncExamResp;
|
|
|
+import cn.com.qmth.examcloud.task.api.response.SyncExamStudentResp;
|
|
|
+import cn.com.qmth.examcloud.task.api.response.SyncOrgResp;
|
|
|
+import cn.com.qmth.examcloud.task.api.response.SyncSpecialtyResp;
|
|
|
+import cn.com.qmth.examcloud.task.api.response.SyncStudentResp;
|
|
|
+import cn.com.qmth.examcloud.task.api.response.SyncUserResp;
|
|
|
+
|
|
|
+/**
|
|
|
+ * 类注释
|
|
|
+ *
|
|
|
+ * @author WANGWEI
|
|
|
+ * @date 2018年8月2日
|
|
|
+ * @Copyright (c) 2018-? http://qmth.com.cn All Rights Reserved.
|
|
|
+ */
|
|
|
+@Service
|
|
|
+public class DataSyncCloudServiceClient extends TaskCloudClientSupport
|
|
|
+ implements
|
|
|
+ DataSyncCloudService {
|
|
|
+
|
|
|
+ private static final long serialVersionUID = -2880611326177571371L;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ RestTemplate restTemplate;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private RedisClient redisClient;
|
|
|
+
|
|
|
+ @Override
|
|
|
+ protected RedisClient getRedisClient() {
|
|
|
+ return redisClient;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ protected RestTemplate getRestTemplate() {
|
|
|
+ return restTemplate;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public SyncCourseResp syncCourse(SyncCourseReq req) {
|
|
|
+ return post("dataSync/syncCourse", req, SyncCourseResp.class);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public SyncOrgResp syncOrg(SyncOrgReq req) {
|
|
|
+ return post("dataSync/syncOrg", req, SyncOrgResp.class);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public SyncStudentResp syncStudent(SyncStudentReq req) {
|
|
|
+ return post("dataSync/syncStudent", req, SyncStudentResp.class);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public SyncSpecialtyResp syncSpecialty(SyncSpecialtyReq req) {
|
|
|
+ return post("dataSync/syncSpecialty", req, SyncSpecialtyResp.class);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public SyncExamResp syncExam(SyncExamReq req) {
|
|
|
+ return post("dataSync/syncExam", req, SyncExamResp.class);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public SyncExamStudentResp syncExamStudent(SyncExamStudentReq req) {
|
|
|
+ return post("dataSync/syncExamStudent", req, SyncExamStudentResp.class);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public SyncUserResp syncUser(SyncUserReq req) {
|
|
|
+ return post("dataSync/syncUser", req, SyncUserResp.class);
|
|
|
+ }
|
|
|
+
|
|
|
+}
|