Skip to main content

upnqr

README is also available in English

Python knjižnica za generiranje QR kod za Univerzalni Plačilni Nalog (UPN).

Specifikacija

Namestitev

pip install git+https://github.com/franga2000/upnqr.git#egg=upnqr

Uporaba

Priprava podatkov:

import upnqr

data = upnqr.Data(
 placnik = upnqr.Placnik(
        ime='Ime Plačnika',
        ulica='Plačnikova ulica 1',
        kraj='Kraj Plačnika'),
    prejemnik = upnqr.Prejemnik(
        ime='Ime Prejemnika',
        ulica='Prejemnikova ulica 1',
        kraj='Kraj Prejemnika',
        iban='SI56043020002997963'),
    znesek = 42.00,
    koda_namena = 'COST',
    namen_placila = 'Namen plačila',
    rok_placila = '2022-05-01',
    referenca = 'SI1212345678909'
)

qr = upnqr.make_from_data(data)

Izpis v različnih oblikah:

# V rastrski obliki (slika)
img = upnqr.to_pil(qr)
img.save('out.png')

# V vektorski obliki (SVG)
svg = upnqr.to_svg(qr)
with open('out.svg', 'w') as f:
    f.write(svg)

# V vektorski obliki (SVG path - za vstavljanje v obstoječ SVG)
path_spec = upnqr.to_svg_path(qr)
path_el = f'<path d="{path_spec}" fill="#000000"/>'

# V besedilni obliki (npr. za izpis v terminalu, uporablja Unicode simbole za bela polja)
txt = to_text(qr)
print(txt)

Download files

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

Source Distribution

upnqr-0.1.0.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

upnqr-0.1.0-py3-none-any.whl (17.1 kB view details)

Uploaded Python 3

File details

Details for the file upnqr-0.1.0.tar.gz.

File metadata

  • Download URL: upnqr-0.1.0.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for upnqr-0.1.0.tar.gz
Algorithm Hash digest
SHA256 0e699bc64f1373c6128952a748781071b0d7cba44ef264d7f9b6c6adc77fea26
MD5 8fb03088e85f2124cb8a7609f5d72cd4
BLAKE2b-256 6e7ae667530369c0816076612991042c5cd856932ffd06c8a715bff527201c59

See more details on using hashes here.

Provenance

The following attestation bundles were made for upnqr-0.1.0.tar.gz:

Publisher: pypi.yml on franga2000/upnqr

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file upnqr-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: upnqr-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 17.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for upnqr-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9195455178c8d72585e1bacc5bc5fafb4c76c43568c91e0cf119f69cb7428b48
MD5 90acbcfa00116e63c7eba5d50dd95bfa
BLAKE2b-256 8f7a9a9bf89f8995490bccc41c703dd5a928bc898fcb6ca8db84fa50b5723d2a

See more details on using hashes here.

Provenance

The following attestation bundles were made for upnqr-0.1.0-py3-none-any.whl:

Publisher: pypi.yml on franga2000/upnqr

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 files

Supported by

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