Merge pull request #13639 from Budibase/various-fixes
UI fixes from bug grooming
This commit is contained in:
commit
d292a104ae
|
@ -2,7 +2,7 @@
|
||||||
apiVersion: {{ ternary "autoscaling/v2" "autoscaling/v2beta2" (.Capabilities.APIVersions.Has "autoscaling/v2") }}
|
apiVersion: {{ ternary "autoscaling/v2" "autoscaling/v2beta2" (.Capabilities.APIVersions.Has "autoscaling/v2") }}
|
||||||
kind: HorizontalPodAutoscaler
|
kind: HorizontalPodAutoscaler
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ include "budibase.fullname" . }}-apps
|
name: {{ include "budibase.fullname" . }}-automation-worker
|
||||||
labels:
|
labels:
|
||||||
{{- include "budibase.labels" . | nindent 4 }}
|
{{- include "budibase.labels" . | nindent 4 }}
|
||||||
spec:
|
spec:
|
||||||
|
|
|
@ -98,14 +98,22 @@
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
async function fetchBackups(filters, page, dateRange) {
|
async function fetchBackups(filters, page, dateRange = []) {
|
||||||
const response = await backups.searchBackups({
|
const body = {
|
||||||
appId: $appStore.appId,
|
appId: $appStore.appId,
|
||||||
...filters,
|
...filters,
|
||||||
page,
|
page,
|
||||||
startDate: dateRange[0],
|
}
|
||||||
endDate: dateRange[1],
|
|
||||||
})
|
const [startDate, endDate] = dateRange
|
||||||
|
if (startDate) {
|
||||||
|
body.startDate = startDate
|
||||||
|
}
|
||||||
|
if (endDate) {
|
||||||
|
body.endDate = endDate
|
||||||
|
}
|
||||||
|
|
||||||
|
const response = await backups.searchBackups(body)
|
||||||
pageInfo.fetched(response.hasNextPage, response.nextPage)
|
pageInfo.fetched(response.hasNextPage, response.nextPage)
|
||||||
|
|
||||||
// flatten so we have an easier structure to use for the table schema
|
// flatten so we have an easier structure to use for the table schema
|
||||||
|
@ -120,7 +128,7 @@
|
||||||
})
|
})
|
||||||
await fetchBackups(filterOpt, page)
|
await fetchBackups(filterOpt, page)
|
||||||
notifications.success(response.message)
|
notifications.success(response.message)
|
||||||
} catch {
|
} catch (err) {
|
||||||
notifications.error("Unable to create backup")
|
notifications.error("Unable to create backup")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue