|
@@ -21,8 +21,8 @@ class Test(unittest.TestCase):
|
|
|
name_string = r'[a-zA-Z0-9. ]*(?=\nRidewave SRL)'
|
|
|
value_string = r'(?<=otal \(RON\):\n)[a-zA-Z0-9.]*'
|
|
|
docn_string = r'(?<=Factura nr. )[a-zA-Z\n0-9-]*|(?<=Invoice no. )[a-zA-Z\n0-9-]*'
|
|
|
- note_string = r'(?<=Pornire: )[a-zA-Z \n,.\(\):0-9-]*|(?<=Start: )[a-zA-Z \n,.\(\):0-9-]*'
|
|
|
- date_string = r'(?<=Dată: )[0-9.]*|(?<=Date: )[0-9.]*'
|
|
|
+ note_string = r'(?<=Pornire: )[a-zA-Z \n,.\(\):0-9-]*|(?<=Start: )[a-zA-Z \n,.\(\):0-9-]*|(?<=Indítás: )[a-zA-Z \n,.\(\):0-9-]*'
|
|
|
+ date_string = r'(?<=Dată: )[0-9.]*|(?<=Date: )[0-9.]*|(?<=Dátum: )[0-9.]*|(?<=Date: )[0-9.]*'
|
|
|
|
|
|
def test_bolt_inv(self) -> None:
|
|
|
names = []
|
|
@@ -31,7 +31,7 @@ class Test(unittest.TestCase):
|
|
|
numbers = []
|
|
|
notes = []
|
|
|
dates = []
|
|
|
- for root, _dir, files in os.walk(r'f:\Gdrive\Misc\Dosar-Contabilitate\Ridewave\2024_04\e-Fact'):
|
|
|
+ for root, _dir, files in os.walk(r'f:\Gdrive\Misc\Dosar-Contabilitate\Ridewave\2024_01\e-Fact'):
|
|
|
for file in files:
|
|
|
if file.endswith('.pdf'):
|
|
|
with pymupdf.open(os.path.join(root, file)) as doc:
|
|
@@ -70,7 +70,7 @@ class Test(unittest.TestCase):
|
|
|
for date, name, code, value, number, note in zip(df['dates'], df['names'], df['codes'], df['values'], df['numbers'], df['notes']):
|
|
|
invoice = BoltSaleInvoice(doc_data=date, buyer_name=name, buyer_code=code, total_value=value, doc_number=number, doc_notes=note)
|
|
|
invoices.append(invoice)
|
|
|
- partner = Partner(vat_code=code, name=name)
|
|
|
+ partner = Partner(vat_code=code, name=None)
|
|
|
partners.append(partner)
|
|
|
data = {'AnLucru': datetime.date.today().year,
|
|
|
'LunaLucru': get_last_month(0),
|