root: return API dates as timestamp
This commit is contained in:
parent
119adb3e7b
commit
5f9c1e229c
|
@ -142,6 +142,7 @@ SWAGGER_SETTINGS = {
|
||||||
REST_FRAMEWORK = {
|
REST_FRAMEWORK = {
|
||||||
"DEFAULT_PAGINATION_CLASS": "authentik.api.pagination.Pagination",
|
"DEFAULT_PAGINATION_CLASS": "authentik.api.pagination.Pagination",
|
||||||
"PAGE_SIZE": 100,
|
"PAGE_SIZE": 100,
|
||||||
|
'DATETIME_FORMAT': '%s',
|
||||||
"DEFAULT_FILTER_BACKENDS": [
|
"DEFAULT_FILTER_BACKENDS": [
|
||||||
"rest_framework_guardian.filters.ObjectPermissionsFilter",
|
"rest_framework_guardian.filters.ObjectPermissionsFilter",
|
||||||
"django_filters.rest_framework.DjangoFilterBackend",
|
"django_filters.rest_framework.DjangoFilterBackend",
|
||||||
|
|
|
@ -50,3 +50,7 @@ export function loading<T>(v: T, actual: TemplateResult): TemplateResult {
|
||||||
}
|
}
|
||||||
return actual;
|
return actual;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function time(t: string): Date {
|
||||||
|
return new Date(parseInt(t, 10) * 1000);
|
||||||
|
}
|
||||||
|
|
Reference in a new issue