├── apps ├── __init__.py └── volontulo │ ├── views │ ├── admin.py │ └── admin_panel.py │ ├── migrations │ ├── __init__.py │ ├── 0007_remove_page_slug.py │ ├── 0002_userprofile_phone_no.py │ ├── 0004_auto_20151118_1157.py │ ├── 0003_offer_weight.py │ ├── 0005_removing_badges.py │ └── 0006_page.py │ ├── tests │ ├── forms │ │ └── __init__.py │ ├── __init__.py │ ├── views │ │ ├── __init__.py │ │ ├── offers │ │ │ ├── __init__.py │ │ │ ├── test_offer_delete.py │ │ │ ├── test_offer_accept.py │ │ │ ├── test_offers_list.py │ │ │ ├── commons.py │ │ │ └── test_offers_archived.py │ │ ├── test_newsletter.py │ │ └── test_organizations.py │ └── models │ │ ├── __init__.py │ │ ├── test_organization.py │ │ └── test_userprofile.py │ ├── templates │ ├── emails │ │ ├── password_reset.subject │ │ ├── registration.txt │ │ ├── password_reset.txt │ │ ├── volunteer_to_organisation.txt │ │ ├── volunteer_to_admin.txt │ │ ├── offer_creation.txt │ │ ├── offer_application.txt │ │ ├── registration.html │ │ ├── base.txt │ │ ├── password_reset.html │ │ ├── offer_creation.html │ │ ├── site_owner_details.html │ │ ├── user_layout.html │ │ ├── base.html │ │ ├── volunteer_to_organisation.html │ │ ├── admin_layout.html │ │ ├── volunteer_to_admin.html │ │ └── offer_application.html │ ├── common │ │ ├── messages.html │ │ ├── col1.html │ │ ├── labeled_status.html │ │ ├── col2.html │ │ ├── sub-footer.html │ │ ├── base.html │ │ ├── footer.html │ │ └── header.html │ ├── 500.html │ ├── 404.html │ ├── contact.html │ ├── newsletter_signup.html │ ├── pages │ │ ├── page_detail.html │ │ ├── page_edit_form.html │ │ ├── regulations.html │ │ ├── office.html │ │ ├── page_list.html │ │ ├── faq-volunteers.html │ │ ├── faq-organizations.html │ │ └── about-us.html │ ├── users │ │ ├── gallery.html │ │ ├── user_profile.html │ │ └── my_offers.html │ ├── admin │ │ └── offers_nav.html │ ├── auth │ │ ├── password_reset_confirm.html │ │ ├── password_reset.html │ │ └── login.html │ ├── organizations │ │ ├── list.html │ │ ├── gallery.html │ │ ├── organization_view.html │ │ ├── organization_form.html │ │ └── organization_offers.html │ ├── offers │ │ ├── applied_volunteers.html │ │ ├── archived.html │ │ ├── gallery.html │ │ ├── reorder.html │ │ └── offers_list.html │ └── contact_form.html │ ├── __init__.py │ ├── lib │ ├── __init__.py │ └── email.py │ ├── templatetags │ ├── __init__.py │ ├── labeled_status.py │ ├── offer_utilities.py │ └── main_image.py │ ├── frontend │ ├── img │ │ ├── favicon.ico │ │ ├── doodle_help.png │ │ ├── volo_logo.png │ │ ├── doodle_create.png │ │ ├── logo │ │ │ ├── logo-wrk.png │ │ │ ├── logo-komitywa.png │ │ │ ├── logo-stx-next.png │ │ │ └── logo-koduj-dla-polski.png │ │ ├── doodle_contact.png │ │ ├── volo_mail_logo.png │ │ ├── volontulo_baner.png │ │ └── doodle_reg_confirm.png │ ├── scss │ │ ├── open-sans │ │ │ ├── _variables.scss │ │ │ ├── _Bold.scss │ │ │ ├── _Light.scss │ │ │ ├── _Italic.scss │ │ │ ├── _Regular.scss │ │ │ ├── _Semibold.scss │ │ │ ├── _ExtraBold.scss │ │ │ ├── _BoldItalic.scss │ │ │ ├── _LightItalic.scss │ │ │ ├── _SemiboldItalic.scss │ │ │ ├── _ExtraBoldItalic.scss │ │ │ └── _mixins.scss │ │ ├── bootstrap │ │ │ ├── mixins │ │ │ │ ├── _center-block.scss │ │ │ │ ├── _opacity.scss │ │ │ │ ├── _size.scss │ │ │ │ ├── _text-overflow.scss │ │ │ │ ├── _tab-focus.scss │ │ │ │ ├── _labels.scss │ │ │ │ ├── _resize.scss │ │ │ │ ├── _progress-bar.scss │ │ │ │ ├── _text-emphasis.scss │ │ │ │ ├── _reset-filter.scss │ │ │ │ ├── _nav-divider.scss │ │ │ │ ├── _background-variant.scss │ │ │ │ ├── _alerts.scss │ │ │ │ ├── _nav-vertical-align.scss │ │ │ │ ├── _reset-text.scss │ │ │ │ ├── _border-radius.scss │ │ │ │ ├── _pagination.scss │ │ │ │ ├── _responsive-visibility.scss │ │ │ │ ├── _panels.scss │ │ │ │ ├── _hide-text.scss │ │ │ │ ├── _clearfix.scss │ │ │ │ ├── _list-group.scss │ │ │ │ ├── _table-row.scss │ │ │ │ ├── _image.scss │ │ │ │ ├── _buttons.scss │ │ │ │ ├── _grid-framework.scss │ │ │ │ └── _forms.scss │ │ │ ├── _wells.scss │ │ │ ├── _responsive-embed.scss │ │ │ ├── _breadcrumbs.scss │ │ │ ├── _close.scss │ │ │ ├── _component-animations.scss │ │ │ ├── _utilities.scss │ │ │ ├── _thumbnails.scss │ │ │ ├── _pager.scss │ │ │ ├── _mixins.scss │ │ │ ├── _media.scss │ │ │ ├── _jumbotron.scss │ │ │ ├── _labels.scss │ │ │ ├── _code.scss │ │ │ ├── _grid.scss │ │ │ ├── _alerts.scss │ │ │ ├── _progress-bars.scss │ │ │ ├── _pagination.scss │ │ │ ├── _print.scss │ │ │ └── _tooltip.scss │ │ ├── iconify │ │ │ ├── icons.fallback.scss │ │ │ ├── icons.svg.scss │ │ │ └── icons.png.scss │ │ ├── customization │ │ │ ├── _extended-media.scss │ │ │ ├── _extended-thumbnail.scss │ │ │ ├── _auto-clear.scss │ │ │ └── _customization-variables.scss │ │ └── bootstrap.scss │ ├── fonts │ │ ├── open-sans │ │ │ ├── Bold │ │ │ │ ├── OpenSans-Bold.eot │ │ │ │ ├── OpenSans-Bold.ttf │ │ │ │ ├── OpenSans-Bold.woff │ │ │ │ └── OpenSans-Bold.woff2 │ │ │ ├── Light │ │ │ │ ├── OpenSans-Light.eot │ │ │ │ ├── OpenSans-Light.ttf │ │ │ │ ├── OpenSans-Light.woff │ │ │ │ └── OpenSans-Light.woff2 │ │ │ ├── Italic │ │ │ │ ├── OpenSans-Italic.eot │ │ │ │ ├── OpenSans-Italic.ttf │ │ │ │ ├── OpenSans-Italic.woff │ │ │ │ └── OpenSans-Italic.woff2 │ │ │ ├── Regular │ │ │ │ ├── OpenSans-Regular.eot │ │ │ │ ├── OpenSans-Regular.ttf │ │ │ │ ├── OpenSans-Regular.woff │ │ │ │ └── OpenSans-Regular.woff2 │ │ │ ├── Semibold │ │ │ │ ├── OpenSans-Semibold.eot │ │ │ │ ├── OpenSans-Semibold.ttf │ │ │ │ ├── OpenSans-Semibold.woff │ │ │ │ └── OpenSans-Semibold.woff2 │ │ │ ├── ExtraBold │ │ │ │ ├── OpenSans-ExtraBold.eot │ │ │ │ ├── OpenSans-ExtraBold.ttf │ │ │ │ ├── OpenSans-ExtraBold.woff │ │ │ │ └── OpenSans-ExtraBold.woff2 │ │ │ ├── BoldItalic │ │ │ │ ├── OpenSans-BoldItalic.eot │ │ │ │ ├── OpenSans-BoldItalic.ttf │ │ │ │ ├── OpenSans-BoldItalic.woff │ │ │ │ └── OpenSans-BoldItalic.woff2 │ │ │ ├── LightItalic │ │ │ │ ├── OpenSans-LightItalic.eot │ │ │ │ ├── OpenSans-LightItalic.ttf │ │ │ │ ├── OpenSans-LightItalic.woff │ │ │ │ └── OpenSans-LightItalic.woff2 │ │ │ ├── SemiboldItalic │ │ │ │ ├── OpenSans-SemiboldItalic.eot │ │ │ │ ├── OpenSans-SemiboldItalic.ttf │ │ │ │ ├── OpenSans-SemiboldItalic.woff │ │ │ │ └── OpenSans-SemiboldItalic.woff2 │ │ │ └── ExtraBoldItalic │ │ │ │ ├── OpenSans-ExtraBoldItalic.eot │ │ │ │ ├── OpenSans-ExtraBoldItalic.ttf │ │ │ │ ├── OpenSans-ExtraBoldItalic.woff │ │ │ │ └── OpenSans-ExtraBoldItalic.woff2 │ │ └── bootstrap │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ ├── icons │ │ ├── template │ │ │ └── icon_gen.scss.mustache │ │ └── asterisk.svg │ └── javascripts │ │ ├── cookielaw │ │ └── js │ │ │ └── cookielaw.js │ │ └── bootstrap │ │ ├── transition.js │ │ └── alert.js │ ├── package.json │ ├── admin.py │ ├── gulpfile.js │ └── utils.py ├── volontulo_org ├── __init__.py ├── settings │ ├── __init__.py │ ├── production.py │ └── dev.py ├── wsgi.py └── urls.py ├── MANIFEST.in ├── requirements ├── production.txt ├── base.txt └── dev.txt ├── bin ├── install_dependencies └── setup ├── manage.py ├── etc ├── local_config.yaml.sample └── pre-commit ├── PULL_REQUEST_TEMPLATE ├── .travis.yml ├── initial └── data.json ├── LICENSE ├── .gitignore ├── fabfile.py ├── setup.py └── README.md /apps/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /volontulo_org/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /apps/volontulo/views/admin.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /apps/volontulo/migrations/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /volontulo_org/settings/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /apps/volontulo/tests/forms/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/password_reset.subject: -------------------------------------------------------------------------------- 1 | Reset hasła na Volontulo 2 | -------------------------------------------------------------------------------- /apps/volontulo/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """ 4 | .. module:: __init__ 5 | """ 6 | -------------------------------------------------------------------------------- /apps/volontulo/lib/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: __init__ 5 | """ 6 | -------------------------------------------------------------------------------- /apps/volontulo/tests/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: __init__ 5 | """ 6 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: __init__ 5 | """ 6 | -------------------------------------------------------------------------------- /apps/volontulo/templatetags/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: __init__ 5 | """ 6 | -------------------------------------------------------------------------------- /apps/volontulo/tests/models/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: __init__ 5 | """ 6 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/offers/__init__.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: __init__ 5 | """ 6 | -------------------------------------------------------------------------------- /MANIFEST.in: -------------------------------------------------------------------------------- 1 | include LICENSE 2 | include README.md 3 | recursive-include volontulo/static * 4 | recursive-include volontulo/templates * 5 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/favicon.ico -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/doodle_help.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/doodle_help.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/volo_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/volo_logo.png -------------------------------------------------------------------------------- /requirements/production.txt: -------------------------------------------------------------------------------- 1 | -r base.txt # includes base.txt requirements file 2 | 3 | psycopg2==2.6 4 | 5 | # Extra content goes here: 6 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/doodle_create.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/doodle_create.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/logo/logo-wrk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/logo/logo-wrk.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_variables.scss: -------------------------------------------------------------------------------- 1 | $OpenSansPath: "../fonts/open-sans" !default; 2 | $OpenSansVersion: "1.1.0" !default; 3 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/doodle_contact.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/doodle_contact.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/volo_mail_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/volo_mail_logo.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/volontulo_baner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/volontulo_baner.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/doodle_reg_confirm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/doodle_reg_confirm.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/logo/logo-komitywa.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/logo/logo-komitywa.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/logo/logo-stx-next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/logo/logo-stx-next.png -------------------------------------------------------------------------------- /apps/volontulo/frontend/img/logo/logo-koduj-dla-polski.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/img/logo/logo-koduj-dla-polski.png -------------------------------------------------------------------------------- /volontulo_org/settings/production.py: -------------------------------------------------------------------------------- 1 | """ 2 | Production Settings File 3 | """ 4 | # pylint: skip=file 5 | 6 | from .base import * 7 | 8 | # Extra settings go here: 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.woff -------------------------------------------------------------------------------- /apps/volontulo/templates/common/messages.html: -------------------------------------------------------------------------------- 1 | {% load bootstrap3 %} 2 | {% if messages %} 3 |
4 | {% bootstrap_messages %} 5 |
6 | {% endif %} 7 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Bold/OpenSans-Bold.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Italic/OpenSans-Italic.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Light/OpenSans-Light.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Regular/OpenSans-Regular.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/Semibold/OpenSans-Semibold.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/bootstrap/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBold/OpenSans-ExtraBold.woff2 -------------------------------------------------------------------------------- /bin/install_dependencies: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | apt-get update 4 | apt-get build-dep -y python-imaging 5 | apt-get install -y python-virtualenv libjpeg8 libjpeg62-dev libfreetype6 libfreetype6-dev npm 6 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/BoldItalic/OpenSans-BoldItalic.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/LightItalic/OpenSans-LightItalic.woff2 -------------------------------------------------------------------------------- /apps/volontulo/templates/500.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Błąd serwera{% endblock %} 4 | 5 | {% block content %} 6 |

Wewnętrzny błąd serwera

7 | {% endblock %} 8 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_center-block.scss: -------------------------------------------------------------------------------- 1 | // Center-align a block level element 2 | 3 | @mixin center-block() { 4 | display: block; 5 | margin-left: auto; 6 | margin-right: auto; 7 | } 8 | -------------------------------------------------------------------------------- /apps/volontulo/templates/404.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Strona nie znaleziona{% endblock %} 4 | 5 | {% block content %} 6 |

Strona nie znaleziona

7 | {% endblock %} 8 | -------------------------------------------------------------------------------- /requirements/base.txt: -------------------------------------------------------------------------------- 1 | Django==1.8.4 2 | django-bootstrap3==6.2.2 3 | django-cookie-law==1.0.6 4 | logilab-common==1.0.2 5 | Pillow==3.0.0 6 | pyyaml==3.11 7 | six==1.9.0 8 | unipath==1.1 9 | wheel==0.24.0 10 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.eot -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.ttf -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.woff -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/SemiboldItalic/OpenSans-SemiboldItalic.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stxnext-csr/volontulo/HEAD/apps/volontulo/frontend/fonts/open-sans/ExtraBoldItalic/OpenSans-ExtraBoldItalic.woff2 -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_opacity.scss: -------------------------------------------------------------------------------- 1 | // Opacity 2 | 3 | @mixin opacity($opacity) { 4 | opacity: $opacity; 5 | // IE8 filter 6 | $opacity-ie: ($opacity * 100); 7 | filter: alpha(opacity=$opacity-ie); 8 | } 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_size.scss: -------------------------------------------------------------------------------- 1 | // Sizing shortcuts 2 | 3 | @mixin size($width, $height) { 4 | width: $width; 5 | height: $height; 6 | } 7 | 8 | @mixin square($size) { 9 | @include size($size, $size); 10 | } 11 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_Bold.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Bold */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "Bold"); 5 | font-weight: bold; 6 | font-style: normal; 7 | } 8 | /* END Bold */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_Light.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Light */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "Light"); 5 | font-weight: 300; 6 | font-style: normal; 7 | } 8 | /* END Light */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/templates/contact.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Kontakt z administratorem{% endblock %} 4 | 5 | {% block content %} 6 | {% include 'contact_form.html' with contact_form=contact_form %} 7 | {% endblock %} 8 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_text-overflow.scss: -------------------------------------------------------------------------------- 1 | // Text overflow 2 | // Requires inline-block or block for proper styling 3 | 4 | @mixin text-overflow() { 5 | overflow: hidden; 6 | text-overflow: ellipsis; 7 | white-space: nowrap; 8 | } 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_tab-focus.scss: -------------------------------------------------------------------------------- 1 | // WebKit-style focus 2 | 3 | @mixin tab-focus() { 4 | // Default 5 | outline: thin dotted; 6 | // WebKit 7 | outline: 5px auto -webkit-focus-ring-color; 8 | outline-offset: -2px; 9 | } 10 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_Italic.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Italic */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "Italic"); 5 | font-weight: normal; 6 | font-style: italic; 7 | } 8 | /* END Italic */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_Regular.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Regular */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "Regular"); 5 | font-weight: normal; 6 | font-style: normal; 7 | } 8 | /* END Regular */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_Semibold.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Semibold */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "Semibold"); 5 | font-weight: 600; 6 | font-style: normal; 7 | } 8 | /* END Semibold */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_ExtraBold.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Extrabold */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "ExtraBold"); 5 | font-weight: 800; 6 | font-style: normal; 7 | } 8 | /* END Extrabold */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/templates/newsletter_signup.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | {% load main_image %} 3 | 4 | {% block title %}Zapisz się do newslettera{% endblock %} 5 | 6 | {% block content %} 7 |

Zapisz się do newslettera

8 | 9 | {% endblock %} 10 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_labels.scss: -------------------------------------------------------------------------------- 1 | // Labels 2 | 3 | @mixin label-variant($color) { 4 | background-color: $color; 5 | 6 | &[href] { 7 | &:hover, 8 | &:focus { 9 | background-color: darken($color, 10%); 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_resize.scss: -------------------------------------------------------------------------------- 1 | // Resize anything 2 | 3 | @mixin resizable($direction) { 4 | resize: $direction; // Options: horizontal, vertical, both 5 | overflow: auto; // Per CSS3 UI, `resize` only applies when `overflow` isn't `visible` 6 | } 7 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_BoldItalic.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Bold Italic */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "BoldItalic"); 5 | font-weight: bold; 6 | font-style: italic; 7 | } 8 | /* END Bold Italic */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_LightItalic.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Light Italic */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "LightItalic"); 5 | font-weight: 300; 6 | font-style: italic; 7 | } 8 | /* END Light Italic */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_SemiboldItalic.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Semibold Italic */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "SemiboldItalic"); 5 | font-weight: 600; 6 | font-style: italic; 7 | } 8 | /* END Semibold Italic */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_ExtraBoldItalic.scss: -------------------------------------------------------------------------------- 1 | /* BEGIN Extrabold Italic */ 2 | @font-face { 3 | font-family: 'Open Sans'; 4 | @include fontdef($OpenSansPath, $OpenSansVersion, "ExtraBoldItalic"); 5 | font-weight: 800; 6 | font-style: italic; 7 | } 8 | /* END Extrabold Italic */ 9 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/registration.txt: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.txt" %} 2 | {% block email_content %} 3 | Dziękujemy za rejestrację. 4 | Zweryfikuj swoje konto na Volontulo wchodząc w przeglądarce pod poniższy link: 5 | {{ protocol }}://{{ domain }}{% url 'activate' uuid %} 6 | {% endblock %} 7 | -------------------------------------------------------------------------------- /apps/volontulo/views/admin_panel.py: -------------------------------------------------------------------------------- 1 | """ 2 | .. module:: admin_panel 3 | """ 4 | from django.shortcuts import render 5 | 6 | 7 | def main_panel(request): 8 | """Main admin panel view.""" 9 | 10 | return render( 11 | request, 12 | 'admin/list_offers.html' 13 | ) 14 | -------------------------------------------------------------------------------- /apps/volontulo/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "private": true, 3 | "engines": { 4 | "node": ">=0.10.0" 5 | }, 6 | "devDependencies": { 7 | "gulp": "^3.6.0", 8 | "gulp-util": "^3.0.6", 9 | "gulp-sass": "^2.0.4", 10 | "gulp-iconify": "~0.4.0" 11 | }, 12 | "dependencies": {} 13 | } 14 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_progress-bar.scss: -------------------------------------------------------------------------------- 1 | // Progress bars 2 | 3 | @mixin progress-bar-variant($color) { 4 | background-color: $color; 5 | 6 | // Deprecated parent class requirement as of v3.2.0 7 | .progress-striped & { 8 | @include gradient-striped; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/password_reset.txt: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.txt" %} 2 | Została złożona prośba resetu hasła dla użytkownika {{ email }}. 3 | 4 | Zmiany możesz dokonać za pomocą adresu: 5 | {{ protocol}}://{{ domain }}{% url 'password_reset_confirm' uidb64=uid token=token %} 6 | {% endblock %} 7 | -------------------------------------------------------------------------------- /manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | import os 3 | import sys 4 | 5 | if __name__ == "__main__": 6 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "volontulo_org.settings") 7 | 8 | from django.core.management import execute_from_command_line 9 | 10 | execute_from_command_line(sys.argv) 11 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_text-emphasis.scss: -------------------------------------------------------------------------------- 1 | // Typography 2 | 3 | // [converter] $parent hack 4 | @mixin text-emphasis-variant($parent, $color) { 5 | #{$parent} { 6 | color: $color; 7 | } 8 | a#{$parent}:hover, 9 | a#{$parent}:focus { 10 | color: darken($color, 10%); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_reset-filter.scss: -------------------------------------------------------------------------------- 1 | // Reset filters for IE 2 | // 3 | // When you need to remove a gradient background, do not forget to use this to reset 4 | // the IE filter for IE9 and below. 5 | 6 | @mixin reset-filter() { 7 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 8 | } 9 | -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/page_detail.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | {% load bootstrap3 %} 3 | 4 | {% block title %}{{ object.title }}{% endblock %} 5 | {% block content %} 6 |

{{ object.title }}

7 |
Dodał: {{ object.author }}
8 | {{ object.content|safe }} 9 | {% endblock %} -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_nav-divider.scss: -------------------------------------------------------------------------------- 1 | // Horizontal dividers 2 | // 3 | // Dividers (basically an hr) within dropdowns and nav lists 4 | 5 | @mixin nav-divider($color: #e5e5e5) { 6 | height: 1px; 7 | margin: (($line-height-computed / 2) - 1) 0; 8 | overflow: hidden; 9 | background-color: $color; 10 | } 11 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/volunteer_to_organisation.txt: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.txt" %} 2 | {% block email_content %} 3 | Wolontariusz chce skontaktować się z Twoją organizacją. 4 | 5 | Imię i nazwisko: {{ name }}, 6 | Email: {{ email }}, 7 | Numer telefonu: {{ phone_no }}, 8 | Wiadomość: 9 | {{ message}}, 10 | {% endblock %} 11 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/iconify/icons.fallback.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Svg datauri background images generated by gulp-iconify task 3 | // -------------------------------------------------- 4 | 5 | %asterisk-icon { 6 | background-image: url('..\static\volontulo\img\icons\png\asterisk.png'); 7 | background-repeat: no-repeat; 8 | } 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_background-variant.scss: -------------------------------------------------------------------------------- 1 | // Contextual backgrounds 2 | 3 | // [converter] $parent hack 4 | @mixin bg-variant($parent, $color) { 5 | #{$parent} { 6 | background-color: $color; 7 | } 8 | a#{$parent}:hover, 9 | a#{$parent}:focus { 10 | background-color: darken($color, 10%); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/icons/template/icon_gen.scss.mustache: -------------------------------------------------------------------------------- 1 | // 2 | // Svg datauri background images generated by gulp-iconify task 3 | // -------------------------------------------------- 4 | 5 | {{#items}} 6 | %{{slug}}-icon { 7 | background-image: url('{{{datauri}}}'); 8 | background-repeat: no-repeat; 9 | } 10 | {{/items}} 11 | -------------------------------------------------------------------------------- /apps/volontulo/admin.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """ 4 | .. module:: admin 5 | """ 6 | 7 | from django.contrib import admin 8 | 9 | from apps.volontulo.models import ( 10 | UserProfile, 11 | Organization, 12 | Offer 13 | ) 14 | 15 | 16 | admin.site.register(UserProfile) 17 | admin.site.register(Organization) 18 | admin.site.register(Offer) 19 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_alerts.scss: -------------------------------------------------------------------------------- 1 | // Alerts 2 | 3 | @mixin alert-variant($background, $border, $text-color) { 4 | background-color: $background; 5 | border-color: $border; 6 | color: $text-color; 7 | 8 | hr { 9 | border-top-color: darken($border, 5%); 10 | } 11 | .alert-link { 12 | color: darken($text-color, 10%); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /etc/local_config.yaml.sample: -------------------------------------------------------------------------------- 1 | # Fill the values 2 | 3 | secret_key: # generate the key using unix "head -c 64 /dev/urandom | base64 -w 0" 4 | allowed_host: # Site's domain. Important in production mode 5 | 6 | # Database Credentials 7 | # Example 8 | # db_user: awesome_username 9 | # db_pass: my-ultra-strong-password 10 | # etc. 11 | 12 | db_host: 13 | db_port: 14 | db_name: 15 | db_user: 16 | db_pass: 17 | 18 | 19 | -------------------------------------------------------------------------------- /requirements/dev.txt: -------------------------------------------------------------------------------- 1 | -r base.txt # includes travis.txt requirements file 2 | 3 | colorama==0.3.3 4 | django-coverage==1.2 5 | django-debug-toolbar==1.4 6 | django-extensions==1.5 7 | fake-factory==0.5.3 8 | ipdb==0.8.1 9 | 10 | # tests 11 | astroid==1.4.8 12 | codecov==1.4.1 13 | coverage==4.0 14 | django-nose==1.4.2 15 | pep8==1.6.2 16 | pylint==1.6.4 17 | pylint-django==0.7.2 18 | pylint-plugin-utils==0.2.4 19 | -------------------------------------------------------------------------------- /apps/volontulo/templates/common/col1.html: -------------------------------------------------------------------------------- 1 | {% extends "common/base.html" %} 2 | 3 | {% block layout %} 4 |
5 |
6 | {% block content-heading %} 7 | {% endblock %} 8 |
9 |
10 |
11 |
12 | {% block content %} 13 | {% endblock %} 14 |
15 |
16 | 17 | {% endblock %} 18 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/volunteer_to_admin.txt: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.txt" %} 2 | {% block email_content %} 3 | Witaj 4 | 5 | Dziękujemy za pytanie. Nasz doradca skontaktuje się z Tobą mailowo lub telefonicznie. 6 | Twoja wiadomość znajduje się poniżej: 7 | 8 | Imię i nazwisko: {{ name}}, 9 | Email: {{ email }}, 10 | Numer telefonu: {{ phone_no }}, 11 | Aplikant: {{ applicant }}, 12 | Wiadomość: 13 | {{ message }} 14 | {% endblock %} 15 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/offer_creation.txt: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.txt" %} 2 | {% block email_content %} 3 | Witaj 4 | 5 | Dziękujemy za skorzystanie z naszego portalu. 6 | Twoja oferta czeka na weryfikację administratora i w ciągu 48h pojawi się w sieci. 7 | Adres: {{ protocol }}://{{ domain }}{% url 'offers_view' offer.title|slugify offer.id %} 8 | 9 | W wolnej chwili serdecznie zapraszamy do naszego Centrum Wolontariatu. 10 | {% endblock %} 11 | -------------------------------------------------------------------------------- /apps/volontulo/migrations/0007_remove_page_slug.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('volontulo', '0006_page'), 11 | ] 12 | 13 | operations = [ 14 | migrations.RemoveField( 15 | model_name='page', 16 | name='slug', 17 | ), 18 | ] 19 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_nav-vertical-align.scss: -------------------------------------------------------------------------------- 1 | // Navbar vertical align 2 | // 3 | // Vertically center elements in the navbar. 4 | // Example: an element has a height of 30px, so write out `.navbar-vertical-align(30px);` to calculate the appropriate top margin. 5 | 6 | @mixin navbar-vertical-align($element-height) { 7 | margin-top: (($navbar-height - $element-height) / 2); 8 | margin-bottom: (($navbar-height - $element-height) / 2); 9 | } 10 | -------------------------------------------------------------------------------- /PULL_REQUEST_TEMPLATE: -------------------------------------------------------------------------------- 1 | __Story / Bug id:__ https://github.com/stxnext-csr/volontulo/issues/123 2 | __Reference person:__ @yourgithubname 3 | __Description:__ 4 | 5 | Description of your changes. 6 | 7 | __New imports / dependencies:__ 8 | 9 | * `package` 10 | 11 | __Unit Tests:__ 12 | 13 | * `apps/volontulo/tests/views/test_auth.py` 14 | 15 | __What tests do I need to run to validate this change:__ 16 | 17 | Description of testing workflow and potential affected places. 18 | -------------------------------------------------------------------------------- /apps/volontulo/templatetags/labeled_status.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: labeled_status 5 | """ 6 | 7 | from django import template 8 | 9 | from apps.volontulo.utils import OFFERS_STATUSES 10 | 11 | 12 | register = template.Library() 13 | 14 | 15 | @register.filter(name='human') 16 | def human(status): 17 | u"""Get offer status description. 18 | 19 | :param status: string Status key 20 | """ 21 | return OFFERS_STATUSES.get(status, status) 22 | -------------------------------------------------------------------------------- /apps/volontulo/templatetags/offer_utilities.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: offer_utilities 5 | """ 6 | 7 | from django import template 8 | 9 | register = template.Library() 10 | 11 | 12 | @register.filter(name='can_edit_offer') 13 | def can_edit_offer(userprofile, offer): 14 | u"""Return whether the user can edit an offer based on an ID.""" 15 | if userprofile is None: 16 | return False 17 | return userprofile.can_edit_offer(offer=offer) 18 | -------------------------------------------------------------------------------- /volontulo_org/wsgi.py: -------------------------------------------------------------------------------- 1 | """ 2 | WSGI config for volontulo_org project. 3 | 4 | It exposes the WSGI callable as a module-level variable named ``application``. 5 | 6 | For more information on this file, see 7 | https://docs.djangoproject.com/en/1.8/howto/deployment/wsgi/ 8 | """ 9 | 10 | import os 11 | 12 | from django.core.wsgi import get_wsgi_application 13 | 14 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "volontulo_org.settings") 15 | 16 | application = get_wsgi_application() 17 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/offer_application.txt: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.txt" %} 2 | {% block email_content %} 3 | Witaj 4 | 5 | Wolontariusz zgłosił się na pomoc w ofercie: 6 | {{ protocol }}://{{ domain }}{% url 'offers_view' offer.title|slugify offer.id %} 7 | Prosimy o wzajemny kontakt w celu ustalenia wszystkich szczegółów wolontariatu. 8 | 9 | Imię i nazwisko: {{ fullname }} 10 | Email wolontariusza: {{ email }} 11 | Numer telefonu: {{ phone_no }} 12 | Uwagi wolontariusza: 13 | {{ comments }} 14 | {% endblock %} 15 | -------------------------------------------------------------------------------- /apps/volontulo/migrations/0002_userprofile_phone_no.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('volontulo', '0001_initial'), 11 | ] 12 | 13 | operations = [ 14 | migrations.AddField( 15 | model_name='userprofile', 16 | name='phone_no', 17 | field=models.CharField(blank=True, null=True, max_length=32, default=''), 18 | ), 19 | ] 20 | -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/page_edit_form.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | {% load bootstrap3 %} 3 | 4 | {% block title %}{{ offer.id|yesno:"Edycja,Tworzenie" }} strony{% endblock %} 5 | {% block content %} 6 |
7 | {% csrf_token %} 8 | {% bootstrap_form form %} 9 | {% buttons %} 10 | 13 | {% endbuttons %} 14 |
15 | {% endblock %} -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/regulations.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Regulamin{% endblock %} 4 | 5 | {% block content %} 6 |

Regulamin

7 |

§1

8 |
    9 |
  1. 10 |

    Myj zęby

    11 |
  2. 12 |
  3. 13 |

    Śniadanie najważniejszym posiłkiem dnia

    14 |
  4. 15 |
16 |

§2

17 |
    18 |
  1. 19 |

    Miej ręcznik

    20 |
  2. 21 |
22 | 23 | {% endblock %} 24 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/test_newsletter.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: test_newsletter 5 | """ 6 | from django.test import TestCase 7 | 8 | 9 | class TestNews(TestCase): 10 | u"""Class responsible for testing newsletter specific views.""" 11 | 12 | def test__newsletter(self): 13 | u"""Test getting newsletter signup page as anonymous.""" 14 | response = self.client.get('/newsletter', follow=True) 15 | 16 | self.assertEqual(response.status_code, 200) 17 | self.assertTemplateUsed(response, 'newsletter_signup.html') 18 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/customization/_extended-media.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Extended bootstrap media 3 | // -------------------------------------------------- 4 | 5 | .media { 6 | display: table; 7 | height: 100%; 8 | .media-left, 9 | .media-right, 10 | .media-body { 11 | height: 100%; 12 | } 13 | &.row { 14 | .media-left, 15 | .media-right, 16 | .media-body { 17 | padding-left: ($grid-gutter-width / 2); 18 | padding-right: ($grid-gutter-width / 2); 19 | float: none; 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /apps/volontulo/templates/users/gallery.html: -------------------------------------------------------------------------------- 1 | {% load bootstrap3 %} 2 |
3 | {% csrf_token %} 4 |
5 |

{% bootstrap_form user_avatar_form %}

6 |

Proszę o uwzględnienie formatu zdjęcia: jpg, gif, png, bmp

7 |
8 |
9 | 11 |
12 |
13 | -------------------------------------------------------------------------------- /apps/volontulo/templatetags/main_image.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: main_image 5 | """ 6 | 7 | from django import template 8 | 9 | 10 | register = template.Library() 11 | 12 | 13 | @register.filter(name='main_image') 14 | def main_image(images): 15 | u"""Get main or first image from all offer images. 16 | 17 | :param images: list Offer images 18 | """ 19 | main_img = [str(i) for i in images if i.is_main] 20 | if main_img: 21 | return str(main_img[0]) 22 | 23 | if not main_img and images: 24 | return images[0] 25 | 26 | return '' 27 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_reset-text.scss: -------------------------------------------------------------------------------- 1 | @mixin reset-text() { 2 | font-family: $font-family-base; 3 | // We deliberately do NOT reset font-size. 4 | font-style: normal; 5 | font-weight: normal; 6 | letter-spacing: normal; 7 | line-break: auto; 8 | line-height: $line-height-base; 9 | text-align: left; // Fallback for where `start` is not supported 10 | text-align: start; 11 | text-decoration: none; 12 | text-shadow: none; 13 | text-transform: none; 14 | white-space: normal; 15 | word-break: normal; 16 | word-spacing: normal; 17 | word-wrap: normal; 18 | } 19 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/customization/_extended-thumbnail.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Extended bootstrap thumbnail 3 | // -------------------------------------------------- 4 | 5 | .thumbnail { 6 | border: 0; 7 | padding: 0; 8 | @include box-shadow(0 1px 2px rgba(black, .2)); 9 | .heading-image { 10 | padding-top: 75%; 11 | background-position: center; 12 | background-size: cover; 13 | @include border-top-radius(3px); 14 | } 15 | h1, h2, h3, h4, h5, h6 { 16 | margin: 10px 0 10px; 17 | font-size: 16px; 18 | font-weight: bold; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_border-radius.scss: -------------------------------------------------------------------------------- 1 | // Single side border-radius 2 | 3 | @mixin border-top-radius($radius) { 4 | border-top-right-radius: $radius; 5 | border-top-left-radius: $radius; 6 | } 7 | @mixin border-right-radius($radius) { 8 | border-bottom-right-radius: $radius; 9 | border-top-right-radius: $radius; 10 | } 11 | @mixin border-bottom-radius($radius) { 12 | border-bottom-right-radius: $radius; 13 | border-bottom-left-radius: $radius; 14 | } 15 | @mixin border-left-radius($radius) { 16 | border-bottom-left-radius: $radius; 17 | border-top-left-radius: $radius; 18 | } 19 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_pagination.scss: -------------------------------------------------------------------------------- 1 | // Pagination 2 | 3 | @mixin pagination-size($padding-vertical, $padding-horizontal, $font-size, $line-height, $border-radius) { 4 | > li { 5 | > a, 6 | > span { 7 | padding: $padding-vertical $padding-horizontal; 8 | font-size: $font-size; 9 | line-height: $line-height; 10 | } 11 | &:first-child { 12 | > a, 13 | > span { 14 | @include border-left-radius($border-radius); 15 | } 16 | } 17 | &:last-child { 18 | > a, 19 | > span { 20 | @include border-right-radius($border-radius); 21 | } 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_responsive-visibility.scss: -------------------------------------------------------------------------------- 1 | // Responsive utilities 2 | 3 | // 4 | // More easily include all the states for responsive-utilities.less. 5 | // [converter] $parent hack 6 | @mixin responsive-visibility($parent) { 7 | #{$parent} { 8 | display: block !important; 9 | } 10 | table#{$parent} { display: table !important; } 11 | tr#{$parent} { display: table-row !important; } 12 | th#{$parent}, 13 | td#{$parent} { display: table-cell !important; } 14 | } 15 | 16 | // [converter] $parent hack 17 | @mixin responsive-invisibility($parent) { 18 | #{$parent} { 19 | display: none !important; 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /apps/volontulo/templates/admin/offers_nav.html: -------------------------------------------------------------------------------- 1 | {% block content %} 2 | 8 | {% endblock %} 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_panels.scss: -------------------------------------------------------------------------------- 1 | // Panels 2 | 3 | @mixin panel-variant($border, $heading-text-color, $heading-bg-color, $heading-border) { 4 | border-color: $border; 5 | 6 | & > .panel-heading { 7 | color: $heading-text-color; 8 | background-color: $heading-bg-color; 9 | border-color: $heading-border; 10 | 11 | + .panel-collapse > .panel-body { 12 | border-top-color: $border; 13 | } 14 | .badge { 15 | color: $heading-bg-color; 16 | background-color: $heading-text-color; 17 | } 18 | } 19 | & > .panel-footer { 20 | + .panel-collapse > .panel-body { 21 | border-bottom-color: $border; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /apps/volontulo/templates/auth/password_reset_confirm.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Resetowanie hasła{% endblock %} 4 | 5 | {% block content %} 6 |

Resetowanie hasła

7 | 8 |
9 | {% csrf_token %} 10 | 11 |

12 | 13 |

14 | 15 |

16 |
17 | 18 | {% endblock %} 19 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_wells.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Wells 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base class 7 | .well { 8 | min-height: 20px; 9 | padding: 19px; 10 | margin-bottom: 20px; 11 | background-color: $well-bg; 12 | border: 1px solid $well-border; 13 | border-radius: $border-radius-base; 14 | @include box-shadow(inset 0 1px 1px rgba(0,0,0,.05)); 15 | blockquote { 16 | border-color: #ddd; 17 | border-color: rgba(0,0,0,.15); 18 | } 19 | } 20 | 21 | // Sizes 22 | .well-lg { 23 | padding: 24px; 24 | border-radius: $border-radius-large; 25 | } 26 | .well-sm { 27 | padding: 9px; 28 | border-radius: $border-radius-small; 29 | } 30 | -------------------------------------------------------------------------------- /apps/volontulo/templates/auth/password_reset.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Resetowanie hasła{% endblock %} 4 | 5 | {% block content %} 6 |

Resetowanie hasła

7 | 8 |
9 | {% csrf_token %} 10 |
11 | {{ user_form.email.label_tag }} 12 | 13 |
14 | 15 |
16 | {% endblock %} 17 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_hide-text.scss: -------------------------------------------------------------------------------- 1 | // CSS image replacement 2 | // 3 | // Heads up! v3 launched with only `.hide-text()`, but per our pattern for 4 | // mixins being reused as classes with the same name, this doesn't hold up. As 5 | // of v3.0.1 we have added `.text-hide()` and deprecated `.hide-text()`. 6 | // 7 | // Source: https://github.com/h5bp/html5-boilerplate/commit/aa0396eae757 8 | 9 | // Deprecated as of v3.0.1 (will be removed in v4) 10 | @mixin hide-text() { 11 | font: 0/0 a; 12 | color: transparent; 13 | text-shadow: none; 14 | background-color: transparent; 15 | border: 0; 16 | } 17 | 18 | // New mixin to use as of v3.0.1 19 | @mixin text-hide() { 20 | @include hide-text; 21 | } 22 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/registration.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/user_layout.html" %} 2 | 3 | {% load staticfiles %} 4 | 5 | {% block title %}Rejestracja{% endblock %} 6 | 7 | {% block email_content %} 8 |
9 |
10 |
11 | Dziękujemy za rejestrację.
12 |
13 | Zweryfikuj swoje konto na Volontulo wchodząc w poniższy link:
14 | Aktywuj 15 |
16 | {% endblock %} 17 | 18 | {% block email_info_details %} 19 | {% include "emails/site_owner_details.html" %} 20 | {% endblock %} 21 | -------------------------------------------------------------------------------- /apps/volontulo/migrations/0004_auto_20151118_1157.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('volontulo', '0003_offer_weight'), 11 | ] 12 | 13 | operations = [ 14 | migrations.AlterField( 15 | model_name='offer', 16 | name='requirements', 17 | field=models.TextField(default='', blank=True), 18 | ), 19 | migrations.AlterField( 20 | model_name='offerimage', 21 | name='offer', 22 | field=models.ForeignKey(to='volontulo.Offer', related_name='images'), 23 | ), 24 | ] 25 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/base.txt: -------------------------------------------------------------------------------- 1 | VOLONTULO 2 | 3 | {% block email_content %} 4 | {% endblock %} 5 | 6 | --- 7 | 8 | Zapraszamy do Centrum Wolontariatu na dyżury dla wolontariuszy i organizatorów wolontariatu. Odbywają się one w każdy wtorek w godz. 16:00 - 18:00 lub w czwartek w godz. 16:00 - 18:00 w Centrum Bukowska (ul. Bukowskiej 27/29). 9 | 10 | Z pozdrowieniami 11 | Zespół Centrum Wolontariatu w Poznaniu 12 | ul. Bukowska 27/29, 60-501 Poznań 13 | tel. 61 85 30 930, 61 62 32 145 14 | wolontariat@wrk.org.pl, www.wolontariat.wrk.org.pl 15 | 16 | Wielkopolska Rada Koordynacyjna Związek Organizacji Pozarządowych (www.wrk.org.pl) należy do Ogólnopolskiej Sieci Centrów Wolontariatu i prowadzi Regionalne Centrum Wolontariatu w Poznaniu. 17 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_responsive-embed.scss: -------------------------------------------------------------------------------- 1 | // Embeds responsive 2 | // 3 | // Credit: Nicolas Gallagher and SUIT CSS. 4 | 5 | .embed-responsive { 6 | position: relative; 7 | display: block; 8 | height: 0; 9 | padding: 0; 10 | overflow: hidden; 11 | 12 | .embed-responsive-item, 13 | iframe, 14 | embed, 15 | object, 16 | video { 17 | position: absolute; 18 | top: 0; 19 | left: 0; 20 | bottom: 0; 21 | height: 100%; 22 | width: 100%; 23 | border: 0; 24 | } 25 | } 26 | 27 | // Modifier class for 16:9 aspect ratio 28 | .embed-responsive-16by9 { 29 | padding-bottom: 56.25%; 30 | } 31 | 32 | // Modifier class for 4:3 aspect ratio 33 | .embed-responsive-4by3 { 34 | padding-bottom: 75%; 35 | } 36 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_clearfix.scss: -------------------------------------------------------------------------------- 1 | // Clearfix 2 | // 3 | // For modern browsers 4 | // 1. The space content is one way to avoid an Opera bug when the 5 | // contenteditable attribute is included anywhere else in the document. 6 | // Otherwise it causes space to appear at the top and bottom of elements 7 | // that are clearfixed. 8 | // 2. The use of `table` rather than `block` is only necessary if using 9 | // `:before` to contain the top-margins of child elements. 10 | // 11 | // Source: http://nicolasgallagher.com/micro-clearfix-hack/ 12 | 13 | @mixin clearfix() { 14 | &:before, 15 | &:after { 16 | content: " "; // 1 17 | display: table; // 2 18 | } 19 | &:after { 20 | clear: both; 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /volontulo_org/settings/dev.py: -------------------------------------------------------------------------------- 1 | """ 2 | Development Settings Module 3 | """ 4 | 5 | from .base import * 6 | 7 | DEBUG = True 8 | 9 | ALLOWED_HOSTS = [] 10 | 11 | DEBUG_TOOLBAR_PATCH_SETTINGS = False 12 | 13 | INSTALLED_APPS += ( 14 | 'debug_toolbar', 15 | 'django_coverage', 16 | 'django_extensions', 17 | 'django_nose' 18 | ) 19 | 20 | TEST_RUNNER = 'django_nose.NoseTestSuiteRunner' 21 | 22 | EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend' 23 | 24 | DATABASES = { 25 | 'default': { 26 | 'ENGINE': 'django.db.backends.sqlite3', 27 | 'NAME': 'db.sqlite3', 28 | } 29 | } 30 | 31 | EMAIL_BACKEND = 'django.core.mail.backends.filebased.EmailBackend' 32 | EMAIL_FILE_PATH = os.path.join(BASE_DIR, 'fake_emails') 33 | -------------------------------------------------------------------------------- /apps/volontulo/templates/common/labeled_status.html: -------------------------------------------------------------------------------- 1 | {% load labeled_status %} 2 | 3 | {% if status %} 4 | {% if status == 'NEW' %} 5 | {{ status|human }} 6 | {% elif status == 'ACTIVE' %} 7 | {{ status|human }} 8 | {% elif status == 'FINISHED' %} 9 | {{ status|human }} 10 | {% elif status == 'SUSPENDED' %} 11 | {{ status|human }} 12 | {% elif status == 'CLOSED' %} 13 | {{ status|human }} 14 | {% else %} 15 | {{ status|human }} 16 | {% endif %} 17 | {% endif %} 18 | -------------------------------------------------------------------------------- /apps/volontulo/templates/common/col2.html: -------------------------------------------------------------------------------- 1 | {% extends "common/base.html" %} 2 | 3 | {% block layout %} 4 |
5 |
6 | {% block content-heading %} 7 | {% endblock %} 8 |
9 |
10 |
11 |
12 |
13 |
14 | {% block sidebar %} 15 | Sidebar block 16 | {% endblock %} 17 |
18 |
19 | {% block content %} 20 | Content block 21 | {% endblock %} 22 |
23 |
24 |
25 |
26 | {% endblock %} 27 | -------------------------------------------------------------------------------- /volontulo_org/urls.py: -------------------------------------------------------------------------------- 1 | from os import path 2 | 3 | from django.conf import settings 4 | from django.conf.urls import include 5 | from django.conf.urls import url 6 | from django.contrib import admin 7 | 8 | PROJECT_ROOT = path.dirname(path.dirname(__file__)) 9 | 10 | urlpatterns = [ 11 | url(r'', include('apps.volontulo.urls')), 12 | url(r'^admin/', include(admin.site.urls)), 13 | url( 14 | r'^static/(?P.*)$', 15 | 'django.views.static.serve', 16 | { 17 | 'document_root': path.join(PROJECT_ROOT, 'static') 18 | } 19 | ), 20 | url( 21 | r'^media/(?P.*)$', 22 | 'django.views.static.serve', 23 | { 24 | 'document_root': settings.MEDIA_ROOT 25 | } 26 | ), 27 | ] 28 | -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/office.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %} Przyjdź na dyżur {% endblock %} 4 | 5 | {% block content %} 6 |

Przyjdź na dyżur

7 |
8 |
Zapraszamy do naszego biura, które znajduje się przy ul. Bukowskiej 27/29 w Poznaniu.
9 |
Dyżury dla wolontariuszy oraz organizacji i instytucji współpracujących z wolontariuszami odbywają się w każdy wtorek w godz. 16.00-18.00 i czwartek w godz. 16.00-18.00.
10 | 11 |
Możesz też skontaktować się z nami mailowo: wolontariat@wrk.org.pl lub telefonicznie: 61 85 30 930.
12 | 13 |
Zachęcamy do kontaktu :)
14 |
15 | {% endblock %} 16 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/open-sans/_mixins.scss: -------------------------------------------------------------------------------- 1 | @mixin fontdef($OpenSansPath, $OpenSansVersion, $FontType:"Regular") { 2 | src: url('#{$OpenSansPath}/#{$FontType}/OpenSans-#{$FontType}.eot?v=#{$OpenSansVersion}'); 3 | src: url('#{$OpenSansPath}/#{$FontType}/OpenSans-#{$FontType}.eot?#iefix&v=#{$OpenSansVersion}') format('embedded-opentype'), 4 | url('#{$OpenSansPath}/#{$FontType}/OpenSans-#{$FontType}.woff2?v=#{$OpenSansVersion}') format('woff2'), 5 | url('#{$OpenSansPath}/#{$FontType}/OpenSans-#{$FontType}.woff?v=#{$OpenSansVersion}') format('woff'), 6 | url('#{$OpenSansPath}/#{$FontType}/OpenSans-#{$FontType}.ttf?v=#{$OpenSansVersion}') format('truetype'), 7 | url('#{$OpenSansPath}/#{$FontType}/OpenSans-#{$FontType}.svg?v=#{$OpenSansVersion}##{$FontType}') format('svg'); 8 | } 9 | -------------------------------------------------------------------------------- /apps/volontulo/templates/organizations/list.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Lista organizacji{% endblock %} 4 | 5 | {% block content %} 6 | {% if organizations %} 7 |

Lista organizacji

8 | 9 | 10 | 11 | 12 | 13 | {% for o in organizations %} 14 | 15 | 16 | 17 | 18 | {% endfor %} 19 |
NazwaAdres
{{ o.name }}{{ o.address }}
20 | {% else %} 21 |

Brak zdefiniowanych organizacji.

22 | {% endif %} 23 | 24 | {% endblock %} 25 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/password_reset.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/user_layout.html" %} 2 | 3 | {% load staticfiles %} 4 | 5 | {% block title %}Resetowanie hasła{% endblock %} 6 | 7 | {% block email_content %} 8 |
9 |
10 |
11 | Została złożona prośba resetu hasła dla użytkownika:
12 | {{ email }}
13 |
14 | Zmiany możesz dokonać za pomocą poniższego linku:
15 | Resetuj hasło 16 |
17 | {% endblock %} 18 | 19 | {% block email_info_details %} 20 | {% include "emails/site_owner_details.html" %} 21 | {% endblock %} 22 | -------------------------------------------------------------------------------- /apps/volontulo/templates/offers/applied_volunteers.html: -------------------------------------------------------------------------------- 1 | {% if volunteers %} 2 |

Lista wolontariuszy, którzy zgłosili chęć pomocy

3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | {% for volunteer in volunteers %} 11 | 12 | 13 | 14 | 15 | 16 | 17 | {% endfor %} 18 |
IDImię i nazwiskoEmailKontakt
{{ volunteer.id }}{{ volunteer.first_name }} {{ volunteer.last_name }}{{ volunteer.email }}Formularz kontaktowy
19 | {% else %} 20 |

Dla tej oferty nie ma jeszcze zgłoszeń wolontariuszy.

21 | {% endif %} 22 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_breadcrumbs.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Breadcrumbs 3 | // -------------------------------------------------- 4 | 5 | 6 | .breadcrumb { 7 | padding: $breadcrumb-padding-vertical $breadcrumb-padding-horizontal; 8 | margin-bottom: $line-height-computed; 9 | list-style: none; 10 | background-color: $breadcrumb-bg; 11 | border-radius: $border-radius-base; 12 | 13 | > li { 14 | display: inline-block; 15 | 16 | + li:before { 17 | // [converter] Workaround for https://github.com/sass/libsass/issues/1115 18 | $nbsp: "\00a0"; 19 | content: "#{$breadcrumb-separator}#{$nbsp}"; // Unicode space added since inline-block means non-collapsing white-space 20 | padding: 0 5px; 21 | color: $breadcrumb-color; 22 | } 23 | } 24 | 25 | > .active { 26 | color: $breadcrumb-active-color; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_list-group.scss: -------------------------------------------------------------------------------- 1 | // List Groups 2 | 3 | @mixin list-group-item-variant($state, $background, $color) { 4 | .list-group-item-#{$state} { 5 | color: $color; 6 | background-color: $background; 7 | 8 | // [converter] extracted a&, button& to a.list-group-item-#{$state}, button.list-group-item-#{$state} 9 | } 10 | 11 | a.list-group-item-#{$state}, 12 | button.list-group-item-#{$state} { 13 | color: $color; 14 | 15 | .list-group-item-heading { 16 | color: inherit; 17 | } 18 | 19 | &:hover, 20 | &:focus { 21 | color: $color; 22 | background-color: darken($background, 5%); 23 | } 24 | &.active, 25 | &.active:hover, 26 | &.active:focus { 27 | color: #fff; 28 | background-color: $color; 29 | border-color: $color; 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /apps/volontulo/migrations/0003_offer_weight.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | def populate_null_weight_rows(apps, schema_editor): 8 | Offer = apps.get_model('volontulo', 'Offer') 9 | records = Offer.objects.filter(weight__isnull=True) 10 | for row in records: 11 | row.weight = 0 12 | Offer(**row).save() 13 | 14 | class Migration(migrations.Migration): 15 | 16 | dependencies = [ 17 | ('volontulo', '0002_userprofile_phone_no'), 18 | ] 19 | 20 | operations = [ 21 | migrations.AddField( 22 | model_name='offer', 23 | name='weight', 24 | field=models.IntegerField(blank=True, default=0, null=True), 25 | ), 26 | migrations.RunPython(populate_null_weight_rows), 27 | ] 28 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/offer_creation.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/user_layout.html" %} 2 | 3 | {% load staticfiles %} 4 | 5 | {% block title %}Zgłoszenie oferty{% endblock %} 6 | 7 | {% block email_content %} 8 |
9 |
10 |
11 | Witaj
12 |
13 |
14 | Dziękujemy za skorzystanie z naszego portalu.
15 |
16 | Twoja oferta czeka na weryfikację administratora i w ciągu 48h pojawi się w sieci.
17 |
18 | W wolnej chwili serdecznie zapraszamy do naszego Centrum Wolontariatu.
19 | {% endblock %} 20 | 21 | {% block email_info_details %} 22 | {% include "emails/site_owner_details.html" %} 23 | {% endblock %} 24 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/javascripts/cookielaw/js/cookielaw.js: -------------------------------------------------------------------------------- 1 | var Cookielaw = { 2 | 3 | createCookie: function (name, value, days) { 4 | var date = new Date(), 5 | expires = ''; 6 | if (days) { 7 | date.setTime(date.getTime() + (days * 24 * 60 * 60 * 1000)); 8 | expires = "; expires=" + date.toGMTString(); 9 | } else { 10 | expires = ""; 11 | } 12 | document.cookie = name + "=" + value + expires + "; path=/"; 13 | }, 14 | 15 | createCookielawCookie: function () { 16 | this.createCookie('cookielaw_accepted', '1', 10 * 365); 17 | 18 | if (typeof (window.jQuery) === 'function') { 19 | jQuery('#CookielawBanner').slideUp(); 20 | } else { 21 | document.getElementById('CookielawBanner').style.display = 'none'; 22 | } 23 | } 24 | 25 | }; 26 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_table-row.scss: -------------------------------------------------------------------------------- 1 | // Tables 2 | 3 | @mixin table-row-variant($state, $background) { 4 | // Exact selectors below required to override `.table-striped` and prevent 5 | // inheritance to nested tables. 6 | .table > thead > tr, 7 | .table > tbody > tr, 8 | .table > tfoot > tr { 9 | > td.#{$state}, 10 | > th.#{$state}, 11 | &.#{$state} > td, 12 | &.#{$state} > th { 13 | background-color: $background; 14 | } 15 | } 16 | 17 | // Hover states for `.table-hover` 18 | // Note: this is not available for cells or rows within `thead` or `tfoot`. 19 | .table-hover > tbody > tr { 20 | > td.#{$state}:hover, 21 | > th.#{$state}:hover, 22 | &.#{$state}:hover > td, 23 | &:hover > .#{$state}, 24 | &.#{$state}:hover > th { 25 | background-color: darken($background, 5%); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/customization/_auto-clear.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Automatically clears first items in a column row 3 | // -------------------------------------------------- 4 | 5 | @mixin row-first-child($col-type) { 6 | .col-#{$col-type}- { 7 | &1:nth-child(12n+1), 8 | &2:nth-child(6n+1), 9 | &3:nth-child(4n+1), 10 | &4:nth-child(3n+1), 11 | &6:nth-child(odd){ 12 | clear: left; 13 | } 14 | } 15 | } 16 | 17 | .auto-clear { 18 | @media (min-width: $screen-lg-min){ 19 | @include row-first-child(lg); 20 | } 21 | @media (min-width: $screen-md-min) and (max-width: $screen-md-max){ 22 | @include row-first-child(md); 23 | } 24 | @media (min-width: $screen-sm-min) and (max-width: $screen-sm-max){ 25 | @include row-first-child(sm); 26 | } 27 | @media (max-width: $screen-xs-max){ 28 | @include row-first-child(xs); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: python 2 | python: 3 | - "3.4" 4 | install: 5 | - "pip install -r requirements/dev.txt" 6 | script: 7 | - "cp etc/local_config.yaml.sample local_config.yaml" 8 | - "sed -i 's/secret_key:.*/secret_key: classified_secret_key/g' local_config.yaml" 9 | - "sed -i 's/db_host:.*/db_host: localhost/g' local_config.yaml" 10 | - "sed -i 's/db_port:.*/db_port: 5432/g' local_config.yaml" 11 | - "sed -i 's/db_name:.*/db_name: volontulo/g' local_config.yaml" 12 | - "sed -i 's/db_user:.*/db_user: postgres/g' local_config.yaml" 13 | - "sed -i 's/db_pass:.*/db_pass:/g' local_config.yaml" 14 | - "pep8 --exclude='apps/volontulo/migrations/*,node_modules,.ropeproject' ." 15 | - "pylint apps" 16 | - "coverage run --source='./apps' manage.py test --settings=volontulo_org.settings.dev -v 3" 17 | - "cd apps/volontulo && npm install && gulp build && cd ../.." 18 | after_success: 19 | - "codecov" 20 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/icons/asterisk.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /apps/volontulo/tests/models/test_organization.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: test_organization 5 | """ 6 | from __future__ import unicode_literals 7 | from django.test import TestCase 8 | 9 | from apps.volontulo.models import Organization 10 | 11 | 12 | class TestOrganization(TestCase): 13 | """Class responsible for testing organization model.""" 14 | 15 | def setUp(self): 16 | """Set up each test.""" 17 | self.organization = Organization.objects.create( 18 | name="Sample organization", 19 | address="Sample organization address", 20 | description="Sample organization description", 21 | ) 22 | 23 | def test__string_reprezentation(self): 24 | """String reprezentation of an organization object.""" 25 | self.assertEqual( 26 | str(self.organization), 27 | "Sample organization" 28 | ) 29 | -------------------------------------------------------------------------------- /initial/data.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "pk": 1, 4 | "model": "auth.user", 5 | "fields": { 6 | "is_staff": false, 7 | "email": "admin@volontuloapp.org", 8 | "first_name": "", 9 | "groups": [], 10 | "password": "pbkdf2_sha256$20000$uDrW54Nh7e0F$1jExxFlpSR1+aPL5fhodxVCx9x0dYXG8P82OWVOB/fI=", 11 | "last_login": "2016-02-25T11:47:59.562Z", 12 | "last_name": "", 13 | "username": "admin@volontuloapp.org", 14 | "is_superuser": false, 15 | "is_active": true, 16 | "date_joined": "2016-02-05T09:34:43.382Z", 17 | "user_permissions": [] 18 | } 19 | }, 20 | { 21 | "pk": 1, 22 | "model": "volontulo.userprofile", 23 | "fields": { 24 | "user": 1, 25 | "organizations": [], 26 | "is_administrator": true, 27 | "phone_no": "", 28 | "uuid": "aa28f486-532b-4530-8fc4-ad3692f2fb49" 29 | } 30 | } 31 | ] -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/iconify/icons.svg.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Svg datauri background images generated by gulp-iconify task 3 | // -------------------------------------------------- 4 | 5 | %asterisk-icon { 6 | background-image: url('data:image/svg+xml;charset=UTF-8,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20height%3D%2216%22%20width%3D%2216%22%20viewBox%3D%220%200%2016%2016%22%3E%3Cpath%20d%3D%22M6.223.4c.016%201.097.177%203.104.484%206.023-1.162-.66-3.025-1.443-5.59-2.346L.005%207.512c1.87.5%203.847.953%205.927%201.356-.806.742-2.146%202.265-4.016%204.57l2.854%202.057c.903-1.193%201.952-2.927%203.145-5.2%201.274%202.193%202.38%203.926%203.315%205.2l2.902-2.056c-1.79-2.194-3.177-3.717-4.16-4.572%201.967-.226%203.975-.68%206.023-1.356l-1.112-3.435c-2.145.71-4.05%201.484-5.71%202.322.323-2.404.508-4.403.556-6H6.222z%22%20fill%3D%22%23da4453%22%2F%3E%3C%2Fsvg%3E'); 7 | background-repeat: no-repeat; 8 | } 9 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/site_owner_details.html: -------------------------------------------------------------------------------- 1 | {% load staticfiles %} 2 | 3 | {% block info_content %} 4 | Zapraszamy do Centrum Wolontariatu na dyżury dla wolontariuszy i organizatorów wolontariatu. Odbywają się one w każdy wtorek w godz. 16:00 - 18:00 lub w czwartek w godz. 16:00 - 18:00 w Centrum Bukowska (ul. Bukowska 27/29).
5 |
6 | Z pozdrowieniami
7 | Zespół Centrum Wolontariatu w Poznaniu
8 | ul. Bukowska 27/29, 60-501 Poznań
9 | tel. 61 85 30 930, 61 62 32 145
10 | wolontariat@wrk.org.pl, www.wolontariat.wrk.org.pl
11 |
12 | Wielkopolska Rada Koordynacyjna Związek Organizacji Pozarządowych (www.wrk.org.pl) należy do Ogólnopolskiej Sieci Centrów Wolontariatu i prowadzi Regionalne Centrum Wolontariatu w Poznaniu. 13 | {% endblock %} 14 | -------------------------------------------------------------------------------- /bin/setup: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | BASEDIR=`dirname $0`/.. 4 | 5 | if [ ! -d "$BASEDIR/env" ]; then 6 | virtualenv -p python3 -q $BASEDIR/env --no-site-packages 7 | echo "Virtualenv created." 8 | fi 9 | 10 | $BASEDIR/env/bin/pip install -r $BASEDIR/requirements/dev.txt 11 | echo "Requirements installed." 12 | 13 | cp $BASEDIR/etc/local_config.yaml.sample $BASEDIR/local_config.yaml 14 | 15 | sed '/^secret_key/ d' $BASEDIR/local_config.yaml > $BASEDIR/tmp.yaml && mv tmp.yaml local_config.yaml 16 | UUID=a63eb5ef-3b25-4595-846a-5d97d99486f0 17 | echo "secret_key: $UUID" >> $BASEDIR/local_config.yaml 18 | 19 | $BASEDIR/env/bin/python manage.py migrate --settings=volontulo_org.settings.dev 20 | $BASEDIR/env/bin/python manage.py loaddata initial/data.json --settings=volontulo_org.settings.dev 21 | 22 | # if npm command gives error "/usr/bin/env: node: No such file or directory 23 | # sudo ln -s /usr/bin/nodejs /usr/bin/node 24 | 25 | cd $BASEDIR/apps/volontulo && npm install && node_modules/.bin/gulp build 26 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_close.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Close icons 3 | // -------------------------------------------------- 4 | 5 | 6 | .close { 7 | float: right; 8 | font-size: ($font-size-base * 1.5); 9 | font-weight: $close-font-weight; 10 | line-height: 1; 11 | color: $close-color; 12 | text-shadow: $close-text-shadow; 13 | @include opacity(.2); 14 | 15 | &:hover, 16 | &:focus { 17 | color: $close-color; 18 | text-decoration: none; 19 | cursor: pointer; 20 | @include opacity(.5); 21 | } 22 | 23 | // [converter] extracted button& to button.close 24 | } 25 | 26 | // Additional properties for button version 27 | // iOS requires the button element instead of an anchor tag. 28 | // If you want the anchor version, it requires `href="#"`. 29 | // See https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile 30 | button.close { 31 | padding: 0; 32 | cursor: pointer; 33 | background: transparent; 34 | border: 0; 35 | -webkit-appearance: none; 36 | } 37 | -------------------------------------------------------------------------------- /apps/volontulo/migrations/0005_removing_badges.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('volontulo', '0004_auto_20151118_1157'), 11 | ] 12 | 13 | operations = [ 14 | migrations.RemoveField( 15 | model_name='userbadges', 16 | name='badge', 17 | ), 18 | migrations.RemoveField( 19 | model_name='userbadges', 20 | name='content_type', 21 | ), 22 | migrations.RemoveField( 23 | model_name='userbadges', 24 | name='userprofile', 25 | ), 26 | migrations.RemoveField( 27 | model_name='userprofile', 28 | name='badges', 29 | ), 30 | migrations.DeleteModel( 31 | name='Badge', 32 | ), 33 | migrations.DeleteModel( 34 | name='UserBadges', 35 | ), 36 | ] 37 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_component-animations.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Component animations 3 | // -------------------------------------------------- 4 | 5 | // Heads up! 6 | // 7 | // We don't use the `.opacity()` mixin here since it causes a bug with text 8 | // fields in IE7-8. Source: https://github.com/twbs/bootstrap/pull/3552. 9 | 10 | .fade { 11 | opacity: 0; 12 | @include transition(opacity .15s linear); 13 | &.in { 14 | opacity: 1; 15 | } 16 | } 17 | 18 | .collapse { 19 | display: none; 20 | 21 | &.in { display: block; } 22 | // [converter] extracted tr&.in to tr.collapse.in 23 | // [converter] extracted tbody&.in to tbody.collapse.in 24 | } 25 | 26 | tr.collapse.in { display: table-row; } 27 | 28 | tbody.collapse.in { display: table-row-group; } 29 | 30 | .collapsing { 31 | position: relative; 32 | height: 0; 33 | overflow: hidden; 34 | @include transition-property(height, visibility); 35 | @include transition-duration(.35s); 36 | @include transition-timing-function(ease); 37 | } 38 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/iconify/icons.png.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Svg datauri background images generated by gulp-iconify task 3 | // -------------------------------------------------- 4 | 5 | %asterisk-icon { 6 | background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAOxAAADsQBlSsOGwAAAddJREFUOI2Vkr9rE3EYxj/vXYo4VO3q4lISELci+KNFbK/gIEVyRkGjCEUdBYvo1JC/oIMWRLqpFDmMujk0DqJbEEWwJMEOgtBiKyiC2ph7HHK5XBIz+N3uuef53Ps+3zMGnJqXvSVsFACF7zLlJ7f/5XMGAZBNG8wazIKND7INBMj4Gj+Ybf03APgS59HGIFPqo5fb/Ufhc2C5SfPh/vLTrSi0DgZAiPO5HVj1Zva6YSqPg7/dcKesNnX6PKYHABK/QYEjLYSOM2ZwL4KdEO4vFF4TmjEzt6VzNgXyO6uyAywvs7yhajyBuGMWjmJgkdbS5Tsy1oU+9W9nmQ44us7EEfpm8D3GrR3P7mu4dsTQIbDDwMHuhCrCVoXemmOv03ucigVB03rJlbErQ8MjmyXDTnbnuZ8eP3DJisUwqfdd466RzaV2WPBGsBH1c6H+6v3dXn8XoOZlC2AX45diDnGzU4tdrnnZ+WQmXqHu+WcEj+KR0bPMSumUwOpe9mXydxacy6w8Xo4nUKHgCM0lwj8R16MviNC9irSdaOSGcjk3BlixGA41ho8hLUaDzWfKpbW2Pf0i+CCzYiurxZ0/3KMWBM3ePgCoTvoTKhT6ylUu51Yn/Yle/S+UhLHhsYTOMgAAAABJRU5ErkJggg=='); 7 | background-repeat: no-repeat; 8 | } 9 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_utilities.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Utility classes 3 | // -------------------------------------------------- 4 | 5 | 6 | // Floats 7 | // ------------------------- 8 | 9 | .clearfix { 10 | @include clearfix; 11 | } 12 | .center-block { 13 | @include center-block; 14 | } 15 | .pull-right { 16 | float: right !important; 17 | } 18 | .pull-left { 19 | float: left !important; 20 | } 21 | 22 | 23 | // Toggling content 24 | // ------------------------- 25 | 26 | // Note: Deprecated .hide in favor of .hidden or .sr-only (as appropriate) in v3.0.1 27 | .hide { 28 | display: none !important; 29 | } 30 | .show { 31 | display: block !important; 32 | } 33 | .invisible { 34 | visibility: hidden; 35 | } 36 | .text-hide { 37 | @include text-hide; 38 | } 39 | 40 | 41 | // Hide from screenreaders and browsers 42 | // 43 | // Credit: HTML5 Boilerplate 44 | 45 | .hidden { 46 | display: none !important; 47 | } 48 | 49 | 50 | // For Affix plugin 51 | // ------------------------- 52 | 53 | .affix { 54 | position: fixed; 55 | } 56 | -------------------------------------------------------------------------------- /apps/volontulo/migrations/0006_page.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | from __future__ import unicode_literals 3 | 4 | from django.db import models, migrations 5 | 6 | 7 | class Migration(migrations.Migration): 8 | 9 | dependencies = [ 10 | ('volontulo', '0005_removing_badges'), 11 | ] 12 | 13 | operations = [ 14 | migrations.CreateModel( 15 | name='Page', 16 | fields=[ 17 | ('id', models.AutoField(serialize=False, auto_created=True, primary_key=True, verbose_name='ID')), 18 | ('title', models.CharField(max_length=255)), 19 | ('slug', models.SlugField(max_length=100)), 20 | ('content', models.TextField()), 21 | ('published', models.BooleanField(default=False)), 22 | ('modified_at', models.DateTimeField(auto_now=True)), 23 | ('created_at', models.DateTimeField(auto_now_add=True)), 24 | ('author', models.ForeignKey(to='volontulo.UserProfile')), 25 | ], 26 | ), 27 | ] 28 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_thumbnails.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Thumbnails 3 | // -------------------------------------------------- 4 | 5 | 6 | // Mixin and adjust the regular image class 7 | .thumbnail { 8 | display: block; 9 | padding: $thumbnail-padding; 10 | margin-bottom: $line-height-computed; 11 | line-height: $line-height-base; 12 | background-color: $thumbnail-bg; 13 | border: 1px solid $thumbnail-border; 14 | border-radius: $thumbnail-border-radius; 15 | @include transition(border .2s ease-in-out); 16 | 17 | > img, 18 | a > img { 19 | @include img-responsive; 20 | margin-left: auto; 21 | margin-right: auto; 22 | } 23 | 24 | // [converter] extracted a&:hover, a&:focus, a&.active to a.thumbnail:hover, a.thumbnail:focus, a.thumbnail.active 25 | 26 | // Image captions 27 | .caption { 28 | padding: $thumbnail-caption-padding; 29 | color: $thumbnail-caption-color; 30 | } 31 | } 32 | 33 | // Add a hover state for linked versions only 34 | a.thumbnail:hover, 35 | a.thumbnail:focus, 36 | a.thumbnail.active { 37 | border-color: $link-color; 38 | } 39 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_pager.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Pager pagination 3 | // -------------------------------------------------- 4 | 5 | 6 | .pager { 7 | padding-left: 0; 8 | margin: $line-height-computed 0; 9 | list-style: none; 10 | text-align: center; 11 | @include clearfix; 12 | li { 13 | display: inline; 14 | > a, 15 | > span { 16 | display: inline-block; 17 | padding: 5px 14px; 18 | background-color: $pager-bg; 19 | border: 1px solid $pager-border; 20 | border-radius: $pager-border-radius; 21 | } 22 | 23 | > a:hover, 24 | > a:focus { 25 | text-decoration: none; 26 | background-color: $pager-hover-bg; 27 | } 28 | } 29 | 30 | .next { 31 | > a, 32 | > span { 33 | float: right; 34 | } 35 | } 36 | 37 | .previous { 38 | > a, 39 | > span { 40 | float: left; 41 | } 42 | } 43 | 44 | .disabled { 45 | > a, 46 | > a:hover, 47 | > a:focus, 48 | > span { 49 | color: $pager-disabled-color; 50 | background-color: $pager-bg; 51 | cursor: $cursor-disabled; 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015-2016 STX Next & contributors 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/page_list.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | {% load bootstrap3 %} 3 | 4 | {% block title %}Strony{% endblock %} 5 | {% block content %} 6 |

Lista stron

7 | Stwórz stronę 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | {% for page in object_list %} 17 | 18 | 19 | 20 | 21 | 22 | 26 | 27 | {% endfor %} 28 |
TytułDodałData modyfikacjiData dodaniaAkcje
{{ page.title }}{{ page.author }}{{ page.modified_at }}{{ page.created_at }} 23 | Edytuj 24 | Usuń 25 |
29 | {% endblock %} -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_mixins.scss: -------------------------------------------------------------------------------- 1 | // Mixins 2 | // -------------------------------------------------- 3 | 4 | // Utilities 5 | @import "mixins/hide-text"; 6 | @import "mixins/opacity"; 7 | @import "mixins/image"; 8 | @import "mixins/labels"; 9 | @import "mixins/reset-filter"; 10 | @import "mixins/resize"; 11 | @import "mixins/responsive-visibility"; 12 | @import "mixins/size"; 13 | @import "mixins/tab-focus"; 14 | @import "mixins/reset-text"; 15 | @import "mixins/text-emphasis"; 16 | @import "mixins/text-overflow"; 17 | @import "mixins/vendor-prefixes"; 18 | 19 | // Components 20 | @import "mixins/alerts"; 21 | @import "mixins/buttons"; 22 | @import "mixins/panels"; 23 | @import "mixins/pagination"; 24 | @import "mixins/list-group"; 25 | @import "mixins/nav-divider"; 26 | @import "mixins/forms"; 27 | @import "mixins/progress-bar"; 28 | @import "mixins/table-row"; 29 | 30 | // Skins 31 | @import "mixins/background-variant"; 32 | @import "mixins/border-radius"; 33 | @import "mixins/gradients"; 34 | 35 | // Layout 36 | @import "mixins/clearfix"; 37 | @import "mixins/center-block"; 38 | @import "mixins/nav-vertical-align"; 39 | @import "mixins/grid-framework"; 40 | @import "mixins/grid"; 41 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/user_layout.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.html" %} 2 | 3 | {% block email_layout %} 4 | 5 | 6 | 7 | 11 | 12 | 13 |
8 | {% block email_content %} 9 | {% endblock %} 10 |
14 | 15 | 16 | 17 | 19 | 20 | 21 | 23 | 24 | 25 | 27 | 28 | 29 |
18 |
22 |
26 |
30 | 31 | 32 | 33 | 37 | 38 | 39 |
34 | {% block email_info_details %} 35 | {% endblock %} 36 |
40 | 41 | {% endblock %} 42 | -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/faq-volunteers.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Często zadawane pytania przez{% endblock %} 4 | 5 | {% block content %} 6 |

Często zadawane pytania przez wolontariuszy

7 |
8 |
9 | symbol 10 |
11 |
12 |

PytanieCzy niebo jest niebieskie

13 |

Odpowiedź Tak, ale Cras sit amet nibh libero, in gravida nulla. Nulla vel metus scelerisque ante sollicitudin commodo. Cras purus odio, vestibulum in vulputate at, tempus viverra turpis. Fusce condimentum nunc ac nisi vulputate fringilla. Donec lacinia congue felis in faucibus.

14 |

Donec sed odio dui. Nullam quis risus eget urna mollis ornare vel eu leo. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.

15 |
16 |
17 | {% endblock %} 18 | -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/faq-organizations.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Często zadawane pytania przez{% endblock %} 4 | 5 | {% block content %} 6 |

Często zadawane pytania przez organizatorów

7 |
8 |
9 | symbol 10 |
11 |
12 |

PytanieCzy niebo jest niebieskie

13 |

Odpowiedź Tak, ale Cras sit amet nibh libero, in gravida nulla. Nulla vel metus scelerisque ante sollicitudin commodo. Cras purus odio, vestibulum in vulputate at, tempus viverra turpis. Fusce condimentum nunc ac nisi vulputate fringilla. Donec lacinia congue felis in faucibus.

14 |

Donec sed odio dui. Nullam quis risus eget urna mollis ornare vel eu leo. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.

15 |
16 |
17 | {% endblock %} 18 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_media.scss: -------------------------------------------------------------------------------- 1 | .media { 2 | // Proper spacing between instances of .media 3 | margin-top: 15px; 4 | 5 | &:first-child { 6 | margin-top: 0; 7 | } 8 | } 9 | 10 | .media, 11 | .media-body { 12 | zoom: 1; 13 | overflow: hidden; 14 | } 15 | 16 | .media-body { 17 | width: 10000px; 18 | } 19 | 20 | .media-object { 21 | display: block; 22 | 23 | // Fix collapse in webkit from max-width: 100% and display: table-cell. 24 | &.img-thumbnail { 25 | max-width: none; 26 | } 27 | } 28 | 29 | .media-right, 30 | .media > .pull-right { 31 | padding-left: 10px; 32 | } 33 | 34 | .media-left, 35 | .media > .pull-left { 36 | padding-right: 10px; 37 | } 38 | 39 | .media-left, 40 | .media-right, 41 | .media-body { 42 | display: table-cell; 43 | vertical-align: top; 44 | } 45 | 46 | .media-middle { 47 | vertical-align: middle; 48 | } 49 | 50 | .media-bottom { 51 | vertical-align: bottom; 52 | } 53 | 54 | // Reset margins on headings for tighter default spacing 55 | .media-heading { 56 | margin-top: 0; 57 | margin-bottom: 5px; 58 | } 59 | 60 | // Media list variation 61 | // 62 | // Undo default ul/ol styles 63 | .media-list { 64 | padding-left: 0; 65 | list-style: none; 66 | } 67 | -------------------------------------------------------------------------------- /apps/volontulo/templates/offers/archived.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Lista ofert w archiwum{% endblock %} 4 | 5 | {% block content %} 6 | {% include 'admin/offers_nav.html' %} 7 | {% if offers %} 8 |

Lista ofert

9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | {% for o in offers %} 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | {% endfor %} 30 |
TytułMiejsceNazwa organizacjiCzas obowiązywaniaData rozpoczęcia akcjiData zakończenia akcji
{{ o.title }}{{ o.location }}{{ o.organization.name }}{{ o.time_period }}{{ o.started_at }}{{ o.finished_at }}Podgląd
31 | {% else %} 32 |

Brak ofert spełniających podane kryteria

33 | {% endif %} 34 | {% endblock %} 35 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Configuration files 2 | local_config.yaml 3 | 4 | # Byte-compiled / optimized / DLL files 5 | __pycache__/ 6 | *.py[cod] 7 | *$py.class 8 | 9 | # C extensions 10 | *.so 11 | 12 | # Distribution / packaging 13 | .Python 14 | env/ 15 | build/ 16 | develop-eggs/ 17 | dist/ 18 | downloads/ 19 | eggs/ 20 | .eggs/ 21 | lib64/ 22 | parts/ 23 | sdist/ 24 | var/ 25 | *.egg-info/ 26 | .installed.cfg 27 | *.egg 28 | 29 | # PyInstaller 30 | # Usually these files are written by a python script from a template 31 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 32 | *.manifest 33 | *.spec 34 | 35 | # Installer logs 36 | pip-log.txt 37 | pip-delete-this-directory.txt 38 | 39 | # Unit test / coverage reports 40 | htmlcov/ 41 | .tox/ 42 | .coverage 43 | .coverage.* 44 | .cache 45 | nosetests.xml 46 | coverage.xml 47 | *,cover 48 | 49 | # Translations 50 | *.mo 51 | *.pot 52 | 53 | # Django stuff: 54 | *.log 55 | 56 | # Sphinx documentation 57 | docs/_build/ 58 | 59 | # PyBuilder 60 | target/ 61 | 62 | # PyCharm directory 63 | .idea/ 64 | 65 | # npm and gulp 66 | apps/volontulo/node_modules/ 67 | apps/volontulo/static/ 68 | media 69 | static 70 | 71 | # Development directories / files 72 | .ropeproject 73 | 74 | # SQLite database 75 | *.sqlite3 76 | *.sqlite 77 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_jumbotron.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Jumbotron 3 | // -------------------------------------------------- 4 | 5 | 6 | .jumbotron { 7 | padding-top: $jumbotron-padding; 8 | padding-bottom: $jumbotron-padding; 9 | margin-bottom: $jumbotron-padding; 10 | color: $jumbotron-color; 11 | background-color: $jumbotron-bg; 12 | 13 | h1, 14 | .h1 { 15 | color: $jumbotron-heading-color; 16 | } 17 | 18 | p { 19 | margin-bottom: ($jumbotron-padding / 2); 20 | font-size: $jumbotron-font-size; 21 | font-weight: 200; 22 | } 23 | 24 | > hr { 25 | border-top-color: darken($jumbotron-bg, 10%); 26 | } 27 | 28 | .container &, 29 | .container-fluid & { 30 | border-radius: $border-radius-large; // Only round corners at higher resolutions if contained in a container 31 | } 32 | 33 | .container { 34 | max-width: 100%; 35 | } 36 | 37 | @media screen and (min-width: $screen-sm-min) { 38 | padding-top: ($jumbotron-padding * 1.6); 39 | padding-bottom: ($jumbotron-padding * 1.6); 40 | 41 | .container &, 42 | .container-fluid & { 43 | padding-left: ($jumbotron-padding * 2); 44 | padding-right: ($jumbotron-padding * 2); 45 | } 46 | 47 | h1, 48 | .h1 { 49 | font-size: $jumbotron-heading-font-size; 50 | } 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_image.scss: -------------------------------------------------------------------------------- 1 | // Image Mixins 2 | // - Responsive image 3 | // - Retina image 4 | 5 | 6 | // Responsive image 7 | // 8 | // Keep images from scaling beyond the width of their parents. 9 | @mixin img-responsive($display: block) { 10 | display: $display; 11 | max-width: 100%; // Part 1: Set a maximum relative to the parent 12 | height: auto; // Part 2: Scale the height according to the width, otherwise you get stretching 13 | } 14 | 15 | 16 | // Retina image 17 | // 18 | // Short retina mixin for setting background-image and -size. Note that the 19 | // spelling of `min--moz-device-pixel-ratio` is intentional. 20 | @mixin img-retina($file-1x, $file-2x, $width-1x, $height-1x) { 21 | background-image: url(if($bootstrap-sass-asset-helper, twbs-image-path("#{$file-1x}"), "#{$file-1x}")); 22 | 23 | @media 24 | only screen and (-webkit-min-device-pixel-ratio: 2), 25 | only screen and ( min--moz-device-pixel-ratio: 2), 26 | only screen and ( -o-min-device-pixel-ratio: 2/1), 27 | only screen and ( min-device-pixel-ratio: 2), 28 | only screen and ( min-resolution: 192dpi), 29 | only screen and ( min-resolution: 2dppx) { 30 | background-image: url(if($bootstrap-sass-asset-helper, twbs-image-path("#{$file-2x}"), "#{$file-2x}")); 31 | background-size: $width-1x $height-1x; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /apps/volontulo/templates/common/sub-footer.html: -------------------------------------------------------------------------------- 1 | {% block subfooter %} 2 |
3 |
4 |

Ten serwis powstał wspólnym wysiłkiem we współpracy pomiędzy

5 |
6 |
7 |
8 |
9 | Logo WRK - Wielkopolska Rada Koordynacyjna Związek Organizacji Pozarządowych 10 |
11 |
12 | Logo STX Next 13 |
14 |
15 | Logo Koduj Dla Polski 16 |
17 |
18 | Logo Komitywa 19 |
20 |
21 | {% endblock %} 22 | -------------------------------------------------------------------------------- /fabfile.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: fabfile 5 | 6 | Be aware, that becaus fabric doesn't support py3k You need to execute this 7 | particular script using Python 2. 8 | """ 9 | 10 | import contextlib 11 | 12 | from fabric.api import cd 13 | from fabric.api import env 14 | from fabric.api import prefix 15 | from fabric.api import run 16 | 17 | env.user = 'root' 18 | env.hosts = ['volontuloapp.org'] 19 | env.forward_agent = True 20 | 21 | 22 | def update(): 23 | u"""Function defining all steps required to properly update application.""" 24 | 25 | # Django app refresh: 26 | with contextlib.nested( 27 | cd('/var/www/volontuloapp_org'), 28 | prefix('workon volontuloapp_org') 29 | ): 30 | run('git checkout master') 31 | run('git pull') 32 | run('pip install -r requirements/production.txt') 33 | 34 | # Gulp frontend refresh: 35 | with contextlib.nested( 36 | cd('/var/www/volontuloapp_org/apps/volontulo') 37 | ): 38 | run('npm install .') 39 | run('./node_modules/.bin/gulp build') 40 | 41 | # Django site refresh: 42 | with contextlib.nested( 43 | cd('/var/www/volontuloapp_org'), 44 | prefix('workon volontuloapp_org') 45 | ): 46 | run('python manage.py migrate --traceback' 47 | ' --settings=volontulo_org.settings.production') 48 | run('service apache2 restart') 49 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_labels.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Labels 3 | // -------------------------------------------------- 4 | 5 | .label { 6 | display: inline; 7 | padding: .2em .6em .3em; 8 | font-size: 75%; 9 | font-weight: bold; 10 | line-height: 1; 11 | color: $label-color; 12 | text-align: center; 13 | white-space: nowrap; 14 | vertical-align: baseline; 15 | border-radius: .25em; 16 | 17 | // [converter] extracted a& to a.label 18 | 19 | // Empty labels collapse automatically (not available in IE8) 20 | &:empty { 21 | display: none; 22 | } 23 | 24 | // Quick fix for labels in buttons 25 | .btn & { 26 | position: relative; 27 | top: -1px; 28 | } 29 | } 30 | 31 | // Add hover effects, but only for links 32 | a.label { 33 | &:hover, 34 | &:focus { 35 | color: $label-link-hover-color; 36 | text-decoration: none; 37 | cursor: pointer; 38 | } 39 | } 40 | 41 | // Colors 42 | // Contextual variations (linked labels get darker on :hover) 43 | 44 | .label-default { 45 | @include label-variant($label-default-bg); 46 | } 47 | 48 | .label-primary { 49 | @include label-variant($label-primary-bg); 50 | } 51 | 52 | .label-success { 53 | @include label-variant($label-success-bg); 54 | } 55 | 56 | .label-info { 57 | @include label-variant($label-info-bg); 58 | } 59 | 60 | .label-warning { 61 | @include label-variant($label-warning-bg); 62 | } 63 | 64 | .label-danger { 65 | @include label-variant($label-danger-bg); 66 | } 67 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/base.html: -------------------------------------------------------------------------------- 1 | {% load staticfiles %} 2 | 3 | 4 | 5 | 6 | 32 | 33 | 34 |
7 | 8 | 9 | 10 | 28 | 29 | 30 |
11 | 12 | 13 | 14 | 18 | 19 | 20 | 22 | 23 | 24 |
15 | 16 | VOLONTULO 17 |
21 |
25 | {% block email_layout %} 26 | {% endblock %} 27 |
31 |
35 | 36 | 45 | -------------------------------------------------------------------------------- /apps/volontulo/templates/offers/gallery.html: -------------------------------------------------------------------------------- 1 | {% load bootstrap3 %} 2 | 3 |
4 | 5 |
6 |
7 | {% csrf_token %} 8 | {% bootstrap_form offer_image_form %} 9 |
10 | 11 |
12 |
13 |

Proszę o uwzględnienie formatu zdjęcia: jpg, gif, png, bmp

14 |
15 |
16 | {% if images|length %} 17 |
    18 | {% for image in images %} 19 | {% if image.is_main %} 20 |
  • {{ image }}
  • 21 | {% else %} 22 |
  • {{ image }}
  • 23 | {% endif %} 24 | {% endfor %} 25 |
26 | {% else %} 27 |

Ta oferta nie ma jeszcze dodanych zdjęć.

28 | {% endif %} 29 |
30 |
31 | -------------------------------------------------------------------------------- /etc/pre-commit: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # -*- coding: utf-8 -*- 3 | 4 | import os 5 | import subprocess 6 | import sys 7 | 8 | 9 | REPO_ROOT = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) 10 | 11 | 12 | def system(*args, **kwargs): 13 | kwargs.setdefault('stdout', subprocess.PIPE) 14 | kwargs.setdefault('stderr', subprocess.PIPE) 15 | proc = subprocess.Popen(args, **kwargs) 16 | out, err = proc.communicate() 17 | proc.wait() 18 | if proc.returncode: 19 | print(args) 20 | print(kwargs) 21 | print(out.decode("unicode_escape")) 22 | print(err.decode("unicode_escape") if err else '') 23 | return proc.returncode 24 | 25 | 26 | def print_red(text): 27 | format_ = '0;30;41' 28 | print('\x1b[%sm %s \x1b[0m' % (format_, text)) 29 | 30 | 31 | def main(): 32 | exitcode = system("pep8 --exclude='apps/volontulo/migrations/*,node_modules,.ropeproject' .", cwd=REPO_ROOT, shell=True) 33 | if exitcode: 34 | print_red(u'PEP8!') 35 | sys.exit(exitcode) 36 | 37 | exitcode = system('pylint --load-plugins pylint_django --min-similarity-lines=10 apps', cwd=REPO_ROOT, shell=True) 38 | if exitcode: 39 | print_red(u'PYLINT') 40 | sys.exit(exitcode) 41 | 42 | exitcode = system('python manage.py test --settings=volontulo_org.settings.test_settings -v 3', cwd=REPO_ROOT, shell=True) 43 | if exitcode: 44 | print_red(u'UNIT TEST') 45 | sys.exit(exitcode) 46 | 47 | sys.exit(0) 48 | 49 | if __name__ == '__main__': 50 | main() 51 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/customization/_customization-variables.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Customization variables 3 | // -------------------------------------------------- 4 | 5 | // bootflat color elements 6 | $white: #FFF !default; 7 | $black: #000 !default; 8 | 9 | $bluejeans-dark: #4A89DC !default; 10 | $bluejeans-light: #5D9CEC !default; 11 | 12 | $aqua-dark: #3BAFDA !default; 13 | $aqua-light: #4FC1E9 !default; 14 | 15 | $mint-dark: #37BC9B !default; 16 | $mint-light: #48CFAD !default; 17 | 18 | $grass-dark: #8CC152 !default; 19 | $grass-light: #A0D468 !default; 20 | 21 | $sunflower-dark: #F6BB42 !default; 22 | $sunflower-light: #FFCE54 !default; 23 | 24 | $bittersweet-dark: #E9573F !default; 25 | $bittersweet-light: #FC6E51 !default; 26 | 27 | $grapefruit-dark: #DA4453 !default; 28 | $grapefruit-light: #ED5565 !default; 29 | 30 | $lavender-dark: #967ADC !default; 31 | $lavender-light: #AC92EC !default; 32 | 33 | $pinkrose-dark: #D770AD !default; 34 | $pinkrose-light: #EC87C0 !default; 35 | 36 | $lightgray-dark: #E6E9ED !default; 37 | $lightgray-light: #F5F7FA !default; 38 | 39 | $mediumgray-dark: #AAB2BD !default; 40 | $mediumgray-light: #CCD1D9 !default; 41 | 42 | $darkgray-dark: #434A54 !default; 43 | $darkgray-light: #656D78 !default; 44 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/volunteer_to_organisation.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/user_layout.html" %} 2 | 3 | {% load staticfiles %} 4 | 5 | {% block title %}Kontakt wolontariusza z organizacją{% endblock %} 6 | 7 | {% block email_content %} 8 |
9 |
10 |
11 | Wolontariusz chce skontaktować się z Twoją organizacją.
12 |
13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 |
Imię i nazwisko:  {{ name }}
Email:  {{ email }}
Numer telefonu:  {{ phone_no }}
30 | 31 | 32 | 33 | 36 | 37 | 38 | 41 | 42 | 43 |
34 | Wiadomość: 35 |
39 | {{ message }} 40 |
44 | 45 | {% endblock %} 46 | 47 | {% block email_info_details %} 48 | {% include "emails/site_owner_details.html" %} 49 | {% endblock %} 50 | -------------------------------------------------------------------------------- /apps/volontulo/templates/organizations/gallery.html: -------------------------------------------------------------------------------- 1 | {% load bootstrap3 %} 2 | {% if organization_image_form.organization|length %} 3 |
4 | {% csrf_token %} 5 |
6 |

{% bootstrap_form organization_image_form %}

7 |

Proszę o uwzględnienie formatu zdjęcia: jpg, gif, png, bmp

8 |
9 |
10 | 11 |
12 |
13 | {% if galleries.items|length %} 14 |
15 | {% for organization, gallery in galleries.items %} 16 |

{{ organization }}

17 | {% for image in gallery %} 18 | {% if image.is_main %} 19 | {{ image }} 20 | {% else %} 21 | {{ image }} 22 | {% endif %} 23 | {% endfor %} 24 | {% endfor %} 25 |
26 | {% else %} 27 |

Żadna z organizacji do których należysz nie ma jeszcze dodanego zdjęcia.

28 | {% endif %} 29 | {% else %} 30 |

Aby dodawać zdjęcia do instytucji czy organizacji należy być częścią przynajmniej jednej z nich.

31 | {% endif %} 32 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/admin_layout.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/base.html" %} 2 | 3 | {% block email_layout %} 4 | 5 | 6 | 7 | 12 | 13 | 15 | 16 | 17 | 18 |
8 |
9 | {% block title %}{% endblock %} 10 |
11 |
14 |
19 | 20 | 21 | 22 | 26 | 27 | 28 |
23 | {% block email_content %} 24 | {% endblock %} 25 |
29 | 30 | 31 | 32 | 34 | 35 | 36 | 38 | 39 | 40 | 42 | 43 | 44 |
33 |
37 |
41 |
45 | 46 | 47 | 48 | 52 | 53 | 54 |
49 | {% block email_info_details %} 50 | {% endblock %} 51 |
55 | {% endblock %} 56 | -------------------------------------------------------------------------------- /apps/volontulo/templates/common/base.html: -------------------------------------------------------------------------------- 1 | {% load bootstrap3 %} 2 | {% load staticfiles %} 3 | {% load cookielaw_tags %} 4 | 5 | 6 | 7 | 8 | 9 | Volontulo - {% block title %}{% endblock %} 10 | 11 | {% block styles %} 12 | 13 | {% endblock %} 14 | 15 | 16 | 17 | 18 | 19 | 20 | {% cookielaw_banner %} 21 |
22 |
23 | {% include "common/header.html" %} 24 | {% include "common/messages.html" %} 25 |
26 |
27 | {% block layout %} 28 | {% endblock %} 29 | 34 | 39 | 40 | {% block scripts %} 41 | 42 | 43 | 44 | {% endblock %} 45 | 46 | 47 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_code.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Code (inline and block) 3 | // -------------------------------------------------- 4 | 5 | 6 | // Inline and block code styles 7 | code, 8 | kbd, 9 | pre, 10 | samp { 11 | font-family: $font-family-monospace; 12 | } 13 | 14 | // Inline code 15 | code { 16 | padding: 2px 4px; 17 | font-size: 90%; 18 | color: $code-color; 19 | background-color: $code-bg; 20 | border-radius: $border-radius-base; 21 | } 22 | 23 | // User input typically entered via keyboard 24 | kbd { 25 | padding: 2px 4px; 26 | font-size: 90%; 27 | color: $kbd-color; 28 | background-color: $kbd-bg; 29 | border-radius: $border-radius-small; 30 | box-shadow: inset 0 -1px 0 rgba(0,0,0,.25); 31 | 32 | kbd { 33 | padding: 0; 34 | font-size: 100%; 35 | font-weight: bold; 36 | box-shadow: none; 37 | } 38 | } 39 | 40 | // Blocks of code 41 | pre { 42 | display: block; 43 | padding: (($line-height-computed - 1) / 2); 44 | margin: 0 0 ($line-height-computed / 2); 45 | font-size: ($font-size-base - 1); // 14px to 13px 46 | line-height: $line-height-base; 47 | word-break: break-all; 48 | word-wrap: break-word; 49 | color: $pre-color; 50 | background-color: $pre-bg; 51 | border: 1px solid $pre-border-color; 52 | border-radius: $border-radius-base; 53 | 54 | // Account for some code outputs that place code tags in pre tags 55 | code { 56 | padding: 0; 57 | font-size: inherit; 58 | color: inherit; 59 | white-space: pre-wrap; 60 | background-color: transparent; 61 | border-radius: 0; 62 | } 63 | } 64 | 65 | // Enable scrollable blocks of code 66 | .pre-scrollable { 67 | max-height: $pre-scrollable-max-height; 68 | overflow-y: scroll; 69 | } 70 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_buttons.scss: -------------------------------------------------------------------------------- 1 | // Button variants 2 | // 3 | // Easily pump out default styles, as well as :hover, :focus, :active, 4 | // and disabled options for all buttons 5 | 6 | @mixin button-variant($color, $background, $border) { 7 | color: $color; 8 | background-color: $background; 9 | border-color: $border; 10 | 11 | &:focus, 12 | &.focus { 13 | color: $color; 14 | background-color: darken($background, 10%); 15 | border-color: darken($border, 25%); 16 | } 17 | &:hover { 18 | color: $color; 19 | background-color: darken($background, 10%); 20 | border-color: darken($border, 12%); 21 | } 22 | &:active, 23 | &.active, 24 | .open > &.dropdown-toggle { 25 | color: $color; 26 | background-color: darken($background, 10%); 27 | border-color: darken($border, 12%); 28 | 29 | &:hover, 30 | &:focus, 31 | &.focus { 32 | color: $color; 33 | background-color: darken($background, 17%); 34 | border-color: darken($border, 25%); 35 | } 36 | } 37 | &:active, 38 | &.active, 39 | .open > &.dropdown-toggle { 40 | background-image: none; 41 | } 42 | &.disabled, 43 | &[disabled], 44 | fieldset[disabled] & { 45 | &, 46 | &:hover, 47 | &:focus, 48 | &.focus, 49 | &:active, 50 | &.active { 51 | background-color: $background; 52 | border-color: $border; 53 | } 54 | } 55 | 56 | .badge { 57 | color: $background; 58 | background-color: $color; 59 | } 60 | } 61 | 62 | // Button sizes 63 | @mixin button-size($padding-vertical, $padding-horizontal, $font-size, $line-height, $border-radius) { 64 | padding: $padding-vertical $padding-horizontal; 65 | font-size: $font-size; 66 | line-height: $line-height; 67 | border-radius: $border-radius; 68 | } 69 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/volunteer_to_admin.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/admin_layout.html" %} 2 | 3 | {% load staticfiles %} 4 | 5 | {% block title %}Kontakt wolontariusza z administratorem{% endblock %} 6 | 7 | {% block email_content %} 8 |
9 |
10 |
11 | Witaj
12 |
13 |
14 | Dziękujemy za pytanie. Nasz doradca skontaktuje się z Tobą mailowo lub telefonicznie.
15 | Twoja wiadomość znajduje się poniżej:
16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 |
Imię i nazwisko:  {{ name }}
Email:  {{ email }}
Numer telefonu:  {{ phone_no }}
Aplikant:  {{ applicant }}
37 | 38 | 39 | 40 | 43 | 44 | 45 | 48 | 49 | 50 |
41 | Wiadomość: 42 |
46 | {{ message }} 47 |
51 | {% endblock %} 52 | 53 | {% block email_info_details %} 54 | {% include "emails/site_owner_details.html" %} 55 | {% endblock %} 56 | -------------------------------------------------------------------------------- /apps/volontulo/templates/emails/offer_application.html: -------------------------------------------------------------------------------- 1 | {% extends "emails/user_layout.html" %} 2 | 3 | {% load staticfiles %} 4 | 5 | {% block title %}Zgłoszenie wolontariusza w ofercie{% endblock %} 6 | 7 | {% block email_content %} 8 |
9 |
10 |
11 | Witaj
12 |
13 |
14 | Wolontariusz zgłosił się na pomoc w tej ofercie.
15 |
16 | Prosimy o wzajemny kontakt w celu ustalenia wszystkich szczegółów wolontariatu.
17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 |
Imię i nazwisko:  {{ fullname }}
Email:  {{ email }}
Numer telefonu:  {{ phone_no }}
34 | 35 | 36 | 37 | 40 | 41 | 42 | 45 | 46 | 47 |
38 | Uwagi wolontariusza: 39 |
43 | {{ comments }} 44 |
48 | {% endblock %} 49 | 50 | {% block email_info_details %} 51 | {% include "emails/site_owner_details.html" %} 52 | {% endblock %} -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_grid.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Grid system 3 | // -------------------------------------------------- 4 | 5 | 6 | // Container widths 7 | // 8 | // Set the container width, and override it for fixed navbars in media queries. 9 | 10 | .container { 11 | @include container-fixed; 12 | 13 | @media (min-width: $screen-sm-min) { 14 | width: $container-sm; 15 | } 16 | @media (min-width: $screen-md-min) { 17 | width: $container-md; 18 | } 19 | @media (min-width: $screen-lg-min) { 20 | width: $container-lg; 21 | } 22 | } 23 | 24 | 25 | // Fluid container 26 | // 27 | // Utilizes the mixin meant for fixed width containers, but without any defined 28 | // width for fluid, full width layouts. 29 | 30 | .container-fluid { 31 | @include container-fixed; 32 | } 33 | 34 | 35 | // Row 36 | // 37 | // Rows contain and clear the floats of your columns. 38 | 39 | .row { 40 | @include make-row; 41 | } 42 | 43 | 44 | // Columns 45 | // 46 | // Common styles for small and large grid columns 47 | 48 | @include make-grid-columns; 49 | 50 | 51 | // Extra small grid 52 | // 53 | // Columns, offsets, pushes, and pulls for extra small devices like 54 | // smartphones. 55 | 56 | @include make-grid(xs); 57 | 58 | 59 | // Small grid 60 | // 61 | // Columns, offsets, pushes, and pulls for the small device range, from phones 62 | // to tablets. 63 | 64 | @media (min-width: $screen-sm-min) { 65 | @include make-grid(sm); 66 | } 67 | 68 | 69 | // Medium grid 70 | // 71 | // Columns, offsets, pushes, and pulls for the desktop device range. 72 | 73 | @media (min-width: $screen-md-min) { 74 | @include make-grid(md); 75 | } 76 | 77 | 78 | // Large grid 79 | // 80 | // Columns, offsets, pushes, and pulls for the large desktop device range. 81 | 82 | @media (min-width: $screen-lg-min) { 83 | @include make-grid(lg); 84 | } 85 | -------------------------------------------------------------------------------- /apps/volontulo/templates/organizations/organization_view.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Wyświetlanie organizacji{% endblock %} 4 | 5 | {% block content %} 6 |

Organizacja

7 |
8 |
9 | 10 |
11 | {{ organization.name }} 12 |
13 | 14 |
15 | {{ organization.address }} 16 |
17 |
18 |
19 | 20 |
21 | {{ organization.description }} 22 |
23 |
24 |
25 |
26 | {% if allow_edit %} 27 | Edytuj organizację 28 | {% endif %} 29 | {% if allow_offer_create %} 30 | Dodaj ofertę 31 | {% endif %} 32 |
33 |
34 |
35 | 36 | {% if allow_contact %} 37 |
38 | {% include 'contact_form.html' with contact_form=contact_form %} 39 |
40 | {% endif %} 41 | 42 | {% include 'organizations/organization_offers.html' with offers=offers allow_edit=allow_edit %} 43 | 44 | {% endblock %} 45 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_alerts.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Alerts 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base styles 7 | // ------------------------- 8 | 9 | .alert { 10 | padding: $alert-padding; 11 | margin-bottom: $line-height-computed; 12 | border: 1px solid transparent; 13 | border-radius: $alert-border-radius; 14 | 15 | // Headings for larger alerts 16 | h4 { 17 | margin-top: 0; 18 | // Specified for the h4 to prevent conflicts of changing $headings-color 19 | color: inherit; 20 | } 21 | 22 | // Provide class for links that match alerts 23 | .alert-link { 24 | font-weight: $alert-link-font-weight; 25 | } 26 | 27 | // Improve alignment and spacing of inner content 28 | > p, 29 | > ul { 30 | margin-bottom: 0; 31 | } 32 | 33 | > p + p { 34 | margin-top: 5px; 35 | } 36 | } 37 | 38 | // Dismissible alerts 39 | // 40 | // Expand the right padding and account for the close button's positioning. 41 | 42 | .alert-dismissable, // The misspelled .alert-dismissable was deprecated in 3.2.0. 43 | .alert-dismissible { 44 | padding-right: ($alert-padding + 20); 45 | 46 | // Adjust close link position 47 | .close { 48 | position: relative; 49 | top: -2px; 50 | right: -21px; 51 | color: inherit; 52 | } 53 | } 54 | 55 | // Alternate styles 56 | // 57 | // Generate contextual modifier classes for colorizing the alert. 58 | 59 | .alert-success { 60 | @include alert-variant($alert-success-bg, $alert-success-border, $alert-success-text); 61 | } 62 | 63 | .alert-info { 64 | @include alert-variant($alert-info-bg, $alert-info-border, $alert-info-text); 65 | } 66 | 67 | .alert-warning { 68 | @include alert-variant($alert-warning-bg, $alert-warning-border, $alert-warning-text); 69 | } 70 | 71 | .alert-danger { 72 | @include alert-variant($alert-danger-bg, $alert-danger-border, $alert-danger-text); 73 | } 74 | -------------------------------------------------------------------------------- /apps/volontulo/templates/organizations/organization_form.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Tworzenie organizacji{% endblock %} 4 | 5 | {% block content %} 6 |

Tworzenie organizacji

7 | 8 |
9 | {% csrf_token %} 10 |
11 | 12 |
13 | 14 |
15 | 16 |
17 | 18 |
19 |
20 |
21 | 22 |
23 | 24 |
25 |
26 | 27 |
28 |
29 | 30 |
31 |
32 |
33 | {% endblock %} 34 | -------------------------------------------------------------------------------- /apps/volontulo/gulpfile.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | var gulp = require('gulp'); 4 | var gutil = require('gulp-util'); 5 | var sass = require('gulp-sass'); 6 | var iconify = require('gulp-iconify'); 7 | 8 | gulp.task('build_icons', function() { 9 | iconify({ 10 | src: './frontend/icons/*.svg', 11 | pngOutput: './static/volontulo/img/icons/png', 12 | cssDisabled: true, 13 | cssOutput: 'false', 14 | scssOutput: './frontend/scss/iconify', 15 | styleTemplate: './frontend/icons/template/icon_gen.scss.mustache', 16 | defaultWidth: '32px', 17 | defaultHeight: '32px', 18 | svgoOptions: { 19 | enabled: true, 20 | options: { 21 | plugins: [ 22 | { removeUnknownsAndDefaults: true }, 23 | { mergePaths: false } 24 | ] 25 | } 26 | } 27 | }); 28 | }); 29 | 30 | gulp.task('build_fonts', function() { 31 | gulp.src('./frontend/fonts/**/*') 32 | .pipe(gulp.dest('./static/volontulo/fonts/')); 33 | }); 34 | 35 | gulp.task('build_img', function() { 36 | gulp.src('./frontend/img/**/*') 37 | .pipe(gulp.dest('./static/volontulo/img/')); 38 | }); 39 | 40 | gulp.task('build_javascripts', function() { 41 | gulp.src('./frontend/javascripts/**/*.js') 42 | .pipe(gulp.dest('./static/volontulo/javascripts/')); 43 | }); 44 | 45 | gulp.task('build_scss', function() { 46 | gulp.src('./frontend/scss/**/*.scss') 47 | .pipe(sass().on('error', sass.logError)) 48 | .pipe(gulp.dest('./static/volontulo/css/')); 49 | }); 50 | 51 | gulp.task('build:svg', ['build_icons'], function() { 52 | }); 53 | 54 | gulp.task('build', ['build_fonts', 'build_img', 'build_javascripts', 'build_scss'], function() { 55 | }); 56 | 57 | gulp.task('watch', ['build'], function() { 58 | gulp.watch('./frontend/**/*', ['build']); 59 | gutil.log(gutil.colors.bgGreen('Watching for changes...')); 60 | }); 61 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: setup 5 | """ 6 | 7 | import os 8 | from distutils.command.install import install 9 | from setuptools import setup 10 | from subprocess import check_output 11 | 12 | REPO_ROOT = os.path.dirname(__file__) 13 | 14 | 15 | class install_with_gulp(install): 16 | u"""Class extending install command - responsible for building fronted.""" 17 | 18 | def run(self): 19 | u"""Definition of custom install command.""" 20 | check_output( 21 | ['npm', 'install', '--quiet'], 22 | cwd=os.path.join(REPO_ROOT, 'volontulo'), 23 | ) 24 | check_output( 25 | ['gulp', 'build'], 26 | cwd=os.path.join(REPO_ROOT, 'volontulo') 27 | ) 28 | install.run(self) 29 | 30 | with open(os.path.join(REPO_ROOT, 'README.md')) as readme: 31 | README = readme.read() 32 | 33 | # allow setup.py to be run from any path 34 | os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) 35 | 36 | setup( 37 | name='volontulo', 38 | version='alpha', 39 | packages=['apps.volontulo'], 40 | include_package_data=True, 41 | license='MIT License', 42 | description='Simple Django app connecting organizations with volonteers.', 43 | long_description=README, 44 | cmdclass=dict(install=install_with_gulp), 45 | url='http://volontuloapp.org/', 46 | author='Tomasz Magulski', 47 | author_email='tomasz.magulski@stxnext.pl', 48 | classifiers=[ 49 | 'Environment :: Web Environment', 50 | 'Framework :: Django', 51 | 'Intended Audience :: Developers', 52 | 'License :: OSI Approved :: MIT License', 53 | 'Operating System :: OS Independent', 54 | 'Programming Language :: Python', 55 | 'Programming Language :: Python :: 3', 56 | 'Programming Language :: Python :: 3.4', 57 | 'Topic :: Internet :: WWW/HTTP', 58 | 'Topic :: Internet :: WWW/HTTP :: Dynamic Content', 59 | ], 60 | ) 61 | -------------------------------------------------------------------------------- /apps/volontulo/templates/common/footer.html: -------------------------------------------------------------------------------- 1 | {% block footer %} 2 |

Nawigacja

3 |
4 |
5 | 6 | 14 |
15 |
16 | 17 | 22 |
23 | 34 |
35 | {% endblock %} 36 | -------------------------------------------------------------------------------- /apps/volontulo/templates/common/header.html: -------------------------------------------------------------------------------- 1 | {% load staticfiles %} 2 | 3 | {% block header %} 4 | {% block social_nav %} 5 | {% endblock %} 6 | 7 | {% block navigations %} 8 |
9 |
10 | 39 |
40 |
41 | {% endblock %} 42 | {% endblock %} 43 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/javascripts/bootstrap/transition.js: -------------------------------------------------------------------------------- 1 | /* ======================================================================== 2 | * Bootstrap: transition.js v3.3.5 3 | * http://getbootstrap.com/javascript/#transitions 4 | * ======================================================================== 5 | * Copyright 2011-2015 Twitter, Inc. 6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 7 | * ======================================================================== */ 8 | 9 | 10 | +function ($) { 11 | 'use strict'; 12 | 13 | // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/) 14 | // ============================================================ 15 | 16 | function transitionEnd() { 17 | var el = document.createElement('bootstrap') 18 | 19 | var transEndEventNames = { 20 | WebkitTransition : 'webkitTransitionEnd', 21 | MozTransition : 'transitionend', 22 | OTransition : 'oTransitionEnd otransitionend', 23 | transition : 'transitionend' 24 | } 25 | 26 | for (var name in transEndEventNames) { 27 | if (el.style[name] !== undefined) { 28 | return { end: transEndEventNames[name] } 29 | } 30 | } 31 | 32 | return false // explicit for ie8 ( ._.) 33 | } 34 | 35 | // http://blog.alexmaccaw.com/css-transitions 36 | $.fn.emulateTransitionEnd = function (duration) { 37 | var called = false 38 | var $el = this 39 | $(this).one('bsTransitionEnd', function () { called = true }) 40 | var callback = function () { if (!called) $($el).trigger($.support.transition.end) } 41 | setTimeout(callback, duration) 42 | return this 43 | } 44 | 45 | $(function () { 46 | $.support.transition = transitionEnd() 47 | 48 | if (!$.support.transition) return 49 | 50 | $.event.special.bsTransitionEnd = { 51 | bindType: $.support.transition.end, 52 | delegateType: $.support.transition.end, 53 | handle: function (e) { 54 | if ($(e.target).is(this)) return e.handleObj.handler.apply(this, arguments) 55 | } 56 | } 57 | }) 58 | 59 | }(jQuery); 60 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/offers/test_offer_delete.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """ 4 | .. module:: test_offer_delete 5 | """ 6 | 7 | from django.test import Client 8 | from django.test import TestCase 9 | 10 | from apps.volontulo.tests.views.offers.commons import TestOffersCommons 11 | 12 | 13 | class TestOfferDelete(TestOffersCommons, TestCase): 14 | """Class responsible for testing offers deletion.""" 15 | 16 | def setUp(self): 17 | """Set up each test.""" 18 | self.client = Client() 19 | 20 | def test_offer_deletion_for_anonymous_user(self): 21 | """Test deletion for anonymous users.""" 22 | response = self.client.get('/offers/delete/{}' 23 | .format(self.inactive_offer.id)) 24 | self.assertEqual(response.status_code, 403) 25 | 26 | def test_offer_deletion_for_volunteer(self): 27 | """Test deletion for account of volunteer.""" 28 | self.client.post('/login', { 29 | 'email': 'volunteer@example.com', 30 | 'password': '123volunteer', 31 | }) 32 | response = self.client.get('/offers/delete/{}' 33 | .format(self.inactive_offer.id)) 34 | self.assertEqual(response.status_code, 403) 35 | 36 | def test_offer_deletion_for_organization(self): 37 | """Test deletion for account of organization.""" 38 | self.client.post('/login', { 39 | 'email': 'organization@example.com', 40 | 'password': '123org', 41 | }) 42 | response = self.client.get('/offers/delete/{}' 43 | .format(self.inactive_offer.id)) 44 | self.assertEqual(response.status_code, 403) 45 | 46 | def test_offer_deletion_for_admin(self): 47 | """Test deletion for account of admin.""" 48 | self.client.post('/login', { 49 | 'email': 'admin@example.com', 50 | 'password': '123admin', 51 | }) 52 | response = self.client.get('/offers/delete/{}' 53 | .format(self.inactive_offer.id)) 54 | self.assertEqual(response.status_code, 302) 55 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/offers/test_offer_accept.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """ 4 | .. module:: test_offer_accept 5 | """ 6 | 7 | from django.test import Client 8 | from django.test import TestCase 9 | 10 | from apps.volontulo.tests.views.offers.commons import TestOffersCommons 11 | 12 | 13 | class TestOfferAccept(TestOffersCommons, TestCase): 14 | """Class responsible for testing offers acceptance.""" 15 | 16 | def setUp(self): 17 | """Set up each test.""" 18 | self.client = Client() 19 | 20 | def test_offer_acceptance_for_anonymous_user(self): 21 | """Test offer acceptance for anonymous users.""" 22 | response = self.client.get('/offers/delete/{}' 23 | .format(self.inactive_offer.id)) 24 | self.assertEqual(response.status_code, 403) 25 | 26 | def test_offer_acceptance_for_volunteer(self): 27 | """Test offer acceptance for account of volunteer.""" 28 | self.client.post('/login', { 29 | 'email': 'volunteer@example.com', 30 | 'password': '123volunteer', 31 | }) 32 | response = self.client.get('/offers/delete/{}' 33 | .format(self.inactive_offer.id)) 34 | self.assertEqual(response.status_code, 403) 35 | 36 | def test_offer_acceptance_for_organization(self): 37 | """Test offer acceptance for account of organization.""" 38 | self.client.post('/login', { 39 | 'email': 'organization@example.com', 40 | 'password': '123org', 41 | }) 42 | response = self.client.get('/offers/delete/{}' 43 | .format(self.inactive_offer.id)) 44 | self.assertEqual(response.status_code, 403) 45 | 46 | def test_offer_acceptance_for_admin(self): 47 | """Test offer acceptance for account of admin.""" 48 | self.client.post('/login', { 49 | 'email': 'admin@example.com', 50 | 'password': '123admin', 51 | }) 52 | response = self.client.get('/offers/delete/{}' 53 | .format(self.inactive_offer.id)) 54 | self.assertEqual(response.status_code, 302) 55 | -------------------------------------------------------------------------------- /apps/volontulo/lib/email.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: email 5 | """ 6 | 7 | from django.contrib.sites.shortcuts import get_current_site 8 | from django.core.mail import EmailMultiAlternatives 9 | from django.core.mail import get_connection 10 | from django.template import Context 11 | from django.template.loader import get_template 12 | 13 | from apps.volontulo.utils import get_administrators_emails 14 | 15 | FROM_ADDRESS = 'support@volontuloapp.org' 16 | FAIL_SILENTLY = False 17 | AUTH_USER = None 18 | AUTH_PASSWORD = None 19 | CONNECTION = None 20 | 21 | SUBJECTS = { 22 | 'offer_application': u'Zgłoszenie chęci pomocy w ofercie', 23 | 'offer_creation': u'Zgłoszenie oferty na Volontulo', 24 | 'registration': u'Rejestracja na Volontulo', 25 | 'volunteer_to_admin': u'Kontakt z administratorem', 26 | 'volunteer_to_organisation': u'Kontakt od wolontariusza', 27 | } 28 | 29 | 30 | def send_mail(request, templates_name, recipient_list, context=None): 31 | """Proxy for sending emails.""" 32 | fail_silently = FAIL_SILENTLY 33 | auth_user = AUTH_USER 34 | auth_password = AUTH_PASSWORD 35 | connection = CONNECTION 36 | 37 | context = Context(context or {}) 38 | context.update({ 39 | 'protocol': 'https' if request.is_secure() else 'http', 40 | 'domain': get_current_site(request).domain, 41 | }) 42 | text_template = get_template('emails/{}.txt'.format(templates_name)) 43 | html_template = get_template('emails/{}.html'.format(templates_name)) 44 | 45 | bcc = list(get_administrators_emails().values()) 46 | connection = connection or get_connection( 47 | username=auth_user, 48 | password=auth_password, 49 | fail_silently=fail_silently 50 | ) 51 | # required, if omitted then no emails from BCC are send 52 | headers = {'bcc': ','.join(bcc)} 53 | email = EmailMultiAlternatives( 54 | SUBJECTS[templates_name], 55 | text_template.render(context), 56 | FROM_ADDRESS, 57 | recipient_list, 58 | bcc, 59 | connection=connection, 60 | headers=headers 61 | ) 62 | email.attach_alternative(html_template.render(context), 'text/html') 63 | 64 | return email.send() 65 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_progress-bars.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Progress bars 3 | // -------------------------------------------------- 4 | 5 | 6 | // Bar animations 7 | // ------------------------- 8 | 9 | // WebKit 10 | @-webkit-keyframes progress-bar-stripes { 11 | from { background-position: 40px 0; } 12 | to { background-position: 0 0; } 13 | } 14 | 15 | // Spec and IE10+ 16 | @keyframes progress-bar-stripes { 17 | from { background-position: 40px 0; } 18 | to { background-position: 0 0; } 19 | } 20 | 21 | 22 | // Bar itself 23 | // ------------------------- 24 | 25 | // Outer container 26 | .progress { 27 | overflow: hidden; 28 | height: $line-height-computed; 29 | margin-bottom: $line-height-computed; 30 | background-color: $progress-bg; 31 | border-radius: $progress-border-radius; 32 | @include box-shadow(inset 0 1px 2px rgba(0,0,0,.1)); 33 | } 34 | 35 | // Bar of progress 36 | .progress-bar { 37 | float: left; 38 | width: 0%; 39 | height: 100%; 40 | font-size: $font-size-small; 41 | line-height: $line-height-computed; 42 | color: $progress-bar-color; 43 | text-align: center; 44 | background-color: $progress-bar-bg; 45 | @include box-shadow(inset 0 -1px 0 rgba(0,0,0,.15)); 46 | @include transition(width .6s ease); 47 | } 48 | 49 | // Striped bars 50 | // 51 | // `.progress-striped .progress-bar` is deprecated as of v3.2.0 in favor of the 52 | // `.progress-bar-striped` class, which you just add to an existing 53 | // `.progress-bar`. 54 | .progress-striped .progress-bar, 55 | .progress-bar-striped { 56 | @include gradient-striped; 57 | background-size: 40px 40px; 58 | } 59 | 60 | // Call animation for the active one 61 | // 62 | // `.progress.active .progress-bar` is deprecated as of v3.2.0 in favor of the 63 | // `.progress-bar.active` approach. 64 | .progress.active .progress-bar, 65 | .progress-bar.active { 66 | @include animation(progress-bar-stripes 2s linear infinite); 67 | } 68 | 69 | 70 | // Variations 71 | // ------------------------- 72 | 73 | .progress-bar-success { 74 | @include progress-bar-variant($progress-bar-success-bg); 75 | } 76 | 77 | .progress-bar-info { 78 | @include progress-bar-variant($progress-bar-info-bg); 79 | } 80 | 81 | .progress-bar-warning { 82 | @include progress-bar-variant($progress-bar-warning-bg); 83 | } 84 | 85 | .progress-bar-danger { 86 | @include progress-bar-variant($progress-bar-danger-bg); 87 | } 88 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/offers/test_offers_list.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """ 4 | .. module:: test_offers_list 5 | """ 6 | 7 | from django.test import Client 8 | from django.test import TestCase 9 | 10 | from apps.volontulo.tests.views.offers.commons import TestOffersCommons 11 | 12 | 13 | class TestOffersList(TestOffersCommons, TestCase): 14 | """Class responsible for testing offers' list.""" 15 | 16 | def setUp(self): 17 | """Set up each test.""" 18 | self.client = Client() 19 | 20 | def _test_offers_list_for_standard_user(self): 21 | """Test offers' list for standard user. 22 | 23 | List of offers is available for standard users and shows only ACTIVE 24 | offers. 25 | Test are common for anonymous user, volunteer and organization. 26 | """ 27 | response = self.client.get('/offers') 28 | self.assertEqual(response.status_code, 200) 29 | self.assertTemplateUsed(response, 'offers/offers_list.html') 30 | self.assertIn('offers', response.context) 31 | self.assertEqual(len(response.context['offers']), 0) 32 | 33 | def test_offer_list_for_anonymous_user(self): 34 | """Test offers' list for anonymus user.""" 35 | return self._test_offers_list_for_standard_user() 36 | 37 | def test_offers_list_for_volunteer(self): 38 | """Test offers' list for account of volunteer.""" 39 | self.client.post('/login', { 40 | 'email': 'volunteer@example.com', 41 | 'password': '123volunteer', 42 | }) 43 | return self._test_offers_list_for_standard_user() 44 | 45 | def test_offers_list_for_organization(self): 46 | """Test offers' list for account of organization.""" 47 | self.client.post('/login', { 48 | 'email': 'organization@example.com', 49 | 'password': '123org', 50 | }) 51 | return self._test_offers_list_for_standard_user() 52 | 53 | def test_offers_list_for_admin(self): 54 | """Test offers' list for account of admin.""" 55 | self.client.post('/login', { 56 | 'email': 'admin@example.com', 57 | 'password': '123admin', 58 | }) 59 | response = self.client.get('/offers') 60 | self.assertEqual(response.status_code, 200) 61 | self.assertTemplateUsed(response, 'offers/offers_list.html') 62 | self.assertIn('offers', response.context) 63 | self.assertEqual(len(response.context['offers']), 2) 64 | -------------------------------------------------------------------------------- /apps/volontulo/templates/organizations/organization_offers.html: -------------------------------------------------------------------------------- 1 | {% load staticfiles %} 2 | {% load main_image %} 3 | 4 | {% if offers %} 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | {% for o in offers %} 15 | 16 | 21 | 24 | 29 | 35 | 41 | 50 | 51 | {% endfor %} 52 |
TytułMiejsceCzas obowiązywaniaStatus
17 | 18 | {{o.images.all|main_image|slugify|default:''}} 19 | 20 | 22 | {{ o.title }} 23 | 25 |
26 | {{ o.location }} 27 |
28 |
30 |
31 | {{ o.started_at|date:'j E Y, G:m'|default:' teraz' }} - 32 | {{ o.finished_at|date:'j E Y, G:m'|default:' do ustalenia' }} 33 |
34 |
36 |
37 | {# {{ Offer.OFFER_STATUS[o.offer_status].value | default:' unavailable'}} #} 38 | {% include 'common/labeled_status.html' with status=o.offer_status %} 39 |
40 |
42 | {% if o.status_old == 'STAGED' %} 43 | Włącz się 44 | {% endif %} 45 | {# Only the user that can edit the organization can edit its offers #} 46 | {% if allow_edit %} 47 | Edytuj 48 | {% endif %} 49 |
53 | {% else %} 54 |

Ta organizacja nie utworzyła jeszcze żadnych ofert.

55 | {% endif %} 56 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_pagination.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Pagination (multiple pages) 3 | // -------------------------------------------------- 4 | .pagination { 5 | display: inline-block; 6 | padding-left: 0; 7 | margin: $line-height-computed 0; 8 | border-radius: $border-radius-base; 9 | 10 | > li { 11 | display: inline; // Remove list-style and block-level defaults 12 | > a, 13 | > span { 14 | position: relative; 15 | float: left; // Collapse white-space 16 | padding: $padding-base-vertical $padding-base-horizontal; 17 | line-height: $line-height-base; 18 | text-decoration: none; 19 | color: $pagination-color; 20 | background-color: $pagination-bg; 21 | border: 1px solid $pagination-border; 22 | margin-left: -1px; 23 | } 24 | &:first-child { 25 | > a, 26 | > span { 27 | margin-left: 0; 28 | @include border-left-radius($border-radius-base); 29 | } 30 | } 31 | &:last-child { 32 | > a, 33 | > span { 34 | @include border-right-radius($border-radius-base); 35 | } 36 | } 37 | } 38 | 39 | > li > a, 40 | > li > span { 41 | &:hover, 42 | &:focus { 43 | z-index: 3; 44 | color: $pagination-hover-color; 45 | background-color: $pagination-hover-bg; 46 | border-color: $pagination-hover-border; 47 | } 48 | } 49 | 50 | > .active > a, 51 | > .active > span { 52 | &, 53 | &:hover, 54 | &:focus { 55 | z-index: 2; 56 | color: $pagination-active-color; 57 | background-color: $pagination-active-bg; 58 | border-color: $pagination-active-border; 59 | cursor: default; 60 | } 61 | } 62 | 63 | > .disabled { 64 | > span, 65 | > span:hover, 66 | > span:focus, 67 | > a, 68 | > a:hover, 69 | > a:focus { 70 | color: $pagination-disabled-color; 71 | background-color: $pagination-disabled-bg; 72 | border-color: $pagination-disabled-border; 73 | cursor: $cursor-disabled; 74 | } 75 | } 76 | } 77 | 78 | // Sizing 79 | // -------------------------------------------------- 80 | 81 | // Large 82 | .pagination-lg { 83 | @include pagination-size($padding-large-vertical, $padding-large-horizontal, $font-size-large, $line-height-large, $border-radius-large); 84 | } 85 | 86 | // Small 87 | .pagination-sm { 88 | @include pagination-size($padding-small-vertical, $padding-small-horizontal, $font-size-small, $line-height-small, $border-radius-small); 89 | } 90 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_print.scss: -------------------------------------------------------------------------------- 1 | /*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */ 2 | 3 | // ========================================================================== 4 | // Print styles. 5 | // Inlined to avoid the additional HTTP request: h5bp.com/r 6 | // ========================================================================== 7 | 8 | @media print { 9 | *, 10 | *:before, 11 | *:after { 12 | background: transparent !important; 13 | color: #000 !important; // Black prints faster: h5bp.com/s 14 | box-shadow: none !important; 15 | text-shadow: none !important; 16 | } 17 | 18 | a, 19 | a:visited { 20 | text-decoration: underline; 21 | } 22 | 23 | a[href]:after { 24 | content: " (" attr(href) ")"; 25 | } 26 | 27 | abbr[title]:after { 28 | content: " (" attr(title) ")"; 29 | } 30 | 31 | // Don't show links that are fragment identifiers, 32 | // or use the `javascript:` pseudo protocol 33 | a[href^="#"]:after, 34 | a[href^="javascript:"]:after { 35 | content: ""; 36 | } 37 | 38 | pre, 39 | blockquote { 40 | border: 1px solid #999; 41 | page-break-inside: avoid; 42 | } 43 | 44 | thead { 45 | display: table-header-group; // h5bp.com/t 46 | } 47 | 48 | tr, 49 | img { 50 | page-break-inside: avoid; 51 | } 52 | 53 | img { 54 | max-width: 100% !important; 55 | } 56 | 57 | p, 58 | h2, 59 | h3 { 60 | orphans: 3; 61 | widows: 3; 62 | } 63 | 64 | h2, 65 | h3 { 66 | page-break-after: avoid; 67 | } 68 | 69 | // Bootstrap specific changes start 70 | 71 | // Bootstrap components 72 | .navbar { 73 | display: none; 74 | } 75 | .btn, 76 | .dropup > .btn { 77 | > .caret { 78 | border-top-color: #000 !important; 79 | } 80 | } 81 | .label { 82 | border: 1px solid #000; 83 | } 84 | 85 | .table { 86 | border-collapse: collapse !important; 87 | 88 | td, 89 | th { 90 | background-color: #fff !important; 91 | } 92 | } 93 | .table-bordered { 94 | th, 95 | td { 96 | border: 1px solid #ddd !important; 97 | } 98 | } 99 | 100 | // Bootstrap specific changes end 101 | } 102 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/test_organizations.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: test_organizations 5 | """ 6 | from django.test import Client 7 | from django.test import TestCase 8 | 9 | from apps.volontulo.models import Organization 10 | from apps.volontulo.tests import common 11 | 12 | 13 | class TestOrganizations(TestCase): 14 | u"""Class responsible for testing organization specific views.""" 15 | 16 | @classmethod 17 | def setUpTestData(cls): 18 | u"""Data fixtures for all tests.""" 19 | # volunteer user - totally useless 20 | cls.volunteer = common.initialize_empty_volunteer() 21 | # organization user - no offers 22 | cls.organization = common.initialize_empty_organization() 23 | # volunteer user - offers, organizations 24 | cls.volunteer2, cls.organization2 = \ 25 | common.initialize_filled_volunteer_and_organization() 26 | 27 | def setUp(self): 28 | u"""Set up each test.""" 29 | self.client = Client() 30 | 31 | def test__organization_list(self): 32 | u"""Test getting organization list as anonymous.""" 33 | response = self.client.get('/organizations', follow=True) 34 | 35 | self.assertEqual(response.status_code, 200) 36 | self.assertTemplateUsed(response, 'organizations/list.html') 37 | self.assertIn('organizations', response.context) 38 | self.assertEqual(Organization.objects.all().count(), 2) 39 | 40 | def test__ensure_status_is_displayed_in_profile_view(self): 41 | """Test if offer status is displayed in a profile view.""" 42 | self.client.login( 43 | username=u'volunteer2@example.com', 44 | password=u'volunteer2' 45 | ) 46 | response = self.client.get('/me', follow=True) 47 | self.assertTemplateUsed(response, 'users/my_offers.html') 48 | self.assertIn('offers', response.context) 49 | self.assertEqual( 50 | 'published', response.context['offers'][0].offer_status) 51 | 52 | def test__ensure_status_is_displayed_in_organisations_view(self): 53 | """Test if offer status is displayed in an organisation view.""" 54 | self.client.login( 55 | username=u'volunteer2@example.com', 56 | password=u'volunteer2' 57 | ) 58 | response = self.client.get('/me', follow=True) 59 | self.assertIn('offers', response.context) 60 | self.assertEqual( 61 | 'published', response.context['offers'][0].offer_status) 62 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap.scss: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.3.5 (http://getbootstrap.com) 3 | * Copyright 2011-2015 Twitter, Inc. 4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 5 | */ 6 | 7 | // Core variables and mixins 8 | @import "bootstrap/variables"; 9 | @import "bootstrap/mixins"; 10 | 11 | // Reset and dependencies 12 | @import "bootstrap/normalize"; 13 | @import "bootstrap/print"; 14 | @import "bootstrap/glyphicons"; 15 | 16 | // Core CSS 17 | @import "bootstrap/scaffolding"; 18 | @import "bootstrap/type"; 19 | @import "bootstrap/code"; 20 | @import "bootstrap/grid"; 21 | @import "bootstrap/tables"; 22 | @import "bootstrap/forms"; 23 | @import "bootstrap/buttons"; 24 | 25 | // Components 26 | @import "bootstrap/component-animations"; 27 | @import "bootstrap/dropdowns"; 28 | @import "bootstrap/button-groups"; 29 | @import "bootstrap/input-groups"; 30 | @import "bootstrap/navs"; 31 | @import "bootstrap/navbar"; 32 | @import "bootstrap/breadcrumbs"; 33 | @import "bootstrap/pagination"; 34 | @import "bootstrap/pager"; 35 | @import "bootstrap/labels"; 36 | @import "bootstrap/jumbotron"; 37 | @import "bootstrap/thumbnails"; 38 | @import "bootstrap/alerts"; 39 | @import "bootstrap/progress-bars"; 40 | @import "bootstrap/media"; 41 | @import "bootstrap/list-group"; 42 | @import "bootstrap/panels"; 43 | @import "bootstrap/responsive-embed"; 44 | @import "bootstrap/wells"; 45 | @import "bootstrap/close"; 46 | 47 | // Components w/ JavaScript 48 | @import "bootstrap/modals"; 49 | @import "bootstrap/tooltip"; 50 | @import "bootstrap/popovers"; 51 | @import "bootstrap/carousel"; 52 | 53 | // Utility classes 54 | @import "bootstrap/utilities"; 55 | @import "bootstrap/responsive-utilities"; 56 | 57 | // Icons 58 | @import "iconify/icons.svg.scss"; 59 | 60 | // Volontulo customization overwrites 61 | @import "customization/customization-variables"; 62 | @import "customization/auto-clear"; 63 | @import "customization/extended-media"; 64 | @import "customization/extended-thumbnail"; 65 | @import "customization/bootflat-panel"; 66 | @import "customization/customization"; 67 | 68 | // Open Sans webfont 69 | @import "open-sans/variables"; 70 | @import "open-sans/mixins"; 71 | @import "open-sans/Light"; 72 | //@import "open-sans/LightItalic"; 73 | @import "open-sans/Regular"; 74 | @import "open-sans/Italic"; 75 | @import "open-sans/Semibold"; 76 | //@import "open-sans/SemiboldItalic"; 77 | @import "open-sans/Bold"; 78 | @import "open-sans/BoldItalic"; 79 | //@import "open-sans/ExtraBold"; 80 | //@import "open-sans/ExtraBoldItalic"; 81 | -------------------------------------------------------------------------------- /apps/volontulo/tests/models/test_userprofile.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: test_userprofile 5 | """ 6 | from __future__ import unicode_literals 7 | from django.test import TestCase 8 | 9 | from apps.volontulo.models import Organization 10 | from apps.volontulo.models import User 11 | from apps.volontulo.models import UserProfile 12 | 13 | 14 | class TestUserProfile(TestCase): 15 | u"""Class responsible for testing UserProfile model.""" 16 | 17 | def setUp(self): 18 | u"""Set up each test.""" 19 | 20 | # volunteer user 21 | self.volunteer_user = UserProfile.objects.create( 22 | user=User.objects.create_user( 23 | username='volunteer@example.com', 24 | email='volunteer@example.com', 25 | password='volunteer', 26 | ), 27 | is_administrator=False, 28 | ) 29 | 30 | # organization user 31 | self.organization_user = UserProfile.objects.create( 32 | user=User.objects.create_user( 33 | username='organization@example.com', 34 | email='organization@example.com', 35 | password='organization', 36 | ), 37 | is_administrator=False, 38 | ) 39 | self.organization_user.organizations.add( 40 | Organization.objects.create(name=u'Organization') 41 | ) 42 | 43 | # administrator user 44 | self.administrator_user = UserProfile.objects.create( 45 | user=User.objects.create_user( 46 | username='administrator@example.com', 47 | email='administrator@example.com', 48 | password='administrator', 49 | ), 50 | is_administrator=True 51 | ) 52 | 53 | def test__string_reprezentation(self): 54 | u"""String reprezentation of an userprofile object.""" 55 | self.assertEqual( 56 | str(self.volunteer_user), 57 | u'volunteer@example.com', 58 | ) 59 | self.assertEqual( 60 | str(self.organization_user), 61 | u'organization@example.com' 62 | ) 63 | self.assertEqual( 64 | str(self.administrator_user), 65 | u'administrator@example.com' 66 | ) 67 | 68 | def test__is_admin_or_volunteer(self): 69 | """Check if specified user has enabled/disabled administrator flag.""" 70 | 71 | self.assertTrue(self.administrator_user.is_administrator) 72 | self.assertFalse(self.volunteer_user.is_administrator) 73 | self.assertFalse(self.organization_user.is_administrator) 74 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/javascripts/bootstrap/alert.js: -------------------------------------------------------------------------------- 1 | /* ======================================================================== 2 | * Bootstrap: alert.js v3.3.5 3 | * http://getbootstrap.com/javascript/#alerts 4 | * ======================================================================== 5 | * Copyright 2011-2015 Twitter, Inc. 6 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 7 | * ======================================================================== */ 8 | 9 | 10 | +function ($) { 11 | 'use strict'; 12 | 13 | // ALERT CLASS DEFINITION 14 | // ====================== 15 | 16 | var dismiss = '[data-dismiss="alert"]' 17 | var Alert = function (el) { 18 | $(el).on('click', dismiss, this.close) 19 | } 20 | 21 | Alert.VERSION = '3.3.5' 22 | 23 | Alert.TRANSITION_DURATION = 150 24 | 25 | Alert.prototype.close = function (e) { 26 | var $this = $(this) 27 | var selector = $this.attr('data-target') 28 | 29 | if (!selector) { 30 | selector = $this.attr('href') 31 | selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7 32 | } 33 | 34 | var $parent = $(selector) 35 | 36 | if (e) e.preventDefault() 37 | 38 | if (!$parent.length) { 39 | $parent = $this.closest('.alert') 40 | } 41 | 42 | $parent.trigger(e = $.Event('close.bs.alert')) 43 | 44 | if (e.isDefaultPrevented()) return 45 | 46 | $parent.removeClass('in') 47 | 48 | function removeElement() { 49 | // detach from parent, fire event then clean up data 50 | $parent.detach().trigger('closed.bs.alert').remove() 51 | } 52 | 53 | $.support.transition && $parent.hasClass('fade') ? 54 | $parent 55 | .one('bsTransitionEnd', removeElement) 56 | .emulateTransitionEnd(Alert.TRANSITION_DURATION) : 57 | removeElement() 58 | } 59 | 60 | 61 | // ALERT PLUGIN DEFINITION 62 | // ======================= 63 | 64 | function Plugin(option) { 65 | return this.each(function () { 66 | var $this = $(this) 67 | var data = $this.data('bs.alert') 68 | 69 | if (!data) $this.data('bs.alert', (data = new Alert(this))) 70 | if (typeof option == 'string') data[option].call($this) 71 | }) 72 | } 73 | 74 | var old = $.fn.alert 75 | 76 | $.fn.alert = Plugin 77 | $.fn.alert.Constructor = Alert 78 | 79 | 80 | // ALERT NO CONFLICT 81 | // ================= 82 | 83 | $.fn.alert.noConflict = function () { 84 | $.fn.alert = old 85 | return this 86 | } 87 | 88 | 89 | // ALERT DATA-API 90 | // ============== 91 | 92 | $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close) 93 | 94 | }(jQuery); 95 | -------------------------------------------------------------------------------- /apps/volontulo/templates/offers/reorder.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | {% load main_image %} 3 | 4 | {% block title %}Kolejność ofert{% endblock %} 5 | 6 | {% block content %} 7 | {% include 'admin/offers_nav.html' %} 8 | {% if offers %} 9 |

Kolejność ofert

10 |
11 | {% csrf_token %} 12 |
13 | 14 |
15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | {% for o in offers %} 25 | 26 | 31 | 34 | 37 | 43 | 46 | 47 | 48 | {% endfor %} 49 |
TytułMiejsceRozpoczęcieNazwa organizacjiWaga
27 | 28 | {{o.images.all|main_image|slugify|default:''}} 29 | 30 | 32 | {{ o.title }} 33 | 35 |
{{ o.location }}
36 |
38 |
39 | {{ o.started_at|date:'j E Y, G:m'|default:' teraz' }} - 40 | {{ o.finished_at|date:'j E Y, G:m'|default:' do ustalenia' }} 41 |
42 |
44 |
{{ o.organization.name }}
45 |
50 |
51 | 52 |
53 |
54 | {% else %} 55 |

Brak ofert spełniających podane kryteria

56 | {% endif %} 57 | {% endblock %} 58 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_grid-framework.scss: -------------------------------------------------------------------------------- 1 | // Framework grid generation 2 | // 3 | // Used only by Bootstrap to generate the correct number of grid classes given 4 | // any value of `$grid-columns`. 5 | 6 | // [converter] This is defined recursively in LESS, but Sass supports real loops 7 | @mixin make-grid-columns($i: 1, $list: ".col-xs-#{$i}, .col-sm-#{$i}, .col-md-#{$i}, .col-lg-#{$i}") { 8 | @for $i from (1 + 1) through $grid-columns { 9 | $list: "#{$list}, .col-xs-#{$i}, .col-sm-#{$i}, .col-md-#{$i}, .col-lg-#{$i}"; 10 | } 11 | #{$list} { 12 | position: relative; 13 | // Prevent columns from collapsing when empty 14 | min-height: 1px; 15 | // Inner gutter via padding 16 | padding-left: ceil(($grid-gutter-width / 2)); 17 | padding-right: floor(($grid-gutter-width / 2)); 18 | } 19 | } 20 | 21 | 22 | // [converter] This is defined recursively in LESS, but Sass supports real loops 23 | @mixin float-grid-columns($class, $i: 1, $list: ".col-#{$class}-#{$i}") { 24 | @for $i from (1 + 1) through $grid-columns { 25 | $list: "#{$list}, .col-#{$class}-#{$i}"; 26 | } 27 | #{$list} { 28 | float: left; 29 | } 30 | } 31 | 32 | 33 | @mixin calc-grid-column($index, $class, $type) { 34 | @if ($type == width) and ($index > 0) { 35 | .col-#{$class}-#{$index} { 36 | width: percentage(($index / $grid-columns)); 37 | } 38 | } 39 | @if ($type == push) and ($index > 0) { 40 | .col-#{$class}-push-#{$index} { 41 | left: percentage(($index / $grid-columns)); 42 | } 43 | } 44 | @if ($type == push) and ($index == 0) { 45 | .col-#{$class}-push-0 { 46 | left: auto; 47 | } 48 | } 49 | @if ($type == pull) and ($index > 0) { 50 | .col-#{$class}-pull-#{$index} { 51 | right: percentage(($index / $grid-columns)); 52 | } 53 | } 54 | @if ($type == pull) and ($index == 0) { 55 | .col-#{$class}-pull-0 { 56 | right: auto; 57 | } 58 | } 59 | @if ($type == offset) { 60 | .col-#{$class}-offset-#{$index} { 61 | margin-left: percentage(($index / $grid-columns)); 62 | } 63 | } 64 | } 65 | 66 | // [converter] This is defined recursively in LESS, but Sass supports real loops 67 | @mixin loop-grid-columns($columns, $class, $type) { 68 | @for $i from 0 through $columns { 69 | @include calc-grid-column($i, $class, $type); 70 | } 71 | } 72 | 73 | 74 | // Create grid for specific class 75 | @mixin make-grid($class) { 76 | @include float-grid-columns($class); 77 | @include loop-grid-columns($grid-columns, $class, width); 78 | @include loop-grid-columns($grid-columns, $class, pull); 79 | @include loop-grid-columns($grid-columns, $class, push); 80 | @include loop-grid-columns($grid-columns, $class, offset); 81 | } 82 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/offers/commons.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """ 4 | .. module:: commons 5 | """ 6 | 7 | from django.contrib.auth.models import User 8 | 9 | from apps.volontulo.models import Offer 10 | from apps.volontulo.models import Organization 11 | from apps.volontulo.models import UserProfile 12 | 13 | 14 | class TestOffersCommons(object): 15 | """Commons setups for offers' testcases.""" 16 | 17 | @classmethod 18 | def setUpTestData(cls): 19 | """Set up data for all tests.""" 20 | cls.organization = Organization.objects.create( 21 | name='Organization Name', 22 | address='', 23 | description='', 24 | ) 25 | cls.organization.save() 26 | 27 | cls.common_offer_data = { 28 | 'organization': cls.organization, 29 | 'description': '', 30 | 'requirements': '', 31 | 'time_commitment': '', 32 | 'benefits': '', 33 | 'location': '', 34 | 'title': 'volontulo offer', 35 | 'time_period': '', 36 | 'started_at': '2105-10-24 09:10:11', 37 | 'finished_at': '2105-11-28 12:13:14', 38 | 'offer_status': 'unpublished', 39 | 'recruitment_status': 'closed', 40 | 'action_status': 'ongoing', 41 | } 42 | 43 | cls.inactive_offer = Offer.objects.create( 44 | status_old='NEW', 45 | **cls.common_offer_data 46 | ) 47 | cls.inactive_offer.save() 48 | cls.active_offer = Offer.objects.create( 49 | status_old='ACTIVE', 50 | **cls.common_offer_data 51 | ) 52 | cls.active_offer.save() 53 | 54 | volunteer_user = User.objects.create_user( 55 | 'volunteer@example.com', 56 | 'volunteer@example.com', 57 | '123volunteer' 58 | ) 59 | 60 | cls.volunteer = UserProfile(user=volunteer_user) 61 | cls.volunteer.save() 62 | 63 | organization_user = User.objects.create_user( 64 | 'cls.organization@example.com', 65 | 'cls.organization@example.com', 66 | '123org' 67 | ) 68 | 69 | cls.organization_profile = UserProfile( 70 | user=organization_user, 71 | ) 72 | cls.organization_profile.save() 73 | cls.organization_profile.organizations.add(cls.organization) 74 | 75 | admin_user = User.objects.create_user( 76 | 'admin@example.com', 77 | 'admin@example.com', 78 | '123admin' 79 | ) 80 | 81 | cls.admin = UserProfile( 82 | user=admin_user, 83 | is_administrator=True, 84 | ) 85 | cls.admin.save() 86 | -------------------------------------------------------------------------------- /apps/volontulo/utils.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: utils 5 | """ 6 | from django.contrib.admin.models import LogEntry 7 | from django.contrib.auth.models import User 8 | from django.contrib.contenttypes.models import ContentType 9 | from django.shortcuts import get_object_or_404 10 | from django.shortcuts import redirect 11 | from django.utils.text import slugify 12 | 13 | from apps.volontulo.models import UserProfile 14 | 15 | 16 | # Offers statuses dictionary with meaningful names. 17 | # todo: remove dependency 18 | OFFERS_STATUSES = { 19 | 'NEW': 'Nowa', 20 | 'ACTIVE': 'Aktywna', 21 | 'FINISHED': 'Zakończona', 22 | 'SUSPENDED': 'Zawieszona', 23 | 'CLOSED': 'Zamknięta', 24 | } 25 | 26 | 27 | def get_administrators_emails(): 28 | """Get all administrators emails or superuser email 29 | 30 | Format returned: 31 | emails = { 32 | 1: 'admin1@example.com', 33 | 2: 'admin2@example.com', 34 | } 35 | """ 36 | administrators = UserProfile.objects.filter(is_administrator=True) 37 | emails = {} 38 | for admin in administrators: 39 | emails[str(admin.user.id)] = admin.user.email 40 | 41 | if not emails: 42 | administrators = User.objects.filter(is_superuser=True) 43 | for admin in administrators: 44 | emails[str(admin.id)] = admin.email 45 | 46 | return emails 47 | 48 | 49 | def save_history(req, obj, action): 50 | """Save model changes history.""" 51 | LogEntry.objects.log_action( 52 | user_id=req.user.pk, 53 | content_type_id=ContentType.objects.get_for_model(obj).pk, 54 | object_id=obj.pk, 55 | object_repr=str(obj), 56 | action_flag=action 57 | ) 58 | 59 | 60 | def correct_slug(model_class, view_name, slug_field): 61 | """Decorator that is reposponsible for redirect to url with correct slug. 62 | 63 | It is used by url for offers, organizations and users. 64 | """ 65 | def decorator(wrapped_func): 66 | """Decorator function for correcting slugs.""" 67 | 68 | def wrapping_func(request, slug, id_): 69 | """Wrapping function for correcting slugs.""" 70 | obj = get_object_or_404(model_class, id=id_) 71 | if slug != slugify(getattr(obj, slug_field)): 72 | return redirect( 73 | view_name, 74 | slug=slugify(getattr(obj, slug_field)), 75 | id_=id_ 76 | ) 77 | return wrapped_func(request, slug, id_) 78 | 79 | return wrapping_func 80 | 81 | return decorator 82 | 83 | 84 | def is_admin_test(user): 85 | """Check if passed user is administrator 86 | 87 | :param user: An instance of AUTH_USER_MODEL representing 88 | the currently logged-in user. 89 | """ 90 | return user.is_authenticated() and user.userprofile.is_administrator 91 | -------------------------------------------------------------------------------- /apps/volontulo/templates/auth/login.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}Logowanie do Volontulo{% endblock %} 4 | 5 | {% block content %} 6 |
7 |

Rejestracja w Volontulo

8 |
9 | {% csrf_token %} 10 |
11 | {{ user_form.email.errors }} 12 | 13 | 14 |
15 |
16 | {{ user_form.password.errors }} 17 | 18 | 19 |
20 |
21 | {{ user_form.terms_acceptance.errors }} 22 | 23 |
24 | 25 |
26 |
27 |
28 |

Logowanie

29 |
30 | {% csrf_token %} 31 |
32 | {{ user_form.email.label_tag }} 33 | 34 |
35 |
36 | {{ user_form.password.label_tag }} 37 | 38 |
39 | 42 | 43 |
44 |
45 | {% endblock %} 46 | -------------------------------------------------------------------------------- /apps/volontulo/templates/pages/about-us.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | 3 | {% block title %}O nas{% endblock %} 4 | 5 | {% block content %} 6 |

O Volontulo

7 |
8 |
Lubisz nowe wyzwania? Chcesz pomagać innym? Zależy Ci na rozwoju? Szukasz wolontariuszy? Jeśli choć na jedno z tych pytań opowiedziałeś/aś twierdząco wolontariat to odpowiedź dla Ciebie! Zgłoś się do Poznańskiego Centrum Wolontariatu prowadzonego przez Wielkopolską Radę Koordynacyjną Związek Organizacji Pozarządowych. Naszym celem jest pomoc we wzajemnym odnalezieniu się ludzi, którzy chcą realizować się jako wolontariusze/szki oraz organizacji i instytucji, które takich osób poszukują.
9 | 10 |
Wolontariat to niesamowita okazja do zdobycia nowych doświadczeń, rozwoju swoich umiejętności i kompetencji, poznania innych ludzi. To także świadomość, że to co robisz ma sens!
11 | 12 |

KIM JESTEŚMY?

13 | 14 |
Wielkopolska Rada Koordynacyjna Związek Organizacji Pozarządowych jest dobrowolnym związkiem organizacji pozarządowych, który został utworzony w 1990 roku z inicjatywy kilkudziesięciu organizacji społecznych. Dziś jesteśmy największym związkiem w Wielkopolsce i zrzeszamy ponad 200 fundacji i stowarzyszeń z całego regionu. Poprzez swoją działalność kształcimy proobywatelskie i proaktywne postawy mieszkańców i mieszkanek Wielkopolski. Jako lider ruchu obywatelskiego w regionie inspirujemy do działań w obszarze „małych ojczyzn”. Uwrażliwiamy na potrzeby i problemy innych. Edukujemy, doradzamy, animujemy, wspieramy zarówno grupy formalne jak i nieformalne oraz niezrzeszonych aktywistów…
15 | 16 |
Od lat działamy na rzecz: 17 |
    18 |
  • wzmocnienia postaw obywatelskich,
  • 19 |
  • inicjowania i pomocy w uruchomieniu nowych społecznych inicjatyw,
  • 20 |
  • animowania wolontariatu,
  • 21 |
  • współpracy międzynarodowej i wymiany doświadczeń związanych z funkcjonowaniem sektora obywatelskiego.
  • 22 |
23 |
24 | 25 |
W swoim działaniu kierujemy się wzajemnym wsparciem, partnerstwem, otwartą komunikacją, zaufaniem.
26 | 27 |
Od 2012 roku należymy do Ogólnopolskiej Sieci Centrów Wolontariatu i prowadzimy w Wielkopolsce Regionalne Centrum Wolontariatu koordynujące sieć 17 Lokalnych Centrów Wolontariatu. Jeśli chcesz założyć Lokalne Centrum Wolontariatu w swojej miejscowości, również zgłoś się do nas. Przygotujemy Ciebie i Twoją organizację.
28 | 29 |
W Poznaniu znajdziesz nas na ul. Bukowskiej 27/29, gdzie prowadzimy Poznańskie Centrum Wolontariatu i pomagamy łączyć wolontariuszy z organizatorami wolontariatu.
30 | 31 |
Więcej informacji o nas znajdziesz na www.wrk.org.pl.
32 |
33 | 34 | {% endblock %} 35 | -------------------------------------------------------------------------------- /apps/volontulo/tests/views/offers/test_offers_archived.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | u""" 4 | .. module:: test_offers_2 5 | """ 6 | 7 | from django.contrib.auth.models import User 8 | from django.test import Client 9 | from django.test import TestCase 10 | 11 | from apps.volontulo.models import Offer 12 | from apps.volontulo.models import Organization 13 | from apps.volontulo.models import UserProfile 14 | 15 | 16 | class TestOffersArchived(TestCase): 17 | """Class responsible for testing archived offers page.""" 18 | 19 | @classmethod 20 | def setUpTestData(cls): 21 | """Set up data for all tests.""" 22 | for i in range(1, 6): 23 | Organization.objects.create( 24 | name='Organization {0} name'.format(i), 25 | address='Organization {0} address'.format(i), 26 | description='Organization {0} description'.format(i), 27 | ) 28 | 29 | organizations = Organization.objects.all() 30 | for idx, org in enumerate(organizations): 31 | for i in range(1, 6): 32 | user = User.objects.create_user( 33 | 'volunteer{0}{1}@example.com'.format(idx + 1, i), 34 | 'volunteer{0}{1}@example.com'.format(idx + 1, i), 35 | 'password', 36 | ) 37 | userprofile = UserProfile(user=user) 38 | userprofile.save() 39 | userprofile.organizations.add(org) 40 | userprofile.save() 41 | 42 | for idx, org in enumerate(organizations): 43 | for i in range(0, idx + 1): 44 | Offer.objects.create( 45 | organization=org, 46 | benefits='Offer {0}-{1} benefits'.format(idx + 1, i), 47 | location='Offer {0}-{1} location'.format(idx + 1, i), 48 | title='Offer {0}-{1} title'.format(idx + 1, i), 49 | time_period='', 50 | description='', 51 | requirements='', 52 | time_commitment='', 53 | offer_status='published', 54 | recruitment_status='closed', 55 | action_status='finished', 56 | started_at='2010-10-10 10:10:10', 57 | finished_at='2012-12-12 12:12:12' 58 | ) 59 | 60 | def setUp(self): 61 | """Set up each test.""" 62 | self.client = Client() 63 | 64 | def test_offers_archived_page(self): 65 | """Offers archive page.""" 66 | response = self.client.get('/offers/archived') 67 | 68 | self.assertEqual(response.status_code, 200) 69 | self.assertTemplateUsed(response, 'offers/archived.html') 70 | self.assertIn('offers', response.context) 71 | self.assertEqual(len(response.context['offers']), 15) 72 | self.assertNotContains( 73 | response, 74 | 'Brak ofert spełniających podane kryteria', 75 | ) 76 | -------------------------------------------------------------------------------- /apps/volontulo/templates/offers/offers_list.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | {% load main_image %} 3 | 4 | {% block title %}Lista ofert Volontulo{% endblock %} 5 | 6 | {% block content %} 7 | {% include 'admin/offers_nav.html' %} 8 | {% if offers %} 9 |

Lista ofert

10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | {% for offer in offers %} 20 | 21 | 26 | 29 | 32 | 38 | 41 | 55 | 56 | {% endfor %} 57 |
TytułMiejsceCzas obowiązywaniaNazwa organizacji
22 | 23 | {{offer.images.all|slugify|default:''}} 24 | 25 | 27 | {{ offer.title }} 28 | 30 |
{{ offer.location }}
31 |
33 |
34 | {{ offer.started_at|date:'j E Y, G:m'|default:' teraz' }} - 35 | {{ offer.finished_at|date:'j E Y, G:m'|default:' do ustalenia' }} 36 |
37 |
39 | 40 | 42 | {% if user.userprofile.is_administrator %} 43 | {% if offer.offer_status == 'unpublished' %} 44 |
45 | {% csrf_token %} 46 | 47 | 48 | 49 |
50 | {% endif %} 51 | {% elif offer.offer_status == 'published' %} 52 | Włącz się 53 | {% endif %} 54 |
58 | {% else %} 59 |

Brak ofert spełniających podane kryteria

60 | {% endif %} 61 | 62 | {% endblock %} 63 | -------------------------------------------------------------------------------- /apps/volontulo/templates/users/user_profile.html: -------------------------------------------------------------------------------- 1 | {% extends "common/col1.html" %} 2 | {% load bootstrap3 %} 3 | 4 | {% block title %}Strona użytkownika {{ user.email }}{% endblock %} 5 | 6 | {% block name %}user-profile{% endblock %} 7 | 8 | {% block content %} 9 | 10 |
11 |
12 |
13 |

14 | 15 | Zdjęcie profilowe 16 |

17 |
18 |
19 | {% include 'users/gallery.html' with image=image %} 20 |
21 |
22 | 23 |
24 |
25 |
26 |
27 |
28 |
29 |

30 | 31 | Profil 32 |

33 |
34 |
35 | {% csrf_token %} 36 | {% bootstrap_form profile_form %} 37 |
38 | 39 |
40 |
41 |
42 |
43 |
44 |
45 | 46 |
47 |

48 | 49 | Aktywność 50 |

51 |
52 | {% if participated_offers %} 53 |

Oferty w których zamierzasz wziąć udział

54 | {% endif %} 55 | {% include 'users/my_offers.html' with offers=participated_offers%} 56 |
57 |
58 | 59 |
60 |

61 | 62 | Działania w instytucji czy organizacji 63 |

64 |
65 | {% include 'organizations/gallery.html' with image_form=image_form gallery=gallery %} 66 |
67 |
68 |

Organizowane oferty

69 | Utwórz ofertę 70 |
71 | {% include 'organizations/organization_offers.html' with offers=created_offers %} 72 |
73 |
74 | 75 | {% endblock %} 76 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/mixins/_forms.scss: -------------------------------------------------------------------------------- 1 | // Form validation states 2 | // 3 | // Used in forms.less to generate the form validation CSS for warnings, errors, 4 | // and successes. 5 | 6 | @mixin form-control-validation($text-color: #555, $border-color: #ccc, $background-color: #f5f5f5) { 7 | // Color the label and help text 8 | .help-block, 9 | .control-label, 10 | .radio, 11 | .checkbox, 12 | .radio-inline, 13 | .checkbox-inline, 14 | &.radio label, 15 | &.checkbox label, 16 | &.radio-inline label, 17 | &.checkbox-inline label { 18 | color: $text-color; 19 | } 20 | // Set the border and box shadow on specific inputs to match 21 | .form-control { 22 | border-color: $border-color; 23 | @include box-shadow(inset 0 1px 1px rgba(0,0,0,.075)); // Redeclare so transitions work 24 | &:focus { 25 | border-color: darken($border-color, 10%); 26 | $shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 6px lighten($border-color, 20%); 27 | @include box-shadow($shadow); 28 | } 29 | } 30 | // Set validation states also for addons 31 | .input-group-addon { 32 | color: $text-color; 33 | border-color: $border-color; 34 | background-color: $background-color; 35 | } 36 | // Optional feedback icon 37 | .form-control-feedback { 38 | color: $text-color; 39 | } 40 | } 41 | 42 | 43 | // Form control focus state 44 | // 45 | // Generate a customized focus state and for any input with the specified color, 46 | // which defaults to the `$input-border-focus` variable. 47 | // 48 | // We highly encourage you to not customize the default value, but instead use 49 | // this to tweak colors on an as-needed basis. This aesthetic change is based on 50 | // WebKit's default styles, but applicable to a wider range of browsers. Its 51 | // usability and accessibility should be taken into account with any change. 52 | // 53 | // Example usage: change the default blue border and shadow to white for better 54 | // contrast against a dark gray background. 55 | @mixin form-control-focus($color: $input-border-focus) { 56 | $color-rgba: rgba(red($color), green($color), blue($color), .6); 57 | &:focus { 58 | border-color: $color; 59 | outline: 0; 60 | @include box-shadow(inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px $color-rgba); 61 | } 62 | } 63 | 64 | // Form control sizing 65 | // 66 | // Relative text size, padding, and border-radii changes for form controls. For 67 | // horizontal sizing, wrap controls in the predefined grid classes. ` 11 | {% for option in contact_form.applicant.choices %} 12 | 13 | {% endfor %} 14 | 15 | 16 | 17 |
18 | 19 |
20 | 25 |
26 |
27 | {% endif %} 28 | 29 |
30 | 31 |
32 | 33 |
34 |
35 |
36 | 37 |
38 | 39 |
40 | {% if contact_form.phone_no %} 41 | 42 |
43 | 44 |
45 | {% endif %} 46 |
47 |
48 | 49 |
50 | 51 |
52 |
53 | 54 |
55 |
56 | {% if organization %} 57 | 58 | {% endif %} 59 | 60 |
61 |
62 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # volontulo 2 | 3 | [![Join the chat at https://gitter.im/stxnext-csr/volontulo](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/stxnext-csr/volontulo?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) 4 | [![Build Status](https://travis-ci.org/stxnext-csr/volontulo.svg)](https://travis-ci.org/stxnext-csr/volontulo) 5 | [![codecov.io](http://codecov.io/github/stxnext-csr/volontulo/coverage.svg?branch=master)](http://codecov.io/github/stxnext-csr/volontulo?branch=master) 6 | 7 | ![Volontulo logo](/apps/volontulo/frontend/img/volo_logo.png) 8 | 9 | Web portal for collaboration of community volunteers with organizations and institutions. 10 | 11 | ## Semi-automated Project Set Up 12 | 13 | Install system dependecies 14 | ``` 15 | sudo bin/install_dependencies 16 | ``` 17 | Setup virtualenv, python packages, run migration and gulp. 18 | ``` 19 | bin/setup 20 | ``` 21 | Activate virtualenv. 22 | ``` 23 | source env/bin/activate 24 | ``` 25 | Django commands 26 | ``` 27 | python manage.py COMMAND --settings=volontulo_org.settings.dev 28 | ``` 29 | 30 | ## Manual Project Set Up 31 | 32 | Usage of virtualenv is recommended. Assuming you use Virtualenvwrapper: 33 | ``` 34 | mkvirtualenv --no-site-packages venv_name 35 | ``` 36 | To install project dependencies use pip and choose the correct file (production, development, etc.) 37 | ``` 38 | pip install -r requirements/dev.txt 39 | ``` 40 | 41 | Copy the Local Configuration file: 42 | ``` 43 | cp etc/local_config.yaml.sample local_config.yaml 44 | vim local_config.yaml 45 | ``` 46 | 47 | Fill the Local Configuration Values. 48 | To generate "secret_key", you can use 49 | ```head -c 64 /dev/urandom | base64 -w 0``` 50 | For Windows users may be used simple: 51 | ``` 52 | python -c "import uuid; print str(uuid.uuid4()).replace('-', '')" 53 | ``` 54 | 55 | If the site is supposed to be served under different domain than volontulo.org or volontuloapp.org 56 | and you are not in development environment, fill the "allowed_host" value. Otherwise 57 | it can be left blank. 58 | 59 | ### Gulp Instalation 60 | 61 | Gulp is used to prepare and serve all static files into `/apps/volontulo/static/volontulo` so Django can use them 62 | ``` 63 | cd /apps/volontulo 64 | npm install 65 | ``` 66 | Windows can have problems with unix paths, so it is practical to install Gulp globally (with `sudo` on linux) 67 | ``` 68 | npm install -g gulp 69 | ``` 70 | ### Using Gulp 71 | In development 72 | ``` 73 | gulp watch 74 | ``` 75 | Otherwise 76 | ``` 77 | gulp build 78 | ``` 79 | To convert svg icons to base64 format that ultimately is compiled to CSS, use: 80 | ``` 81 | gulp build_icons 82 | ``` 83 | Icons in .svg format should be placed at `\volontulo\apps\volontulo\frontend\icons\`. 84 | That will allow their usage in SCSS like so: `@extend %asterisk-icon;` as an element background. 85 | 86 | ### Running the App in development mode 87 | Choose the appriopriate settings file 88 | Run server 89 | ``` 90 | python manage.py runserver --settings=volontulo_org.settings.dev 91 | ``` 92 | Now you able to access the development site: 93 | [http://localhost:8000](http://localhost:8000) 94 | 95 | ### Running tests 96 | To run the project tests: 97 | ``` 98 | python manage.py test --settings=volontulo_org.settings.dev -v 3 99 | ``` 100 | 101 | ### Initial admin credentials 102 | * user: admin@volontuloapp.org 103 | * pass: stx123 104 | -------------------------------------------------------------------------------- /apps/volontulo/templates/users/my_offers.html: -------------------------------------------------------------------------------- 1 | {% load main_image %} 2 | 3 | {% if offers %} 4 |
5 | {% for offer in offers %} 6 |
7 |
8 | 9 | 10 |
11 |
12 |

13 | {{ offer.title }} 14 |

15 |
16 |
17 |
18 |
19 | 20 |
21 |
22 | {{ offer.location }} 23 |
24 |
25 |
26 |
27 |
28 | 29 |
30 |
31 | {{ offer.started_at|date:'j E Y, G:m'|default:' teraz' }} - 32 | {{ offer.finished_at|date:'j E Y, G:m'|default:' do ustalenia' }} 33 |
34 |
35 |
36 |
37 |
38 |
39 | {% if offer.benefits %} 40 |

Twoje korzyści

41 |

{{ offer.benefits }}

42 | {% endif %} 43 | {% if offer.requirements %} 44 |

Wymagania wobec Ciebie

45 |

{{ offer.requirements }}

46 | {% endif %} 47 | {% if offer.time_commitment %} 48 |

Zaangażowanie czasowe

49 |

{{ offer.time_commitment }}

50 | {% endif %} 51 | 52 |
53 |
54 |
55 | {% endfor %} 56 |
57 | 58 | {% else %} 59 |

Zgłoś się w jednej z dostępnych ofert wolontariuatu i zapełnij to miejsce.

60 | {% endif %} 61 | -------------------------------------------------------------------------------- /apps/volontulo/frontend/scss/bootstrap/_tooltip.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Tooltips 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base class 7 | .tooltip { 8 | position: absolute; 9 | z-index: $zindex-tooltip; 10 | display: block; 11 | // Our parent element can be arbitrary since tooltips are by default inserted as a sibling of their target element. 12 | // So reset our font and text properties to avoid inheriting weird values. 13 | @include reset-text; 14 | font-size: $font-size-small; 15 | 16 | @include opacity(0); 17 | 18 | &.in { @include opacity($tooltip-opacity); } 19 | &.top { margin-top: -3px; padding: $tooltip-arrow-width 0; } 20 | &.right { margin-left: 3px; padding: 0 $tooltip-arrow-width; } 21 | &.bottom { margin-top: 3px; padding: $tooltip-arrow-width 0; } 22 | &.left { margin-left: -3px; padding: 0 $tooltip-arrow-width; } 23 | } 24 | 25 | // Wrapper for the tooltip content 26 | .tooltip-inner { 27 | max-width: $tooltip-max-width; 28 | padding: 3px 8px; 29 | color: $tooltip-color; 30 | text-align: center; 31 | background-color: $tooltip-bg; 32 | border-radius: $border-radius-base; 33 | } 34 | 35 | // Arrows 36 | .tooltip-arrow { 37 | position: absolute; 38 | width: 0; 39 | height: 0; 40 | border-color: transparent; 41 | border-style: solid; 42 | } 43 | // Note: Deprecated .top-left, .top-right, .bottom-left, and .bottom-right as of v3.3.1 44 | .tooltip { 45 | &.top .tooltip-arrow { 46 | bottom: 0; 47 | left: 50%; 48 | margin-left: -$tooltip-arrow-width; 49 | border-width: $tooltip-arrow-width $tooltip-arrow-width 0; 50 | border-top-color: $tooltip-arrow-color; 51 | } 52 | &.top-left .tooltip-arrow { 53 | bottom: 0; 54 | right: $tooltip-arrow-width; 55 | margin-bottom: -$tooltip-arrow-width; 56 | border-width: $tooltip-arrow-width $tooltip-arrow-width 0; 57 | border-top-color: $tooltip-arrow-color; 58 | } 59 | &.top-right .tooltip-arrow { 60 | bottom: 0; 61 | left: $tooltip-arrow-width; 62 | margin-bottom: -$tooltip-arrow-width; 63 | border-width: $tooltip-arrow-width $tooltip-arrow-width 0; 64 | border-top-color: $tooltip-arrow-color; 65 | } 66 | &.right .tooltip-arrow { 67 | top: 50%; 68 | left: 0; 69 | margin-top: -$tooltip-arrow-width; 70 | border-width: $tooltip-arrow-width $tooltip-arrow-width $tooltip-arrow-width 0; 71 | border-right-color: $tooltip-arrow-color; 72 | } 73 | &.left .tooltip-arrow { 74 | top: 50%; 75 | right: 0; 76 | margin-top: -$tooltip-arrow-width; 77 | border-width: $tooltip-arrow-width 0 $tooltip-arrow-width $tooltip-arrow-width; 78 | border-left-color: $tooltip-arrow-color; 79 | } 80 | &.bottom .tooltip-arrow { 81 | top: 0; 82 | left: 50%; 83 | margin-left: -$tooltip-arrow-width; 84 | border-width: 0 $tooltip-arrow-width $tooltip-arrow-width; 85 | border-bottom-color: $tooltip-arrow-color; 86 | } 87 | &.bottom-left .tooltip-arrow { 88 | top: 0; 89 | right: $tooltip-arrow-width; 90 | margin-top: -$tooltip-arrow-width; 91 | border-width: 0 $tooltip-arrow-width $tooltip-arrow-width; 92 | border-bottom-color: $tooltip-arrow-color; 93 | } 94 | &.bottom-right .tooltip-arrow { 95 | top: 0; 96 | left: $tooltip-arrow-width; 97 | margin-top: -$tooltip-arrow-width; 98 | border-width: 0 $tooltip-arrow-width $tooltip-arrow-width; 99 | border-bottom-color: $tooltip-arrow-color; 100 | } 101 | } 102 | --------------------------------------------------------------------------------