Skip to content

Commit

Permalink
fix: fix calendar scope reactivity
Browse files Browse the repository at this point in the history
  • Loading branch information
nichenqin committed Nov 21, 2024
1 parent 1cb2cce commit b733aa2
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@
const getRecords = createInfiniteQuery(
derived(
[t, viewId, calendarStore, startTimestamp, endTimestamp, search, validValue],
([$table, $viewId, $calendarStore, $startTimestamp, $endTimestamp, $search, $filter]) => {
[t, viewId, calendarStore, startTimestamp, endTimestamp, search, validValue, scope],
([$table, $viewId, $calendarStore, $startTimestamp, $endTimestamp, $search, $filter, $scope]) => {
const date = $calendarStore.selectedDate
const filters = match($scope)
Expand Down Expand Up @@ -107,7 +107,7 @@
.with("thisWeek", () => $startOfWeekTimestamp?.toISOString())
.otherwise(() => undefined)
return {
queryKey: ["records", $table?.id.value, $viewId, scope, dateString, $search],
queryKey: ["records", $table?.id.value, $viewId, $scope, dateString, $search],
queryFn: ({ pageParam = 1 }) => {
if (shareId) {
return trpc.shareData.records.query({
Expand Down

0 comments on commit b733aa2

Please sign in to comment.