-
-
Notifications
You must be signed in to change notification settings - Fork 9.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
release 1.1.1 Co-authored-by: John Niang <[email protected]>
- Loading branch information
Showing
43 changed files
with
128 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
51 changes: 51 additions & 0 deletions
51
src/main/java/run/halo/app/controller/content/api/PhotoController.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
package run.halo.app.controller.content.api; | ||
|
||
import org.springframework.data.domain.Page; | ||
import org.springframework.data.domain.Pageable; | ||
import org.springframework.data.domain.Sort; | ||
import org.springframework.data.web.PageableDefault; | ||
import org.springframework.data.web.SortDefault; | ||
import org.springframework.web.bind.annotation.GetMapping; | ||
import org.springframework.web.bind.annotation.RequestMapping; | ||
import org.springframework.web.bind.annotation.RestController; | ||
import run.halo.app.model.dto.PhotoDTO; | ||
import run.halo.app.model.params.PhotoQuery; | ||
import run.halo.app.service.PhotoService; | ||
|
||
import java.util.List; | ||
|
||
import static org.springframework.data.domain.Sort.Direction.DESC; | ||
|
||
/** | ||
* Content photo controller. | ||
* | ||
* @author ryanwang | ||
* @date 2019-09-21 | ||
*/ | ||
@RestController("ApiContentPhotoController") | ||
@RequestMapping("/api/content/photos") | ||
public class PhotoController { | ||
|
||
private final PhotoService photoService; | ||
|
||
public PhotoController(PhotoService photoService) { | ||
this.photoService = photoService; | ||
} | ||
|
||
/** | ||
* List all photos | ||
* | ||
* @param sort sort | ||
* @return all of photos | ||
*/ | ||
@GetMapping(value = "latest") | ||
public List<PhotoDTO> listPhotos(@SortDefault(sort = "updateTime", direction = Sort.Direction.DESC) Sort sort) { | ||
return photoService.listDtos(sort); | ||
} | ||
|
||
@GetMapping | ||
public Page<PhotoDTO> pageBy(@PageableDefault(sort = "updateTime", direction = DESC) Pageable pageable, | ||
PhotoQuery photoQuery) { | ||
return photoService.pageDtosBy(pageable, photoQuery); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ces/admin/css/chunk-38e065ca.8f4ac180.css → ...ces/admin/css/chunk-0cc826ee.d94071d6.css
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
<!DOCTYPE html><html lang=zh-cmn-Hans><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><meta name=robots content=noindex,nofllow><meta name=generator content=Halo><link rel=icon href=/logo.png><title>Halo Dashboard</title><style>#loader{position:absolute;top:0;right:0;bottom:0;left:0;margin:auto;border:solid 3px #e5e5e5;border-top-color:#333;border-radius:50%;width:30px;height:30px;animation:spin .6s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}</style><link href=/css/chunk-00feb227.84211a72.css rel=prefetch><link href=/css/chunk-09a78eda.0e33e21a.css rel=prefetch><link href=/css/chunk-1922a40e.f4349937.css rel=prefetch><link href=/css/chunk-1e303e8c.46a67c57.css rel=prefetch><link href=/css/chunk-2cf7efe4.0e33e21a.css rel=prefetch><link href=/css/chunk-36ac1a23.0becaf8c.css rel=prefetch><link href=/css/chunk-38e065ca.8f4ac180.css rel=prefetch><link href=/css/chunk-59456d4e.afea7f86.css rel=prefetch><link href=/css/chunk-afda5a22.041fa426.css rel=prefetch><link href=/css/chunk-f1c576e6.b38ba436.css rel=prefetch><link href=/css/fail.809a6bc5.css rel=prefetch><link href=/js/chunk-00feb227.2c332405.js rel=prefetch><link href=/js/chunk-09a78eda.ecea3d8e.js rel=prefetch><link href=/js/chunk-0ba750a2.c7f7fd0b.js rel=prefetch><link href=/js/chunk-13882457.562b4d43.js rel=prefetch><link href=/js/chunk-1922a40e.3378b225.js rel=prefetch><link href=/js/chunk-1e303e8c.f696700e.js rel=prefetch><link href=/js/chunk-2cf7efe4.edad6794.js rel=prefetch><link href=/js/chunk-2d0b383e.6fd94865.js rel=prefetch><link href=/js/chunk-2d0b64bf.db02cecd.js rel=prefetch><link href=/js/chunk-2d0b8b03.818cca76.js rel=prefetch><link href=/js/chunk-2d0cf13d.02e642fe.js rel=prefetch><link href=/js/chunk-2d21a35c.cff39891.js rel=prefetch><link href=/js/chunk-2d228c74.3f60fbb2.js rel=prefetch><link href=/js/chunk-2d228d13.e7c565c8.js rel=prefetch><link href=/js/chunk-36ac1a23.36af80b4.js rel=prefetch><link href=/js/chunk-37a26d88.04a2a49e.js rel=prefetch><link href=/js/chunk-38e065ca.a9b9711f.js rel=prefetch><link href=/js/chunk-59456d4e.13903f8f.js rel=prefetch><link href=/js/chunk-664d53d7.4cc459ed.js rel=prefetch><link href=/js/chunk-6709ac89.606ab90b.js rel=prefetch><link href=/js/chunk-78dfb9ad.2fb3220c.js rel=prefetch><link href=/js/chunk-7f061eff.83785ccc.js rel=prefetch><link href=/js/chunk-afda5a22.464c5981.js rel=prefetch><link href=/js/chunk-b0eebb32.3d368473.js rel=prefetch><link href=/js/chunk-f1c576e6.04de3e8c.js rel=prefetch><link href=/js/fail.ef3c85c4.js rel=prefetch><link href=/css/app.ad52b47a.css rel=preload as=style><link href=/css/chunk-vendors.70dcf28e.css rel=preload as=style><link href=/js/app.0bb46c3a.js rel=preload as=script><link href=/js/chunk-vendors.8dff577d.js rel=preload as=script><link href=/css/chunk-vendors.70dcf28e.css rel=stylesheet><link href=/css/app.ad52b47a.css rel=stylesheet></head><body><noscript><strong>We're sorry but vue-antd-pro doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app><div id=loader></div></div><script src=/js/chunk-vendors.8dff577d.js></script><script src=/js/app.0bb46c3a.js></script></body></html> | ||
<!DOCTYPE html><html lang=zh-cmn-Hans><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><meta name=robots content=noindex,nofllow><meta name=generator content=Halo><link rel=icon href=/logo.png><title>Halo Dashboard</title><style>#loader{position:absolute;top:0;right:0;bottom:0;left:0;margin:auto;border:solid 3px #e5e5e5;border-top-color:#333;border-radius:50%;width:30px;height:30px;animation:spin .6s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}</style><link href=/css/chunk-00feb227.84211a72.css rel=prefetch><link href=/css/chunk-09a78eda.0e33e21a.css rel=prefetch><link href=/css/chunk-0cc826ee.d94071d6.css rel=prefetch><link href=/css/chunk-1922a40e.f4349937.css rel=prefetch><link href=/css/chunk-1e303e8c.46a67c57.css rel=prefetch><link href=/css/chunk-2cf7efe4.0e33e21a.css rel=prefetch><link href=/css/chunk-36ac1a23.0becaf8c.css rel=prefetch><link href=/css/chunk-59456d4e.afea7f86.css rel=prefetch><link href=/css/chunk-afda5a22.041fa426.css rel=prefetch><link href=/css/chunk-f1c576e6.b38ba436.css rel=prefetch><link href=/css/fail.809a6bc5.css rel=prefetch><link href=/js/chunk-00feb227.9a8da69e.js rel=prefetch><link href=/js/chunk-09a78eda.cc69abe1.js rel=prefetch><link href=/js/chunk-0ba750a2.1fe7a063.js rel=prefetch><link href=/js/chunk-0cc826ee.944fd5f4.js rel=prefetch><link href=/js/chunk-13882457.c82a4d82.js rel=prefetch><link href=/js/chunk-1922a40e.c260b56d.js rel=prefetch><link href=/js/chunk-1e303e8c.13b99962.js rel=prefetch><link href=/js/chunk-2cf7efe4.01e2d029.js rel=prefetch><link href=/js/chunk-2d0b383e.d5e906d0.js rel=prefetch><link href=/js/chunk-2d0b64bf.dc1f06bd.js rel=prefetch><link href=/js/chunk-2d0b8b03.44d2af44.js rel=prefetch><link href=/js/chunk-2d0cf13d.49fc8c5f.js rel=prefetch><link href=/js/chunk-2d21a35c.82f5da19.js rel=prefetch><link href=/js/chunk-2d228c74.931307e8.js rel=prefetch><link href=/js/chunk-2d228d13.c03e48e4.js rel=prefetch><link href=/js/chunk-36ac1a23.907bf32d.js rel=prefetch><link href=/js/chunk-37a26d88.20c02945.js rel=prefetch><link href=/js/chunk-59456d4e.0c1f28f5.js rel=prefetch><link href=/js/chunk-664d53d7.69874f43.js rel=prefetch><link href=/js/chunk-6709ac89.81fe9f80.js rel=prefetch><link href=/js/chunk-78dfb9ad.08dc84c7.js rel=prefetch><link href=/js/chunk-7f061eff.9efbb5ce.js rel=prefetch><link href=/js/chunk-afda5a22.14d03c3c.js rel=prefetch><link href=/js/chunk-b0eebb32.58f570c3.js rel=prefetch><link href=/js/chunk-f1c576e6.a11c537b.js rel=prefetch><link href=/js/fail.244fe78b.js rel=prefetch><link href=/css/app.ad52b47a.css rel=preload as=style><link href=/css/chunk-vendors.70dcf28e.css rel=preload as=style><link href=/js/app.e29a566a.js rel=preload as=script><link href=/js/chunk-vendors.8dff577d.js rel=preload as=script><link href=/css/chunk-vendors.70dcf28e.css rel=stylesheet><link href=/css/app.ad52b47a.css rel=stylesheet></head><body><noscript><strong>We're sorry but vue-antd-pro doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app><div id=loader></div></div><script src=/js/chunk-vendors.8dff577d.js></script><script src=/js/app.e29a566a.js></script></body></html> |
2 changes: 1 addition & 1 deletion
2
src/main/resources/admin/js/app.0bb46c3a.js → src/main/resources/admin/js/app.e29a566a.js
Large diffs are not rendered by default.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...urces/admin/js/chunk-38e065ca.a9b9711f.js → ...urces/admin/js/chunk-0cc826ee.944fd5f4.js
Large diffs are not rendered by default.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.