Skip to main content

A Python package to get weather reports for any location.

Project description

x-django-app

Django application for all my custom stuff

Features:

Models:

  • XActivity to store all user activities in the project
    CREATE
    EDIT
    DELETE
    RESET
    DOWNLOAD
    BACKUP
    RESTORE
    EXPORT
    IMPORT
    PUBLISH
    ACCEPT
    REJECT
    ENABLE
    DISABLE
    ACTIVATE
    DEACTIVATE

Views:

  • XListView for searching in selected fields

  • XCreateView to record create activity in XActivity model, also add created_by for the requested user

  • XUpdateView to record edit activity in XActivity model, also add edited_by for the requested user

  • x_record_delete_object function to record delete activity in XActivity model
    NOTE: x_record_delete_object is a function not a view used as
    x_record_delete_object(request, object, message)

Tags:

  • class_name return the class name for the object

  • detect_language return language code to the text

  • get_data change '' to "" for Jason use

  • to_string change number to string

  • trunc trnucate text for any selected length

  • make_clear replace all ' _ ' to ' '

  • permission_check check if user has specific permission regardless if user is superuser or not

  • x_sort sort model data with selected field

Install:

  • Install python > 3.8.8

  • Install using pip
    pip install x-django-app

  • Add "x_django_app" to your INSTALLED_APPS settings:

    INSTALLED_APPS = [
    ...
    'x_django_app',
    ]

Use:

  • For views
    from x_django_app.views import XListView, XCreateView, XUpdateView, x_record_delete_object

  • For tags
    {% load x_tags %}

  • For paginations
    {% include 'x_django_app/_pagination.html' %}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

x-django-app-1.2.2.tar.gz (11.0 kB view hashes)

Uploaded Source

Built Distribution

x_django_app-1.2.2-py3-none-any.whl (12.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page