Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gic-store
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
base_platform_enterprise
gic-store
Commits
e0be2ec0
Commit
e0be2ec0
authored
Nov 12, 2019
by
zhiwj
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加门店日志
parent
924e783f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
12 deletions
+23
-12
StoreController.java
...in/java/com/gic/store/web/controller/StoreController.java
+23
-12
No files found.
gic-store-web/src/main/java/com/gic/store/web/controller/StoreController.java
View file @
e0be2ec0
...
...
@@ -8,6 +8,7 @@ import com.gic.commons.webapi.reponse.RestResponse;
import
com.gic.download.utils.log.LogUtils
;
import
com.gic.enterprise.error.ErrorCode
;
import
com.gic.enterprise.response.EnterpriseRestResponse
;
import
com.gic.enterprise.utils.ResultControllerUtils
;
import
com.gic.enterprise.utils.UserDetailUtils
;
import
com.gic.log.api.service.LogApiService
;
import
com.gic.redis.data.util.RedisUtil
;
...
...
@@ -18,6 +19,7 @@ import com.gic.store.dto.*;
import
com.gic.store.service.StoreApiService
;
import
com.gic.store.service.StoreAuthorizationApiService
;
import
com.gic.store.service.StoreDictApiService
;
import
com.gic.store.service.StoreLogApiService
;
import
com.gic.store.utils.StoreRedisKeyUtils
;
import
com.gic.store.web.qo.PageQO
;
import
com.gic.store.web.qo.store.StoreQO
;
...
...
@@ -35,9 +37,7 @@ import org.springframework.web.bind.annotation.ResponseBody;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
* @author zhiwj
...
...
@@ -54,6 +54,8 @@ public class StoreController {
private
StoreDictApiService
storeDictApiService
;
@Autowired
private
LogApiService
logApiService
;
@Autowired
private
StoreLogApiService
storeLogApiService
;
@RequestMapping
(
"/save-store"
)
public
RestResponse
saveOrUpdate
(
@Validated
({
StoreQO
.
SaveValidView
.
class
})
StoreQO
storeQO
)
{
...
...
@@ -184,17 +186,26 @@ public class StoreController {
return
EnterpriseRestResponse
.
failure
(
response
);
}
// @RequestMapping("list-store-log")
// public RestResponse listStoreLog(Integer storeId, PageQO pageQO) {
// Page page = new Page(pageQO.getCurrentPage(), pageQO.getPageSize());
// Map<String, Object> params = new HashMap<>();
// params.put("relationId", storeId);
// page.setParams(params);
// ServiceResponse response = this.logApiService.listSystemSetLog(page);
// if (response.isSuccess()) {
// return RestResponse.success(response.getResult());
// }
// return EnterpriseRestResponse.failure(response);
// }
@RequestMapping
(
"list-store-log"
)
public
RestResponse
listStoreLog
(
Integer
storeId
,
PageQO
pageQO
)
{
Page
page
=
new
Page
(
pageQO
.
getCurrentPage
(),
pageQO
.
getPageSize
());
Map
<
String
,
Object
>
params
=
new
HashMap
<>();
params
.
put
(
"relationId"
,
storeId
);
page
.
setParams
(
params
);
ServiceResponse
response
=
this
.
logApiService
.
listSystemSetLog
(
page
);
if
(
response
.
isSuccess
())
{
return
RestResponse
.
success
(
response
.
getResult
());
}
return
EnterpriseRestResponse
.
failure
(
response
);
public
RestResponse
listStoreLog
(
com
.
gic
.
enterprise
.
qo
.
PageQO
pageQO
,
String
content
,
Integer
reason
,
Integer
logType
)
{
StoreLogDTO
storeLog
=
new
StoreLogDTO
();
storeLog
.
setContent
(
content
);
storeLog
.
setReason
(
reason
);
storeLog
.
setLogType
(
logType
);
ServiceResponse
<
Page
<
StoreLogDTO
>>
response
=
storeLogApiService
.
listStoreLog
(
storeLog
,
pageQO
);
return
ResultControllerUtils
.
commonResult
(
response
);
}
@RequestMapping
(
"bulk-update-store"
)
...
...
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