{ "info": { "author": "Jeff McRiffey", "author_email": "jeff.mcriffey@ambition.com", "bugtrack_url": null, "classifiers": [ "Framework :: Django", "Framework :: Django :: 1.8", "Framework :: Django :: 1.9", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5" ], "description": "[![Build Status](https://travis-ci.org/ambitioninc/django-user-guide.png)](https://travis-ci.org/ambitioninc/django-user-guide)\n# Django User Guide\n\n\nDjango User Guide is a `django>=1.6` app that shows configurable, self-contained HTML guides to users. Showing a guide to all of your users is as easy as\ncreating a `Guide` object and linking them to your users. Use the convenient `{% user_guide %}` template tag where you want guides to appear and Django User Guide does the rest. When a user visits a page containing the template tag, they are greeted with relevant guides. Django User Guide decides what guide(s) a user needs to see and displays them in a modal window with controls for cycling through those guides. Django User Guide tracks plenty of meta-data: creation times, guide importance, if the guide has been finished by specific users, finished times, etc.\n\n## Table of Contents\n1. [Installation](#installation)\n1. [Guide](#guide)\n1. [GuideInfo](#guide-info)\n1. [Settings](#settings)\n1. [Finishing Criteria](#finishing-criteria)\n1. [Putting It All Together](#putting-it-all-together)\n\n## Installation\nTo install Django User Guide:\n\n```shell\npip install git+https://github.com/ambitioninc/django-user-guide.git@0.1\n```\n\nAdd Django User Guide to your `INSTALLED_APPS` to get started:\n\nsettings.py\n\n```python\n\n# Simply add 'user_guide' to your installed apps.\n# Django User Guide relies on several basic django apps.\nINSTALLED_APPS = (\n 'django.contrib.auth',\n 'django.contrib.admin',\n 'django.contrib.sites',\n 'django.contrib.sessions',\n 'django.contrib.messages',\n 'django.contrib.staticfiles',\n 'django.contrib.contenttypes',\n 'user_guide',\n)\n```\n\nMake sure Django's CsrfViewMiddleware is enabled:\n\nsettings.py\n\n```python\nMIDDLEWARE_CLASSES = (\n 'django.middleware.csrf.CsrfViewMiddleware',\n)\n```\n\nAdd Django User Guide's urls to your project:\n\nurls.py\n\n```python\nfrom django.conf.urls import include, patterns, url\n\nurlpatterns = patterns(\n url(r'^user-guide/', include('user_guide.urls')),\n)\n```\n\n## Guide\n\nFirst you will need to create one or more `Guide` objects. A `Guide` object consists of:\n\n#### guide_name (required, max_length=64, unique)\n\nThis is a semantic, unique identifier for a `Guide`. Allows for easy identification and targeted filtering.\n\n#### html\n\nThe markup for the `Guide`. Use this field to communicate with your users in a meaningful way.\nNote that the data in this field is output with `{% html|safe %}`, so it would be a bad idea to put untrusted data in it. The html field automatically replaces `{static}` within the html with the value of `settings.STATIC_URL` for convenience.\n\n#### guide_tag (default='all')\n\nA custom tag for grouping several guides together. Specifically designed to be used for filtering. If you had `my_guide_tag_list = ['welcome', 'onboarding']` in your context, you would use `{% user_guide guide_tags=my_guide_tag_list %}` to show users all guides with tags 'welcome' and 'onboard' specifically.\n\n#### guide_importance (default=0)\n\nA number representing the importance of the `Guide`. `Guide` objects with a higher `guide_importance` are shown first. `Guide` objects are always sorted by `guide_importance`, then `creation_time`.\n\n#### guide_type (default='Window')\n\nThe rendering type for the `Guide`. Only a modal window is currently supported. Future support for positioned coach-marks and other elements is planned.\n\n#### creation_time (auto_now_add=True)\n\nStores the current datetime when a `Guide` is created.\n\n\n## Guide Usage\n\n```python\nfrom user_guide.models import Guide\n\nGuide.objects.create(\n html='
Hello Guide!
',\n guide_name='First Guide',\n guide_tag='onboarding',\n guide_importance=5\n)\n```\n\n## GuideInfo\n\nThe next step is creating `GuideInfo` objects. These are used to connect a `Guide` to a `User`. A `GuideInfo` object consists of:\n\n#### user (required)\n\nThe `User` that should see a `Guide`. Any number of `User` objects can be pointed to a `Guide`.\n\n#### guide (required)\n\nThe `Guide` to show a `User`. Any number of `Guide` objects can be tied to a `User`.\n\n#### is_finished (default=False)\n\nMarked true when the `User` has completed some [finishing criteria](#finishing-criteria). By default, users are only shown `Guide` objects with `is_finished=False`.\n\n#### finished_time\n\nWhen the [finishing criteria](#finishing-criteria) is met, the value of `datetime.utcnow()` is stored.\n\n## GuideInfo Usage\n\n```python\nfrom django.contrib.auth.models import User\n\nfrom user_guide.models import Guide, GuideInfo\n\n# Show the guide with the name 'First Guide' to the given user\nguide = Guide.objects.get(guide_name='First Guide')\nuser = User.objects.get(id=1)\n\nGuideInfo.objects.create(guide=guide, user=user)\n```\n\n## Settings\n\nDjango User Guide has several configurations that can finely tune your user guide experience.\n\n#### USER_GUIDE_SHOW_MAX (default=10)\n\nThe maximum number of guides to show for a single page load. If a user had 20 possible guides and `USER_GUIDE_SHOW_MAX` was set to 5, only the first 5 (based on `guide_importance` and `creation_time`) guides would be shown.\n\n#### USER_GUIDE_CSS_URL (default=None)\n\nThe path to a custom style sheet for Django User Guides. Added as a `link` tag immediately after the [django-user-guide.css](user_guide/static/user_guide/build/django-user-guide.css) source. If omitted, no extra style sheets are included. See [django-user-guide.css](user_guide/static/user_guide/build/django-user-guide.css) for class names to override.\n\n#### USER_GUIDE_JS_URL (default=None)\n\nThe path to a custom script for Django User Guides. Added as a `script` tag immediately after the [django-user-guide.js](user_guide/static/user_guide/build/django-user-guide.js) source. If omitted, no extra scripts are included. See [django-user-guide.js](user_guide/static/user_guide/build/django-user-guide.js) for methods to override.\n\n#### USER_GUIDE_USE_COOKIES (default=False)\n\nTrue to use cookies instead of marking the guides as seen in the database. Useful for showing guides to multiple shared Django users.\n\n## Settings Usage\n\nsettings.py\n\n```python\n# Django User Guide settings\nUSER_GUIDE_SHOW_MAX = 5\nUSER_GUIDE_USE_COOKIES = True\nUSER_GUIDE_CSS_URL = 'absolute/path/to/style.css'\nUSER_GUIDE_JS_URL = 'absolute/path/to/script.js'\n```\n\n## Finishing criteria\n\nFinishing criteria are rules to marking a guide as finished. By default, they only need to press the 'next' or 'done' button on a guide. This behavior can be overridden by creating a custom script and adding it to the USER_GUIDE_JS_URL setting. The custom script only needs to override the `window.DjangoUserGuide.isFinished` method.\n\ncustom-script.js\n\n```js\n /**\n * @override isFinished\n * Only allows guides to be marked finished on Mondays.\n * @param {HTMLDivElement} item - The item to check.\n * @returns {Boolean}\n */\n window.DjangoUserGuide.prototype.isFinished = function isFinished(item) {\n if ((new Date()).getDay() === 1) {\n return true;\n }\n return false;\n };\n```\n\nsettings.py\n\n```python\nUSER_GUIDE_JS_URL = 'path/to/custom-script.js'\n```\n\n## Putting It All Together\n\nAssuming you have created some `Guide` and `GuideInfo` objects, this is how you would\nshow your users their relevant guides.\n\nviews.py\n\n```python\nfrom django.views.generic import TemplateView\n\nclass CoolView(TemplateView):\n template_name = 'cool_project/cool_template.html'\n\n def get_context_data(self, **kwargs):\n context = super(CoolView, self).get_context_data(**kwargs)\n context['cool_guide_tags'] = ['general', 'welcome', 'onboarding']\n return context\n```\n\ntemplates/cool_project/cool_template.html\n\n```html\n\n\n \n \n Hello User Guides\n \n \n {% load user_guide_tags %}\n {% user_guide guide_tags=cool_guide_tags %}\n

Hello User Guides!

\n \n\n```\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/ambitioninc/django-user-guide", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "django-user-guide", "package_url": "https://pypi.org/project/django-user-guide/", "platform": "", "project_url": "https://pypi.org/project/django-user-guide/", "project_urls": { "Homepage": "https://github.com/ambitioninc/django-user-guide" }, "release_url": "https://pypi.org/project/django-user-guide/0.11.0/", "requires_dist": null, "requires_python": "", "summary": "Show configurable HTML guides to users.", "version": "0.11.0" }, "last_serial": 2489942, "releases": { "0.10.1": [ { "comment_text": "", "digests": { "md5": "7329d64551c33d1c909786d9d09483b8", "sha256": "f90492761ca89f14777f0d66c0f197ff07d0146864a4d0e177d48bd829df7227" }, "downloads": -1, "filename": "django_user_guide-0.10.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "7329d64551c33d1c909786d9d09483b8", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 21383, "upload_time": "2016-02-18T20:43:01", "url": "https://files.pythonhosted.org/packages/06/f0/8be9c36a00f0a82a17778df6934706e5101fa1cc820c0836c4fbc3bddb99/django_user_guide-0.10.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "63d780c910e01eeaedc8392e9ba6daa5", "sha256": "f58990fca13b5aa23b4e23cb87125f1b13b91915fe9c0adc2b88a91e524e30f3" }, "downloads": -1, "filename": "django-user-guide-0.10.1.tar.gz", "has_sig": false, "md5_digest": "63d780c910e01eeaedc8392e9ba6daa5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14791, "upload_time": "2016-02-18T20:42:52", "url": "https://files.pythonhosted.org/packages/8a/35/2e5c776800fe73b8f331f70f7dd7b32c8f644e52968848a257d5dbe220f7/django-user-guide-0.10.1.tar.gz" } ], "0.11.0": [ { "comment_text": "", "digests": { "md5": "210c0da505b47c8ff6111b90266fb627", "sha256": "d3bad22515d3bee0c5b1e74ab57995729584108caf163e22d7d4a9d02d2ed515" }, "downloads": -1, "filename": "django_user_guide-0.11.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "210c0da505b47c8ff6111b90266fb627", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 21383, "upload_time": "2016-11-29T15:38:28", "url": "https://files.pythonhosted.org/packages/19/93/5eea630c170b4b845786dda1fc4d404038ad94b298aff6b1eff902fa1633/django_user_guide-0.11.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "4be38708b541e4286bb97864dcbe970e", "sha256": "eb3bfa2e2721eb926dd13cdcf64c1239649e21cf2db41e3627e077b455d5a531" }, "downloads": -1, "filename": "django-user-guide-0.11.0.tar.gz", "has_sig": false, "md5_digest": "4be38708b541e4286bb97864dcbe970e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14787, "upload_time": "2016-11-29T15:38:25", "url": "https://files.pythonhosted.org/packages/28/1e/833a6d528a39101731eef791a40a4bf3d08dc36f93bfe8750d754c760ccd/django-user-guide-0.11.0.tar.gz" } ], "0.7.1": [ { "comment_text": "", "digests": { "md5": "1b252aa804a0c174b9c63c09cdc50619", "sha256": "560c4a6dbc5433e40babe0493244b0bc323aa1a5c23886feee15517be073eab4" }, "downloads": -1, "filename": "django-user-guide-0.7.1.tar.gz", "has_sig": false, "md5_digest": "1b252aa804a0c174b9c63c09cdc50619", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15518, "upload_time": "2014-05-24T03:24:48", "url": "https://files.pythonhosted.org/packages/fb/cf/ae4ecc31e141728163aa41c99c467d66a0248f7df6ffbe809740faef878c/django-user-guide-0.7.1.tar.gz" } ], "0.7.2": [ { "comment_text": "", "digests": { "md5": "1c2da0f7049a78d3a6dcda6b9640b3c5", "sha256": "a20b2f5bc9c5c62d2fcb49fd11a6e48126ab86273202f8bf6a825f222cc62d5c" }, "downloads": -1, "filename": "django-user-guide-0.7.2.tar.gz", "has_sig": false, "md5_digest": "1c2da0f7049a78d3a6dcda6b9640b3c5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15634, "upload_time": "2014-06-12T14:21:09", "url": "https://files.pythonhosted.org/packages/6f/f8/83342c6b963029701334aa7d2261db6e30ee9bcfd48681e35df634d6ec66/django-user-guide-0.7.2.tar.gz" } ], "0.7.3": [ { "comment_text": "", "digests": { "md5": "a5db0a8eaf26bc47521d75fd3c7a2621", "sha256": "f1c622916b88896312cd7dc35ca5a947dd42d23ad8d9d6e80ead68fb506cb3ac" }, "downloads": -1, "filename": "django-user-guide-0.7.3.tar.gz", "has_sig": false, "md5_digest": "a5db0a8eaf26bc47521d75fd3c7a2621", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15534, "upload_time": "2015-01-20T19:09:26", "url": "https://files.pythonhosted.org/packages/70/26/af3c559cc8eaa8782c52aaa6c393bf1266c4f65024647336968ccbdbfd8f/django-user-guide-0.7.3.tar.gz" } ], "0.7.4": [ { "comment_text": "", "digests": { "md5": "d94594e9766856194fd39a18b29aea0b", "sha256": "4e06ef711cf8a0ef883173ad0b2e5bf0ccf6dfaaa3f2b96e6a43ed9a070499a5" }, "downloads": -1, "filename": "django-user-guide-0.7.4.tar.gz", "has_sig": false, "md5_digest": "d94594e9766856194fd39a18b29aea0b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15524, "upload_time": "2015-01-20T19:47:53", "url": "https://files.pythonhosted.org/packages/21/b2/5aef37f1d399cc35a46f378575868918b4c20df4dd3253c378ed4b142074/django-user-guide-0.7.4.tar.gz" } ], "0.8.0": [ { "comment_text": "", "digests": { "md5": "494c6fd577fa1b6ebd5b739585f5c427", "sha256": "4f98be145d0c72878e835a861c9bca954338d917ab2ca79fad31a5a5eecdb2e2" }, "downloads": -1, "filename": "django-user-guide-0.8.0.tar.gz", "has_sig": false, "md5_digest": "494c6fd577fa1b6ebd5b739585f5c427", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15959, "upload_time": "2015-04-02T14:31:40", "url": "https://files.pythonhosted.org/packages/46/b2/9c4d5763f416300d70a53a3d44a06863dc70fa1fe1e8ef250297f1c999c8/django-user-guide-0.8.0.tar.gz" } ], "0.8.1": [ { "comment_text": "", "digests": { "md5": "b0282135dd0288652359688b68cb1085", "sha256": "cc2da5329f775253bb640af6360bc91c9bcad08996df7e3607af164b126d790a" }, "downloads": -1, "filename": "django_user_guide-0.8.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "b0282135dd0288652359688b68cb1085", "packagetype": "bdist_wheel", "python_version": "3.4", "requires_python": null, "size": 22906, "upload_time": "2015-04-16T18:40:08", "url": "https://files.pythonhosted.org/packages/e8/a0/15bb4893ba62d5d0ed2cac2011dc07ed26cff3ea19d37c1fff1279b593da/django_user_guide-0.8.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "63c58b11c30ce1027f64a3ef97ca5031", "sha256": "d91afa57abf035f2935d245652fb46ab896d10a1071aed0f354df9f42a7b7dc2" }, "downloads": -1, "filename": "django-user-guide-0.8.1.tar.gz", "has_sig": false, "md5_digest": "63c58b11c30ce1027f64a3ef97ca5031", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15923, "upload_time": "2015-04-16T18:40:04", "url": "https://files.pythonhosted.org/packages/83/0a/8cfa5457a8017b2dff026f30b561574677d40841ceefb06cd2e02310900a/django-user-guide-0.8.1.tar.gz" } ], "0.8.2": [ { "comment_text": "", "digests": { "md5": "0e57ccaa029241f5a0e13de80664c457", "sha256": "2c68d7b3eb617ffb44850aa3bc56d0a578ee6473aec364beb27b59acbd21aa67" }, "downloads": -1, "filename": "django-user-guide-0.8.2.tar.gz", "has_sig": false, "md5_digest": "0e57ccaa029241f5a0e13de80664c457", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 15975, "upload_time": "2015-04-24T18:07:53", "url": "https://files.pythonhosted.org/packages/24/2c/1bc3e530df3d79afbf40f6a3f5df595ad522ce3e4c9d10a0e661485597ae/django-user-guide-0.8.2.tar.gz" } ], "0.8.3": [ { "comment_text": "", "digests": { "md5": "0eafd61da11a0ebaa2872723ed9961ed", "sha256": "19863f7f396cb92050732493fa5c705b7a30492a72a2250504a1dd42b20b7bbc" }, "downloads": -1, "filename": "django-user-guide-0.8.3.tar.gz", "has_sig": false, "md5_digest": "0eafd61da11a0ebaa2872723ed9961ed", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16059, "upload_time": "2015-04-24T18:41:04", "url": "https://files.pythonhosted.org/packages/0b/d5/5748e3444d8762c91a3da7c7f8195ffcf5d18c565370a12f9d32f6b02dde/django-user-guide-0.8.3.tar.gz" } ], "0.9.0": [ { "comment_text": "", "digests": { "md5": "b902ea15e8dc66a806932cd4eb3a1ce3", "sha256": "48df05ce721ddb54b6b884d0124f3663945dd5ac50334774be7226b4f765f711" }, "downloads": -1, "filename": "django_user_guide-0.9.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "b902ea15e8dc66a806932cd4eb3a1ce3", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 21362, "upload_time": "2015-10-05T20:11:37", "url": "https://files.pythonhosted.org/packages/19/d9/2057db0717a29a9633b2faf394e8e0204ef12e9710a52f3cd44f42a4c9f8/django_user_guide-0.9.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "fce8ee267c469de0dc3e503663aa56c4", "sha256": "f824032d2c82de3dce2f6009ad47f567ecfd9aee28388098eeca09141e65714b" }, "downloads": -1, "filename": "django-user-guide-0.9.0.tar.gz", "has_sig": false, "md5_digest": "fce8ee267c469de0dc3e503663aa56c4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14789, "upload_time": "2015-10-05T20:11:32", "url": "https://files.pythonhosted.org/packages/32/14/816327ab951d99e19e9b62e3342d8cc719082a29335949d3284b3b3f8284/django-user-guide-0.9.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "210c0da505b47c8ff6111b90266fb627", "sha256": "d3bad22515d3bee0c5b1e74ab57995729584108caf163e22d7d4a9d02d2ed515" }, "downloads": -1, "filename": "django_user_guide-0.11.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "210c0da505b47c8ff6111b90266fb627", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 21383, "upload_time": "2016-11-29T15:38:28", "url": "https://files.pythonhosted.org/packages/19/93/5eea630c170b4b845786dda1fc4d404038ad94b298aff6b1eff902fa1633/django_user_guide-0.11.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "4be38708b541e4286bb97864dcbe970e", "sha256": "eb3bfa2e2721eb926dd13cdcf64c1239649e21cf2db41e3627e077b455d5a531" }, "downloads": -1, "filename": "django-user-guide-0.11.0.tar.gz", "has_sig": false, "md5_digest": "4be38708b541e4286bb97864dcbe970e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14787, "upload_time": "2016-11-29T15:38:25", "url": "https://files.pythonhosted.org/packages/28/1e/833a6d528a39101731eef791a40a4bf3d08dc36f93bfe8750d754c760ccd/django-user-guide-0.11.0.tar.gz" } ] }