Skip to main content

NEMO Plugin - Transaction Validation

Project description

This NEMO plugin is inspired from the transaction validation features implemented by Penn State's LEO.

Description

This plugin allows staff members to validate and contest transactions performed on behalf of a customer. Once contests are reviewed and approved by an administrator, the plugin automatically revises the transaction according to the contest submission. The plugin also saves a copy of the original transaction data as a contest item for historical data.

A transaction can be validated if no contests are required. Else, if contests have been submitted for approval, then it can be validated once all contests are approved by the administrator.

Installation

  1. Install plugin.
pip install NEMO-transaction-validation
  1. Add the plugin to INSTALLED_APPS in your settings.py file.
INSTALLED_APPS = [
    ...
    'NEMO_transaction_validation', #must be placed before 'NEMO'
    'NEMO',
    ...
]
  1. Add the function auto_validate_transactions to the list of cron tasks. For this example, transactions at least five days old are checked and validated every 5 minutes.
sudo crontab -e

---> In the root crontab <---
...
*/5 * * * * /snap/bin/docker exec nemo django-admin auto_validate_transactions

N.B.: Ensure that there is a newline at the end of the crontab file

Let's breakdown the crontab line that was added:
*/5 * * * * Time and date fields
/snap/bin/docker Path to the docker executable file. You may omit this if the docker executable file has already been included in your PATH variable. Otherwise, you will need to provide the directory path to the executable file.
exec In the following container, execute the following command
nemo Name of the docker container
django-admin auto_validate_transactions Custom django-admin command

Changes

Version Description
0.2.11 Fixed bug where validation buttons were not working
0.2.10 Rerouted "remote work" menu to transaction validation page to avoid confusion
0.2.9 Fixed admin save_model function for ContestUsageEvent models
0.2.8 Fixed migration issues
0.2.6 Reverted changes from 0.2.5, except for template changes
0.2.5 Revised how date range from transaction validation page is initially handled
0.2.4 Revised cronjob command for all contest models
0.2.3 More fixes for migrations
0.2.1 Minor bug fix
0.2.0 - Added contests for Staff Charge
- Updated UI layout
0.1.1 Fixed bug for auto validating transactions 5 days prior
0.1.0 Cron job added by using system crontab instead of django packages
0.0.4 - Fixed plugin import error in cron function
- Added cron job function for auto validating transactions every 5 minutes
0.0.2 Fixed plugin imports
0.0.1 Initial

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

NEMO_transaction_validation-0.2.11.tar.gz (20.3 kB view details)

Uploaded Source

File details

Details for the file NEMO_transaction_validation-0.2.11.tar.gz.

File metadata

  • Download URL: NEMO_transaction_validation-0.2.11.tar.gz
  • Upload date:
  • Size: 20.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.10

File hashes

Hashes for NEMO_transaction_validation-0.2.11.tar.gz
Algorithm Hash digest
SHA256 b97840a5fb5e7948cea649f20f94556725185b996a6ae57e945bec82fd6221ae
MD5 65db69d30d2efc04e74c5f61d10f68bb
BLAKE2b-256 4733f04a1d6de0346fff06bc49969c6832b865a06b522f30347d549284c95be6

See more details on using hashes here.

Supported by

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