Skip to content

Commit

Permalink
🎸 feat: fetchRequest で offset limit γ‚’εŠ γˆγ¦ι€γ‚‹ (#364)
Browse files Browse the repository at this point in the history
  • Loading branch information
anko9801 authored Dec 29, 2024
1 parent 192d846 commit 1c29229
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
6 changes: 4 additions & 2 deletions src/features/request/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import type { DateTime } from 'luxon'
import type { Group } from '/@/features/group/model'
import type { RequestComment } from '/@/features/requestComment/model'
import type {
RequestStatusDetail,
RequestStatus
RequestStatus,
RequestStatusDetail
} from '/@/features/requestStatus/model'
import type {
RequestTarget,
Expand All @@ -30,6 +30,8 @@ export interface RequestQuerySeed {
target: string
since: string
until: string
limit: number
offset: number
tags: string[]
group: string
}
Expand Down
6 changes: 4 additions & 2 deletions src/features/request/repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import { convertRequestCommentFromData } from '/@/features/requestComment/conver
import type { RequestComment } from '/@/features/requestComment/model'
import { convertRequestStatusFromData } from '/@/features/requestStatus/converter'
import type {
RequestStatusDetail,
RequestStatus
RequestStatus,
RequestStatusDetail
} from '/@/features/requestStatus/model'

import type {
Expand All @@ -31,6 +31,8 @@ const createRequestRepository = () => ({
querySeed.target,
querySeed.since,
querySeed.until,
querySeed.limit,
querySeed.offset,
querySeed.tags.join(','),
querySeed.group
)
Expand Down
2 changes: 2 additions & 0 deletions src/stores/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ const defaultParams: RequestQuerySeed = {
target: '',
since: '',
until: '',
limit: 10,
offset: 0,
tags: [],
group: ''
}
Expand Down

0 comments on commit 1c29229

Please sign in to comment.