This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from dateutil.relativedelta import relativedelta | |
from django.http.response import HttpResponse | |
from datetime import datetime | |
import requests | |
import re | |
from ipware.ip import get_real_ip |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import xlsxwriter | |
def main(): | |
""" | |
for exporting licenses in json file execute | |
pip-licenses --order=license --format=json > licenses.json | |
Note! pip-licenses must be installed in the environment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Regex below --> | |
<!-- [\$\{]([^}]+)\} --> | |
<body> | |
<p style="margin-top: 0; margin-bottom: 0;"><span style="font-family: 'Arial';">MODEL ADEVERINb ANGAJATOR</span></p> | |
<p> </p> | |
<p style="margin-top: 0; margin-bottom: 0;"><span style="font-family: 'Arial'; color: #000000;">Antetul unitc</span></p> | |
<p style="margin-top: 0; margin-bottom: 0;"><span style="font-family: 'Arial'; color: #000000;">ii (${Societa</span></p> | |
<p style="margin-top: 0; margin-bottom: 0;"><span style="font-family: 'Arial'; color: #000000;">te</span></p> | |
<p style="margin-top: 0; margin-bottom: 0;"><span style="font-family: 'Arial'; color: #000000;">a}, ${Adresa S</span></p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from django.conf import settings | |
from django_nose import NoseTestSuiteRunner | |
class MongoTestRunner(NoseTestSuiteRunner): | |
""" | |
A test runner that can be used to create, connect to, disconnect from, | |
and destroy a mongo test database for standard django testing. | |
Redefine TEST_RUNNER in settings |