{ "info": { "author": "Luis Zarate Montero", "author_email": "luis.zarate@solvosoft.com", "bugtrack_url": null, "classifiers": [ "Environment :: Web Environment", "Framework :: Django", "Intended Audience :: Developers", "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.4", "Topic :: Internet :: WWW/HTTP", "Topic :: Internet :: WWW/HTTP :: Dynamic Content" ], "description": "Async notifications\n=====================\n\nEmail notification with celery and administrative view for send email with delay e.g daily\n\nFeatures\n---------\n\n- Celery integration\n- Administrative view \n- Enqueued mail system and instantly send\n- Problems notification\n- User filter email\n- Template system with template context\n- Send to User, Group or external email\n- Django cms integration (djcms_async_notifications) and standalone.\n- Custom text area widget support\n- Allow send group mail list if it's defined.\n\n\nInstallation\n=============\n\n#. Install from pip \n\n .. code:: bash\n \n $ pip install async_notifications\n\n#. Add required apps in your settings **\n\n .. code:: python\n\n INSTALLED_APPS = [\n ...\n 'ajax_select',\n 'async_notifications'\n ]\n\n#. Add ajax_select urls in urls.py\n\n .. code:: python\n\n from django.conf.urls import url, include\n from ajax_select import urls as ajax_select_urls\n urlpatterns = [\n ...\n url(r'^ajax_select/', include(ajax_select_urls)),\n ]\n \n#. It's really important set *CELERY_MODULE* pointing to your project celery file, because it's needed for assing task to the current project, and configure some default celery options\n\n .. code:: python\n\n # settings.py\n CELERY_MODULE = \"demo.celery\"\n CELERY_TIMEZONE = TIME_ZONE\n CELERY_ACCEPT_CONTENT = ['pickle', 'json']\n \n\n\n#. Configure your email settings, e.g for development\n\n .. code:: python\n \n DEFAULT_FROM_EMAIL=\"mail@example.com\"\n EMAIL_HOST=\"localhost\"\n EMAIL_PORT=\"1025\"\n\n# Copy celery app in your project folder from demo, and adjust the crontab execution\n\n .. code:: python\n\n # celery.py\n app.conf.CELERYBEAT_SCHEDULE = {\n # execute 12:30 pm\n 'send_daily_emails': {\n 'task': 'async_notifications.tasks.send_daily',\n 'schedule': crontab(minute=30, hour=0),\n\n },\n }\n\nRemember use demo/__init__.py to update your projectfolder/__init__.py.\n\n#. Run migrations \n\n .. code:: bash\n \n $ python manage.py migrate\n\n\nRuning the project\n===================\n\nYou need to run 3 subsystems for run this app so you need 3 xterm, for this explanation I will use the demo project\n\n1. Run smtp debug client\n\n .. code:: bash\n \n $ python -m smtpd -n -c DebuggingServer localhost:1025 \n\n2. Run celery, if you aren't setup celery yet see `celery documentation `_.\n\n .. code:: bash\n\n $ celery -A demo worker -l info -B\n \n3. Run django\n\n .. code:: bash\n \n $ python manage.py runserver\n\nUsage\n=========\n\nReport your context template \n\n.. code:: python\n\n from async_notifications.register import update_template_context\n context = [\n ('fieldname', 'Field description'),\n ('fieldname2', 'Field description'),\n ...\n ]\n update_template_context(\"yourcode\", 'your email subject', context )\n\nThis autom\u00e1tically create a Email template if not found. \n\nContext is list of tuples with the fields available in the template context, this context is add in the same file \nthat have `send_email_from_template`\n\nUsing with django templates \n\n.. code:: python\n\n update_template_context(\"yourcode\", 'your email subject', context, 'templatepath.html', as_template=True )\n\nSend dict as context is now available, but remember that you can not repit keys in dict so use with precaution.\n\nSend an email :) \n\n.. code:: python\n\n send_email_from_template(code, recipient,\n context={},\n enqueued=True,\n user=None,\n upfile=None)\n\nParams description:\n\n- `recipient` is a list of emails\n- `code` is the same code register in update_template_context\n- `enqueued` if **False** send the email immediately else enqueued to be sended when send email task run.\n- `user` user how send email\n- `upfile` attached file in email\n\nOther optional options \n========================\n\nAdding context dummy object\n----------------------------\n\nWhen you need to pass a default template message base on template, but you have not the template object\nand also you need to write the object with django template sintaxis you can use DummyContextObject that \nreturn always something like {{ myobj.attr1.objattr }}\n \n.. code:: python\n\n from async_notifications.register import update_template_context, DummyContextObject\n context = [\n ('myobj', 'Field description'),\n ...\n ]\n message = render_to_string('some/template.html',\n context={\n 'myobj': DummyContextObject('myobj')\n }\n )\n update_template_context(\"yourcode\", 'your email subject', context, message=message )\n\n\nDjango cms integration\n-------------------------\n\nThis configuration could help you to integrate with Django CMS.\n\ninclude in your `INSTALLED_APPS`:\n\n.. code:: python\n\n INSTALLED_APPS = [\n ...\n 'async_notifications',\n 'async_notifications.djcms_async_notifications',\n ]\n\nConfigure how models and field async_notifications will use, ej. aldryn_people\n\n.. code:: python\n\n ASYNC_NOTIFICATION_GROUP = 'aldryn_people.Group'\n ASYNC_NOTIFICATION_GROUP_LOOKUP_FIELDS = {\n 'order_by': 'translations__name',\n 'email': 'email',\n 'group_lookup': 'translations__name',\n 'display': 'name',\n 'filter': ['translations__name__icontains']}\n\n\n ASYNC_NOTIFICATION_USER = 'aldryn_people.Person'\n\n ASYNC_NOTIFICATION_USER_LOOKUP_FIELDS = {\n 'order_by': 'translations__name',\n 'display': 'name',\n 'filter': [\n 'user__first_name__icontains',\n 'user__last_name__icontains',\n 'translations__name__icontains'],\n 'group_lookup': 'groups__translations__name'}\n\n.. note:: Django auth is used by default\n\ncmsplugin-contact-plus\n-------------------------\n\nCONTACT_PLUS_SEND_METHOD = 'async_notifications.djcms_async_notifications.contact_plus.send_email'\nASYNC_NOTIFICATION_CONTACT_PLUS_EMAIL = 'email'\n\n.. note:: \n\n This requires special cmsplugin-contact-plus version, we send a PRs, but is not merged yet.\n\nDefault text area widget\n--------------------------\n\nFor example using ckeditor widget\n\nASYNC_NOTIFICATION_TEXT_AREA_WIDGET = 'ckeditor.widgets.CKEditorWidget'\n\n.. note:: \n See how to configure `CKEditor `_ .\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/luisza/async_notifications", "keywords": "", "license": "GNU General Public License", "maintainer": "", "maintainer_email": "", "name": "async_notifications", "package_url": "https://pypi.org/project/async_notifications/", "platform": "OS Independent", "project_url": "https://pypi.org/project/async_notifications/", "project_urls": { "Homepage": "https://github.com/luisza/async_notifications" }, "release_url": "https://pypi.org/project/async_notifications/0.1.12/", "requires_dist": null, "requires_python": "", "summary": "Email async notifications with celery.", "version": "0.1.12" }, "last_serial": 5985501, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "49120a0e7e453eb821b8b34abef15a7e", "sha256": "f731b2c396f3b39bd1b593584f15e8588918783fca65b0eeea2e1aa80497172d" }, "downloads": -1, "filename": "async_notifications-0.0.1.tar.gz", "has_sig": false, "md5_digest": "49120a0e7e453eb821b8b34abef15a7e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13851, "upload_time": "2015-12-21T17:02:03", "url": "https://files.pythonhosted.org/packages/46/45/1cffa6fe1e8adac66d951afdfa452fcf697e1e726cf635363131733312df/async_notifications-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "f306d3a6b0f470f964b5dd6549579b43", "sha256": "c842ad2c766d1539cc5f0a4f7c7889885cbaba7eb1cf8306eafde945f8e50b7c" }, "downloads": -1, "filename": "async_notifications-0.0.2.tar.gz", "has_sig": false, "md5_digest": "f306d3a6b0f470f964b5dd6549579b43", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14116, "upload_time": "2016-05-15T02:45:28", "url": "https://files.pythonhosted.org/packages/a2/77/b0a807a8cc0f8f9e89958e23b9b303d150bb6fefc7a664da5e25fe225e7d/async_notifications-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "10be6eaf483ebcc2310741dbd2e70be2", "sha256": "bce02b033f6309d2286a8883978a2cc2f989d92da555936eb93ef3bae8729d60" }, "downloads": -1, "filename": "async_notifications-0.0.3.tar.gz", "has_sig": false, "md5_digest": "10be6eaf483ebcc2310741dbd2e70be2", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14301, "upload_time": "2016-05-15T06:20:18", "url": "https://files.pythonhosted.org/packages/2b/38/05c8643072f90a29973e1a427b37c3ad1896cc6d9f4998ac9619a69ca37e/async_notifications-0.0.3.tar.gz" } ], "0.0.4": [ { "comment_text": "", "digests": { "md5": "515465ac0c0e228ebca9705bcaec793d", "sha256": "0386a28e2596a4227bd591146dfb38482ff29cdae3cbe2a93c371702f8f12070" }, "downloads": -1, "filename": "async_notifications-0.0.4.tar.gz", "has_sig": false, "md5_digest": "515465ac0c0e228ebca9705bcaec793d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 23966, "upload_time": "2016-09-27T08:48:21", "url": "https://files.pythonhosted.org/packages/e8/9e/a0cdfb26add6e89120cbca310fe31ff1bbfd5022169d76428d21a1d5f815/async_notifications-0.0.4.tar.gz" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "894f58e46b2cda1c855a25aa3419627a", "sha256": "aa67ed7cdf4321c5486928aecd3760d2fe5fed5ad651ebfd5cf0e142de9ce65c" }, "downloads": -1, "filename": "async_notifications-0.0.5.tar.gz", "has_sig": false, "md5_digest": "894f58e46b2cda1c855a25aa3419627a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 23946, "upload_time": "2016-09-28T02:53:10", "url": "https://files.pythonhosted.org/packages/bd/40/b1a15d2c86c08432cf18e03ba9f1ad014f50a04adfbe1d78a2083589fe72/async_notifications-0.0.5.tar.gz" } ], "0.0.6": [ { "comment_text": "", "digests": { "md5": "b4751a0518d68db68d46e1e9b212d197", "sha256": "25e2016651972e22fb2079e98925065c789faa3bb6bc8f85716fc6c8b7e0abb3" }, "downloads": -1, "filename": "async_notifications-0.0.6.tar.gz", "has_sig": false, "md5_digest": "b4751a0518d68db68d46e1e9b212d197", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 24002, "upload_time": "2016-10-16T05:58:36", "url": "https://files.pythonhosted.org/packages/02/25/f425d3dfa1013fadd8527a0588e5c76850489de6710690e3deb5e2ae019c/async_notifications-0.0.6.tar.gz" } ], "0.0.7": [ { "comment_text": "", "digests": { "md5": "755abcf7121b01bf08f7e1aeb9c1ee90", "sha256": "6b4cb40ea30056ddbc7527912bf9850596aae31af27e52891b9385fef7f191b9" }, "downloads": -1, "filename": "async_notifications-0.0.7.tar.gz", "has_sig": false, "md5_digest": "755abcf7121b01bf08f7e1aeb9c1ee90", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 24042, "upload_time": "2016-10-18T17:07:32", "url": "https://files.pythonhosted.org/packages/d8/4c/9940374f4aaceedbdbadac627eb5b37a80bf4bfc28dbb3f75a9580aef135/async_notifications-0.0.7.tar.gz" } ], "0.0.8": [ { "comment_text": "", "digests": { "md5": "78adf306f9da3fbd88e5739e4185c694", "sha256": "dd7ed74f636ad86a4e2e5c331923f4adcd555bb2fa2b040eb2ff6d0a38d3415c" }, "downloads": -1, "filename": "async_notifications-0.0.8.tar.gz", "has_sig": false, "md5_digest": "78adf306f9da3fbd88e5739e4185c694", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 23820, "upload_time": "2016-11-10T22:15:00", "url": "https://files.pythonhosted.org/packages/72/77/ace4dda2883d49e519f436194069e6578c3c3d6b66cce1aa743c7f11a949/async_notifications-0.0.8.tar.gz" } ], "0.0.9": [ { "comment_text": "", "digests": { "md5": "948f3a415652469ac3f0bd71ed23475f", "sha256": "b770ddcf05903ad661f487908501928a95e04b393189455b72a4860d6732e1cd" }, "downloads": -1, "filename": "async_notifications-0.0.9.tar.gz", "has_sig": false, "md5_digest": "948f3a415652469ac3f0bd71ed23475f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 23936, "upload_time": "2016-11-18T07:11:49", "url": "https://files.pythonhosted.org/packages/c5/97/e3adab03fbadc2bb80028fb4fc38c93fd2853254c3e963a27024709db33a/async_notifications-0.0.9.tar.gz" } ], "0.1": [ { "comment_text": "", "digests": { "md5": "79f1da77ccb828eb505fabd585879c1d", "sha256": "2a1117351ae94f09faf85efdd3b36de7fab6a32b8a6fe50a811947c0a0399505" }, "downloads": -1, "filename": "async_notifications-0.1.tar.gz", "has_sig": false, "md5_digest": "79f1da77ccb828eb505fabd585879c1d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 24679, "upload_time": "2016-11-18T17:43:58", "url": "https://files.pythonhosted.org/packages/49/30/cbbb2f6dfd2224e7f345ca7036ff0defa995204b2c7d95f85530864810ae/async_notifications-0.1.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "b21649b775223c7a17fe94d3021691d9", "sha256": "dfa5d6de4eb1fca28c4ced9c0faeb055be2fc189a6255ff140cb403af3fae5fc" }, "downloads": -1, "filename": "async_notifications-0.1.1.tar.gz", "has_sig": false, "md5_digest": "b21649b775223c7a17fe94d3021691d9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26704, "upload_time": "2016-11-18T19:05:17", "url": "https://files.pythonhosted.org/packages/5b/52/aa96853fb04542564239ba9df08455abc2ca4ad280d81d2f2894f2cc1610/async_notifications-0.1.1.tar.gz" } ], "0.1.10": [ { "comment_text": "", "digests": { "md5": "6d56d9e748f4596ae1032bce439d28d3", "sha256": "82fdf84c454357feaf424d95daa0badb4ad696105fabca6f1fca434f85213ae8" }, "downloads": -1, "filename": "async_notifications-0.1.10.tar.gz", "has_sig": false, "md5_digest": "6d56d9e748f4596ae1032bce439d28d3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26587, "upload_time": "2019-02-06T18:45:29", "url": "https://files.pythonhosted.org/packages/0e/fc/2c941f5bd865274dfa76fb2834cb690072c3f5dc51b688df2b7f1b730982/async_notifications-0.1.10.tar.gz" } ], "0.1.11": [ { "comment_text": "", "digests": { "md5": "595eca4f3a3b7feb26d4d67bf410be03", "sha256": "25db36db1ccc086deb5b7503b742f1aaa81486a2bfc923ba72e50ad423898b9b" }, "downloads": -1, "filename": "async_notifications-0.1.11.tar.gz", "has_sig": false, "md5_digest": "595eca4f3a3b7feb26d4d67bf410be03", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26727, "upload_time": "2019-10-16T17:07:02", "url": "https://files.pythonhosted.org/packages/a4/2d/65456dec01d6de0aeaf00ec7a4f69e1167c77d68270f8cfb9a72826f9ec4/async_notifications-0.1.11.tar.gz" } ], "0.1.12": [ { "comment_text": "", "digests": { "md5": "c21205e60428ff52cb49c2326e78ca56", "sha256": "cf26a0b867cc4c5d373ffac0489afe1a9c2518fff00e1f763e72c6c4b9082d6d" }, "downloads": -1, "filename": "async_notifications-0.1.12.tar.gz", "has_sig": false, "md5_digest": "c21205e60428ff52cb49c2326e78ca56", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26968, "upload_time": "2019-10-16T17:17:13", "url": "https://files.pythonhosted.org/packages/0b/38/6bcb78bdb8313a5b6879523b152f7f04745c67c10dca08a476940615199e/async_notifications-0.1.12.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "ea31f10a3ee47e575196b04f99bc1929", "sha256": "121a223c0e852cf35d290461235c96009f1c3196a78faafdd0a7cae6bcad114e" }, "downloads": -1, "filename": "async_notifications-0.1.2.tar.gz", "has_sig": false, "md5_digest": "ea31f10a3ee47e575196b04f99bc1929", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26725, "upload_time": "2017-01-29T21:39:44", "url": "https://files.pythonhosted.org/packages/6f/23/52f68fed1cd86d67ee55708ff070078705af6415a92d1bef38eb2357e5aa/async_notifications-0.1.2.tar.gz" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "56b046c8c0b86383604a7d66d832aedd", "sha256": "34e065e08224e1b47a20406f9ce67e6963d6268d0efb5c847b85df02d2298865" }, "downloads": -1, "filename": "async_notifications-0.1.3.tar.gz", "has_sig": false, "md5_digest": "56b046c8c0b86383604a7d66d832aedd", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26950, "upload_time": "2017-05-26T00:04:22", "url": "https://files.pythonhosted.org/packages/09/27/ee7da7ab5042d39a07b3185bdf4a101e7661cebb4e090b4f5067601bc65b/async_notifications-0.1.3.tar.gz" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "fa722a5671d99c914aca008d5066ccc4", "sha256": "f87ed3c32d8e865a95c428627e687e38db32ebd573ca2a91afd6c2002c6adb86" }, "downloads": -1, "filename": "async_notifications-0.1.4.tar.gz", "has_sig": false, "md5_digest": "fa722a5671d99c914aca008d5066ccc4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26967, "upload_time": "2017-06-30T14:07:42", "url": "https://files.pythonhosted.org/packages/bc/8e/1ca16c2a5835ea48f3a81ea530fa2c2af3e1102a8b85cd4919bf3325390f/async_notifications-0.1.4.tar.gz" } ], "0.1.5": [ { "comment_text": "", "digests": { "md5": "dec0eb797837ca006e98704e9623c3e6", "sha256": "efb853b780c2b5abdd5eb993c407e59411d24315d819a89f7473af21ec91824f" }, "downloads": -1, "filename": "async_notifications-0.1.5.tar.gz", "has_sig": false, "md5_digest": "dec0eb797837ca006e98704e9623c3e6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26963, "upload_time": "2017-07-08T07:27:55", "url": "https://files.pythonhosted.org/packages/d5/e0/be7f75c857e658fba9c5d469aa1da97c7ce777e5c0fae6fee6bffd2001d7/async_notifications-0.1.5.tar.gz" } ], "0.1.6": [ { "comment_text": "", "digests": { "md5": "b14a7a194eeded8ef2fbd91ce0ceadec", "sha256": "443fcdb0327f7b01af0c9d879dff565eebf64db6de63bc8db6e8dadb027d48f2" }, "downloads": -1, "filename": "async_notifications-0.1.6.tar.gz", "has_sig": false, "md5_digest": "b14a7a194eeded8ef2fbd91ce0ceadec", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 25542, "upload_time": "2018-07-01T04:56:37", "url": "https://files.pythonhosted.org/packages/f2/fd/8443ec30c5fa810209fabf9c515de92cbd6ba1af69f85ba4a501aed6271f/async_notifications-0.1.6.tar.gz" } ], "0.1.7": [ { "comment_text": "", "digests": { "md5": "2353f419dc5029a6ee7b6c3123d15628", "sha256": "db9702d3b5145d6fb3a8fa822bebee07f4c90262c60e9057471c3889d1a7ef74" }, "downloads": -1, "filename": "async_notifications-0.1.7.tar.gz", "has_sig": false, "md5_digest": "2353f419dc5029a6ee7b6c3123d15628", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 25543, "upload_time": "2018-07-01T05:12:01", "url": "https://files.pythonhosted.org/packages/04/6d/6fc40a0564acbefddba4b122b21029821267ad9345bb44361eb483073913/async_notifications-0.1.7.tar.gz" } ], "0.1.8": [ { "comment_text": "", "digests": { "md5": "d88cddb3a945405e6e80eb3ee7a1bce7", "sha256": "41f52eb37e230bf5f623b10cc433434ac07f0eac67aafa7dc59c62f58c57b8c4" }, "downloads": -1, "filename": "async_notifications-0.1.8.tar.gz", "has_sig": false, "md5_digest": "d88cddb3a945405e6e80eb3ee7a1bce7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 27552, "upload_time": "2018-07-01T05:58:10", "url": "https://files.pythonhosted.org/packages/21/cf/a4bf39be51dd571f8be16952e5e1838897339af016f1efa3c2eddbb96ae5/async_notifications-0.1.8.tar.gz" } ], "0.1.9": [ { "comment_text": "", "digests": { "md5": "35fa6645bb73b41a0444b6fd5d087c06", "sha256": "0a3b4251e53a09c8455c2c49abeedcaf8a05a352c6f17bd5e6b9461831ca3215" }, "downloads": -1, "filename": "async_notifications-0.1.9.tar.gz", "has_sig": false, "md5_digest": "35fa6645bb73b41a0444b6fd5d087c06", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26639, "upload_time": "2019-02-06T01:37:22", "url": "https://files.pythonhosted.org/packages/85/ba/6bb6d45602ce923fdbc7633c153fdebcffcd01e9b5c520c89563bd31917e/async_notifications-0.1.9.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c21205e60428ff52cb49c2326e78ca56", "sha256": "cf26a0b867cc4c5d373ffac0489afe1a9c2518fff00e1f763e72c6c4b9082d6d" }, "downloads": -1, "filename": "async_notifications-0.1.12.tar.gz", "has_sig": false, "md5_digest": "c21205e60428ff52cb49c2326e78ca56", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26968, "upload_time": "2019-10-16T17:17:13", "url": "https://files.pythonhosted.org/packages/0b/38/6bcb78bdb8313a5b6879523b152f7f04745c67c10dca08a476940615199e/async_notifications-0.1.12.tar.gz" } ] }