Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
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
haoban3.0
haoban-manage3.0
Commits
7fc0ca46
Commit
7fc0ca46
authored
Apr 13, 2020
by
fudahua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
同步优化初步1
parent
084fb540
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
38 deletions
+11
-38
dubbo-haoban-manage-service.xml
...ervice/src/main/resources/dubbo-haoban-manage-service.xml
+3
-0
SyncDealContoller.java
...m/gic/haoban/manage/web/controller/SyncDealContoller.java
+5
-38
dubbo-haoban-manage-web.xml
...3-web/src/main/webapp/WEB-INF/dubbo-haoban-manage-web.xml
+3
-0
No files found.
haoban-manage3-service/src/main/resources/dubbo-haoban-manage-service.xml
View file @
7fc0ca46
...
@@ -37,6 +37,9 @@
...
@@ -37,6 +37,9 @@
<dubbo:service
interface=
"com.gic.haoban.manage.api.service.DictApiService"
ref=
"dictApiServiceImpl"
timeout=
"10000"
/>
<dubbo:service
interface=
"com.gic.haoban.manage.api.service.DictApiService"
ref=
"dictApiServiceImpl"
timeout=
"10000"
/>
<dubbo:service
interface=
"com.gic.haoban.manage.api.service.AuditApiService"
ref=
"auditApiServiceImpl"
timeout=
"10000"
/>
<dubbo:service
interface=
"com.gic.haoban.manage.api.service.AuditApiService"
ref=
"auditApiServiceImpl"
timeout=
"10000"
/>
<dubbo:service
interface=
"com.gic.haoban.manage.api.service.DealSyncOperationApiService"
ref=
"dealSyncOperationApiServiceImpl"
timeout=
"10000"
/>
<dubbo:reference
interface=
"com.gic.enterprise.api.service.DepartmentService"
id=
"gicDepartmentService"
/>
<dubbo:reference
interface=
"com.gic.enterprise.api.service.DepartmentService"
id=
"gicDepartmentService"
/>
<dubbo:reference
interface=
"com.gic.wechat.api.service.qywx.QywxDepartmentApiService"
id=
"qywxDepartmentApiService"
/>
<dubbo:reference
interface=
"com.gic.wechat.api.service.qywx.QywxDepartmentApiService"
id=
"qywxDepartmentApiService"
/>
...
...
haoban-manage3-web/src/main/java/com/gic/haoban/manage/web/controller/SyncDealContoller.java
View file @
7fc0ca46
package
com
.
gic
.
haoban
.
manage
.
web
.
controller
;
package
com
.
gic
.
haoban
.
manage
.
web
.
controller
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONArray
;
import
com.gic.api.base.commons.Page
;
import
com.gic.clerk.api.dto.ClerkDTO
;
import
com.gic.clerk.api.dto.ClerkListDTO
;
import
com.gic.clerk.api.service.ClerkService
;
import
com.gic.clerk.api.service.ClerkService
;
import
com.gic.enterprise.api.dto.EnterpriseDTO
;
import
com.gic.enterprise.api.dto.GicTreeDTO
;
import
com.gic.enterprise.api.dto.StoreDTO
;
import
com.gic.enterprise.api.service.EnterpriseService
;
import
com.gic.enterprise.api.service.EnterpriseService
;
import
com.gic.enterprise.api.service.StoreGroupService
;
import
com.gic.enterprise.api.service.StoreGroupService
;
import
com.gic.enterprise.api.service.StoreService
;
import
com.gic.enterprise.api.service.StoreService
;
import
com.gic.haoban.base.api.common.BasePageInfo
;
import
com.gic.haoban.base.api.common.Constant
;
import
com.gic.haoban.base.api.common.PageResult
;
import
com.gic.haoban.base.api.common.ServiceResponse
;
import
com.gic.haoban.common.utils.EntityUtil
;
import
com.gic.haoban.common.utils.HaobanResponse
;
import
com.gic.haoban.common.utils.HaobanResponse
;
import
com.gic.haoban.manage.api.dto.DepartmentDTO
;
import
com.gic.haoban.manage.api.service.DealSyncOperationApiService
;
import
com.gic.haoban.manage.api.dto.StaffDTO
;
import
com.gic.haoban.manage.api.dto.StaffDepartmentRelatedDTO
;
import
com.gic.haoban.manage.api.service.DepartmentApiService
;
import
com.gic.haoban.manage.api.service.DepartmentApiService
;
import
com.gic.haoban.manage.api.service.StaffApiService
;
import
com.gic.haoban.manage.api.service.StaffApiService
;
import
com.gic.haoban.manage.api.service.StaffDepartmentRelatedApiService
;
import
com.gic.haoban.manage.api.service.StaffDepartmentRelatedApiService
;
import
com.gic.haoban.manage.web.auth.AuthRequestUtil
;
import
com.gic.haoban.manage.web.auth.AuthRequestUtil
;
import
com.gic.haoban.manage.web.errCode.HaoBanErrCode
;
import
com.gic.haoban.manage.web.errCode.HaoBanErrCode
;
import
com.gic.haoban.manage.web.qo.DepartmentAddQO
;
import
com.gic.haoban.manage.web.qo.DepartmentEditQO
;
import
com.gic.haoban.manage.web.qo.SyncDealQO
;
import
com.gic.haoban.manage.web.qo.SyncDealQO
;
import
com.gic.haoban.manage.web.qo.SyncDepartmentQO
;
import
com.gic.haoban.manage.web.thread.SyncDepartmentThread
;
import
com.gic.haoban.manage.web.vo.DepartmentVO
;
import
com.gic.haoban.manage.web.vo.LoginVO
;
import
com.gic.haoban.manage.web.vo.LoginVO
;
import
com.gic.redis.data.util.RedisUtil
;
import
com.gic.redis.data.util.RedisUtil
;
import
org.apache.commons.lang.StringUtils
;
import
org.slf4j.Logger
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -43,8 +22,6 @@ import org.springframework.web.bind.annotation.RequestMapping;
...
@@ -43,8 +22,6 @@ import org.springframework.web.bind.annotation.RequestMapping;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.*
;
@RestController
@RestController
public
class
SyncDealContoller
extends
WebBaseController
{
public
class
SyncDealContoller
extends
WebBaseController
{
...
@@ -67,6 +44,9 @@ public class SyncDealContoller extends WebBaseController {
...
@@ -67,6 +44,9 @@ public class SyncDealContoller extends WebBaseController {
@Autowired
@Autowired
private
StaffDepartmentRelatedApiService
staffDepartmentRelatedApiService
;
private
StaffDepartmentRelatedApiService
staffDepartmentRelatedApiService
;
@Autowired
private
DealSyncOperationApiService
dealSyncOperationApiService
;
@RequestMapping
(
"department-sync"
)
@RequestMapping
(
"department-sync"
)
@ResponseBody
@ResponseBody
...
@@ -77,20 +57,7 @@ public class SyncDealContoller extends WebBaseController {
...
@@ -77,20 +57,7 @@ public class SyncDealContoller extends WebBaseController {
if
(
RedisUtil
.
getCache
(
key
)
!=
null
)
{
if
(
RedisUtil
.
getCache
(
key
)
!=
null
)
{
return
resultResponse
(
HaoBanErrCode
.
ERR_10011
);
return
resultResponse
(
HaoBanErrCode
.
ERR_10011
);
}
}
Object
editDepartmentObject
=
null
;
dealSyncOperationApiService
.
dealDepartment
(
"111"
,
login
.
getWxEnterpriseId
(),
qo
.
getAddDepartment
(),
qo
.
getEditDepartment
());
Object
addDepartmentObject
=
null
;
String
editDepartment
=
""
;
String
addDepartment
=
""
;
String
delDepartmentIds
=
""
;
logger
.
info
(
"【部门同步】args={}"
,
JSON
.
toJSONString
(
args
));
if
(
args
!=
null
)
{
editDepartmentObject
=
args
.
getEditDepartment
();
addDepartmentObject
=
args
.
getAddDepartment
();
editDepartment
=
JSON
.
toJSONString
(
editDepartmentObject
);
addDepartment
=
JSON
.
toJSONString
(
addDepartmentObject
);
}
RedisUtil
.
setCache
(
key
,
1
,
3600
l
);
new
SyncDepartmentThread
(
this
,
editDepartment
,
delDepartmentIds
,
addDepartment
,
key
).
start
();
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
key
);
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
key
);
...
...
haoban-manage3-web/src/main/webapp/WEB-INF/dubbo-haoban-manage-web.xml
View file @
7fc0ca46
...
@@ -52,4 +52,7 @@
...
@@ -52,4 +52,7 @@
<dubbo:reference
interface=
"com.gic.wechat.token.api.service.QywxTokenManageService"
id=
"qywxTokenManageService"
/>
<dubbo:reference
interface=
"com.gic.wechat.token.api.service.QywxTokenManageService"
id=
"qywxTokenManageService"
/>
<dubbo:reference
interface=
"com.gic.haoban.manage.api.service.DealSyncOperationApiService"
id=
"dealSyncOperationApiService"
/>
</beans>
</beans>
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