{ "info": { "author": "alrusdi", "author_email": "alrusdi@gmail.com", "bugtrack_url": null, "classifiers": [ "Framework :: Django", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python" ], "description": "django-menus\n============\n\ndjango-menus is an app that provides some useful template helpers for\nrendering and handling menus within django projects.\n\nTo use in in your django project, it needs to be installed:\n\n::\n\n $ pip install django-menus\n\nAnd ``\"menus\"`` needs to be in your ``settings.INSTALLED_APPS``.\n\nmenu\\_item\n----------\n\nAn inclusion template tag that will create a single instance of a menu\nitem, which will only be rendered if the logged in user can access the\nreferenced view. Secondly, the currently active view will have a CSS\nclass of ``active`` in it's menu item.\n\n::\n\n {% load menu_item %}\n\n {% menu_item \"/foo/\" \"Foo\" %}\n {% menu_item \"/bar/\" \"Bar\" %}\n {% menu_item \"http://example.com\" \"Baz\" %}\n\nIf we were viewing ``/foo/``, this renders to:\n\n::\n\n Foo\n Bar\n Baz\n\nUsing the standard template. If you want, you can override the\n``menus/item.html`` template to change the display format.\n\nYou may also pass in a string like ``\"url:foo_name\"`` to the first\nargument. This will do a ``reverse('foo_name')`` call (with no args or\nkwargs) to find a matching url.\n\nIf the menu item title is ``'home'`` (case insensitive), or the url path\nis ``'/'``, then an exact match will be required to mark it as active,\notherwise a prefix match is done. This means that if you had a menu item\nas above, and were viewing the url ``/foo/bar/``, then the first\nmenu\\_item would be marked as active.\n\ntree\\_menu\n----------\n\nAn extension to\n`django-mptt `_, this is a\ntemplate that you can use to have a dynamic tree menu, where selecting\nitems with children expands them, and selecting a leaf node follows the\nlink. To use it, you'll need to have mptt installed into your project as\nwell as this package.\n\nYou use it like:\n\n::\n\n {% load mptt_tags %}\n\n {% block tree_menu %}\n {% full_tree_for_model app_label.ModelName as menu %}\n {% include \"menu/tree-menu.html\" %}\n {% endblock %}\n\nIf you want it to dynamically hide/show nested data, then you will want\nto have:\n\n::\n\n \n \n\nSomewhere in your page.\n\nThis part is currently in use in one small part of a project, and may\nchange if I start to use it more. This README is a little light on\nbecause I haven't touched this code in a long, long time.\n\nChanges\n-------\n\n\n1.1.2 - Python 3 support\n\n1.1.1 - Pass through args and kwargs to the test function if it accepts them.\n\n1.0.9 - Allow for adding classes, and buttons as menu items.\n\n1.0.8 - Allow for absolute urls, ie, pointing to another server. We never\ntry to validate these for permission to view, it is assumed the user can.\n\n1.0.7 - Change how version number is stored. Include a new li-item.html\ntemplate, and refactor how the template is found. Check func\\_code\nexists before accessing it. Refactor some of the handling of paths.\nBetter handle quoting issues.\n\n1.0.6 - Documentation fix only.\n\n1.0.5 - Actually install all of the static media/templates.\n\n1.0.4 - Don't fail on install if README.md missing.\n\n1.0.3 - Repackaged to include README.rst [Thanks to John Bazik\njsb@cs.brown.edu]", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/alrusdi/django-admin-bootstrap-legacy", "keywords": null, "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "django-menus-py3", "package_url": "https://pypi.org/project/django-menus-py3/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-menus-py3/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/alrusdi/django-admin-bootstrap-legacy" }, "release_url": "https://pypi.org/project/django-menus-py3/1.1.3/", "requires_dist": null, "requires_python": null, "summary": "Menu helpers for django projects", "version": "1.1.3" }, "last_serial": 1491729, "releases": { "1.1.3": [ { "comment_text": "", "digests": { "md5": "cfc1c3a60249bc5c9b00eb5621ef0f1a", "sha256": "10a9fd9a319c4979376a537d032ae6ff70ae53241486db6089d5b38736597919" }, "downloads": -1, "filename": "django-menus-py3-1.1.3.tar.gz", "has_sig": false, "md5_digest": "cfc1c3a60249bc5c9b00eb5621ef0f1a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7889, "upload_time": "2015-04-05T12:57:02", "url": "https://files.pythonhosted.org/packages/1f/95/2ff772432925f7d8bda18151f54ede7f70ffb591674e6f6b53c9dbb41de0/django-menus-py3-1.1.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "cfc1c3a60249bc5c9b00eb5621ef0f1a", "sha256": "10a9fd9a319c4979376a537d032ae6ff70ae53241486db6089d5b38736597919" }, "downloads": -1, "filename": "django-menus-py3-1.1.3.tar.gz", "has_sig": false, "md5_digest": "cfc1c3a60249bc5c9b00eb5621ef0f1a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7889, "upload_time": "2015-04-05T12:57:02", "url": "https://files.pythonhosted.org/packages/1f/95/2ff772432925f7d8bda18151f54ede7f70ffb591674e6f6b53c9dbb41de0/django-menus-py3-1.1.3.tar.gz" } ] }