mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-23 01:50:12 +01:00
This commit is contained in:
parent
7a8cb81e06
commit
0f62506d25
1 changed files with 2 additions and 2 deletions
|
|
@ -78,7 +78,7 @@ export const viewCards = (deckID: string, title: string, deckType: "Tree" | "" |
|
|||
if (pageIndex <= 1) {
|
||||
previousElement.setAttribute("disabled", "disabled");
|
||||
}
|
||||
fetchPost("/api/riff/getRiffCards", {id: deckID, page: pageIndex}, (cardsResponse) => {
|
||||
fetchPost(`/api/riff/get${deckType}RiffCards`, {id: deckID, page: pageIndex}, (cardsResponse) => {
|
||||
if (pageIndex === cardsResponse.data.pageCount) {
|
||||
nextElement.setAttribute("disabled", "disabled");
|
||||
} else if (cardsResponse.data.pageCount > 1) {
|
||||
|
|
@ -97,7 +97,7 @@ export const viewCards = (deckID: string, title: string, deckType: "Tree" | "" |
|
|||
}
|
||||
pageIndex++;
|
||||
previousElement.removeAttribute("disabled");
|
||||
fetchPost("/api/riff/getRiffCards", {id: deckID, page: pageIndex}, (cardsResponse) => {
|
||||
fetchPost(`/api/riff/get${deckType}RiffCards`, {id: deckID, page: pageIndex}, (cardsResponse) => {
|
||||
if (pageIndex === cardsResponse.data.pageCount) {
|
||||
nextElement.setAttribute("disabled", "disabled");
|
||||
} else if (cardsResponse.data.pageCount > 1) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue