update README.md

This commit is contained in:
long2ice
2021-04-25 22:47:26 +08:00
parent 7f957661ec
commit ab1f338d9d
5 changed files with 27 additions and 5 deletions

View File

@@ -7,6 +7,23 @@
## Introduction
`fastapi-admin` is a fast admin dashboard based on FastAPI and TortoiseORM with [tabler](https://github.com/tabler/tabler) ui, inspired by Django admin.
**Looking for old version? See branch [v1](https://github.com/fastapi-admin/fastapi-admin/tree/v1)**.
## Live Demo
You can check a online demo [here](https://fastapi-admin.long2ice.cn).
- username: `admin`
- password: `123456`
## Screenshots
![](./images/login.png)
![](./images/dashboard.png)
## Documentation
See documentation at [https://fastapi-admin.github.io/fastapi-admin](https://fastapi-admin.github.io/fastapi-admin).

View File

@@ -3,5 +3,5 @@ import os
BASE_DIR = os.path.dirname(os.path.abspath(__file__))
DATETIME_FORMAT = "%Y-%m-%d %H:%M:%S"
DATE_FORMAT = "%Y-%m-%d"
DATETIME_FORMAT_MONENT = "YYYY-MM-DD HH:mm:ss"
DATE_FORMAT_MONENT = "YYYY-MM-DD"
DATETIME_FORMAT_MOMENT = "YYYY-MM-DD HH:mm:ss"
DATE_FORMAT_MOMENT = "YYYY-MM-DD"

View File

@@ -48,7 +48,7 @@ class Datetime(Filter):
self,
name: str,
label: str,
format_: str = constants.DATE_FORMAT_MONENT,
format_: str = constants.DATE_FORMAT_MOMENT,
):
"""
Datetime filter
@@ -76,7 +76,7 @@ class Date(Datetime):
self,
name: str,
label: str,
format_: str = constants.DATE_FORMAT_MONENT,
format_: str = constants.DATE_FORMAT_MOMENT,
):
super().__init__(
name,
@@ -110,7 +110,12 @@ class Select(Filter):
class Enum(Select):
def __init__(
self, enum: Type[EnumCLS], name: str, label: str, enum_type: Type = int, null: bool = False
self,
enum: Type[EnumCLS],
name: str,
label: str,
enum_type: Type = int,
null: bool = False,
):
super().__init__(name, label, null)
self.enum = enum

BIN
images/dashboard.png Normal file
View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 178 KiB

BIN
images/login.png Normal file
View File

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB