Get 2024 Templates Mega Bundle!14 Bootstrap, Vue & React Templates + 3 Vector Sets
Get for 99$

Metronic Django


Please, on django why didn't you give even one exemple of how you link pages in _menuSibar ?


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(

Replies (2)


I want to link the menu's elements "File manager" with the app file manager, I don't find details in the documentation



Hi Meschac Lubula,

To link the menu element "File Manager" with the app file manager, you can follow these steps:

You can refer from the existing Dashboards module or reuse the existing dashboard module in your project.

Inside the dashboard/urls.py file, create a URL pattern for your page. For example:

# dashboard/urls.py
from django.urls import path
from . import views

urlpatterns = [
# ... other dashboard URLs ...
path("file-manager/", views.file_manager, name="file_manager"),
]


For the file manager HTML template, you may need to copy it from the Metronic HTML version and customize it according to your needs.

To update the menu URL, navigate to the following file:
/starterkit/_templates/layout/partials/sidebar-layout/sidebar/_menu.html

Locate the entry for "File Manager" and update the href attribute with the URL you defined in the dashboard/urls.py file:

<a href="%7B%%20url%20"file_manager"%20%%7D%22%20class=%22menu-link" target="_blank">File manager</a>


Ensure the {% url 'file_manager' %} matches the name you assigned in the urls.py file.

If you encounter any issues or need further assistance, feel free to ask!


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(
Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(