mirror of https://github.com/usbharu/Hideout.git
parent
975fd5160b
commit
fec59ab622
|
@ -22,9 +22,9 @@ class TimelineController(
|
|||
@GetMapping("/home")
|
||||
suspend fun homeTimeline(
|
||||
model: Model,
|
||||
@RequestParam sinceId: String?,
|
||||
@RequestParam maxId: String?,
|
||||
@RequestParam minId: String?
|
||||
@RequestParam("since_id") sinceId: String?,
|
||||
@RequestParam("max_id") maxId: String?,
|
||||
@RequestParam("min_id") minId: String?
|
||||
): String {
|
||||
val principal = springSecurityFormLoginPrincipalContextHolder.getPrincipal()
|
||||
val userDetail = transaction.transaction {
|
||||
|
|
|
@ -25,9 +25,9 @@ class UserController(
|
|||
@GetMapping("/users/{name}")
|
||||
suspend fun userById(
|
||||
@PathVariable name: String,
|
||||
@RequestParam minId: Long?,
|
||||
@RequestParam maxId: Long?,
|
||||
@RequestParam sinceId: Long?,
|
||||
@RequestParam("min_id") minId: Long?,
|
||||
@RequestParam("max_id") maxId: Long?,
|
||||
@RequestParam("since_id") sinceId: Long?,
|
||||
model: Model
|
||||
): String {
|
||||
val principal = springSecurityFormLoginPrincipalContextHolder.getPrincipal()
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<th:block th:fragment="simple-timline(timelineObject,href)">
|
||||
<!--/*@thymesVar id="timelineObject" type="dev.usbharu.hideout.core.domain.model.support.page.PaginationList<dev.usbharu.hideout.core.application.post.PostDetail,dev.usbharu.hideout.core.domain.model.post.PostId>"*/-->
|
||||
<div th:if="${timelineObject.prev != null}">
|
||||
<a th:href="${href + '?minId=' + timelineObject.prev.id}" th:text="#{common.paging-load}">Show more</a>
|
||||
<a th:href="${href + '?min_id=' + timelineObject.prev.id}" th:text="#{common.paging-load}">Show more</a>
|
||||
</div>
|
||||
<div th:if="${timelineObject.isEmpty()}" th:text="#{common.empty}"></div>
|
||||
<div th:each="postDetail : ${timelineObject}">
|
||||
|
@ -16,7 +16,7 @@
|
|||
<th:block th:replace="~{fragments-post :: single-post-controller(${postDetail})}"></th:block>
|
||||
</div>
|
||||
<div th:if="${timelineObject.next != null}">
|
||||
<a th:href="${href + '?maxId=' + timelineObject.next.id}" th:text="#{common.paging-load}">Show more</a>
|
||||
<a th:href="${href + '?max_id=' + timelineObject.next.id}" th:text="#{common.paging-load}">Show more</a>
|
||||
</div>
|
||||
</th:block>
|
||||
</body>
|
||||
|
|
Loading…
Reference in New Issue