WIP - Added pagination for list view
This commit is contained in:
@@ -78,7 +78,9 @@ const fetchRecords = async () => {
|
||||
try {
|
||||
const endpoint = `${props.baseUrl}/${relationObject.value}/records`
|
||||
const response = await api.get(endpoint)
|
||||
records.value = response || []
|
||||
records.value = Array.isArray(response)
|
||||
? response
|
||||
: response?.data || response?.records || []
|
||||
|
||||
// If we have a modelValue, find the selected record
|
||||
if (props.modelValue) {
|
||||
|
||||
Reference in New Issue
Block a user