mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-01 19:29:10 +00:00
Merge branch 'version-14-hotfix' into mergify/bp/version-14-hotfix/pr-35397
This commit is contained in:
@@ -2,75 +2,13 @@
|
|||||||
"country_code": "nl",
|
"country_code": "nl",
|
||||||
"name": "Netherlands - Grootboekschema",
|
"name": "Netherlands - Grootboekschema",
|
||||||
"tree": {
|
"tree": {
|
||||||
"FABRIKAGEREKENINGEN": {
|
|
||||||
"is_group": 1,
|
|
||||||
"root_type": "Expense"
|
|
||||||
},
|
|
||||||
"FINANCIELE REKENINGEN, KORTLOPENDE VORDERINGEN EN SCHULDEN": {
|
"FINANCIELE REKENINGEN, KORTLOPENDE VORDERINGEN EN SCHULDEN": {
|
||||||
"Bank": {
|
"Bank": {
|
||||||
"RABO Bank": {
|
"RABO Bank": {
|
||||||
"account_type": "Bank"
|
"account_type": "Bank"
|
||||||
},
|
},
|
||||||
"account_type": "Bank"
|
"account_type": "Bank"
|
||||||
},
|
},
|
||||||
"KORTLOPENDE SCHULDEN": {
|
|
||||||
"Af te dragen Btw-verlegd": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Afdracht loonheffing": {},
|
|
||||||
"Btw af te dragen hoog": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Btw af te dragen laag": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Btw af te dragen overig": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Btw oude jaren": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Btw te vorderen hoog": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Btw te vorderen laag": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Btw te vorderen overig": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Btw-afdracht": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Crediteuren": {
|
|
||||||
"account_type": "Payable"
|
|
||||||
},
|
|
||||||
"Dividend": {},
|
|
||||||
"Dividendbelasting": {},
|
|
||||||
"Energiekosten 1": {},
|
|
||||||
"Investeringsaftrek": {},
|
|
||||||
"Loonheffing": {},
|
|
||||||
"Overige te betalen posten": {},
|
|
||||||
"Pensioenpremies 1": {},
|
|
||||||
"Premie WIR": {},
|
|
||||||
"Rekening-courant inkoopvereniging": {},
|
|
||||||
"Rente": {},
|
|
||||||
"Sociale lasten 1": {},
|
|
||||||
"Stock Recieved niet gefactureerd": {
|
|
||||||
"account_type": "Stock Received But Not Billed"
|
|
||||||
},
|
|
||||||
"Tanti\u00e8mes 1": {},
|
|
||||||
"Te vorderen Btw-verlegd": {
|
|
||||||
"account_type": "Tax"
|
|
||||||
},
|
|
||||||
"Telefoon/telefax 1": {},
|
|
||||||
"Termijnen onderh. werk": {},
|
|
||||||
"Vakantiedagen": {},
|
|
||||||
"Vakantiegeld 1": {},
|
|
||||||
"Vakantiezegels": {},
|
|
||||||
"Vennootschapsbelasting": {},
|
|
||||||
"Vooruit ontvangen bedr.": {}
|
|
||||||
},
|
|
||||||
"LIQUIDE MIDDELEN": {
|
"LIQUIDE MIDDELEN": {
|
||||||
"ABN-AMRO bank": {},
|
"ABN-AMRO bank": {},
|
||||||
"Bankbetaalkaarten": {},
|
"Bankbetaalkaarten": {},
|
||||||
@@ -91,6 +29,110 @@
|
|||||||
},
|
},
|
||||||
"account_type": "Cash"
|
"account_type": "Cash"
|
||||||
},
|
},
|
||||||
|
"TUSSENREKENINGEN": {
|
||||||
|
"Betaalwijze cadeaubonnen": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Betaalwijze chipknip": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Betaalwijze contant": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Betaalwijze pin": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen Nederland hoog": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen Nederland laag": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen Nederland onbelast": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen Nederland overig": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen Nederland verlegd": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen binnen EU hoog": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen binnen EU laag": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen binnen EU overig": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen buiten EU hoog": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen buiten EU laag": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Inkopen buiten EU overig": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Kassa 1": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Kassa 2": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Netto lonen": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tegenrekening Inkopen": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tussenrek. autom. betalingen": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tussenrek. autom. loonbetalingen": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tussenrek. cadeaubonbetalingen": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tussenrekening balans": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tussenrekening chipknip": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tussenrekening correcties": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Tussenrekening pin": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"Vraagposten": {
|
||||||
|
"account_type": "Cash"
|
||||||
|
},
|
||||||
|
"VOORRAAD GRONDSTOFFEN, HULPMATERIALEN EN HANDELSGOEDEREN": {
|
||||||
|
"Emballage": {},
|
||||||
|
"Gereed product 1": {},
|
||||||
|
"Gereed product 2": {},
|
||||||
|
"Goederen 1": {},
|
||||||
|
"Goederen 2": {},
|
||||||
|
"Goederen in consignatie": {},
|
||||||
|
"Goederen onderweg": {},
|
||||||
|
"Grondstoffen 1": {},
|
||||||
|
"Grondstoffen 2": {},
|
||||||
|
"Halffabrikaten 1": {},
|
||||||
|
"Halffabrikaten 2": {},
|
||||||
|
"Hulpstoffen 1": {},
|
||||||
|
"Hulpstoffen 2": {},
|
||||||
|
"Kantoorbenodigdheden": {},
|
||||||
|
"Onderhanden werk": {},
|
||||||
|
"Verpakkingsmateriaal": {},
|
||||||
|
"Zegels": {},
|
||||||
|
"root_type": "Asset"
|
||||||
|
},
|
||||||
|
"root_type": "Asset"
|
||||||
|
},
|
||||||
"VORDERINGEN": {
|
"VORDERINGEN": {
|
||||||
"Debiteuren": {
|
"Debiteuren": {
|
||||||
"account_type": "Receivable"
|
"account_type": "Receivable"
|
||||||
@@ -104,278 +146,299 @@
|
|||||||
"Voorziening dubieuze debiteuren": {}
|
"Voorziening dubieuze debiteuren": {}
|
||||||
},
|
},
|
||||||
"root_type": "Asset"
|
"root_type": "Asset"
|
||||||
},
|
},
|
||||||
"INDIRECTE KOSTEN": {
|
"KORTLOPENDE SCHULDEN": {
|
||||||
|
"Af te dragen Btw-verlegd": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Afdracht loonheffing": {},
|
||||||
|
"Btw af te dragen hoog": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Btw af te dragen laag": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Btw af te dragen overig": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Btw oude jaren": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Btw te vorderen hoog": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Btw te vorderen laag": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Btw te vorderen overig": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Btw-afdracht": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Crediteuren": {
|
||||||
|
"account_type": "Payable"
|
||||||
|
},
|
||||||
|
"Dividend": {},
|
||||||
|
"Dividendbelasting": {},
|
||||||
|
"Energiekosten 1": {},
|
||||||
|
"Investeringsaftrek": {},
|
||||||
|
"Loonheffing": {},
|
||||||
|
"Overige te betalen posten": {},
|
||||||
|
"Pensioenpremies 1": {},
|
||||||
|
"Premie WIR": {},
|
||||||
|
"Rekening-courant inkoopvereniging": {},
|
||||||
|
"Rente": {},
|
||||||
|
"Sociale lasten 1": {},
|
||||||
|
"Stock Recieved niet gefactureerd": {
|
||||||
|
"account_type": "Stock Received But Not Billed"
|
||||||
|
},
|
||||||
|
"Tanti\u00e8mes 1": {},
|
||||||
|
"Te vorderen Btw-verlegd": {
|
||||||
|
"account_type": "Tax"
|
||||||
|
},
|
||||||
|
"Telefoon/telefax 1": {},
|
||||||
|
"Termijnen onderh. werk": {},
|
||||||
|
"Vakantiedagen": {},
|
||||||
|
"Vakantiegeld 1": {},
|
||||||
|
"Vakantiezegels": {},
|
||||||
|
"Vennootschapsbelasting": {},
|
||||||
|
"Vooruit ontvangen bedr.": {},
|
||||||
|
"is_group": 1,
|
||||||
|
"root_type": "Liability"
|
||||||
|
},
|
||||||
|
"FABRIKAGEREKENINGEN": {
|
||||||
"is_group": 1,
|
"is_group": 1,
|
||||||
"root_type": "Expense"
|
"root_type": "Expense",
|
||||||
},
|
"INDIRECTE KOSTEN": {
|
||||||
"KOSTENREKENINGEN": {
|
"is_group": 1,
|
||||||
"AFSCHRIJVINGEN": {
|
"root_type": "Expense"
|
||||||
"Aanhangwagens": {},
|
},
|
||||||
"Aankoopkosten": {},
|
"KOSTENREKENINGEN": {
|
||||||
"Aanloopkosten": {},
|
"AFSCHRIJVINGEN": {
|
||||||
"Auteursrechten": {},
|
"Aanhangwagens": {},
|
||||||
"Bedrijfsgebouwen": {},
|
"Aankoopkosten": {},
|
||||||
"Bedrijfsinventaris": {
|
"Aanloopkosten": {},
|
||||||
|
"Auteursrechten": {},
|
||||||
|
"Bedrijfsgebouwen": {},
|
||||||
|
"Bedrijfsinventaris": {
|
||||||
|
"account_type": "Depreciation"
|
||||||
|
},
|
||||||
|
"Drankvergunningen": {},
|
||||||
|
"Fabrieksinventaris": {
|
||||||
|
"account_type": "Depreciation"
|
||||||
|
},
|
||||||
|
"Gebouwen": {},
|
||||||
|
"Gereedschappen": {},
|
||||||
|
"Goodwill": {},
|
||||||
|
"Grondverbetering": {},
|
||||||
|
"Heftrucks": {},
|
||||||
|
"Kantine-inventaris": {},
|
||||||
|
"Kantoorinventaris": {
|
||||||
|
"account_type": "Depreciation"
|
||||||
|
},
|
||||||
|
"Kantoormachines": {},
|
||||||
|
"Licenties": {},
|
||||||
|
"Machines 1": {},
|
||||||
|
"Magazijninventaris": {},
|
||||||
|
"Octrooien": {},
|
||||||
|
"Ontwikkelingskosten": {},
|
||||||
|
"Pachtersinvestering": {},
|
||||||
|
"Parkeerplaats": {},
|
||||||
|
"Personenauto's": {
|
||||||
|
"account_type": "Depreciation"
|
||||||
|
},
|
||||||
|
"Rijwielen en bromfietsen": {},
|
||||||
|
"Tonnagevergunningen": {},
|
||||||
|
"Verbouwingen": {},
|
||||||
|
"Vergunningen": {},
|
||||||
|
"Voorraadverschillen": {},
|
||||||
|
"Vrachtauto's": {},
|
||||||
|
"Winkels": {},
|
||||||
|
"Woon-winkelhuis": {},
|
||||||
"account_type": "Depreciation"
|
"account_type": "Depreciation"
|
||||||
},
|
},
|
||||||
"Drankvergunningen": {},
|
"ALGEMENE KOSTEN": {
|
||||||
"Fabrieksinventaris": {
|
"Accountantskosten": {},
|
||||||
"account_type": "Depreciation"
|
"Advieskosten": {},
|
||||||
|
"Assuranties 1": {},
|
||||||
|
"Bankkosten": {},
|
||||||
|
"Juridische kosten": {},
|
||||||
|
"Overige algemene kosten": {},
|
||||||
|
"Toev. Ass. eigen risico": {}
|
||||||
},
|
},
|
||||||
"Gebouwen": {},
|
"BEDRIJFSKOSTEN": {
|
||||||
"Gereedschappen": {},
|
"Assuranties 2": {},
|
||||||
"Goodwill": {},
|
"Energie (krachtstroom)": {},
|
||||||
"Grondverbetering": {},
|
"Gereedschappen 1": {},
|
||||||
"Heftrucks": {},
|
"Hulpmaterialen 1": {},
|
||||||
"Kantine-inventaris": {},
|
"Huur inventaris": {},
|
||||||
"Kantoorinventaris": {
|
"Huur machines": {},
|
||||||
"account_type": "Depreciation"
|
"Leasing invent.operational": {},
|
||||||
|
"Leasing mach. operational": {},
|
||||||
|
"Onderhoud inventaris": {},
|
||||||
|
"Onderhoud machines": {},
|
||||||
|
"Ophalen/vervoer afval": {},
|
||||||
|
"Overige bedrijfskosten": {}
|
||||||
},
|
},
|
||||||
"Kantoormachines": {},
|
"FINANCIERINGSKOSTEN 1": {
|
||||||
"Licenties": {},
|
"Overige rentebaten": {},
|
||||||
"Machines 1": {},
|
"Overige rentelasten": {},
|
||||||
"Magazijninventaris": {},
|
"Rente bankkrediet": {},
|
||||||
"Octrooien": {},
|
"Rente huurkoopcontracten": {},
|
||||||
"Ontwikkelingskosten": {},
|
"Rente hypotheek": {},
|
||||||
"Pachtersinvestering": {},
|
"Rente leasecontracten": {},
|
||||||
"Parkeerplaats": {},
|
"Rente lening o/g": {},
|
||||||
"Personenauto's": {
|
"Rente lening u/g": {}
|
||||||
"account_type": "Depreciation"
|
|
||||||
},
|
},
|
||||||
"Rijwielen en bromfietsen": {},
|
"HUISVESTINGSKOSTEN": {
|
||||||
"Tonnagevergunningen": {},
|
"Assurantie onroerend goed": {},
|
||||||
"Verbouwingen": {},
|
"Belastingen onr. Goed": {},
|
||||||
"Vergunningen": {},
|
"Energiekosten": {},
|
||||||
"Voorraadverschillen": {},
|
"Groot onderhoud onr. Goed": {},
|
||||||
"Vrachtauto's": {},
|
"Huur": {},
|
||||||
"Winkels": {},
|
"Huurwaarde woongedeelte": {},
|
||||||
"Woon-winkelhuis": {},
|
"Onderhoud onroerend goed": {},
|
||||||
"account_type": "Depreciation"
|
"Ontvangen huren": {},
|
||||||
},
|
"Overige huisvestingskosten": {},
|
||||||
"ALGEMENE KOSTEN": {
|
"Pacht": {},
|
||||||
"Accountantskosten": {},
|
"Schoonmaakkosten": {},
|
||||||
"Advieskosten": {},
|
"Toevoeging egalisatieres. Groot onderhoud": {}
|
||||||
"Assuranties 1": {},
|
},
|
||||||
"Bankkosten": {},
|
"KANTOORKOSTEN": {
|
||||||
"Juridische kosten": {},
|
"Administratiekosten": {},
|
||||||
"Overige algemene kosten": {},
|
"Contributies/abonnementen": {},
|
||||||
"Toev. Ass. eigen risico": {}
|
"Huur kantoorapparatuur": {},
|
||||||
},
|
"Internetaansluiting": {},
|
||||||
"BEDRIJFSKOSTEN": {
|
"Kantoorbenodigdh./drukw.": {},
|
||||||
"Assuranties 2": {},
|
"Onderhoud kantoorinvent.": {},
|
||||||
"Energie (krachtstroom)": {},
|
"Overige kantoorkosten": {},
|
||||||
"Gereedschappen 1": {},
|
"Porti": {},
|
||||||
"Hulpmaterialen 1": {},
|
"Telefoon/telefax": {}
|
||||||
"Huur inventaris": {},
|
},
|
||||||
"Huur machines": {},
|
"OVERIGE BATEN EN LASTEN": {
|
||||||
"Leasing invent.operational": {},
|
"Betaalde schadevergoed.": {},
|
||||||
"Leasing mach. operational": {},
|
"Boekverlies vaste activa": {},
|
||||||
"Onderhoud inventaris": {},
|
"Boekwinst van vaste activa": {},
|
||||||
"Onderhoud machines": {},
|
"K.O. regeling OB": {},
|
||||||
"Ophalen/vervoer afval": {},
|
"Kasverschillen": {},
|
||||||
"Overige bedrijfskosten": {}
|
"Kosten loonbelasting": {},
|
||||||
},
|
"Kosten omzetbelasting": {},
|
||||||
"FINANCIERINGSKOSTEN 1": {
|
"Nadelige koersverschillen": {},
|
||||||
"Overige rentebaten": {},
|
"Naheffing bedrijfsver.": {},
|
||||||
"Overige rentelasten": {},
|
"Ontvangen schadevergoed.": {},
|
||||||
"Rente bankkrediet": {},
|
"Overige baten": {},
|
||||||
"Rente huurkoopcontracten": {},
|
"Overige lasten": {},
|
||||||
"Rente hypotheek": {},
|
"Voordelige koersverschil.": {}
|
||||||
"Rente leasecontracten": {},
|
},
|
||||||
"Rente lening o/g": {},
|
"PERSONEELSKOSTEN": {
|
||||||
"Rente lening u/g": {}
|
"Autokostenvergoeding": {},
|
||||||
},
|
"Bedrijfskleding": {},
|
||||||
"HUISVESTINGSKOSTEN": {
|
"Belastingvrije uitkeringen": {},
|
||||||
"Assurantie onroerend goed": {},
|
"Bijzondere beloningen": {},
|
||||||
"Belastingen onr. Goed": {},
|
"Congressen, seminars en symposia": {},
|
||||||
"Energiekosten": {},
|
"Gereedschapsgeld": {},
|
||||||
"Groot onderhoud onr. Goed": {},
|
"Geschenken personeel": {},
|
||||||
"Huur": {},
|
"Gratificaties": {},
|
||||||
"Huurwaarde woongedeelte": {},
|
"Inhouding pensioenpremies": {},
|
||||||
"Onderhoud onroerend goed": {},
|
"Inhouding sociale lasten": {},
|
||||||
"Ontvangen huren": {},
|
"Kantinekosten": {},
|
||||||
"Overige huisvestingskosten": {},
|
"Lonen en salarissen": {},
|
||||||
"Pacht": {},
|
"Loonwerk": {},
|
||||||
"Schoonmaakkosten": {},
|
"Managementvergoedingen": {},
|
||||||
"Toevoeging egalisatieres. Groot onderhoud": {}
|
"Opleidingskosten": {},
|
||||||
},
|
"Oprenting stamrechtverpl.": {},
|
||||||
"KANTOORKOSTEN": {
|
"Overhevelingstoeslag": {},
|
||||||
"Administratiekosten": {},
|
"Overige kostenverg.": {},
|
||||||
"Contributies/abonnementen": {},
|
"Overige personeelskosten": {},
|
||||||
"Huur kantoorapparatuur": {},
|
"Overige uitkeringen": {},
|
||||||
"Internetaansluiting": {},
|
"Pensioenpremies": {},
|
||||||
"Kantoorbenodigdh./drukw.": {},
|
"Provisie 1": {},
|
||||||
"Onderhoud kantoorinvent.": {},
|
"Reiskosten": {},
|
||||||
"Overige kantoorkosten": {},
|
"Rijwielvergoeding": {},
|
||||||
"Porti": {},
|
"Sociale lasten": {},
|
||||||
"Telefoon/telefax": {}
|
"Tanti\u00e8mes": {},
|
||||||
},
|
"Thuiswerkers": {},
|
||||||
"OVERIGE BATEN EN LASTEN": {
|
"Toev. Backservice pens.verpl.": {},
|
||||||
"Betaalde schadevergoed.": {},
|
"Toevoeging pensioenverpl.": {},
|
||||||
"Boekverlies vaste activa": {},
|
"Uitkering ziekengeld": {},
|
||||||
"Boekwinst van vaste activa": {},
|
"Uitzendkrachten": {},
|
||||||
"K.O. regeling OB": {},
|
"Vakantiebonnen": {},
|
||||||
"Kasverschillen": {},
|
"Vakantiegeld": {},
|
||||||
"Kosten loonbelasting": {},
|
"Vergoeding studiekosten": {},
|
||||||
"Kosten omzetbelasting": {},
|
"Wervingskosten personeel": {}
|
||||||
"Nadelige koersverschillen": {},
|
},
|
||||||
"Naheffing bedrijfsver.": {},
|
"VERKOOPKOSTEN": {
|
||||||
"Ontvangen schadevergoed.": {},
|
"Advertenties": {},
|
||||||
"Overige baten": {},
|
"Afschrijving dubieuze deb.": {},
|
||||||
"Overige lasten": {},
|
"Beurskosten": {},
|
||||||
"Voordelige koersverschil.": {}
|
"Etalagekosten": {},
|
||||||
},
|
"Exportkosten": {},
|
||||||
"PERSONEELSKOSTEN": {
|
"Kascorrecties": {},
|
||||||
"Autokostenvergoeding": {},
|
"Overige verkoopkosten": {},
|
||||||
"Bedrijfskleding": {},
|
"Provisie": {},
|
||||||
"Belastingvrije uitkeringen": {},
|
"Reclame": {},
|
||||||
"Bijzondere beloningen": {},
|
"Reis en verblijfkosten": {},
|
||||||
"Congressen, seminars en symposia": {},
|
"Relatiegeschenken": {},
|
||||||
"Gereedschapsgeld": {},
|
"Representatiekosten": {},
|
||||||
"Geschenken personeel": {},
|
"Uitgaande vrachten": {},
|
||||||
"Gratificaties": {},
|
"Veilingkosten": {},
|
||||||
"Inhouding pensioenpremies": {},
|
"Verpakkingsmateriaal 1": {},
|
||||||
"Inhouding sociale lasten": {},
|
"Websitekosten": {}
|
||||||
"Kantinekosten": {},
|
},
|
||||||
"Lonen en salarissen": {},
|
"VERVOERSKOSTEN": {
|
||||||
"Loonwerk": {},
|
"Assuranties auto's": {},
|
||||||
"Managementvergoedingen": {},
|
"Brandstoffen": {},
|
||||||
"Opleidingskosten": {},
|
"Leasing auto's": {},
|
||||||
"Oprenting stamrechtverpl.": {},
|
"Onderhoud personenauto's": {},
|
||||||
"Overhevelingstoeslag": {},
|
"Onderhoud vrachtauto's": {},
|
||||||
"Overige kostenverg.": {},
|
"Overige vervoerskosten": {},
|
||||||
"Overige personeelskosten": {},
|
"Priv\u00e9-gebruik auto's": {},
|
||||||
"Overige uitkeringen": {},
|
"Wegenbelasting": {}
|
||||||
"Pensioenpremies": {},
|
},
|
||||||
"Provisie 1": {},
|
"VOORRAAD GEREED PRODUCT EN ONDERHANDEN WERK": {
|
||||||
"Reiskosten": {},
|
"Betalingskort. crediteuren": {},
|
||||||
"Rijwielvergoeding": {},
|
"Garantiekosten": {},
|
||||||
"Sociale lasten": {},
|
"Hulpmaterialen": {},
|
||||||
"Tanti\u00e8mes": {},
|
"Inkomende vrachten": {
|
||||||
"Thuiswerkers": {},
|
"account_type": "Expenses Included In Valuation"
|
||||||
"Toev. Backservice pens.verpl.": {},
|
},
|
||||||
"Toevoeging pensioenverpl.": {},
|
"Inkoop import buiten EU hoog": {},
|
||||||
"Uitkering ziekengeld": {},
|
"Inkoop import buiten EU laag": {},
|
||||||
"Uitzendkrachten": {},
|
"Inkoop import buiten EU overig": {},
|
||||||
"Vakantiebonnen": {},
|
"Inkoopbonussen": {},
|
||||||
"Vakantiegeld": {},
|
"Inkoopkosten": {},
|
||||||
"Vergoeding studiekosten": {},
|
"Inkoopprovisie": {},
|
||||||
"Wervingskosten personeel": {}
|
"Inkopen BTW verlegd": {},
|
||||||
},
|
"Inkopen EU hoog tarief": {},
|
||||||
"VERKOOPKOSTEN": {
|
"Inkopen EU laag tarief": {},
|
||||||
"Advertenties": {},
|
"Inkopen EU overig": {},
|
||||||
"Afschrijving dubieuze deb.": {},
|
"Inkopen hoog": {},
|
||||||
"Beurskosten": {},
|
"Inkopen laag": {},
|
||||||
"Etalagekosten": {},
|
"Inkopen nul": {},
|
||||||
"Exportkosten": {},
|
"Inkopen overig": {},
|
||||||
"Kascorrecties": {},
|
"Invoerkosten": {},
|
||||||
"Overige verkoopkosten": {},
|
"Kosten inkoopvereniging": {},
|
||||||
"Provisie": {},
|
"Kostprijs omzet grondstoffen": {
|
||||||
"Reclame": {},
|
"account_type": "Cost of Goods Sold"
|
||||||
"Reis en verblijfkosten": {},
|
},
|
||||||
"Relatiegeschenken": {},
|
"Kostprijs omzet handelsgoederen": {},
|
||||||
"Representatiekosten": {},
|
"Onttrekking uitgev.garantie": {},
|
||||||
"Uitgaande vrachten": {},
|
"Priv\u00e9-gebruik goederen": {},
|
||||||
"Veilingkosten": {},
|
"Stock aanpassing": {
|
||||||
"Verpakkingsmateriaal 1": {},
|
"account_type": "Stock Adjustment"
|
||||||
"Websitekosten": {}
|
},
|
||||||
},
|
"Tegenrekening inkoop": {},
|
||||||
"VERVOERSKOSTEN": {
|
"Toev. Voorz. incour. grondst.": {},
|
||||||
"Assuranties auto's": {},
|
"Toevoeging garantieverpl.": {},
|
||||||
"Brandstoffen": {},
|
"Toevoeging voorz. incour. handelsgoed.": {},
|
||||||
"Leasing auto's": {},
|
"Uitbesteed werk": {},
|
||||||
"Onderhoud personenauto's": {},
|
"Voorz. Incourourant grondst.": {},
|
||||||
"Onderhoud vrachtauto's": {},
|
"Voorz.incour. handelsgoed.": {},
|
||||||
"Overige vervoerskosten": {},
|
"root_type": "Expense"
|
||||||
"Priv\u00e9-gebruik auto's": {},
|
},
|
||||||
"Wegenbelasting": {}
|
"root_type": "Expense"
|
||||||
},
|
}
|
||||||
"root_type": "Expense"
|
|
||||||
},
|
|
||||||
"TUSSENREKENINGEN": {
|
|
||||||
"Betaalwijze cadeaubonnen": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Betaalwijze chipknip": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Betaalwijze contant": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Betaalwijze pin": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen Nederland hoog": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen Nederland laag": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen Nederland onbelast": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen Nederland overig": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen Nederland verlegd": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen binnen EU hoog": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen binnen EU laag": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen binnen EU overig": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen buiten EU hoog": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen buiten EU laag": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Inkopen buiten EU overig": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Kassa 1": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Kassa 2": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Netto lonen": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tegenrekening Inkopen": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tussenrek. autom. betalingen": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tussenrek. autom. loonbetalingen": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tussenrek. cadeaubonbetalingen": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tussenrekening balans": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tussenrekening chipknip": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tussenrekening correcties": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Tussenrekening pin": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"Vraagposten": {
|
|
||||||
"account_type": "Cash"
|
|
||||||
},
|
|
||||||
"root_type": "Asset"
|
|
||||||
},
|
},
|
||||||
"VASTE ACTIVA, EIGEN VERMOGEN, LANGLOPEND VREEMD VERMOGEN EN VOORZIENINGEN": {
|
"VASTE ACTIVA, EIGEN VERMOGEN, LANGLOPEND VREEMD VERMOGEN EN VOORZIENINGEN": {
|
||||||
"EIGEN VERMOGEN": {
|
"EIGEN VERMOGEN": {
|
||||||
@@ -602,7 +665,7 @@
|
|||||||
"account_type": "Equity"
|
"account_type": "Equity"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root_type": "Asset"
|
"root_type": "Equity"
|
||||||
},
|
},
|
||||||
"VERKOOPRESULTATEN": {
|
"VERKOOPRESULTATEN": {
|
||||||
"Diensten fabric. 0% niet-EU": {},
|
"Diensten fabric. 0% niet-EU": {},
|
||||||
@@ -627,67 +690,6 @@
|
|||||||
"Verleende Kredietbep. fabricage": {},
|
"Verleende Kredietbep. fabricage": {},
|
||||||
"Verleende Kredietbep. handel": {},
|
"Verleende Kredietbep. handel": {},
|
||||||
"root_type": "Income"
|
"root_type": "Income"
|
||||||
},
|
|
||||||
"VOORRAAD GEREED PRODUCT EN ONDERHANDEN WERK": {
|
|
||||||
"Betalingskort. crediteuren": {},
|
|
||||||
"Garantiekosten": {},
|
|
||||||
"Hulpmaterialen": {},
|
|
||||||
"Inkomende vrachten": {
|
|
||||||
"account_type": "Expenses Included In Valuation"
|
|
||||||
},
|
|
||||||
"Inkoop import buiten EU hoog": {},
|
|
||||||
"Inkoop import buiten EU laag": {},
|
|
||||||
"Inkoop import buiten EU overig": {},
|
|
||||||
"Inkoopbonussen": {},
|
|
||||||
"Inkoopkosten": {},
|
|
||||||
"Inkoopprovisie": {},
|
|
||||||
"Inkopen BTW verlegd": {},
|
|
||||||
"Inkopen EU hoog tarief": {},
|
|
||||||
"Inkopen EU laag tarief": {},
|
|
||||||
"Inkopen EU overig": {},
|
|
||||||
"Inkopen hoog": {},
|
|
||||||
"Inkopen laag": {},
|
|
||||||
"Inkopen nul": {},
|
|
||||||
"Inkopen overig": {},
|
|
||||||
"Invoerkosten": {},
|
|
||||||
"Kosten inkoopvereniging": {},
|
|
||||||
"Kostprijs omzet grondstoffen": {
|
|
||||||
"account_type": "Cost of Goods Sold"
|
|
||||||
},
|
|
||||||
"Kostprijs omzet handelsgoederen": {},
|
|
||||||
"Onttrekking uitgev.garantie": {},
|
|
||||||
"Priv\u00e9-gebruik goederen": {},
|
|
||||||
"Stock aanpassing": {
|
|
||||||
"account_type": "Stock Adjustment"
|
|
||||||
},
|
|
||||||
"Tegenrekening inkoop": {},
|
|
||||||
"Toev. Voorz. incour. grondst.": {},
|
|
||||||
"Toevoeging garantieverpl.": {},
|
|
||||||
"Toevoeging voorz. incour. handelsgoed.": {},
|
|
||||||
"Uitbesteed werk": {},
|
|
||||||
"Voorz. Incourourant grondst.": {},
|
|
||||||
"Voorz.incour. handelsgoed.": {},
|
|
||||||
"root_type": "Expense"
|
|
||||||
},
|
|
||||||
"VOORRAAD GRONDSTOFFEN, HULPMATERIALEN EN HANDELSGOEDEREN": {
|
|
||||||
"Emballage": {},
|
|
||||||
"Gereed product 1": {},
|
|
||||||
"Gereed product 2": {},
|
|
||||||
"Goederen 1": {},
|
|
||||||
"Goederen 2": {},
|
|
||||||
"Goederen in consignatie": {},
|
|
||||||
"Goederen onderweg": {},
|
|
||||||
"Grondstoffen 1": {},
|
|
||||||
"Grondstoffen 2": {},
|
|
||||||
"Halffabrikaten 1": {},
|
|
||||||
"Halffabrikaten 2": {},
|
|
||||||
"Hulpstoffen 1": {},
|
|
||||||
"Hulpstoffen 2": {},
|
|
||||||
"Kantoorbenodigdheden": {},
|
|
||||||
"Onderhanden werk": {},
|
|
||||||
"Verpakkingsmateriaal": {},
|
|
||||||
"Zegels": {},
|
|
||||||
"root_type": "Asset"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -194,7 +194,7 @@ class PaymentEntry(AccountsController):
|
|||||||
# The reference has already been partly paid
|
# The reference has already been partly paid
|
||||||
elif (
|
elif (
|
||||||
latest.outstanding_amount < latest.invoice_amount
|
latest.outstanding_amount < latest.invoice_amount
|
||||||
and d.outstanding_amount != latest.outstanding_amount
|
and flt(d.outstanding_amount, d.precision("outstanding_amount")) != latest.outstanding_amount
|
||||||
):
|
):
|
||||||
frappe.throw(
|
frappe.throw(
|
||||||
_(
|
_(
|
||||||
|
|||||||
@@ -152,5 +152,5 @@ def get_entries(filters):
|
|||||||
|
|
||||||
return sorted(
|
return sorted(
|
||||||
journal_entries + payment_entries + loan_disbursements + loan_repayments,
|
journal_entries + payment_entries + loan_disbursements + loan_repayments,
|
||||||
key=lambda k: k[2] or getdate(nowdate()),
|
key=lambda k: k[2].strftime("%H%M%S") or getdate(nowdate()),
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -15,20 +15,21 @@ from erpnext.accounts.report.item_wise_sales_register.item_wise_sales_register i
|
|||||||
get_group_by_conditions,
|
get_group_by_conditions,
|
||||||
get_tax_accounts,
|
get_tax_accounts,
|
||||||
)
|
)
|
||||||
|
from erpnext.accounts.report.utils import get_query_columns, get_values_for_columns
|
||||||
|
|
||||||
|
|
||||||
def execute(filters=None):
|
def execute(filters=None):
|
||||||
return _execute(filters)
|
return _execute(filters)
|
||||||
|
|
||||||
|
|
||||||
def _execute(filters=None, additional_table_columns=None, additional_query_columns=None):
|
def _execute(filters=None, additional_table_columns=None):
|
||||||
if not filters:
|
if not filters:
|
||||||
filters = {}
|
filters = {}
|
||||||
columns = get_columns(additional_table_columns, filters)
|
columns = get_columns(additional_table_columns, filters)
|
||||||
|
|
||||||
company_currency = erpnext.get_company_currency(filters.company)
|
company_currency = erpnext.get_company_currency(filters.company)
|
||||||
|
|
||||||
item_list = get_items(filters, additional_query_columns)
|
item_list = get_items(filters, get_query_columns(additional_table_columns))
|
||||||
aii_account_map = get_aii_accounts()
|
aii_account_map = get_aii_accounts()
|
||||||
if item_list:
|
if item_list:
|
||||||
itemised_tax, tax_columns = get_tax_accounts(
|
itemised_tax, tax_columns = get_tax_accounts(
|
||||||
@@ -79,28 +80,20 @@ def _execute(filters=None, additional_table_columns=None, additional_query_colum
|
|||||||
"posting_date": d.posting_date,
|
"posting_date": d.posting_date,
|
||||||
"supplier": d.supplier,
|
"supplier": d.supplier,
|
||||||
"supplier_name": d.supplier_name,
|
"supplier_name": d.supplier_name,
|
||||||
|
**get_values_for_columns(additional_table_columns, d),
|
||||||
|
"credit_to": d.credit_to,
|
||||||
|
"mode_of_payment": d.mode_of_payment,
|
||||||
|
"project": d.project,
|
||||||
|
"company": d.company,
|
||||||
|
"purchase_order": d.purchase_order,
|
||||||
|
"purchase_receipt": purchase_receipt,
|
||||||
|
"expense_account": expense_account,
|
||||||
|
"stock_qty": d.stock_qty,
|
||||||
|
"stock_uom": d.stock_uom,
|
||||||
|
"rate": d.base_net_amount / d.stock_qty if d.stock_qty else d.base_net_amount,
|
||||||
|
"amount": d.base_net_amount,
|
||||||
}
|
}
|
||||||
|
|
||||||
if additional_query_columns:
|
|
||||||
for col in additional_query_columns:
|
|
||||||
row.update({col: d.get(col)})
|
|
||||||
|
|
||||||
row.update(
|
|
||||||
{
|
|
||||||
"credit_to": d.credit_to,
|
|
||||||
"mode_of_payment": d.mode_of_payment,
|
|
||||||
"project": d.project,
|
|
||||||
"company": d.company,
|
|
||||||
"purchase_order": d.purchase_order,
|
|
||||||
"purchase_receipt": purchase_receipt,
|
|
||||||
"expense_account": expense_account,
|
|
||||||
"stock_qty": d.stock_qty,
|
|
||||||
"stock_uom": d.stock_uom,
|
|
||||||
"rate": d.base_net_amount / d.stock_qty if d.stock_qty else d.base_net_amount,
|
|
||||||
"amount": d.base_net_amount,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
total_tax = 0
|
total_tax = 0
|
||||||
for tax in tax_columns:
|
for tax in tax_columns:
|
||||||
item_tax = itemised_tax.get(d.name, {}).get(tax, {})
|
item_tax = itemised_tax.get(d.name, {}).get(tax, {})
|
||||||
@@ -317,11 +310,6 @@ def get_conditions(filters):
|
|||||||
def get_items(filters, additional_query_columns):
|
def get_items(filters, additional_query_columns):
|
||||||
conditions = get_conditions(filters)
|
conditions = get_conditions(filters)
|
||||||
|
|
||||||
if additional_query_columns:
|
|
||||||
additional_query_columns = ", " + ", ".join(additional_query_columns)
|
|
||||||
else:
|
|
||||||
additional_query_columns = ""
|
|
||||||
|
|
||||||
return frappe.db.sql(
|
return frappe.db.sql(
|
||||||
"""
|
"""
|
||||||
select
|
select
|
||||||
@@ -340,11 +328,10 @@ def get_items(filters, additional_query_columns):
|
|||||||
from `tabPurchase Invoice`, `tabPurchase Invoice Item`, `tabItem`
|
from `tabPurchase Invoice`, `tabPurchase Invoice Item`, `tabItem`
|
||||||
where `tabPurchase Invoice`.name = `tabPurchase Invoice Item`.`parent` and
|
where `tabPurchase Invoice`.name = `tabPurchase Invoice Item`.`parent` and
|
||||||
`tabItem`.name = `tabPurchase Invoice Item`.`item_code` and
|
`tabItem`.name = `tabPurchase Invoice Item`.`item_code` and
|
||||||
`tabPurchase Invoice`.docstatus = 1 %s
|
`tabPurchase Invoice`.docstatus = 1 {1}
|
||||||
""".format(
|
""".format(
|
||||||
additional_query_columns
|
additional_query_columns, conditions
|
||||||
)
|
),
|
||||||
% (conditions),
|
|
||||||
filters,
|
filters,
|
||||||
as_dict=1,
|
as_dict=1,
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ from frappe.utils import cstr, flt
|
|||||||
from frappe.utils.xlsxutils import handle_html
|
from frappe.utils.xlsxutils import handle_html
|
||||||
|
|
||||||
from erpnext.accounts.report.sales_register.sales_register import get_mode_of_payments
|
from erpnext.accounts.report.sales_register.sales_register import get_mode_of_payments
|
||||||
|
from erpnext.accounts.report.utils import get_query_columns, get_values_for_columns
|
||||||
from erpnext.selling.report.item_wise_sales_history.item_wise_sales_history import (
|
from erpnext.selling.report.item_wise_sales_history.item_wise_sales_history import (
|
||||||
get_customer_details,
|
get_customer_details,
|
||||||
)
|
)
|
||||||
@@ -18,19 +19,14 @@ def execute(filters=None):
|
|||||||
return _execute(filters)
|
return _execute(filters)
|
||||||
|
|
||||||
|
|
||||||
def _execute(
|
def _execute(filters=None, additional_table_columns=None, additional_conditions=None):
|
||||||
filters=None,
|
|
||||||
additional_table_columns=None,
|
|
||||||
additional_query_columns=None,
|
|
||||||
additional_conditions=None,
|
|
||||||
):
|
|
||||||
if not filters:
|
if not filters:
|
||||||
filters = {}
|
filters = {}
|
||||||
columns = get_columns(additional_table_columns, filters)
|
columns = get_columns(additional_table_columns, filters)
|
||||||
|
|
||||||
company_currency = frappe.get_cached_value("Company", filters.get("company"), "default_currency")
|
company_currency = frappe.get_cached_value("Company", filters.get("company"), "default_currency")
|
||||||
|
|
||||||
item_list = get_items(filters, additional_query_columns, additional_conditions)
|
item_list = get_items(filters, get_query_columns(additional_table_columns), additional_conditions)
|
||||||
if item_list:
|
if item_list:
|
||||||
itemised_tax, tax_columns = get_tax_accounts(item_list, columns, company_currency)
|
itemised_tax, tax_columns = get_tax_accounts(item_list, columns, company_currency)
|
||||||
|
|
||||||
@@ -79,30 +75,22 @@ def _execute(
|
|||||||
"customer": d.customer,
|
"customer": d.customer,
|
||||||
"customer_name": customer_record.customer_name,
|
"customer_name": customer_record.customer_name,
|
||||||
"customer_group": customer_record.customer_group,
|
"customer_group": customer_record.customer_group,
|
||||||
|
**get_values_for_columns(additional_table_columns, d),
|
||||||
|
"debit_to": d.debit_to,
|
||||||
|
"mode_of_payment": ", ".join(mode_of_payments.get(d.parent, [])),
|
||||||
|
"territory": d.territory,
|
||||||
|
"project": d.project,
|
||||||
|
"company": d.company,
|
||||||
|
"sales_order": d.sales_order,
|
||||||
|
"delivery_note": d.delivery_note,
|
||||||
|
"income_account": d.unrealized_profit_loss_account
|
||||||
|
if d.is_internal_customer == 1
|
||||||
|
else d.income_account,
|
||||||
|
"cost_center": d.cost_center,
|
||||||
|
"stock_qty": d.stock_qty,
|
||||||
|
"stock_uom": d.stock_uom,
|
||||||
}
|
}
|
||||||
|
|
||||||
if additional_query_columns:
|
|
||||||
for col in additional_query_columns:
|
|
||||||
row.update({col: d.get(col)})
|
|
||||||
|
|
||||||
row.update(
|
|
||||||
{
|
|
||||||
"debit_to": d.debit_to,
|
|
||||||
"mode_of_payment": ", ".join(mode_of_payments.get(d.parent, [])),
|
|
||||||
"territory": d.territory,
|
|
||||||
"project": d.project,
|
|
||||||
"company": d.company,
|
|
||||||
"sales_order": d.sales_order,
|
|
||||||
"delivery_note": d.delivery_note,
|
|
||||||
"income_account": d.unrealized_profit_loss_account
|
|
||||||
if d.is_internal_customer == 1
|
|
||||||
else d.income_account,
|
|
||||||
"cost_center": d.cost_center,
|
|
||||||
"stock_qty": d.stock_qty,
|
|
||||||
"stock_uom": d.stock_uom,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
if d.stock_uom != d.uom and d.stock_qty:
|
if d.stock_uom != d.uom and d.stock_qty:
|
||||||
row.update({"rate": (d.base_net_rate * d.qty) / d.stock_qty, "amount": d.base_net_amount})
|
row.update({"rate": (d.base_net_rate * d.qty) / d.stock_qty, "amount": d.base_net_amount})
|
||||||
else:
|
else:
|
||||||
@@ -394,11 +382,6 @@ def get_group_by_conditions(filters, doctype):
|
|||||||
def get_items(filters, additional_query_columns, additional_conditions=None):
|
def get_items(filters, additional_query_columns, additional_conditions=None):
|
||||||
conditions = get_conditions(filters, additional_conditions)
|
conditions = get_conditions(filters, additional_conditions)
|
||||||
|
|
||||||
if additional_query_columns:
|
|
||||||
additional_query_columns = ", " + ", ".join(additional_query_columns)
|
|
||||||
else:
|
|
||||||
additional_query_columns = ""
|
|
||||||
|
|
||||||
return frappe.db.sql(
|
return frappe.db.sql(
|
||||||
"""
|
"""
|
||||||
select
|
select
|
||||||
@@ -424,7 +407,7 @@ def get_items(filters, additional_query_columns, additional_conditions=None):
|
|||||||
`tabItem`.name = `tabSales Invoice Item`.`item_code` and
|
`tabItem`.name = `tabSales Invoice Item`.`item_code` and
|
||||||
`tabSales Invoice`.docstatus = 1 {1}
|
`tabSales Invoice`.docstatus = 1 {1}
|
||||||
""".format(
|
""".format(
|
||||||
additional_query_columns or "", conditions
|
additional_query_columns, conditions
|
||||||
),
|
),
|
||||||
filters,
|
filters,
|
||||||
as_dict=1,
|
as_dict=1,
|
||||||
|
|||||||
@@ -10,17 +10,18 @@ from erpnext.accounts.doctype.accounting_dimension.accounting_dimension import (
|
|||||||
get_accounting_dimensions,
|
get_accounting_dimensions,
|
||||||
get_dimension_with_children,
|
get_dimension_with_children,
|
||||||
)
|
)
|
||||||
|
from erpnext.accounts.report.utils import get_query_columns, get_values_for_columns
|
||||||
|
|
||||||
|
|
||||||
def execute(filters=None):
|
def execute(filters=None):
|
||||||
return _execute(filters)
|
return _execute(filters)
|
||||||
|
|
||||||
|
|
||||||
def _execute(filters=None, additional_table_columns=None, additional_query_columns=None):
|
def _execute(filters=None, additional_table_columns=None):
|
||||||
if not filters:
|
if not filters:
|
||||||
filters = {}
|
filters = {}
|
||||||
|
|
||||||
invoice_list = get_invoices(filters, additional_query_columns)
|
invoice_list = get_invoices(filters, get_query_columns(additional_table_columns))
|
||||||
columns, expense_accounts, tax_accounts, unrealized_profit_loss_accounts = get_columns(
|
columns, expense_accounts, tax_accounts, unrealized_profit_loss_accounts = get_columns(
|
||||||
invoice_list, additional_table_columns
|
invoice_list, additional_table_columns
|
||||||
)
|
)
|
||||||
@@ -47,13 +48,12 @@ def _execute(filters=None, additional_table_columns=None, additional_query_colum
|
|||||||
purchase_receipt = list(set(invoice_po_pr_map.get(inv.name, {}).get("purchase_receipt", [])))
|
purchase_receipt = list(set(invoice_po_pr_map.get(inv.name, {}).get("purchase_receipt", [])))
|
||||||
project = list(set(invoice_po_pr_map.get(inv.name, {}).get("project", [])))
|
project = list(set(invoice_po_pr_map.get(inv.name, {}).get("project", [])))
|
||||||
|
|
||||||
row = [inv.name, inv.posting_date, inv.supplier, inv.supplier_name]
|
row = [
|
||||||
|
inv.name,
|
||||||
if additional_query_columns:
|
inv.posting_date,
|
||||||
for col in additional_query_columns:
|
inv.supplier,
|
||||||
row.append(inv.get(col))
|
inv.supplier_name,
|
||||||
|
*get_values_for_columns(additional_table_columns, inv).values(),
|
||||||
row += [
|
|
||||||
supplier_details.get(inv.supplier), # supplier_group
|
supplier_details.get(inv.supplier), # supplier_group
|
||||||
inv.tax_id,
|
inv.tax_id,
|
||||||
inv.credit_to,
|
inv.credit_to,
|
||||||
@@ -244,9 +244,6 @@ def get_conditions(filters):
|
|||||||
|
|
||||||
|
|
||||||
def get_invoices(filters, additional_query_columns):
|
def get_invoices(filters, additional_query_columns):
|
||||||
if additional_query_columns:
|
|
||||||
additional_query_columns = ", " + ", ".join(additional_query_columns)
|
|
||||||
|
|
||||||
conditions = get_conditions(filters)
|
conditions = get_conditions(filters)
|
||||||
return frappe.db.sql(
|
return frappe.db.sql(
|
||||||
"""
|
"""
|
||||||
@@ -255,11 +252,10 @@ def get_invoices(filters, additional_query_columns):
|
|||||||
remarks, base_net_total, base_grand_total, outstanding_amount,
|
remarks, base_net_total, base_grand_total, outstanding_amount,
|
||||||
mode_of_payment {0}
|
mode_of_payment {0}
|
||||||
from `tabPurchase Invoice`
|
from `tabPurchase Invoice`
|
||||||
where docstatus = 1 %s
|
where docstatus = 1 {1}
|
||||||
order by posting_date desc, name desc""".format(
|
order by posting_date desc, name desc""".format(
|
||||||
additional_query_columns or ""
|
additional_query_columns, conditions
|
||||||
)
|
),
|
||||||
% conditions,
|
|
||||||
filters,
|
filters,
|
||||||
as_dict=1,
|
as_dict=1,
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -11,17 +11,18 @@ from erpnext.accounts.doctype.accounting_dimension.accounting_dimension import (
|
|||||||
get_accounting_dimensions,
|
get_accounting_dimensions,
|
||||||
get_dimension_with_children,
|
get_dimension_with_children,
|
||||||
)
|
)
|
||||||
|
from erpnext.accounts.report.utils import get_query_columns, get_values_for_columns
|
||||||
|
|
||||||
|
|
||||||
def execute(filters=None):
|
def execute(filters=None):
|
||||||
return _execute(filters)
|
return _execute(filters)
|
||||||
|
|
||||||
|
|
||||||
def _execute(filters, additional_table_columns=None, additional_query_columns=None):
|
def _execute(filters, additional_table_columns=None):
|
||||||
if not filters:
|
if not filters:
|
||||||
filters = frappe._dict({})
|
filters = frappe._dict({})
|
||||||
|
|
||||||
invoice_list = get_invoices(filters, additional_query_columns)
|
invoice_list = get_invoices(filters, get_query_columns(additional_table_columns))
|
||||||
columns, income_accounts, tax_accounts, unrealized_profit_loss_accounts = get_columns(
|
columns, income_accounts, tax_accounts, unrealized_profit_loss_accounts = get_columns(
|
||||||
invoice_list, additional_table_columns
|
invoice_list, additional_table_columns
|
||||||
)
|
)
|
||||||
@@ -54,30 +55,22 @@ def _execute(filters, additional_table_columns=None, additional_query_columns=No
|
|||||||
"posting_date": inv.posting_date,
|
"posting_date": inv.posting_date,
|
||||||
"customer": inv.customer,
|
"customer": inv.customer,
|
||||||
"customer_name": inv.customer_name,
|
"customer_name": inv.customer_name,
|
||||||
|
**get_values_for_columns(additional_table_columns, inv),
|
||||||
|
"customer_group": inv.get("customer_group"),
|
||||||
|
"territory": inv.get("territory"),
|
||||||
|
"tax_id": inv.get("tax_id"),
|
||||||
|
"receivable_account": inv.debit_to,
|
||||||
|
"mode_of_payment": ", ".join(mode_of_payments.get(inv.name, [])),
|
||||||
|
"project": inv.project,
|
||||||
|
"owner": inv.owner,
|
||||||
|
"remarks": inv.remarks,
|
||||||
|
"sales_order": ", ".join(sales_order),
|
||||||
|
"delivery_note": ", ".join(delivery_note),
|
||||||
|
"cost_center": ", ".join(cost_center),
|
||||||
|
"warehouse": ", ".join(warehouse),
|
||||||
|
"currency": company_currency,
|
||||||
}
|
}
|
||||||
|
|
||||||
if additional_query_columns:
|
|
||||||
for col in additional_query_columns:
|
|
||||||
row.update({col: inv.get(col)})
|
|
||||||
|
|
||||||
row.update(
|
|
||||||
{
|
|
||||||
"customer_group": inv.get("customer_group"),
|
|
||||||
"territory": inv.get("territory"),
|
|
||||||
"tax_id": inv.get("tax_id"),
|
|
||||||
"receivable_account": inv.debit_to,
|
|
||||||
"mode_of_payment": ", ".join(mode_of_payments.get(inv.name, [])),
|
|
||||||
"project": inv.project,
|
|
||||||
"owner": inv.owner,
|
|
||||||
"remarks": inv.remarks,
|
|
||||||
"sales_order": ", ".join(sales_order),
|
|
||||||
"delivery_note": ", ".join(delivery_note),
|
|
||||||
"cost_center": ", ".join(cost_center),
|
|
||||||
"warehouse": ", ".join(warehouse),
|
|
||||||
"currency": company_currency,
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
# map income values
|
# map income values
|
||||||
base_net_total = 0
|
base_net_total = 0
|
||||||
for income_acc in income_accounts:
|
for income_acc in income_accounts:
|
||||||
@@ -402,9 +395,6 @@ def get_conditions(filters):
|
|||||||
|
|
||||||
|
|
||||||
def get_invoices(filters, additional_query_columns):
|
def get_invoices(filters, additional_query_columns):
|
||||||
if additional_query_columns:
|
|
||||||
additional_query_columns = ", " + ", ".join(additional_query_columns)
|
|
||||||
|
|
||||||
conditions = get_conditions(filters)
|
conditions = get_conditions(filters)
|
||||||
return frappe.db.sql(
|
return frappe.db.sql(
|
||||||
"""
|
"""
|
||||||
@@ -413,10 +403,10 @@ def get_invoices(filters, additional_query_columns):
|
|||||||
base_net_total, base_grand_total, base_rounded_total, outstanding_amount,
|
base_net_total, base_grand_total, base_rounded_total, outstanding_amount,
|
||||||
is_internal_customer, represents_company, company {0}
|
is_internal_customer, represents_company, company {0}
|
||||||
from `tabSales Invoice`
|
from `tabSales Invoice`
|
||||||
where docstatus = 1 %s order by posting_date desc, name desc""".format(
|
where docstatus = 1 {1}
|
||||||
additional_query_columns or ""
|
order by posting_date desc, name desc""".format(
|
||||||
)
|
additional_query_columns, conditions
|
||||||
% conditions,
|
),
|
||||||
filters,
|
filters,
|
||||||
as_dict=1,
|
as_dict=1,
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -67,8 +67,9 @@ def get_all_transfers(date, shareholder):
|
|||||||
# condition = 'AND company = %(company)s '
|
# condition = 'AND company = %(company)s '
|
||||||
return frappe.db.sql(
|
return frappe.db.sql(
|
||||||
"""SELECT * FROM `tabShare Transfer`
|
"""SELECT * FROM `tabShare Transfer`
|
||||||
WHERE (DATE(date) <= %(date)s AND from_shareholder = %(shareholder)s {condition})
|
WHERE ((DATE(date) <= %(date)s AND from_shareholder = %(shareholder)s {condition})
|
||||||
OR (DATE(date) <= %(date)s AND to_shareholder = %(shareholder)s {condition})
|
OR (DATE(date) <= %(date)s AND to_shareholder = %(shareholder)s {condition}))
|
||||||
|
AND docstatus = 1
|
||||||
ORDER BY date""".format(
|
ORDER BY date""".format(
|
||||||
condition=condition
|
condition=condition
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import frappe
|
import frappe
|
||||||
from frappe.utils import flt, formatdate, get_datetime_str
|
from frappe.utils import flt, formatdate, get_datetime_str, get_table_name
|
||||||
|
|
||||||
from erpnext import get_company_currency, get_default_company
|
from erpnext import get_company_currency, get_default_company
|
||||||
from erpnext.accounts.doctype.fiscal_year.fiscal_year import get_from_and_to_date
|
from erpnext.accounts.doctype.fiscal_year.fiscal_year import get_from_and_to_date
|
||||||
@@ -151,3 +151,32 @@ def get_invoiced_item_gross_margin(
|
|||||||
result = sum(d.gross_profit for d in result)
|
result = sum(d.gross_profit for d in result)
|
||||||
|
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
|
||||||
|
def get_query_columns(report_columns):
|
||||||
|
if not report_columns:
|
||||||
|
return ""
|
||||||
|
|
||||||
|
columns = []
|
||||||
|
for column in report_columns:
|
||||||
|
fieldname = column["fieldname"]
|
||||||
|
|
||||||
|
if doctype := column.get("_doctype"):
|
||||||
|
columns.append(f"`{get_table_name(doctype)}`.`{fieldname}`")
|
||||||
|
else:
|
||||||
|
columns.append(fieldname)
|
||||||
|
|
||||||
|
return ", " + ", ".join(columns)
|
||||||
|
|
||||||
|
|
||||||
|
def get_values_for_columns(report_columns, report_row):
|
||||||
|
values = {}
|
||||||
|
|
||||||
|
if not report_columns:
|
||||||
|
return values
|
||||||
|
|
||||||
|
for column in report_columns:
|
||||||
|
fieldname = column["fieldname"]
|
||||||
|
values[fieldname] = report_row.get(fieldname)
|
||||||
|
|
||||||
|
return values
|
||||||
|
|||||||
Reference in New Issue
Block a user