Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
Eladmin
Commits
e1366ee4
"eladmin-common/vscode:/vscode.git/clone" did not exist on "784d670c54da9fdc838646383e02498d0299534c"
Commit
e1366ee4
authored
Oct 29, 2019
by
dqjdda
Browse files
菜单修改
parent
cad0c08c
Changes
23
Expand all
Show whitespace changes
Inline
Side-by-side
eladmin-tools/src/main/java/me/zhengjie/rest/LocalStorageController.java
View file @
e1366ee4
...
@@ -30,21 +30,21 @@ public class LocalStorageController {
...
@@ -30,21 +30,21 @@ public class LocalStorageController {
@ApiOperation
(
"查询文件"
)
@ApiOperation
(
"查询文件"
)
@GetMapping
@GetMapping
@PreAuthorize
(
"hasAnyRole('
ADMIN
','LOCALSTORAGE_ALL','LOCALSTORAGE_SELECT')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','LOCALSTORAGE_ALL','LOCALSTORAGE_SELECT')"
)
public
ResponseEntity
getLocalStorages
(
LocalStorageQueryCriteria
criteria
,
Pageable
pageable
){
public
ResponseEntity
getLocalStorages
(
LocalStorageQueryCriteria
criteria
,
Pageable
pageable
){
return
new
ResponseEntity
<>(
localStorageService
.
queryAll
(
criteria
,
pageable
),
HttpStatus
.
OK
);
return
new
ResponseEntity
<>(
localStorageService
.
queryAll
(
criteria
,
pageable
),
HttpStatus
.
OK
);
}
}
@ApiOperation
(
"上传文件"
)
@ApiOperation
(
"上传文件"
)
@PostMapping
@PostMapping
@PreAuthorize
(
"hasAnyRole('
ADMIN
','LOCALSTORAGE_ALL','LOCALSTORAGE_CREATE')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','LOCALSTORAGE_ALL','LOCALSTORAGE_CREATE')"
)
public
ResponseEntity
create
(
@RequestParam
String
name
,
@RequestParam
(
"file"
)
MultipartFile
file
){
public
ResponseEntity
create
(
@RequestParam
String
name
,
@RequestParam
(
"file"
)
MultipartFile
file
){
return
new
ResponseEntity
<>(
localStorageService
.
create
(
name
,
file
),
HttpStatus
.
CREATED
);
return
new
ResponseEntity
<>(
localStorageService
.
create
(
name
,
file
),
HttpStatus
.
CREATED
);
}
}
@ApiOperation
(
"修改文件"
)
@ApiOperation
(
"修改文件"
)
@PutMapping
@PutMapping
@PreAuthorize
(
"hasAnyRole('
ADMIN
','LOCALSTORAGE_ALL','LOCALSTORAGE_EDIT')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','LOCALSTORAGE_ALL','LOCALSTORAGE_EDIT')"
)
public
ResponseEntity
update
(
@Validated
@RequestBody
LocalStorage
resources
){
public
ResponseEntity
update
(
@Validated
@RequestBody
LocalStorage
resources
){
localStorageService
.
update
(
resources
);
localStorageService
.
update
(
resources
);
return
new
ResponseEntity
(
HttpStatus
.
NO_CONTENT
);
return
new
ResponseEntity
(
HttpStatus
.
NO_CONTENT
);
...
@@ -52,7 +52,7 @@ public class LocalStorageController {
...
@@ -52,7 +52,7 @@ public class LocalStorageController {
@ApiOperation
(
"删除文件"
)
@ApiOperation
(
"删除文件"
)
@DeleteMapping
(
value
=
"/{id}"
)
@DeleteMapping
(
value
=
"/{id}"
)
@PreAuthorize
(
"hasAnyRole('
ADMIN
','LOCALSTORAGE_ALL','LOCALSTORAGE_DELETE')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','LOCALSTORAGE_ALL','LOCALSTORAGE_DELETE')"
)
public
ResponseEntity
delete
(
@PathVariable
Long
id
){
public
ResponseEntity
delete
(
@PathVariable
Long
id
){
localStorageService
.
delete
(
id
);
localStorageService
.
delete
(
id
);
return
new
ResponseEntity
(
HttpStatus
.
OK
);
return
new
ResponseEntity
(
HttpStatus
.
OK
);
...
...
eladmin-tools/src/main/java/me/zhengjie/rest/PictureController.java
View file @
e1366ee4
...
@@ -32,7 +32,7 @@ public class PictureController {
...
@@ -32,7 +32,7 @@ public class PictureController {
}
}
@Log
(
"查询图片"
)
@Log
(
"查询图片"
)
@PreAuthorize
(
"hasAnyRole('
ADMIN
','PICTURE_ALL','PICTURE_SELECT')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','PICTURE_ALL','PICTURE_SELECT')"
)
@GetMapping
@GetMapping
@ApiOperation
(
"查询图片"
)
@ApiOperation
(
"查询图片"
)
public
ResponseEntity
getRoles
(
PictureQueryCriteria
criteria
,
Pageable
pageable
){
public
ResponseEntity
getRoles
(
PictureQueryCriteria
criteria
,
Pageable
pageable
){
...
@@ -40,7 +40,7 @@ public class PictureController {
...
@@ -40,7 +40,7 @@ public class PictureController {
}
}
@Log
(
"上传图片"
)
@Log
(
"上传图片"
)
@PreAuthorize
(
"hasAnyRole('
ADMIN
','PICTURE_ALL','PICTURE_UPLOAD')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','PICTURE_ALL','PICTURE_UPLOAD')"
)
@PostMapping
@PostMapping
@ApiOperation
(
"上传图片"
)
@ApiOperation
(
"上传图片"
)
public
ResponseEntity
upload
(
@RequestParam
MultipartFile
file
){
public
ResponseEntity
upload
(
@RequestParam
MultipartFile
file
){
...
@@ -55,7 +55,7 @@ public class PictureController {
...
@@ -55,7 +55,7 @@ public class PictureController {
@Log
(
"删除图片"
)
@Log
(
"删除图片"
)
@ApiOperation
(
"删除图片"
)
@ApiOperation
(
"删除图片"
)
@PreAuthorize
(
"hasAnyRole('
ADMIN
','PICTURE_ALL','PICTURE_DELETE')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','PICTURE_ALL','PICTURE_DELETE')"
)
@DeleteMapping
(
value
=
"/{id}"
)
@DeleteMapping
(
value
=
"/{id}"
)
public
ResponseEntity
delete
(
@PathVariable
Long
id
)
{
public
ResponseEntity
delete
(
@PathVariable
Long
id
)
{
pictureService
.
delete
(
pictureService
.
findById
(
id
));
pictureService
.
delete
(
pictureService
.
findById
(
id
));
...
@@ -64,7 +64,7 @@ public class PictureController {
...
@@ -64,7 +64,7 @@ public class PictureController {
@Log
(
"多选删除图片"
)
@Log
(
"多选删除图片"
)
@ApiOperation
(
"多选删除图片"
)
@ApiOperation
(
"多选删除图片"
)
@PreAuthorize
(
"hasAnyRole('
ADMIN
','PICTURE_ALL','PICTURE_DELETE')"
)
@PreAuthorize
(
"hasAnyRole('
admin
','PICTURE_ALL','PICTURE_DELETE')"
)
@DeleteMapping
@DeleteMapping
public
ResponseEntity
deleteAll
(
@RequestBody
Long
[]
ids
)
{
public
ResponseEntity
deleteAll
(
@RequestBody
Long
[]
ids
)
{
pictureService
.
deleteAll
(
ids
);
pictureService
.
deleteAll
(
ids
);
...
...
sql/eladmin.sql
deleted
100644 → 0
View file @
cad0c08c
This diff is collapsed.
Click to expand it.
Prev
1
2
Next
Write
Preview
Supports
Markdown
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