diff --git a/CHANGELOG.md b/CHANGELOG.md index 662ca21..c8ed977 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,14 @@ # Change Log +## [1.0.6] 2023-01-29 +### Changes + +- DOCS Update (readme). New sections: + - `How to customize the theme` + - Render deployment +- Configure the project to use `home/templates` +- Added `custom_footer` sample + ## [1.0.5] 2023-01-01 ### Changes diff --git a/README.md b/README.md index d83085c..f92b794 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # [Soft Dashboard PRO Django](https://appseed.us/product/soft-ui-dashboard-pro/django/) -**Django** starter styled with **[Soft Dashboard PRO](https://appseed.us/product/soft-ui-dashboard-pro/django/)**, a premium `Bootstrap 5` KIT from [Creative-Tim](https://bit.ly/3fKQZaL) +**Django** starter styled with **[Soft Dashboard PRO](https://appseed.us/product/soft-ui-dashboard-pro/django/)**, a premium `Bootstrap 5` KIT from [Creative-Tim](https://bit.ly/3fKQZaL). The product is designed to deliver the best possible user experience with highly customizable feature-rich pages. > **NOTE**: This product `requires a License` in order to access the theme. During the purchase, a `GitHub Access TOKEN` is provided. @@ -102,6 +102,74 @@ At this point, the app runs at `http://127.0.0.1:8000/`.
+## How to Customize + +When a template file is loaded in the controller, `Django` scans all template directories starting from the ones defined by the user, and returns the first match or an error in case the template is not found. +The theme used to style this starter provides the following files: + +```bash +< LIBRARY_ROOT > # This exists in ENV: LIB/admin_soft_pro + | + |-- templates/ # Root Templates Folder + | | + | |-- accounts/ + | | |-- signin/basic.html # Sign IN Page + | | |-- signup/basic.html # Sign UP Page + | | + | |-- includes/ + | | |-- footer.html # Footer component + | | |-- sidebar.html # Sidebar component + | | |-- navigation.html # Navigation Bar + | | |-- scripts.html # Scripts Component + | | + | |-- layouts/ + | | |-- base.html # Masterpage + | | |-- base-fullscreen.html # Masterpage for Auth Pages + | | + | |-- pages/ + | |-- widgets.html # Widgets page + | |-- messages.html # Messaging APP Page + | |-- *.html # All other pages + | + |-- ************************************************************************ +``` + +When the project requires customization, we need to copy the original file that needs an update (from the virtual environment) and place it in the template folder using the same path. + +> For instance, if we want to **customize the footer.html** these are the steps: + +- ✅ `Step 1`: create the `templates` DIRECTORY inside the `home` app +- ✅ `Step 2`: configure the project to use this new template directory + - `core/settings.py` TEMPLATES section +- ✅ `Step 3`: copy the `footer.html` from the original location (inside your ENV) and save it to the `home/templates` DIR + - Source PATH: `/LIB/admin_soft_pro/includes/footer.html` + - Destination PATH: `home/templates/includes/footer.html` + +> To speed up all these steps, the **codebase is already configured** (`Steps 1, and 2`) and a `custom footer` can be found at this location: + +`home/templates/includes/custom_footer.html` + +By default, this file is unused because the `theme` expects `footer.html` (without the `custom_` prefix). + +In order to use it, simply rename it to `footer.html`. Like this, the default version shipped in the library is ignored by Django. + +In a similar way, all other files and components can be customized easily. + +
+ +## Deploy on [Render](https://render.com/) + +- Create a Blueprint instance + - Go to https://dashboard.render.com/blueprints this link. +- Click `New Blueprint Instance` button. +- Connect your `repo` which you want to deploy. +- Fill the `Service Group Name` and click on `Update Existing Resources` button. +- After that your deployment will start automatically. + +At this point, the product should be LIVE. + +
+ ## Screenshots ![Django Admin Soft PRO - Main dashboard page, dark-mode ready.](https://user-images.githubusercontent.com/51070104/211251678-0ff9390a-2035-4cb3-b07d-62fa23f908d3.jpg) @@ -121,4 +189,4 @@ At this point, the app runs at `http://127.0.0.1:8000/`.
--- -**[Django Admin Soft PRO](https://appseed.us/product/soft-ui-dashboard-pro/django/)** - Modern Admin Interface provided by **[AppSeed](https://appseed.us/)** +**[Soft Dashboard PRO Django](https://appseed.us/product/soft-ui-dashboard-pro/django/)** - Modern Admin Interface provided by **[AppSeed](https://appseed.us/)** diff --git a/core/settings.py b/core/settings.py index 7e65e7d..c9cf5ac 100644 --- a/core/settings.py +++ b/core/settings.py @@ -63,10 +63,12 @@ ROOT_URLCONF = "core.urls" +HOME_TEMPLATES = os.path.join(BASE_DIR, 'home', 'templates') + TEMPLATES = [ { "BACKEND": "django.template.backends.django.DjangoTemplates", - "DIRS": [], + "DIRS": [HOME_TEMPLATES], "APP_DIRS": True, "OPTIONS": { "context_processors": [ diff --git a/home/templates/includes/sample_footer.html b/home/templates/includes/sample_footer.html new file mode 100644 index 0000000..109e71f --- /dev/null +++ b/home/templates/includes/sample_footer.html @@ -0,0 +1,25 @@ + \ No newline at end of file