Skip to main content

Submitify

Build Status Coverage Status PyPI

Multi-format submission accepting platform.

Quick start

  1. Add “submitify” to your INSTALLED_APPS setting like this:

    INSTALLED_APPS = [
        ...
        'submitify',
    ]

    Ensure that you have django.contrib.auth added as an application as well.

  2. Include the submitify URLconf in your project urls.py like this:

    url(r'^submitify/', include('submitify.urls')),
  3. Run python manage.py migrate to create the submitify models.

  4. Start the development server.

  5. Visit http://127.0.0.1:8000/submitify/ to see the app.

Notes for the pluggable application

The standalone application is basically ready to use as one would normally run a Django app, but the pluggable application has a few more things to note.

  • Submitify hooks into the Django permissions system. Creating a new call-for-submissions requires the submitify.add_call permission, so publishers should be added to a group with that permission.

  • Submitify is designed, loosely, for a site using Bootstrap, so elements are classed as such, but this is designed to not be a hard requirement. To that end, some styles are defined within the templates.

  • Applications must implement the ability to add users as readers/invite users as writers. A form for doing such is available at submitify.forms.InviteForm. The view should look something like this:

    def view_user(request, username=None):
        user = get_object_or_404(User, username=username)
        ...
        invite_calls_reading = []
        invite_calls_writing = []
        if request.user.is_authenticated and request.user != user:
            invite_calls_reading = request.user.submitify_calls_editing.filter(
                  ~Q(readers__in=[user]),
                status__in=[
                    Call.NOT_OPEN_YET,
                    Call.OPEN
                  ])
            invite_calls_writing = request.user.submitify_calls_reading.filter(
                    status__in=[
                    Call.NOT_OPEN_YET,
                    Call.OPEN,
                  ],
                invite_only=True)
        invite_reader_form = InviteForm(initial={
              'user': user,
          })
        invite_reader_form.fields['calls'].queryset = invite_calls_reading
        invite_writer_form = InviteForm(initial={
              'user': user,
          })
        invite_writer_form.fields['calls'].queryset = invite_calls_writing
        return render(request, 'view_profile.html', {
              ...
              'invite_reader_form': (invite_reader_form if
                                   len(invite_calls_reading) > 0 else None),
              'invite_writer_form': (invite_writer_form if
                                   len(invite_calls_writing) > 0 else None),
          })

    The template should look something like:

    {% if invite_reader_form %}
        <form method="post" action="{% url 'submitify:invite_reader' %}">
            {% csrf_token %}
            {{ invite_reader_form.user }}
            <div class="form-group">
                <label for="id_calls">Invite user as a reader to...</label>
                {{ invite_reader_form.calls }}
            </div>
        </form>
    {% endif %}
    {% if invite_writer_form %}
        <form method="post" action="{% url 'submitify:invite_writer' %}">
            {% csrf_token %}
            {{ invite_writer_form.user }}
            <div class="form-group">
                <label for="id_calls">Invite user as a writer to...</label>
                {{ invite_writer_form.calls }}
            </div>
        </form>
    {% endif %}

    See the standalone application for more information.

Further information

Source, issues, and further information:

GitHub

Author

The OpenFurry Contributors

Metadata

Release files for django-submitify 0.0.12

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-submitify 0.0.12
File Size Uploaded Provenance
django-submitify-0.0.12.tar.gz 29.2 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for django-submitify 0.0.12
File Interpreter ABI Platform
django_submitify-0.0.12-py3-none-any.whl Python 3 none any Details

Total release size: 81.1 kB

Release files / django-submitify-0.0.12.tar.gz

Download URL django-submitify-0.0.12.tar.gz
Size 29.2 kB
Tags Source
SHA-256 checksum
How to use checksums
77ee56fe763c9fe1b40b9e28d9e7e636889c4eb33d32947394c439bb0787931f
BLAKE2b-256 checksum
How to use checksums
9f227253d35d933451e8cf6e801ae6f24bc0a6690e09b5db41b34b9e57da272f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.3

Release files / django_submitify-0.0.12-py3-none-any.whl

Download URL django_submitify-0.0.12-py3-none-any.whl
Size 51.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
484a297b97ee3b030e92b43a6a9d83da2388ad802c6f7e54df01eaf85bf7a4de
BLAKE2b-256 checksum
How to use checksums
5ef3595c26568d627f0dc79942aea5a96d0f0011f509bde028fd8ed6f24fa5b9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.3

Security for django-submitify 0.0.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page