A materialize design Django admin app to make your dashboard awesome.
Project description
===================
django_modern_admin
===================
DjangoModernAdmin is a materialize Django admin extension to for your web apps.
With DjangoModernAdmin your dashboard will be more powerful and had a wonderful design.
Detailed documentation is in the "docs" directory.
Quick start
-----------
1. Add “django_modern_admin” to your INSTALLED_APPS setting like this::
INSTALLED_APPS = [
‘django.contrib.auth’,
‘django_modern_admin’,
‘django.contrib.admin’,
‘... ‘
]
2. Requirements: Pillow, oauth2client
3. Run `python manage.py migrate` to create the django_modern_admin models.
4. You must define in settings.py
GOOGLE_ANALYTICS_SERVICE_ACCOUNT_JSON = os.path.join(BASE_DIR, ‘xxx.json’)
GOOGLE_ANALYTICS_ID = ‘123456789’
5. If you want to use charts you should set chart model and field in settings.py
For Top Left Line Chart:
TOP_LEFT_CHART = {
'title': 'Revenue',
'baseChartModel': 'Orders.Orders',
'baseChartLineField': 'orderTotal',
'baseChartDateField': 'orderDate',
'doughnutChartNameField': 'orderCategory',
'doughnutChartValueField': 'orderTotal',
'tableFieldsForDay': {'orderQty', 'productPrice', 'orderTotal'},
'tableFieldsForMonth': {'orderQty', 'orderTotal'}
}
For Mini Bar Charts:
MINI_BAR_CHART = {
'first': {
'icon': 'mdi-action-account-child', # optional
'chartModel': 'auth.User',
'chartModelDateField': 'date_joined',
'color': 'green',
},
'second': {
# 'icon': '', # optional
'chartModel': 'Orders.Orders',
'chartModelDateField': 'orderDate',
'color': 'deep-purple',
},
'third': {
'icon': 'mdi-action-announcement', # optional
'chartModel': 'auth.User',
'chartModelDateField': 'date_joined',
'color': 'blue-grey',
},
'fourth': {
# 'icon': '', # optional
'chartModel': 'Orders.Orders',
'chartModelDateField': 'orderDate',
'color': 'orange'
}
}
For jVectorMap:
VECTOR_MAP_JS_URL = '/static/js/plugins/jvectormap/jvector-turkey.js'
For Left and Right Model List:
MODEL_LIST = {
'left': {
'modelIcon': 'mdi-content-select-all',
'modelName': 'Products.Products',
'listFields': {'name', 'price', },
'filterField': 'price__lte', # optional
'filterValue': '400', # optional
'orderField': 'price',
},
'right': {
'modelName': 'Orders.Orders',
'listFields': ['product', 'orderQty'],
'orderField': 'orderDate'
}
}
Footer Copyright:
FOOTERCOPYRIGHT = ‘Django Modern Admin’ # optional
Site Title:
SITE_TITLE = ‘Django Modern Admin Administration’
Site Header:
SITE_HEADER = ‘Django Modern Admin Header’
Index Title:
INDEX_TITLE = ‘Django Modern Admin Index’
6. Visit http://127.0.0.1:8000/admin/ to see the magic.
django_modern_admin
===================
DjangoModernAdmin is a materialize Django admin extension to for your web apps.
With DjangoModernAdmin your dashboard will be more powerful and had a wonderful design.
Detailed documentation is in the "docs" directory.
Quick start
-----------
1. Add “django_modern_admin” to your INSTALLED_APPS setting like this::
INSTALLED_APPS = [
‘django.contrib.auth’,
‘django_modern_admin’,
‘django.contrib.admin’,
‘... ‘
]
2. Requirements: Pillow, oauth2client
3. Run `python manage.py migrate` to create the django_modern_admin models.
4. You must define in settings.py
GOOGLE_ANALYTICS_SERVICE_ACCOUNT_JSON = os.path.join(BASE_DIR, ‘xxx.json’)
GOOGLE_ANALYTICS_ID = ‘123456789’
5. If you want to use charts you should set chart model and field in settings.py
For Top Left Line Chart:
TOP_LEFT_CHART = {
'title': 'Revenue',
'baseChartModel': 'Orders.Orders',
'baseChartLineField': 'orderTotal',
'baseChartDateField': 'orderDate',
'doughnutChartNameField': 'orderCategory',
'doughnutChartValueField': 'orderTotal',
'tableFieldsForDay': {'orderQty', 'productPrice', 'orderTotal'},
'tableFieldsForMonth': {'orderQty', 'orderTotal'}
}
For Mini Bar Charts:
MINI_BAR_CHART = {
'first': {
'icon': 'mdi-action-account-child', # optional
'chartModel': 'auth.User',
'chartModelDateField': 'date_joined',
'color': 'green',
},
'second': {
# 'icon': '', # optional
'chartModel': 'Orders.Orders',
'chartModelDateField': 'orderDate',
'color': 'deep-purple',
},
'third': {
'icon': 'mdi-action-announcement', # optional
'chartModel': 'auth.User',
'chartModelDateField': 'date_joined',
'color': 'blue-grey',
},
'fourth': {
# 'icon': '', # optional
'chartModel': 'Orders.Orders',
'chartModelDateField': 'orderDate',
'color': 'orange'
}
}
For jVectorMap:
VECTOR_MAP_JS_URL = '/static/js/plugins/jvectormap/jvector-turkey.js'
For Left and Right Model List:
MODEL_LIST = {
'left': {
'modelIcon': 'mdi-content-select-all',
'modelName': 'Products.Products',
'listFields': {'name', 'price', },
'filterField': 'price__lte', # optional
'filterValue': '400', # optional
'orderField': 'price',
},
'right': {
'modelName': 'Orders.Orders',
'listFields': ['product', 'orderQty'],
'orderField': 'orderDate'
}
}
Footer Copyright:
FOOTERCOPYRIGHT = ‘Django Modern Admin’ # optional
Site Title:
SITE_TITLE = ‘Django Modern Admin Administration’
Site Header:
SITE_HEADER = ‘Django Modern Admin Header’
Index Title:
INDEX_TITLE = ‘Django Modern Admin Index’
6. Visit http://127.0.0.1:8000/admin/ to see the magic.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file django_modern_admin-0.1.tar.gz.
File metadata
- Download URL: django_modern_admin-0.1.tar.gz
- Upload date:
- Size: 2.3 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c557e09b0982e1d8b5385fe630319682884e415bce69bad67d94fe9c4895e0ea
|
|
| MD5 |
ad8fe785b6512d07939c7136321d06bc
|
|
| BLAKE2b-256 |
ba16a109ad146a77ff71fb2009d421e93cbd2b11a8c291baf0ad27acd82a31f0
|