Fix in Archived Filtering
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import {useDataStore} from "~/stores/data.js";
|
||||
|
||||
|
||||
export const useSupabaseSelect = async (relation,select = '*', sortColumn = null, ascending = true) => {
|
||||
export const useSupabaseSelect = async (relation,select = '*', sortColumn = null, ascending = true,noArchivedFiltering = false) => {
|
||||
const supabase = useSupabaseClient()
|
||||
const profileStore = useProfileStore()
|
||||
let data = null
|
||||
@@ -22,7 +22,7 @@ export const useSupabaseSelect = async (relation,select = '*', sortColumn = null
|
||||
.eq("tenant", profileStore.currentTenant)).data
|
||||
}
|
||||
|
||||
if(dataType && dataType.isArchivable) {
|
||||
if(dataType && dataType.isArchivable && !noArchivedFiltering) {
|
||||
data = data.filter(i => !i.archived)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user