From 91325105c510beb69a843e97e9d40833992fc9f6 Mon Sep 17 00:00:00 2001 From: Goran Kliska Date: Wed, 28 Mar 2012 18:25:45 +0200 Subject: [PATCH 01/41] l10n_hr bzr revid: goran.kliska@slobodni-programi.hr-20120328162545-p0outnnuqcp5desr --- addons/l10n_hr/__init__.py | 27 + addons/l10n_hr/__openerp__.py | 84 + .../l10n_hr/data/account.account.template.csv | 2284 +++++++++++++++++ addons/l10n_hr/data/account.account.type.csv | 26 + .../data/account.fiscal.position.template.csv | 4 + .../data/account.tax.code.template.csv | 78 + addons/l10n_hr/data/account.tax.template.csv | 62 + addons/l10n_hr/data/fiscal_position.xml | 68 + .../l10n_hr/data/fiscal_position.xml.backup | 139 + addons/l10n_hr/i18n/hr.po | 149 ++ addons/l10n_hr/i18n/l10n_hr.pot | 149 ++ addons/l10n_hr/l10n_hr_wizard.xml | 47 + 12 files changed, 3117 insertions(+) create mode 100644 addons/l10n_hr/__init__.py create mode 100644 addons/l10n_hr/__openerp__.py create mode 100644 addons/l10n_hr/data/account.account.template.csv create mode 100644 addons/l10n_hr/data/account.account.type.csv create mode 100644 addons/l10n_hr/data/account.fiscal.position.template.csv create mode 100644 addons/l10n_hr/data/account.tax.code.template.csv create mode 100644 addons/l10n_hr/data/account.tax.template.csv create mode 100644 addons/l10n_hr/data/fiscal_position.xml create mode 100644 addons/l10n_hr/data/fiscal_position.xml.backup create mode 100644 addons/l10n_hr/i18n/hr.po create mode 100644 addons/l10n_hr/i18n/l10n_hr.pot create mode 100755 addons/l10n_hr/l10n_hr_wizard.xml diff --git a/addons/l10n_hr/__init__.py b/addons/l10n_hr/__init__.py new file mode 100644 index 00000000000..e559ab15644 --- /dev/null +++ b/addons/l10n_hr/__init__.py @@ -0,0 +1,27 @@ +# -*- encoding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# Module: l10n_hr +# Author: Goran Kliska +# mail: gkliskaATgmail.com +# Copyright (C) 2011- Slobodni programi d.o.o., Zagreb +# Contributions: +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file diff --git a/addons/l10n_hr/__openerp__.py b/addons/l10n_hr/__openerp__.py new file mode 100644 index 00000000000..ec0f6269364 --- /dev/null +++ b/addons/l10n_hr/__openerp__.py @@ -0,0 +1,84 @@ +# -*- encoding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# Module: l10n_hr +# Author: Goran Kliska +# mail: gkliskaATgmail.com +# Copyright: Slobodni programi d.o.o., Zagreb +# Contributions: +# Tomislav Bošnjaković, Storm Computers d.o.o. : +# - account types +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +{ + "name" : "Croatia - RRIF's 2012 chat of accounts", + "description" : """ +Croatian localisation. +====================== + +Author: Goran Kliska, Slobodni programi d.o.o., Zagreb + http://www.slobodni-programi.hr + +Contributions: + Infokom d.o.o. + Storm Computers d.o.o. + +Description: + +Croatian Chart of Accounts (RRIF ver.2012) + +RRIF-ov računski plan za poduzetnike za 2012. +Vrste konta +Kontni plan prema RRIF-u, dorađen u smislu kraćenja naziva i dodavanja analitika +Porezne grupe prema poreznoj prijavi +Porezi PDV-a +Ostali porezi (samo češće korišteni) povezani s kontima kontnog plana + +Izvori podataka: + http://www.rrif.hr/dok/preuzimanje/rrif-rp2011.rar + http://www.rrif.hr/dok/preuzimanje/rrif-rp2012.rar + + + +""", + "version" : "2012.1", + "author" : "OpenERP Croatian Community", + "category" : 'Localization/Account Charts', + "website": "https://code.launchpad.net/openobject-croatia" , + + 'depends': [ + 'account', + 'base_vat', + 'base_iban', + 'account_chart', +# 'account_coda', + ], + 'init_xml': [], + 'update_xml': [ + 'data/account.account.type.csv', + 'data/account.tax.code.template.csv', + 'data/account.account.template.csv', + 'l10n_hr_wizard.xml', + 'data/account.tax.template.csv', + 'data/fiscal_position.xml', + ], + "demo_xml" : [], + 'test' : [], + "active": False, + "installable": True, +} +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_hr/data/account.account.template.csv b/addons/l10n_hr/data/account.account.template.csv new file mode 100644 index 00000000000..ee6ebba3cae --- /dev/null +++ b/addons/l10n_hr/data/account.account.template.csv @@ -0,0 +1,2284 @@ +"code","id","parent_id:id","type","user_type:id","reconcile","shortcut","name","note" +"RRIF","kp_rrif",,"view","account_type_view",,,"KONTNI PLAN", +"0","kp_rrif0","kp_rrif","view","account_type_view",,,"POTRAŽIVANJA ZA UPISANI KAPITAL I DUGOTRAJNA IMOVINA","POTRAŽIVANJA ZA UPISANI KAPITAL I DUGOTRAJNA IMOVINA" +"00","kp_rrif00","kp_rrif0","view","account_type_view",,,"POTRAŽIVANJA ZA UPISANI A NEUPLAĆENI KAPITAL","POTRAŽIVANJA ZA UPISANI A NEUPLAĆENI KAPITAL" +"000","kp_rrif000","kp_rrif00","view","account_type_view",,,"Potraživanja za upisani a neuplaćeni dionički kapital (analitika po upisnicima)","Potraživanja za upisani a neuplaćeni dionički kapital (analitika po upisnicima)" +"0000","kp_rrif0000","kp_rrif000","other","account_type_upis_kapital",,,"Potraživanja za upisani a neuplaćeni dionički kapital (analitika po upisnicima)-a1","Potraživanja za upisani a neuplaćeni dionički kapital (analitika po upisnicima)-Analitika 1" +"001","kp_rrif001","kp_rrif00","view","account_type_view",,,"Potraživanja iz ponovljene emisije dionica za upisane a neuplaćene svote kapitala po emisijama dionica","Potraživanja iz ponovljene emisije dionica za upisane a neuplaćene svote kapitala (razrada po emisijama dionica)" +"0010","kp_rrif0010","kp_rrif001","other","account_type_upis_kapital",,,"Potraživanja iz ponovljene emisije dionica za upisane a neuplaćene svote kapitala po emisijama dionica-a1","Potraživanja iz ponovljene emisije dionica za upisane a neuplaćene svote kapitala (razrada po emisijama dionica)-Analitika 1" +"002","kp_rrif002","kp_rrif00","view","account_type_view",,,"Potraživanja za upisani a neuplaćeni kapital u d.o.o. (analitika po članovima društva)","Potraživanja za upisani a neuplaćeni kapital u d.o.o. (analitika po članovima društva)" +"0020","kp_rrif0020","kp_rrif002","other","account_type_upis_kapital",,,"Potraživanja za upisani a neuplaćeni kapital u d.o.o. (analitika po članovima društva)-a1","Potraživanja za upisani a neuplaćeni kapital u d.o.o. (analitika po članovima društva)-Analitika 1" +"003","kp_rrif003","kp_rrif00","view","account_type_view",,,"Potraživanja za temeljni ulog komanditora","Potraživanja za temeljni ulog komanditora" +"0030","kp_rrif0030","kp_rrif003","other","account_type_upis_kapital",,,"Potraživanja za temeljni ulog komanditora-a1","Potraživanja za temeljni ulog komanditora-Analitika 1" +"004","kp_rrif004","kp_rrif00","view","account_type_view",,,"Potraživanje za ostale uloge u kapital","Potraživanje za ostale uloge u kapital" +"0040","kp_rrif0040","kp_rrif004","other","account_type_upis_kapital",,,"Potraživanje za ostale uloge u kapital-a1","Potraživanje za ostale uloge u kapital-Analitika 1" +"01","kp_rrif01","kp_rrif0","view","account_type_view",,,"NEMATERIJALNA IMOVINA","NEMATERIJALNA IMOVINA" +"010","kp_rrif010","kp_rrif01","view","account_type_view",,,"Izdatci za razvoj","Izdatci za razvoj" +"0100","kp_rrif0100","kp_rrif010","other","account_type_dug_imovina",,,"Izdatci za razvoj projekta (konstruiranje i test. prototipova i modela,alata,naprava i kalupa i sl.","Izdatci za razvoj projekta (konstruiranje i testiranje prototipova i modela, dizajn alata, naprava i kalupa i sl." +"0101","kp_rrif0101","kp_rrif010","other","account_type_dug_imovina",,,"Izdatci za razvoj proizvoda (uzorci, recepture, troškovi pronalazaka i sl.).","Izdatci za razvoj proizvoda (uzorci, recepture, troškovi pronalazaka i sl.)." +"0102","kp_rrif0102","kp_rrif010","other","account_type_dug_imovina",,,"Izdatci za istraživanje mineralnih blaga (MSFI 6)","Izdatci za istraživanje mineralnih blaga (MSFI 6)" +"011","kp_rrif011","kp_rrif01","view","account_type_view",,,"Koncesije, patenti, licencije, robne i uslužne marke","Koncesije, patenti, licencije, robne i uslužne marke" +"0110","kp_rrif0110","kp_rrif011","other","account_type_dug_imovina",,,"Ulaganje u koncesije idozvole(za resurse, ceste, ribarenje, linije, sirovine, itd.)","Ulaganje u koncesije i dozvole (za resurse, ceste, ribarenje, linije, sirovine, itd.)" +"0111","kp_rrif0111","kp_rrif011","other","account_type_dug_imovina",,,"Ulaganje u patente i tehnologiju, inovacije, teh.dokumentaciju za proizv. proizvoda ili pružanje usluga","Ulaganje u patente i tehnologiju, inovacije, tehničku i tehnološku dokumentaciju za proizvodnju proizvoda ili pružanje usluga" +"0112","kp_rrif0112","kp_rrif011","other","account_type_dug_imovina",,,"Ulaganje u licenciju i frenčajz (Franchising)","Ulaganje u licenciju i frenčajz (Franchising)" +"0113","kp_rrif0113","kp_rrif011","other","account_type_dug_imovina",,,"Robne marke, trgovačko ime, lista kupaca, industrijska prava, marketinška prava, usl. marke i sl.prava","Robne marke, trgovačko ime, lista kupaca, industrijska prava, marketinška prava, uslužne marke i sl. prava" +"0114","kp_rrif0114","kp_rrif011","other","account_type_dug_imovina",,,"Ulaganje u tržišni udio (otkup prava distribucije za neko područje)","Ulaganje u tržišni udio (otkup prava distribucije za neko područje)" +"012","kp_rrif012","kp_rrif01","view","account_type_view",,,"Softver i ostala prava","Softver i ostala prava" +"0120","kp_rrif0120","kp_rrif012","view","account_type_view",,,"Softwer","Softwer" +"01200","kp_rrif01200","kp_rrif0120","other","account_type_dug_imovina",,,"Ulaganje u računalni softwer","Ulaganje u računalni softwer" +"01201","kp_rrif01201","kp_rrif0120","other","account_type_dug_imovina",,,"Ulaganje u internetske stranice","Ulaganje u internetske stranice" +"0121","kp_rrif0121","kp_rrif012","view","account_type_view",,,"Ostala dugotrajna prava","Ostala dugotrajna prava" +"01210","kp_rrif01210","kp_rrif0121","other","account_type_dug_imovina",,,"Ulaganje u autorska i dr. prava korištenja","Ulaganje u autorska i dr. prava korištenja" +"01211","kp_rrif01211","kp_rrif0121","other","account_type_dug_imovina",,,"Ulaganje u znanje (know how), dizajn","Ulaganje u znanje (know how), dizajn" +"01212","kp_rrif01212","kp_rrif0121","other","account_type_dug_imovina",,,"Ulaganje u pravo reproduciranja (npr. filmova), pravo objave u izdavaštvu i sl.","Ulaganje u pravo reproduciranja (npr. filmova), pravo objave u izdavaštvu i sl." +"01213","kp_rrif01213","kp_rrif0121","other","account_type_dug_imovina",,,"Ulaganja na tuđoj imovini radi uporabe ili poboljšanja (nekretnina, opreme i sl.)","Ulaganja na tuđoj imovini radi uporabe ili poboljšanja (nekretnina, opreme i sl.)" +"01214","kp_rrif01214","kp_rrif0121","other","account_type_dug_imovina",,,"Ulaganje u dugogodišnje pravo uporabe (prema ugovoru)","Ulaganje u dugogodišnje pravo uporabe (prema ugovoru)" +"01215","kp_rrif01215","kp_rrif0121","other","account_type_dug_imovina",,,"Ulaganje u pravo suvlasništva opreme","Ulaganje u pravo suvlasništva opreme" +"0122","kp_rrif0122","kp_rrif012","view","account_type_view",,,"Ostala prava","Ostala prava" +"01220","kp_rrif01220","kp_rrif0122","other","account_type_dug_imovina",,,"Založno pravo i hipoteke (realizirane)","Založno pravo i hipoteke (realizirane)" +"01221","kp_rrif01221","kp_rrif0122","other","account_type_dug_imovina",,,"Ostala dugogodišnja prava","Ostala dugogodišnja prava" +"013","kp_rrif013","kp_rrif01","view","account_type_view",,,"Goodwill","Goodwill" +"0130","kp_rrif0130","kp_rrif013","other","account_type_dug_imovina",,,"Goodwill","Goodwill" +"014","kp_rrif014","kp_rrif01","view","account_type_view",,,"Ostala nematerijalna imovina","Ostala nematerijalna imovina" +"0140","kp_rrif0140","kp_rrif014","other","account_type_dug_imovina",,,"Dugogodišnje naknade plaćene za pravo građenja, pravo prolaza i sl.","Dugogodišnje naknade plaćene za pravo građenja, pravo prolaza i sl." +"0141","kp_rrif0141","kp_rrif014","other","account_type_dug_imovina",,,"Filmovi, glazbeni zapisi","Filmovi, glazbeni zapisi" +"0142","kp_rrif0142","kp_rrif014","other","account_type_dug_imovina",,,"Ostala nematerijalna imovina","Ostala nematerijalna imovina" +"015","kp_rrif015","kp_rrif01","view","account_type_view",,,"Predujmovi za nabavu nematerijalne imovine","Predujmovi za nabavu nematerijalne imovine" +"0150","kp_rrif0150","kp_rrif015","other","account_type_dug_imovina",,,"Predujmovi za razvoj","Predujmovi za razvoj" +"0151","kp_rrif0151","kp_rrif015","other","account_type_dug_imovina",,,"Predujmovi za koncesije","Predujmovi za koncesije" +"0152","kp_rrif0152","kp_rrif015","other","account_type_dug_imovina",,,"Predujmovi za patente, licencije i dr.","Predujmovi za patente, licencije i dr." +"0153","kp_rrif0153","kp_rrif015","other","account_type_dug_imovina",,,"Predujmovi za robne ili uslužne marke","Predujmovi za robne ili uslužne marke" +"0154","kp_rrif0154","kp_rrif015","other","account_type_dug_imovina",,,"Predujmovi za nabavu softwera","Predujmovi za nabavu softwera" +"0155","kp_rrif0155","kp_rrif015","other","account_type_dug_imovina",,,"Predujmovi za nabavu ostalih prava uporabe","Predujmovi za nabavu ostalih prava uporabe" +"0156","kp_rrif0156","kp_rrif015","other","account_type_dug_imovina",,,"Predujmovi za ostalu nematerijalnu imovinu","Predujmovi za ostalu nematerijalnu imovinu" +"016","kp_rrif016","kp_rrif01","view","account_type_view",,,"Nematerijalna imovina u pripremi (analitika prema vrsti računa skupine 01)","Nematerijalna imovina u pripremi (analitika prema vrsti računa skupine 01)" +"0160","kp_rrif0160","kp_rrif016","other","account_type_dug_imovina",,,"Nematerijalna imovina u pripremi (analitika prema vrsti računa skupine 01)-a1","Nematerijalna imovina u pripremi (analitika prema vrsti računa skupine 01)-Analitika 1" +"018","kp_rrif018","kp_rrif01","view","account_type_view",,,"Vrijednosno usklađenje nematerijalne imovine (analitika prema vrsti računa skupine 01)","Vrijednosno usklađenje nematerijalne imovine (analitika prema vrsti računa skupine 01)" +"0180","kp_rrif0180","kp_rrif018","other","account_type_dug_imovina",,,"Vrijednosno usklađenje nematerijalne imovine (analitika prema vrsti računa skupine 01)-a1","Vrijednosno usklađenje nematerijalne imovine (analitika prema vrsti računa skupine 01)-Analitika 1" +"019","kp_rrif019","kp_rrif01","view","account_type_view",,,"Akumulirana amortizacija nematerijalne imovine","Akumulirana amortizacija nematerijalne imovine" +"0190","kp_rrif0190","kp_rrif019","other","account_type_dug_imovina",,,"Akumulirana amortizacija izdataka za razvoj","Akumulirana amortizacija izdataka za razvoj" +"0191","kp_rrif0191","kp_rrif019","other","account_type_dug_imovina",,,"Akumulirana amortizacija koncesija, patenata, licencija i sl.","Akumulirana amortizacija koncesija, patenata, licencija i sl." +"0192","kp_rrif0192","kp_rrif019","other","account_type_dug_imovina",,,"Akumulirana amort. robne i uslužne marke","Akumulirana amort. robne i uslužne marke" +"0193","kp_rrif0193","kp_rrif019","other","account_type_dug_imovina",,,"Akumulirana amortizacija softwera","Akumulirana amortizacija softwera" +"0194","kp_rrif0194","kp_rrif019","other","account_type_dug_imovina",,,"Akumulirana amortizacija godwilla (v. napom. 3.)","Akumulirana amortizacija godwilla (v. napom. 3.)" +"0195","kp_rrif0195","kp_rrif019","other","account_type_dug_imovina",,,"Akumulirana amort. ostale nematerijalne imovine","Akumulirana amort. ostale nematerijalne imovine" +"02","kp_rrif02","kp_rrif0","view","account_type_view",,,"MATERIJALNA IMOVINA - NEKRETNINE","MATERIJALNA IMOVINA - NEKRETNINE" +"020","kp_rrif020","kp_rrif02","view","account_type_view",,,"Zemljišta","Zemljišta" +"0200","kp_rrif0200","kp_rrif020","other","account_type_dug_imovina",,,"Građevinsko zemljište (bez zgrada)","Građevinsko zemljište (bez zgrada)" +"0201","kp_rrif0201","kp_rrif020","other","account_type_dug_imovina",,,"Poljoprivredno zemljište","Poljoprivredno zemljište" +"0202","kp_rrif0202","kp_rrif020","other","account_type_dug_imovina",,,"Zemljište za deponije smeća i otpada","Zemljište za deponije smeća i otpada" +"0203","kp_rrif0203","kp_rrif020","other","account_type_dug_imovina",,,"Zemljište za eksploataciju kamena, gline, šljunka i pijeska,","Zemljište za eksploataciju kamena, gline, šljunka i pijeska," +"0204","kp_rrif0204","kp_rrif020","other","account_type_dug_imovina",,,"Zemljište sa supstancijalnom potrošnjom ili odlagališta","Zemljište sa supstancijalnom potrošnjom ili odlagališta" +"0205","kp_rrif0205","kp_rrif020","other","account_type_dug_imovina",,,"Zemljište pod prometnicama, dvorištima, parkiralištima i sl.","Zemljište pod prometnicama, dvorištima, parkiralištima i sl." +"0206","kp_rrif0206","kp_rrif020","other","account_type_dug_imovina",,,"Zemljišta pod dugogodišnjim nasadama, parkovima, vrtovima i sl.","Zemljišta pod dugogodišnjim nasadama, parkovima, vrtovima i sl." +"0207","kp_rrif0207","kp_rrif020","other","account_type_dug_imovina",,,"Čista neobrađena i nezasađena zemljišta i kamenjari","Čista neobrađena i nezasađena zemljišta i kamenjari" +"0208","kp_rrif0208","kp_rrif020","other","account_type_dug_imovina",,,"Zemljišta ispod građevina","Zemljišta ispod građevina" +"0209","kp_rrif0209","kp_rrif020","other","account_type_dug_imovina",,,"Poboljšanja na zemljištu (ulaganja u odvodnjavanje, uređivanje prilaza i sl.)","Poboljšanja na zemljištu (ulaganja u odvodnjavanje, uređivanje prilaza i sl.)" +"021","kp_rrif021","kp_rrif02","view","account_type_view",,,"Zemljišna prava (višegodišnja)","Zemljišna prava (višegodišnja)" +"0210","kp_rrif0210","kp_rrif021","other","account_type_dug_imovina",,,"Zemljište s upisanim pravom građenja (unaprijed plaćena)","Zemljište s upisanim pravom građenja (unaprijed plaćena)" +"0211","kp_rrif0211","kp_rrif021","other","account_type_dug_imovina",,,"Pravo služnosti na zemljištu (unaprijed plaćena)","Pravo služnosti na zemljištu (unaprijed plaćena)" +"0212","kp_rrif0212","kp_rrif021","other","account_type_dug_imovina",,,"Zemljišta u zakupu (unaprijed plaćena)","Zemljišta u zakupu (unaprijed plaćena)" +"023","kp_rrif023","kp_rrif02","view","account_type_view",,,"Građevinski objekti (za vlastite potrebe)","Građevinski objekti (za vlastite potrebe)" +"0230","kp_rrif0230","kp_rrif023","other","account_type_dug_imovina",,,"Poslovne zgrade","Poslovne zgrade" +"0231","kp_rrif0231","kp_rrif023","other","account_type_dug_imovina",,,"Tvorničke zgrade, hale i radionice","Tvorničke zgrade, hale i radionice" +"0232","kp_rrif0232","kp_rrif023","other","account_type_dug_imovina",,,"Zgrade trgovine, hotela, motela, restorana","Zgrade trgovine, hotela, motela, restorana" +"0233","kp_rrif0233","kp_rrif023","other","account_type_dug_imovina",,,"Skladišta, silosi, nadstrešnice i garaže, staklenici, sušionice, hladnjače","Skladišta, silosi, nadstrešnice i garaže, staklenici, sušionice, hladnjače" +"0234","kp_rrif0234","kp_rrif023","other","account_type_dug_imovina",,,"Zgrade montažne, barake, mostovi, drvene konstrukcije i sl.","Zgrade montažne, barake, mostovi, drvene konstrukcije i sl." +"0235","kp_rrif0235","kp_rrif023","other","account_type_dug_imovina",,,"Ograde, izlozi, potporni zidovi -brane, športski tereni,šatori,žičare i sl.","Ograde (betonske, kamene, metalne i sl.), izlozi, potporni zidovi - brane, športski tereni, šatori, žičare i sl." +"0236","kp_rrif0236","kp_rrif023","other","account_type_dug_imovina",,,"Putovi, parkirališta, staze i dr. građevine (rampe i sl.), nadvožnjaci i dr. bet. ili met. konstruk.","Putovi, parkirališta, staze i dr. građevine (rampe i sl.), nadvožnjaci i dr. betonske ili metalne konstrukcije" +"0237","kp_rrif0237","kp_rrif023","other","account_type_dug_imovina",,,"Cjevovodi, vodospremnici, utvrđene obale, kanali, kanalizacija, dalekovodi","Cjevovodi, vodospremnici, utvrđene obale, kanali, kanalizacija, dalekovodi" +"0238","kp_rrif0238","kp_rrif023","other","account_type_dug_imovina",,,"Objekti poljoprivrede i ribarstva","Objekti poljoprivrede i ribarstva" +"0239","kp_rrif0239","kp_rrif023","other","account_type_dug_imovina",,,"Ostali nespomenuti građevinski objekti (rudnici, brane) i objekti izvan uporabe","Ostali nespomenuti građevinski objekti (rudnici, brane) i objekti izvan uporabe" +"024","kp_rrif024","kp_rrif02","view","account_type_view",,,"Stanovi za vlastite zaposlenike","Stanovi za vlastite zaposlenike" +"0240","kp_rrif0240","kp_rrif024","other","account_type_dug_imovina",,,"Stanovi za vlastite zaposlenike-a1","Stanovi za vlastite zaposlenike-Analitika 1" +"026","kp_rrif026","kp_rrif02","view","account_type_view",,,"Predujmovi za nabavu nekretnina","Predujmovi za nabavu nekretnina" +"0260","kp_rrif0260","kp_rrif026","other","account_type_dug_imovina",,,"Predujmovi za nabavu zemljišta","Predujmovi za nabavu zemljišta" +"0261","kp_rrif0261","kp_rrif026","other","account_type_dug_imovina",,,"Predujmovi za građevine u nabavi","Predujmovi za građevine u nabavi" +"027","kp_rrif027","kp_rrif02","view","account_type_view",,,"Nekretnine u pripremi","Nekretnine u pripremi" +"0270","kp_rrif0270","kp_rrif027","other","account_type_dug_imovina",,,"Zemljišta u pripremi","Zemljišta u pripremi" +"0271","kp_rrif0271","kp_rrif027","other","account_type_dug_imovina",,,"Građevine u pripremi","Građevine u pripremi" +"028","kp_rrif028","kp_rrif02","view","account_type_view",,,"Vrijednosno usklađenje nekretnina","Vrijednosno usklađenje nekretnina" +"0280","kp_rrif0280","kp_rrif028","other","account_type_dug_imovina",,,"Vrijednosno usklađenje zemljišta","Vrijednosno usklađenje zemljišta" +"0281","kp_rrif0281","kp_rrif028","other","account_type_dug_imovina",,,"Vrijednosno usklađenje građevina","Vrijednosno usklađenje građevina" +"029","kp_rrif029","kp_rrif02","view","account_type_view",,,"Akumulirana amortizacija građevina","Akumulirana amortizacija građevina" +"0290","kp_rrif0290","kp_rrif029","other","account_type_dug_imovina",,,"Akumulirana amortizacija građevina (analitika prema pojedinim građevinama)","Akumulirana amortizacija građevina (analitika prema pojedinim građevinama)" +"0291","kp_rrif0291","kp_rrif029","other","account_type_dug_imovina",,,"Akumulirana amortizacija odlagališta otpada, kamenoloma i sl. (MRS 16. t. 58.)","Akumulirana amortizacija odlagališta otpada, kamenoloma i sl. (MRS 16. t. 58.)" +"03","kp_rrif03","kp_rrif0","view","account_type_view",,,"POSTROJENJA, OPREMA, ALATI, INVENTAR I TRANSPORTNA SREDSTVA","POSTROJENJA, OPREMA, ALATI, INVENTAR I TRANSPORTNA SREDSTVA" +"030","kp_rrif030","kp_rrif03","view","account_type_view",,,"Postrojenja","Postrojenja" +"0300","kp_rrif0300","kp_rrif030","other","account_type_dug_imovina",,,"Tehnička postrojenja, uređaji, spremnici, pogonski motori, platforme i dr.","Tehnička postrojenja, uređaji, spremnici, pogonski motori, platforme i dr." +"0301","kp_rrif0301","kp_rrif030","other","account_type_dug_imovina",,,"Strojevi i alati u svezi sa strojevima u pogonima i radionicama za obradu i preradu","Strojevi i alati u svezi sa strojevima u pogonima i radionicama za obradu i preradu" +"0302","kp_rrif0302","kp_rrif030","other","account_type_dug_imovina",,,"Energetska postrojenja (kotlovnice, generatori,solarne ćelije, vjetro-elektrane, toplinske crpke i dr.)","Energetska postrojenja (kotlovnice, generatori, naponske i solarne ćelije, vjetro-elektrane, toplinske crpke i dr.)" +"0303","kp_rrif0303","kp_rrif030","other","account_type_dug_imovina",,,"Rashladna postrojenja","Rashladna postrojenja" +"0304","kp_rrif0304","kp_rrif030","other","account_type_dug_imovina",,,"Prijenosna postrojenja (dizala, pokretne stepenice, elevatori, pokretne trake i sl.)","Prijenosna postrojenja (dizala, pokretne stepenice, elevatori, pokretne trake i sl.)" +"0305","kp_rrif0305","kp_rrif030","other","account_type_dug_imovina",,,"Poboljšanje na postrojenjima","Poboljšanje na postrojenjima" +"0306","kp_rrif0306","kp_rrif030","other","account_type_dug_imovina",,,"Mlinska postrojenja","Mlinska postrojenja" +"0307","kp_rrif0307","kp_rrif030","other","account_type_dug_imovina",,,"Postrojenje za pakiranje, ambalažu i sl.","Postrojenje za pakiranje, ambalažu i sl." +"0309","kp_rrif0309","kp_rrif030","other","account_type_dug_imovina",,,"Ostala postrojenja i postrojenja izvan uporabe","Ostala postrojenja i postrojenja izvan uporabe" +"031","kp_rrif031","kp_rrif03","view","account_type_view",,,"Oprema","Oprema" +"0310","kp_rrif0310","kp_rrif031","other","account_type_dug_imovina",,,"Uredska oprema (fotokopirni, telefoni, telefaxi, blagajne, alarmi, klima, hladnjaci, televizori, i dr.)","Uredska oprema (fotokopirni aparati, telefoni, telefaxi, blagajne, alarmi, klimatizacijski uređaji, hladnjaci, televizori, i dr.)" +"0311","kp_rrif0311","kp_rrif031","other","account_type_dug_imovina",,,"Računalna oprema","Računalna oprema" +"0312","kp_rrif0312","kp_rrif031","other","account_type_dug_imovina",,,"Telekomunikacijska oprema (mobiteli, tel. centrale, antene i sl.)","Telekomunikacijska oprema (mobiteli, tel. centrale, antene i sl.)" +"0313","kp_rrif0313","kp_rrif031","other","account_type_dug_imovina",,,"Oprema trgovine (police, blagajne, hladnjaci, i dr.)","Oprema trgovine (police, blagajne, hladnjaci, i dr.)" +"0314","kp_rrif0314","kp_rrif031","other","account_type_dug_imovina",,,"Oprema ugostiteljstva, hotela i sl. (aparati, štednjaci, hladnjaci, pokućstvo i sl.)","Oprema ugostiteljstva, hotela i sl. (aparati, štednjaci, hladnjaci, pokućstvo i sl.)" +"0315","kp_rrif0315","kp_rrif031","other","account_type_dug_imovina",,,"Oprema servisa (dizalice, ispitni uređaji, aparati i dr.)","Oprema servisa (dizalice, ispitni uređaji, aparati i dr.)" +"0316","kp_rrif0316","kp_rrif031","other","account_type_dug_imovina",,,"Oprema za graditeljstvo i montažu(kranovi, bageri, skele, oplate, mješalice, dizalice, valjci i sl.)","Oprema za graditeljstvo (kranovi, bageri, skele, oplate, mješalice, dizalice, valjci i sl.)" +"0317","kp_rrif0317","kp_rrif031","other","account_type_dug_imovina",,,"Oprema grijanja i hlađenja","Oprema grijanja i hlađenja" +"0318","kp_rrif0318","kp_rrif031","other","account_type_dug_imovina",,,"Oprema zaštite na radu i protupožarne zaštite","Oprema zaštite na radu i protupožarne zaštite" +"0319","kp_rrif0319","kp_rrif031","other","account_type_dug_imovina",,,"Ostala oprema i oprema izvan uporabe","Ostala oprema i oprema izvan uporabe" +"032","kp_rrif032","kp_rrif03","view","account_type_view",,,"Alati, pogonski inventar i transportna imovina","Alati, pogonski inventar i transportna imovina" +"0320","kp_rrif0320","kp_rrif032","view","account_type_view",,,"Transportna imovina","Transportna imovina" +"03200","kp_rrif03200","kp_rrif0320","other","account_type_dug_imovina",,,"Putnička vozila (osobna i putnički kombi) i motor kotači","Putnička vozila (osobna i putnički kombi) i motor kotači" +"03201","kp_rrif03201","kp_rrif0320","other","account_type_dug_imovina",,,"Teretna i vučna vozila, tegljači i kamioni","Teretna i vučna vozila, tegljači i kamioni" +"03202","kp_rrif03202","kp_rrif0320","other","account_type_dug_imovina",,,"Priključna transportna sredstva (prikolice)","Priključna transportna sredstva (prikolice)" +"03203","kp_rrif03203","kp_rrif0320","other","account_type_dug_imovina",,,"Teretna vozila (dostavna i kombi) i hladnjače, cisterne","Teretna vozila (dostavna i kombi) i hladnjače, cisterne" +"03204","kp_rrif03204","kp_rrif0320","other","account_type_dug_imovina",,,"Auto mješalice, auto crpke za beton, auto dizalice i sl.","Auto mješalice, auto crpke za beton, auto dizalice i sl." +"03205","kp_rrif03205","kp_rrif0320","other","account_type_dug_imovina",,,"Autobusi","Autobusi" +"03206","kp_rrif03206","kp_rrif0320","other","account_type_dug_imovina",,,"Zrakoplovi","Zrakoplovi" +"03207","kp_rrif03207","kp_rrif0320","other","account_type_dug_imovina",,,"Brodovi (veći od 1000 BRT)","Brodovi (veći od 1000 BRT)" +"03208","kp_rrif03208","kp_rrif0320","other","account_type_dug_imovina",,,"Brodice, jahte i ost. plovila","Brodice, jahte i ost. plovila" +"03209","kp_rrif03209","kp_rrif0320","other","account_type_dug_imovina",,,"Ostala transportna sredstva i uređaji (gusjeničari, el. vozila, viljuškari, vagoni bicikli i dr.)","Ostala transportna sredstva i uređaji (gusjeničari, el. vozila, viljuškari, vagoni, elevatori, traktori, bicikli i dr.)" +"0321","kp_rrif0321","kp_rrif032","view","account_type_view",,,"Pokućstvo - inventar","Pokućstvo - inventar" +"03210","kp_rrif03210","kp_rrif0321","other","account_type_dug_imovina",,,"Uredsko pokućstvo, sagovi, zavjese i sl.","Uredsko pokućstvo, sagovi, zavjese i sl." +"03211","kp_rrif03211","kp_rrif0321","other","account_type_dug_imovina",,,"Inventar trgovine (police, pregrade, pultovi)","Inventar trgovine (police, pregrade, pultovi)" +"03212","kp_rrif03212","kp_rrif0321","other","account_type_dug_imovina",,,"Ugostiteljsko i hotelsko pokućstvo i inventar","Ugostiteljsko i hotelsko pokućstvo i inventar" +"03213","kp_rrif03213","kp_rrif0321","other","account_type_dug_imovina",,,"Ostalo pokućstvo i inventar","Ostalo pokućstvo i inventar" +"0322","kp_rrif0322","kp_rrif032","other","account_type_dug_imovina",,,"Pogonski i skladišni inventar (stalaže, zatvoreni ormari, skele, oplate, protupožarni aparati i sl.)","Pogonski i skladišni inventar (stalaže, zatvoreni ormari, skele, oplate, protupožarni aparati, zaštitna sredstva i sl.)" +"0323","kp_rrif0323","kp_rrif032","other","account_type_dug_imovina",,,"Alati, mjerni i kontrolni instrumenti i pomoćna oprema","Alati, mjerni i kontrolni instrumenti i pomoćna oprema" +"0324","kp_rrif0324","kp_rrif032","other","account_type_dug_imovina",,,"Audio i video aparati, kamere, parkir. rampe i sl.","Audio i video aparati, kamere, parkir. rampe i sl." +"0325","kp_rrif0325","kp_rrif032","other","account_type_dug_imovina",,,"Reklame (svjetleće), stupovi i sl.","Reklame (svjetleće), stupovi i sl." +"0326","kp_rrif0326","kp_rrif032","other","account_type_dug_imovina",,,"Inventar ustanova (aparati, kreveti i sl.)","Inventar ustanova (aparati, kreveti i sl.)" +"0327","kp_rrif0327","kp_rrif032","other","account_type_dug_imovina",,,"Ostali pogonski inventar,","Ostali pogonski inventar," +"0328","kp_rrif0328","kp_rrif032","other","account_type_dug_imovina",,,"Višegodišnja ambalaža","Višegodišnja ambalaža" +"0329","kp_rrif0329","kp_rrif032","other","account_type_dug_imovina",,,"Alati, inventar i vozila izvan uporabe","Alati, inventar i vozila izvan uporabe" +"033","kp_rrif033","kp_rrif03","view","account_type_view",,,"Pretporez koji se ne može odbiti (kao dio vrijed. os. aut.)","Pretporez koji se ne može odbiti (kao dio vrijed. os. aut.)" +"0330","kp_rrif0330","kp_rrif033","other","account_type_dug_imovina",,,"30% pretporeza od osobnih automobila (n. v. do 400.000,00 kn)","30% pretporeza od osobnih automobila (n. v. do 400.000,00 kn)" +"0331","kp_rrif0331","kp_rrif033","other","account_type_dug_imovina",,,"30% i 100% pretporeza od osobnih automobila (n. v. veće od 400.000,00 kn)","30% i 100% pretporeza od osobnih automobila (n. v. veće od 400.000,00 kn)" +"0332","kp_rrif0332","kp_rrif033","other","account_type_dug_imovina",,,"30% pretporeza od brodova, jahti i dr. (n.v. do 400.000,00 kn)","30% pretporeza od brodova, jahti i dr. (n.v. do 400.000,00 kn)" +"0333","kp_rrif0333","kp_rrif033","other","account_type_dug_imovina",,,"30% i 100% pretporeza od brodova, jahti i dr. (n.v. veće od 400.000,00 kn)","30% i 100% pretporeza od brodova, jahti i dr. (n.v. veće od 400.000,00 kn)" +"034","kp_rrif034","kp_rrif03","view","account_type_view",,,"Poljoprivredna oprema i mehanizacija","Poljoprivredna oprema i mehanizacija" +"0340","kp_rrif0340","kp_rrif034","other","account_type_dug_imovina",,,"Traktori, kombajni, prikolice, kosilice i sl.","Traktori, kombajni, prikolice kosilice i sl." +"0341","kp_rrif0341","kp_rrif034","other","account_type_dug_imovina",,,"Radni priključci (plugovi, beračice, freze, prskalice, sabirače i sl.)","Radni priključci (plugovi, beračice, freze, prskalice, sabirače i sl.)" +"0342","kp_rrif0342","kp_rrif034","other","account_type_dug_imovina",,,"Oprema za mljekarstvo (muzilice, separatori, police, spremnici i sl.)","Oprema za mljekarstvo (muzilice, separatori, police, spremnici i sl.)" +"0343","kp_rrif0343","kp_rrif034","other","account_type_dug_imovina",,,"Oprema ribarstva (kavezi, mreže, čamci i brodovi, pakirnice)","Oprema ribarstva (kavezi, mreže, čamci i brodovi, pakirnice)" +"0344","kp_rrif0344","kp_rrif034","other","account_type_dug_imovina",,,"Oprema vinogradarstva (bačve, filteri, preše, punionica)","Oprema vinogradarstva (bačve, filteri, preše, punionica)" +"0345","kp_rrif0345","kp_rrif034","other","account_type_dug_imovina",,,"Oprema vočarstva i maslinarstva","Oprema vočarstva i maslinarstva" +"0346","kp_rrif0346","kp_rrif034","other","account_type_dug_imovina",,,"Oprema stočarstva i pćelarstva","Oprema stočarstva i pćelarstva" +"0347","kp_rrif0347","kp_rrif034","other","account_type_dug_imovina",,,"Oprema mlinova","Oprema mlinova" +"0349","kp_rrif0349","kp_rrif034","other","account_type_dug_imovina",,,"Ostala oprema poljoprivrede, stočarstva i ribarstva","Ostala oprema poljoprivrede, stočarstva i ribarstva" +"035","kp_rrif035","kp_rrif03","view","account_type_view",,,"Ostala materijalna imovina","Ostala materijalna imovina" +"0350","kp_rrif0350","kp_rrif035","other","account_type_dug_imovina",,,"Umjetnine, slike i sl.","Umjetnine, slike i sl." +"0351","kp_rrif0351","kp_rrif035","other","account_type_dug_imovina",,,"Arhivski predmeti, makete i sl.","Arhivski predmeti, makete i sl." +"0352","kp_rrif0352","kp_rrif035","other","account_type_dug_imovina",,,"Knjige, karte, fotografije i sl.","Knjige, karte, fotografije i sl." +"0353","kp_rrif0353","kp_rrif035","other","account_type_dug_imovina",,,"Oldtimeri (automobili, brodovi i dr.)","Oldtimeri (automobili, brodovi i dr.)" +"0354","kp_rrif0354","kp_rrif035","other","account_type_dug_imovina",,,"Ostala materijalna imovina","Ostala materijalna imovina" +"036","kp_rrif036","kp_rrif03","view","account_type_view",,,"Predujmovi za materijalnu imovinu","Predujmovi za materijalnu imovinu" +"0360","kp_rrif0360","kp_rrif036","other","account_type_dug_imovina",,,"Predujmovi za postrojenja i opremu","Predujmovi za postrojenja i opremu" +"0361","kp_rrif0361","kp_rrif036","other","account_type_dug_imovina",,,"Predujmovi za alate, pogonski inventar i transportnu imovinu","Predujmovi za alate, pogonski inventar i transportnu imovinu" +"0367","kp_rrif0367","kp_rrif036","other","account_type_dug_imovina",,,"Predujam za ostalu imovinu","Predujam za ostalu imovinu" +"037","kp_rrif037","kp_rrif03","view","account_type_view",,,"Materijalna imovina u pripremi","Materijalna imovina u pripremi" +"0370","kp_rrif0370","kp_rrif037","other","account_type_dug_imovina",,,"Postrojenja u pripremi","Postrojenja u pripremi" +"0371","kp_rrif0371","kp_rrif037","other","account_type_dug_imovina",,,"Oprema u pripremi","Oprema u pripremi" +"0372","kp_rrif0372","kp_rrif037","other","account_type_dug_imovina",,,"Alati, pogonski inventar u pripremi","Alati, pogonski inventar u pripremi" +"0373","kp_rrif0373","kp_rrif037","other","account_type_dug_imovina",,,"Osobni automobili i transportna sredstva u pripremi","Osobni automobili i transportna sredstva u pripremi" +"0374","kp_rrif0374","kp_rrif037","other","account_type_dug_imovina",,,"Poljoprivredna oprema u pripremi","Poljoprivredna oprema u pripremi" +"0375","kp_rrif0375","kp_rrif037","other","account_type_dug_imovina",,,"Ostala imovina u pripremi","Ostala imovina u pripremi" +"038","kp_rrif038","kp_rrif03","view","account_type_view",,,"Vrijednosno usklađenje postrojenja i opreme","Vrijednosno usklađenje postrojenja i opreme" +"0380","kp_rrif0380","kp_rrif038","other","account_type_dug_imovina",,,"Vrijednosno usklađenje postrojenja","Vrijednosno usklađenje postrojenja" +"0381","kp_rrif0381","kp_rrif038","other","account_type_dug_imovina",,,"Vrijednosno usklađenje opreme","Vrijednosno usklađenje opreme" +"0382","kp_rrif0382","kp_rrif038","other","account_type_dug_imovina",,,"Vrijednosno usklađenje alata, pogonskog inventara i transportne imovine","Vrijednosno usklađenje alata, pogonskog inventara i transportne imovine" +"0383","kp_rrif0383","kp_rrif038","other","account_type_dug_imovina",,,"Vrijednosno usklađenje ostale mat. imovine","Vrijednosno usklađenje ostale mat. imovine" +"0384","kp_rrif0384","kp_rrif038","other","account_type_dug_imovina",,,"Vrijednosno usklađenje poljoprivredne opreme","Vrijednosno usklađenje poljoprivredne opreme" +"039","kp_rrif039","kp_rrif03","view","account_type_view",,,"Akumulirana amortizacija postrojenja i opreme","Akumulirana amortizacija postrojenja i opreme" +"0390","kp_rrif0390","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. postrojenja","Akumulirana amortiz. postrojenja" +"0391","kp_rrif0391","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. opreme","Akumulirana amortiz. opreme" +"0392","kp_rrif0392","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. alata, pogonskog inventara i transportne imovine","Akumulirana amortiz. alata, pogonskog inventara i transportne imovine" +"0393","kp_rrif0393","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. ostale mat. imovine","Akumulirana amortiz. ostale mat. imovine" +"0394","kp_rrif0394","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. poljoprivredne opreme","Akumulirana amortiz. poljoprivredne opreme" +"0395","kp_rrif0395","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. 30% pretporeza od osob. automobila","Akumulirana amortiz. 30% pretporeza od osob. automobila" +"0396","kp_rrif0396","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. 30% i 100% pretporeza od osob. automobila (n. v. veće od 400.000,00 kn)","Akumulirana amortiz. 30% i 100% pretporeza od osob. automobila (n. v. veće od 400.000,00 kn)" +"0397","kp_rrif0397","kp_rrif039","other","account_type_dug_imovina",,,"Akumulirana amortiz. 30% od pretporeza od brodova, jahti i dr. sred. za osobni prijevoz","Akumulirana amortiz. 30% od pretporeza od brodova, jahti i dr. sred. za osobni prijevoz" +"0398","kp_rrif0398","kp_rrif039","other","account_type_dug_imovina",,,"Akum. amortiz.30% i 100% pretporeza od brodova, jahti i dr. sred. za os. prijevoz(NV preko 400000,00kn)","Akumulirana amortiz. 30% i 100% pretporeza od brodova, jahti i dr. sred. za osobni prijevoz (n. v. veće od 400.000,00 kn)" +"0399","kp_rrif0399","kp_rrif039","other","account_type_dug_imovina",,,"Ostala akumulirana amortizacija","Ostala akumulirana amortizacija" +"04","kp_rrif04","kp_rrif0","view","account_type_view",,,"BIOLOŠKA IMOVINA","BIOLOŠKA IMOVINA" +"040","kp_rrif040","kp_rrif04","view","account_type_view",,,"Biološka imovina - bilje - višegodišnji nasadi","Biološka imovina - bilje - višegodišnji nasadi" +"0400","kp_rrif0400","kp_rrif040","other","account_type_dug_imovina",,,"Voćnjaci","Voćnjaci" +"0401","kp_rrif0401","kp_rrif040","other","account_type_dug_imovina",,,"Vinogradi","Vinogradi" +"0402","kp_rrif0402","kp_rrif040","other","account_type_dug_imovina",,,"Maslinici","Maslinici" +"0403","kp_rrif0403","kp_rrif040","other","account_type_dug_imovina",,,"Plantaže drveća i bilja (šume)","Plantaže drveća i bilja (šume)" +"0404","kp_rrif0404","kp_rrif040","other","account_type_dug_imovina",,,"Parkovi, zelenila, nasadi i cvijeće","Parkovi, zelenila, nasadi i cvijeće" +"0405","kp_rrif0405","kp_rrif040","other","account_type_dug_imovina",,,"Ulaganja u ostale višegodišnje nasade","Ulaganja u ostale višegodišnje nasade" +"041","kp_rrif041","kp_rrif04","view","account_type_view",,,"Biološka imovina - životinje - osnovno stado","Biološka imovina - životinje - osnovno stado" +"0410","kp_rrif0410","kp_rrif041","other","account_type_dug_imovina",,,"Goveda","Goveda" +"0411","kp_rrif0411","kp_rrif041","other","account_type_dug_imovina",,,"Konji","Konji" +"0412","kp_rrif0412","kp_rrif041","other","account_type_dug_imovina",,,"Mazge, magarci i mule","Mazge, magarci i mule" +"0413","kp_rrif0413","kp_rrif041","other","account_type_dug_imovina",,,"Svinje","Svinje" +"0414","kp_rrif0414","kp_rrif041","other","account_type_dug_imovina",,,"Ovce i koze","Ovce i koze" +"0415","kp_rrif0415","kp_rrif041","other","account_type_dug_imovina",,,"Perad","Perad" +"0416","kp_rrif0416","kp_rrif041","other","account_type_dug_imovina",,,"Ribe","Ribe" +"0417","kp_rrif0417","kp_rrif041","other","account_type_dug_imovina",,,"Pčelinja društva","Pčelinja društva" +"0418","kp_rrif0418","kp_rrif041","other","account_type_dug_imovina",,,"Stado divljači","Stado divljači, kunića, nutrija (za rasplod)" +"0419","kp_rrif0419","kp_rrif041","other","account_type_dug_imovina",,,"Ostale nespomenute životinje (psi, ptice i dr.)","Ostale nespomenute životinje (psi, ptice i dr.)" +"046","kp_rrif046","kp_rrif04","view","account_type_view",,,"Predujmovi za biološku imovinu","Predujmovi za biološku imovinu" +"0460","kp_rrif0460","kp_rrif046","other","account_type_dug_imovina",,,"Predujmovi za višegodišnje nasade","Predujmovi za višegodišnje nasade" +"0461","kp_rrif0461","kp_rrif046","other","account_type_dug_imovina",,,"Predujmovi na nabavu životinja","Predujmovi na nabavu životinja" +"047","kp_rrif047","kp_rrif04","view","account_type_view",,,"Biološka imovina u pripremi","Biološka imovina u pripremi" +"0470","kp_rrif0470","kp_rrif047","other","account_type_dug_imovina",,,"Višegodišnji nasadi u pripremi","Višegodišnji nasadi u pripremi" +"0471","kp_rrif0471","kp_rrif047","other","account_type_dug_imovina",,,"Životinje (osnovno stado) u nabavi","Životinje (osnovno stado) u nabavi" +"048","kp_rrif048","kp_rrif04","view","account_type_view",,,"Vrijednosno usklađenje biološke imovine","Vrijednosno usklađenje biološke imovine" +"0480","kp_rrif0480","kp_rrif048","other","account_type_dug_imovina",,,"Vrijednosno usklađenje višegodišnjih nasada","Vrijednosno usklađenje višegodišnjih nasada" +"0481","kp_rrif0481","kp_rrif048","other","account_type_dug_imovina",,,"Vrijednosno usklađenje životinja (osnovnog stada)","Vrijednosno usklađenje životinja (osnovnog stada)" +"049","kp_rrif049","kp_rrif04","view","account_type_view",,,"Akumulirana amortizacija biološke imovine","Akumulirana amortizacija biološke imovine" +"0490","kp_rrif0490","kp_rrif049","other","account_type_dug_imovina",,,"Akumulirana amortiz. višegodišnjih nasada","Akumulirana amortiz. višegodišnjih nasada" +"0491","kp_rrif0491","kp_rrif049","other","account_type_dug_imovina",,,"Akumulirana amortiz. životinja (osnovnog stada)","Akumulirana amortiz. životinja (osnovnog stada)" +"05","kp_rrif05","kp_rrif0","view","account_type_view",,,"ULAGANJA U NEKRETNINE","ULAGANJA U NEKRETNINE" +"050","kp_rrif050","kp_rrif05","view","account_type_view",,,"Ulaganja u nekretnine - zemljišta","Ulaganja u nekretnine - zemljišta" +"0500","kp_rrif0500","kp_rrif050","other","account_type_dug_imovina",,,"Ulaganja u nekretnine - zemljišta-a1","Ulaganja u nekretnine - zemljišta-Analitika 1" +"051","kp_rrif051","kp_rrif05","view","account_type_view",,,"Ulaganja u nekretnine - građevine","Ulaganja u nekretnine - građevine" +"0510","kp_rrif0510","kp_rrif051","other","account_type_dug_imovina",,,"Građevine u najmovima (poslovne zgrade, stanovi, apartmani, kuće)","Građevine u najmovima (poslovne zgrade, stanovi, apartmani, kuće)" +"0511","kp_rrif0511","kp_rrif051","other","account_type_dug_imovina",,,"Građevine izvan uporabe (zgrade, stanovi, apartmani, kuće)","Građevine izvan uporabe (zgrade, stanovi, apartmani, kuće)" +"056","kp_rrif056","kp_rrif05","view","account_type_view",,,"Predujmovi za ulaganja u nekretnine","Predujmovi za ulaganja u nekretnine" +"0560","kp_rrif0560","kp_rrif056","other","account_type_dug_imovina",,,"Predujam za ulaganja u zemljište","Predujam za ulaganja u zemljište" +"0561","kp_rrif0561","kp_rrif056","other","account_type_dug_imovina",,,"Predujam za ulaganje u građevine","Predujam za ulaganje u građevine" +"057","kp_rrif057","kp_rrif05","view","account_type_view",,,"Ulaganja u nekretnine u pripremi","Ulaganja u nekretnine u pripremi" +"0570","kp_rrif0570","kp_rrif057","other","account_type_dug_imovina",,,"Ulaganja u zemljišta u nabavi","Ulaganja u zemljišta u nabavi" +"0571","kp_rrif0571","kp_rrif057","other","account_type_dug_imovina",,,"Ulaganja u građevine u nabavi","Ulaganja u građevine u nabavi" +"0572","kp_rrif0572","kp_rrif057","other","account_type_dug_imovina",,,"Ulaganja u građevine u izgradnji","Ulaganja u građevine u izgradnji" +"058","kp_rrif058","kp_rrif05","view","account_type_view",,,"Vrijednosno usklađenje ulaganja u nekretnine","Vrijednosno usklađenje ulaganja u nekretnine" +"0580","kp_rrif0580","kp_rrif058","other","account_type_dug_imovina",,,"Vrijednosno usklađenje ulaganja u zemljište","Vrijednosno usklađenje ulaganja u zemljište" +"0581","kp_rrif0581","kp_rrif058","other","account_type_dug_imovina",,,"Vrijednosno usklađenje ulaganja u građevine","Vrijednosno usklađenje ulaganja u građevine" +"059","kp_rrif059","kp_rrif05","view","account_type_view",,,"Akumulirana amortizacija ulaganja u građevine","Akumulirana amortizacija ulaganja u građevine" +"0590","kp_rrif0590","kp_rrif059","other","account_type_dug_imovina",,,"Akumulirana amortizacija ulaganja u građevine-a1","Akumulirana amortizacija ulaganja u građevine-Analitika 1" +"06","kp_rrif06","kp_rrif0","view","account_type_view",,,"DUGOTRAJNA FINANCIJSKA IMOVINA (s povratom dužim od jedne godine)","DUGOTRAJNA FINANCIJSKA IMOVINA (s povratom dužim od jedne godine)" +"060","kp_rrif060","kp_rrif06","view","account_type_view",,,"Udjeli (dionice) kod povezanih poduzetnika (s više od 20% udjela)","Udjeli (dionice) kod povezanih poduzetnika (s više od 20% udjela)" +"0600","kp_rrif0600","kp_rrif060","other","account_type_dug_imovina",,,"Udjel u dionicama (s više od 20%)","Udjel u dionicama (s više od 20%)" +"0601","kp_rrif0601","kp_rrif060","other","account_type_dug_imovina",,,"Udjel u kapitalu d.o.o.-a (s više od 20%)","Udjel u kapitalu d.o.o.-a (s više od 20%)" +"0602","kp_rrif0602","kp_rrif060","other","account_type_dug_imovina",,,"Udjeli u komanditnom društvu","Udjeli u komanditnom društvu" +"0603","kp_rrif0603","kp_rrif060","other","account_type_dug_imovina",,,"Udjeli u društvima u inozemstvu (s više od 20%)","Udjeli u društvima u inozemstvu (s više od 20%)" +"0604","kp_rrif0604","kp_rrif060","other","account_type_dug_imovina",,,"Osnivački udjeli u ustanovama","Osnivački udjeli u ustanovama" +"0605","kp_rrif0605","kp_rrif060","other","account_type_dug_imovina",,,"Udjeli u zadrugama","Udjeli u zadrugama" +"0606","kp_rrif0606","kp_rrif060","other","account_type_dug_imovina",,,"Udio u društvu s uzajamnim udjelima","Udio u društvu s uzajamnim udjelima" +"0607","kp_rrif0607","kp_rrif060","other","account_type_dug_imovina",,,"Ulaganje u kapitalne pričuve (neupisani kapital)","Ulaganje u kapitalne pričuve (neupisani kapital)" +"061","kp_rrif061","kp_rrif06","view","account_type_view",,,"Dani zajmovi povezanim poduzetnicima (analitika po društvima u kojima se ima više od 20% udjela)","Dani zajmovi povezanim poduzetnicima (analitika po društvima u kojima se ima više od 20% udjela)" +"0610","kp_rrif0610","kp_rrif061","other","account_type_dug_imovina",,,"Dani zajmovi povezanim poduzetnicima (analitika po društvima u kojima se ima više od 20% udjela)-a1","Dani zajmovi povezanim poduzetnicima (analitika po društvima u kojima se ima više od 20% udjela)-Analitika 1" +"062","kp_rrif062","kp_rrif06","view","account_type_view",,,"Sudjelujući interesi (udjeli)","Sudjelujući interesi (udjeli)" +"0620","kp_rrif0620","kp_rrif062","other","account_type_dug_imovina",,,"Udjel u dioničkom kapitalu (do 20% udjela - analitika po društvima)","Udjel u dioničkom kapitalu (do 20% udjela - analitika po društvima)" +"0621","kp_rrif0621","kp_rrif062","other","account_type_dug_imovina",,,"Udjel u kapitalu d.o.o. (do 20% udjela)","Udjel u kapitalu d.o.o. (do 20% udjela)" +"0622","kp_rrif0622","kp_rrif062","other","account_type_dug_imovina",,,"Udjeli u društvima u inozemstvu (do 20% udjela)","Udjeli u društvima u inozemstvu (do 20% udjela)" +"0623","kp_rrif0623","kp_rrif062","other","account_type_dug_imovina",,,"Ulaganje u dionice i udjele radi preprodaje","Ulaganje u dionice i udjele radi preprodaje" +"0624","kp_rrif0624","kp_rrif062","other","account_type_dug_imovina",,,"Potraživanja za udio u dobitku (analitika po udjelima)","Potraživanja za udio u dobitku (analitika po udjelima)" +"063","kp_rrif063","kp_rrif06","view","account_type_view",,,"Zajmovi dani poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela u T.K.)","Zajmovi dani poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela u T.K.)" +"0630","kp_rrif0630","kp_rrif063","other","account_type_dug_imovina",,,"Zajmovi dani poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela u T.K.)-a1","Zajmovi dani poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela u T.K.)-Analitika 1" +"064","kp_rrif064","kp_rrif06","view","account_type_view",,,"Ulaganja u vrijednosne papire (dugotrajne)","Ulaganja u vrijednosne papire (dugotrajne)" +"0640","kp_rrif0640","kp_rrif064","other","account_type_dug_imovina",,,"Ulaganja u mjenice, zadužnice (kupljene)","Ulaganja u mjenice, zadužnice (kupljene)" +"0641","kp_rrif0641","kp_rrif064","other","account_type_dug_imovina",,,"Ulaganja u državne obveznice","Ulaganja u državne obveznice" +"0642","kp_rrif0642","kp_rrif064","other","account_type_dug_imovina",,,"Dugotrajna ulaganja u obveznice društva","Dugotrajna ulaganja u obveznice društva" +"0643","kp_rrif0643","kp_rrif064","other","account_type_dug_imovina",,,"Dugotrajna ulaganja u blagajničke zapise","Dugotrajna ulaganja u blagajničke zapise" +"0644","kp_rrif0644","kp_rrif064","other","account_type_dug_imovina",,,"Dugotrajna ulaganja u opcije, certifikate i sl.","Dugotrajna ulaganja u opcije, certifikate i sl." +"0645","kp_rrif0645","kp_rrif064","other","account_type_dug_imovina",,,"Ulaganja u robne ugovore","Ulaganja u robne ugovore" +"0646","kp_rrif0646","kp_rrif064","view","account_type_dug_imovina",,,"Ulaganja u ostale vrijednosne papire","Ulaganja ostale u vrijednosne papire" +"06460","kp_rrif06460","kp_rrif0646","other","account_type_dug_imovina",,,"Ulaganja u vrijednosne papire po fer vrijednosti","Ulaganja u vrijednosne papire po fer vrijednosti" +"06461","kp_rrif06461","kp_rrif0646","other","account_type_dug_imovina",,,"Vrijednosni papiri namijenjeni prodaji (do dospijeća)","Vrijednosni papiri namijenjeni prodaji (do dospijeća)" +"0648","kp_rrif0648","kp_rrif064","other","account_type_dug_imovina",,,"Ulaganje u vrijed. pap. raspoložive za prodaju","Ulaganje u vrijed. pap. raspoložive za prodaju" +"0649","kp_rrif0649","kp_rrif064","other","account_type_dug_imovina",,,"Nezarađeni prihodi u financijskim instrumentima","Nezarađeni prihodi u financijskim instrumentima" +"065","kp_rrif065","kp_rrif06","view","account_type_view",,,"Dani zajmovi, depoziti i sl.","Dani zajmovi, depoziti i sl." +"0650","kp_rrif0650","kp_rrif065","view","account_type_view",,,"Dani dugotrajni zajmovi","Dani dugotrajni zajmovi" +"06500","kp_rrif06500","kp_rrif0650","other","account_type_dug_imovina",,,"Dani zajmovi vanjskim pravnim osobama (nepovezanim)","Dani zajmovi vanjskim pravnim osobama (nepovezanim)" +"06501","kp_rrif06501","kp_rrif0650","other","account_type_dug_imovina",,,"Dani zajmovi vanjskim fizičkim osobama - obrtnicima","Dani zajmovi vanjskim fizičkim osobama - obrtnicima" +"06502","kp_rrif06502","kp_rrif0650","other","account_type_dug_imovina",,,"Dani zajmovi kooperantima","Dani zajmovi kooperantima" +"06503","kp_rrif06503","kp_rrif0650","other","account_type_dug_imovina",,,"Dani zajmovi direktoru, ortacima, menadžerima, zaposlenicima","Dani zajmovi direktoru, ortacima, menadžerima, zaposlenicima" +"06504","kp_rrif06504","kp_rrif0650","other","account_type_dug_imovina",,,"Oročenja u bankama","Oročenja u bankama" +"06505","kp_rrif06505","kp_rrif0650","other","account_type_dug_imovina",,,"Financijski zajmovi dani u inozemstvo","Financijski zajmovi dani u inozemstvo" +"06509","kp_rrif06509","kp_rrif0650","other","account_type_dug_imovina",,,"Ostali dugotrajni zajmovi","Ostali dugotrajni zajmovi" +"0651","kp_rrif0651","kp_rrif065","view","account_type_view",,,"Depoziti dugotrajni","Depoziti dugotrajni" +"06510","kp_rrif06510","kp_rrif0651","other","account_type_dug_imovina",,,"Depoziti iz poslovnih aktivnosti","Depoziti iz poslovnih aktivnosti" +"06511","kp_rrif06511","kp_rrif0651","other","account_type_dug_imovina",,,"Depoziti kod osiguravajućih društava","Depoziti kod osiguravajućih društava" +"06512","kp_rrif06512","kp_rrif0651","other","account_type_dug_imovina",,,"Depoziti u poslovnim bankama","Depoziti u poslovnim bankama" +"06513","kp_rrif06513","kp_rrif0651","other","account_type_dug_imovina",,,"Depoziti na carini (garancija špeditera)","Depoziti na carini (garancija špeditera)" +"06514","kp_rrif06514","kp_rrif0651","other","account_type_dug_imovina",,,"Sudski depoziti","Sudski depoziti" +"0652","kp_rrif0652","kp_rrif065","view","account_type_view",,,"Kaucije i kapare","Kaucije i kapare" +"06520","kp_rrif06520","kp_rrif0652","other","account_type_dug_imovina",,,"Kaucije za obveze","Kaucije za obveze" +"06521","kp_rrif06521","kp_rrif0652","other","account_type_dug_imovina",,,"Kaucije iz kupoprodajnih poslova","Kaucije iz kupoprodajnih poslova" +"06522","kp_rrif06522","kp_rrif0652","other","account_type_dug_imovina",,,"Kaucije za plaćanja","Kaucije za plaćanja" +"06523","kp_rrif06523","kp_rrif0652","other","account_type_dug_imovina",,,"Dane kapare i osiguranja","Dane kapare i osiguranja" +"066","kp_rrif066","kp_rrif06","view","account_type_view",,,"Ulaganja koja se obračunavaju metodom udjela","Ulaganja koja se obračunavaju metodom udjela" +"0660","kp_rrif0660","kp_rrif066","other","account_type_dug_imovina",,,"Ulaganja (udjeli) koji su raspoloživi za prodaju (dugotrajno ulaganje -MRS28.t.11. i 13. te MRS39.t.9.)","Ulaganja (udjeli) koji su raspoloživi za prodaju (dugotrajno ulaganje - MRS 28. t. 11. i 13. te MRS 39. t. 9.)" +"067","kp_rrif067","kp_rrif06","view","account_type_view",,,"Ostala dugotrajna financijska imovina","Ostala dugotrajna financijska imovina" +"0670","kp_rrif0670","kp_rrif067","other","account_type_dug_imovina",,,"Ulaganja u investicijske fondove (s rokom dužim od 1 god.)","Ulaganja u investicijske fondove (s rokom dužim od 1 god.)" +"0672","kp_rrif0672","kp_rrif067","other","account_type_dug_imovina",,,"Ostala nespomenuta dugoročna ulaganja","Ostala nespomenuta dugoročna ulaganja" +"068","kp_rrif068","kp_rrif06","view","account_type_view",,,"Vrijednosno usklađenje financijske imovine - dugotrajne (analitika prema oblicima imovine u usklađenju)","Vrijednosno usklađenje financijske imovine - dugotrajne (analitika prema oblicima imovine u usklađenju)" +"0680","kp_rrif0680","kp_rrif068","other","account_type_dug_imovina",,,"Vrijednosno usklađenje financijske imovine - dugotrajne (analitika prema oblicima imovine u usklađenju)-a1","Vrijednosno usklađenje financijske imovine - dugotrajne (analitika prema oblicima imovine u usklađenju)-Analitika 1" +"069","kp_rrif069","kp_rrif06","view","account_type_view",,,"Nezarađene kamate u kreditima i sl.","Nezarađene kamate u kreditima i sl." +"0690","kp_rrif0690","kp_rrif069","other","account_type_dug_imovina",,,"Nezarađene kamate u kreditima i sl.-a1","Nezarađene kamate u kreditima i sl.-Analitika 1" +"07","kp_rrif07","kp_rrif0","view","account_type_view",,,"POTRAŽIVANJA (dulja od jedne godine)","POTRAŽIVANJA (dulja od jedne godine)" +"070","kp_rrif070","kp_rrif07","view","account_type_view",,,"Potraživanja od povezanih poduzetnika","Potraživanja od povezanih poduzetnika" +"0700","kp_rrif0700","kp_rrif070","other","account_type_dug_imovina",,,"Potraživanja od povezanih društava za isporuke dobara i usluga","Potraživanja od povezanih društava za isporuke dobara i usluga" +"0701","kp_rrif0701","kp_rrif070","other","account_type_dug_imovina",,,"Potraživanja od povezanih društava za dana sredstva na dugoročnu posudbu (osim novca)","Potraživanja od povezanih društava za dana sredstva na dugoročnu posudbu (osim novca)" +"0702","kp_rrif0702","kp_rrif070","other","account_type_dug_imovina",,,"Potraživanja od zadrugara, kooperanata i sl.","Potraživanja od zadrugara, kooperanata i sl." +"071","kp_rrif071","kp_rrif07","view","account_type_view",,,"Potraživanja s osnove prodaje na kredit","Potraživanja s osnove prodaje na kredit" +"0710","kp_rrif0710","kp_rrif071","other","account_type_dug_imovina",,,"Potraživanja s osnove prodaje na robni kredit","Potraživanja s osnove prodaje na robni kredit" +"0711","kp_rrif0711","kp_rrif071","other","account_type_dug_imovina",,,"Potraživanja s osnove prodaje na robni kredit u inozemstvu","Potraživanja s osnove prodaje na robni kredit u inozemstvu" +"0712","kp_rrif0712","kp_rrif071","other","account_type_dug_imovina",,,"Potraživanja za prodane usluge na kredit","Potraživanja za prodane usluge na kredit" +"0713","kp_rrif0713","kp_rrif071","other","account_type_dug_imovina",,,"Potraživanje za dugotr. imovinu prodanu na kredit","Potraživanje za dugotr. imovinu prodanu na kredit" +"0714","kp_rrif0714","kp_rrif071","other","account_type_dug_imovina",,,"Potraživanja za prodaju u financijskom lizingu","Potraživanja za prodaju u financijskom lizingu" +"0715","kp_rrif0715","kp_rrif071","other","account_type_dug_imovina",,,"Potraživanja za prodani udjel na kredit","Potraživanja za prodani udjel na kredit" +"0716","kp_rrif0716","kp_rrif071","other","account_type_dug_imovina",,,"Potraživanja za prodaju na potrošački kredit","Potraživanja za prodaju na potrošački kredit" +"0717","kp_rrif0717","kp_rrif071","other","account_type_dug_imovina",,,"Ostala potraživanja iz prodaje na kredit","Ostala potraživanja iz prodaje na kredit" +"072","kp_rrif072","kp_rrif07","view","account_type_view",,,"Potraživanja iz faktoringa","Potraživanja iz faktoringa" +"0720","kp_rrif0720","kp_rrif072","other","account_type_dug_imovina",,,"Potraživanja iz faktoringa-a1","Potraživanja iz faktoringa-Analitika 1" +"073","kp_rrif073","kp_rrif07","view","account_type_view",,,"Potraživanja za jamčevine","Potraživanja za jamčevine" +"0730","kp_rrif0730","kp_rrif073","other","account_type_dug_imovina",,,"Potraživanja za jamčevine iz operativnog lizinga","Potraživanja za jamčevine iz operativnog lizinga" +"0731","kp_rrif0731","kp_rrif073","other","account_type_dug_imovina",,,"Jamstvo za dobro izvedene radove","Jamstvo za dobro izvedene radove" +"0732","kp_rrif0732","kp_rrif073","other","account_type_dug_imovina",,,"Jamčevine iz natječaja","Jamčevine iz natječaja" +"0733","kp_rrif0733","kp_rrif073","other","account_type_dug_imovina",,,"Jamčevine za štete","Jamčevine za štete" +"074","kp_rrif074","kp_rrif07","view","account_type_view",,,"Potraživanja u sporu i rizična potraživanja","Potraživanja u sporu i rizična potraživanja" +"0740","kp_rrif0740","kp_rrif074","other","account_type_dug_imovina",,,"Potraživanja u sporu i rizična potraživanja-a1","Potraživanja u sporu i rizična potraživanja-Analitika 1" +"075","kp_rrif075","kp_rrif07","view","account_type_view",,,"Potraživanja za predujmove za usluge","Potraživanja za predujmove za usluge" +"0750","kp_rrif0750","kp_rrif075","other","account_type_dug_imovina",,,"Potraživanja za predujmove za usluge-a1","Potraživanja za predujmove za usluge-Analitika 1" +"076","kp_rrif076","kp_rrif07","view","account_type_view",,,"Ostala potraživanja - dugotrajna","Ostala potraživanja - dugotrajna" +"0760","kp_rrif0760","kp_rrif076","other","account_type_dug_imovina",,,"Potraživanja od radnika","Potraživanja od radnika" +"0761","kp_rrif0761","kp_rrif076","other","account_type_dug_imovina",,,"Potraživanja od članova društva","Potraživanja od članova društva" +"0762","kp_rrif0762","kp_rrif076","other","account_type_dug_imovina",,,"Potraživanja iz ortaštva","Potraživanja iz ortaštva" +"078","kp_rrif078","kp_rrif07","view","account_type_view",,,"Vrijednosno usklađivanje dugotrajnih potraživanja","Vrijednosno usklađivanje dugotrajnih potraživanja" +"0780","kp_rrif0780","kp_rrif078","other","account_type_dug_imovina",,,"Vrijednosno usklađivanje dugotrajnih potraživanja-a1","Vrijednosno usklađivanje dugotrajnih potraživanja-Analitika 1" +"079","kp_rrif079","kp_rrif07","view","account_type_view",,,"Potraživanja za nezarađenu kamatu","Potraživanja za nezarađenu kamatu" +"0790","kp_rrif0790","kp_rrif079","other","account_type_dug_imovina",,,"Potraživanja za nezarađenu kamatu-a1","Potraživanja za nezarađenu kamatu-Analitika 1" +"08","kp_rrif08","kp_rrif0","view","account_type_view",,,"ODGOĐENA POREZNA IMOVINA","ODGOĐENA POREZNA IMOVINA" +"080","kp_rrif080","kp_rrif08","view","account_type_view",,,"Odgođena privremena razlika poreza na dobitak (analitika po godinama)","Odgođena privremena razlika poreza na dobitak (analitika po godinama)" +"0800","kp_rrif080","kp_rrif08","view","account_type_view",,,"Odgođena porezna imovina s osnove poreznog gubitka","Odgođena porezna imovina s osnove poreznog gubitka" +"08000","kp_rrif08000","kp_rrif080","other","account_type_dug_imovina",,,"Odgođena porezna imovina s osnove poreznog gubitka-a1","Odgođena porezna imovina s osnove poreznog gubitka-Analitika 1" +"0801","kp_rrif081","kp_rrif080","view","account_type_view",,,"Odgođena porezna imovina s osnove povećane amortizacije","Odgođena porezna imovina s osnove povećane amortizacije" +"08010","kp_rrif08010","kp_rrif081","other","account_type_dug_imovina",,,"Odgođena porezna imovina s osnove povećane amortizacije-a1","Odgođena porezna imovina s osnove povećane amortizacije -Analitika 1" +"081","kp_rrif081","kp_rrif08","view","account_type_view",,,"Ostala odgođena porezna imovina","Ostala odgođena porezna imovina" +"0810","kp_rrif0810","kp_rrif081","other","account_type_dug_imovina",,,"Ostala odgođena porezna imovina-a1","Ostala odgođena porezna imovina-Analitika 1" +"1","kp_rrif1","kp_rrif","view","account_type_view",,,"NOVAC, KRATKOTRAJNA FINANCIJSKA IMOVINA, KRATKOTRAJNA POTRAŽIVANJA, TROŠKOVI I PRIHOD BUDUĆEG RAZDOBLJA","NOVAC, KRATKOTRAJNA FINANCIJSKA IMOVINA, KRATKOTRAJNA POTRAŽIVANJA, TE TROŠKOVI I PRIHOD BUDUĆEG RAZDOBLJA" +"10","kp_rrif10","kp_rrif1","view","account_type_view",,,"NOVAC U BANKAMA I BLAGAJNAMA","NOVAC U BANKAMA I BLAGAJNAMA" +"100","kp_rrif100","kp_rrif10","view","account_type_view",,,"Transakcijski računi u bankama","Transakcijski računi u bankama" +"1000","kp_rrif1000","kp_rrif100","view","account_type_view",,,"Transakcijski u banci (analitika po računima u bankama i štedionicama)","Transakcijski u banci (analitika po računima u bankama i štedionicama)" +"1007","kp_rrif1007","kp_rrif100","liquidity","account_type_kratk_imovina",,,"Podračun društva","Podračun društva" +"1008","kp_rrif1008","kp_rrif100","liquidity","account_type_kratk_imovina",,,"Račun društva u osnivanju","Račun društva u osnivanju" +"1009","kp_rrif1009","kp_rrif100","liquidity","account_type_kratk_imovina",,,"Žiro-račun prijelazni konto","Žiro-račun prijelazni konto" +"101","kp_rrif101","kp_rrif10","view","account_type_view",,,"Otvoreni akreditiv u domaćoj banci","Otvoreni akreditiv u domaćoj banci" +"1010","kp_rrif1010","kp_rrif101","liquidity","account_type_kratk_imovina",,,"Otvoreni akreditiv u domaćoj banci-a1","Otvoreni akreditiv u domaćoj banci-Analitika 1" +"102","kp_rrif102","kp_rrif10","view","account_type_view",,,"Blagajne","Blagajne" +"1020","kp_rrif1020","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Glavna blagajna (uključivo i plemenitih metala)","Glavna blagajna (uključivo i plemenitih metala)" +"1021","kp_rrif1021","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Blagajna vrijednosnica (poštanskih, taksenih maraka i dr. vrijednosnica)","Blagajna vrijednosnica (poštanskih, taksenih maraka i dr. vrijednosnica)" +"1022","kp_rrif1022","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Blagajna prodavaonice","Blagajna prodavaonice" +"1023","kp_rrif1023","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Blagajna servisa","Blagajna servisa" +"1024","kp_rrif1024","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Blagajna recepcije (šanka)","Blagajna recepcije (šanka)" +"1025","kp_rrif1025","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Blagajna radne jedinice","Blagajna radne jedinice" +"1028","kp_rrif1028","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Blagajna za ostalo","Blagajna za ostalo" +"1029","kp_rrif1029","kp_rrif102","liquidity","account_type_kratk_imovina",,,"Prijelazni račun blagajne prodavaonice","Prijelazni račun blagajne prodavaonice" +"103","kp_rrif103","kp_rrif10","view","account_type_view",,,"Devizni računi","Devizni računi" +"1030","kp_rrif1030","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Devizni račun u domaćoj banci (analitika po devizama)","Devizni račun u domaćoj banci (analitika po devizama)" +"1031","kp_rrif1031","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Devizni račun u inozemnoj banci (u EU)","Devizni račun u inozemnoj banci (u EU)" +"1032","kp_rrif1032","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Devizni račun reeksportnih poslova","Devizni račun reeksportnih poslova" +"1034","kp_rrif1034","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Devizni račun investicijskih radova","Devizni račun investicijskih radova" +"1035","kp_rrif1035","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Devizni račun poslovne jedinice u inozemstvu","Devizni račun poslovne jedinice u inozemstvu" +"1036","kp_rrif1036","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Devizni račun u slobodnoj zoni","Devizni račun u slobodnoj zoni" +"1037","kp_rrif1037","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Nerezidentski devizni račun","Nerezidentski devizni račun" +"1038","kp_rrif1038","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Devizni račun terminskih poslova","Devizni račun terminskih poslova" +"1039","kp_rrif1039","kp_rrif103","liquidity","account_type_kratk_imovina",,,"Prijelazni devizni račun","Prijelazni devizni račun" +"104","kp_rrif104","kp_rrif10","view","account_type_view",,,"Otvoreni akreditiv u stranim valutama","Otvoreni akreditiv u stranim valutama" +"1040","kp_rrif1040","kp_rrif104","liquidity","account_type_kratk_imovina",,,"Otvoreni devizni akreditiv u domaćoj banci","Otvoreni devizni akreditiv u domaćoj banci" +"1041","kp_rrif1041","kp_rrif104","liquidity","account_type_kratk_imovina",,,"Otvoreni akreditiv u inozemnoj banci","Otvoreni akreditiv u inozemnoj banci" +"1042","kp_rrif1042","kp_rrif104","liquidity","account_type_kratk_imovina",,,"Ecsrow račun","Ecsrow račun" +"105","kp_rrif105","kp_rrif10","view","account_type_view",,,"Devizna blagajna","Devizna blagajna" +"1050","kp_rrif1050","kp_rrif105","liquidity","account_type_kratk_imovina",,,"Glavna devizna blagajna","Glavna devizna blagajna" +"1051","kp_rrif1051","kp_rrif105","liquidity","account_type_kratk_imovina",,,"Devizna blagajna za službena putovanja u inozemstvo","Devizna blagajna za službena putovanja u inozemstvo" +"1052","kp_rrif1052","kp_rrif105","liquidity","account_type_kratk_imovina",,,"Devizna blagajna za troškove prijevoza robe u inozemstvo","Devizna blagajna za troškove prijevoza robe u inozemstvo" +"1053","kp_rrif1053","kp_rrif105","liquidity","account_type_kratk_imovina",,,"Devizna blagajna za mjenjačke poslove","Devizna blagajna za mjenjačke poslove" +"1055","kp_rrif1055","kp_rrif105","liquidity","account_type_kratk_imovina",,,"Devizna blagajna za razne isplate","Devizna blagajna za razne isplate" +"106","kp_rrif106","kp_rrif10","view","account_type_view",,,"Novac za kupnju deviza","Novac za kupnju deviza" +"1060","kp_rrif1060","kp_rrif106","liquidity","account_type_kratk_imovina",,,"Novac za kupnju deviza-a1","Novac za kupnju deviza-Analitika 1" +"108","kp_rrif108","kp_rrif10","view","account_type_view",,,"Ostala novčana sredstva","Ostala novčana sredstva" +"1080","kp_rrif1080","kp_rrif108","liquidity","account_type_kratk_imovina",,,"Ostala novčana sredstva-a1","Ostala novčana sredstva-Analitika 1" +"109","kp_rrif109","kp_rrif10","view","account_type_view",,,"Vrijednosno usklađenje depozita u bankama","Vrijednosno usklađenje depozita u bankama" +"1090","kp_rrif1090","kp_rrif109","liquidity","account_type_kratk_imovina",,,"Vrijednosno usklađenje depozita u bankama-a1","Vrijednosno usklađenje depozita u bankama-Analitika 1" +"11","kp_rrif11","kp_rrif1","view","account_type_view",,,"KRATKOTRAJNA FINANCIJSKA IMOVINA (do jedne godine)","KRATKOTRAJNA FINANCIJSKA IMOVINA (do jedne godine)" +"110","kp_rrif110","kp_rrif11","view","account_type_view",,,"Udjeli (dionice) u povezanim poduzetnicima","Udjeli (dionice) u povezanim poduzetnicima" +"1100","kp_rrif1100","kp_rrif110","other","account_type_kratk_imovina",,,"Udjeli u povezanim društvima (s više od 20%)","Udjeli u povezanim društvima (s više od 20%)" +"1101","kp_rrif1101","kp_rrif110","other","account_type_kratk_imovina",,,"Dionički udio u d.d. (s više od 20%)","Dionički udio u d.d. (s više od 20%)" +"1102","kp_rrif1102","kp_rrif110","other","account_type_kratk_imovina",,,"Ulaganje u dionice radi preprodaje (iz udjela više od 20%)","Ulaganje u dionice radi preprodaje (iz udjela više od 20%)" +"111","kp_rrif111","kp_rrif11","view","account_type_view",,,"Dani zajmovi povezanim poduzetnicima","Dani zajmovi povezanim poduzetnicima" +"1110","kp_rrif1110","kp_rrif111","other","account_type_kratk_imovina",,,"Kratkoročni zajam povezanom društvu","Kratkoročni zajam povezanom društvu" +"1111","kp_rrif1111","kp_rrif111","other","account_type_kratk_imovina",,,"Kratkoročni zajam povezanom društvu u inozemstvu","Kratkoročni zajam povezanom društvu u inozemstvu" +"1112","kp_rrif1112","kp_rrif111","other","account_type_kratk_imovina",,,"Zajmovi dani vlastitim podružnicama","Zajmovi dani vlastitim podružnicama" +"1113","kp_rrif1113","kp_rrif111","other","account_type_kratk_imovina",,,"Zajmovi dani ustanovama i školama (kojih je društvo osnivač)","Zajmovi dani ustanovama i školama (kojih je društvo osnivač)" +"112","kp_rrif112","kp_rrif11","view","account_type_view",,,"Sudjelujući interesi (udjeli)","Sudjelujući interesi (udjeli)" +"1120","kp_rrif1120","kp_rrif112","other","account_type_kratk_imovina",,,"Udjeli (do 20%) u društvima kapitala","Udjeli (do 20%) u društvima kapitala" +"1121","kp_rrif1121","kp_rrif112","other","account_type_kratk_imovina",,,"Udjeli - dionice u bankama","Udjeli - dionice u bankama" +"1122","kp_rrif1122","kp_rrif112","other","account_type_kratk_imovina",,,"Udjeli (do 20%) u ustanovama, zadrugama i dr.","Udjeli (do 20%) u ustanovama, zadrugama i dr." +"113","kp_rrif113","kp_rrif11","view","account_type_view",,,"Zajmovi dani poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)","Zajmovi dani poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)" +"1130","kp_rrif1130","kp_rrif113","other","account_type_kratk_imovina",,,"Zajmovi u novcu","Zajmovi u novcu" +"1131","kp_rrif1131","kp_rrif113","other","account_type_kratk_imovina",,,"Zajmovi iz preuzetog duga","Zajmovi iz preuzetog duga" +"1132","kp_rrif1132","kp_rrif113","other","account_type_kratk_imovina",,,"Zajmovi iz dospjelih anuiteta u razdoblju do 12 mj. od dospijeća","Zajmovi iz dospjelih anuiteta u razdoblju do 12 mj. od dospijeća" +"1133","kp_rrif1133","kp_rrif113","other","account_type_kratk_imovina",,,"Ostali zajmovi društvima u kojima se drži udjel do 20%","Ostali zajmovi društvima u kojima se drži udjel do 20%" +"114","kp_rrif114","kp_rrif11","view","account_type_view",,,"Ulaganja u vrijednosne papire","Ulaganja u vrijednosne papire" +"1140","kp_rrif1140","kp_rrif114","other","account_type_kratk_imovina",,,"Čekovi","Čekovi" +"1141","kp_rrif1141","kp_rrif114","view","account_type_view",,,"Mjenice","Mjenice" +"11410","kp_rrif11410","kp_rrif1141","other","account_type_kratk_imovina",,,"Mjenice u portfelju","Mjenice u portfelju" +"11411","kp_rrif11411","kp_rrif1141","other","account_type_kratk_imovina",,,"Mjenice na naplati","Mjenice na naplati" +"11412","kp_rrif11412","kp_rrif1141","other","account_type_kratk_imovina",,,"Mjenice u protestu","Mjenice u protestu" +"11413","kp_rrif11413","kp_rrif1141","other","account_type_kratk_imovina",,,"Utužene mjenice","Utužene mjenice" +"1142","kp_rrif1142","kp_rrif114","other","account_type_kratk_imovina",,,"Komercijalni zapisi","Komercijalni zapisi" +"1143","kp_rrif1143","kp_rrif114","other","account_type_kratk_imovina",,,"Kratkotrajne obveze poduzetnika","Kratkotrajne obveze poduzetnika" +"1144","kp_rrif1144","kp_rrif114","other","account_type_kratk_imovina",,,"Blagajnički zapisi (izdani od banaka)","Blagajnički zapisi (izdani od banaka)" +"1145","kp_rrif1145","kp_rrif114","other","account_type_kratk_imovina",,,"Ulaganje u obveznice","Ulaganje u obveznice" +"1146","kp_rrif1146","kp_rrif114","other","account_type_kratk_imovina",,,"Zadužnice (iskupljene)-trađbina s temelja jamstva","Zadužnice (iskupljene)-trađbina s temelja jamstva" +"1147","kp_rrif1147","kp_rrif114","other","account_type_kratk_imovina",,,"Ulaganje u vrijednosne papire (namjenjene za trgovanje)","Ulaganje u vrijednosne papire (namjenjene za trgovanje)" +"1148","kp_rrif1148","kp_rrif114","other","account_type_kratk_imovina",,,"Ostali brzounovčivi vrijednosni papiri (robni papiri, ostale obveznice)","Ostali brzounovčivi vrijednosni papiri (robni papiri, ostale obveznice)" +"1149","kp_rrif1149","kp_rrif114","other","account_type_kratk_imovina",,,"Predani vrijednosni papiri na naplatu","Predani vrijednosni papiri na naplatu" +"115","kp_rrif115","kp_rrif11","view","account_type_view",,,"Dani zajmovi, depoziti i sl.","Dani zajmovi, depoziti i sl." +"1150","kp_rrif1150","kp_rrif115","view","account_type_view",,,"Dani kratkotrajni zajmovi","Dani kratkotrajni zajmovi" +"11500","kp_rrif11500","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi poduzetnicima","Zajmovi poduzetnicima" +"11501","kp_rrif11501","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi ortacima","Zajmovi ortacima" +"11502","kp_rrif11502","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi obrtnicima","Zajmovi obrtnicima" +"11503","kp_rrif11503","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi podružnicama","Zajmovi podružnicama" +"11504","kp_rrif11504","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi ustanovama","Zajmovi ustanovama" +"11505","kp_rrif11505","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi dani u inozemstvo","Zajmovi dani u inozemstvo" +"11506","kp_rrif11506","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi članovima uprave i zaposlenicima","Zajmovi članovima uprave i zaposlenicima" +"11507","kp_rrif11507","kp_rrif1150","other","account_type_kratk_imovina",,,"Zajmovi dani poljoprivrednicima ili zadrugarima","Zajmovi dani poljoprivrednicima ili zadrugarima" +"11508","kp_rrif11508","kp_rrif1150","other","account_type_kratk_imovina",,,"Dospjeli anuiteti dugotrajnih zajmova (naplaćuju se u roku od 12 mjeseci - analitika po korisnicima)","Dospjeli anuiteti dugotrajnih zajmova (koji se naplaćuju u roku od 12 mjeseci - analitika po korisnicima)" +"11509","kp_rrif11509","kp_rrif1150","other","account_type_kratk_imovina",,,"Ostali kratkotrajni zajmovi","Ostali kratkotrajni zajmovi" +"1151","kp_rrif1151","kp_rrif115","view","account_type_view",,,"Depoziti (do jedne godine)","Depoziti (do jedne godine)" +"11510","kp_rrif11510","kp_rrif1151","other","account_type_kratk_imovina",,,"Depoziti u bankama","Depoziti u bankama" +"11511","kp_rrif11511","kp_rrif1151","other","account_type_kratk_imovina",,,"Depoziti u osiguravajućim društvima","Depoziti u osiguravajućim društvima" +"11512","kp_rrif11512","kp_rrif1151","other","account_type_kratk_imovina",,,"Depoziti u inozemnim financijskim institucijama","Depoziti u inozemnim financijskim institucijama" +"11513","kp_rrif11513","kp_rrif1151","other","account_type_kratk_imovina",,,"Depoziti za ostale poslovne aktivnosti","Depoziti za ostale poslovne aktivnosti" +"1152","kp_rrif1152","kp_rrif115","view","account_type_view",,,"Kaucije i jamčevine (do jedne godine)","Kaucije i jamčevine (do jedne godine)" +"11520","kp_rrif11520","kp_rrif1152","other","account_type_kratk_imovina",,,"Kaucije na aukcijama (dražbama)","Kaucije na aukcijama (dražbama)" +"11521","kp_rrif11521","kp_rrif1152","other","account_type_kratk_imovina",,,"Kaucije za robu","Kaucije za robu" +"11522","kp_rrif11522","kp_rrif1152","other","account_type_kratk_imovina",,,"Kaucije za ambalažu","Kaucije za ambalažu" +"11523","kp_rrif11523","kp_rrif1152","other","account_type_kratk_imovina",,,"Dane jamčevine za natječaje","Dane jamčevine za natječaje" +"11524","kp_rrif11524","kp_rrif1152","other","account_type_kratk_imovina",,,"Potraživanja za kapare (čl. 303. ZOO-a)","Potraživanja za kapare (čl. 303. ZOO-a)" +"11525","kp_rrif11525","kp_rrif1152","other","account_type_kratk_imovina",,,"Polozi gotovine za ostale poslovne aktivnosti","Polozi gotovine za ostale poslovne aktivnosti" +"116","kp_rrif116","kp_rrif11","view","account_type_view",,,"Potraživanja iz ulaganja u investicijske fondove","Potraživanja iz ulaganja u investicijske fondove" +"1160","kp_rrif1160","kp_rrif116","other","account_type_kratk_imovina",,,"Kratkotrajno ulaganje u novčane fondove","Kratkotrajno ulaganje u novčane fondove" +"1161","kp_rrif1161","kp_rrif116","other","account_type_kratk_imovina",,,"Kratkotrajno ulaganje u ostale investicijske fondove","Kratkotrajno ulaganje u ostale investicijske fondove" +"117","kp_rrif117","kp_rrif11","view","account_type_view",,,"Ostala financijska imovina","Ostala financijska imovina" +"1170","kp_rrif1170","kp_rrif117","other","account_type_kratk_imovina",,,"Otkup kratkoročnih potraživanja (faktoring)","Otkup kratkoročnih potraživanja (faktoring)" +"1171","kp_rrif1171","kp_rrif117","other","account_type_kratk_imovina",,,"Ulaganje u kratkotrajne eskontne poslove","Ulaganje u kratkotrajne eskontne poslove" +"1172","kp_rrif1172","kp_rrif117","other","account_type_kratk_imovina",,,"Potraživanja za više uplaćeno po kreditnoj kartici","Potraživanja za više uplaćeno po kreditnoj kartici" +"1173","kp_rrif1173","kp_rrif117","other","account_type_kratk_imovina",,,"Potraživanja za isplate avaliranih ili indosiranih mjenica","Potraživanja za isplate avaliranih ili indosiranih mjenica" +"1174","kp_rrif1174","kp_rrif117","other","account_type_kratk_imovina",,,"Potraživanja po isplaćenim garancijama","Potraživanja po isplaćenim garancijama" +"1175","kp_rrif1175","kp_rrif117","other","account_type_kratk_imovina",,,"Potraživanja iz preuzetog duga (čl. 96. ZOO)","Potraživanja iz preuzetog duga (čl. 96. ZOO)" +"1176","kp_rrif1176","kp_rrif117","other","account_type_kratk_imovina",,,"Potraživanje po asignacijama, novacijama i sl.","Potraživanje po asignacijama, novacijama i sl." +"118","kp_rrif118","kp_rrif11","view","account_type_view",,,"Potraživanja u sporu (npr. utužena, u stečaju i sl. iz fin. imovine)","Potraživanja u sporu (npr. utužena, u stečaju i sl. iz fin. imovine)" +"1180","kp_rrif1180","kp_rrif118","other","account_type_kratk_imovina",,,"Potraživanja u sporu (npr. utužena, u stečaju i sl. iz fin. imovine)-a1","Potraživanja u sporu (npr. utužena, u stečaju i sl. iz fin. imovine)-Analitika 1" +"119","kp_rrif119","kp_rrif11","view","account_type_view",,,"Vrijednosno usklađivanje financijske imovine - kratkotrajne (analitika po otpisima iz ove skupine rn)","Vrijednosno usklađivanje financijske imovine - kratkotrajne (analitika po otpisima iz ove skupine računa)" +"1190","kp_rrif1190","kp_rrif119","other","account_type_kratk_imovina",,,"Vrijednosno usklađivanje financijske imovine - kratkotrajne (analitika po otpisima iz ove skupine rn)-a1","Vrijednosno usklađivanje financijske imovine - kratkotrajne (analitika po otpisima iz ove skupine računa)-Analitika 1" +"12","kp_rrif12","kp_rrif1","view","account_type_view",,,"POTRAŽIVANJA (KRATKOTRAJNA)","POTRAŽIVANJA (KRATKOTRAJNA)" +"120","kp_rrif120","kp_rrif12","view","account_type_view",,,"Potraživanja od kupaca","Potraživanja od kupaca" +"1200","kp_rrif1200","kp_rrif120","receivable","account_type_potraz_kup","True",,"Potraživanja od kupaca dobara","Potraživanja od kupaca dobara" +"1201","kp_rrif1201","kp_rrif120","receivable","account_type_potraz_kup","True",,"Potraživanja od kupaca usluga (servisne, najmovi, ustupanje radne snage, kapaciteta i dr.)","Potraživanja od kupaca usluga (servisne, najmovi, ustupanje radne snage, kapaciteta i dr.)" +"1202","kp_rrif1202","kp_rrif120","receivable","account_type_potraz_kup","True",,"Potraživanja za prodaju prava","Potraživanja za prodaju prava" +"1203","kp_rrif1203","kp_rrif120","receivable","account_type_potraz_kup","True",,"Kupci građani i prodaja na potrošački kredit","Kupci građani i prodaja na potrošački kredit" +"1204","kp_rrif1204","kp_rrif120","receivable","account_type_potraz_kup","True",,"Kupci imovinskih sredstava, inventara, materijala, otpadaka i sl.","Kupci imovinskih sredstava, inventara, materijala, otpadaka i sl." +"1205","kp_rrif1205","kp_rrif120","receivable","account_type_potraz_kup","True",,"Potraživanja od kupaca za prodanu robu iz komisije","Potraživanja od kupaca za prodanu robu iz komisije" +"1206","kp_rrif1206","kp_rrif120","receivable","account_type_potraz_kup","True",,"Kupci zastupničke i franšizne prodaje","Kupci zastupničke i franšizne prodaje" +"1207","kp_rrif1207","kp_rrif120","receivable","account_type_potraz_kup","True",,"Potraživanja za prodaju na kreditne kartice","Potraživanja za prodaju na kreditne kartice" +"1208","kp_rrif1208","kp_rrif120","receivable","account_type_potraz_kup","True",,"Potraživanja od ostalih prodaja","Potraživanja od ostalih prodaja" +"1209","kp_rrif1209","kp_rrif120","receivable","account_type_potraz_kup","True",,"Potraživanja za nefakturiranu isporuku dobara ili usluga","Potraživanja za nefakturiranu isporuku dobara ili usluga" +"121","kp_rrif121","kp_rrif12","view","account_type_view",,,"Kupci u inozemstvu","Kupci u inozemstvu" +"1210","kp_rrif1210","kp_rrif121","receivable","account_type_potraz_kup","True",,"Kupci dobara iz inozemstva","Kupci dobara iz inozemstva" +"1211","kp_rrif1211","kp_rrif121","receivable","account_type_potraz_kup","True",,"Kupci usluga iz inozemstva","Kupci usluga iz inozemstva" +"1212","kp_rrif1212","kp_rrif121","receivable","account_type_potraz_kup","True",,"Kupci prava iz inozemstva","Kupci prava iz inozemstva" +"122","kp_rrif122","kp_rrif12","view","account_type_view",,,"Potraživanja od povezanih poduzetnika (s više od 20% udjela - ovisni poduzet.)","Potraživanja od povezanih poduzetnika (s više od 20% udjela - ovisni poduzet.)" +"1220","kp_rrif1220","kp_rrif122","receivable","account_type_potraz_kup","True",,"Potraživanja za prodaju - isporuku povezanim društvima","Potraživanja za prodaju - isporuku povezanim društvima" +"1221","kp_rrif1221","kp_rrif122","receivable","account_type_potraz_kup","True",,"Potraživanja za dividende od povezanih društava","Potraživanja za dividende od povezanih društava" +"1222","kp_rrif1222","kp_rrif122","receivable","account_type_potraz_kup","True",,"Potraživanja za isporuke povezanim društvima u inozemstvu","Potraživanja za isporuke povezanim društvima u inozemstvu" +"1223","kp_rrif1223","kp_rrif122","receivable","account_type_potraz_kup","True",,"Potraživanja za nadoknadu gubitka od povezanih društava (čl. 489. ZTD)","Potraživanja za nadoknadu gubitka od povezanih društava (čl. 489. ZTD)" +"1224","kp_rrif1224","kp_rrif122","receivable","account_type_potraz_kup","True",,"Potraživanja za kamate od povezanih društava","Potraživanja za kamate od povezanih društava" +"1225","kp_rrif1225","kp_rrif122","receivable","account_type_potraz_kup","True",,"Potraživanja od podružnica","Potraživanja od podružnica" +"1226","kp_rrif1226","kp_rrif122","receivable","account_type_potraz_kup","True",,"Ostala kratkoročna potraživanja od povezanih poduzetnika","Ostala kratkoročna potraživanja od povezanih poduzetnika" +"1227","kp_rrif1227","kp_rrif122","receivable","account_type_potraz_kup","True",,"Potraživanja za udio u dobitku d.o.o.-a","Potraživanja za udio u dobitku d.o.o.-a" +"1228","kp_rrif1228","kp_rrif122","other","account_type_potraz_kup",,,"Potraživanja iz ulaganja radi povećanja udjela (do upisa u t.k.)","Potraživanja iz ulaganja radi povećanja udjela (do upisa u t.k.)" +"123","kp_rrif123","kp_rrif12","view","account_type_view",,,"Potraživanja od sudjelujućih poduzetnika (u kojima se drži manje od 20% udjela)","Potraživanja od sudjelujućih poduzetnika (u kojima se drži manje od 20% udjela)" +"1230","kp_rrif1230","kp_rrif123","receivable","account_type_potraz_kup","True",,"Potraživanja za isporuke dobara i usluga","Potraživanja za isporuke dobara i usluga" +"1231","kp_rrif1231","kp_rrif123","receivable","account_type_potraz_kup","True",,"Potraživanja za dividendu - dobitak","Potraživanja za dividendu - dobitak" +"1232","kp_rrif1232","kp_rrif123","receivable","account_type_potraz_kup","True",,"Potraživanja za kamate","Potraživanja za kamate" +"1233","kp_rrif1233","kp_rrif123","receivable","account_type_potraz_kup","True",,"Ostala potraživanja od sudjelujućih društava","Ostala potraživanja od sudjelujućih društava" +"124","kp_rrif124","kp_rrif12","view","account_type_view",,,"Potraživanja za kamate","Potraživanja za kamate" +"1240","kp_rrif1240","kp_rrif124","receivable","account_type_potraz_kup","True",,"Potraživanja od kupaca za ugovorene kamate (koje nisu pripisane glavnici)","Potraživanja od kupaca za ugovorene kamate (koje nisu pripisane glavnici)" +"1241","kp_rrif1241","kp_rrif124","receivable","account_type_potraz_kup","True",,"Potraživanja za zatezne kamate (koje nisu pripisane glavnici)","Potraživanja za zatezne kamate (koje nisu pripisane glavnici)" +"1242","kp_rrif1242","kp_rrif124","receivable","account_type_potraz_kup","True",,"Potraživanja za kamate po nagodbama","Potraživanja za kamate po nagodbama" +"1243","kp_rrif1243","kp_rrif124","receivable","account_type_potraz_kup","True",,"Potraživanje za kamatu iz danih zajmova","Potraživanje za kamatu iz danih zajmova" +"1245","kp_rrif1245","kp_rrif124","receivable","account_type_potraz_kup","True",,"Kamate iz ostalih trađbina","Kamate iz ostalih trađbina" +"125","kp_rrif125","kp_rrif12","view","account_type_view",,,"Potraživanja za predujmove za usluge (koje nisu u svezi sa zalihama i dugotr. imov.)","Potraživanja za predujmove za usluge (koje nisu u svezi sa zalihama i dugotr. imov.)" +"1250","kp_rrif1250","kp_rrif125","receivable","account_type_potraz_kup","True",,"Potraživanja za predujmove za usluge (koje nisu u svezi sa zalihama i dugotr. imov.)-a1","Potraživanja za predujmove za usluge (koje nisu u svezi sa zalihama i dugotr. imov.)-Analitika 1" +"126","kp_rrif126","kp_rrif12","view","account_type_view",,,"Potraživanja iz vanjskotrgovačkog poslovanja (s osnove uvoza odnosno izvoza za tuđi račun)","Potraživanja iz vanjskotrgovačkog poslovanja (s osnove uvoza odnosno izvoza za tuđi račun)" +"1260","kp_rrif1260","kp_rrif126","receivable","account_type_potraz_kup","True",,"Potraživanja po poslovima uvoza za tuđi račun","Potraživanja po poslovima uvoza za tuđi račun" +"1261","kp_rrif1261","kp_rrif126","receivable","account_type_potraz_kup","True",,"Potraživanja od izvoznika","Potraživanja od izvoznika" +"127","kp_rrif127","kp_rrif12","view","account_type_view",,,"Potraživanja s osnove ostalih aktivnosti","Potraživanja s osnove ostalih aktivnosti" +"1270","kp_rrif1270","kp_rrif127","receivable","account_type_potraz_kup","True",,"Potraživanja s osnove prodaje udjela i dionica","Potraživanja s osnove prodaje udjela i dionica" +"1271","kp_rrif1271","kp_rrif127","receivable","account_type_potraz_kup","True",,"Potraživanja za nakladno odobrene popuste (bonifikacije, casa-sconto, rabat i sl.)","Potraživanja za nakladno odobrene popuste (bonifikacije, casa-sconto, rabat i sl.)" +"1272","kp_rrif1272","kp_rrif127","receivable","account_type_potraz_kup","True",,"Potraživanja za predujam za kupnju dionica i udjela","Potraživanja za predujam za kupnju dionica i udjela" +"1273","kp_rrif1273","kp_rrif127","receivable","account_type_potraz_kup","True",,"Potraživanja od komisionara","Potraživanja od komisionara" +"128","kp_rrif128","kp_rrif12","view","account_type_view",,,"Ostala kratkoročna potraživanja","Ostala kratkoročna potraživanja" +"1280","kp_rrif1280","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja iz odštetnih zahtjeva (od osiguravajućih društava)","Potraživanja iz odštetnih zahtjeva (od osiguravajućih društava)" +"1281","kp_rrif1281","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja za udjel u dobitku - prihodu u investicijskom fondu","Potraživanja za udjel u dobitku - prihodu u investicijskom fondu" +"1282","kp_rrif1282","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja za tantijeme (nadoknade za korištenje patenta, znaka i autorskih prava)","Potraživanja za tantijeme (nadoknade za korištenje patenta, znaka i autorskih prava)" +"1283","kp_rrif1283","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja stečena cesijom, asignacijom i preuzimanjem duga od prodaje","Potraživanja stečena cesijom, asignacijom i preuzimanjem duga od prodaje" +"1284","kp_rrif1284","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja za nadoknadu troškova iz jamstva","Potraživanja za nadoknadu troškova iz jamstva" +"1285","kp_rrif1285","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja od kooperanata, zadrugara, ustanove","Potraživanja od kooperanata, zadrugara, ustanove" +"1286","kp_rrif1286","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja od članova društva za pokriće gubitka","Potraživanja od članova društva za pokriće gubitka" +"1287","kp_rrif1287","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja za dana jamstva i činidbe","Potraživanja za dana jamstva i činidbe" +"1288","kp_rrif1288","kp_rrif128","receivable","account_type_potraz_kup","True",,"Potraživanja za poreze iz poslovnih odnosa","Potraživanja za poreze iz poslovnih odnosa" +"1289","kp_rrif1289","kp_rrif128","receivable","account_type_potraz_kup","True",,"Ostala potraživanja","Ostala potraživanja" +"129","kp_rrif129","kp_rrif12","view","account_type_view",,,"Vrijednosno usklađenje potraživanja","Vrijednosno usklađenje potraživanja" +"1290","kp_rrif1290","kp_rrif129","receivable","account_type_potraz_kup","True",,"Vrijednosno usklađenje potraživanja od kupaca","Vrijednosno usklađenje potraživanja od kupaca" +"1291","kp_rrif1291","kp_rrif129","receivable","account_type_potraz_kup","True",,"Vrijednosno usklađenje potraživanja od povezanih društava","Vrijednosno usklađenje potraživanja od povezanih društava" +"1292","kp_rrif1292","kp_rrif129","receivable","account_type_potraz_kup","True",,"Vrijednosno usklađenje od poduzetnika iz sudjelujućih interesa","Vrijednosno usklađenje od poduzetnika iz sudjelujućih interesa" +"1293","kp_rrif1293","kp_rrif129","receivable","account_type_potraz_kup","True",,"Vrijednosno usklađenje kamata","Vrijednosno usklađenje kamata" +"1294","kp_rrif1294","kp_rrif129","receivable","account_type_potraz_kup","True",,"Vrijednosno usklađenje za dane predujmove za usluge","Vrijednosno usklađenje za dane predujmove za usluge" +"1295","kp_rrif1295","kp_rrif129","receivable","account_type_potraz_kup","True",,"Vrijednosno usklađenje ostalih potraživanja (računi 126 do 128)","Vrijednosno usklađenje ostalih potraživanja (računi 126 do 128)" +"13","kp_rrif13","kp_rrif1","view","account_type_view",,,"POTRAŽIVANJA OD ZAPOSLENIH I OSTALA POTRAŽIVANJA (kratkotrajna)","POTRAŽIVANJA OD ZAPOSLENIH I OSTALA POTRAŽIVANJA (kratkotrajna)" +"130","kp_rrif130","kp_rrif13","view","account_type_view",,,"Potraživanja od zaposlenih","Potraživanja od zaposlenih" +"1300","kp_rrif1300","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja od zaposlenih za više isplaćenu plaću","Potraživanja od zaposlenih za više isplaćenu plaću" +"1301","kp_rrif1301","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja za isplaćeni predujam za službeni put","Potraživanja za isplaćeni predujam za službeni put" +"1302","kp_rrif1302","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja za dane novčane svote za nabave u gotovini (za tržišni nakup, za karnete i dr.)","Potraživanja za dane novčane svote za nabave u gotovini (za tržišni nakup, za karnete i dr.)" +"1303","kp_rrif1303","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja za manjkove i učinjene štete (s PDV-om)","Potraživanja za manjkove i učinjene štete (s PDV-om)" +"1304","kp_rrif1304","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja za prehranu, kazne, za korištenje odmarališta i sl.","Potraživanja za prehranu, kazne, za korištenje odmarališta i sl." +"1305","kp_rrif1305","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja od zaposlenih za manje plaćene poreze i doprinose","Potraživanja od zaposlenih za manje plaćene poreze i doprinose" +"1306","kp_rrif1306","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja od zaposlenika za plaćene privatne troškove (npr. po službenoj kred. kartici)","Potraživanja od zaposlenika za plaćene privatne troškove (npr. po službenoj kred. kartici)" +"1307","kp_rrif1307","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja od zaposlenika za primitak u naravi","Potraživanja od zaposlenika za primitak u naravi" +"1309","kp_rrif1309","kp_rrif130","other","account_type_kratk_imovina",,,"Ostala potraživanja od zaposlenih","Ostala potraživanja od zaposlenih" +"131","kp_rrif130","kp_rrif13","view","account_type_view",,,"Potraživanja od vanjskih suradnika","Potraživanja od vanjskih suradnika" +"1310","kp_rrif1310","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja za predujmljene honorare","Potraživanja za predujmljene honorare" +"1311","kp_rrif1311","kp_rrif130","other","account_type_kratk_imovina",,,"Potraživanja za isplaćene svote","Potraživanja za isplaćene svote" +"1319","kp_rrif1319","kp_rrif130","other","account_type_kratk_imovina",,,"Ostala potraživanja od vanjskih suradnika","Ostala potraživanja od vanjskih suradnika" +"133","kp_rrif133","kp_rrif13","view","account_type_view",,,"Potraživanja od članova poduzetnika","Potraživanja od članova poduzetnika" +"1330","kp_rrif1330","kp_rrif133","other","account_type_kratk_imovina",,,"Potraživanja od članova društva za predujmljeni dobitak - dividendu","Potraživanja od članova društva za predujmljeni dobitak - dividendu" +"1331","kp_rrif1331","kp_rrif133","other","account_type_kratk_imovina",,,"Potraživanja od članova društva za privatne troškove","Potraživanja od članova društva za privatne troškove" +"1332","kp_rrif1332","kp_rrif133","other","account_type_kratk_imovina",,,"Potraživanja od članova ustanove","Potraživanja od članova ustanove" +"1333","kp_rrif1333","kp_rrif133","other","account_type_kratk_imovina",,,"Potraživanja od članova zadruge","Potraživanja od članova zadruge" +"134","kp_rrif134","kp_rrif13","view","account_type_view",,,"Potraživanja u sporu i rizična potraživanja (iz skupine 12 i 13)","Potraživanja u sporu i rizična potraživanja (iz skupine 12 i 13)" +"1340","kp_rrif1340","kp_rrif134","other","account_type_kratk_imovina",,,"Potraživanja u sporu i rizična potraživanja (iz skupine 12 i 13)-a1","Potraživanja u sporu i rizična potraživanja (iz skupine 12 i 13)-Analitika 1" +"135","kp_rrif135","kp_rrif13","view","account_type_view",,,"Potraživanja za sredstva u slobodnoj zoni","Potraživanja za sredstva u slobodnoj zoni" +"1350","kp_rrif1350","kp_rrif135","other","account_type_kratk_imovina",,,"Potraživanja za sredstva u slobodnoj zoni-a1","Potraživanja za sredstva u slobodnoj zoni-Analitika 1" +"136","kp_rrif136","kp_rrif13","view","account_type_view",,,"Potraživanja od banaka za prodaju na potrošački kredit","Potraživanja od banaka za prodaju na potrošački kredit" +"1360","kp_rrif1360","kp_rrif136","other","account_type_kratk_imovina",,,"Potraživanja od banaka za prodaju na potrošački kredit-a1","Potraživanja od banaka za prodaju na potrošački kredit-Analitika 1" +"137","kp_rrif137","kp_rrif13","view","account_type_view",,,"Potraživanja od poslovnih jedinica u inozemstvu","Potraživanja od poslovnih jedinica u inozemstvu" +"1370","kp_rrif1370","kp_rrif137","other","account_type_kratk_imovina",,,"Potraživanja za isporučena dobra i usluge","Potraživanja za isporučena dobra i usluge" +"1371","kp_rrif1371","kp_rrif137","other","account_type_kratk_imovina",,,"Potraživanja za doznake novca, za dobitak i dr.","Potraživanja za doznake novca, za dobitak i dr." +"138","kp_rrif138","kp_rrif13","view","account_type_view",,,"Ostala poslovna potraživanja","Ostala poslovna potraživanja" +"1380","kp_rrif1380","kp_rrif138","other","account_type_kratk_imovina",,,"Potraživanja za naknadne popuste","Potraživanja za naknadne popuste" +"1381","kp_rrif1381","kp_rrif138","other","account_type_kratk_imovina",,,"Potraživanja od ortaka","Potraživanja od ortaka" +"1382","kp_rrif1382","kp_rrif138","other","account_type_kratk_imovina",,,"Potraživanja od zastupnika","Potraživanja od zastupnika" +"1389","kp_rrif1389","kp_rrif138","other","account_type_kratk_imovina",,,"Ostala poslovna potraživanja","Ostala poslovna potraživanja" +"139","kp_rrif139","kp_rrif13","view","account_type_view",,,"Vrijednosno usklađenje potraživanja od zaposlenih članova društva i ostalih potraživanja","Vrijednosno usklađenje potraživanja od zaposlenih članova društva i ostalih potraživanja" +"1390","kp_rrif1390","kp_rrif139","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje potraživanja od zaposlenih članova društva i ostalih potraživanja-a1","Vrijednosno usklađenje potraživanja od zaposlenih članova društva i ostalih potraživanja-Analitika 1" +"14","kp_rrif14","kp_rrif1","view","account_type_view",,,"POTRAŽIVANJA OD DRŽAVE ZA POREZE, CARINU I DOPRINOSE","POTRAŽIVANJA OD DRŽAVE ZA POREZE, CARINU I DOPRINOSE" +"140","kp_rrif140","kp_rrif14","view","account_type_view",,,"Porez na dodanu vrijednost","Porez na dodanu vrijednost" +"1400","kp_rrif1400","kp_rrif140","view","account_type_view",,,"Pretporez po ulaznim računima","Pretporez po ulaznim računima" +"14000","kp_rrif14000","kp_rrif1400","other","account_type_pretporez",,,"Pretporez - 10%","Pretporez - 10%" +"14001","kp_rrif14001","kp_rrif1400","other","account_type_pretporez",,,"Pretporez - 22%","Pretporez - 22%" +"14002","kp_rrif14002","kp_rrif1400","other","account_type_pretporez",,,"Pretporez - 23%","Pretporez - 23%" +"14003","kp_rrif14003","kp_rrif1400","other","account_type_pretporez",,,"Pretporez - 25%","Pretporez - 25%" +"1401","kp_rrif1401","kp_rrif140","view","account_type_view",,,"Pretporez iz predujmova","Pretporez iz predujmova" +"14010","kp_rrif14010","kp_rrif1401","other","account_type_pretporez",,,"Pretporez iz predujmova -10%","Pretporez iz predujmova -10%" +"14011","kp_rrif14011","kp_rrif1401","other","account_type_pretporez",,,"Pretporez iz predujmova - 22%","Pretporez iz predujmova - 22%" +"14012","kp_rrif14012","kp_rrif1401","other","account_type_pretporez",,,"Pretporez iz predujmova - 23%","Pretporez iz predujmova - 23%" +"14013","kp_rrif14013","kp_rrif1401","other","account_type_pretporez",,,"Pretporez iz predujmova - 25%","Pretporez iz predujmova - 25%" +"1402","kp_rrif1402","kp_rrif140","view","account_type_view",,,"Plaćeni PDV pri uvozu dobara","Plaćeni PDV pri uvozu dobara" +"14020","kp_rrif14020","kp_rrif1402","other","account_type_pretporez",,,"Plaćeni PDV pri uvozu dobara - 10%","Plaćeni PDV pri uvozu dobara - 10%" +"14021","kp_rrif14021","kp_rrif1402","other","account_type_pretporez",,,"Plaćeni PDV pri uvozu dobara - 22%","Plaćeni PDV pri uvozu dobara - 22%" +"14022","kp_rrif14022","kp_rrif1402","other","account_type_pretporez",,,"Plaćeni PDV pri uvozu dobara - 23%","Plaćeni PDV pri uvozu dobara - 23%" +"14023","kp_rrif14023","kp_rrif1402","other","account_type_pretporez",,,"Plaćeni PDV pri uvozu dobara - 25%","Plaćeni PDV pri uvozu dobara - 25%" +"1403","kp_rrif1403","kp_rrif140","view","account_type_view",,,"Plaćeni PDV na usluge inozemnih poduzetnika","Plaćeni PDV na usluge inozemnih poduzetnika" +"14030","kp_rrif14030","kp_rrif1403","other","account_type_pretporez",,,"Plaćeni PDV na usluge inozemnih poduzetnika - 10%","Plaćeni PDV na usluge inozemnih poduzetnika - 10%" +"14031","kp_rrif14031","kp_rrif1403","other","account_type_pretporez",,,"Plaćeni PDV na usluge inozemnih poduzetnika - 22%","Plaćeni PDV na usluge inozemnih poduzetnika - 22%" +"14032","kp_rrif14032","kp_rrif1403","other","account_type_pretporez",,,"Plaćeni PDV na usluge inozemnih poduzetnika - 23%","Plaćeni PDV na usluge inozemnih poduzetnika - 23%" +"14033","kp_rrif14033","kp_rrif1403","other","account_type_pretporez",,,"Plaćeni PDV na usluge inozemnih poduzetnika - 25%","Plaćeni PDV na usluge inozemnih poduzetnika - 25%" +"1404","kp_rrif1404","kp_rrif140","view","account_type_view",,,"Ispravci pretporeza zbog prenamjene dobara","Ispravci pretporeza zbog prenamjene dobara" +"14040","kp_rrif14040","kp_rrif1404","other","account_type_pretporez",,,"Ispravak pretporeza zbog promjene postotka priznavanja PDV-a","Ispravak pretporeza zbog promjene postotka priznavanja PDV-a" +"1406","kp_rrif1406","kp_rrif140","other","account_type_pretporez",,,"Pretporez stečen po ugovoru o asignaciji ili iz preknjižavanja","Pretporez stečen po ugovoru o asignaciji ili iz preknjižavanja" +"1407","kp_rrif1407","kp_rrif140","other","account_type_pretporez",,,"Potraživanja za razliku većeg pretporeza od obveze u obračunskom razdoblju","Potraživanja za razliku većeg pretporeza od obveze u obračunskom razdoblju" +"1408","kp_rrif1408","kp_rrif140","other","account_type_pretporez",,,"Pretporez koji još nije priznan (uključivo i neplaćeni R-2)","Pretporez koji još nije priznan (uključivo i neplaćeni R-2)" +"1409","kp_rrif1409","kp_rrif140","other","account_type_pretporez",,,"Potraživanja za više plaćeni PDV po konačnom obračunu","Potraživanja za više plaćeni PDV po konačnom obračunu" +"141","kp_rrif141","kp_rrif14","view","account_type_view",,,"Potraživanja za porez i prirez na dohodak iz plaća i drugih primanja","Potraživanja za porez i prirez na dohodak iz plaća i drugih primanja" +"1410","kp_rrif1410","kp_rrif141","other","account_type_kratk_imovina",,,"Potraživanja za porez na dohodak iz plaća","Potraživanja za porez na dohodak iz plaća" +"1411","kp_rrif1411","kp_rrif141","other","account_type_kratk_imovina",,,"Potraživanja za prirez iz plaća","Potraživanja za prirez iz plaća" +"1412","kp_rrif1412","kp_rrif141","other","account_type_kratk_imovina",,,"Potraživanja za porez na dohodak iz autorskih prava, ugovora o djelu, članova nadz. odbora i dr.doh.","Potraživanja za porez na dohodak iz autorskih prava, ugovora o djelu, dohodaka članova nadzornog odbora i drugih dohodaka" +"1413","kp_rrif1413","kp_rrif141","other","account_type_kratk_imovina",,,"Potraživanja za porez i prirez na stipendije i nagrade učenika i studenta","Potraživanja za porez i prirez na stipendije i nagrade učenika i studenta" +"1414","kp_rrif1414","kp_rrif141","other","account_type_kratk_imovina",,,"Potraživanja za poreze iz drugih dohodaka","Potraživanja za poreze iz drugih dohodaka" +"1417","kp_rrif1417","kp_rrif141","other","account_type_kratk_imovina",,,"Potraživanja za više plaćeni porez na dohodak od kapitala","Potraživanja za više plaćeni porez na dohodak od kapitala" +"142","kp_rrif142","kp_rrif14","view","account_type_view",,,"Potraživanja za više plaćene doprinose iz plaća i na plaće","Potraživanja za više plaćene doprinose iz plaća i na plaće" +"1420","kp_rrif1420","kp_rrif142","other","account_type_kratk_imovina",,,"Potraživanja za više plaćene doprinose za MO iz plaće","Potraživanja za više plaćene doprinose za MO iz plaće" +"1421","kp_rrif1421","kp_rrif142","other","account_type_kratk_imovina",,,"Potraživanja od MO za više plaćeni doprinos za beneficirani staž","Potraživanja od MO za više plaćeni doprinos za beneficirani staž" +"1422","kp_rrif1422","kp_rrif142","other","account_type_kratk_imovina",,,"Potraživanja za više plaćeni doprinos za zdravstveno osiguranje na plaće","Potraživanja za više plaćeni doprinos za zdravstveno osiguranje na plaće" +"1423","kp_rrif1423","kp_rrif142","other","account_type_kratk_imovina",,,"Potraživanja za više plaćeni dopr. za zdrav. osigur. za slučaj ozljede na radu i prof. bolesti","Potraživanja za više plaćeni dopr. za zdrav. osigur. za slučaj ozljede na radu i prof. bolesti" +"1424","kp_rrif1424","kp_rrif142","other","account_type_kratk_imovina",,,"Potraživanja za više plaćeni doprinos za zapošljavanje na plaće","Potraživanja za više plaćeni doprinos za zapošljavanje na plaće" +"1429","kp_rrif1429","kp_rrif142","other","account_type_kratk_imovina",,,"Potraživanja za ostale nespomenute doprinose","Potraživanja za ostale nespomenute doprinose" +"143","kp_rrif143","kp_rrif14","view","account_type_view",,,"Potraživanja za porez na dobitak i po odbitku","Potraživanja za porez na dobitak i po odbitku" +"1430","kp_rrif1430","kp_rrif143","other","account_type_kratk_imovina",,,"Potraživanja za plaćene predujmove poreza na dobitak","Potraživanja za plaćene predujmove poreza na dobitak" +"1432","kp_rrif1432","kp_rrif143","other","account_type_kratk_imovina",,,"Potraživanja za više plaćeni porez po odbitku (na inozemne usluge)","Potraživanja za više plaćeni porez po odbitku (na inozemne usluge)" +"1433","kp_rrif1433","kp_rrif143","other","account_type_kratk_imovina",,,"Potraživanja za porez na dobitak stečen po ugovoru o cesiji ili iz preknjižavanja","Potraživanja za porez na dobitak stečen po ugovoru o cesiji ili iz preknjižavanja" +"1434","kp_rrif1434","kp_rrif143","other","account_type_kratk_imovina",,,"Porez na dobitak plaćen u inozemstvu","Porez na dobitak plaćen u inozemstvu" +"144","kp_rrif144","kp_rrif14","view","account_type_view",,,"Potraživanja za posebne poreze (akcize - trošarine) i dr. poreze od države","Potraživanja za posebne poreze (akcize - trošarine) i dr. poreze od države" +"1440","kp_rrif1440","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na kavu","Potraživanja za poseban porez na kavu" +"1441","kp_rrif1441","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na bezalkoholna pića","Potraživanja za poseban porez na bezalkoholna pića" +"1442","kp_rrif1442","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na alkoholna pića","Potraživanja za poseban porez na alkoholna pića" +"1443","kp_rrif1443","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na pivo","Potraživanja za poseban porez na pivo" +"1444","kp_rrif1444","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na duhanske proizvode","Potraživanja za poseban porez na duhanske proizvode" +"1445","kp_rrif1445","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na naftne derivate i naknade za ceste","Potraživanja za poseban porez na naftne derivate i naknade za ceste" +"1446","kp_rrif1446","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na osobne automobile, motocikle, ostala mot. vozila, plovila i zrakop.","Potraživanja za poseban porez na osobne automobile, motocikle, ostala motorna vozila, plovila i zrakoplove" +"1447","kp_rrif1447","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za poseban porez na luksuzne proizvode","Potraživanja za poseban porez na luksuzne proizvode" +"1448","kp_rrif1448","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za porez na promet nekretnina","Potraživanja za porez na promet nekretnina" +"1449","kp_rrif1449","kp_rrif144","other","account_type_kratk_imovina",,,"Potraživanja za 5% poreza na promet motornih vozila i plovila","Potraživanja za 5% poreza na promet motornih vozila i plovila" +"145","kp_rrif145","kp_rrif14","view","account_type_view",,,"Potraživanja za plaćenu članarinu turističkim zajed.","Potraživanja za plaćenu članarinu turističkim zajed." +"1450","kp_rrif1450","kp_rrif145","other","account_type_kratk_imovina",,,"Potraživanja za plaćenu članarinu turističkim zajed.-a1","Potraživanja za plaćenu članarinu turističkim zajed.-Analitika 1" +"146","kp_rrif146","kp_rrif14","view","account_type_view",,,"Potraživanja za članarine komori (HGK ili HOK)","Potraživanja za članarine komori (HGK ili HOK)" +"1460","kp_rrif1460","kp_rrif146","other","account_type_kratk_imovina",,,"Potraživanja za članarine komori (HGK ili HOK)-a1","Potraživanja za članarine komori (HGK ili HOK)-Analitika 1" +"147","kp_rrif147","kp_rrif14","view","account_type_view",,,"Potraživanja za carinu i više plaćene carinske pristojbe","Potraživanja za carinu i više plaćene carinske pristojbe" +"1470","kp_rrif1470","kp_rrif147","other","account_type_kratk_imovina",,,"Potraživanja za carinu i više plaćene carinske pristojbe-a1","Potraživanja za carinu i više plaćene carinske pristojbe-Analitika 1" +"148","kp_rrif148","kp_rrif14","view","account_type_view",,,"Potraživanja za županijski i općinski (gradski) porez","Potraživanja za županijski i općinski (gradski) porez" +"1480","kp_rrif1480","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za više plaćeni porez na motorna vozila i plovne objekte","Potraživanja za više plaćeni porez na motorna vozila i plovne objekte" +"1481","kp_rrif1481","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za porez na kuće za odmor i korištenje javnih površina","Potraživanja za porez na kuće za odmor i korištenje javnih površina" +"1482","kp_rrif1482","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za porez na reklamu","Potraživanja za porez na reklamu" +"1483","kp_rrif1483","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za porez na tvrtku ili naziv","Potraživanja za porez na tvrtku ili naziv" +"1484","kp_rrif1484","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za porez na potrošnju u ugostiteljstvu","Potraživanja za porez na potrošnju u ugostiteljstvu" +"1485","kp_rrif1485","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za plaćeni porez na priređivanje zabavnih i športskih priredbi","Potraživanja za plaćeni porez na priređivanje zabavnih i športskih priredbi" +"1486","kp_rrif1486","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za plaćeni porez na nasljedstva i darove","Potraživanja za plaćeni porez na nasljedstva i darove" +"1487","kp_rrif1487","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za više plaćeni porez na neiskorištene nekretnine","Potraživanja za više plaćeni porez na neiskorištene nekretnine" +"1489","kp_rrif1489","kp_rrif148","other","account_type_kratk_imovina",,,"Potraživanja za ostale poreze županije (grada), općine","Potraživanja za ostale poreze županije (grada), općine" +"149","kp_rrif149","kp_rrif14","view","account_type_view",,,"Potraživanja za ostale nespomenute poreze, doprinose, takse i pristojbe","Potraživanja za ostale nespomenute poreze, doprinose, takse i pristojbe" +"1490","kp_rrif1490","kp_rrif149","other","account_type_kratk_imovina",,,"Potraživanja za više plaćenu nadoknadu za šume","Potraživanja za više plaćenu nadoknadu za šume" +"1491","kp_rrif1491","kp_rrif149","other","account_type_kratk_imovina",,,"Potraživanja za više plaćene kazne i sl.","Potraživanja za više plaćene kazne i sl." +"1492","kp_rrif1492","kp_rrif149","other","account_type_kratk_imovina",,,"Potraživanja za više uplaćene naknade za iskorištavanje mineralnih sirovina","Potraživanja za više uplaćene naknade za iskorištavanje mineralnih sirovina" +"1493","kp_rrif1493","kp_rrif149","other","account_type_kratk_imovina",,,"Potraživanja za više plaćene naknade za koncesije","Potraživanja za više plaćene naknade za koncesije" +"1495","kp_rrif1495","kp_rrif149","other","account_type_kratk_imovina",,,"Potraživanja za spomeničku rentu","Potraživanja za spomeničku rentu" +"1497","kp_rrif1497","kp_rrif149","other","account_type_kratk_imovina",,,"Potraživanje od Fonda za razvoj i sl.","Potraživanje od Fonda za razvoj i sl." +"1499","kp_rrif1499","kp_rrif149","other","account_type_kratk_imovina",,,"Potraživanja za ostala plaćena davanja državi i državnim institucijama","Potraživanja za ostala plaćena davanja državi i državnim institucijama" +"15","kp_rrif15","kp_rrif1","view","account_type_view",,,"OSTALA POTRAŽIVANJA OD DRŽAVNIH I DRUGIH INSTITUCIJA","OSTALA POTRAŽIVANJA OD DRŽAVNIH I DRUGIH INSTITUCIJA" +"150","kp_rrif150","kp_rrif15","view","account_type_view",,,"Potraživanje za nadoknade bolovanja od HZZO","Potraživanje za nadoknade bolovanja od HZZO" +"1500","kp_rrif1500","kp_rrif150","other","account_type_kratk_imovina",,,"Potraživanje za nadoknade bolovanja od HZZO-a1","Potraživanje za nadoknade bolovanja od HZZO-Analitika 1" +"151","kp_rrif151","kp_rrif15","view","account_type_view",,,"Potraživanja od mirovinskog osiguranja","Potraživanja od mirovinskog osiguranja" +"1510","kp_rrif1510","kp_rrif151","other","account_type_kratk_imovina",,,"Potraživanja od mirovinskog osiguranja-a1","Potraživanja od mirovinskog osiguranja-Analitika 1" +"152","kp_rrif152","kp_rrif15","view","account_type_view",,,"Potraživanja od lokalne samouprave","Potraživanja od lokalne samouprave" +"1520","kp_rrif1520","kp_rrif152","other","account_type_kratk_imovina",,,"Potraživanja od lokalne samouprave-a1","Potraživanja od lokalne samouprave-Analitika 1" +"153","kp_rrif153","kp_rrif15","view","account_type_view",,,"Potraživ. za regrese, premije, stimulac. i držav. potpore","Potraživ. za regrese, premije, stimulac. i držav. potpore" +"1530","kp_rrif1530","kp_rrif153","other","account_type_kratk_imovina",,,"Potraživ. za regrese, premije, stimulac. i držav. potpore-a1","Potraživ. za regrese, premije, stimulac. i držav. potpore-Analitika 1" +"154","kp_rrif154","kp_rrif15","view","account_type_view",,,"Potraživanje od Fonda za otkupljenu ambalažu","Potraživanje od Fonda za otkupljenu ambalažu" +"1540","kp_rrif1540","kp_rrif154","other","account_type_kratk_imovina",,,"Potraživanje od Fonda za otkupljenu ambalažu-a1","Potraživanje od Fonda za otkupljenu ambalažu-Analitika 1" +"155","kp_rrif155","kp_rrif15","view","account_type_view",,,"Ostala potraživanja od državnih institucija","Ostala potraživanja od državnih institucija" +"1550","kp_rrif1550","kp_rrif155","other","account_type_kratk_imovina",,,"Ostala potraživanja od državnih institucija-a1","Ostala potraživanja od državnih institucija-Analitika 1" +"159","kp_rrif159","kp_rrif15","view","account_type_view",,,"Vrijednosno usklađenje potraživanja od države i drugih institucija","Vrijednosno usklađenje potraživanja od države i drugih institucija" +"1590","kp_rrif1590","kp_rrif159","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje potraživanja od države i drugih institucija-a1","Vrijednosno usklađenje potraživanja od države i drugih institucija-Analitika 1" +"19","kp_rrif19","kp_rrif1","view","account_type_view",,,"PLAĆENI TROŠKOVI BUDUĆEG RAZDOBLJA I OBRAČUNANI PRIHODI","PLAĆENI TROŠKOVI BUDUĆEG RAZDOBLJA I OBRAČUNANI PRIHODI" +"190","kp_rrif190","kp_rrif19","view","account_type_view",,,"Unaprijed plaćeni troškovi","Unaprijed plaćeni troškovi" +"1900","kp_rrif1900","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni troškovi održavanja, opreme, postrojenja i građevina","Unaprijed plaćeni troškovi održavanja, opreme, postrojenja i građevina" +"1901","kp_rrif1901","kp_rrif190","view","account_type_view",,,"Unaprijed plaćena zakupnina iz operativnog - poslovnog najma","Unaprijed plaćena zakupnina iz operativnog - poslovnog najma" +"19010","kp_rrif19010","kp_rrif1901","other","account_type_aktiv_razgran",,,"Unaprijed plaćena zakupnina","Unaprijed plaćena zakupnina" +"19011","kp_rrif19011","kp_rrif1901","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni a nepriznati PDV na zakupninu (npr. 30% od leasinga osob. aut.)","Unaprijed plaćeni a nepriznati PDV na zakupninu (npr. 30% od leasinga osob. aut.)" +"1902","kp_rrif1902","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni troškovi reklame, propagande i sajmova","Unaprijed plaćeni troškovi reklame, propagande i sajmova" +"1903","kp_rrif1903","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni troškovi energije za sljedeće razdoblje","Unaprijed plaćeni troškovi energije za sljedeće razdoblje" +"1904","kp_rrif1904","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni troškovi osig. imovine i osoba na opasnim poslovima ili putnika u prometu i sl.","Unaprijed plaćeni troškovi osiguranja imovine i osoba koje rade na opasnim poslovima ili putnika u prometu i sl." +"1905","kp_rrif1905","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćene kamate na bankovna jamstava i sl.","Unaprijed plaćene kamate na bankovna jamstava i sl." +"1906","kp_rrif1906","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni troškovi reprezentacije","Unaprijed plaćeni troškovi reprezentacije" +"1907","kp_rrif1907","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćene pretplate na službena glasila i stručne časopise","Unaprijed plaćene pretplate na službena glasila i stručne časopise" +"1908","kp_rrif1908","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed isplaćene plaće za buduće razdoblje","Unaprijed isplaćene plaće za buduće razdoblje" +"1909","kp_rrif1909","kp_rrif190","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni ostali troškovi posl.(prijevoza, bank. usluge, zdr. zaštita,autorski,rad po ug. i sl)","Unaprijed plaćeni ostali troškovi poslovanja (troškovi prijevoza, bankovne usluge, zdravstvena zaštita, autorski honorari, rad po ugovoru i sl.)" +"191","kp_rrif191","kp_rrif19","view","account_type_view",,,"Obračunani prihodi (budućeg razdoblja)","Obračunani prihodi (budućeg razdoblja)" +"1910","kp_rrif1910","kp_rrif191","other","account_type_aktiv_razgran",,,"Obračunani prihodi (budućeg razdoblja)-a1","Obračunani prihodi (budućeg razdoblja)-Analitika 1" +"192","kp_rrif192","kp_rrif19","view","account_type_view",,,"Unaprijed plaćeni ovisni troškovi nabave (koji nisu na 651)","Unaprijed plaćeni ovisni troškovi nabave (koji nisu na 651)" +"1920","kp_rrif1920","kp_rrif192","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni ovisni troškovi nabave (koji nisu na 651)-a1","Unaprijed plaćeni ovisni troškovi nabave (koji nisu na 651)-Analitika 1" +"193","kp_rrif193","kp_rrif19","view","account_type_view",,,"Troškovi kamata iz budućeg razdoblja","Troškovi kamata iz budućeg razdoblja" +"1930","kp_rrif1930","kp_rrif193","other","account_type_aktiv_razgran",,,"Troškovi kamata iz budućeg razdoblja-a1","Troškovi kamata iz budućeg razdoblja-Analitika 1" +"194","kp_rrif194","kp_rrif19","view","account_type_view",,,"Unaprijed plaćeni troškovi koncesija (za razdoblje do 12 mj.)","Unaprijed plaćeni troškovi koncesija (za razdoblje do 12 mj.)" +"1940","kp_rrif1940","kp_rrif194","other","account_type_aktiv_razgran",,,"Unaprijed plaćeni troškovi koncesija (za razdoblje do 12 mj.)-a1","Unaprijed plaćeni troškovi koncesija (za razdoblje do 12 mj.)-Analitika 1" +"195","kp_rrif195","kp_rrif19","view","account_type_view",,,"Unaprijed plaćene franšize, trgovačko znakovlje, prava i sl. (do 12 mj.)","Unaprijed plaćene franšize, trgovačko znakovlje, prava i sl. (do 12 mj.)" +"1950","kp_rrif1950","kp_rrif195","other","account_type_aktiv_razgran",,,"Unaprijed plaćene franšize, trgovačko znakovlje, prava i sl. (do 12 mj.)-a1","Unaprijed plaćene franšize, trgovačko znakovlje, prava i sl. (do 12 mj.)-Analitika 1" +"196","kp_rrif196","kp_rrif19","view","account_type_view",,,"Unaprijed plaćene licencije i patenti (do 12 mj.)","Unaprijed plaćene licencije i patenti (do 12 mj.)" +"1960","kp_rrif1960","kp_rrif196","other","account_type_aktiv_razgran",,,"Unaprijed plaćene licencije i patenti (do 12 mj.)-a1","Unaprijed plaćene licencije i patenti (do 12 mj.)-Analitika 1" +"199","kp_rrif199","kp_rrif19","view","account_type_view",,,"Ostali plaćeni troškovi budućeg razdoblja","Ostali plaćeni troškovi budućeg razdoblja" +"1999","kp_rrif1999","kp_rrif199","other","account_type_aktiv_razgran",,,"Ostala aktivna vremenska razgraničenja","Ostala aktivna vremenska razgraničenja" +"2","kp_rrif2","kp_rrif","view","account_type_view",,,"KRATKOROČNE I DUGOROČNE OBVEZE, DUGOROČNA REZERVIRANJA, ODGOĐENA PLAĆANJA I PRIHODI BUDUĆEG RAZDOBLJA","KRATKOROČNE I DUGOROČNE OBVEZE, DUGOROČNA REZERVIRANJA, ODGOĐENA PLAĆANJA I PRIHODI BUDUĆEG RAZDOBLJA" +"20","kp_rrif20","kp_rrif2","view","account_type_view",,,"KRATKOROČNE OBVEZE PREMA POVEZANIM PODUZETNICIMA I S OSNOVE UDJELA U REZULTATU (do jedne godine)","KRATKOROČNE OBVEZE PREMA POVEZANIM PODUZETNICIMA I S OSNOVE UDJELA U REZULTATU (do jedne godine)" +"200","kp_rrif200","kp_rrif20","view","account_type_view",,,"Obveze prema povezanim poduzetnicima","Obveze prema povezanim poduzetnicima" +"2000","kp_rrif2000","kp_rrif200","other","account_type_kratk_obveze",,,"Obveze prema povezanim društvima za zalihe (poluproizvoda, robe i sl.)","Obveze prema povezanim društvima za zalihe (poluproizvoda, robe i sl.)" +"2001","kp_rrif2001","kp_rrif200","other","account_type_kratk_obveze",,,"Obveze za raspoređeni dobitak iz poslovanja prema povezanim društvima","Obveze za raspoređeni dobitak iz poslovanja prema povezanim društvima" +"2002","kp_rrif2002","kp_rrif200","other","account_type_kratk_obveze",,,"Obveze za zajmove prema povezanim društvima","Obveze za zajmove prema povezanim društvima" +"2003","kp_rrif2003","kp_rrif200","other","account_type_kratk_obveze",,,"Obveze prema podružnicama","Obveze prema podružnicama" +"2004","kp_rrif2004","kp_rrif200","other","account_type_kratk_obveze",,,"Obveze prema osnovanim ustanovama, zadrugama i sl.","Obveze prema osnovanim ustanovama, zadrugama i sl." +"2005","kp_rrif2005","kp_rrif200","other","account_type_kratk_obveze",,,"Obveze za predujmove od povezanih društvima","Obveze za predujmove od povezanih društvima" +"2008","kp_rrif2008","kp_rrif200","other","account_type_kratk_obveze",,,"Obveze za kamate prema povezanim društvima","Obveze za kamate prema povezanim društvima" +"2009","kp_rrif2009","kp_rrif200","other","account_type_kratk_obveze",,,"Ostale kratkoročne obveze prema povezanim društvima","Ostale kratkoročne obveze prema povezanim društvima" +"201","kp_rrif201","kp_rrif20","view","account_type_view",,,"Obveze s osnove udjela u rezultatu","Obveze s osnove udjela u rezultatu" +"2010","kp_rrif2010","kp_rrif201","other","account_type_kratk_obveze",,,"Obveze s osnove udjela u dobitku (analitika prema članovima)","Obveze s osnove udjela u dobitku (analitika prema članovima)" +"2011","kp_rrif2011","kp_rrif201","other","account_type_kratk_obveze",,,"Obveze za dividende dioničarima","Obveze za dividende dioničarima" +"2012","kp_rrif2012","kp_rrif201","other","account_type_kratk_obveze",,,"Obveze za sudjelujuće dobitke u rezultatu iz zajedničkog pothvata","Obveze za sudjelujuće dobitke u rezultatu iz zajedničkog pothvata" +"2013","kp_rrif2013","kp_rrif201","other","account_type_kratk_obveze",,,"Obveze prema zadrugarima iz rezultata","Obveze prema zadrugarima iz rezultata" +"2014","kp_rrif2014","kp_rrif201","other","account_type_kratk_obveze",,,"Obveze iz dobitka prema tajnim članovima","Obveze iz dobitka prema tajnim članovima" +"2015","kp_rrif2015","kp_rrif201","other","account_type_kratk_obveze",,,"Ostale obveze s osnove udjela u dobitku","Ostale obveze s osnove udjela u dobitku" +"21","kp_rrif21","kp_rrif2","view","account_type_view",,,"KRATKOROČNE FINANCIJSKE OBVEZE","KRATKOROČNE FINANCIJSKE OBVEZE" +"210","kp_rrif210","kp_rrif21","view","account_type_view",,,"Obveze za izdane čekove","Obveze za izdane čekove" +"2100","kp_rrif2100","kp_rrif210","other","account_type_kratk_obveze",,,"Obveze za izdane čekove-a1","Obveze za izdane čekove-Analitika 1" +"211","kp_rrif211","kp_rrif21","view","account_type_view",,,"Obveze za izdane mjenice","Obveze za izdane mjenice" +"2110","kp_rrif2110","kp_rrif211","other","account_type_kratk_obveze",,,"Obveze za dane mjenice","Obveze za dane mjenice" +"2111","kp_rrif2111","kp_rrif211","other","account_type_kratk_obveze",,,"Obveze za dane mjenične akcepte","Obveze za dane mjenične akcepte" +"212","kp_rrif212","kp_rrif21","view","account_type_view",,,"Obveze po izdanim vrijednosnim papirima","Obveze po izdanim vrijednosnim papirima" +"2120","kp_rrif2120","kp_rrif212","other","account_type_kratk_obveze",,,"Obveze po izdanim komercijalnim zapisima","Obveze po izdanim komercijalnim zapisima" +"2121","kp_rrif2121","kp_rrif212","other","account_type_kratk_obveze",,,"Obveze po izdanim obveznicama","Obveze po izdanim obveznicama" +"2122","kp_rrif2122","kp_rrif212","other","account_type_kratk_obveze",,,"Obveze po izdanim zadužnicama","Obveze po izdanim zadužnicama" +"2123","kp_rrif2123","kp_rrif212","other","account_type_kratk_obveze",,,"Obveze po ostalim kratkoročnim vrijednosnim papirima","Obveze po ostalim kratkoročnim vrijednosnim papirima" +"2128","kp_rrif2128","kp_rrif212","other","account_type_kratk_obveze",,,"Obveze za kamate sadržane u vrijed. papirima","Obveze za kamate sadržane u vrijed. papirima" +"213","kp_rrif213","kp_rrif21","view","account_type_view",,,"Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)","Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)" +"2130","kp_rrif2130","kp_rrif213","other","account_type_kratk_obveze",,,"Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)-a1","Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)-Analitika 1" +"214","kp_rrif214","kp_rrif21","view","account_type_view",,,"Obveze s osnove zajmova, depozita i sl.","Obveze s osnove zajmova, depozita i sl." +"2140","kp_rrif2140","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za financijske zajmove od društava","Obveze za financijske zajmove od društava" +"2141","kp_rrif2141","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za zajmove od ustanova, zadruga i sl.","Obveze za zajmove od ustanova, zadruga i sl." +"2142","kp_rrif2142","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za kratkoročne zajmove iz inozemstva","Obveze za kratkoročne zajmove iz inozemstva" +"2143","kp_rrif2143","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za dio dospjelih dugoročnih zajmova koji se trebaju platiti u roku 12 mj.","Obveze za dio dospjelih dugoročnih zajmova koji se trebaju platiti u roku 12 mj." +"2144","kp_rrif2144","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za zajmove prema građanima","Obveze za zajmove prema građanima" +"2145","kp_rrif2145","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za zajmove članova društva","Obveze za zajmove članova društva" +"2146","kp_rrif2146","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze po kontokorentnom računu","Obveze po kontokorentnom računu" +"2147","kp_rrif2147","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za depozite, jamčevine i kapare","Obveze za depozite, jamčevine i kapare" +"2148","kp_rrif2148","kp_rrif214","other","account_type_kratk_obveze",,,"Obveze za kaucije","Obveze za kaucije" +"2149","kp_rrif2149","kp_rrif214","other","account_type_kratk_obveze",,,"Ostali kratkoročni zajmovi i sl.","Ostali kratkoročni zajmovi i sl." +"215","kp_rrif215","kp_rrif21","view","account_type_view",,,"Obveze prema bankama i drugim financijskim institucijama","Obveze prema bankama i drugim financijskim institucijama" +"2150","kp_rrif2150","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze za kratkoročne kredite u banci (analitika po bankama a unutar banke po ugovorima o kreditu)","Obveze za kratkoročne kredite u banci (analitika po bankama a unutar banke po ugovorima o kreditu)" +"2151","kp_rrif2151","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze za kratkoročne kredite u osiguravajućim društvima (analitika po društvima i kreditima)","Obveze za kratkoročne kredite u osiguravajućim društvima (analitika po društvima i kreditima)" +"2152","kp_rrif2152","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze prema ostalim kreditnim institucijama (štedionicama, mirovinskom fondu i dr.)","Obveze prema ostalim kreditnim institucijama (štedionicama, mirovinskom fondu i dr.)" +"2153","kp_rrif2153","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze prema kreditnim institucijama i bankama u inozemstvu","Obveze prema kreditnim institucijama i bankama u inozemstvu" +"2154","kp_rrif2154","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze prema bankama po naplaćenim garancijama","Obveze prema bankama po naplaćenim garancijama" +"2155","kp_rrif2155","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze po isplaćenom akreditivu","Obveze po isplaćenom akreditivu" +"2156","kp_rrif2156","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze za prekoračenje na računu (okvirni kredit)","Obveze za prekoračenje na računu (okvirni kredit)" +"2157","kp_rrif2157","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze za kamate prema bankama","Obveze za kamate prema bankama" +"2158","kp_rrif2158","kp_rrif215","other","account_type_kratk_obveze",,,"Obveze za kamate prema financ. institucijama","Obveze za kamate prema financ. institucijama" +"2159","kp_rrif2159","kp_rrif215","other","account_type_kratk_obveze",,,"Ostale obveze prema kreditnim institucijama","Ostale obveze prema kreditnim institucijama" +"216","kp_rrif216","kp_rrif21","view","account_type_view",,,"Obveze prema izdavateljima kreditnih kartica (analitika prema kartičarima)","Obveze prema izdavateljima kreditnih kartica (analitika prema kartičarima)" +"2160","kp_rrif2160","kp_rrif216","other","account_type_kratk_obveze",,,"Obveze prema izdavateljima kreditnih kartica (analitika prema kartičarima)-a1","Obveze prema izdavateljima kreditnih kartica (analitika prema kartičarima)-Analitika 1" +"217","kp_rrif217","kp_rrif21","view","account_type_view",,,"Obveze iz eskontnih poslova","Obveze iz eskontnih poslova" +"2170","kp_rrif2170","kp_rrif217","other","account_type_kratk_obveze",,,"Obveze s temelja eskontiranih mjenica","Obveze s temelja eskontiranih mjenica" +"2171","kp_rrif2171","kp_rrif217","other","account_type_kratk_obveze",,,"Ostale obveze iz eskonta vrijednosnih papira","Ostale obveze iz eskonta vrijednosnih papira" +"2172","kp_rrif2172","kp_rrif217","other","account_type_kratk_obveze",,,"Obveze iz otkupa tražbina","Obveze iz otkupa tražbina" +"218","kp_rrif218","kp_rrif21","view","account_type_view",,,"Obveze s osnove dugotrajne imovine namijenjene prodaji (analitika prema izvorima)","Obveze s osnove dugotrajne imovine namijenjene prodaji (analitika prema izvorima)" +"2180","kp_rrif2180","kp_rrif218","other","account_type_kratk_obveze",,,"Obveze s osnove dugotrajne imovine namijenjene prodaji (analitika prema izvorima)-a1","Obveze s osnove dugotrajne imovine namijenjene prodaji (analitika prema izvorima)-Analitika 1" +"22","kp_rrif22","kp_rrif2","view","account_type_view",,,"OBVEZE PREMA DOBAVLJAČIMA, ZA PREDUJMOVE I OSTALE OBVEZE","OBVEZE PREMA DOBAVLJAČIMA, ZA PREDUJMOVE I OSTALE OBVEZE" +"220","kp_rrif220","kp_rrif22","view","account_type_view",,,"Obveze prema dobavljačima u zemlji (analitika prema dobavljačima)","Obveze prema dobavljačima u zemlji (analitika prema dobavljačima)" +"2200","kp_rrif2200","kp_rrif220","payable","account_type_obveze_dob","True",,"Dobavljači dobara","Dobavljači dobara" +"2201","kp_rrif2201","kp_rrif220","payable","account_type_obveze_dob","True",,"Dobavljači usluga","Dobavljači usluga" +"2202","kp_rrif2202","kp_rrif220","payable","account_type_obveze_dob","True",,"Dobavljači opreme, postrojenja i nekretnina","Dobavljači opreme, postrojenja i nekretnina" +"2203","kp_rrif2203","kp_rrif220","payable","account_type_obveze_dob","True",,"Dobavljači nematerijalne imovine","Dobavljači nematerijalne imovine" +"2204","kp_rrif2204","kp_rrif220","payable","account_type_obveze_dob","True",,"Dobavljači iz operativnog lizinga (za najmove)","Dobavljači iz operativnog lizinga (za najmove)" +"2205","kp_rrif2205","kp_rrif220","payable","account_type_obveze_dob","True",,"Dobavljači iz ortačkog ugovora","Dobavljači iz ortačkog ugovora" +"2206","kp_rrif2206","kp_rrif220","payable","account_type_obveze_dob","True",,"Dobavljači zadruge, ustanove i dr.","Dobavljači zadruge, ustanove i dr." +"221","kp_rrif221","kp_rrif22","view","account_type_view",,,"Dobavljači iz inozemstva (analitika prema dobavljačima)","Dobavljači iz inozemstva (analitika prema dobavljačima)" +"2210","kp_rrif2210","kp_rrif221","payable","account_type_obveze_dob","True",,"Dobavljači dobara iz inozemstva","Dobavljači dobara iz inozemstva" +"2211","kp_rrif2211","kp_rrif221","payable","account_type_obveze_dob","True",,"Dobavljači usluga iz inozemstva","Dobavljači usluga iz inozemstva" +"2212","kp_rrif2212","kp_rrif221","payable","account_type_obveze_dob","True",,"Dobavljači prava intelektualnog vlasništva, istraživanja tržišta i dr.","Dobavljači prava intelektualnog vlasništva, istraživanja tržišta i dr." +"2213","kp_rrif2213","kp_rrif221","payable","account_type_obveze_dob","True",,"Dobavljači prava na franšizu, uporabu imena i sl.","Dobavljači prava na franšizu, uporabu imena i sl." +"222","kp_rrif222","kp_rrif22","view","account_type_view",,,"Dobavljači fizičke osobe","Dobavljači fizičke osobe" +"2220","kp_rrif2220","kp_rrif222","payable","account_type_obveze_dob","True",,"Dobavljači, obrtnici i slobodna zanimanja","Dobavljači, obrtnici i slobodna zanimanja" +"2221","kp_rrif2221","kp_rrif222","payable","account_type_obveze_dob","True",,"Dobavljači fizičke osobe (za isporučene osnovne proizvode poljodjelstva, ribarstva i šumarstva)","Dobavljači fizičke osobe (za isporučene osnovne proizvode poljodjelstva, ribarstva i šumarstva)" +"2222","kp_rrif2222","kp_rrif222","payable","account_type_obveze_dob","True",,"Dobavljači za isporučenu osobnu imovinu","Dobavljači za isporučenu osobnu imovinu" +"2223","kp_rrif2223","kp_rrif222","payable","account_type_obveze_dob","True",,"Obveze s osnove autorskih prava, inovacija, patenata i sl.","Obveze s osnove autorskih prava, inovacija, patenata i sl." +"2224","kp_rrif2224","kp_rrif222","payable","account_type_obveze_dob","True",,"Obveze s osnove ugovora o djelu i akviziterstva","Obveze s osnove ugovora o djelu i akviziterstva" +"2225","kp_rrif2225","kp_rrif222","payable","account_type_obveze_dob","True",,"Obveze prema studentima i učenicima za rad preko studentskog servisa","Obveze prema studentima i učenicima za rad preko studentskog servisa" +"2226","kp_rrif2226","kp_rrif222","payable","account_type_obveze_dob","True",,"Dobavljači kooperanti - fizičke osobe","Dobavljači kooperanti - fizičke osobe" +"2229","kp_rrif2229","kp_rrif222","payable","account_type_obveze_dob","True",,"Ostali dobavljači - fizičke osobe","Ostali dobavljači - fizičke osobe" +"223","kp_rrif223","kp_rrif22","view","account_type_view",,,"Dobavljači komunalnih usluga","Dobavljači komunalnih usluga" +"2230","kp_rrif2230","kp_rrif223","payable","account_type_obveze_dob","True",,"Obveze za energetske isporuke","Obveze za energetske isporuke" +"2231","kp_rrif2231","kp_rrif223","payable","account_type_obveze_dob","True",,"Obveze za usluge odvodnje i odvoza smeća","Obveze za usluge odvodnje i odvoza smeća" +"2232","kp_rrif2232","kp_rrif223","payable","account_type_obveze_dob","True",,"Obveze za ostale komunalne usluge","Obveze za ostale komunalne usluge" +"224","kp_rrif224","kp_rrif22","view","account_type_view",,,"Obveze za nefakturirane a preuzete isporuke robe i usluge","Obveze za nefakturirane a preuzete isporuke robe i usluge" +"2240","kp_rrif2240","kp_rrif224","payable","account_type_obveze_dob","True",,"Obveze za nefakturirane a preuzete isporuke robe i usluge-a1","Obveze za nefakturirane a preuzete isporuke robe i usluge-Analitika 1" +"225","kp_rrif225","kp_rrif22","view","account_type_view",,,"Obveze za predujmove","Obveze za predujmove" +"2250","kp_rrif2250","kp_rrif225","payable","account_type_obveze_dob","True",,"Primljeni predujmovi za koje su izdani računi s PDV-om","Primljeni predujmovi za koje su izdani računi s PDV-om" +"2251","kp_rrif2251","kp_rrif225","payable","account_type_obveze_dob","True",,"Primljeni predujmovi koji nisu pod PDV-om","Primljeni predujmovi koji nisu pod PDV-om" +"2252","kp_rrif2252","kp_rrif225","payable","account_type_obveze_dob","True",,"Primljeni predujmovi iz inozemstva","Primljeni predujmovi iz inozemstva" +"2253","kp_rrif2253","kp_rrif225","payable","account_type_obveze_dob","True",,"Obveze za predujmove građana","Obveze za predujmove građana" +"23","kp_rrif23","kp_rrif2","view","account_type_view",,,"OBVEZE PREMA ZAPOSLENIMA I OSTALE OBVEZE","OBVEZE PREMA ZAPOSLENIMA I OSTALE OBVEZE" +"230","kp_rrif230","kp_rrif23","view","account_type_view",,,"Obveze prema zaposlenicima","Obveze prema zaposlenicima" +"2300","kp_rrif2300","kp_rrif230","other","account_type_kratk_obveze",,,"Obveze za neto-plaće","Obveze za neto-plaće" +"2301","kp_rrif2301","kp_rrif230","other","account_type_kratk_obveze",,,"Nadoknade plaća koje se refundiraju (od državnih institucija, od HZZO, od lokalne samoupr.)","Nadoknade plaća koje se refundiraju (od državnih institucija, od HZZO, od lokalne samoupr.)" +"2302","kp_rrif2302","kp_rrif230","other","account_type_kratk_obveze",,,"Obveze za nadoknade troškova (dnevnice, terenski dod.,troškovi sl. puta, km,dolazak na posao i dr.)","Obveze za nadoknade troškova (dnevnice, terenski dodatak, nadoknade troškova službenog puta, uključivo i kilometraža, nadoknade za dolazak na posao i dr.)" +"2303","kp_rrif2303","kp_rrif230","other","account_type_kratk_obveze",,,"Obveze za darove i potpore (božićnica, dar djeci, potpora zbog bolesti, regres za g. o. i sl.)","Obveze za darove i potpore (božićnica, dar djeci, potpora zbog bolesti, regres za g. o. i sl.)" +"2304","kp_rrif2304","kp_rrif230","other","account_type_kratk_obveze",,,"Obveze prema zaposlenima za primitke koji se smatraju dohotkom (prehrana, davanja u naravi i sl.)","Obveze prema zaposlenima za primitke koji se smatraju dohotkom (prehrana, davanja u naravi i sl.)" +"2305","kp_rrif2305","kp_rrif230","other","account_type_kratk_obveze",,,"Obveze prema zaposlenima zbog otpremnine, jubilarne, odvojeni život, pomoć obitelji umrlog posloprimca","Obveze prema zaposlenima s temelja otpremnine, jubilarne nagrade, nadoknade za odvojeni život, pomoći obitelji umrlog posloprimca i sl." +"2306","kp_rrif2306","kp_rrif230","view","account_type_view",,,"Obveze za obustave iz neto-plaća i nadoknada plaća","Obveze za obustave iz neto-plaća i nadoknada plaća" +"23060","kp_rrif23060","kp_rrif2306","other","account_type_kratk_obveze",,,"Obveze za obustave iz neto-plaće za isplate kredita i pozajmica","Obveze za obustave iz neto-plaće za isplate kredita i pozajmica" +"23061","kp_rrif23061","kp_rrif2306","other","account_type_kratk_obveze",,,"Obveze za obustave iz neto-plaća i nadoknada za sudske zabrane, kazne i sl.","Obveze za obustave iz neto-plaća i nadoknada za sudske zabrane, kazne i sl." +"23062","kp_rrif23062","kp_rrif2306","other","account_type_kratk_obveze",,,"Obveze iz ovrha na neto-plaći","Obveze iz ovrha na neto-plaći" +"23063","kp_rrif23063","kp_rrif2306","other","account_type_kratk_obveze",,,"Obveze za obustave iz neto-plaća i nadoknada plaća za članarine, i dr.","Obveze za obustave iz neto-plaća i nadoknada plaća za članarine, i dr." +"2307","kp_rrif2307","kp_rrif230","other","account_type_kratk_obveze",,,"Obveze prema zaposlenima za zatezne kamate i sl.","Obveze prema zaposlenima za zatezne kamate i sl." +"2308","kp_rrif2308","kp_rrif230","other","account_type_kratk_obveze",,,"Obveza prema zaposlenima za naknadu šteta: zbog ozljede na radu, neiskorištenog godišnjeg odmora i sl.","Obveza prema zaposlenima za naknadu šteta: zbog ozljede na radu, neiskorištenog godišnjeg odmora i sl." +"2309","kp_rrif2309","kp_rrif230","other","account_type_kratk_obveze",,,"Obveze za obračunanu bruto-plaću iz prošle poslovne godine (koje nisu isplaćene i XIII. plaća)","Obveze za obračunanu bruto-plaću iz prošle poslovne godine (koje nisu isplaćene i XIII. plaća)" +"231","kp_rrif231","kp_rrif23","view","account_type_view",,,"Kratkoročne obveze iz nabava i potpora","Kratkoročne obveze iz nabava i potpora" +"2310","kp_rrif2310","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze s temelja tekuće nabave u gotovini","Obveze s temelja tekuće nabave u gotovini" +"2311","kp_rrif2311","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze prema vanjskim članovima uprave, nadzornog odbora, prokuristima, stečajnim upraviteljima i sl.","Obveze prema vanjskim članovima uprave, nadzornog odbora, prokuristima, stečajnim upraviteljima i sl." +"2312","kp_rrif2312","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze za preuzeta plaćanja temeljem ugovora o cesiji, asignaciji i preuzimanjem duga","Obveze za preuzeta plaćanja temeljem ugovora o cesiji, asignaciji i preuzimanjem duga" +"2313","kp_rrif2313","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze za ugovorene penale, kazne i sl.","Obveze za ugovorene penale, kazne i sl." +"2314","kp_rrif2314","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze za darovanja (do 2% od ukupnog prihoda)","Obveze za darovanja (do 2% od ukupnog prihoda)" +"2315","kp_rrif2315","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze za nadoknadu troškova (refundacije)","Obveze za nadoknadu troškova (refundacije)" +"2316","kp_rrif2316","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze za naknadno odobrene bonifikacije, casasconte i druge popuste","Obveze za naknadno odobrene bonifikacije, casasconte i druge popuste" +"2317","kp_rrif2317","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze za stipendije","Obveze za stipendije" +"2318","kp_rrif2318","kp_rrif231","other","account_type_kratk_obveze",,,"Obveze za primljene potpore (nisu za prihod)","Obveze za primljene potpore (nisu za prihod)" +"2319","kp_rrif2319","kp_rrif231","other","account_type_kratk_obveze",,,"Ostale kratkoročne obveze (npr. prema vanjskim suradnicima)","Ostale kratkoročne obveze(npr. prema vanjskim suradnicima)" +"232","kp_rrif232","kp_rrif23","view","account_type_view",,,"Obveze za kamate (analitika prema dužnicima i vrstama obveza prema nepovezanim društvima)","Obveze za kamate (analitika prema dužnicima i vrstama obveza prema nepovezanim društvima)" +"2320","kp_rrif2320","kp_rrif232","other","account_type_kratk_obveze",,,"Obveze za ugovorenu kamatu","Obveze za ugovorenu kamatu" +"2321","kp_rrif2321","kp_rrif232","other","account_type_kratk_obveze",,,"Obveze za zateznu kamatu","Obveze za zateznu kamatu" +"2322","kp_rrif2322","kp_rrif232","other","account_type_kratk_obveze",,,"Obveze za kamate na zajmove prema poduzetnicima","Obveze za kamate na zajmove prema poduzetnicima" +"2323","kp_rrif2323","kp_rrif232","other","account_type_kratk_obveze",,,"Obveze za kamate po sudskim sporovima","Obveze za kamate po sudskim sporovima" +"233","kp_rrif233","kp_rrif23","view","account_type_view",,,"Obveze po obračunu prodanih dobara primljenih u komisiju ili konsignaciju","Obveze po obračunu prodanih dobara primljenih u komisiju ili konsignaciju" +"2330","kp_rrif2330","kp_rrif233","other","account_type_kratk_obveze",,,"Obveze po obračunu za prodana dobra","Obveze po obračunu za prodana dobra" +"2331","kp_rrif2331","kp_rrif233","other","account_type_kratk_obveze",,,"Obveze za isplatu komitentu","Obveze za isplatu komitentu" +"2332","kp_rrif2332","kp_rrif233","other","account_type_kratk_obveze",,,"Obveze prema nalogodavatelju iz zastupničke prodaje","Obveze prema nalogodavatelju iz zastupničke prodaje" +"234","kp_rrif234","kp_rrif23","view","account_type_view",,,"Obveze prema osiguravajućim društvima","Obveze prema osiguravajućim društvima" +"2340","kp_rrif2340","kp_rrif234","other","account_type_kratk_obveze",,,"Obveze iz osiguranja imovine i osoba","Obveze iz osiguranja imovine i osoba" +"2341","kp_rrif2341","kp_rrif234","other","account_type_kratk_obveze",,,"Obveze za životna osiguranja","Obveze za životna osiguranja" +"2342","kp_rrif2342","kp_rrif234","other","account_type_kratk_obveze",,,"Obveze za III. stupu mirovinskog osiguranja","Obveze za III. stupu mirovinskog osiguranja" +"2343","kp_rrif2343","kp_rrif234","other","account_type_kratk_obveze",,,"Obveze za premije zdravstvenog osiguranja","Obveze za premije zdravstvenog osiguranja" +"2344","kp_rrif2344","kp_rrif234","other","account_type_kratk_obveze",,,"Obveze za dopunsko zdravstveno osiguranje","Obveze za dopunsko zdravstveno osiguranje" +"235","kp_rrif235","kp_rrif23","view","account_type_view",,,"Obveze iz poslovanja u slobodnoj zoni","Obveze iz poslovanja u slobodnoj zoni" +"2350","kp_rrif2350","kp_rrif235","other","account_type_kratk_obveze",,,"Obveze iz poslovanja u slobodnoj zoni-a1","Obveze iz poslovanja u slobodnoj zoni-Analitika 1" +"236","kp_rrif236","kp_rrif23","view","account_type_view",,,"Obveze iz vanjskotrgovačkog poslovanja","Obveze iz vanjskotrgovačkog poslovanja" +"2360","kp_rrif2360","kp_rrif236","other","account_type_kratk_obveze",,,"Obveze prema uvozniku (ili naručitelju)","Obveze prema uvozniku (ili naručitelju)" +"2361","kp_rrif2361","kp_rrif236","other","account_type_kratk_obveze",,,"Obveze po poslovima izvoza za tuđi račun","Obveze po poslovima izvoza za tuđi račun" +"237","kp_rrif237","kp_rrif23","view","account_type_view",,,"Obveze prema poslovnim jedinicama u inozemstvu","Obveze prema poslovnim jedinicama u inozemstvu" +"2370","kp_rrif2370","kp_rrif237","other","account_type_kratk_obveze",,,"Obveze prema P.J. u inozemstvu","Obveze prema P.J. u inozemstvu" +"2371","kp_rrif2371","kp_rrif237","other","account_type_kratk_obveze",,,"Obveze prema podružnicama u inozemstvu","Obveze prema podružnicama u inozemstvu" +"238","kp_rrif238","kp_rrif23","view","account_type_view",,,"Obveze iz stjecanja udjela","Obveze iz stjecanja udjela" +"2380","kp_rrif2380","kp_rrif238","other","account_type_kratk_obveze",,,"Obveze za uplaćeni a neupisani temeljni kapital","Obveze za uplaćeni a neupisani temeljni kapital" +"2381","kp_rrif2381","kp_rrif238","other","account_type_kratk_obveze",,,"Obveze za kupnju poslovnog udjela","Obveze za kupnju poslovnog udjela" +"239","kp_rrif239","kp_rrif23","view","account_type_view",,,"Ostale kratkoročne obveze","Ostale kratkoročne obveze" +"2390","kp_rrif2390","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze prema odštetnim zahtjevima","Obveze prema odštetnim zahtjevima" +"2391","kp_rrif2391","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze prema brokerima za kupljene vrijednosne papire","Obveze prema brokerima za kupljene vrijednosne papire" +"2392","kp_rrif2392","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze za doprinos za komunalnu infrastrukturu","Obveze za doprinos za komunalnu infrastrukturu" +"2393","kp_rrif2393","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze za PDV iz poslovnih odnosa","Obveze za PDV iz poslovnih odnosa" +"2394","kp_rrif2394","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze iz primjene valutne klauzule","Obveze iz primjene valutne klauzule" +"2395","kp_rrif2395","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze s osnove sudskih presuda","Obveze s osnove sudskih presuda" +"2396","kp_rrif2396","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze iz ortaštva","Obveze iz ortaštva" +"2397","kp_rrif2397","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze za tuđa sredstva","Obveze za tuđa sredstva" +"2398","kp_rrif2398","kp_rrif239","other","account_type_kratk_obveze",,,"Obveze prema inozemnom poduzet. za PDV","Obveze prema inozemnom poduzet. za PDV" +"2399","kp_rrif2399","kp_rrif239","other","account_type_kratk_obveze",,,"Ostale nespomenute obveze","Ostale nespomenute obveze" +"24","kp_rrif24","kp_rrif2","view","account_type_view",,,"KRATKOROČNE OBVEZE ZA POREZE, DOPRINOSE I SLIČNA DAVANJA","KRATKOROČNE OBVEZE ZA POREZE, DOPRINOSE I SLIČNA DAVANJA" +"240","kp_rrif240","kp_rrif24","view","account_type_view",,,"Obveze za porez na dodanu vrijednost","Obveze za porez na dodanu vrijednost" +"2400","kp_rrif2400","kp_rrif240","view","account_type_view",,,"Obveza za PDV po isporukama","Obveza za PDV po isporukama" +"24000","kp_rrif24000","kp_rrif2400","other","account_type_pdv",,,"Obveza za PDV - 10%","Obveza za PDV - 10%" +"24001","kp_rrif24001","kp_rrif2400","other","account_type_pdv",,,"Obveza za PDV - 22%","Obveza za PDV - 22%" +"24002","kp_rrif24002","kp_rrif2400","other","account_type_pdv",,,"Obveza za PDV - 23%","Obveza za PDV - 23%" +"24003","kp_rrif24003","kp_rrif2400","other","account_type_pdv",,,"Obveza za PDV - 25%","Obveza za PDV - 25%" +"2401","kp_rrif2401","kp_rrif240","view","account_type_view",,,"Obveza za PDV-a prema računu za predujam","Obveza za PDV-a prema računu za predujam" +"24010","kp_rrif24010","kp_rrif2401","other","account_type_pdv",,,"Obveza za PDV za predujam - 10%","Obveza za PDV za predujam - 10%" +"24011","kp_rrif24011","kp_rrif2401","other","account_type_pdv",,,"Obveza za PDV za predujam - 22%","Obveza za PDV za predujam - 22%" +"24012","kp_rrif24012","kp_rrif2401","other","account_type_pdv",,,"Obveza za PDV za predujam - 23%","Obveza za PDV za predujam - 23%" +"24013","kp_rrif24013","kp_rrif2401","other","account_type_pdv",,,"Obveza za PDV za predujam - 25%","Obveza za PDV za predujam - 25%" +"2402","kp_rrif2402","kp_rrif240","other","account_type_pdv",,,"Obveze za PDV s osnove vlastite potrošnje - 23% (za proizv. za reprez. te za o.auto. nab. do 2010.)","Obveze za PDV s osnove vlastite potrošnje - 23% (za uporabu proizv. za reprezentaciju te za osobne automobile nabavljene do 1.I. 2010.)" +"2403","kp_rrif2403","kp_rrif240","view","account_type_view",,,"Obveza za PDV po nezaračunanim isporukama","Obveza za PDV po nezaračunanim isporukama" +"24030","kp_rrif24030","kp_rrif2403","other","account_type_pdv",,,"Obveza za PDV po nezaračunanim isporukama - 10%","Obveza za PDV po nezaračunanim isporukama - 10%" +"24031","kp_rrif24031","kp_rrif2403","other","account_type_pdv",,,"Obveza za PDV po nezaračunanim isporukama - 22%","Obveza za PDV po nezaračunanim isporukama - 22%" +"24032","kp_rrif24032","kp_rrif2403","other","account_type_pdv",,,"Obveza za PDV po nezaračunanim isporukama - 23%","Obveza za PDV po nezaračunanim isporukama - 23%" +"24033","kp_rrif24033","kp_rrif2403","other","account_type_pdv",,,"Obveza za PDV po nezaračunanim isporukama - 25%","Obveza za PDV po nezaračunanim isporukama - 25%" +"2404","kp_rrif2404","kp_rrif240","view","account_type_view",,,"Obveze za ispravljeni PDV zbog prenamjene dobara","Obveze za ispravljeni PDV zbog prenamjene dobara" +"24041","kp_rrif24041","kp_rrif2404","other","account_type_pdv",,,"Obveza za PDV zbog promjene postotka priznavanja PDV-a","Obveza za PDV zbog promjene postotka priznavanja PDV-a" +"2405","kp_rrif2405","kp_rrif240","other","account_type_pdv",,,"Obračunana a nedospjela obveza za PDV","Obračunana a nedospjela obveza za PDV" +"2406","kp_rrif2406","kp_rrif240","view","account_type_pdv",,,"Obveza za PDV koje se ne izvještavaju u obrascu PDV","Obveza za PDV koje se ne izvještavaju u obrascu PDV" +"24060","kp_rrif24060","kp_rrif2406","other","account_type_pdv",,,"Obveza za PDV po Rješenju PU","Obveza za PDV po Rješenju PU" +"24061","kp_rrif24061","kp_rrif2406","other","account_type_pdv",,,"Obveza za PDV na inozemne usluge","Obveza za PDV inozemne usluge" +"2407","kp_rrif2407","kp_rrif240","other","account_type_pdv",,,"Obveza za razliku poreza i pretporeza u obračunskom razdoblju","Obveza za razliku poreza i pretporeza u obračunskom razdoblju" +"2408","kp_rrif2408","kp_rrif240","other","account_type_pdv",,,"Povrat PDV-a iz putničkog prometa","Povrat PDV-a iz putničkog prometa" +"2409","kp_rrif2409","kp_rrif240","other","account_type_pdv",,,"Obveza za PDV po konačnom obračunu","Obveza za PDV po konačnom obračunu" +"241","kp_rrif241","kp_rrif24","view","account_type_view",,,"Obveze za porez i prirez na dohodak","Obveze za porez i prirez na dohodak" +"2410","kp_rrif2410","kp_rrif241","other","account_type_kratk_obveze",,,"Obveze za porez na dohodak iz plaća i primitaka izjednačenih s plaćom","Obveze za porez na dohodak iz plaća i primitaka izjednačenih s plaćom" +"2411","kp_rrif2411","kp_rrif241","other","account_type_kratk_obveze",,,"Obveze za prirez iz plaća i primitaka izjednačenih s plaćama","Obveze za prirez iz plaća i primitaka izjednačenih s plaćama" +"2412","kp_rrif2412","kp_rrif241","other","account_type_kratk_obveze",,,"Obveze za porez i prirez na drugi dohodak (autorski honorari, ug. o djelu, doh. članova nadz.i dr.)","Obveze za porez i prirez na drugi dohodak (iz autorskih honorara, ugovora o djelu, dohodaka članova nadzornog odbora i dr.)" +"2413","kp_rrif2413","kp_rrif241","other","account_type_kratk_obveze",,,"Obveze za porez i prirez iz stipendija i nagrada učenika na praksi","Obveze za porez i prirez iz stipendija i nagrada učenika na praksi" +"2414","kp_rrif2414","kp_rrif241","other","account_type_kratk_obveze",,,"Obveze za porez i prirez za ostale dohotke","Obveze za porez i prirez za ostale dohotke" +"242","kp_rrif242","kp_rrif24","view","account_type_view",,,"Obveze za doprinose za osiguranja","Obveze za doprinose za osiguranja" +"2420","kp_rrif2420","kp_rrif242","other","account_type_kratk_obveze",,,"Doprinos za MO iz plaća (I. stup)","Doprinos za MO iz plaća (I. stup)" +"2421","kp_rrif2421","kp_rrif242","other","account_type_kratk_obveze",,,"Doprinos za MO iz plaća (II. stup - analitika prema fondovima)","Doprinos za MO iz plaća (II. stup - analitika prema fondovima)" +"2422","kp_rrif2422","kp_rrif242","other","account_type_kratk_obveze",,,"Doprinos za MO za beneficirani staž (I. i II. stup)","Doprinos za MO za beneficirani staž (I. i II. stup)" +"2423","kp_rrif2423","kp_rrif242","other","account_type_kratk_obveze",,,"Doprinos za zdravstveno osiguranje na plaće","Doprinos za zdravstveno osiguranje na plaće" +"2424","kp_rrif2424","kp_rrif242","other","account_type_kratk_obveze",,,"Poseban doprinos za zdravstveno osiguranje na plaće za ozljede na radu i prof. bolesti","Poseban doprinos za zdravstveno osiguranje na plaće za ozljede na radu i prof. bolesti" +"2426","kp_rrif2426","kp_rrif242","other","account_type_kratk_obveze",,,"Doprinos za zapošljavanje na plaću","Doprinos za zapošljavanje na plaću" +"2427","kp_rrif2427","kp_rrif242","view","account_type_view",,,"Doprinosi za osiguranja na druge dohotke","Doprinosi za osiguranja na druge dohotke" +"24270","kp_rrif24270","kp_rrif2427","other","account_type_kratk_obveze",,,"Doprinos za MO I. stup","Doprinos za MO I. stup" +"24271","kp_rrif24271","kp_rrif2427","other","account_type_kratk_obveze",,,"Doprinos za MO II. stup","Doprinos za MO II. stup" +"24272","kp_rrif24272","kp_rrif2427","other","account_type_kratk_obveze",,,"Doprinos za zdravstveno osiguranje na honorar","Doprinos za zdravstveno osiguranje na honorar" +"2428","kp_rrif2428","kp_rrif242","other","account_type_kratk_obveze",,,"Doprinos HZZO-u na službena putovanja u inozemstvo","Doprinos HZZO-u na službena putovanja u inozemstvo" +"2429","kp_rrif2429","kp_rrif242","other","account_type_kratk_obveze",,,"Obveze za ostale nespomenute doprinose koji se plaćaju na dohotke","Obveze za ostale nespomenute doprinose koji se plaćaju na dohotke" +"243","kp_rrif243","kp_rrif24","view","account_type_view",,,"Obveze za porez na dobitak, dohodak od kapitala i porez po odbitku","Obveze za porez na dobitak, dohodak od kapitala i porez po odbitku" +"2430","kp_rrif2430","kp_rrif243","other","account_type_kratk_obveze",,,"Obveze za porez na dobitak","Obveze za porez na dobitak" +"2431","kp_rrif2431","kp_rrif243","view","account_type_view",,,"Obveze za porez na dohotke od kapitala","Obveze za porez na dohotke od kapitala" +"24310","kp_rrif24310","kp_rrif2431","other","account_type_kratk_obveze",,,"Porez na dohodak od kapitala na izuzimanja ili privatni život članova društva i dioničara (40%+prirez)","Porez na dohodak od kapitala na izuzimanja ili privatni život članova društva i dioničara (40% + prirez)" +"24311","kp_rrif24311","kp_rrif2431","other","account_type_kratk_obveze",,,"Porez na dohodak od kapitala na isplate dobitka i dividendi (iz 2001. do 2004. = 12% + prirez)","Porez na dohodak od kapitala na isplate dobitka i dividendi (iz 2001. do 2004. = 12% + prirez)" +"24312","kp_rrif24312","kp_rrif2431","other","account_type_kratk_obveze",,,"Porez na dohodak od kapitala na kamate (na zajmove fizičkih osoba = 40% + prirez)","Porez na dohodak od kapitala na kamate (na zajmove fizičkih osoba = 40% + prirez)" +"24313","kp_rrif24313","kp_rrif2431","other","account_type_kratk_obveze",,,"Porez na dohodak od kapitala s osnove opcijskih dionica (25% + prirez)","Porez na dohodak od kapitala s osnove opcijskih dionica (25% + prirez)" +"2432","kp_rrif2432","kp_rrif243","other","account_type_kratk_obveze",,,"Obveze za porez po odbitku (-15% -čl.31.Zakona o porezu na dobit -na ino usluge intelek. vlas. i dr.)","Obveze za porez po odbitku (na inozemne usluge intelektualnog vlasništva, za istraživ. tržišta, poslovno i porezno savjetovanje, revizorske usluge i na kamate inozemnim nebankarskim pravnim osobama - 15% - čl. 31. Zakona o porezu na dobit)" +"2436","kp_rrif2436","kp_rrif243","other","account_type_kratk_obveze",,,"Obveza za PD po rješenju poreznog nadzora","Obveza za PD po rješenju poreznog nadzora" +"244","kp_rrif244","kp_rrif24","view","account_type_view",,,"Obveze za posebne poreze (trošarine - akcize) i dr. poreze državi","Obveze za posebne poreze (trošarine - akcize) i dr. poreze državi" +"2440","kp_rrif2440","kp_rrif244","other","account_type_kratk_obveze",,,"Obveza za posebni porez pri uvozu automobila, plovila i zrakoplova","Obveza za posebni porez pri uvozu automobila, plovila i zrakoplova" +"2441","kp_rrif2441","kp_rrif244","other","account_type_kratk_obveze",,,"Obveza za posebni porez na bezalkoholna pića","Obveza za posebni porez na bezalkoholna pića" +"2442","kp_rrif2442","kp_rrif244","other","account_type_kratk_obveze",,,"Obveza za posebni porez na pivo","Obveza za posebni porez na pivo" +"2443","kp_rrif2443","kp_rrif244","other","account_type_kratk_obveze",,,"Obveza za posebni porez na alkohol","Obveza za posebni porez na alkohol" +"2444","kp_rrif2444","kp_rrif244","view","account_type_view",,,"Obveza za posebni porez na naftne derivate","Obveza za posebni porez na naftne derivate" +"24440","kp_rrif24440","kp_rrif2444","other","account_type_kratk_obveze",,,"Obveze za naknade za Hrvatske autoceste","Obveze za naknade za Hrvatske autoceste" +"24441","kp_rrif24441","kp_rrif2444","other","account_type_kratk_obveze",,,"Obveze za naknade za Hrvatske ceste","Obveze za naknade za Hrvatske ceste" +"2445","kp_rrif2445","kp_rrif244","other","account_type_kratk_obveze",,,"Obveze za posebni porez na duhanske proizvode","Obveze za posebni porez na duhanske proizvode" +"2446","kp_rrif2446","kp_rrif244","other","account_type_kratk_obveze",,,"Obveza za posebni porez na kavu","Obveza za posebni porez na kavu" +"2447","kp_rrif2447","kp_rrif244","other","account_type_kratk_obveze",,,"Obveze za posebni porez na luksuzne proizvode","Obveze za posebni porez na luksuzne proizvode" +"2448","kp_rrif2448","kp_rrif244","other","account_type_kratk_obveze",,,"Obveza za 5% poreza na promet nekretnina","Obveza za 5% poreza na promet nekretnina" +"2449","kp_rrif2449","kp_rrif244","other","account_type_kratk_obveze",,,"Obveze za 5% poreza na promet mot. vozila i plovila","Obveze za 5% poreza na promet mot. vozila i plovila" +"245","kp_rrif245","kp_rrif24","view","account_type_view",,,"Obveze za članarinu turist. zajednicama","Obveze za članarinu turist. zajednicama" +"2450","kp_rrif2450","kp_rrif245","other","account_type_kratk_obveze",,,"Obveze za članarinu turist. zajednicama-a1","Obveze za članarinu turist. zajednicama-Analitika 1" +"246","kp_rrif246","kp_rrif24","view","account_type_view",,,"Obveze za članarinu komori","Obveze za članarinu komori" +"2460","kp_rrif2460","kp_rrif246","other","account_type_kratk_obveze",,,"Obveza za HGK za paušalnu naknadu","Obveza za HGK za paušalnu naknadu" +"2461","kp_rrif2461","kp_rrif246","other","account_type_kratk_obveze",,,"Obveza za HGK za javnu funkciju","Obveza za HGK za javnu funkciju" +"2462","kp_rrif2462","kp_rrif246","other","account_type_kratk_obveze",,,"Obveza za članarinu Obrtničkoj komori","Obveza za članarinu Obrtničkoj komori" +"2463","kp_rrif2463","kp_rrif246","other","account_type_kratk_obveze",,,"Obveze za paušal HOK-u","Obveze za paušal HOK-u" +"2464","kp_rrif2464","kp_rrif246","other","account_type_kratk_obveze",,,"Obveze za članarinu granskoj ili strukovnoj komori","Obveze za članarinu granskoj ili strukovnoj komori" +"247","kp_rrif247","kp_rrif24","view","account_type_view",,,"Obveze za carinu i carinske pristojbe","Obveze za carinu i carinske pristojbe" +"2470","kp_rrif2470","kp_rrif247","other","account_type_kratk_obveze",,,"Obveze za carinu","Obveze za carinu" +"2471","kp_rrif2471","kp_rrif247","other","account_type_kratk_obveze",,,"Obveze za carinu prema mjernoj jedinici (prelevmani)","Obveze za carinu prema mjernoj jedinici (prelevmani)" +"2472","kp_rrif2472","kp_rrif247","other","account_type_kratk_obveze",,,"Obveze za carinske pristojbe i takse","Obveze za carinske pristojbe i takse" +"2473","kp_rrif2473","kp_rrif247","other","account_type_kratk_obveze",,,"Ostale obveze prema carini (za PDV i dr.)","Ostale obveze prema carini (za PDV i dr.)" +"248","kp_rrif248","kp_rrif24","view","account_type_view",,,"Obveze za županijske (gradske) i općinske poreze","Obveze za županijske (gradske) i općinske poreze" +"2480","kp_rrif2480","kp_rrif248","other","account_type_kratk_obveze",,,"Obveze za imovinski porez na motorna vozila i plovne objekte","Obveze za imovinski porez na motorna vozila i plovne objekte" +"2481","kp_rrif2481","kp_rrif248","other","account_type_kratk_obveze",,,"Obveze za imovinski porez na kuće za odmor i porez na korištenje javnih površina","Obveze za imovinski porez na kuće za odmor i porez na korištenje javnih površina" +"2482","kp_rrif2482","kp_rrif248","other","account_type_kratk_obveze",,,"Obveze za porez na istaknutu reklamu","Obveze za porez na istaknutu reklamu" +"2483","kp_rrif2483","kp_rrif248","other","account_type_kratk_obveze",,,"Obveze za porez na tvrtku ili naziv","Obveze za porez na tvrtku ili naziv" +"2484","kp_rrif2484","kp_rrif248","other","account_type_kratk_obveze",,,"Obveza za porez na potrošnju alkoholnih i bezalkoholnih pića i piva u ugostiteljstvu","Obveza za porez na potrošnju alkoholnih i bezalkoholnih pića i piva u ugostiteljstvu" +"2485","kp_rrif2485","kp_rrif248","other","account_type_kratk_obveze",,,"Obveze za porez na zabavne i športske priredbe","Obveze za porez na zabavne i športske priredbe" +"2486","kp_rrif2486","kp_rrif248","other","account_type_kratk_obveze",,,"Obveze za porez na nasljedstva i darove","Obveze za porez na nasljedstva i darove" +"2489","kp_rrif2489","kp_rrif248","other","account_type_kratk_obveze",,,"Obveze za ostale poreze županiji, gradu ili općini","Obveze za ostale poreze županiji, gradu ili općini" +"249","kp_rrif249","kp_rrif24","view","account_type_view",,,"Ostale obveze javnih davanja","Ostale obveze javnih davanja" +"2490","kp_rrif2490","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze za nadoknadu za šume","Obveze za nadoknadu za šume" +"2491","kp_rrif2491","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze prema lokalnoj samoupravi za financiranje komunalne izgradnje (Zakon o komunalnom gospodarstvu)","Obveze prema lokalnoj samoupravi za financiranje komunalne izgradnje (prema Zakonu o komunalnom gospodarstvu)" +"2492","kp_rrif2492","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze za zakonske kazne","Obveze za zakonske kazne" +"2493","kp_rrif2493","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze za boravišnu pristojbu","Obveze za boravišnu pristojbu" +"2494","kp_rrif2494","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze za koncesije","Obveze za koncesije" +"2495","kp_rrif2495","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze za spomeničku rentu","Obveze za spomeničku rentu" +"2496","kp_rrif2496","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze za naknade za iskorištav. mineral. sirovina","Obveze za naknade za iskorištav. mineral. sirovina" +"2497","kp_rrif2497","kp_rrif249","other","account_type_kratk_obveze",,,"Obveze za naknade za ambalažu","Obveze za naknade za ambalažu" +"2499","kp_rrif2499","kp_rrif249","other","account_type_kratk_obveze",,,"Ostale obveze za ostala javna davanja","Ostale obveze za ostala javna davanja" +"25","kp_rrif25","kp_rrif2","view","account_type_view",,,"DUGOROČNE OBVEZE (za duže od jedne godine)","DUGOROČNE OBVEZE (za duže od jedne godine)" +"250","kp_rrif250","kp_rrif25","view","account_type_view",,,"Obveze prema povezanim poduzetnicima","Obveze prema povezanim poduzetnicima" +"2500","kp_rrif2500","kp_rrif250","other","account_type_dug_obv",,,"Obveze za primljena dobra i usluge","Obveze za primljena dobra i usluge" +"2501","kp_rrif2501","kp_rrif250","other","account_type_dug_obv",,,"Obveze za korištenje zajmova","Obveze za korištenje zajmova" +"251","kp_rrif251","kp_rrif25","view","account_type_view",,,"Obveze za zajmove, depozite i sl.","Obveze za zajmove, depozite i sl." +"2510","kp_rrif2510","kp_rrif251","other","account_type_dug_obv",,,"Obveze za dugoročne financijske zajmove","Obveze za dugoročne financijske zajmove" +"2511","kp_rrif2511","kp_rrif251","other","account_type_dug_obv",,,"Obveze za dugoročne hipotekarne zajmove","Obveze za dugoročne hipotekarne zajmove" +"2512","kp_rrif2512","kp_rrif251","other","account_type_dug_obv",,,"Obveze za dugoročne zajmove prema građanima","Obveze za dugoročne zajmove prema građanima" +"2513","kp_rrif2513","kp_rrif251","other","account_type_dug_obv",,,"Obveze za dugoročne zajmove članovima društva","Obveze za dugoročne zajmove članovima društva" +"2514","kp_rrif2514","kp_rrif251","other","account_type_dug_obv",,,"Obveze za dugoročne zajmove iz inozemstva","Obveze za dugoročne zajmove iz inozemstva" +"2515","kp_rrif2515","kp_rrif251","other","account_type_dug_obv",,,"Obveze za depozite","Obveze za depozite" +"2516","kp_rrif2516","kp_rrif251","other","account_type_dug_obv",,,"Obveze za kapare","Obveze za kapare" +"2517","kp_rrif2517","kp_rrif251","other","account_type_dug_obv",,,"Obveze s osnove jamstva (realiziranih)","Obveze s osnove jamstva (realiziranih)" +"2519","kp_rrif2519","kp_rrif251","other","account_type_dug_obv",,,"Ostale obveze za dugoročne zajmove","Ostale obveze za dugoročne zajmove" +"252","kp_rrif252","kp_rrif25","view","account_type_view",,,"Obveze prema bankama i dr. financijskim institucijama","Obveze prema bankama i dr. financijskim institucijama" +"2520","kp_rrif2520","kp_rrif252","other","account_type_dug_obv",,,"Dugoročni financijski krediti banaka (analitika po bankama, pa po sklopljenim ugovorima o kreditu)","Dugoročni financijski krediti banaka (analitika po bankama a unutar toga po sklopljenim ugovorima o kreditu)" +"2521","kp_rrif2521","kp_rrif252","other","account_type_dug_obv",,,"Dugoročni krediti od osiguravajućih društava (analitika po društvima, pa po sklopljenim ugovorima)","Dugoročni krediti od osiguravajućih društava (analitika po društvima a unutar toga po sklopljenim ugovorima)" +"2522","kp_rrif2522","kp_rrif252","other","account_type_dug_obv",,,"Dugoročni krediti od ostalih domaćih kreditnih institucija (fonda, i dr.)","Dugoročni krediti od ostalih domaćih kreditnih institucija (fonda, i dr.)" +"2523","kp_rrif2523","kp_rrif252","other","account_type_dug_obv",,,"Dugoročni krediti od inozemnih banaka i drugih inozemnih kreditnih institucija","Dugoročni krediti od inozemnih banaka i drugih inozemnih kreditnih institucija" +"2529","kp_rrif2529","kp_rrif252","other","account_type_dug_obv",,,"Dugoročne obveze za kamate","Dugoročne obveze za kamate" +"253","kp_rrif253","kp_rrif25","view","account_type_view",,,"Dugoročne obveze iz financijskog lizinga","Dugoročne obveze iz financijskog lizinga" +"2530","kp_rrif2530","kp_rrif253","other","account_type_dug_obv",,,"Financijski najam vozila, brodova i dr.","Financijski najam vozila, brodova i dr." +"2531","kp_rrif2531","kp_rrif253","other","account_type_dug_obv",,,"Povratni financijski najam (npr. nekretnina brodova, tramvaja, vlakova i dr.)","Povratni financijski najam (npr. nekretnina brodova, tramvaja, vlakova i dr.)" +"254","kp_rrif254","kp_rrif25","view","account_type_view",,,"Obveze za predujmove","Obveze za predujmove" +"2540","kp_rrif2540","kp_rrif254","other","account_type_dug_obv",,,"Obveze za dugoročne predujmove (avanse) za izgradnju objekata i postrojenja (bez PDV-a)","Obveze za dugoročne predujmove (avanse) za izgradnju objekata i postrojenja (bez PDV-a)" +"2541","kp_rrif2541","kp_rrif254","other","account_type_dug_obv",,,"Obveze za dugoročne predujmove za isporuke zaliha","Obveze za dugoročne predujmove za isporuke zaliha" +"2542","kp_rrif2542","kp_rrif254","other","account_type_dug_obv",,,"Ostale dugoročne obveze za predujmove","Ostale dugoročne obveze za predujmove" +"255","kp_rrif255","kp_rrif25","view","account_type_view",,,"Obveze prema dobavljačima (neisplaćene dugoročne obveze prema vjerovnicima s osnove poslovanja)","Obveze prema dobavljačima (neisplaćene dugoročne obveze prema vjerovnicima s osnove poslovanja)" +"2550","kp_rrif2550","kp_rrif255","other","account_type_dug_obv",,,"Obveze prema dobavljačima s rokom plaćanja duljim od godine dana (npr. kod izgradnje)","Obveze prema dobavljačima s rokom plaćanja duljim od godine dana (npr. kod izgradnje)" +"2551","kp_rrif2551","kp_rrif255","other","account_type_dug_obv",,,"Obveze prema dobavljačima iz inozemstva (dugoročne)","Obveze prema dobavljačima iz inozemstva (dugoročne)" +"2552","kp_rrif2552","kp_rrif255","other","account_type_dug_obv",,,"Obveze prema vjerovnicima iz ostalih poslovnih aktivnosti","Obveze prema vjerovnicima iz ostalih poslovnih aktivnosti" +"2553","kp_rrif2553","kp_rrif255","other","account_type_dug_obv",,,"Obveze prema dobavljačima za zadržani dio iz jamstva","Obveze prema dobavljačima za zadržani dio iz jamstva" +"256","kp_rrif256","kp_rrif25","view","account_type_view",,,"Obveze po vrijednosnim papirima (dugoročnim)","Obveze po vrijednosnim papirima (dugoročnim)" +"2560","kp_rrif2560","kp_rrif256","other","account_type_dug_obv",,,"Obveze za izdane dugoročne obveznice","Obveze za izdane dugoročne obveznice" +"2561","kp_rrif2561","kp_rrif256","other","account_type_dug_obv",,,"Obveze za dugoročne komercijalne vrijednosne papire","Obveze za dugoročne komercijalne vrijednosne papire" +"2562","kp_rrif2562","kp_rrif256","other","account_type_dug_obv",,,"Obveze za dugoročne mjenice","Obveze za dugoročne mjenice" +"2563","kp_rrif2563","kp_rrif256","other","account_type_dug_obv",,,"Obveze po ostalim dugoroč. vrijednos. papirima","Obveze po ostalim dugoroč. vrijednos. papirima" +"2568","kp_rrif2568","kp_rrif256","other","account_type_dug_obv",,,"Obveze za kamate iz obveznica","Obveze za kamate iz obveznica" +"2569","kp_rrif2569","kp_rrif256","other","account_type_dug_obv",,,"Diskont na vrijednosne papire (kao razlika do nominalne vrijednosti)","Diskont na vrijednosne papire (kao razlika do nominalne vrijednosti)" +"257","kp_rrif257","kp_rrif25","view","account_type_view",,,"Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)","Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)" +"2570","kp_rrif2570","kp_rrif257","other","account_type_dug_obv",,,"Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)-a1","Obveze prema poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)-Analitika 1" +"258","kp_rrif258","kp_rrif25","view","account_type_view",,,"Obveze prema Državi (realizirana jamstva, krediti)","Obveze prema Državi (realizirana jamstva, krediti)" +"2580","kp_rrif2580","kp_rrif258","other","account_type_dug_obv",,,"Obveze prema Državi (realizirana jamstva, krediti)-a1","Obveze prema Državi (realizirana jamstva, krediti)-Analitika 1" +"259","kp_rrif259","kp_rrif25","view","account_type_view",,,"Ostale dugoročne obveze","Ostale dugoročne obveze" +"2590","kp_rrif2590","kp_rrif259","other","account_type_dug_obv",,,"Obveze prema zakladama, komorama i sl.","Obveze prema zakladama, komorama i sl." +"2591","kp_rrif2591","kp_rrif259","other","account_type_dug_obv",,,"Dugoročne obveze za porez","Dugoročne obveze za porez" +"2592","kp_rrif2592","kp_rrif259","other","account_type_dug_obv",,,"Dugoročne obveze za socijalno osiguranje","Dugoročne obveze za socijalno osiguranje" +"2593","kp_rrif2593","kp_rrif259","other","account_type_dug_obv",,,"Obveze za dugoročne jamčevine","Obveze za dugoročne jamčevine" +"2599","kp_rrif2599","kp_rrif259","other","account_type_dug_obv",,,"Ostale dugoročne obveze","Ostale dugoročne obveze" +"26","kp_rrif26","kp_rrif2","view","account_type_view",,,"ODGOĐENI POREZI","ODGOĐENI POREZI" +"260","kp_rrif260","kp_rrif26","view","account_type_view",,,"Odgođena porezna obveza","Odgođena porezna obveza" +"2600","kp_rrif2600","kp_rrif260","other","account_type_dug_obv",,,"Odgođena privremena razlika porezne obveze (analitika po godinama - HSFI t. 12.22. i MRS 12 t. 5.)","Odgođena privremena razlika porezne obveze (analitika po godinama - HSFI t. 12.22. i MRS 12 t. 5.)" +"28","kp_rrif28","kp_rrif2","view","account_type_view",,,"DUGOROČNA REZERVIRANJA ZA RIZIKE I TROŠKOVE","DUGOROČNA REZERVIRANJA ZA RIZIKE I TROŠKOVE" +"280","kp_rrif280","kp_rrif28","view","account_type_view",,,"Rezerviranja za otpremnine i mirovine","Rezerviranja za otpremnine i mirovine" +"2800","kp_rrif2800","kp_rrif280","other","account_type_rezervacije",,,"Rezerviranja za otpremnine","Rezerviranja za otpremnine" +"2801","kp_rrif2801","kp_rrif280","other","account_type_rezervacije",,,"Rezerviranja za mirovine","Rezerviranja za mirovine" +"281","kp_rrif281","kp_rrif28","view","account_type_view",,,"Rezerviranja za porezne obveze","Rezerviranja za porezne obveze" +"2810","kp_rrif2810","kp_rrif281","other","account_type_rezervacije",,,"Dugor. rezerv. za odg. plać. poreza i dopr.","Dugor. rezerv. za odg. plać. poreza i dopr." +"282","kp_rrif282","kp_rrif28","view","account_type_view",,,"Druga rezerviranja","Druga rezerviranja" +"2820","kp_rrif2820","kp_rrif282","other","account_type_rezervacije",,,"Dugoročna rezerviranja za troškove izdanih jamstava za prodana dobra","Dugoročna rezerviranja za troškove izdanih jamstava za prodana dobra" +"2821","kp_rrif2821","kp_rrif282","other","account_type_rezervacije",,,"Dugoročna rezerviranja za gubitke po započetim sudskim sporovima","Dugoročna rezerviranja za gubitke po započetim sudskim sporovima" +"2822","kp_rrif2822","kp_rrif282","other","account_type_rezervacije",,,"Dugor. rezerv. za obnovu prirodnog bogatstva-dug. rezer. za neiskor. g.o.(MRS19.t14.,HSFI13) -vidi 298","Dugor. rezerv. za obnovu prirodnog bogatstva - Dug. rezer. za neiskorištene g. o. (MRS 19. t. 14. i HSFI 13) - vidi račun 298" +"2824","kp_rrif2824","kp_rrif282","other","account_type_rezervacije",,,"Dugoročno rezerviranje za restrukturiranje (MRS 37 i HSFI t. 16.22.)","Dugoročno rezerviranje za restrukturiranje (MRS 37 i HSFI t. 16.22.)" +"2825","kp_rrif2825","kp_rrif282","other","account_type_rezervacije",,,"Rezerviranje za ugovore s poteškoćama (MRS 37, t. 66. i HSFI t. 16.21.)","Rezerviranje za ugovore s poteškoćama (MRS 37, t. 66. i HSFI t. 16.21.)" +"2829","kp_rrif2829","kp_rrif282","other","account_type_rezervacije",,,"Ostala dugoročna rezerviranja za rizike i dr.","Ostala dugoročna rezerviranja za rizike i dr." +"29","kp_rrif29","kp_rrif2","view","account_type_view",,,"ODGOĐENO PLAĆANJE TROŠKOVA I PRIHOD BUDUĆEG RAZDOBLJA","ODGOĐENO PLAĆANJE TROŠKOVA I PRIHOD BUDUĆEG RAZDOBLJA" +"290","kp_rrif290","kp_rrif29","view","account_type_view",,,"Odgođeno plaćanje troškova","Odgođeno plaćanje troškova" +"2900","kp_rrif2900","kp_rrif290","other","account_type_pas_razgran",,,"Obračunani troškovi za koje nije primljena faktura (telefon, grijanje, el. energija, plin, voda i sl.)","Obračunani troškovi za koje nije primljena faktura (telefon, grijanje, el. energija, plin, voda i sl.)" +"2901","kp_rrif2901","kp_rrif290","other","account_type_pas_razgran",,,"Obračunana najamnina iz operativnog (poslovnog) najma","Obračunana najamnina iz operativnog (poslovnog) najma" +"2902","kp_rrif2902","kp_rrif290","other","account_type_pas_razgran",,,"Obračunani troškovi tekućeg održavanja","Obračunani troškovi tekućeg održavanja" +"2903","kp_rrif2903","kp_rrif290","other","account_type_pas_razgran",,,"Obračunani troškovi reklame, propagande i sajmova","Obračunani troškovi reklame, propagande i sajmova" +"2904","kp_rrif2904","kp_rrif290","other","account_type_pas_razgran",,,"Obračunane a neplaćene usluge korištene u obračunskom razdoblju","Obračunane a neplaćene usluge korištene u obračunskom razdoblju" +"2905","kp_rrif2905","kp_rrif290","other","account_type_pas_razgran",,,"Obračunani rad po ugovoru o djelu, autor. hon.","Obračunani rad po ugovoru o djelu, autor. hon." +"2906","kp_rrif2906","kp_rrif290","other","account_type_pas_razgran",,,"Obračunani kalo, rastep, kvar i lom","Obračunani kalo, rastep, kvar i lom" +"2907","kp_rrif2907","kp_rrif290","other","account_type_pas_razgran",,,"Obračunani troškovi premije osiguranja","Obračunani troškovi premije osiguranja" +"2908","kp_rrif2908","kp_rrif290","other","account_type_pas_razgran",,,"Uračunani troškovi službenih glasila i stručnih časopisa","Uračunani troškovi službenih glasila i stručnih časopisa" +"2909","kp_rrif2909","kp_rrif290","other","account_type_pas_razgran",,,"Obračunani ostali troškovi poslovanja (prijevoz, bankovne usluge i platni promet, reprez. i dr.)","Obračunani ostali troškovi poslovanja (troškovi prijevoza, bankovne usluge i platni promet, reprezentacija i dr.)" +"291","kp_rrif291","kp_rrif29","view","account_type_view",,,"Obračunani troškovi korištenih prava","Obračunani troškovi korištenih prava" +"2910","kp_rrif2910","kp_rrif291","other","account_type_pas_razgran",,,"Obračunani troškovi franšiza, korištenih trgovačkih znakova, prava i sl.","Obračunani troškovi franšiza, korištenih trgovačkih znakova, prava i sl." +"2911","kp_rrif2911","kp_rrif291","other","account_type_pas_razgran",,,"Obračunani troškovi licencija","Obračunani troškovi licencija" +"2912","kp_rrif2912","kp_rrif291","other","account_type_pas_razgran",,,"Obračunani troškovi autorskih prava","Obračunani troškovi autorskih prava" +"2913","kp_rrif2913","kp_rrif291","other","account_type_pas_razgran",,,"Odgođeno plaćanje troškova za ostala prava","Odgođeno plaćanje troškova za ostala prava" +"292","kp_rrif292","kp_rrif29","view","account_type_view",,,"Obračunani troškovi nabave dobara","Obračunani troškovi nabave dobara" +"2920","kp_rrif2920","kp_rrif292","other","account_type_pas_razgran",,,"Obračunani ovisni troškovi nabave (za koje nisu primljeni računi)-prijevoz, osiguranje, špedicija i dr.","Obračunani ovisni troškovi nabave (za koje nisu primljeni računi) - prijevoz, osiguranje, špedicija i dr. vanjski troškovi" +"293","kp_rrif293","kp_rrif29","view","account_type_view",,,"Obračunani prihodi budućeg razdoblja","Obračunani prihodi budućeg razdoblja" +"2930","kp_rrif2930","kp_rrif293","other","account_type_pas_razgran",,,"Odgođeni prihodi radi neizvjesnih troškova","Odgođeni prihodi radi neizvjesnih troškova" +"2931","kp_rrif2931","kp_rrif293","other","account_type_pas_razgran",,,"Obračunani prihodi budućeg razdoblja koji su rezultat primjene računovodstvene politike","Obračunani prihodi budućeg razdoblja koji su rezultat primjene računovodstvene politike" +"2932","kp_rrif2932","kp_rrif293","other","account_type_pas_razgran",,,"Odgođeno priznavanje prihoda kad se predviđa povrat robe","Odgođeno priznavanje prihoda kad se predviđa povrat robe" +"2933","kp_rrif2933","kp_rrif293","other","account_type_pas_razgran",,,"Odgođeni prihodi iz otkupa tražbine (faktoring koji nije zarađen)","Odgođeni prihodi iz otkupa tražbine (faktoring koji nije zarađen)" +"2934","kp_rrif2934","kp_rrif293","other","account_type_pas_razgran",,,"Odgođeni prihodi od kamata iz financijskog lizinga","Odgođeni prihodi od kamata iz financijskog lizinga" +"2935","kp_rrif2935","kp_rrif293","other","account_type_pas_razgran",,,"Odgođeni prihodi iz operativnog lizinga","Odgođeni prihodi iz operativnog lizinga" +"2936","kp_rrif2936","kp_rrif293","other","account_type_pas_razgran",,,"Obračunane (anticipativne) kamate na dane zajmove i zatezne kamate (za buduće razdoblje)","Obračunane (anticipativne) kamate na dane zajmove i zatezne kamate (za buduće razdoblje)" +"2937","kp_rrif2937","kp_rrif293","other","account_type_pas_razgran",,,"Unaprijed obračunane ili naplaćene školarine","Unaprijed obračunane ili naplaćene školarine" +"2938","kp_rrif2938","kp_rrif293","other","account_type_pas_razgran",,,"Odgođeni prihodi iz ortaštva","Odgođeni prihodi iz ortaštva" +"2939","kp_rrif2939","kp_rrif293","other","account_type_pas_razgran",,,"Ostali odgođeni prihodi budućeg razdoblja","Ostali odgođeni prihodi budućeg razdoblja" +"294","kp_rrif294","kp_rrif29","view","account_type_view",,,"Odgođeno priznavanje prihoda iz državnih potpora (HSFI t. 15.37 i MRS 20, t. 12. i 24.)","Odgođeno priznavanje prihoda iz državnih potpora (HSFI t. 15.37 i MRS 20, t. 12. i 24.)" +"2940","kp_rrif2940","kp_rrif294","other","account_type_pas_razgran",,,"Odgođeni prihodi iz potpora za dug. nemat. i mat. imovinu (analitike po primitcima, investicijama)","Odgođeni prihodi iz državnih i lokalnih potpora za dugotrajnu nematerijalnu i materijalnu imovinu (analitike po namjenskim primitcima iz proračuna - po investicijama)" +"2941","kp_rrif2941","kp_rrif294","other","account_type_pas_razgran",,,"Odgođeni prihodi iz potpora za zapošljavanje","Odgođeni prihodi iz potpora za zapošljavanje" +"2942","kp_rrif2942","kp_rrif294","other","account_type_pas_razgran",,,"Odgođeno priznavanje prihoda za unaprijed naplaćene subvencije i potpore","Odgođeno priznavanje prihoda za unaprijed naplaćene subvencije i potpore" +"2943","kp_rrif2943","kp_rrif294","other","account_type_pas_razgran",,,"Odgođeni prihodi ostalih potpora","Odgođeni prihodi ostalih potpora" +"295","kp_rrif295","kp_rrif29","view","account_type_view",,,"Odgođeno priznavanje prihoda","Odgođeno priznavanje prihoda" +"2950","kp_rrif2950","kp_rrif295","other","account_type_pas_razgran",,,"Odgođeni prihodi zbog rizika naplate (HSFI t. 15.71 u svezi s t. 15.24)","Odgođeni prihodi zbog rizika naplate (HSFI t. 15.71 u svezi s t. 15.24)" +"2951","kp_rrif2951","kp_rrif295","other","account_type_pas_razgran",,,"Razgraničeni višak prihoda od prodaje i povratnog financijskog najma (MRS 17, t. 59.)","Razgraničeni višak prihoda od prodaje i povratnog financijskog najma (MRS 17, t. 59.)" +"296","kp_rrif296","kp_rrif29","view","account_type_view",,,"Odgođeni prihod s osnove nefakturiranih isporuka dobara i usluga","Odgođeni prihod s osnove nefakturiranih isporuka dobara i usluga" +"2960","kp_rrif2960","kp_rrif296","other","account_type_pas_razgran",,,"Odgođeni prihod s osnove nefakturiranih isporuka dobara i usluga-a1","Odgođeni prihod s osnove nefakturiranih isporuka dobara i usluga-Analitika 1" +"297","kp_rrif297","kp_rrif29","view","account_type_view",,,"Nerealizirani dobitci iz financijske imovine (HSFI 9 i MRS 39)","Nerealizirani dobitci iz financijske imovine (HSFI 9 i MRS 39)" +"2970","kp_rrif2970","kp_rrif297","other","account_type_pas_razgran",,,"Nerealizirani dobitci iz financijske imovine (HSFI 9 i MRS 39)-a1","Nerealizirani dobitci iz financijske imovine (HSFI 9 i MRS 39)-Analitika 1" +"298","kp_rrif298","kp_rrif29","view","account_type_view",,,"Rezerviranje troška za neiskorištene godišnje odmore","Rezerviranje troška za neiskorištene godišnje odmore" +"2980","kp_rrif2980","kp_rrif298","other","account_type_pas_razgran",,,"Rezerviranje troška za neiskorištene godišnje odmore-a1","Rezerviranje troška za neiskorištene godišnje odmore-Analitika 1" +"299","kp_rrif299","kp_rrif29","view","account_type_view",,,"Ostala pasivna vremenska razgraničenja","Ostala pasivna vremenska razgraničenja" +"2999","kp_rrif2999","kp_rrif299","other","account_type_pas_razgran",,,"Ostala pasivna vremenska razgraničenja troškova","Ostala pasivna vremenska razgraničenja troškova" +"3","kp_rrif3","kp_rrif","view","account_type_view",,,"ZALIHE SIROVINA I MATERIJALA, REZERVNIH DIJELOVA I SITNOG INVENTARA","ZALIHE SIROVINA I MATERIJALA, REZERVNIH DIJELOVA I SITNOG INVENTARA" +"30","kp_rrif30","kp_rrif3","view","account_type_view",,,"OBRAČUN TROŠKOVA KUPNJE ZALIHA","OBRAČUN TROŠKOVA KUPNJE ZALIHA" +"300","kp_rrif300","kp_rrif30","view","account_type_view",,,"Kupovna cijena dobavljača","Kupovna cijena dobavljača" +"3000","kp_rrif3000","kp_rrif300","other","account_type_kratk_imovina",,,"Fakturna cijena sirovina i materijala na putu","Fakturna cijena sirovina i materijala na putu" +"3001","kp_rrif3001","kp_rrif300","other","account_type_kratk_imovina",,,"Fakturna cijena sirovina i materijala","Fakturna cijena sirovina i materijala" +"3002","kp_rrif3002","kp_rrif300","other","account_type_kratk_imovina",,,"Fakturna cijena rezervnih dijelova","Fakturna cijena rezervnih dijelova" +"3003","kp_rrif3003","kp_rrif300","other","account_type_kratk_imovina",,,"Fakturna cijena sitnog inventara, autoguma i ambalaže","Fakturna cijena sitnog inventara, autoguma i ambalaže" +"3005","kp_rrif3005","kp_rrif300","other","account_type_kratk_imovina",,,"Materijal i dijelovi u preuzimanju (nema dokumentacije)","Materijal i dijelovi u preuzimanju (nema dokumentacije)" +"301","kp_rrif301","kp_rrif30","view","account_type_view",,,"Ovisni troškovi nabave (u svezi s dovođenjem na zalihu)","Ovisni troškovi nabave (u svezi s dovođenjem na zalihu)" +"3010","kp_rrif3010","kp_rrif301","other","account_type_kratk_imovina",,,"Troškovi transporta","Troškovi transporta" +"3011","kp_rrif3011","kp_rrif301","other","account_type_kratk_imovina",,,"Troškovi ukrcaja i iskrcaja (fakturirani)","Troškovi ukrcaja i iskrcaja (fakturirani)" +"3012","kp_rrif3012","kp_rrif301","other","account_type_kratk_imovina",,,"Transportno osiguranje i čuvanje","Transportno osiguranje i čuvanje" +"3013","kp_rrif3013","kp_rrif301","other","account_type_kratk_imovina",,,"Posebni troškovi pakiranja - ambalaže","Posebni troškovi pakiranja - ambalaže" +"3014","kp_rrif3014","kp_rrif301","other","account_type_kratk_imovina",,,"Troškovi vlastitog transporta","Troškovi vlastitog transporta" +"3015","kp_rrif3015","kp_rrif301","other","account_type_kratk_imovina",,,"Troškovi vlastitog ukrcaja i iskrcaja","Troškovi vlastitog ukrcaja i iskrcaja" +"3016","kp_rrif3016","kp_rrif301","other","account_type_kratk_imovina",,,"Troškovi špeditera","Troškovi špeditera" +"3017","kp_rrif3017","kp_rrif301","other","account_type_kratk_imovina",,,"Troškovi atesta i kontrole","Troškovi atesta i kontrole" +"3018","kp_rrif3018","kp_rrif301","other","account_type_kratk_imovina",,,"Troškovi dorade i oplemenjivanja za vrijeme dovođenja na zalihu","Troškovi dorade i oplemenjivanja za vrijeme dovođenja na zalihu" +"3019","kp_rrif3019","kp_rrif301","other","account_type_kratk_imovina",,,"Ostali ovisni troškovi nabave","Ostali ovisni troškovi nabave" +"302","kp_rrif302","kp_rrif30","view","account_type_view",,,"Carina i druge uvozne pristojbe","Carina i druge uvozne pristojbe" +"3020","kp_rrif3020","kp_rrif302","other","account_type_kratk_imovina",,,"Carina i druge uvozne pristojbe-a1","Carina i druge uvozne pristojbe-Analitika 1" +"303","kp_rrif303","kp_rrif30","view","account_type_view",,,"Posebni porezi (trošarine) koji se ne mogu odbiti","Posebni porezi (trošarine) koji se ne mogu odbiti" +"3030","kp_rrif3030","kp_rrif303","other","account_type_kratk_imovina",,,"Posebni porezi (trošarine) koji se ne mogu odbiti-a1","Posebni porezi (trošarine) koji se ne mogu odbiti-Analitika 1" +"309","kp_rrif309","kp_rrif30","view","account_type_view",,,"Obračun troškova kupnje","Obračun troškova kupnje" +"3090","kp_rrif3090","kp_rrif309","other","account_type_kratk_imovina",,,"Obračun nabave sirovina i materijala, dijelova i sitnog inventara koji se skladišti","Obračun nabave sirovina i materijala, dijelova i sitnog inventara koji se skladišti" +"3091","kp_rrif3091","kp_rrif309","other","account_type_kratk_imovina",,,"Obračun nabave sirovina i materijala i dijelova koji izravno terete troškove","Obračun nabave sirovina i materijala i dijelova koji izravno terete troškove" +"31","kp_rrif31","kp_rrif3","view","account_type_view",,,"SIROVINE I MATERIJAL NA ZALIHI","SIROVINE I MATERIJAL NA ZALIHI" +"310","kp_rrif310","kp_rrif31","view","account_type_view",,,"Sirovine i materijal u skladištu","Sirovine i materijal u skladištu" +"3100","kp_rrif3100","kp_rrif310","other","account_type_kratk_imovina",,,"Zalihe sirovina i materijala","Zalihe sirovina i materijala" +"3101","kp_rrif3101","kp_rrif310","other","account_type_kratk_imovina",,,"Zalihe goriva i maziva","Zalihe goriva i maziva" +"3102","kp_rrif3102","kp_rrif310","other","account_type_kratk_imovina",,,"Poluproizvodi za ugradnju ili proizvodnju","Poluproizvodi za ugradnju ili proizvodnju" +"3103","kp_rrif3103","kp_rrif310","other","account_type_kratk_imovina",,,"Uredski materijal i pribor","Uredski materijal i pribor" +"3104","kp_rrif3104","kp_rrif310","other","account_type_kratk_imovina",,,"Zalihe materijala s temelja povezane proizvodnje","Zalihe materijala s temelja povezane proizvodnje" +"3105","kp_rrif3105","kp_rrif310","other","account_type_kratk_imovina",,,"Zalihe ambalažnog materijala","Zalihe ambalažnog materijala" +"3106","kp_rrif3106","kp_rrif310","other","account_type_kratk_imovina",,,"Zalihe materijala kod kooperanata","Zalihe materijala kod kooperanata" +"3107","kp_rrif3107","kp_rrif310","other","account_type_kratk_imovina",,,"Materijal na zalihi u javnom ili drugom skladištu","Materijal na zalihi u javnom ili drugom skladištu" +"3108","kp_rrif3108","kp_rrif310","other","account_type_kratk_imovina",,,"Zalihe pića, hrane i dr. u ugostiteljstvu i hotelijerstvu","Zalihe pića, hrane i dr. u ugostiteljstvu i hotelijerstvu" +"3109","kp_rrif3109","kp_rrif310","other","account_type_kratk_imovina",,,"Zalihe otpadnog i rashodovanog materijala","Zalihe otpadnog i rashodovanog materijala" +"311","kp_rrif311","kp_rrif31","view","account_type_view",,,"Materijal u doradi, obradi i manipulaciji","Materijal u doradi, obradi i manipulaciji" +"3110","kp_rrif3110","kp_rrif311","other","account_type_kratk_imovina",,,"Materijal u doradi, obradi i oplemenjivanju","Materijal u doradi, obradi i oplemenjivanju" +"3111","kp_rrif3111","kp_rrif311","other","account_type_kratk_imovina",,,"Materijal u manipulaciji i na putu","Materijal u manipulaciji i na putu" +"3112","kp_rrif3112","kp_rrif311","other","account_type_kratk_imovina",,,"Troškovi dorade, obrade i oplemenjivanja","Troškovi dorade, obrade i oplemenjivanja" +"312","kp_rrif312","kp_rrif31","view","account_type_view",,,"Materijal na doradi kod ortaka","Materijal na doradi kod ortaka" +"3120","kp_rrif3120","kp_rrif312","other","account_type_kratk_imovina",,,"Materijal na doradi kod ortaka-a1","Materijal na doradi kod ortaka-Analitika 1" +"313","kp_rrif313","kp_rrif31","view","account_type_view",,,"Zalihe materijala za poljoprivredu","Zalihe materijala za poljoprivredu" +"3130","kp_rrif3130","kp_rrif313","other","account_type_kratk_imovina",,,"Zalihe sjemena i sadnog materijala","Zalihe sjemena i sadnog materijala" +"3131","kp_rrif3131","kp_rrif313","other","account_type_kratk_imovina",,,"Zalihe komponenti za proizvodnju","Zalihe komponenti za proizvodnju" +"318","kp_rrif318","kp_rrif31","view","account_type_view",,,"Odstupanje od cijene zaliha","Odstupanje od cijene zaliha" +"3180","kp_rrif3180","kp_rrif318","other","account_type_kratk_imovina",,,"Odstupanje od cijene zaliha-a1","Odstupanje od cijene zaliha-Analitika 1" +"319","kp_rrif319","kp_rrif31","view","account_type_view",,,"Vrijednosno usklađenje zaliha sirovina i materijala","Vrijednosno usklađenje zaliha sirovina i materijala" +"3190","kp_rrif3190","kp_rrif319","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje zaliha sirovina i materijala-a1","Vrijednosno usklađenje zaliha sirovina i materijala-Analitika 1" +"32","kp_rrif32","kp_rrif3","view","account_type_view",,,"ZALIHE REZERVNIH DIJELOVA","ZALIHE REZERVNIH DIJELOVA" +"320","kp_rrif320","kp_rrif32","view","account_type_view",,,"Rezervni dijelovi na zalihi","Rezervni dijelovi na zalihi" +"3200","kp_rrif3200","kp_rrif320","other","account_type_kratk_imovina",,,"Rezervni dijelovi za servisne usluge","Rezervni dijelovi za servisne usluge" +"3201","kp_rrif3201","kp_rrif320","other","account_type_kratk_imovina",,,"Dijelovi i sklopovi za ugradnju (u proizvode)","Dijelovi i sklopovi za ugradnju (u proizvode)" +"3202","kp_rrif3202","kp_rrif320","other","account_type_kratk_imovina",,,"Rezervni dijelovi za tekuće i investicijsko održavanje","Rezervni dijelovi za tekuće i investicijsko održavanje" +"3203","kp_rrif3203","kp_rrif320","other","account_type_kratk_imovina",,,"Zalihe polovnih rezervnih dijelova","Zalihe polovnih rezervnih dijelova" +"3204","kp_rrif3204","kp_rrif320","other","account_type_kratk_imovina",,,"Zalihe otpadaka rezervnih dijelova","Zalihe otpadaka rezervnih dijelova" +"328","kp_rrif328","kp_rrif32","view","account_type_view",,,"Odstupanje od cijene dijelova na zalihi","Odstupanje od cijene dijelova na zalihi" +"3280","kp_rrif3280","kp_rrif328","other","account_type_kratk_imovina",,,"Odstupanje od cijene dijelova na zalihi-a1","Odstupanje od cijene dijelova na zalihi-Analitika 1" +"329","kp_rrif329","kp_rrif32","view","account_type_view",,,"Vrijednosno usklađenje zaliha rezervnih dijelova","Vrijednosno usklađenje zaliha rezervnih dijelova" +"3290","kp_rrif3290","kp_rrif329","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje zaliha rezervnih dijelova-a1","Vrijednosno usklađenje zaliha rezervnih dijelova-Analitika 1" +"35","kp_rrif35","kp_rrif3","view","account_type_view",,,"ZALIHE SITNOG INVENTARA","ZALIHE SITNOG INVENTARA" +"350","kp_rrif350","kp_rrif35","view","account_type_view",,,"Sitan inventar na zalihi","Sitan inventar na zalihi" +"3500","kp_rrif3500","kp_rrif350","other","account_type_kratk_imovina",,,"Sitan inventar na zalihi (analitika prema vrstama: alati, mjerni instrumenti, pribori,odjeća, i dr.)","Sitan inventar na zalihi (analitika prema vrstama: alati, mjerni instrumenti, pribori, ostala sredstva rada male vrijednosti, radna i zaštitna odjeća, protupožarna i sanitetska sredstva, i dr.)" +"351","kp_rrif351","kp_rrif35","view","account_type_view",,,"Ambalaža na zalihi (samo vlastita i višekratna, analitika prema vrstama)","Ambalaža na zalihi (samo vlastita i višekratna, analitika prema vrstama)" +"3510","kp_rrif3510","kp_rrif351","other","account_type_kratk_imovina",,,"Ambalaža na zalihi (samo vlastita i višekratna, analitika prema vrstama)-a1","Ambalaža na zalihi (samo vlastita i višekratna, analitika prema vrstama)-Analitika 1" +"352","kp_rrif352","kp_rrif35","view","account_type_view",,,"Autogume na zalihi","Autogume na zalihi" +"3520","kp_rrif3520","kp_rrif352","other","account_type_kratk_imovina",,,"Autogume na zalihi-a1","Autogume na zalihi-Analitika 1" +"358","kp_rrif358","kp_rrif35","view","account_type_view",,,"Odstupanje od cijene","Odstupanje od cijene" +"3580","kp_rrif3580","kp_rrif358","other","account_type_kratk_imovina",,,"Odstupanje od cijene-a1","Odstupanje od cijene-Analitika 1" +"359","kp_rrif359","kp_rrif35","view","account_type_view",,,"Vrijednosno usklađenje zaliha","Vrijednosno usklađenje zaliha" +"3590","kp_rrif3590","kp_rrif359","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje zaliha-a1","Vrijednosno usklađenje zaliha-Analitika 1" +"36","kp_rrif36","kp_rrif3","view","account_type_view",,,"ZALIHE SITNOG INVENTARA U UPORABI","ZALIHE SITNOG INVENTARA U UPORABI" +"360","kp_rrif360","kp_rrif36","view","account_type_view",,,"Sitan inventar u uporabi","Sitan inventar u uporabi" +"3600","kp_rrif3600","kp_rrif360","other","account_type_kratk_imovina",,,"Sitan inventar u uporabi-a1","Sitan inventar u uporabi-Analitika 1" +"361","kp_rrif361","kp_rrif36","view","account_type_view",,,"Ambalaža u uporabi","Ambalaža u uporabi" +"3610","kp_rrif3610","kp_rrif361","other","account_type_kratk_imovina",,,"Ambalaža u uporabi-a1","Ambalaža u uporabi-Analitika 1" +"362","kp_rrif362","kp_rrif36","view","account_type_view",,,"Autogume u uporabi","Autogume u uporabi" +"3620","kp_rrif3620","kp_rrif362","other","account_type_kratk_imovina",,,"Autogume u uporabi-a1","Autogume u uporabi-Analitika 1" +"363","kp_rrif363","kp_rrif36","view","account_type_view",,,"Otpis sitnog inventara","Otpis sitnog inventara" +"3630","kp_rrif3630","kp_rrif363","other","account_type_kratk_imovina",,,"Otpis sitnog inventara-a1","Otpis sitnog inventara-Analitika 1" +"364","kp_rrif364","kp_rrif36","view","account_type_view",,,"Otpis ambalaže","Otpis ambalaže" +"3640","kp_rrif3640","kp_rrif364","other","account_type_kratk_imovina",,,"Otpis ambalaže-a1","Otpis ambalaže-Analitika 1" +"365","kp_rrif365","kp_rrif36","view","account_type_view",,,"Otpis autoguma","Otpis autoguma" +"3650","kp_rrif3650","kp_rrif365","other","account_type_kratk_imovina",,,"Otpis autoguma-a1","Otpis autoguma-Analitika 1" +"369","kp_rrif369","kp_rrif36","view","account_type_view",,,"Vrijednosno usklađenje sitnog inventara, ambalaže i autoguma","Vrijednosno usklađenje sitnog inventara, ambalaže i autoguma" +"3690","kp_rrif3690","kp_rrif369","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje sitnog inventara, ambalaže i autoguma-a1","Vrijednosno usklađenje sitnog inventara, ambalaže i autoguma-Analitika 1" +"37","kp_rrif37","kp_rrif3","view","account_type_view",,,"PREDUJMOVI DOBAVLJAČIMA SIROVINA I MATERIJALA, REZERVNIH DIJELOVA, SITNOG INVENTARA I AUTOGUMA","PREDUJMOVI DOBAVLJAČIMA SIROVINA I MATERIJALA, REZERVNIH DIJELOVA, SITNOG INVENTARA I AUTOGUMA" +"370","kp_rrif370","kp_rrif37","view","account_type_view",,,"Predujmovi dobavljačima materijala","Predujmovi dobavljačima materijala" +"3700","kp_rrif3700","kp_rrif370","other","account_type_kratk_imovina",,,"Predujmovi dobavljačima materijala-a1","Predujmovi dobavljačima materijala-Analitika 1" +"371","kp_rrif371","kp_rrif37","view","account_type_view",,,"Predujmovi dobavljačima rezervnih dijelova","Predujmovi dobavljačima rezervnih dijelova" +"3710","kp_rrif3710","kp_rrif371","other","account_type_kratk_imovina",,,"Predujmovi dobavljačima rezervnih dijelova-a1","Predujmovi dobavljačima rezervnih dijelova-Analitika 1" +"372","kp_rrif372","kp_rrif37","view","account_type_view",,,"Predujmovi dobavljačima sitnog inventara","Predujmovi dobavljačima sitnog inventara" +"3720","kp_rrif3720","kp_rrif372","other","account_type_kratk_imovina",,,"Predujmovi dobavljačima sitnog inventara-a1","Predujmovi dobavljačima sitnog inventara-Analitika 1" +"373","kp_rrif373","kp_rrif37","view","account_type_view",,,"Predujmovi dani uvozniku za nabavu sirovina i materijala, dijelova i inventara","Predujmovi dani uvozniku za nabavu sirovina i materijala, dijelova i inventara" +"3730","kp_rrif3730","kp_rrif373","other","account_type_kratk_imovina",,,"Predujmovi dani uvozniku za nabavu sirovina i materijala, dijelova i inventara-a1","Predujmovi dani uvozniku za nabavu sirovina i materijala, dijelova i inventara-Analitika 1" +"374","kp_rrif374","kp_rrif37","view","account_type_view",,,"Predujmovi inozemnim dobavljačima","Predujmovi inozemnim dobavljačima" +"3740","kp_rrif3740","kp_rrif374","other","account_type_kratk_imovina",,,"Predujmovi inozemnim dobavljačima-a1","Predujmovi inozemnim dobavljačima-Analitika 1" +"379","kp_rrif379","kp_rrif37","view","account_type_view",,,"Vrijednosno usklađenje danih predujmova","Vrijednosno usklađenje danih predujmova" +"3790","kp_rrif3790","kp_rrif379","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje danih predujmova-a1","Vrijednosno usklađenje danih predujmova-Analitika 1" +"4","kp_rrif4","kp_rrif","view","account_type_view",,,"TROŠKOVI PREMA VRSTAMA, FINANCIJSKI I OSTALI RASHODI","TROŠKOVI PREMA VRSTAMA, FINANCIJSKI I OSTALI RASHODI" +"40","kp_rrif40","kp_rrif4","view","account_type_view",,,"MATERIJALNI TROŠKOVI","MATERIJALNI TROŠKOVI" +"400","kp_rrif400","kp_rrif40","view","account_type_view",,,"Troškovi sirovina i materijala (za proizvodnju dobara i usluga)","Troškovi sirovina i materijala (za proizvodnju dobara i usluga)" +"4000","kp_rrif4000","kp_rrif400","other","account_type_posl_rashod",,,"Osnovni materijali i sirovine","Osnovni materijali i sirovine" +"4001","kp_rrif4001","kp_rrif400","other","account_type_posl_rashod",,,"Dijelovi i sklopovi","Dijelovi i sklopovi" +"4002","kp_rrif4002","kp_rrif400","other","account_type_posl_rashod",,,"Poluproizvodi za ugradnju","Poluproizvodi za ugradnju" +"4003","kp_rrif4003","kp_rrif400","other","account_type_posl_rashod",,,"Pomoćni materijali (mazivo, ljepila, svrdla, pile, noževi, brusne ploče i dr.)","Pomoćni materijali (mazivo, ljepila, svrdla, pile, noževi, brusne ploče i dr.)" +"4004","kp_rrif4004","kp_rrif400","other","account_type_posl_rashod",,,"Potrošni materijal za čišćenje i održavanje","Potrošni materijal za čišćenje i održavanje" +"4005","kp_rrif4005","kp_rrif400","other","account_type_posl_rashod",,,"Materijal za HTZ zaštitu, radna i zaštitna odjeća i obuća","Materijal za HTZ zaštitu, radna i zaštitna odjeća i obuća" +"4006","kp_rrif4006","kp_rrif400","other","account_type_posl_rashod",,,"Materijal pogonske administracije i menadžmenta (uredski potrošni i sl.)","Materijal pogonske administracije i menadžmenta (uredski potrošni i sl.)" +"4007","kp_rrif4007","kp_rrif400","other","account_type_posl_rashod",,,"Troškovi oblikovanja proizvoda za posebne kupce","Troškovi oblikovanja proizvoda za posebne kupce" +"4008","kp_rrif4008","kp_rrif400","other","account_type_posl_rashod",,,"Materijali u pomoćnoj djelatnosti (za restoran i dr.)","Materijali u pomoćnoj djelatnosti (za restoran i dr.)" +"4009","kp_rrif4009","kp_rrif400","other","account_type_posl_rashod",,,"Ostali izravni i opći troškovi pogona - uslužne jedinice (HSFI t. 10.17 i MRS 2, t. 10. do 19.)","Ostali izravni i opći troškovi pogona - uslužne jedinice (HSFI t. 10.17 i MRS 2, t. 10. do 19.)" +"401","kp_rrif401","kp_rrif40","view","account_type_view",,,"Materijalni troškovi administracije, uprave i prodaje","Materijalni troškovi administracije, uprave i prodaje" +"4010","kp_rrif4010","kp_rrif401","other","account_type_posl_rashod",,,"Uredski materijal (papir, registratori, olovke, tiskanice, toneri, ulošci, kalendari, rokovnici i sl.)","Uredski materijal (papir, registratori, olovke, tiskanice, toneri, ulošci, kalendari, rokovnici i sl.)" +"4011","kp_rrif4011","kp_rrif401","other","account_type_posl_rashod",,,"Materijal i sredstva za čišćenje i održavanje","Materijal i sredstva za čišćenje i održavanje" +"4012","kp_rrif4012","kp_rrif401","other","account_type_posl_rashod",,,"Troškovi otpisa sitnog inventara","Troškovi otpisa sitnog inventara" +"4013","kp_rrif4013","kp_rrif401","other","account_type_posl_rashod",,,"Ambalažni materijal, vrpce za blagajne, blokovi papira, pisači, naljepnice, etikete i dr.","Ambalažni materijal, vrpce za blagajne, blokovi papira, pisači, naljepnice, etikete i dr." +"4014","kp_rrif4014","kp_rrif401","other","account_type_posl_rashod",,,"Voda (izvorska) za piće","Voda (izvorska) za piće" +"4015","kp_rrif4015","kp_rrif401","other","account_type_posl_rashod",,,"Uniformirana radna odjeća i obuća","Uniformirana radna odjeća i obuća" +"4016","kp_rrif4016","kp_rrif401","other","account_type_posl_rashod",,,"Troškovi opomena","Troškovi opomena" +"4017","kp_rrif4017","kp_rrif401","other","account_type_posl_rashod",,,"Troškovi ukrasnog bilja","Troškovi ukrasnog bilja" +"4019","kp_rrif4019","kp_rrif401","other","account_type_posl_rashod",,,"Ostali materijalni troškovi trgovine","Ostali materijalni troškovi trgovine" +"402","kp_rrif402","kp_rrif40","view","account_type_view",,,"Troškovi istraživanja i razvoja (Zak. o znan - Nn. br. 46/07.)","Troškovi istraživanja i razvoja (Zak. o znan - Nn. br. 46/07.)" +"4020","kp_rrif4020","kp_rrif402","other","account_type_posl_rashod",,,"Troškovi projekta za temeljna istraživanja proizvoda","Troškovi projekta za temeljna istraživanja proizvoda" +"403","kp_rrif403","kp_rrif40","view","account_type_view",,,"Troškovi ambalaže","Troškovi ambalaže" +"4030","kp_rrif4030","kp_rrif403","other","account_type_posl_rashod",,,"Troškovi neodvojive ambalaže u proizvodnji (boce, limenke, kutije i dr.)","Troškovi neodvojive ambalaže u proizvodnji (boce, limenke, kutije i dr.)" +"4031","kp_rrif4031","kp_rrif403","other","account_type_posl_rashod",,,"Troškovi paleta, gajbi i sl.","Troškovi paleta, gajbi i sl." +"404","kp_rrif404","kp_rrif40","view","account_type_view",,,"Trošak sitnog inventara, ambalaže i autoguma","Trošak sitnog inventara, ambalaže i autoguma" +"4040","kp_rrif4040","kp_rrif404","other","account_type_posl_rashod",,,"Troškovi sitnog inventara,","Troškovi sitnog inventara," +"4041","kp_rrif4041","kp_rrif404","other","account_type_posl_rashod",,,"Troškovi ambalaže (povratne, posebne) - otpis","Troškovi ambalaže (povratne, posebne) - otpis" +"4042","kp_rrif4042","kp_rrif404","other","account_type_posl_rashod",,,"Troškovi autoguma (za kamione, autobuse, teretna vozila i strojeve)","Troškovi autoguma (za kamione, autobuse, teretna vozila i strojeve)" +"4044","kp_rrif4044","kp_rrif404","other","account_type_posl_rashod",,,"Trokš. auto guma (neto + 30% PDV) za slučaj plaće","Trokš. auto guma (neto + 30% PDV) za slučaj plaće" +"4045","kp_rrif4045","kp_rrif404","other","account_type_posl_rashod",,,"70% troška autoguma za os. automobile i dr. sredstva prijevoza za potrebe administr., uprave i prodaje","70% troška autoguma za osobne automobile i dr. sredstva prijevoza za potrebe administr., uprave i prodaje" +"4046","kp_rrif4046","kp_rrif404","other","account_type_posl_rashod",,,"30% troška inventara i autoguma za osobne automobile +30% PDV-a","30% troška inventara i autoguma za osobne automobile +30% PDV-a" +"405","kp_rrif405","kp_rrif40","view","account_type_view",,,"Potrošeni rezervni dijelovi i materijal za održavanje","Potrošeni rezervni dijelovi i materijal za održavanje" +"4050","kp_rrif4050","kp_rrif405","other","account_type_posl_rashod",,,"Potrošeni rezervni dijelovi za popravak vlastite opreme","Potrošeni rezervni dijelovi za popravak vlastite opreme" +"4051","kp_rrif4051","kp_rrif405","other","account_type_posl_rashod",,,"Materijal za održavanje opreme i objekata","Materijal za održavanje opreme i objekata" +"4054","kp_rrif4054","kp_rrif405","other","account_type_posl_rashod",,,"Trošak rez. dijelova (neto + 30% PDV) za slučaj plaće","Trošak rez. dijelova (neto + 30% PDV) za slučaj plaće" +"4055","kp_rrif4055","kp_rrif405","other","account_type_posl_rashod",,,"70% troškova rez. dijelova i mat. za automob., plovila i zrakopl.za prijevoz(čl.7.,st.1.,t.4.ZoPD)","70% troškova rezervnih dijelova i materijala za popravak automob., plovila i zrakopl. koji služe za osobni prijevoz poduzet. i zaposlenih (čl. 7., st. 1., t. 4. ZoPD)" +"4056","kp_rrif4056","kp_rrif405","other","account_type_posl_rashod",,,"30% troška rezervnih dijelova i materijala za održavanje automobila i dr. za osobni prijevoz +30% PDV-a","30% troška rezervnih dijelova i materijala za održavanje automobila i dr. za osobni prijevoz +30% PDV-a" +"4057","kp_rrif4057","kp_rrif405","other","account_type_posl_rashod",,,"Troškovi zamjene u jamstvenom roku","Troškovi zamjene u jamstvenom roku" +"4058","kp_rrif4058","kp_rrif405","other","account_type_posl_rashod",,,"Potrošeni vlastiti proizvodi i roba za održavanje","Potrošeni vlastiti proizvodi i roba za održavanje" +"4059","kp_rrif4059","kp_rrif405","other","account_type_posl_rashod",,,"Ostali troškovi rezervnih dijelova","Ostali troškovi rezervnih dijelova" +"406","kp_rrif406","kp_rrif40","view","account_type_view",,,"Potrošena energija u proizvodnji dobara i usluga","Potrošena energija u proizvodnji dobara i usluga" +"4060","kp_rrif4060","kp_rrif406","other","account_type_posl_rashod",,,"Električna energija","Električna energija" +"4061","kp_rrif4061","kp_rrif406","other","account_type_posl_rashod",,,"Plin, para, briketi i drva","Plin, para, briketi i drva" +"4062","kp_rrif4062","kp_rrif406","other","account_type_posl_rashod",,,"Mazut i ulje za loženje","Mazut i ulje za loženje" +"4063","kp_rrif4063","kp_rrif406","other","account_type_posl_rashod",,,"Dizelsko gorivo, benzin i motorno ulje (za stroj. i sl.)","Dizelsko gorivo, benzin i motorno ulje (za stroj. i sl.)" +"4067","kp_rrif4067","kp_rrif406","other","account_type_posl_rashod",,,"Trošak goriva za teretna vozila (kamione, autobuse, strojeve, brodove i sl.)","Trošak goriva za teretna vozila (kamione, autobuse, strojeve, brodove i sl.)" +"4069","kp_rrif4069","kp_rrif406","other","account_type_posl_rashod",,,"Ostali troškovi energije u proizvodnji","Ostali troškovi energije u proizvodnji" +"407","kp_rrif407","kp_rrif40","view","account_type_view",,,"Potrošena energija u administraciji, upravi i prodaji","Potrošena energija u administraciji, upravi i prodaji" +"4070","kp_rrif4070","kp_rrif407","other","account_type_posl_rashod",,,"Trošak električne energije","Trošak električne energije" +"4071","kp_rrif4071","kp_rrif407","other","account_type_posl_rashod",,,"Plin, toplinska energija, briketi, drva","Plin, toplinska energija, briketi, drva" +"4074","kp_rrif4074","kp_rrif407","other","account_type_posl_rashod",,,"Gorivo za osob. aut. (neto + 30% PDV) za sluč. plaće","Gorivo za osob. aut. (neto + 30% PDV) za sluč. plaće" +"4075","kp_rrif4075","kp_rrif407","other","account_type_posl_rashod",,,"70% troškova goriva za pogon automobila za osobni prijevoz(i automobila u najmu)","70% troškova diesela i benzina za pogon automobila, plovila i zrakoplova za osobni prijevoz poduzetnika i zaposlenih te za istu namjenu automobila u najmu" +"4076","kp_rrif4076","kp_rrif407","other","account_type_posl_rashod",,,"30% goriva za osobni prijevoz +30% PDV-a","30% goriva za osobni prijevoz +30% PDV-a" +"4077","kp_rrif4077","kp_rrif407","other","account_type_posl_rashod",,,"Trošak goriva za teretna vozila, strojeve i brodove","Trošak goriva za teretna vozila, strojeve i brodove" +"4079","kp_rrif4079","kp_rrif407","other","account_type_posl_rashod",,,"Ostali troškovi energije","Ostali troškovi energije" +"408","kp_rrif408","kp_rrif40","view","account_type_view",,,"Troškovi energije na pomoćnim mjestima u proizvodnji","Troškovi energije na pomoćnim mjestima u proizvodnji" +"4080","kp_rrif4080","kp_rrif408","other","account_type_posl_rashod",,,"Troškovi energije na pomoćnim mjestima u proizvodnji-a1","Troškovi energije na pomoćnim mjestima u proizvodnji-Analitika 1" +"409","kp_rrif409","kp_rrif40","view","account_type_view",,,"Odstupanja od standardnog troška","Odstupanja od standardnog troška" +"4090","kp_rrif4090","kp_rrif409","other","account_type_posl_rashod",,,"Odstupanja od standardnog troška-a1","Odstupanja od standardnog troška-Analitika 1" +"41","kp_rrif41","kp_rrif4","view","account_type_view",,,"OSTALI VANJSKI TROŠKOVI (TROŠKOVI USLUGA)","OSTALI VANJSKI TROŠKOVI (TROŠKOVI USLUGA)" +"410","kp_rrif410","kp_rrif41","view","account_type_view",,,"Troškovi telefona, prijevoza i sl.","Troškovi telefona, prijevoza i sl." +"4100","kp_rrif4100","kp_rrif410","other","account_type_posl_rashod",,,"Troškovi telefona, interneta i sl.","Troškovi telefona, interneta i sl." +"4101","kp_rrif4101","kp_rrif410","other","account_type_posl_rashod",,,"Poštanski troškovi","Poštanski troškovi" +"4102","kp_rrif4102","kp_rrif410","other","account_type_posl_rashod",,,"Prijevozne usluge u cestovnom prometu","Prijevozne usluge u cestovnom prometu" +"4103","kp_rrif4103","kp_rrif410","other","account_type_posl_rashod",,,"Prijevozne usluge željeznicom","Prijevozne usluge željeznicom" +"4104","kp_rrif4104","kp_rrif410","other","account_type_posl_rashod",,,"Prijevozne usluge brodara","Prijevozne usluge brodara" +"4105","kp_rrif4105","kp_rrif410","other","account_type_posl_rashod",,,"Prijevozne usluge zrakoplova","Prijevozne usluge zrakoplova" +"4106","kp_rrif4106","kp_rrif410","other","account_type_posl_rashod",,,"Troškovi specijalnih prijevoza","Troškovi specijalnih prijevoza" +"4107","kp_rrif4107","kp_rrif410","other","account_type_posl_rashod",,,"Usluge taksi- prijevoza","Usluge taksi- prijevoza" +"4108","kp_rrif4108","kp_rrif410","other","account_type_posl_rashod",,,"Usluge dostave i logistike","Usluge dostave i logistike" +"4109","kp_rrif4109","kp_rrif410","other","account_type_posl_rashod",,,"Ostale usluge prijevoza","Ostale usluge prijevoza" +"411","kp_rrif411","kp_rrif41","view","account_type_view",,,"Troškovi vanjskih usluga pri izradi dobara i obavljanju usluga","Troškovi vanjskih usluga pri izradi dobara i obavljanju usluga" +"4110","kp_rrif4110","kp_rrif411","other","account_type_posl_rashod",,,"Usluge dorade (oplemenjivanja), izrade, prerade i sl. u proizvodnji i izgradnji","Usluge dorade (oplemenjivanja), izrade, prerade i sl. u proizvodnji i izgradnji" +"4111","kp_rrif4111","kp_rrif411","other","account_type_posl_rashod",,,"Usluge kooperanata na zajedničkim uslugama prema trećima","Usluge kooperanata na zajedničkim uslugama prema trećima" +"4112","kp_rrif4112","kp_rrif411","other","account_type_posl_rashod",,,"Usluge studentskog i omladinskog servisa i na izradi proizvoda","Usluge studentskog i omladinskog servisa i na izradi proizvoda" +"4113","kp_rrif4113","kp_rrif411","other","account_type_posl_rashod",,,"Usluge pripreme teksta za tisak, za web. i sl.","Usluge pripreme teksta za tisak, za web. i sl." +"4114","kp_rrif4114","kp_rrif411","other","account_type_posl_rashod",,,"Grafičke usluge tiska i uveza","Grafičke usluge tiska i uveza" +"4115","kp_rrif4115","kp_rrif411","other","account_type_posl_rashod",,,"Usluge hotela i smještaja radnika na terenu","Usluge hotela i smještaja radnika na terenu" +"4116","kp_rrif4116","kp_rrif411","other","account_type_posl_rashod",,,"Usluge za iznajmljeni kapacitet","Usluge za iznajmljeni kapacitet" +"4117","kp_rrif4117","kp_rrif411","other","account_type_posl_rashod",,,"Usluge rada vanjskog osoblja","Usluge rada vanjskog osoblja" +"4118","kp_rrif4118","kp_rrif411","other","account_type_posl_rashod",,,"Usluge izrade ili popravka po ugovoru o djelu","Usluge izrade ili popravka po ugovoru o djelu" +"4119","kp_rrif4119","kp_rrif411","other","account_type_posl_rashod",,,"Ostale vanjske usluge na izradi dobara i proizvodnih usluga","Ostale vanjske usluge na izradi dobara i proizvodnih usluga" +"412","kp_rrif412","kp_rrif41","view","account_type_view",,,"Usluge održavanja i zaštite (servisne usluge)","Usluge održavanja i zaštite (servisne usluge)" +"4120","kp_rrif4120","kp_rrif412","other","account_type_posl_rashod",,,"Nabavljene usluge tekućeg održavanja (bez vlastitog materijala i dijelova)","Nabavljene usluge tekućeg održavanja (bez vlastitog materijala i dijelova)" +"4121","kp_rrif4121","kp_rrif412","other","account_type_posl_rashod",,,"Nabavljene usluge za investicijsko održavanje i popravke (bez vlastitog materijala i dijelova)","Nabavljene usluge za investicijsko održavanje i popravke (bez vlastitog materijala i dijelova)" +"4122","kp_rrif4122","kp_rrif412","other","account_type_posl_rashod",,,"Usluge čišćenja i pranja","Usluge čišćenja i pranja" +"4123","kp_rrif4123","kp_rrif412","other","account_type_posl_rashod",,,"Usluge održavanja softvera i web stranica","Usluge održavanja softvera i web stranica" +"4124","kp_rrif4124","kp_rrif412","view","account_type_view",,,"Vanjske usluge popravka prodanih a neispravnih dobara u jamstvenom roku","Vanjske usluge popravka prodanih a neispravnih dobara u jamstvenom roku" +"41244","kp_rrif41244","kp_rrif4124","other","account_type_posl_rashod",,,"Servis osob. automob. (neto + 30% PDV) za slučaj plaće u naravi","Servis osob. automob. (neto + 30% PDV) za slučaj plaće u naravi" +"4125","kp_rrif4125","kp_rrif412","other","account_type_posl_rashod",,,"70% usluga servisa za održavanje automobila za osobni prijevoz poduzetnika i zaposlenih","70% usluga servisa za održavanje automobila, plovila i zrakoplova koji služe za osobni prijevoz poduzetnika i zaposlenih" +"4126","kp_rrif4126","kp_rrif412","other","account_type_posl_rashod",,,"30% usluga održavanja prijevoznih sredstava za osobni prijevoz + 30% PDV-a","30% usluga održavanja prijevoznih sredstava za osobni prijevoz + 30% PDV-a" +"4127","kp_rrif4127","kp_rrif412","other","account_type_posl_rashod",,,"Usluge zaštite na radu i održavanja okoliša","Usluge zaštite na radu i održavanja okoliša" +"4128","kp_rrif4128","kp_rrif412","other","account_type_posl_rashod",,,"Usluge zaštitara na čuvanju imovine i osoba","Usluge zaštitara na čuvanju imovine i osoba" +"4129","kp_rrif4129","kp_rrif412","other","account_type_posl_rashod",,,"Ostale servisne usluge i usluge osoba","Ostale servisne usluge i usluge osoba" +"413","kp_rrif413","kp_rrif41","view","account_type_view",,,"Usluge registracije prijevoznih sredstava i troškovi dozvola","Usluge registracije prijevoznih sredstava i troškovi dozvola" +"4130","kp_rrif4130","kp_rrif413","other","account_type_posl_rashod",,,"70% troška registracije automobila, plovila i zrakoplova za prijevoz osoba poduz. (osim osiguranja)","70% troška registracije osobnih automobila, plovila i zrakoplova za prijevoz osoba poduzetnika (osim osiguranja)" +"4131","kp_rrif4131","kp_rrif413","view","account_type_view",,,"30% troška registracije sred. za osobni prijevoz + 30% PDV-a (osim troškova osiguranja)","30% troška registracije sred. za osobni prijevoz + 30% PDV-a (osim troškova osiguranja)" +"41314","kp_rrif41314","kp_rrif4131","other","account_type_posl_rashod",,,"Troškovi registr. (neto + 30% PDV) - plaća","Troškovi registr. (neto + 30% PDV) - plaća" +"4132","kp_rrif4132","kp_rrif413","other","account_type_posl_rashod",,,"Trošak registracije dostavnih i teret. vozila i autobusa (sveuk.) i automob. bez poreznog ograničenja","Trošak registracije dostavnih i teret. vozila i autobusa (sveukupno) i automob. bez poreznog ograničenja" +"4133","kp_rrif4133","kp_rrif413","other","account_type_posl_rashod",,,"Troškovi registracije plovila","Troškovi registracije plovila" +"4134","kp_rrif4134","kp_rrif413","other","account_type_posl_rashod",,,"Troškovi registracije zrakoplova","Troškovi registracije zrakoplova" +"4135","kp_rrif4135","kp_rrif413","other","account_type_posl_rashod",,,"Troškovi dozvola za prometne smjerove","Troškovi dozvola za prometne smjerove" +"4136","kp_rrif4136","kp_rrif413","other","account_type_posl_rashod",,,"Troškovi koncesija, licencija i dr. prava na prijevoz","Troškovi koncesija, licencija i dr. prava na prijevoz" +"4137","kp_rrif4137","kp_rrif413","other","account_type_posl_rashod",,,"Troškovi nadoknada za ceste, takse i sl.","Troškovi nadoknada za ceste, takse i sl." +"4139","kp_rrif4139","kp_rrif413","other","account_type_posl_rashod",,,"Ostali troškovi registracije prometala","Ostali troškovi registracije prometala" +"414","kp_rrif414","kp_rrif41","view","account_type_view",,,"Usluge zakupa - lizinga","Usluge zakupa - lizinga" +"4140","kp_rrif4140","kp_rrif414","other","account_type_posl_rashod",,,"Zakupnine - najamnine nekretnina","Zakupnine - najamnine nekretnina" +"4141","kp_rrif4141","kp_rrif414","other","account_type_posl_rashod",,,"Zakupnine opreme","Zakupnine opreme" +"4142","kp_rrif4142","kp_rrif414","other","account_type_posl_rashod",,,"Usluge operativnog (poslovnog) lizinga opreme","Usluge operativnog (poslovnog) lizinga opreme" +"4143","kp_rrif4143","kp_rrif414","other","account_type_posl_rashod",,,"70% usluga operativnog lizinga automobila, brodova i zrakoplova za osobni prijevoz osoba poduzetnika","70% usluga operativnog lizinga automobila, brodova i zrakoplova za osobni prijevoz osoba poduzetnika" +"4144","kp_rrif4144","kp_rrif414","other","account_type_posl_rashod",,,"Usluge operat. najma osob. automob. (neto + 30% PDV) za slučaj plaće","Usluge operat. najma osob. automob. (neto + 30% PDV) za slučaj plaće" +"4145","kp_rrif4145","kp_rrif414","other","account_type_posl_rashod",,,"70% rent-á-car usluge prijevoza osoba","70% rent-á-car usluge prijevoza osoba" +"4146","kp_rrif4146","kp_rrif414","other","account_type_posl_rashod",,,"30% usluga operativnog lizinga sred. za osobni prijevoz + 30% PDV-a","30% usluga operativnog lizinga sred. za osobni prijevoz + 30% PDV-a" +"4147","kp_rrif4147","kp_rrif414","other","account_type_posl_rashod",,,"30% rent-á-car usluga prijevoza osoba + 30% PDV-a","30% rent-á-car usluga prijevoza osoba + 30% PDV-a" +"4148","kp_rrif4148","kp_rrif414","other","account_type_posl_rashod",,,"Rent-á-car za prijevoz tereta","Rent-á-car za prijevoz tereta" +"4149","kp_rrif4149","kp_rrif414","other","account_type_posl_rashod",,,"Usluge najma informatičke opreme","Usluge najma informatičke opreme" +"415","kp_rrif415","kp_rrif41","view","account_type_view",,,"Usluge promidžbe, sponzorstva i troškovi sajmova","Usluge promidžbe, sponzorstva i troškovi sajmova" +"4150","kp_rrif4150","kp_rrif415","other","account_type_posl_rashod",,,"Troškovi promidžbe putem tiskovina, TV, plakata i sl.","Troškovi promidžbe putem tiskovina, TV, plakata i sl." +"4151","kp_rrif4151","kp_rrif415","other","account_type_posl_rashod",,,"Usluge promidžbenih agencija","Usluge promidžbenih agencija" +"4152","kp_rrif4152","kp_rrif415","other","account_type_posl_rashod",,,"Troškovi promidžbe u inozemstvu","Troškovi promidžbe u inozemstvu" +"4153","kp_rrif4153","kp_rrif415","other","account_type_posl_rashod",,,"Trošak sponzoriranja športa i kulture u cilju promidžbe","Trošak sponzoriranja športa i kulture u cilju promidžbe" +"4154","kp_rrif4154","kp_rrif415","other","account_type_posl_rashod",,,"Usluge unapređenja prodaje","Usluge unapređenja prodaje" +"4155","kp_rrif4155","kp_rrif415","other","account_type_posl_rashod",,,"Usluge istraživanja tržišta","Usluge istraživanja tržišta" +"4156","kp_rrif4156","kp_rrif415","other","account_type_posl_rashod",,,"Usluge sajmova (nadoknada za prostor)","Usluge sajmova (nadoknada za prostor)" +"4157","kp_rrif4157","kp_rrif415","other","account_type_posl_rashod",,,"Usluge oblikovanja i uređenja izložbenog i prodajnog prostora","Usluge oblikovanja i uređenja izložbenog i prodajnog prostora" +"4158","kp_rrif4158","kp_rrif415","other","account_type_posl_rashod",,,"Troškovi promidžbe najmom medija (stranica portala i sl.)","Troškovi promidžbe najmom medija (stranica portala i sl.)" +"4159","kp_rrif4159","kp_rrif415","other","account_type_posl_rashod",,,"Ostali troškovi promidžbe (osim reprezentacije, dnevnica na službenom putu i sl.)","Ostali troškovi promidžbe (osim reprezentacije, dnevnica na službenom putu i sl.)" +"416","kp_rrif416","kp_rrif41","view","account_type_view",,,"Intelektualne i osobne usluge","Intelektualne i osobne usluge" +"4160","kp_rrif4160","kp_rrif416","other","account_type_posl_rashod",,,"Troškovi drugih dohodaka (ugovora o djelu, akvizitera, trgov. putnika, konzultanata)","Troškovi drugih dohodaka (ugovora o djelu, akvizitera, trgov. putnika, konzultanata)" +"4161","kp_rrif4161","kp_rrif416","other","account_type_posl_rashod",,,"Autorski honorari (pisana, govorna, prijevodi i dr.)","Autorski honorari (pisana, govorna, prijevodi i dr.)" +"4162","kp_rrif4162","kp_rrif416","other","account_type_posl_rashod",,,"Usluge specijalističkog obrazovanja, znanstvenoistraživačke usluge, usluge informacija i sl.","Usluge specijalističkog obrazovanja, znanstvenoistraživačke usluge, usluge informacija i sl." +"4163","kp_rrif4163","kp_rrif416","other","account_type_posl_rashod",,,"Konzultantske i savjetničke usluge","Konzultantske i savjetničke usluge" +"4164","kp_rrif4164","kp_rrif416","other","account_type_posl_rashod",,,"Knjigovodstvene usluge","Knjigovodstvene usluge" +"4165","kp_rrif4165","kp_rrif416","other","account_type_posl_rashod",,,"Usluge poreznih savjetnika","Usluge poreznih savjetnika" +"4166","kp_rrif4166","kp_rrif416","other","account_type_posl_rashod",,,"Usluge revizije i procjene vrijednosti poduzeća","Usluge revizije i procjene vrijednosti poduzeća" +"4167","kp_rrif4167","kp_rrif416","other","account_type_posl_rashod",,,"Odvjetničke, bilježničke i usluge izrade pravnih akata","Odvjetničke, bilježničke i usluge izrade pravnih akata" +"4168","kp_rrif4168","kp_rrif416","other","account_type_posl_rashod",,,"Naknade za korištenje prava intelektualnog vlasništva (licencije, ind. prava., robni znak i sl.)","Naknade za korištenje prava intelektualnog vlasništva (licencije, ind. prava., robni znak i sl.)" +"4169","kp_rrif4169","kp_rrif416","other","account_type_posl_rashod",,,"Usluge vještačenja, administracijske usluge, i dr. intelektualne usluge","Usluge vještačenja, administracijske usluge, i dr. intelektualne usluge" +"417","kp_rrif417","kp_rrif41","view","account_type_view",,,"Troškovi komunalnih i sličnih usluga","Troškovi komunalnih i sličnih usluga" +"4170","kp_rrif4170","kp_rrif417","other","account_type_posl_rashod",,,"Komunalna naknada (za financ. izgradnje)","Komunalna naknada (za financ. izgradnje)" +"4171","kp_rrif4171","kp_rrif417","other","account_type_posl_rashod",,,"Odvoz smeća i fekalija","Odvoz smeća i fekalija" +"4172","kp_rrif4172","kp_rrif417","other","account_type_posl_rashod",,,"Voda i odvodnja","Voda i odvodnja" +"4173","kp_rrif4173","kp_rrif417","other","account_type_posl_rashod",,,"Održavanje zelenila","Održavanje zelenila" +"4174","kp_rrif4174","kp_rrif417","other","account_type_posl_rashod",,,"Usluge tržnica","Usluge tržnica" +"4175","kp_rrif4175","kp_rrif417","other","account_type_posl_rashod",,,"Garažiranje i parkiranje vozila","Garažiranje i parkiranje vozila" +"4176","kp_rrif4176","kp_rrif417","other","account_type_posl_rashod",,,"Deratizacija i dezinfekcijske usluge","Deratizacija i dezinfekcijske usluge" +"4177","kp_rrif4177","kp_rrif417","other","account_type_posl_rashod",,,"Dimnjačarske i ekološke usluge","Dimnjačarske i ekološke usluge" +"4178","kp_rrif4178","kp_rrif417","other","account_type_posl_rashod",,,"Veterinarske, sanitarne i usluge zbrinjavanja otpada","Veterinarske, sanitarne i usluge zbrinjavanja otpada" +"4179","kp_rrif4179","kp_rrif417","other","account_type_posl_rashod",,,"Ostale komunalne i ekološke usluge","Ostale komunalne i ekološke usluge" +"418","kp_rrif418","kp_rrif41","view","account_type_view",,,"Usluge reprezentacije - ugošćivanja i posredovanja","Usluge reprezentacije - ugošćivanja i posredovanja" +"4180","kp_rrif4180","kp_rrif418","other","account_type_posl_rashod",,,"70% vanjskih usluga ugošćenja (reprezentacije) + 70% PDV-a","70% vanjskih usluga ugošćenja (reprezentacije) + 70% PDV-a" +"4181","kp_rrif4181","kp_rrif418","other","account_type_posl_rashod",,,"30% vanjskih usluga ugošćenja (reprezentacije)","30% vanjskih usluga ugošćenja (reprezentacije)" +"4184","kp_rrif4184","kp_rrif418","other","account_type_posl_rashod",,,"Usluge posredovanja pri nabavi dobara i usluga","Usluge posredovanja pri nabavi dobara i usluga" +"4185","kp_rrif4185","kp_rrif418","other","account_type_posl_rashod",,,"Usluge posredovanja pri prodaji dobara i usluga","Usluge posredovanja pri prodaji dobara i usluga" +"4186","kp_rrif4186","kp_rrif418","other","account_type_posl_rashod",,,"Usluge agenata i detektiva","Usluge agenata i detektiva" +"4187","kp_rrif4187","kp_rrif418","other","account_type_posl_rashod",,,"Troškovi provizija za usluge","Troškovi provizija za usluge" +"419","kp_rrif419","kp_rrif41","view","account_type_view",,,"Troškovi ostalih vanjskih usluga","Troškovi ostalih vanjskih usluga" +"4190","kp_rrif4190","kp_rrif419","other","account_type_posl_rashod",,,"Usluge kontrole kakvoće i atestiranja dobara","Usluge kontrole kakvoće i atestiranja dobara" +"4191","kp_rrif4191","kp_rrif419","other","account_type_posl_rashod",,,"Usluge studentskog servisa","Usluge studentskog servisa" +"4192","kp_rrif4192","kp_rrif419","other","account_type_posl_rashod",,,"Hotelske usluge (u agencijskim poslovima)","Hotelske usluge (u agencijskim poslovima)" +"4193","kp_rrif4193","kp_rrif419","other","account_type_posl_rashod",,,"Vanjskotrgovačke usluge","Vanjskotrgovačke usluge" +"4194","kp_rrif4194","kp_rrif419","other","account_type_posl_rashod",,,"Špediterske usluge pri izvozu i sl.","Špediterske usluge pri izvozu i sl." +"4195","kp_rrif4195","kp_rrif419","other","account_type_posl_rashod",,,"Troškovi oglašavanja u tisku za slobodna radna mjesta, objava fin. izvješća i sl. (osim promidžbe)","Troškovi oglašavanja u tisku za slobodna radna mjesta, objava fin. izvješća i sl. (osim promidžbe)" +"4196","kp_rrif4196","kp_rrif419","other","account_type_posl_rashod",,,"Troškovi korištenja javnih skladišta, luka, pristaništa, hlađenja i sl.","Troškovi korištenja javnih skladišta, luka, pristaništa, hlađenja i sl." +"4197","kp_rrif4197","kp_rrif419","other","account_type_posl_rashod",,,"Trošak autoputa, tunela i mostarina","Trošak autoputa, tunela i mostarina" +"4198","kp_rrif4198","kp_rrif419","other","account_type_posl_rashod",,,"Troškovi fotokopiranja, prijepisa, izrade naljepnica i fotografija i sl.","Troškovi fotokopiranja, prijepisa, izrade naljepnica i fotografija i sl." +"4199","kp_rrif4199","kp_rrif419","other","account_type_posl_rashod",,,"Ostali nespomenuti vanjski troškovi - usluge","Ostali nespomenuti vanjski troškovi - usluge" +"42","kp_rrif42","kp_rrif4","view","account_type_view",,,"TROŠKOVI OSOBLJA - PLAĆE","TROŠKOVI OSOBLJA - PLAĆE" +"420","kp_rrif420","kp_rrif42","view","account_type_view",,,"Neto plaće i nadoknade","Neto plaće i nadoknade" +"4200","kp_rrif4200","kp_rrif420","other","account_type_posl_rashod",,,"Troškovi neto plaća uprave i prodaje","Troškovi neto plaća uprave i prodaje" +"4201","kp_rrif4201","kp_rrif420","other","account_type_posl_rashod",,,"Troškovi neto plaća proizvodnje","Troškovi neto plaća proizvodnje" +"4202","kp_rrif4202","kp_rrif420","other","account_type_posl_rashod",,,"Ostali povremeni primitci","Ostali povremeni primitci" +"421","kp_rrif421","kp_rrif42","view","account_type_view",,,"Troškovi poreza i prireza","Troškovi poreza i prireza" +"4210","kp_rrif4210","kp_rrif421","other","account_type_posl_rashod",,,"Uprava i prodaja","Uprava i prodaja" +"4211","kp_rrif4211","kp_rrif421","other","account_type_posl_rashod",,,"Proizvodnja","Proizvodnja" +"4212","kp_rrif4212","kp_rrif421","other","account_type_posl_rashod",,,"Ostali povremeni primitci","Ostali povremeni primitci" +"422","kp_rrif422","kp_rrif42","view","account_type_view",,,"Troškovi doprinosa iz plaća","Troškovi doprinosa iz plaća" +"4220","kp_rrif4220","kp_rrif422","other","account_type_posl_rashod",,,"Uprava i prodaja","Uprava i prodaja" +"4221","kp_rrif4221","kp_rrif422","other","account_type_posl_rashod",,,"Proizvodnja","Proizvodnja" +"4222","kp_rrif4222","kp_rrif422","other","account_type_posl_rashod",,,"Ostali povremeni primitci","Ostali povremeni primitci" +"423","kp_rrif423","kp_rrif42","view","account_type_view",,,"Doprinosi na plaće","Doprinosi na plaće" +"4230","kp_rrif4230","kp_rrif423","other","account_type_posl_rashod",,,"Uprava i prodaja","Uprava i prodaja" +"4231","kp_rrif4231","kp_rrif423","other","account_type_posl_rashod",,,"Proizvodnja","Proizvodnja" +"4232","kp_rrif4232","kp_rrif423","other","account_type_posl_rashod",,,"Ostali povremeni primitci","Ostali povremeni primitci - potpore i sl." +"4235","kp_rrif4235","kp_rrif423","other","account_type_posl_rashod",,,"Doprinosi za beneficirani radni staž","Doprinosi za beneficirani radni staž" +"424","kp_rrif424","kp_rrif42","view","account_type_view",,,"Bruto plaće (privremeno v. napom. 2)","Bruto plaće (privremeno v. napom. 2)" +"4240","kp_rrif4240","kp_rrif424","other","account_type_posl_rashod",,,"Bruto plaće (privremeno v. napom. 2)-a1","Bruto plaće (privremeno v. napom. 2)-Analitika 1" +"43","kp_rrif43","kp_rrif4","view","account_type_view",,,"AMORTIZACIJA","AMORTIZACIJA" +"430","kp_rrif430","kp_rrif43","view","account_type_view",,,"Amortizacija nematerijalne imovine","Amortizacija nematerijalne imovine" +"4300","kp_rrif4300","kp_rrif430","other","account_type_posl_rashod",,,"Amortizacija izdataka za razvoj","Amortizacija izdataka za razvoj" +"4301","kp_rrif4301","kp_rrif430","other","account_type_posl_rashod",,,"Amortizacija koncesije, patenata i dr. prava","Amortizacija koncesije, patenata i dr. prava" +"4302","kp_rrif4302","kp_rrif430","other","account_type_posl_rashod",,,"Amortizacija softvera i ost. prava","Amortizacija softvera i ost. prava" +"4303","kp_rrif4303","kp_rrif430","other","account_type_posl_rashod",,,"Amortizacija goodwila","Amortizacija goodwila" +"4304","kp_rrif4304","kp_rrif430","other","account_type_posl_rashod",,,"Amortizacija ostale nematerijalne imovine","Amortizacija ostale nematerijalne imovine" +"431","kp_rrif431","kp_rrif43","view","account_type_view",,,"Amortizacija materijalne imovine","Amortizacija materijalne imovine" +"4310","kp_rrif4310","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija građevina","Amortizacija građevina" +"4311","kp_rrif4311","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija postrojenja","Amortizacija postrojenja" +"4312","kp_rrif4312","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija opreme","Amortizacija opreme" +"4313","kp_rrif4313","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija alata i inventara","Amortizacija alata i inventara" +"4314","kp_rrif4314","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija transportnih sredstava","Amortizacija transportnih sredstava" +"4315","kp_rrif4315","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija brodova","Amortizacija brodova" +"4316","kp_rrif4316","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija poljoprivredne opreme","Amortizacija poljoprivredne opreme" +"4319","kp_rrif4319","kp_rrif431","other","account_type_posl_rashod",,,"Amortizacija ostale mater. imovine","Amortizacija ostale mater. imovine" +"432","kp_rrif432","kp_rrif43","view","account_type_view",,,"Amortizacija osobnih automobila i dr. sredstava za osobni prijevoz","Amortizacija osobnih automobila i dr. sredstava za osobni prijevoz" +"4320","kp_rrif4320","kp_rrif432","other","account_type_posl_rashod",,,"70% amortizacije osob. aut. i dr. sred. prijevoza","70% amortizacije osob. aut. i dr. sred. prijevoza" +"4321","kp_rrif4321","kp_rrif432","other","account_type_posl_rashod",,,"30% amortizacije osob. aut. i dr. sred. prijevoza","30% amortizacije osob. aut. i dr. sred. prijevoza" +"4322","kp_rrif4322","kp_rrif432","other","account_type_posl_rashod",,,"Dio amortizacije osob. aut. i dr. sred. prijevoza u vrijednosti iznad 400.000,00 kn","Dio amortizacije osob. aut. i dr. sred. prijevoza u vrijednosti iznad 400.000,00 kn" +"4323","kp_rrif4323","kp_rrif432","other","account_type_posl_rashod",,,"Amortizacija (otpis) nepriznatog PDV-a","Amortizacija (otpis) nepriznatog PDV-a" +"4324","kp_rrif4324","kp_rrif432","other","account_type_posl_rashod",,,"Amortiz. osob. aut. za sluč. plaće (neto + nepriz. PDV)","Amortiz. osob. aut. za sluč. plaće (neto + nepriz. PDV)" +"433","kp_rrif433","kp_rrif43","view","account_type_view",,,"Amortizacija objekata i opreme uprave i prodaje","Amortizacija objekata i opreme uprave i prodaje" +"4330","kp_rrif4330","kp_rrif433","other","account_type_posl_rashod",,,"Amortizacija građev. objekata","Amortizacija građev. objekata" +"4331","kp_rrif4331","kp_rrif433","other","account_type_posl_rashod",,,"Amortizacija računala, računalne opreme i programa te računalne mreže","Amortizacija računala, računalne opreme i programa te računalne mreže" +"4332","kp_rrif4332","kp_rrif433","other","account_type_posl_rashod",,,"Amortizacija osobnih automobila","Amortizacija osobnih automobila" +"4333","kp_rrif4333","kp_rrif433","other","account_type_posl_rashod",,,"Amortizacija ostale opreme (pokućstvo, telefonija i dr.)","Amortizacija ostale opreme (pokućstvo, telefonija i dr.)" +"434","kp_rrif434","kp_rrif43","view","account_type_view",,,"Povećana amortizacija s temelja revalorizacije","Povećana amortizacija s temelja revalorizacije" +"4340","kp_rrif4340","kp_rrif434","other","account_type_posl_rashod",,,"Povećana amortizacija s temelja revalorizacije-a1","Povećana amortizacija s temelja revalorizacije-Analitika 1" +"435","kp_rrif435","kp_rrif43","view","account_type_view",,,"Amortizacija biološke imovine (vinogradi, voćnjaci, osnovno stado i sl.)","Amortizacija biološke imovine (vinogradi, voćnjaci, osnovno stado i sl.)" +"4350","kp_rrif4350","kp_rrif435","other","account_type_posl_rashod",,,"Amortizacija biološke imovine (vinogradi, voćnjaci, osnovno stado i sl.)-a1","Amortizacija biološke imovine (vinogradi, voćnjaci, osnovno stado i sl.)-Analitika 1" +"436","kp_rrif436","kp_rrif43","view","account_type_view",,,"Amortizacija iznad porezno dopuštene","Amortizacija iznad porezno dopuštene" +"4360","kp_rrif4360","kp_rrif436","other","account_type_posl_rashod",,,"Amortizacija iznad porezno dopuštene-a1","Amortizacija iznad porezno dopuštene-Analitika 1" +"44","kp_rrif44","kp_rrif4","view","account_type_view",,,"VRIJEDNOSNO USKLAĐENJE DUGOTRAJNE I KRATKOTRAJNE IMOVINE","VRIJEDNOSNO USKLAĐENJE DUGOTRAJNE I KRATKOTRAJNE IMOVINE" +"440","kp_rrif440","kp_rrif44","view","account_type_view",,,"Vrijednosno usklađenje dugotrajne nematerijalne imovine (018)","Vrijednosno usklađenje dugotrajne nematerijalne imovine (018)" +"4400","kp_rrif4400","kp_rrif440","other","account_type_posl_rashod",,,"Vrijednosno usklađenje prava i dr.","Vrijednosno usklađenje prava i dr." +"4401","kp_rrif4401","kp_rrif440","other","account_type_posl_rashod",,,"Vrijednosno usklađenje goodwill","Vrijednosno usklađenje goodwill" +"4402","kp_rrif4402","kp_rrif440","other","account_type_posl_rashod",,,"Vrijednosno usklađenje ostale nemat. imov.","Vrijednosno usklađenje ostale nemat. imov." +"441","kp_rrif441","kp_rrif44","view","account_type_view",,,"Vrijednosno usklađenje dugotrajne materijalne imovine","Vrijednosno usklađenje dugotrajne materijalne imovine" +"4410","kp_rrif4410","kp_rrif441","other","account_type_posl_rashod",,,"Vrijednosno usklađenje nekretnina (028)","Vrijednosno usklađenje nekretnina (028)" +"4411","kp_rrif4411","kp_rrif441","other","account_type_posl_rashod",,,"Vrijednosno usklađenje postrojenja, opreme, alata, pogonskog inventara i transportne imovine (038)","Vrijednosno usklađenje postrojenja, opreme, alata, pogonskog inventara i transportne imovine (038)" +"4412","kp_rrif4412","kp_rrif441","other","account_type_posl_rashod",,,"Vrijednosno usklađenje biološke imovine (048)","Vrijednosno usklađenje biološke imovine (048)" +"4413","kp_rrif4413","kp_rrif441","other","account_type_posl_rashod",,,"Vrijednosno usklađenje ulaganja u nekretnine (058)","Vrijednosno usklađenje ulaganja u nekretnine (058)" +"4414","kp_rrif4414","kp_rrif441","other","account_type_posl_rashod",,,"Vrijednosno usklađenje ostale mater. imovine","Vrijednosno usklađenje ostale mater. imovine" +"442","kp_rrif442","kp_rrif44","view","account_type_view",,,"Vrijednosno usklađenje dugotrajnih potraživanja (veza sa 078)","Vrijednosno usklađenje dugotrajnih potraživanja (veza sa 078)" +"4420","kp_rrif4420","kp_rrif442","other","account_type_posl_rashod",,,"Vrijednosno usklađenje dugotrajnih potraživanja (veza sa 078)-a1","Vrijednosno usklađenje dugotrajnih potraživanja (veza sa 078)-Analitika 1" +"444","kp_rrif444","kp_rrif44","view","account_type_view",,,"Vrijednosno usklađenje depozita u bankama, mjenica, čekova i sl. (109 i dio 119)","Vrijednosno usklađenje depozita u bankama, mjenica, čekova i sl. (109 i dio 119)" +"4440","kp_rrif4440","kp_rrif444","other","account_type_posl_rashod",,,"Vrijednosno usklađenje depozita u bankama, mjenica, čekova i sl. (109 i dio 119)-a1","Vrijednosno usklađenje depozita u bankama, mjenica, čekova i sl. (109 i dio 119)-Analitika 1" +"445","kp_rrif445","kp_rrif44","view","account_type_view",,,"Vrijednosno usklađenje kratkotrajnih potraživanja","Vrijednosno usklađenje kratkotrajnih potraživanja" +"4450","kp_rrif4450","kp_rrif445","other","account_type_posl_rashod",,,"Vrijednosna usklađenja potraživanja od kupaca nenaplaćena dulje od 120 dana od dospijeća (veza s 129)","Vrijednosna usklađenja potraživanja od kupaca koja nisu naplaćena dulje od 120 dana od dospijeća (veza s 129)" +"4451","kp_rrif4451","kp_rrif445","other","account_type_posl_rashod",,,"Vrijed. usklađenja utuženih kratk. pot. do 5000,00kn (prije zastare,ovršni,stečaj i sl.-dio129,139i159)","Vrijednosna usklađenja kratkoročnih potraživanja od kupaca i drugih koja su utužena (prije zastare, koja su u ovršnom postupku, otvoren je stečaj, nagodba i sl. - dio 129, 139 i 159) i svote do 5.000,00 kn" +"4452","kp_rrif4452","kp_rrif445","other","account_type_posl_rashod",,,"Vrijednosna usklađenja zastarjelih potraživanja (dio sa 129, 139 i 159) - porezno nepriznata","Vrijednosna usklađenja zastarjelih potraživanja (dio sa 129, 139 i 159) - porezno nepriznata" +"446","kp_rrif446","kp_rrif44","view","account_type_view",,,"Vrijednosno usklađenje zaliha (veza s 319, 329, 359 i 369)","Vrijednosno usklađenje zaliha (veza s 319, 329, 359 i 369)" +"4460","kp_rrif4460","kp_rrif446","other","account_type_posl_rashod",,,"Vrijednosno usklađenje zaliha (veza s 319, 329, 359 i 369)-a1","Vrijednosno usklađenje zaliha (veza s 319, 329, 359 i 369)-Analitika 1" +"447","kp_rrif447","kp_rrif44","view","account_type_view",,,"Vrijednosno usklađenje danih predujmova (veza s 379)","Vrijednosno usklađenje danih predujmova (veza s 379)" +"4470","kp_rrif4470","kp_rrif447","other","account_type_posl_rashod",,,"Vrijednosno usklađenje danih predujmova (veza s 379)-a1","Vrijednosno usklađenje danih predujmova (veza s 379)-Analitika 1" +"45","kp_rrif45","kp_rrif4","view","account_type_view",,,"REZERVIRANJA (v. skupinu 28)","REZERVIRANJA (v. skupinu 28)" +"450","kp_rrif450","kp_rrif45","view","account_type_view",,,"Troškovi dugoročnog rezerviranja za rizike u jamstvenom (garancijskom) roku (čl. 11., st. 2. ZoPD)","Troškovi dugoročnog rezerviranja za rizike u jamstvenom (garancijskom) roku (čl. 11., st. 2. ZoPD)" +"4500","kp_rrif4500","kp_rrif450","other","account_type_posl_rashod",,,"Troškovi dugoročnog rezerviranja za rizike u jamstvenom (garancijskom) roku (čl. 11., st. 2. ZoPD)-a1","Troškovi dugoročnog rezerviranja za rizike u jamstvenom (garancijskom) roku (čl. 11., st. 2. ZoPD)-Analitika 1" +"451","kp_rrif451","kp_rrif45","view","account_type_view",,,"Troškovi dugoročnog rezerviranja za gubitke po započetim sudskim sporovima (čl. 11., st. 2. ZoPD)","Troškovi dugoročnog rezerviranja za gubitke po započetim sudskim sporovima (čl. 11., st. 2. ZoPD)" +"4510","kp_rrif4510","kp_rrif451","other","account_type_posl_rashod",,,"Troškovi dugoročnog rezerviranja za gubitke po započetim sudskim sporovima (čl. 11., st. 2. ZoPD)-a1","Troškovi dugoročnog rezerviranja za gubitke po započetim sudskim sporovima (čl. 11., st. 2. ZoPD)-Analitika 1" +"452","kp_rrif452","kp_rrif45","view","account_type_view",,,"Troškovi dugoročnog rezerviranja za obnovu prirodnog bogatstva (čl. 11., st. 2. ZoPD)","Troškovi dugoročnog rezerviranja za obnovu prirodnog bogatstva (čl. 11., st. 2. ZoPD)" +"4520","kp_rrif4520","kp_rrif452","other","account_type_posl_rashod",,,"Troškovi dugoročnog rezerviranja za obnovu prirodnog bogatstva (čl. 11., st. 2. ZoPD)-a1","Troškovi dugoročnog rezerviranja za obnovu prirodnog bogatstva (čl. 11., st. 2. ZoPD)-Analitika 1" +"453","kp_rrif453","kp_rrif45","view","account_type_view",,,"Troškovi dugoročnog rezerviranja za otpremnine (čl. 11., st. 2. ZoPD)","Troškovi dugoročnog rezerviranja za otpremnine (čl. 11., st. 2. ZoPD)" +"4530","kp_rrif4530","kp_rrif453","other","account_type_posl_rashod",,,"Troškovi dugoročnog rezerviranja za otpremnine (čl. 11., st. 2. ZoPD)-a1","Troškovi dugoročnog rezerviranja za otpremnine (čl. 11., st. 2. ZoPD)-Analitika 1" +"454","kp_rrif454","kp_rrif45","view","account_type_view",,,"Troškovi dugoroč. rez. za neiskorišteni godišnji odmor (čl. 11., st. 5. ZoPD i MRS 19) - vidi rač. 298","Troškovi dugoroč. rez. za neiskorišteni godišnji odmor (čl. 11., st. 5. ZoPD i MRS 19) - vidi rač. 298" +"4540","kp_rrif4540","kp_rrif454","other","account_type_posl_rashod",,,"Troškovi dugoroč. rez. za neiskorišteni godišnji odmor (čl. 11., st. 5. ZoPD i MRS 19) - vidi rač. 298-a1","Troškovi dugoroč. rez. za neiskorišteni godišnji odmor (čl. 11., st. 5. ZoPD i MRS 19) - vidi rač. 298-Analitika 1" +"455","kp_rrif455","kp_rrif45","view","account_type_view",,,"Troškovi dugoročnog rezerviranja za restrukturiranje poduzeća (MRS 37, t. 72. i HSFI t. 16.22)","Troškovi dugoročnog rezerviranja za restrukturiranje poduzeća (MRS 37, t. 72. i HSFI t. 16.22)" +"4550","kp_rrif4550","kp_rrif455","other","account_type_posl_rashod",,,"Troškovi dugoročnog rezerviranja za restrukturiranje poduzeća (MRS 37, t. 72. i HSFI t. 16.22)-a1","Troškovi dugoročnog rezerviranja za restrukturiranje poduzeća (MRS 37, t. 72. i HSFI t. 16.22)-Analitika 1" +"456","kp_rrif456","kp_rrif45","view","account_type_view",,,"Troškovi dugoročnog rezerviranja za mirovine i slične troškove - obveze (MRS 19)","Troškovi dugoročnog rezerviranja za mirovine i slične troškove - obveze (MRS 19)" +"4560","kp_rrif4560","kp_rrif456","other","account_type_posl_rashod",,,"Troškovi dugoročnog rezerviranja za mirovine i slične troškove - obveze (MRS 19)-a1","Troškovi dugoročnog rezerviranja za mirovine i slične troškove - obveze (MRS 19)-Analitika 1" +"457","kp_rrif457","kp_rrif45","view","account_type_view",,,"Troškovi rezerviranja po štetnim ugovorima (HSFI 16.21.)","Troškovi rezerviranja po štetnim ugovorima (HSFI 16.21.)" +"4570","kp_rrif4570","kp_rrif457","other","account_type_posl_rashod",,,"Troškovi rezerviranja po štetnim ugovorima (HSFI 16.21.)-a1","Troškovi rezerviranja po štetnim ugovorima (HSFI 16.21.)-Analitika 1" +"459","kp_rrif459","kp_rrif45","view","account_type_view",,,"Troškovi ostalih dugoročnih rezerviranja i troškovi rizika","Troškovi ostalih dugoročnih rezerviranja i troškovi rizika" +"4590","kp_rrif4590","kp_rrif459","other","account_type_posl_rashod",,,"Troškovi ostalih dugoročnih rezerviranja i troškovi rizika-a1","Troškovi ostalih dugoročnih rezerviranja i troškovi rizika-Analitika 1" +"46","kp_rrif46","kp_rrif4","view","account_type_view",,,"OSTALI TROŠKOVI POSLOVANJA","OSTALI TROŠKOVI POSLOVANJA" +"460","kp_rrif460","kp_rrif46","view","account_type_view",,,"Dnevnice za službena putovanja i putni troškovi","Dnevnice za službena putovanja i putni troškovi" +"4600","kp_rrif4600","kp_rrif460","other","account_type_posl_rashod",,,"Dnevnice za službena putovanja i troškovi noćenja u Hrvatskoj","Dnevnice za službena putovanja i troškovi noćenja u Hrvatskoj" +"4601","kp_rrif4601","kp_rrif460","other","account_type_posl_rashod",,,"Dnevnice za službena putovanja u inozemstvu","Dnevnice za službena putovanja u inozemstvu" +"4602","kp_rrif4602","kp_rrif460","other","account_type_posl_rashod",,,"Troškovi uporabe vlastitog automobila na službenom putu","Troškovi uporabe vlastitog automobila na službenom putu" +"4603","kp_rrif4603","kp_rrif460","other","account_type_posl_rashod",,,"Terenski dodatak - pomorski dodatak","Terenski dodatak - pomorski dodatak" +"4604","kp_rrif4604","kp_rrif460","other","account_type_posl_rashod",,,"Doprinos za zdravstveno osiguranje na službena putovanja u inozemstvo","Doprinos za zdravstveno osiguranje na službena putovanja u inozemstvo" +"4605","kp_rrif4605","kp_rrif460","other","account_type_posl_rashod",,,"Troškovi noćenja (po računu hotela i dr.)","Troškovi noćenja (po računu hotela i dr.)" +"4606","kp_rrif4606","kp_rrif460","other","account_type_posl_rashod",,,"Ostali troškovi na službenom putu (trošak autoceste, tunela, parkiranja, trajekta i dr.)","Ostali troškovi na službenom putu (trošak autoceste, tunela, parkiranja, trajekta i dr.)" +"4607","kp_rrif4607","kp_rrif460","other","account_type_posl_rashod",,,"Troškovi službenog puta vanjskih suradnika (bruto s porezima i doprinosima)","Troškovi službenog puta vanjskih suradnika (bruto s porezima i doprinosima)" +"461","kp_rrif461","kp_rrif46","view","account_type_view",,,"Nadoknade troškova, darovi i potpore","Nadoknade troškova, darovi i potpore" +"4610","kp_rrif4610","kp_rrif461","other","account_type_posl_rashod",,,"Troškovi prijevoza na posao i s posla","Troškovi prijevoza na posao i s posla" +"4611","kp_rrif4611","kp_rrif461","other","account_type_posl_rashod",,,"Loko vožnja - Nadoknada za uporabu privatnog automobila u poslovne svrhe za lokalnu vožnju","Nadoknada za uporabu privatnog automobila u poslovne svrhe za lokalnu vožnju" +"4612","kp_rrif4612","kp_rrif461","other","account_type_posl_rashod",,,"Nadoknade za odvojeni život","Nadoknade za odvojeni život" +"4613","kp_rrif4613","kp_rrif461","view","account_type_view",,,"Stipendije, nagrade učenicima i studentima","Stipendije, nagrade učenicima i studentima" +"46130","kp_rrif46130","kp_rrif4613","other","account_type_posl_rashod",,,"Stipendije i nagrade učenicima i studentima do neoporezivih svota","Stipendije i nagrade učenicima i studentima do neoporezivih svota" +"46131","kp_rrif46131","kp_rrif4613","other","account_type_posl_rashod",,,"Stipendije i nagrade učenicima i studentima iznad neoporezivih svota","Stipendije i nagrade učenicima i studentima iznad neoporezivih svota" +"4614","kp_rrif4614","kp_rrif461","other","account_type_posl_rashod",,,"Otpremnine (odlazak u mirovinu, otkaz i teh.viška-čl.119.ZOR-a,ozljeda ili prof.bolesti (čl.80.ZOR-a)","Otpremnine (zbog odlaska radnika u mirovinu i otpremnine zbog danih otkaza i tehnološkog viška - čl. 119. ZOR-a, te otpremnine zbog ozljede ili profesionalne bolesti (čl. 80. ZOR-a)" +"4615","kp_rrif4615","kp_rrif461","other","account_type_posl_rashod",,,"Darovi djeci i slične potpore (ako nisu dohodak)","Darovi djeci i slične potpore (ako nisu dohodak)" +"4616","kp_rrif4616","kp_rrif461","other","account_type_posl_rashod",,,"Prigodne nagrade (božićnice,uskrsnice,u naravi do 400kn, regres, jubilarne i sl., do 2500kn god.)","Prigodne nagrade (božićnice, uskrsnice, dar u naravi (do 400,00 kn god., regres za god. odmor, jubilarne nagrade i sl., do 2.500,00 kn god.)" +"4617","kp_rrif4617","kp_rrif461","other","account_type_posl_rashod",,,"Potpora zbog bolesti, invalidnosti, smrti, elementarnih nepogoda i sl.","Potpora zbog bolesti, invalidnosti, smrti, elementarnih nepogoda i sl." +"4618","kp_rrif4618","kp_rrif461","other","account_type_posl_rashod",,,"Potpore i pomoći iznad neoporezivih svota","Potpore i pomoći iznad neoporezivih svota" +"4619","kp_rrif4619","kp_rrif461","other","account_type_posl_rashod",,,"Ostali troškovi zaposlenika","Ostali troškovi zaposlenika" +"462","kp_rrif462","kp_rrif46","view","account_type_view",,,"Troškovi članova uprave","Troškovi članova uprave" +"4620","kp_rrif4620","kp_rrif462","other","account_type_posl_rashod",,,"Nadoknade članovima nadzornog odbora","Nadoknade članovima nadzornog odbora" +"4621","kp_rrif4621","kp_rrif462","other","account_type_posl_rashod",,,"Nadoknade vanjskim članovima uprave","Nadoknade vanjskim članovima uprave" +"4622","kp_rrif4622","kp_rrif462","other","account_type_posl_rashod",,,"Nadoknade stečajnim upraviteljima","Nadoknade stečajnim upraviteljima" +"4623","kp_rrif4623","kp_rrif462","other","account_type_posl_rashod",,,"Nadoknade prokuristima, članovima skupštine društva i dr.","Nadoknade prokuristima, članovima skupštine društva i dr." +"4624","kp_rrif4624","kp_rrif462","other","account_type_posl_rashod",,,"Troškovi usluga vanjske uprave (po računu)","Troškovi usluga vanjske uprave (po računu)" +"4625","kp_rrif4625","kp_rrif462","other","account_type_posl_rashod",,,"Troškovi honorara vanjskim članovima uprave","Troškovi honorara vanjskim članovima uprave" +"4626","kp_rrif4626","kp_rrif462","other","account_type_posl_rashod",,,"Godišnje nagrade članovima uprave","Godišnje nagrade članovima uprave" +"463","kp_rrif463","kp_rrif46","view","account_type_view",,,"Troškovi reprezentacije i promidžbe (interne)","Troškovi reprezentacije i promidžbe (interne)" +"4630","kp_rrif4630","kp_rrif463","other","account_type_posl_rashod",,,"70% troškova reprezentacije u darovima (robi i proizvodima + 70% PDV-a","70% troškova reprezentacije u darovima (robi i proizvodima + 70% PDV-a" +"4631","kp_rrif4631","kp_rrif463","other","account_type_posl_rashod",,,"70% troškova vlastitih usluga za reprezentaciju + 70% PDV-a","70% troškova vlastitih usluga za reprezentaciju + 70% PDV-a" +"4632","kp_rrif4632","kp_rrif463","other","account_type_posl_rashod",,,"70% troškova reprezentacije od uporabe vlastitih brodova, automobila, nekretnina i sl. + 70% PDV-a","70% troškova reprezentacije od uporabe vlastitih brodova, automobila, nekretnina i sl. + 70% PDV-a" +"4633","kp_rrif4633","kp_rrif463","other","account_type_posl_rashod",,,"30% od svih neto-troškova reprezentacije (vlastitih)","30% od svih neto-troškova reprezentacije (vlastitih)" +"4635","kp_rrif4635","kp_rrif463","other","account_type_posl_rashod",,,"Troškovi promidžbe (u katalozima, letcima, nagradne igre)","Troškovi promidžbe (u katalozima, letcima, nagradne igre)" +"4636","kp_rrif4636","kp_rrif463","other","account_type_posl_rashod",,,"Troškovi promidžbe u proizvodima ili robi (""nije za prodaju"" do 80,00 kn )","Troškovi promidžbe u proizvodima ili robi (s oznakom ""nije za prodaju"" s nazivom tvrtke ili proizvoda pojedinačne vrijedn. do 80,00 kn - čaše, pepeljare, stoljnjaci, podmetači, olovke, rokovnici, upaljači, privjesci i sl.)" +"464","kp_rrif464","kp_rrif46","view","account_type_view",,,"Premije osiguranja","Premije osiguranja" +"4640","kp_rrif4640","kp_rrif464","other","account_type_posl_rashod",,,"Troškovi osiguranja dugotrajne materijalne i nematerijalne imovine","Troškovi osiguranja dugotrajne materijalne i nematerijalne imovine" +"4641","kp_rrif4641","kp_rrif464","other","account_type_posl_rashod",,,"Premije osiguranja osoba (opasni poslovi, prenošenje novca, putnici i sl.)","Premije osiguranja osoba (opasni poslovi, prenošenje novca, putnici i sl.)" +"4642","kp_rrif4642","kp_rrif464","other","account_type_posl_rashod",,,"Premije osiguranja prometnih sredstava (uključivo i kasko)","Premije osiguranja prometnih sredstava (uključivo i kasko)" +"4643","kp_rrif4643","kp_rrif464","other","account_type_posl_rashod",,,"Transportno osiguranje dobara","Transportno osiguranje dobara" +"4644","kp_rrif4644","kp_rrif464","other","account_type_posl_rashod",,,"Premije za zdravstveno osiguranje","Premije za zdravstveno osiguranje" +"4645","kp_rrif4645","kp_rrif464","other","account_type_posl_rashod",,,"Troškovi premija životnog osiguranja (ugovaratelj i korisnik je trgovačko društvo)","Troškovi premija životnog osiguranja (ugovaratelj i korisnik je trgovačko društvo)" +"4646","kp_rrif4646","kp_rrif464","other","account_type_posl_rashod",,,"Premije dobrovoljnog mirov. osig. (do 6000kn god. po radniku-čl.10.Zak. o porezu na dohodak -NN80/10)","Premije dobrovoljnog mirov. osig. (do 6.000 kn godišnje po radniku - čl. 10. Zak. o porezu na dohodak - Nar. nov., br. 80/10.)" +"4647","kp_rrif4647","kp_rrif464","other","account_type_posl_rashod",,,"Premije za dokup mirovine zaposlenicima (III. stup) MRS 19 t. 43. i 44.","Premije za dokup mirovine zaposlenicima (III. stup) MRS 19 t. 43. i 44." +"4649","kp_rrif4649","kp_rrif464","other","account_type_posl_rashod",,,"Premije za ostale oblike osiguranja","Premije za ostale oblike osiguranja" +"465","kp_rrif465","kp_rrif46","view","account_type_view",,,"Bankovne usluge i troškovi platnog prometa","Bankovne usluge i troškovi platnog prometa" +"4650","kp_rrif4650","kp_rrif465","other","account_type_posl_rashod",,,"Troškovi platnog prometa","Troškovi platnog prometa" +"4651","kp_rrif4651","kp_rrif465","other","account_type_posl_rashod",,,"Troškovi provizija (pri kupnji deviza, brokeru i dr.)","Troškovi provizija (pri kupnji deviza, brokeru i dr.)" +"4652","kp_rrif4652","kp_rrif465","other","account_type_posl_rashod",,,"Bankovne usluge (za inozemni platni promet, tečajnu maržu i sl.)","Bankovne usluge (za inozemni platni promet, tečajnu maržu i sl.)" +"4653","kp_rrif4653","kp_rrif465","other","account_type_posl_rashod",,,"Troškovi provizija izdavatelja kreditnih kartica","Troškovi provizija izdavatelja kreditnih kartica" +"4654","kp_rrif4654","kp_rrif465","other","account_type_posl_rashod",,,"Troškovi obrade kredita","Troškovi obrade kredita" +"4655","kp_rrif4655","kp_rrif465","other","account_type_posl_rashod",,,"Troškovi akreditiva","Troškovi akreditiva" +"4656","kp_rrif4656","kp_rrif465","other","account_type_posl_rashod",,,"Troškovi bankovne garancije","Troškovi bankovne garancije" +"4657","kp_rrif4657","kp_rrif465","other","account_type_posl_rashod",,,"Ostali bankovni troškovi","Ostali bankovni troškovi" +"466","kp_rrif466","kp_rrif46","view","account_type_view",,,"Članarine, nadoknade i slična davanja","Članarine, nadoknade i slična davanja" +"4660","kp_rrif4660","kp_rrif466","other","account_type_posl_rashod",,,"Članarine komori (HGK ili HOK) i dopr. za javne ovlasti","Članarine komori (HGK ili HOK) i dopr. za javne ovlasti" +"4661","kp_rrif4661","kp_rrif466","other","account_type_posl_rashod",,,"Članarine udrugama i strukovnim komorama","Članarine udrugama i strukovnim komorama" +"4662","kp_rrif4662","kp_rrif466","other","account_type_posl_rashod",,,"Nadoknada za općekorisnu funkciju šuma (0,0525%)","Nadoknada za općekorisnu funkciju šuma (0,0525%)" +"4663","kp_rrif4663","kp_rrif466","other","account_type_posl_rashod",,,"Članarina turističkoj zajednici","Članarina turističkoj zajednici" +"4664","kp_rrif4664","kp_rrif466","other","account_type_posl_rashod",,,"Nadoknada za korištenje mineralnih sirovina","Nadoknada za korištenje mineralnih sirovina" +"4665","kp_rrif4665","kp_rrif466","other","account_type_posl_rashod",,,"Pričuva za održavanje zgrade (Zakon o vlasništvu - Nar. nov., br. 91/96. do 38/09.)","Pričuva za održavanje zgrade (Zakon o vlasništvu - Nar. nov., br. 91/96. do 38/09.)" +"4666","kp_rrif4666","kp_rrif466","other","account_type_posl_rashod",,,"Dozvole za korištenje autocesta, atesta, certifikata i sl.","Dozvole za korištenje autocesta, atesta, certifikata i sl." +"4667","kp_rrif4667","kp_rrif466","other","account_type_posl_rashod",,,"Članarina za kreditne i potrošačke kartice","Članarina za kreditne i potrošačke kartice" +"4668","kp_rrif4668","kp_rrif466","other","account_type_posl_rashod",,,"Spomenička renta","Spomenička renta" +"4669","kp_rrif4669","kp_rrif466","other","account_type_posl_rashod",,,"Ostala davanja","Ostala davanja" +"467","kp_rrif467","kp_rrif46","view","account_type_view",,,"Porezi koji ne ovise o dobitku i pristojbe","Porezi koji ne ovise o dobitku i pristojbe" +"4670","kp_rrif4670","kp_rrif467","other","account_type_posl_rashod",,,"Porez na tvrtku odnosno naziv","Porez na tvrtku odnosno naziv" +"4671","kp_rrif4671","kp_rrif467","other","account_type_posl_rashod",,,"Porez (imovinski) na cestovna vozila, plovne objekte i zrakoplove","Porez (imovinski) na cestovna vozila, plovne objekte i zrakoplove" +"4672","kp_rrif4672","kp_rrif467","other","account_type_posl_rashod",,,"Porez na reklame koje se ističu na javnim mjestima","Porez na reklame koje se ističu na javnim mjestima" +"4673","kp_rrif4673","kp_rrif467","other","account_type_posl_rashod",,,"Naknade Fondu za ambalažu (prema materijalu, po jed. proizv., povratna i poticajna ambalaža)","Naknade Fondu za ambalažu (prema materijalu, po jed. proizv., povratna i poticajna ambalaža)" +"4674","kp_rrif4674","kp_rrif467","other","account_type_posl_rashod",,,"Porez na kuće za odmor","Porez na kuće za odmor" +"4675","kp_rrif4675","kp_rrif467","other","account_type_posl_rashod",,,"Trošak poreza koji je ugovorno preuzet pri prodaji (npr. 5% p.p.n.)","Trošak poreza koji je ugovorno preuzet pri prodaji (npr. 5% p.p.n.)" +"4676","kp_rrif4676","kp_rrif467","view","account_type_view",,,"Trošak PDV-a koji se ne može priznati","Trošak PDV-a koji se ne može priznati" +"46760","kp_rrif46760","kp_rrif4676","other","account_type_posl_rashod",,,"Trošak PDV-a iz vlastite potrošnje (ako već nije sadržan u trošku)","Trošak PDV-a iz vlastite potrošnje (ako već nije sadržan u trošku)" +"46761","kp_rrif46761","kp_rrif4676","other","account_type_posl_rashod",,,"Trošak PDV-a za koji je prestalo pravo na pretporez","Trošak PDV-a za koji je prestalo pravo na pretporez" +"46762","kp_rrif46762","kp_rrif4676","other","account_type_posl_rashod",,,"30% PDV-a na osobne automobile i dr. sredstva osobnog prijevoza","30% PDV-a na osobne automobile i dr. sredstva osobnog prijevoza" +"46763","kp_rrif46763","kp_rrif4676","other","account_type_posl_rashod",,,"PDV na osobne automobile i dr. sred. prijevoza na dio n. v. iznad 400.000,00 kn","PDV na osobne automobile i dr. sred. prijevoza na dio n. v. iznad 400.000,00 kn" +"4677","kp_rrif4677","kp_rrif467","other","account_type_posl_rashod",,,"Porez po odbitku","Porez po odbitku" +"4678","kp_rrif4678","kp_rrif467","other","account_type_posl_rashod",,,"Troškovi naknadno utvrđenih poreza (npr. PDV, posebni i dr. porezi, osim poreza na dobitak)","Troškovi naknadno utvrđenih poreza (npr. PDV, posebni i dr. porezi, osim poreza na dobitak)" +"4679","kp_rrif4679","kp_rrif467","view","account_type_posl_rashod",,,"Ostali porezi i pristojbe","Ostali porezi i pristojbe" +"46790","kp_rrif46790","kp_rrif4679","other","account_type_posl_rashod",,,"Porez i carina pri izvozu","Porez i carina pri izvozu" +"468","kp_rrif468","kp_rrif46","view","account_type_view",,,"Troškovi prava korištenja (osim najmova)","Troškovi prava korištenja (osim najmova)" +"4680","kp_rrif4680","kp_rrif468","other","account_type_posl_rashod",,,"Troškovi koncesije","Troškovi koncesije" +"4681","kp_rrif4681","kp_rrif468","other","account_type_posl_rashod",,,"Troškovi franšiza, know howa, patenata, uporabe imena, znaka i dr.","Troškovi franšiza, know howa, patenata, uporabe imena, znaka i dr." +"4682","kp_rrif4682","kp_rrif468","other","account_type_posl_rashod",,,"Troškovi prava na proizvodni i sl. postupak","Troškovi prava na proizvodni i sl. postupak" +"4683","kp_rrif4683","kp_rrif468","other","account_type_posl_rashod",,,"Trošak prava na model, nacrt, formulu, plan, iskustvo i sl.","Trošak prava na model, nacrt, formulu, plan, iskustvo i sl." +"4684","kp_rrif4684","kp_rrif468","other","account_type_posl_rashod",,,"Trošak HRT pretplate","Trošak HRT pretplate" +"4685","kp_rrif4685","kp_rrif468","other","account_type_posl_rashod",,,"Troškovi licenciranih prava","Troškovi licenciranih prava" +"4686","kp_rrif4686","kp_rrif468","other","account_type_posl_rashod",,,"Troškovi prava uporabe računalnih programa","Troškovi prava uporabe računalnih programa" +"4689","kp_rrif4689","kp_rrif468","other","account_type_posl_rashod",,,"Ostali troškovi prava korištenja","Ostali troškovi prava korištenja" +"469","kp_rrif469","kp_rrif46","view","account_type_view",,,"Ostali troškovi poslovanja - nematerijalni","Ostali troškovi poslovanja - nematerijalni" +"4690","kp_rrif4690","kp_rrif469","view","account_type_view",,,"Troškovi obrazovanja zaposlenika (stručno, seminari, stručni ispiti,prekval., fakulteti, jezici i sl.)","Troškovi obrazovanja i izobrazbe zaposlenika (stručno obrazovanje, seminari, simpoziji, stručni ispiti, stručno usavršavanje, prekvalifikacije, fakulteti, poslijediplomski, doktorati, učenje jezika i sl.)" +"46900","kp_rrif46900","kp_rrif4690","other","account_type_posl_rashod",,,"Opće obrazovanje","Opće obrazovanje" +"46901","kp_rrif46901","kp_rrif4690","other","account_type_posl_rashod",,,"Posebno obrazovanje","Posebno obrazovanje" +"4691","kp_rrif4691","kp_rrif469","other","account_type_posl_rashod",,,"Troškovi za priručnike, časopise i stručnu literaturu","Troškovi za priručnike, časopise i stručnu literaturu" +"4692","kp_rrif4692","kp_rrif469","other","account_type_posl_rashod",,,"Troškovi službenih glasila","Troškovi službenih glasila" +"4693","kp_rrif4693","kp_rrif469","other","account_type_posl_rashod",,,"Sudski troškovi i pristojbe","Sudski troškovi i pristojbe" +"4694","kp_rrif4694","kp_rrif469","other","account_type_posl_rashod",,,"Troškovi zdravstvenog nadzora i kontrola proizvoda, robe, usluge i sl.","Troškovi zdravstvenog nadzora i kontrola proizvoda, robe, usluge i sl." +"4695","kp_rrif4695","kp_rrif469","other","account_type_posl_rashod",,,"Troškovi obveznih liječničkih pregleda","Troškovi obveznih liječničkih pregleda" +"4696","kp_rrif4696","kp_rrif469","other","account_type_posl_rashod",,,"Troškovi sistematskih kontrolnih liječničkih pregleda zaposlenika","Troškovi sistematskih kontrolnih liječničkih pregleda zaposlenika" +"4697","kp_rrif4697","kp_rrif469","other","account_type_posl_rashod",,,"Troškovi osnivanja (bilježnik, sud, oglasi, odvjetnik)","Troškovi osnivanja (bilježnik, sud, oglasi, odvjetnik)" +"4698","kp_rrif4698","kp_rrif469","other","account_type_posl_rashod",,,"Troškovi licenciranja, certifikata i sl.","Troškovi licenciranja, certifikata i sl." +"4699","kp_rrif4699","kp_rrif469","other","account_type_posl_rashod",,,"Ostali nespomenuti nematerijalni troškovi (ulaznice za sajmove i dr.)","Ostali nespomenuti nematerijalni troškovi (ulaznice za sajmove i dr.)" +"47","kp_rrif47","kp_rrif4","view","account_type_view",,,"FINANCIJSKI RASHODI","FINANCIJSKI RASHODI" +"470","kp_rrif470","kp_rrif47","view","account_type_view",,,"Kamate od povezanih društava","Kamate od povezanih društava" +"4700","kp_rrif4700","kp_rrif470","other","account_type_posl_rashod",,,"Ugovorene kamate","Ugovorene kamate" +"4701","kp_rrif4701","kp_rrif470","other","account_type_posl_rashod",,,"Zatezne kamate (čl. 7., st. 1., t. 9. ZoPD)","Zatezne kamate (čl. 7., st. 1., t. 9. ZoPD)" +"4702","kp_rrif4702","kp_rrif470","other","account_type_posl_rashod",,,"Kamate - porezno nepriznate","Kamate - porezno nepriznate" +"4703","kp_rrif4703","kp_rrif470","other","account_type_posl_rashod",,,"Kamate koje se uračunavaju u zalihe (MRS 23. t.11. i HSFI t. 10.22.)","Kamate koje se uračunavaju u zalihe (MRS 23. t.11. i HSFI t. 10.22.)" +"471","kp_rrif471","kp_rrif47","view","account_type_view",,,"Tečajne razlike iz odnosa s povezanim društvima","Tečajne razlike iz odnosa s povezanim društvima" +"4710","kp_rrif4710","kp_rrif471","other","account_type_posl_rashod",,,"Tečajne razlike iz odnosa s povezanim društvima-a1","Tečajne razlike iz odnosa s povezanim društvima-Analitika 1" +"472","kp_rrif472","kp_rrif47","view","account_type_view",,,"Ostali troškovi iz odnosa s povezanim poduzetnicima","Ostali troškovi iz odnosa s povezanim poduzetnicima" +"4720","kp_rrif4720","kp_rrif472","other","account_type_posl_rashod",,,"Rashodi financiranja, troškovi popusta i naknadnih odobrenja s povezanim poduzetnicima","Rashodi financiranja, troškovi popusta i naknadnih odobrenja s povezanim poduzetnicima" +"4721","kp_rrif4721","kp_rrif472","other","account_type_posl_rashod",,,"Troškovi usluga uprave koncerna i sl.","Troškovi usluga uprave koncerna i sl." +"473","kp_rrif473","kp_rrif47","view","account_type_view",,,"Kamate iz odnosa s nepovezanim društvima","Kamate iz odnosa s nepovezanim društvima" +"4730","kp_rrif4730","kp_rrif473","other","account_type_posl_rashod",,,"Kamate na kredite banaka","Kamate na kredite banaka" +"4731","kp_rrif4731","kp_rrif473","other","account_type_posl_rashod",,,"Kamate iz lizing poslova","Kamate iz lizing poslova" +"4732","kp_rrif4732","kp_rrif473","other","account_type_posl_rashod",,,"Kamate na zajmove pravnih osoba","Kamate na zajmove pravnih osoba" +"4733","kp_rrif4733","kp_rrif473","other","account_type_posl_rashod",,,"Kamata na pozajmice članova društva i dioničara","Kamata na pozajmice članova društva i dioničara" +"4734","kp_rrif4734","kp_rrif473","other","account_type_posl_rashod",,,"Kamate na zajmove od fizičkih osoba","Kamate na zajmove od fizičkih osoba" +"4735","kp_rrif4735","kp_rrif473","other","account_type_posl_rashod",,,"Diskontne kamate po mjenicama i dr. vrijednosnim papirima","Diskontne kamate po mjenicama i dr. vrijednosnim papirima" +"474","kp_rrif474","kp_rrif47","view","account_type_view",,,"Zatezne kamate","Zatezne kamate" +"4740","kp_rrif4740","kp_rrif474","other","account_type_posl_rashod",,,"Zatezne kamate iz trgovačkih ugovora","Zatezne kamate iz trgovačkih ugovora" +"4741","kp_rrif4741","kp_rrif474","other","account_type_posl_rashod",,,"Zatezne kamate na poreze, doprinose i dr. davanja","Zatezne kamate na poreze, doprinose i dr. davanja" +"4742","kp_rrif4742","kp_rrif474","other","account_type_posl_rashod",,,"Zatezne kamate između povezanih osoba (por. neprizn.)","Zatezne kamate između povezanih osoba (por. neprizn.)" +"4743","kp_rrif4743","kp_rrif474","other","account_type_posl_rashod",,,"Zatezne kamate po sudskim presudama","Zatezne kamate po sudskim presudama" +"4744","kp_rrif4744","kp_rrif474","other","account_type_posl_rashod",,,"Ostale zatezne kamate","Ostale zatezne kamate" +"475","kp_rrif475","kp_rrif47","view","account_type_view",,,"Tečajne razlike iz odnosa s nepovezanim društvima","Tečajne razlike iz odnosa s nepovezanim društvima" +"4750","kp_rrif4750","kp_rrif475","other","account_type_posl_rashod",,,"Negativne tečajne razlike iz obveza za nabave u inozemstvu","Negativne tečajne razlike iz obveza za nabave u inozemstvu" +"4751","kp_rrif4751","kp_rrif475","other","account_type_posl_rashod",,,"Negativne tečajne razlike iz kreditnih obveza","Negativne tečajne razlike iz kreditnih obveza" +"4752","kp_rrif4752","kp_rrif475","other","account_type_posl_rashod",,,"Negativne tečajne razlike iz potraživanja u inozemstvu","Negativne tečajne razlike iz potraživanja u inozemstvu" +"4753","kp_rrif4753","kp_rrif475","other","account_type_posl_rashod",,,"Negativne teč. razlike za ostalo (npr. iz blagajničkog, razlika kupovnog i srednjeg tečaja banke i dr.)","Negativne tečajne razlike za ostalo (npr. iz blagajničkog poslovanja, razlika između kupovnog i srednjeg tečaja banke i dr.)" +"4754","kp_rrif4754","kp_rrif475","other","account_type_posl_rashod",,,"Negativne tečajne razlike nastale na stanjima deviznog računa i devizne blagajne","Negativne tečajne razlike nastale na stanjima deviznog računa i devizne blagajne" +"476","kp_rrif476","kp_rrif47","view","account_type_view",,,"Gubitci iz ulaganja u dionice, udjele i dr. vrij. papire (prodane ispod troška nabave - čl. 10. ZoPD","Gubitci iz ulaganja u dionice, udjele, obveznice i dr. vrijednosne papire (koji su prodani ispod troška nabave - čl. 10. ZoPD" +"4760","kp_rrif4760","kp_rrif476","other","account_type_posl_rashod",,,"Gubitci iz ulaganja u dionice, udjele i dr. vrij. papire (prodane ispod troška nabave - čl. 10. ZoPD-a1","Gubitci iz ulaganja u dionice, udjele, obveznice i dr. vrijednosne papire (koji su prodani ispod troška nabave - čl. 10. ZoPD-Analitika 1" +"477","kp_rrif477","kp_rrif47","view","account_type_view",,,"Troškovi diskonta i nagodbi","Troškovi diskonta i nagodbi" +"4770","kp_rrif4770","kp_rrif477","other","account_type_posl_rashod",,,"Troškovi diskonta pri prodaji potraživanja (faktoring)","Troškovi diskonta pri prodaji potraživanja (faktoring)" +"4771","kp_rrif4771","kp_rrif477","other","account_type_posl_rashod",,,"Troškovi iz financijskih nagodbi","Troškovi iz financijskih nagodbi" +"4772","kp_rrif4772","kp_rrif477","other","account_type_posl_rashod",,,"Ostali troškovi","Ostali troškovi" +"478","kp_rrif478","kp_rrif47","view","account_type_view",,,"Nerealizirani gubitci (rashodi) od financ. imovine","Nerealizirani gubitci (rashodi) od financ. imovine" +"4780","kp_rrif4780","kp_rrif478","other","account_type_posl_rashod",,,"Gubitci od smanjenja – vrijed. usklađenja fin. imovine za trgovanje (MRS 39. t. 55a. i HSFI t. 9.22b)","Gubitci od smanjenja - vrijednosnog usklađenja fin. imovine za trgovanje (MRS 39. t. 55a. i HSFI t. 9.22b)" +"4781","kp_rrif4781","kp_rrif478","other","account_type_posl_rashod",,,"Troškovi smanjenja fin. imovine zbog ugovora o poteškoćama (HSFI t. 9.22a i MRS 39. t. 55b.)","Troškovi smanjenja fin. imovine zbog ugovora o poteškoćama (HSFI t. 9.22a i MRS 39. t. 55b.)" +"4782","kp_rrif4782","kp_rrif478","other","account_type_posl_rashod",,,"Gubitci od smanjenja vrijednosti ostale financ. imov.","Gubitci od smanjenja vrijednosti ostale financ. imov." +"479","kp_rrif479","kp_rrif47","view","account_type_view",,,"Ostali financijski troškovi","Ostali financijski troškovi" +"4790","kp_rrif4790","kp_rrif479","other","account_type_posl_rashod",,,"Rashodi s osnove valutne klauzule po obvezama i kreditima","Rashodi s osnove valutne klauzule po obvezama i kreditima" +"4791","kp_rrif4791","kp_rrif479","other","account_type_posl_rashod",,,"Rashodi s osnove usklađenja obveza zbog valutne i sl. klauzule (dobavljači, za predujmove i sl.)","Rashodi s osnove usklađenja obveza temeljem valutne i sl. klauzule (prema dobavljačima, za predujmove i sl.)" +"4792","kp_rrif4792","kp_rrif479","other","account_type_posl_rashod",,,"Troškovi valutne klauzule iz tražbina ili obveza","Troškovi valutne klauzule iz tražbina ili obveza" +"4793","kp_rrif4793","kp_rrif479","other","account_type_posl_rashod",,,"Troškovi burzovnih usluga, emisije vrijednosnih papira i sl.","Troškovi burzovnih usluga, emisije vrijednosnih papira i sl." +"4794","kp_rrif4794","kp_rrif479","other","account_type_posl_rashod",,,"Troškovi carine inozemnog financijskog i operativnog lizinga","Troškovi carine inozemnog financijskog i operativnog lizinga" +"4799","kp_rrif4799","kp_rrif479","other","account_type_posl_rashod",,,"Ostali nespomenuti financijski troškovi","Ostali nespomenuti financijski troškovi" +"48","kp_rrif48","kp_rrif4","view","account_type_view",,,"OSTALI POSLOVNI RASHODI","OSTALI POSLOVNI RASHODI" +"480","kp_rrif480","kp_rrif48","view","account_type_view",,,"Trošak naknadnih popusta, sniženja, reklamacija i troškovi uzoraka","Trošak naknadnih popusta, sniženja, reklamacija i troškovi uzoraka" +"4800","kp_rrif4800","kp_rrif480","other","account_type_posl_rashod",,,"Naknadno odobreni popusti i odobrenja","Naknadno odobreni popusti i odobrenja" +"4801","kp_rrif4801","kp_rrif480","other","account_type_posl_rashod",,,"Troškovi nagodbe (razlike iz sniženja)","Troškovi nagodbe (razlike iz sniženja)" +"4802","kp_rrif4802","kp_rrif480","other","account_type_posl_rashod",,,"Troškovi nenadoknađenih jamstava za prodana dobra","Troškovi nenadoknađenih jamstava za prodana dobra" +"4803","kp_rrif4803","kp_rrif480","other","account_type_posl_rashod",,,"Troškovi naknadnih reklamacija","Troškovi naknadnih reklamacija" +"4804","kp_rrif4804","kp_rrif480","other","account_type_posl_rashod",,,"Troškovi uzoraka zbog kontrole i pregleda, izlaganje radi prodaje i sl.","Troškovi uzoraka zbog kontrole i pregleda, izlaganje radi prodaje i sl." +"481","kp_rrif481","kp_rrif48","view","account_type_view",,,"Otpisi vrijednosno neusklađenih potraživanja","Otpisi vrijednosno neusklađenih potraživanja" +"4810","kp_rrif4810","kp_rrif481","other","account_type_posl_rashod",,,"Otpisi nenaplaćenih jamstava i drugih osiguranja","Otpisi nenaplaćenih jamstava i drugih osiguranja" +"4811","kp_rrif4811","kp_rrif481","other","account_type_posl_rashod",,,"Izravni otpisi nenaplaćenih potraživanja od kupaca i drugih koja nisu vrijednosno usklađena","Izravni otpisi nenaplaćenih potraživanja od kupaca i drugih koja nisu vrijednosno usklađena" +"4812","kp_rrif4812","kp_rrif481","other","account_type_posl_rashod",,,"Troškovi ostalih otpisa","Troškovi ostalih otpisa" +"482","kp_rrif482","kp_rrif48","view","account_type_view",,,"Rashodi - otpisi nematerijalne i materijalne imovine","Rashodi - otpisi nematerijalne i materijalne imovine" +"4820","kp_rrif4820","kp_rrif482","other","account_type_posl_rashod",,,"Neamortizirana vrijednost rashodovane, uništene ili otuđene dugotrajne imovine","Neamortizirana vrijednost rashodovane, uništene ili otuđene dugotrajne imovine" +"4821","kp_rrif4821","kp_rrif482","other","account_type_posl_rashod",,,"Otpisi imovine izvan uporabe - rashod","Otpisi imovine izvan uporabe - rashod" +"4822","kp_rrif4822","kp_rrif482","other","account_type_posl_rashod",,,"Gubitak od prodane dug. imov. koja se ne amortizira","Gubitak od prodane dug. imov. koja se ne amortizira" +"4823","kp_rrif4823","kp_rrif482","other","account_type_posl_rashod",,,"Gubitak od prodaje ost. dug. mat. i nemat. imovine","Gubitak od prodaje ost. dug. mat. i nemat. imovine" +"4824","kp_rrif4824","kp_rrif482","other","account_type_posl_rashod",,,"Otpisi materijala i robe - rashod","Otpisi materijala i robe - rashod" +"483","kp_rrif483","kp_rrif48","view","account_type_view",,,"Manjkovi i provalne krađe na zalihama i drugim sredstvima","Manjkovi i provalne krađe na zalihama i drugim sredstvima" +"4830","kp_rrif4830","kp_rrif483","other","account_type_posl_rashod",,,"Manjkovi uslijed više sile (provalna krađa, elementarna nepogoda)","Manjkovi uslijed više sile (provalna krađa, elementarna nepogoda)" +"4831","kp_rrif4831","kp_rrif483","other","account_type_posl_rashod",,,"Dopušteni manjkovi - kalo, rastep, kvar i lom na zalihama prema odlukama HGK, HOK ili internim aktima","Dopušteni manjkovi - kalo, rastep, kvar i lom na zalihama prema odlukama HGK, HOK ili internim aktima" +"4832","kp_rrif4832","kp_rrif483","other","account_type_posl_rashod",,,"Prekomjerni manjkovi na zalihama (KRL) iznad normativa+PDV, prema HGK,(čl.7.,st.5.ZoPD)","Prekomjerni manjkovi na zalihama (kalo, rastep, kvar i lom) iznad normativa + PDV, prema odlukama HGK, HOK ili interno - skrivene isplate (čl. 7., st. 5. ZoPD)" +"4833","kp_rrif4833","kp_rrif483","other","account_type_posl_rashod",,,"Manjkovi novca i vrijednosnih papira","Manjkovi novca i vrijednosnih papira" +"4839","kp_rrif4839","kp_rrif483","other","account_type_posl_rashod",,,"Ostali manjkovi iz imovine","Ostali manjkovi iz imovine" +"484","kp_rrif484","kp_rrif48","view","account_type_view",,,"Kazne, penali, nadoknade šteta i troškovi iz ugovora","Kazne, penali, nadoknade šteta i troškovi iz ugovora" +"4840","kp_rrif4840","kp_rrif484","other","account_type_posl_rashod",,,"Troškovi kazni za prijestupe i prekršaje i sl. (čl. 7., st. 1., t. 7. ZoPD)","Troškovi kazni za prijestupe i prekršaje i sl. (čl. 7., st. 1., t. 7. ZoPD)" +"4841","kp_rrif4841","kp_rrif484","other","account_type_posl_rashod",,,"Troškovi prisilne naplate poreza i dr. davanja (čl. 7., st. 1., t. 6. ZoPD)","Troškovi prisilne naplate poreza i dr. davanja (čl. 7., st. 1., t. 6. ZoPD)" +"4842","kp_rrif4842","kp_rrif484","other","account_type_posl_rashod",,,"Penali, ležarine, dangubnine","Penali, ležarine, dangubnine" +"4843","kp_rrif4843","kp_rrif484","other","account_type_posl_rashod",,,"Nadoknade šteta iz radnog odnosa (npr. za godišnji odmor, ozljede na radu, odštetne rente i sl.)","Nadoknade šteta iz radnog odnosa (npr. za neiskorišteni godišnji odmor, zbog ozljede na radu, odštetne rente i sl.)" +"4844","kp_rrif4844","kp_rrif484","other","account_type_posl_rashod",,,"Nadoknade štete - troškovi po nagodbama i sudskim presudama - tužbama","Nadoknade štete - troškovi po nagodbama i sudskim presudama - tužbama" +"4845","kp_rrif4845","kp_rrif484","other","account_type_posl_rashod",,,"Ugovorene kazne i penali zbog neizvršenja, propusta i sl.","Ugovorene kazne i penali zbog neizvršenja, propusta i sl." +"4846","kp_rrif4846","kp_rrif484","other","account_type_posl_rashod",,,"Troškovi preuzetih obveza iz ugovora","Troškovi preuzetih obveza iz ugovora" +"4847","kp_rrif4847","kp_rrif484","other","account_type_posl_rashod",,,"Kazne za parkiranje","Kazne za parkiranje" +"4849","kp_rrif4849","kp_rrif484","other","account_type_posl_rashod",,,"Ostali izdatci za štete","Ostali izdatci za štete" +"485","kp_rrif485","kp_rrif48","view","account_type_view",,,"Naknadno utvrđeni troškovi poslovanja","Naknadno utvrđeni troškovi poslovanja" +"4850","kp_rrif4850","kp_rrif485","other","account_type_posl_rashod",,,"Naknadno utvrđeni troškovi - računi iz prethodnih godina","Naknadno utvrđeni troškovi - računi iz prethodnih godina" +"4851","kp_rrif4851","kp_rrif485","other","account_type_posl_rashod",,,"Troškovi naknadnih razlika iz nabava","Troškovi naknadnih razlika iz nabava" +"4852","kp_rrif4852","kp_rrif485","other","account_type_posl_rashod",,,"Ispravak pogrešaka prethodnih razdoblja","Ispravak pogrešaka prethodnih razdoblja" +"486","kp_rrif486","kp_rrif48","view","account_type_view",,,"Darovanje do 2% od ukupnog prihoda","Darovanje do 2% od ukupnog prihoda" +"4860","kp_rrif4860","kp_rrif486","other","account_type_posl_rashod",,,"Darovanje za općekorisne namjene (u novcu ili naravi do 2% od UP pr.god. - čl. 7., st. 7. ZoPD)","Darovanje za općekorisne namjene (Darovi u novcu ili naravi do 2% od ukupnog prihoda prethodne godine za kulturu, znanost, odgoj i obrazovanje, zdravstvo, humanitarne, športske, vjerske, ekološke i dr. svrhe - čl. 7., st. 7. ZoPD)" +"4861","kp_rrif4861","kp_rrif486","other","account_type_posl_rashod",,,"Darovanje za zdrav.potrebe (vanjskih osoba do 2% UPpr.god. a nije pokriveno osig.-čl.7.,st.8.ZoPD)","Darovanje za zdravstvene potrebe (darovanje vanjskih osoba do 2% od UP prethodne godine za operativne zahvate, liječenja, nabavu lijekova, ortopedskih pomagala i dr. što nije pokriveno osiguranjem - čl. 7., st. 8. ZoPD)" +"487","kp_rrif487","kp_rrif48","view","account_type_view",,,"Darovanja iznad 2% od UP i dr. darovanja","Darovanja iznad 2% od UP i dr. darovanja" +"4870","kp_rrif4870","kp_rrif487","other","account_type_posl_rashod",,,"Porezno nepriznata darovanja iznad 2% UP (iznad dop. s 486) i ino. udruga i sl. (čl.7.st.1.t.10 ZoPD)","Porezno nepriznata darovanja iznad 2% UP (za svrhe iznad dopuštenih s računa 486) i darovanja inozemnih udruga, ustanova i sl. (čl. 7. st. 1. t. 10. ZoPD)" +"4871","kp_rrif4871","kp_rrif487","other","account_type_posl_rashod",,,"Darovi bez protučinidbe prim. i izdatci nisu u svezi s ostv.dobitka+PDV,osim na novac-čl7,st1.,t13ZoPD","Darovi (milodari), potpore i dotacije bez protučinidbe primatelja, te dr. izdatci koji nisu u svezi s ostvarivanjem dobitka (+PDV, osim na novac - čl. 7., st. 1., t. 13. ZoPD)" +"4872","kp_rrif4872","kp_rrif487","other","account_type_posl_rashod",,,"Darovanje političkih stranaka i nezavisnih kandidata","Darovanje političkih stranaka i nezavisnih kandidata" +"488","kp_rrif488","kp_rrif48","view","account_type_view",,,"Troškovi iz drugih aktivnosti (izvan osnovne djelatnosti)","Troškovi iz drugih aktivnosti (izvan osnovne djelatnosti)" +"4880","kp_rrif4880","kp_rrif488","other","account_type_posl_rashod",,,"Troškovi iz ortačkog ugovora","Troškovi iz ortačkog ugovora" +"4881","kp_rrif4881","kp_rrif488","other","account_type_posl_rashod",,,"Troškovi iz posredovanja","Troškovi iz posredovanja" +"489","kp_rrif489","kp_rrif48","view","account_type_view",,,"Ostali troškovi - rashodi (čl. 7. ZoPD)","Ostali troškovi - rashodi (čl. 7. ZoPD)" +"4890","kp_rrif4890","kp_rrif489","other","account_type_posl_rashod",,,"Rashodi utvrđeni u postupku nadzora (čl. 7. st. 1. t. 11. ZoPD) - skrivene isplate dobitka","Rashodi utvrđeni u postupku nadzora (čl. 7. st. 1. t. 11. ZoPD) - skrivene isplate dobitka - izuzimanje dioničara članova društva i fizičkih osoba (obrtnika) i s njima povez. osobama" +"4891","kp_rrif4891","kp_rrif489","other","account_type_posl_rashod",,,"Troškovi -porezno nepriznati- koji nisu u svezi s ostvarivanjem dobitka(čl7, st1,t13.ZoPD-red.br.24PD) ","Troškovi koji nisu izravno u svezi s ostvarivanjem dobitka (čl. 7., st. 1., t. 13. ZoPD - red. br. 24 PD, npr. amortiz. imov. koja ne služi obavljanju djelatnosti, dodjela vlastitih dionica - udjela i dr.) - porezno nepriznati" +"4892","kp_rrif4892","kp_rrif489","other","account_type_posl_rashod",,,"Troškovi povalstica i dr. oblici imovinskih koristi (čl. 7., st.1. t.10. ZoPD) - porezno nepriznati","Troškovi povalstica i dr. oblici imovinskih koristi (čl. 7., st.1. t.10. ZoPD) - porezno nepriznati" +"4899","kp_rrif4899","kp_rrif489","other","account_type_posl_rashod",,,"Ostali nespomenuti poslovni rashodi","Ostali nespomenuti poslovni rashodi" +"49","kp_rrif49","kp_rrif4","view","account_type_view",,,"RASPORED TROŠKOVA","RASPORED TROŠKOVA" +"490","kp_rrif490","kp_rrif49","view","account_type_view",,,"Raspored troškova za obračun proiz. i usluga (HSFI10, MRS2, MRS11)-uskladištivi troškovi (na 60,62i63)","Raspored troškova za obračun proizvoda i usluga (prema HSFI 10 i MRS-u 2 i MRS-u 11) - uskladištivi troškovi (na račune 60, 62 i 63)" +"4900","kp_rrif4900","kp_rrif490","other","account_type_posl_rashod",,,"Raspored troškova za obračun proiz. i usluga (HSFI10, MRS2, MRS11)-uskladištivi troškovi (na 60,62i63)-a1","Raspored troškova za obračun proizvoda i usluga (prema HSFI 10 i MRS-u 2 i MRS-u 11) - uskladištivi troškovi (na račune 60, 62 i 63)-Analitika 1" +"491","kp_rrif491","kp_rrif49","view","account_type_view",,,"Raspored troškova za pokriće upravnih, administrativnih, prodajnih i drugih troškova (na rn 70 i 71)","Raspored troškova za pokriće upravnih, administrativnih, prodajnih i drugih troškova (na račune 70 i 71)" +"4910","kp_rrif4910","kp_rrif491","other","account_type_posl_rashod",,,"Raspored troškova za pokriće upravnih, administrativnih, prodajnih i drugih troškova (na rn 70 i 71)-a1","Raspored troškova za pokriće upravnih, administrativnih, prodajnih i drugih troškova (na račune 70 i 71)-Analitika 1" +"6","kp_rrif6","kp_rrif","view","account_type_view",,,"PROIZVODNJA, BIOLOŠKA IMOVINA, GOTOVI PROIZVODI, ROBA I DUGOTRAJNA IMOVINA NAMIJENJENA PRODAJI","PROIZVODNJA, GOTOVI PROIZVODI, ROBA I DUGOTRAJNA IMOVINA NAMIJENJENA PRODAJI" +"60","kp_rrif60","kp_rrif6","view","account_type_view",,,"PROIZVODNJA - TROŠKOVI KONVERZIJE","PROIZVODNJA - TROŠKOVI KONVERZIJE" +"600","kp_rrif600","kp_rrif60","view","account_type_view",,,"Proizvodnja u tijeku (po serijama, nositeljima, mjestima, radnim nalozima i sl.)","Proizvodnja u tijeku (razrada po serijama, nositeljima troškova, mjestima, pogonima, gradilištima, objektima, radnim nalozima i sl.)" +"6000","kp_rrif6000","kp_rrif600","other","account_type_kratk_imovina",,,"Proizvodnja u tijeku (po serijama, nositeljima, mjestima, radnim nalozima i sl.)-a1","Proizvodnja u tijeku (razrada po serijama, nositeljima troškova, mjestima, pogonima, gradilištima, objektima, radnim nalozima i sl.)-Analitika 1" +"601","kp_rrif601","kp_rrif60","view","account_type_view",,,"Vrijednost usluga (u tijeku ili nedovršenih na datum bilance - MRS 2, t. 16.)","Vrijednost usluga (u tijeku ili nedovršenih na datum bilance - MRS 2, t. 16.)" +"6010","kp_rrif6010","kp_rrif601","other","account_type_kratk_imovina",,,"Vrijednost usluga (u tijeku ili nedovršenih na datum bilance - MRS 2, t. 16.)-a1","Vrijednost usluga (u tijeku ili nedovršenih na datum bilance - MRS 2, t. 16.)-Analitika 1" +"602","kp_rrif602","kp_rrif60","view","account_type_view",,,"Vanjska proizvodnja (kooperacija i dr.)","Vanjska proizvodnja (kooperacija i dr.)" +"6020","kp_rrif6020","kp_rrif602","other","account_type_kratk_imovina",,,"Vanjska proizvodnja (kooperacija i dr.)-a1","Vanjska proizvodnja (kooperacija i dr.)-Analitika 1" +"605","kp_rrif605","kp_rrif60","view","account_type_view",,,"Proizvodnja u slobodnoj zoni","Proizvodnja u slobodnoj zoni" +"6050","kp_rrif6050","kp_rrif605","other","account_type_kratk_imovina",,,"Proizvodnja u slobodnoj zoni-a1","Proizvodnja u slobodnoj zoni-Analitika 1" +"606","kp_rrif606","kp_rrif60","view","account_type_view",,,"Proizvodnja u doradi i manipulaciji","Proizvodnja u doradi i manipulaciji" +"6060","kp_rrif6060","kp_rrif606","other","account_type_kratk_imovina",,,"Proizvodnja u doradi i manipulaciji-a1","Proizvodnja u doradi i manipulaciji-Analitika 1" +"607","kp_rrif607","kp_rrif60","view","account_type_view",,,"Obustavljena proizvodnja","Obustavljena proizvodnja" +"6070","kp_rrif6070","kp_rrif607","other","account_type_kratk_imovina",,,"Obustavljena proizvodnja-a1","Obustavljena proizvodnja-Analitika 1" +"608","kp_rrif608","kp_rrif60","view","account_type_view",,,"Proizvodnja u tijeku iz ortačkog ugovora","Proizvodnja u tijeku iz ortačkog ugovora" +"6080","kp_rrif6080","kp_rrif608","other","account_type_kratk_imovina",,,"Proizvodnja u tijeku iz ortačkog ugovora-a1","Proizvodnja u tijeku iz ortačkog ugovora-Analitika 1" +"609","kp_rrif609","kp_rrif60","view","account_type_view",,,"Vrijednosno usklađivanje proizvodnje - usluga","Vrijednosno usklađivanje proizvodnje - usluga" +"6090","kp_rrif6090","kp_rrif609","other","account_type_kratk_imovina",,,"Vrijednosno usklađivanje proizvodnje - usluga-a1","Vrijednosno usklađivanje proizvodnje - usluga-Analitika 1" +"61","kp_rrif61","kp_rrif6","view","account_type_view",,,"NEDOVRŠENI PROIZVODI I POLUPROIZVODI","NEDOVRŠENI PROIZVODI I POLUPROIZVODI" +"610","kp_rrif610","kp_rrif61","view","account_type_view",,,"Zalihe poluproizvoda (analitika prema osnovnim skupinama ili po stupnju dovršenosti)","Zalihe poluproizvoda (analitika prema osnovnim skupinama ili po stupnju dovršenosti)" +"6100","kp_rrif6100","kp_rrif610","other","account_type_kratk_imovina",,,"Zalihe poluproizvoda (analitika prema osnovnim skupinama ili po stupnju dovršenosti)-a1","Zalihe poluproizvoda (analitika prema osnovnim skupinama ili po stupnju dovršenosti)-Analitika 1" +"611","kp_rrif611","kp_rrif61","view","account_type_view",,,"Nedovršeni proizvodi i poluproizvodi (analitika po vrstama proizvoda)","Nedovršeni proizvodi i poluproizvodi (analitika po vrstama proizvoda)" +"6110","kp_rrif6110","kp_rrif611","other","account_type_kratk_imovina",,,"Nedovršeni proizvodi i poluproizvodi (analitika po vrstama proizvoda)-a1","Nedovršeni proizvodi i poluproizvodi (analitika po vrstama proizvoda)-Analitika 1" +"619","kp_rrif619","kp_rrif61","view","account_type_view",,,"Vrijednosno usklađivanje nedovršenih proizvoda i poluproizvoda","Vrijednosno usklađivanje nedovršenih proizvoda i poluproizvoda" +"6190","kp_rrif6190","kp_rrif619","other","account_type_kratk_imovina",,,"Vrijednosno usklađivanje nedovršenih proizvoda i poluproizvoda-a1","Vrijednosno usklađivanje nedovršenih proizvoda i poluproizvoda-Analitika 1" +"62","kp_rrif62","kp_rrif6","view","account_type_view",,,"BIOLOŠKA IMOVINA","BIOLOŠKA IMOVINA" +"620","kp_rrif620","kp_rrif62","view","account_type_view",,,"Zalihe biološke proizvodnje u toku","Zalihe biološke proizvodnje u toku" +"6200","kp_rrif6200","kp_rrif620","other","account_type_kratk_imovina",,,"Zalihe biološke proizvodnje u toku-a1","Zalihe biološke proizvodnje u toku-Analitika 1" +"621","kp_rrif621","kp_rrif62","view","account_type_view",,,"Zaliha biloške imovine za prodaju","Biloška imovina za prodaju" +"6210","kp_rrif6210","kp_rrif621","other","account_type_kratk_imovina",,,"Biloška imovina za prodaju-a1","Biloška imovina za prodaju-Analitika 1" +"629","kp_rrif629","kp_rrif62","view","account_type_view",,,"Vrijednosno usklađivanje biloške imovine","Vrijednosno usklađivanje biloške imovine" +"6290","kp_rrif6290","kp_rrif629","other","account_type_kratk_imovina",,,"Vrijednosno usklađivanje biloške imovine-a1","Vrijednosno usklađivanje biloške imovine-Analitika 1" +"63","kp_rrif63","kp_rrif6","view","account_type_view",,,"ZALIHE GOTOVIH PROIZVODA","ZALIHE GOTOVIH PROIZVODA" +"630","kp_rrif630","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi na skladištu (razrada za svako skladište, pa po skupinama, tipovima, vrstama i sl.)","Gotovi proizvodi na skladištu (razrada za svako skladište a unutar toga po skupinama, tipovima, vrstama i sl.)" +"6300","kp_rrif6300","kp_rrif630","other","account_type_kratk_imovina",,,"Gotovi proizvodi na skladištu (razrada za svako skladište, pa po skupinama, tipovima, vrstama i sl.)-a1","Gotovi proizvodi na skladištu (razrada za svako skladište a unutar toga po skupinama, tipovima, vrstama i sl.)-Analitika 1" +"631","kp_rrif631","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi u javnom skladištu, silosu, i dr.","Gotovi proizvodi u javnom skladištu, silosu, i dr." +"6310","kp_rrif6310","kp_rrif631","other","account_type_kratk_imovina",,,"Gotovi proizvodi u javnom skladištu, silosu, i dr.-a1","Gotovi proizvodi u javnom skladištu, silosu, i dr.-Analitika 1" +"632","kp_rrif632","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi dani u komisijsku prodaju","Gotovi proizvodi dani u komisijsku prodaju" +"6320","kp_rrif6320","kp_rrif632","other","account_type_kratk_imovina",,,"Gotovi proizvodi dani u komisijsku prodaju-a1","Gotovi proizvodi dani u komisijsku prodaju-Analitika 1" +"633","kp_rrif633","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi dani u konsignacijsku prodaju","Gotovi proizvodi dani u konsignacijsku prodaju" +"6330","kp_rrif6330","kp_rrif633","other","account_type_kratk_imovina",,,"Gotovi proizvodi dani u konsignacijsku prodaju-a1","Gotovi proizvodi dani u konsignacijsku prodaju-Analitika 1" +"634","kp_rrif634","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi u doradi, obradi i manipulaciji","Gotovi proizvodi u doradi, obradi i manipulaciji" +"6340","kp_rrif6340","kp_rrif634","other","account_type_kratk_imovina",,,"Gotovi proizvodi u doradi, obradi i manipulaciji-a1","Gotovi proizvodi u doradi, obradi i manipulaciji-Analitika 1" +"635","kp_rrif635","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi u slobodnoj zoni","Gotovi proizvodi u slobodnoj zoni" +"6350","kp_rrif6350","kp_rrif635","other","account_type_kratk_imovina",,,"Gotovi proizvodi u slobodnoj zoni-a1","Gotovi proizvodi u slobodnoj zoni-Analitika 1" +"636","kp_rrif636","kp_rrif63","view","account_type_view",,,"Zalihe nekurentnih proizvoda i otpadaka","Zalihe nekurentnih proizvoda i otpadaka" +"6360","kp_rrif6360","kp_rrif636","other","account_type_kratk_imovina",,,"Zalihe nekurentnih proizvoda i otpadaka-a1","Zalihe nekurentnih proizvoda i otpadaka-Analitika 1" +"637","kp_rrif637","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi u izložbenim prostorima","Gotovi proizvodi u izložbenim prostorima" +"6370","kp_rrif6370","kp_rrif637","other","account_type_kratk_imovina",,,"Gotovi proizvodi u izložbenim prostorima-a1","Gotovi proizvodi u izložbenim prostorima-Analitika 1" +"638","kp_rrif638","kp_rrif63","view","account_type_view",,,"Gotovi proizvodi iz ortaštava","Gotovi proizvodi iz ortaštava" +"6380","kp_rrif6380","kp_rrif638","other","account_type_kratk_imovina",,,"Gotovi proizvodi iz ortaštava-a1","Gotovi proizvodi iz ortaštava-Analitika 1" +"639","kp_rrif639","kp_rrif63","view","account_type_view",,,"Vrijednosno usklađivanje zaliha gotovih proizvoda","Vrijednosno usklađivanje zaliha gotovih proizvoda" +"6390","kp_rrif6390","kp_rrif639","other","account_type_kratk_imovina",,,"Vrijednosno usklađivanje zaliha gotovih proizvoda-a1","Vrijednosno usklađivanje zaliha gotovih proizvoda-Analitika 1" +"64","kp_rrif64","kp_rrif6","view","account_type_view",,,"GOTOVI PROIZVODI U VLASTITIM PRODAVAONICAMA","GOTOVI PROIZVODI U VLASTITIM PRODAVAONICAMA" +"640","kp_rrif640","kp_rrif64","view","account_type_view",,,"Gotovi proizvodi u prodaji u vlastitim prodavaonicama (analitika po prodavaonicama)","Gotovi proizvodi u prodaji u vlastitim prodavaonicama (analitika po prodavaonicama)" +"6400","kp_rrif6400","kp_rrif640","other","account_type_kratk_imovina",,,"Gotovi proizvodi u prodaji u vlastitim prodavaonicama (analitika po prodavaonicama)-a1","Gotovi proizvodi u prodaji u vlastitim prodavaonicama (analitika po prodavaonicama)-Analitika 1" +"641","kp_rrif641","kp_rrif64","view","account_type_view",,,"Uračunani PDV u vrijednosti proizvoda","Uračunani PDV u vrijednosti proizvoda" +"6410","kp_rrif6410","kp_rrif641","other","account_type_kratk_imovina",,,"Uračunani PDV u vrijednosti proizvoda-a1","Uračunani PDV u vrijednosti proizvoda-Analitika 1" +"642","kp_rrif642","kp_rrif64","view","account_type_view",,,"Uračunani porez na luksuz","Uračunani porez na luksuz" +"6420","kp_rrif6420","kp_rrif642","other","account_type_kratk_imovina",,,"Uračunani porez na luksuz-a1","Uračunani porez na luksuz-Analitika 1" +"648","kp_rrif648","kp_rrif64","view","account_type_view",,,"Uračunana marža u prodajnoj cijeni gotovih proizvoda","Uračunana marža u prodajnoj cijeni gotovih proizvoda" +"6480","kp_rrif6480","kp_rrif648","other","account_type_kratk_imovina",,,"Uračunana marža u prodajnoj cijeni gotovih proizvoda-a1","Uračunana marža u prodajnoj cijeni gotovih proizvoda-Analitika 1" +"649","kp_rrif649","kp_rrif64","view","account_type_view",,,"Vrijednosno usklađivanje gotovih proizvoda u prodavaonicama","Vrijednosno usklađivanje gotovih proizvoda u prodavaonicama" +"6490","kp_rrif6490","kp_rrif649","other","account_type_kratk_imovina",,,"Vrijednosno usklađivanje gotovih proizvoda u prodavaonicama-a1","Vrijednosno usklađivanje gotovih proizvoda u prodavaonicama-Analitika 1" +"65","kp_rrif65","kp_rrif6","view","account_type_view",,,"OBRAČUN TROŠKOVA NABAVE ROBE - TROŠKOVI KUPNJE","OBRAČUN TROŠKOVA NABAVE ROBE - TROŠKOVI KUPNJE" +"650","kp_rrif650","kp_rrif65","view","account_type_view",,,"Kupovna cijena robe od dobavljača","Kupovna cijena robe od dobavljača" +"6500","kp_rrif6500","kp_rrif650","other","account_type_kratk_imovina",,,"Kupovna cijena robe od dobavljača-a1","Kupovna cijena robe od dobavljača-Analitika 1" +"651","kp_rrif651","kp_rrif65","view","account_type_view",,,"Ostali troškovi nabave u svezi s dovođenjem robe na zalihu","Ostali troškovi nabave u svezi s dovođenjem robe na zalihu" +"6510","kp_rrif6510","kp_rrif651","other","account_type_kratk_imovina",,,"Troškovi transporta","Troškovi transporta" +"6511","kp_rrif6511","kp_rrif651","other","account_type_kratk_imovina",,,"Troškovi ukrcaja i iskrcaja (fakturirani)","Troškovi ukrcaja i iskrcaja (fakturirani)" +"6512","kp_rrif6512","kp_rrif651","other","account_type_kratk_imovina",,,"Transportno osiguranje","Transportno osiguranje" +"6513","kp_rrif6513","kp_rrif651","other","account_type_kratk_imovina",,,"Troškovi posebnog pakiranja - ambalaže","Troškovi posebnog pakiranja - ambalaže" +"6514","kp_rrif6514","kp_rrif651","other","account_type_kratk_imovina",,,"Troškovi vlastitog transporta (ne više od tarife javnog prijevoza) dovođenja robe na prodajnu lokaciju","Troškovi vlastitog transporta (ne više od tarife javnog prijevoza) dovođenja robe na prodajnu lokaciju" +"6515","kp_rrif6515","kp_rrif651","other","account_type_kratk_imovina",,,"Troškovi oblikovanja za posebne kupce","Troškovi oblikovanja za posebne kupce" +"6516","kp_rrif6516","kp_rrif651","other","account_type_kratk_imovina",,,"Troškovi čuvanja i rukovanja (u fazi nabave)","Troškovi čuvanja i rukovanja (u fazi nabave)" +"6517","kp_rrif6517","kp_rrif651","other","account_type_kratk_imovina",,,"Špediterski i bankarski troškovi","Špediterski i bankarski troškovi" +"6518","kp_rrif6518","kp_rrif651","other","account_type_kratk_imovina",,,"Nadoknada uvozniku za uslugu uvoza","Nadoknada uvozniku za uslugu uvoza" +"6519","kp_rrif6519","kp_rrif651","other","account_type_kratk_imovina",,,"Ostali troškovi kupnje (pregledi, atesti i troškovi u svezi s dovođenjem robe na zalihu -HSFI10 i MRS2)","Ostali troškovi kupnje (pregledi, atesti i dr. troškovi u svezi s dovođenjem robe na zalihu - HSFI 10 i MRS 2)" +"652","kp_rrif652","kp_rrif65","view","account_type_view",,,"Carina i druge uvozne pristojbe za robu","Carina i druge uvozne pristojbe za robu" +"6520","kp_rrif6520","kp_rrif652","other","account_type_kratk_imovina",,,"Carina i druge uvozne pristojbe za robu-a1","Carina i druge uvozne pristojbe za robu-Analitika 1" +"653","kp_rrif653","kp_rrif65","view","account_type_view",,,"Posebni porezi (trošarine)","Posebni porezi (trošarine)" +"6530","kp_rrif6530","kp_rrif653","other","account_type_kratk_imovina",,,"Posebni porezi (trošarine)-a1","Posebni porezi (trošarine)-Analitika 1" +"659","kp_rrif659","kp_rrif65","view","account_type_view",,,"Obračun nabave - trošak kupnje","Obračun nabave - trošak kupnje" +"6590","kp_rrif6590","kp_rrif659","other","account_type_kratk_imovina",,,"Obračun nabave - trošak kupnje-a1","Obračun nabave - trošak kupnje-Analitika 1" +"66","kp_rrif66","kp_rrif6","view","account_type_view",,,"ROBA","ROBA" +"660","kp_rrif660","kp_rrif66","view","account_type_view",,,"Roba u skladištu","Roba u skladištu" +"6600","kp_rrif6600","kp_rrif660","other","account_type_kratk_imovina",,,"Roba u vlastitom veleprodajnom skladištu (analitika po skladištima)","Roba u vlastitom veleprodajnom skladištu (analitika po skladištima)" +"6601","kp_rrif6601","kp_rrif660","other","account_type_kratk_imovina",,,"Zaliha otpadaka od robe","Zaliha otpadaka od robe" +"661","kp_rrif661","kp_rrif66","view","account_type_view",,,"Roba u tuđem skladištu i izlozima","Roba u tuđem skladištu i izlozima" +"6610","kp_rrif6610","kp_rrif661","other","account_type_kratk_imovina",,,"Roba u tuđem skladištu","Roba u tuđem skladištu" +"6611","kp_rrif6611","kp_rrif661","other","account_type_kratk_imovina",,,"Roba u tuđim silosima, hladnjačama i sl.","Roba u tuđim silosima, hladnjačama i sl." +"6612","kp_rrif6612","kp_rrif661","other","account_type_kratk_imovina",,,"Roba u izložbenim prostorima","Roba u izložbenim prostorima" +"662","kp_rrif662","kp_rrif66","view","account_type_view",,,"Roba dana u komisijsku ili konsignacijsku prodaju","Roba dana u komisijsku ili konsignacijsku prodaju" +"6620","kp_rrif6620","kp_rrif662","other","account_type_kratk_imovina",,,"Roba dana u komisijsku ili konsignacijsku prodaju-a1","Roba dana u komisijsku ili konsignacijsku prodaju-Analitika 1" +"663","kp_rrif663","kp_rrif66","view","account_type_view",,,"Roba u prodavaonicama","Roba u prodavaonicama" +"6630","kp_rrif6630","kp_rrif663","view","account_type_view",,,"Roba u prodavaonici (po prodajnoj cijeni -analitika po prodavaonicama), ili","Roba u prodavaonici (po prodajnoj cijeni -analitika po prodavaonicama), ili" +"66300","kp_rrif66300","kp_rrif6630","other","account_type_kratk_imovina",,,"Roba u prodavaonici A s PDV-om 23%","Roba u prodavaonici A s PDV-om 23%" +"66301","kp_rrif66301","kp_rrif6630","other","account_type_kratk_imovina",,,"Roba u prodavaonici A s PDV-om 10%","Roba u prodavaonici A s PDV-om 10%" +"66302","kp_rrif66302","kp_rrif6630","other","account_type_kratk_imovina",,,"Roba u prodavaonici A s PDV-om 0%, itd.","Roba u prodavaonici A s PDV-om 0%, itd." +"664","kp_rrif664","kp_rrif66","view","account_type_view",,,"Uračunani porezi u robi","Uračunani porezi u robi" +"6640","kp_rrif6640","kp_rrif664","other","account_type_kratk_imovina",,,"Uračunani PDV (analitika po prodajnim mjestima i poreznim stopama)","Uračunani PDV (analitika po prodajnim mjestima i poreznim stopama)" +"6641","kp_rrif6641","kp_rrif664","other","account_type_kratk_imovina",,,"Uračunani porez na luksuz","Uračunani porez na luksuz" +"665","kp_rrif665","kp_rrif66","view","account_type_view",,,"Roba u carinskom skladištu ""D"" ili u slobodnoj zoni","Roba u carinskom skladištu ""D"" ili u slobodnoj zoni" +"6650","kp_rrif6650","kp_rrif665","other","account_type_kratk_imovina",,,"Vlastita roba u carinskom skladištu tipa ""D""","Vlastita roba u carinskom skladištu tipa ""D""" +"6651","kp_rrif6651","kp_rrif665","other","account_type_kratk_imovina",,,"Roba u slobodnoj zoni","Roba u slobodnoj zoni" +"666","kp_rrif666","kp_rrif66","view","account_type_view",,,"Roba u doradi, obradi i manipulaciji","Roba u doradi, obradi i manipulaciji" +"6660","kp_rrif6660","kp_rrif666","other","account_type_kratk_imovina",,,"Vrijednost robe u doradi","Vrijednost robe u doradi" +"6661","kp_rrif6661","kp_rrif666","other","account_type_kratk_imovina",,,"Troškovi u svezi s doradom","Troškovi u svezi s doradom" +"667","kp_rrif667","kp_rrif66","view","account_type_view",,,"Roba na putu","Roba na putu" +"6670","kp_rrif6670","kp_rrif667","other","account_type_kratk_imovina",,,"Roba na putu-a1","Roba na putu-Analitika 1" +"668","kp_rrif668","kp_rrif66","view","account_type_view",,,"Uračunana razlika u cijeni robe","Uračunana razlika u cijeni robe" +"6680","kp_rrif6680","kp_rrif668","other","account_type_kratk_imovina",,,"Razlika u cijeni robe na skladištu (analitički po skupinama robe s istom maržom)","Razlika u cijeni robe na skladištu (analitički po skupinama robe s istom maržom)" +"6681","kp_rrif6681","kp_rrif668","other","account_type_kratk_imovina",,,"Uračunana marža robe u prodavaonici","Uračunana marža robe u prodavaonici" +"669","kp_rrif669","kp_rrif66","view","account_type_view",,,"Vrijednosno usklađivanje zaliha robe","Vrijednosno usklađivanje zaliha robe" +"6690","kp_rrif6690","kp_rrif669","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje zbog pada cijena, smanjenja uporabljivosti i sl.","Vrijednosno usklađenje zbog pada cijena, smanjenja uporabljivosti i sl." +"6691","kp_rrif6691","kp_rrif669","other","account_type_kratk_imovina",,,"Prepravljene cijene robe zbog monetarnih oscilacija","Prepravljene cijene robe zbog monetarnih oscilacija" +"67","kp_rrif67","kp_rrif6","view","account_type_view",,,"PREDUJMOVI ZA NABAVU ROBE","PREDUJMOVI ZA NABAVU ROBE" +"670","kp_rrif670","kp_rrif67","view","account_type_view",,,"Dani predujmovi za nabavu robe","Dani predujmovi za nabavu robe" +"6700","kp_rrif6700","kp_rrif670","other","account_type_kratk_imovina",,,"Dani predujmovi za nabavu robe-a1","Dani predujmovi za nabavu robe-Analitika 1" +"671","kp_rrif671","kp_rrif67","view","account_type_view",,,"Dani predujmovi uvozniku za nabavu robe","Dani predujmovi uvozniku za nabavu robe" +"6710","kp_rrif6710","kp_rrif671","other","account_type_kratk_imovina",,,"Dani predujmovi uvozniku za nabavu robe-a1","Dani predujmovi uvozniku za nabavu robe-Analitika 1" +"672","kp_rrif672","kp_rrif67","view","account_type_view",,,"Dani predujmovi za robu povezanom društvu","Dani predujmovi za robu povezanom društvu" +"6720","kp_rrif6720","kp_rrif672","other","account_type_kratk_imovina",,,"Dani predujmovi za robu povezanom društvu-a1","Dani predujmovi za robu povezanom društvu-Analitika 1" +"679","kp_rrif679","kp_rrif67","view","account_type_view",,,"Vrijednosno usklađenje danih predujmova za robu","Vrijednosno usklađenje danih predujmova za robu" +"6790","kp_rrif6790","kp_rrif679","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje danih predujmova za robu-a1","Vrijednosno usklađenje danih predujmova za robu-Analitika 1" +"68","kp_rrif68","kp_rrif6","view","account_type_view",,,"NEKRETNINE I UMJETNINE ZA TRGOVANJE","NEKRETNINE I UMJETNINE ZA TRGOVANJE" +"680","kp_rrif680","kp_rrif68","view","account_type_view",,,"Nabavna vrijednost nekretnina za preprodaju (s porezom na promet)","Nabavna vrijednost nekretnina za preprodaju (s porezom na promet)" +"6800","kp_rrif6800","kp_rrif680","other","account_type_kratk_imovina",,,"Nabavna vrijednost nekretnina za preprodaju (s porezom na promet)-a1","Nabavna vrijednost nekretnina za preprodaju (s porezom na promet)-Analitika 1" +"681","kp_rrif681","kp_rrif68","view","account_type_view",,,"Troškovi dodatnog uređenja - dorade","Troškovi dodatnog uređenja - dorade" +"6810","kp_rrif6810","kp_rrif681","other","account_type_kratk_imovina",,,"Troškovi dodatnog uređenja - dorade-a1","Troškovi dodatnog uređenja - dorade-Analitika 1" +"682","kp_rrif682","kp_rrif68","view","account_type_view",,,"Umjetnine u prodaji","Umjetnine u prodaji" +"6820","kp_rrif6820","kp_rrif682","other","account_type_kratk_imovina",,,"Umjetnine u prodaji-a1","Umjetnine u prodaji-Analitika 1" +"683","kp_rrif683","kp_rrif68","view","account_type_view",,,"Nekretnine za prodaju (uređene)","Nekretnine za prodaju (uređene)" +"6830","kp_rrif6830","kp_rrif683","other","account_type_kratk_imovina",,,"Nekretnine za prodaju (uređene)-a1","Nekretnine za prodaju (uređene)-Analitika 1" +"684","kp_rrif684","kp_rrif68","view","account_type_view",,,"Uračunani PDV u umjetnine","Uračunani PDV u umjetnine" +"6840","kp_rrif6840","kp_rrif684","other","account_type_kratk_imovina",,,"Uračunani PDV u umjetnine-a1","Uračunani PDV u umjetnine-Analitika 1" +"687","kp_rrif687","kp_rrif68","view","account_type_view",,,"Predujmovi za kupnju nekretnina radi daljnje prodaje","Predujmovi za kupnju nekretnina radi daljnje prodaje" +"6870","kp_rrif6870","kp_rrif687","other","account_type_kratk_imovina",,,"Predujmovi za kupnju nekretnina radi daljnje prodaje-a1","Predujmovi za kupnju nekretnina radi daljnje prodaje-Analitika 1" +"688","kp_rrif688","kp_rrif68","view","account_type_view",,,"Uračunana razlika u cijeni nekretnina i umjetnina za daljnju prodaju","Uračunana razlika u cijeni nekretnina i umjetnina za daljnju prodaju" +"6880","kp_rrif6880","kp_rrif688","other","account_type_kratk_imovina",,,"Uračunana razlika u cijeni nekretnina i umjetnina za daljnju prodaju-a1","Uračunana razlika u cijeni nekretnina i umjetnina za daljnju prodaju-Analitika 1" +"689","kp_rrif689","kp_rrif68","view","account_type_view",,,"Vrijednosno usklađivanje nekretnina i umjetnina u prometu i predujmova","Vrijednosno usklađivanje nekretnina i umjetnina u prometu i predujmova" +"6890","kp_rrif6890","kp_rrif689","other","account_type_kratk_imovina",,,"Vrijednosno usklađivanje nekretnina i umjetnina u prometu i predujmova-a1","Vrijednosno usklađivanje nekretnina i umjetnina u prometu i predujmova-Analitika 1" +"69","kp_rrif69","kp_rrif6","view","account_type_view",,,"DUGOTRAJNA IMOVINA NAMIJENJENA PRODAJI","DUGOTRAJNA IMOVINA NAMIJENJENA PRODAJI" +"690","kp_rrif690","kp_rrif69","view","account_type_view",,,"Nematerijalna imovina namijenjena prodaji","Nematerijalna imovina namijenjena prodaji" +"6900","kp_rrif6900","kp_rrif690","other","account_type_kratk_imovina",,,"Nematerijalna imovina namijenjena prodaji-a1","Nematerijalna imovina namijenjena prodaji-Analitika 1" +"691","kp_rrif691","kp_rrif69","view","account_type_view",,,"Materijalna imovina namijenjena za prodaju","Materijalna imovina namijenjena za prodaju" +"6910","kp_rrif6910","kp_rrif691","other","account_type_kratk_imovina",,,"Skupina imovine za prodaju (npr. pogon, poslov. jedinica i sl. )","Skupina imovine za prodaju (npr. pogon, poslov. jedinica i sl. )" +"699","kp_rrif699","kp_rrif69","view","account_type_view",,,"Vrijednosno usklađenje dugotrajne imovine namijenjena prodaji","Vrijednosno usklađenje dugotrajne imovine namijenjena prodaji" +"6990","kp_rrif6990","kp_rrif699","other","account_type_kratk_imovina",,,"Vrijednosno usklađenje dugotrajne imovine namijenjena prodaji-a1","Vrijednosno usklađenje dugotrajne imovine namijenjena prodaji-Analitika 1" +"7","kp_rrif7","kp_rrif","view","account_type_view",,,"POKRIĆE RASHODA I PRIHODI RAZDOBLJA","POKRIĆE RASHODA I PRIHODI RAZDOBLJA" +"70","kp_rrif70","kp_rrif7","view","account_type_view",,,"TROŠKOVI PRODANIH ZALIHA PROIZVODA I USLUGA","TROŠKOVI PRODANIH ZALIHA PROIZVODA I USLUGA" +"700","kp_rrif700","kp_rrif70","view","account_type_view",,,"Trošak zaliha prodanih proizvoda (60, 62, 63 i 64)","Trošak zaliha prodanih proizvoda (60, 62, 63 i 64)" +"7000","kp_rrif7000","kp_rrif700","other","account_type_posl_rashod",,,"Trošak zaliha prodanih proizvoda (60, 62, 63 i 64)-a1","Trošak zaliha prodanih proizvoda (60, 62, 63 i 64)-Analitika 1" +"701","kp_rrif701","kp_rrif70","view","account_type_view",,,"Troškovi realiziranih usluga (490 i 601)","Troškovi realiziranih usluga (490 i 601)" +"7010","kp_rrif7010","kp_rrif701","other","account_type_posl_rashod",,,"Troškovi realiziranih usluga (490 i 601)-a1","Troškovi realiziranih usluga (490 i 601)-Analitika 1" +"702","kp_rrif702","kp_rrif70","view","account_type_view",,,"Troškovi neiskorištenog kapaciteta (HSFI t. 10.18. i MRS 2 t. 13)","Troškovi neiskorištenog kapaciteta (HSFI t. 10.18. i MRS 2 t. 13)" +"7020","kp_rrif7020","kp_rrif702","other","account_type_posl_rashod",,,"Troškovi neiskorištenog kapaciteta (HSFI t. 10.18. i MRS 2 t. 13)-a1","Troškovi neiskorištenog kapaciteta (HSFI t. 10.18. i MRS 2 t. 13)-Analitika 1" +"703","kp_rrif703","kp_rrif70","view","account_type_view",,,"Troškovi prodanih zaliha materijala i otpadaka (31, 32, 35 i 36)","Troškovi prodanih zaliha materijala i otpadaka (31, 32, 35 i 36)" +"7030","kp_rrif7030","kp_rrif703","other","account_type_posl_rashod",,,"Troškovi nabavne vrijednosti materijala, dijelova, inventara i otpadaka","Troškovi nabavne vrijednosti materijala, dijelova, inventara i otpadaka" +"7031","kp_rrif7031","kp_rrif703","other","account_type_posl_rashod",,,"Troškovi manjkova materijala, dijelova i inventara kojom se tereti odgovorna osoba","Troškovi manjkova materijala, dijelova i inventara kojom se tereti odgovorna osoba" +"704","kp_rrif704","kp_rrif70","view","account_type_view",,,"Rashodi zaliha proizvodnje (HSFI 10 i MRS 2)","Rashodi zaliha proizvodnje (HSFI 10 i MRS 2)" +"7040","kp_rrif7040","kp_rrif704","other","account_type_posl_rashod",,,"Dopušteni manjkovi -porezno priznati- tehnološki KRL i škart u proizvodnji (sa skupina 60, 62, 63 i 64)","Dopušteni manjkovi - tehnološki kalo, rastep, kvar i lom i škart u proizvodnji (sa skupina 60, 62, 63 i 64) - porezno priznati" +"7041","kp_rrif7041","kp_rrif704","other","account_type_posl_rashod",,,"Prekomjerni manjkovi-porezno priznati teh.KRL i škart u proiz.(60,62,63i64 -HSFI t10.21. i MRS2,t14)","Prekomjerni manjkovi - tehnološki kalo, rastep, kvar, lom i škart u proizvodnji (60, 62, 63 i 64 - HSFI t. 10.21. i MRS 2, t. 14.) a porezno dopušteni po očevidu i sl. - porezno priznati" +"7042","kp_rrif7042","kp_rrif704","other","account_type_posl_rashod",,,"Prekomjerni manjkovi proizvoda (HSFI t. 10.2. i MRS 2, t. 16.) - porezno nepriznati","Prekomjerni manjkovi proizvoda (HSFI t. 10.2. i MRS 2, t. 16.) - porezno nepriznati" +"7043","kp_rrif7043","kp_rrif704","other","account_type_posl_rashod",,,"Razlika višeg troška proizvodnje od neto-vrij. koja se može realizirati (HSFIt.10.35. i MRS2t.28.-33.)","Razlika višeg troška proizvodnje od neto-vrijednosti koja se može realizirati (HSFI t. 10.35. i MRS 2, t. 28. do 33.)" +"7044","kp_rrif7044","kp_rrif704","other","account_type_posl_rashod",,,"Troškovi isporučenih proizvoda u jamstvenom roku (zamjena)","Troškovi isporučenih proizvoda u jamstvenom roku (zamjena)" +"705","kp_rrif705","kp_rrif70","view","account_type_view",,,"Greškom neiskazani rashodi proteklih razdoblja","Greškom neiskazani rashodi proteklih razdoblja" +"7050","kp_rrif7050","kp_rrif705","other","account_type_posl_rashod",,,"Greškom neiskazani rashodi proteklih razdoblja-a1","Greškom neiskazani rashodi proteklih razdoblja-Analitika 1" +"706","kp_rrif706","kp_rrif70","view","account_type_view",,,"Gubitci iz ugovora o izgradnj (MRS 11, t. 36.)","Gubitci iz ugovora o izgradnj (MRS 11, t. 36.)" +"7060","kp_rrif7060","kp_rrif706","other","account_type_posl_rashod",,,"Gubitci iz ugovora o izgradnj (MRS 11, t. 36.)-a1","Gubitci iz ugovora o izgradnj (MRS 11, t. 36.)-Analitika 1" +"707","kp_rrif707","kp_rrif70","view","account_type_view",,,"Troškovi iz ugovora o ortaštvu","Troškovi iz ugovora o ortaštvu" +"7070","kp_rrif7070","kp_rrif707","other","account_type_posl_rashod",,,"Troškovi iz ugovora o ortaštvu-a1","Troškovi iz ugovora o ortaštvu-Analitika 1" +"708","kp_rrif708","kp_rrif70","view","account_type_view",,,"Troškovi vrijed. uskl. proizvod. u tijeku(609), poluproizvoda(629) i zaliha got. proizvoda (639 i 649)","Troškovi vrijednosnog usklađenja proizvodnje u tijeku (609), poluproizvoda (629) i zaliha gotovih proizvoda (639 i 649)" +"7080","kp_rrif7080","kp_rrif708","other","account_type_posl_rashod",,,"Troškovi vrijed. uskl. proizvod. u tijeku(609), poluproizvoda(629) i zaliha got. proizvoda (639 i 649)-a1","Troškovi vrijednosnog usklađenja proizvodnje u tijeku (609), poluproizvoda (629) i zaliha gotovih proizvoda (639 i 649)-Analitika 1" +"71","kp_rrif71","kp_rrif7","view","account_type_view",,,"TROŠKOVI PRODANE ROBE","TROŠKOVI PRODANE ROBE" +"710","kp_rrif710","kp_rrif71","view","account_type_view",,,"Nabavna vrijednost prodane robe","Nabavna vrijednost prodane robe" +"7100","kp_rrif7100","kp_rrif710","other","account_type_posl_rashod",,,"Trošak prodane robe u tuzemstvu","Trošak prodane robe u tuzemstvu" +"7101","kp_rrif7101","kp_rrif710","other","account_type_posl_rashod",,,"Trošak prodane robe u inozemstvu","Trošak prodane robe u inozemstvu" +"7102","kp_rrif7102","kp_rrif710","other","account_type_posl_rashod",,,"Troškovi prodane robe u tranzitu","Troškovi prodane robe u tranzitu" +"7103","kp_rrif7103","kp_rrif710","other","account_type_posl_rashod",,,"Trošak prodane robe u poslov. jed.","Trošak prodane robe u poslov. jed." +"711","kp_rrif711","kp_rrif71","view","account_type_view",,,"Nabavna vrijednost prodanih nekretnina i umjetnina","Nabavna vrijednost prodanih nekretnina i umjetnina" +"7110","kp_rrif7110","kp_rrif711","other","account_type_posl_rashod",,,"Nabavna vrijednost prodanih nekretnina i umjetnina-a1","Nabavna vrijednost prodanih nekretnina i umjetnina-Analitika 1" +"712","kp_rrif712","kp_rrif71","view","account_type_view",,,"Troškovi dugotr. imov. namijenjeni prodaji","Troškovi dugotr. imov. namijenjeni prodaji" +"7120","kp_rrif7120","kp_rrif712","other","account_type_posl_rashod",,,"Troškovi dugotr. imov. namijenjeni prodaji-a1","Troškovi dugotr. imov. namijenjeni prodaji-Analitika 1" +"713","kp_rrif713","kp_rrif71","view","account_type_view",,,"Troškovi kala, rastepa, kvara i loma na robi i otpisi robe","Troškovi kala, rastepa, kvara i loma na robi i otpisi robe" +"7130","kp_rrif7130","kp_rrif713","other","account_type_posl_rashod",,,"Kalo, rastep, kvar i lom u dopuštenoj visini prema Pravilniku HGK - porezno priznati","Kalo, rastep, kvar i lom u dopuštenoj visini prema Pravilniku HGK - porezno priznati" +"7131","kp_rrif7131","kp_rrif713","other","account_type_posl_rashod",,,"Manjkovi uslijed više sile (provalne krađe, poplava, požar, potres i sl.) - porezno priznati","Manjkovi uslijed više sile (provalne krađe, poplava, požar, potres i sl.) - porezno priznati" +"7132","kp_rrif7132","kp_rrif713","other","account_type_posl_rashod",,,"Manjkovi i otpisi trgovačke robe po očevidu PU i sl. - porezno priznati","Manjkovi i otpisi trgovačke robe po očevidu PU i sl. - porezno priznati" +"7133","kp_rrif7133","kp_rrif713","other","account_type_posl_rashod",,,"Prekomjerni kalo, rastep, kvar i lom + PDV - porezno nepriznati","Prekomjerni kalo, rastep, kvar i lom + PDV - porezno nepriznati" +"7134","kp_rrif7134","kp_rrif713","other","account_type_posl_rashod",,,"Manjak robe na teret odgovorne osobe","Manjak robe na teret odgovorne osobe" +"714","kp_rrif714","kp_rrif71","view","account_type_view",,,"Troškovi zamjene robe u jamstvenom roku","Troškovi zamjene robe u jamstvenom roku" +"7140","kp_rrif7140","kp_rrif714","other","account_type_posl_rashod",,,"Troškovi zamjene robe u jamstvenom roku-a1","Troškovi zamjene robe u jamstvenom roku-Analitika 1" +"715","kp_rrif715","kp_rrif71","view","account_type_view",,,"Greškom neiskazani rashodi prodane robe u proteklim razdobljima u trgovini","Greškom neiskazani rashodi prodane robe u proteklim razdobljima u trgovini" +"7150","kp_rrif7150","kp_rrif715","other","account_type_posl_rashod",,,"Greškom neiskazani rashodi prodane robe u proteklim razdobljima u trgovini-a1","Greškom neiskazani rashodi prodane robe u proteklim razdobljima u trgovini-Analitika 1" +"718","kp_rrif718","kp_rrif71","view","account_type_view",,,"Troškovi vrijednosnog usklađenja trgovačke robe i predujmova (669, 679, 689)","Troškovi vrijednosnog usklađenja trgovačke robe i predujmova (669, 679, 689)" +"7180","kp_rrif7180","kp_rrif718","other","account_type_posl_rashod",,,"Troškovi vrijednosnog usklađenja trgovačke robe i predujmova (669, 679, 689)-a1","Troškovi vrijednosnog usklađenja trgovačke robe i predujmova (669, 679, 689)-Analitika 1" +"719","kp_rrif719","kp_rrif71","view","account_type_view",,,"Troškovi vrijednosnog usklađenja dugotrajne imovine namijenjene prodaji (699)","Troškovi vrijednosnog usklađenja dugotrajne imovine namijenjene prodaji (699)" +"7190","kp_rrif7190","kp_rrif719","other","account_type_posl_rashod",,,"Troškovi vrijednosnog usklađenja dugotrajne imovine namijenjene prodaji (699)-a1","Troškovi vrijednosnog usklađenja dugotrajne imovine namijenjene prodaji (699)-Analitika 1" +"72","kp_rrif72","kp_rrif7","view","account_type_view",,,"TROŠKOVI ADMINISTRACIJE I OSTALI RASHODI","TROŠKOVI ADMINISTRACIJE I OSTALI RASHODI" +"720","kp_rrif720","kp_rrif72","view","account_type_view",,,"Troškovi uprave, prodaje, administracije (491)","Troškovi uprave, prodaje, administracije (491)" +"7200","kp_rrif7200","kp_rrif720","other","account_type_posl_rashod",,,"Troškovi uprave, prodaje, administracije (491)-a1","Troškovi uprave, prodaje, administracije (491)-Analitika 1" +"721","kp_rrif721","kp_rrif72","view","account_type_view",,,"Ostali poslovni rashodi - nespomenuti","Ostali poslovni rashodi - nespomenuti" +"7210","kp_rrif7210","kp_rrif721","other","account_type_posl_rashod",,,"Ostali poslovni rashodi - nespomenuti-a1","Ostali poslovni rashodi - nespomenuti-Analitika 1" +"73","kp_rrif73","kp_rrif7","view","account_type_view",,,"IZVANREDNI - OSTALI RASHODI","IZVANREDNI - OSTALI RASHODI" +"730","kp_rrif730","kp_rrif73","view","account_type_view",,,"Izvanredni rashodi od prodaje dugotrajne imovine (HSFI t. 8.35.)","Izvanredni rashodi od prodaje dugotrajne imovine (HSFI t. 8.35.)" +"7300","kp_rrif7300","kp_rrif730","other","account_type_posl_rashod",,,"Izvanredni rashodi od prodaje dugotrajne imovine (HSFI t. 8.35.)-a1","Izvanredni rashodi od prodaje dugotrajne imovine (HSFI t. 8.35.)-Analitika 1" +"731","kp_rrif731","kp_rrif73","view","account_type_view",,,"Izvanredni otpisi od otuđenja imovine, nastali neočekivano i u visokoj vrijednosti (HSFt4.7. i MRS10t9)","Izvanredni otpisi od otuđenja imovine koji su nastali neočekivano i u visokoj vrijednosti (HSFI t. 4.7. i MRS 10. t. 9.)" +"7310","kp_rrif7310","kp_rrif731","other","account_type_posl_rashod",,,"Izvanredni otpisi od otuđenja imovine, nastali neočekivano i u visokoj vrijednosti (HSFt4.7. i MRS10t9)-a1","Izvanredni otpisi od otuđenja imovine koji su nastali neočekivano i u visokoj vrijednosti (HSFI t. 4.7. i MRS 10. t. 9.)-Analitika 1" +"732","kp_rrif732","kp_rrif73","view","account_type_view",,,"Gubitci zbog izvlaštenja ili zbog prirodnih katastrofa na važnom dijelu imovine","Gubitci zbog izvlaštenja ili zbog prirodnih katastrofa na važnom dijelu imovine" +"7320","kp_rrif7320","kp_rrif732","other","account_type_posl_rashod",,,"Gubitci zbog izvlaštenja ili zbog prirodnih katastrofa na važnom dijelu imovine-a1","Gubitci zbog izvlaštenja ili zbog prirodnih katastrofa na važnom dijelu imovine-Analitika 1" +"733","kp_rrif733","kp_rrif73","view","account_type_view",,,"Izvanredni rashodi iz ostalih rijetkih i neobičnih događaja ili transakcija","Izvanredni rashodi iz ostalih rijetkih i neobičnih događaja ili transakcija" +"7330","kp_rrif7330","kp_rrif733","other","account_type_posl_rashod",,,"Izvanredni rashodi iz ostalih rijetkih i neobičnih događaja ili transakcija-a1","Izvanredni rashodi iz ostalih rijetkih i neobičnih događaja ili transakcija-Analitika 1" +"734","kp_rrif734","kp_rrif73","view","account_type_view",,,"Izvanredne kazne, penali, odštete, naknadno utvrđ. obveze i sl.","Izvanredne kazne, penali, odštete, naknadno utvrđ. obveze i sl." +"7340","kp_rrif7340","kp_rrif734","other","account_type_posl_rashod",,,"Izvanredne kazne, penali, odštete, naknadno utvrđ. obveze i sl.-a1","Izvanredne kazne, penali, odštete, naknadno utvrđ. obveze i sl.-Analitika 1" +"735","kp_rrif735","kp_rrif73","view","account_type_view",,,"Nerealizirani gubitci","Nerealizirani gubitci" +"7350","kp_rrif7350","kp_rrif735","other","account_type_posl_rashod",,,"Nerealizirani gubitci-a1","Nerealizirani gubitci-Analitika 1" +"737","kp_rrif737","kp_rrif73","view","account_type_view",,,"Gubitci od procjene biološke imovine","Gubitci od procjene biološke imovine" +"7370","kp_rrif7370","kp_rrif737","other","account_type_posl_rashod",,,"Gubitci od procjene biološke imovine-a1","Gubitci od procjene biološke imovine-Analitika 1" +"74","kp_rrif74","kp_rrif7","view","account_type_view",,,"UDIO U GUBITKU I DOBITKU PRIDRUŽENIH PODUZETNIKA","UDIO U GUBITKU I DOBITKU PRIDRUŽENIH PODUZETNIKA" +"740","kp_rrif740","kp_rrif74","view","account_type_view",,,"Udio u gubitku pridruženih poduzetnika","Udio u gubitku pridruženih poduzetnika" +"7400","kp_rrif7400","kp_rrif740","other","account_type_posl_rashod",,,"Udio u gubitku povezanih društava","Udio u gubitku povezanih društava" +"7401","kp_rrif7401","kp_rrif740","other","account_type_posl_rashod",,,"Udio u gubitku ortaka","Udio u gubitku ortaka" +"745","kp_rrif745","kp_rrif74","view","account_type_view",,,"Udio u dobitku od pridruženih poduzetnika","Udio u dobitku od pridruženih poduzetnika" +"7450","kp_rrif7450","kp_rrif745","other","account_type_posl_prihod",,,"Udio u dobitku povezanih društava","Udio u dobitku povezanih društava" +"7451","kp_rrif7451","kp_rrif745","other","account_type_posl_prihod",,,"Udio u dobitku ortaštva","Udio u dobitku ortaštva" +"75","kp_rrif75","kp_rrif7","view","account_type_view",,,"PRIHODI OD PRODAJE PROIZVODA I USLUGA","PRIHODI OD PRODAJE PROIZVODA I USLUGA" +"750","kp_rrif750","kp_rrif75","view","account_type_view",,,"Prihodi od prodaje proizvoda (analitika po proizvodima ili profitnim centrima)","Prihodi od prodaje proizvoda (analitika po proizvodima ili profitnim centrima)" +"7500","kp_rrif7500","kp_rrif750","other","account_type_posl_prihod",,,"Prihodi od prodaje proizvoda od redovne prodaje","Prihodi od prodaje proizvoda od redovne prodaje" +"7501","kp_rrif7501","kp_rrif750","other","account_type_posl_prihod",,,"Prihodi od prodaje proizvoda na kredit ili otplatu","Prihodi od prodaje proizvoda na kredit ili otplatu" +"7502","kp_rrif7502","kp_rrif750","other","account_type_posl_prihod",,,"Prihodi ostvareni u slobodnoj zoni","Prihodi ostvareni u slobodnoj zoni" +"7503","kp_rrif7503","kp_rrif750","other","account_type_posl_prihod",,,"Prodaja u vlastitim prodavaonicama","Prodaja u vlastitim prodavaonicama" +"7504","kp_rrif7504","kp_rrif750","other","account_type_posl_prihod",,,"Prihodi od prodaje stanova i dr. građevina","Prihodi od prodaje stanova i dr. građevina" +"7505","kp_rrif7505","kp_rrif750","other","account_type_posl_prihod",,,"Prihodi od prodaje poluproizvoda i nedovršenih proizvoda","Prihodi od prodaje poluproizvoda i nedovršenih proizvoda" +"7506","kp_rrif7506","kp_rrif750","other","account_type_posl_prihod",,,"Prihodi ostvareni u posl. jed. na području posebne držav. skrbi i u Vukovaru","Prihodi ostvareni u posl. jed. na području posebne držav. skrbi i u Vukovaru" +"7507","kp_rrif7507","kp_rrif750","other","account_type_posl_prihod",,,"Prihod od povratne naknade za ambalažu (bez PDV-a)","Prihod od povratne naknade za ambalažu (bez PDV-a)" +"7508","kp_rrif7508","kp_rrif750","other","account_type_posl_prihod",,,"Prihod od prodaje otpadaka iz proizvodnje","Prihod od prodaje otpadaka iz proizvodnje" +"7509","kp_rrif7509","kp_rrif750","other","account_type_posl_prihod",,,"Prihodi od prodaje poluproizvoda i nedovršenih proizvoda","Prihodi od prodaje poluproizvoda i nedovršenih proizvoda" +"751","kp_rrif751","kp_rrif75","view","account_type_view",,,"Prihodi od prodaje usluga","Prihodi od prodaje usluga" +"7510","kp_rrif7510","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od servisnih usluga, usluga popravaka i sl. usluga","Prihodi od servisnih usluga, usluga popravaka i sl. usluga" +"7511","kp_rrif7511","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od restorana i gostionica","Prihodi od restorana i gostionica" +"7512","kp_rrif7512","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od hotela i noćenja","Prihodi od hotela i noćenja" +"7513","kp_rrif7513","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od knjigovodstvenih, usluga poreznog savjetovanja, revizorskih, konzultantskih i dr. usluga","Prihodi od knjigovodstvenih, usluga poreznog savjetovanja, revizorskih, konzultantskih i dr. usluga" +"7514","kp_rrif7514","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od usluga prijevoza","Prihodi od usluga prijevoza" +"7515","kp_rrif7515","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od komunalnih usluga","Prihodi od komunalnih usluga" +"7516","kp_rrif7516","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od promidžbenih usluga","Prihodi od promidžbenih usluga" +"7517","kp_rrif7517","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od usluga zaštite i istraživanja","Prihodi od usluga zaštite i istraživanja" +"7518","kp_rrif7518","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od programskih usluga","Prihodi od programskih usluga" +"7519","kp_rrif7519","kp_rrif751","other","account_type_posl_prihod",,,"Prihodi od prodaje ostalih usluga","Prihodi od prodaje ostalih usluga" +"752","kp_rrif752","kp_rrif75","view","account_type_view",,,"Prihodi od graditeljskih usluga - iz ugovora o izgradnji (građevina, postrojenja, brodova i sl.)","Prihodi od graditeljskih usluga - iz ugovora o izgradnji (građevina, postrojenja, brodova i sl.)" +"7520","kp_rrif7520","kp_rrif752","other","account_type_posl_prihod",,,"Prihodi od graditeljskih usluga - iz ugovora o izgradnji (građevina, postrojenja, brodova i sl.)-a1","Prihodi od graditeljskih usluga - iz ugovora o izgradnji (građevina, postrojenja, brodova i sl.)-Analitika 1" +"753","kp_rrif753","kp_rrif75","view","account_type_view",,,"Prihodi od prodaje dobara u inozemstvo (moguća analitika po vrstama proizvoda i zemljama)","Prihodi od prodaje dobara u inozemstvo (moguća analitika po vrstama proizvoda i zemljama)" +"7530","kp_rrif7530","kp_rrif753","other","account_type_posl_prihod",,,"Prihodi od prodaje dobara u inozemstvo (moguća analitika po vrstama proizvoda i zemljama)-a1","Prihodi od prodaje dobara u inozemstvo (moguća analitika po vrstama proizvoda i zemljama)-Analitika 1" +"754","kp_rrif754","kp_rrif75","view","account_type_view",,,"Prihodi od prodaje usluga u inozemstvo (moguća analitika po vrstama usluga i zemljama kupcima)","Prihodi od prodaje usluga u inozemstvo (moguća analitika po vrstama usluga i zemljama kupcima)" +"7540","kp_rrif7540","kp_rrif754","other","account_type_posl_prihod",,,"Prihodi iz međunarodne plovidbe brodovima (čl. 26., st. 10. ZoPD)","Prihodi iz međunarodne plovidbe brodovima (čl. 26., st. 10. ZoPD)" +"7541","kp_rrif7541","kp_rrif754","other","account_type_posl_prihod",,,"Prihodi od internetskih usluga za inozemstvo","Prihodi od internetskih usluga za inozemstvo" +"7542","kp_rrif7542","kp_rrif754","other","account_type_posl_prihod",,,"Prihodi od poslovnih jedinica u inozemstvu","Prihodi od poslovnih jedinica u inozemstvu" +"7543","kp_rrif7543","kp_rrif754","other","account_type_posl_prihod",,,"Prihodi od prodaje turističkih usluga u inozem.","Prihodi od prodaje turističkih usluga u inozem." +"755","kp_rrif755","kp_rrif75","view","account_type_view",,,"Prihodi od prodaje proizvoda i usluga poduzet. u kojima postoje sudjelujući interesi (do 20% udjela)","Prihodi od prodaje proizvoda i usluga poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)" +"7550","kp_rrif7550","kp_rrif755","other","account_type_posl_prihod",,,"Prihodi od prodaje proizvoda i usluga poduzet. u kojima postoje sudjelujući interesi (do 20% udjela)-a1","Prihodi od prodaje proizvoda i usluga poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)-Analitika 1" +"756","kp_rrif756","kp_rrif75","view","account_type_view",,,"Prihodi od prodaje proizvoda i usluga ovisnim društvima (analitika po društvima)","Prihodi od prodaje proizvoda i usluga ovisnim društvima (analitika po društvima)" +"7560","kp_rrif7560","kp_rrif756","other","account_type_posl_prihod",,,"Prihodi od prodaje proizvoda i usluga ovisnim društvima (analitika po društvima)-a1","Prihodi od prodaje proizvoda i usluga ovisnim društvima (analitika po društvima)-Analitika 1" +"757","kp_rrif757","kp_rrif75","view","account_type_view",,,"Prihodi od najmova i zakupa","Prihodi od najmova i zakupa" +"7570","kp_rrif7570","kp_rrif757","other","account_type_posl_prihod",,,"Prihodi od najmova i zakupa-a1","Prihodi od najmova i zakupa-Analitika 1" +"758","kp_rrif758","kp_rrif75","view","account_type_view",,,"Prihodi iz ortaštva","Prihodi iz ortaštva" +"7580","kp_rrif7580","kp_rrif758","other","account_type_posl_prihod",,,"Prihodi iz ortaštva-a1","Prihodi iz ortaštva-Analitika 1" +"759","kp_rrif759","kp_rrif75","view","account_type_view",,,"Ostali prihodi od prodaje učinaka","Ostali prihodi od prodaje učinaka" +"7590","kp_rrif7590","kp_rrif759","other","account_type_posl_prihod",,,"Ostali prihodi od prodaje učinaka-a1","Ostali prihodi od prodaje učinaka-Analitika 1" +"76","kp_rrif76","kp_rrif7","view","account_type_view",,,"PRIHODI OD PRODAJE TRGOVAČKE ROBE","PRIHODI OD PRODAJE TRGOVAČKE ROBE" +"760","kp_rrif760","kp_rrif76","view","account_type_view",,,"Prihodi od prodaje robe","Prihodi od prodaje robe" +"7600","kp_rrif7600","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prodaje robe na veliko (analitika po prodajnim mjestima)","Prihodi od prodaje robe na veliko (analitika po prodajnim mjestima)" +"7601","kp_rrif7601","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prodaje uvezene robe na veliko","Prihodi od prodaje uvezene robe na veliko" +"7602","kp_rrif7602","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prodaje robe u tranzitu","Prihodi od prodaje robe u tranzitu" +"7603","kp_rrif7603","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prodaje robe na malo (analitika po prodav.)","Prihodi od prodaje robe na malo (analitika po prodav.)" +"7604","kp_rrif7604","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prodaje robe u povezanim društvima","Prihodi od prodaje robe u povezanim društvima" +"7605","kp_rrif7605","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prodaje robe dane u komisiju ili konsignaciju","Prihodi od prodaje robe dane u komisiju ili konsignaciju" +"7606","kp_rrif7606","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prodaje u poslov. jed. na području posebne držav. skrbi i Vukovaru","Prihodi od prodaje u poslov. jed. na području posebne držav. skrbi i Vukovaru" +"7607","kp_rrif7607","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od povratne naknade za ambalažu (bez PDV-a)","Prihodi od povratne naknade za ambalažu (bez PDV-a)" +"7608","kp_rrif7608","kp_rrif760","other","account_type_posl_prihod",,,"Prihodi od prometa nekretnina","Prihodi od prometa nekretnina" +"761","kp_rrif761","kp_rrif76","view","account_type_view",,,"Prihodi od prodaje robe na inozemnom tržištu","Prihodi od prodaje robe na inozemnom tržištu" +"7610","kp_rrif7610","kp_rrif761","other","account_type_posl_prihod",,,"Prihodi od prodaje robe na inozemnom tržištu-a1","Prihodi od prodaje robe na inozemnom tržištu-Analitika 1" +"762","kp_rrif762","kp_rrif76","view","account_type_view",,,"Prihodi od trgovačkih usluga","Prihodi od trgovačkih usluga" +"7620","kp_rrif7620","kp_rrif762","other","account_type_posl_prihod",,,"Prihodi od provizija","Prihodi od provizija" +"7621","kp_rrif7621","kp_rrif762","other","account_type_posl_prihod",,,"Prihodi od franšiza i robnih znakova","Prihodi od franšiza i robnih znakova" +"7622","kp_rrif7622","kp_rrif762","other","account_type_posl_prihod",,,"Prihodi od usluge posredovanja","Prihodi od usluge posredovanja" +"7623","kp_rrif7623","kp_rrif762","other","account_type_posl_prihod",,,"Prihodi od davanja mišljenja","Prihodi od davanja mišljenja" +"763","kp_rrif763","kp_rrif76","view","account_type_view",,,"Prihodi od prodaje nekurentne robe (robe u kvaru, ošte-ćenju, demodirana i sl.)","Prihodi od prodaje nekurentne robe (robe u kvaru, ošte-ćenju, demodirana i sl.)" +"7630","kp_rrif7630","kp_rrif763","other","account_type_posl_prihod",,,"Prihodi od prodaje nekurentne robe (robe u kvaru, ošte-ćenju, demodirana i sl.)-a1","Prihodi od prodaje nekurentne robe (robe u kvaru, ošte-ćenju, demodirana i sl.)-Analitika 1" +"764","kp_rrif764","kp_rrif76","view","account_type_view",,,"Prihodi od prodaje robe na kredit","Prihodi od prodaje robe na kredit" +"7640","kp_rrif7640","kp_rrif764","other","account_type_posl_prihod",,,"Prihodi od prodaje robe na robni kredit","Prihodi od prodaje robe na robni kredit" +"7641","kp_rrif7641","kp_rrif764","other","account_type_posl_prihod",,,"Prihodi od prodaje robe na potrošački kredit","Prihodi od prodaje robe na potrošački kredit" +"765","kp_rrif765","kp_rrif76","view","account_type_view",,,"Prihodi od prodaje robe poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)","Prihodi od prodaje robe poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)" +"7650","kp_rrif7650","kp_rrif765","other","account_type_posl_prihod",,,"Prihodi od prodaje robe poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)-a1","Prihodi od prodaje robe poduzetnicima u kojima postoje sudjelujući interesi (do 20% udjela)-Analitika 1" +"766","kp_rrif766","kp_rrif76","view","account_type_view",,,"Prihodi od prodaje robe ovisnim društvima","Prihodi od prodaje robe ovisnim društvima" +"7660","kp_rrif7660","kp_rrif766","other","account_type_posl_prihod",,,"Prihodi od prodaje robe ovisnim društvima-a1","Prihodi od prodaje robe ovisnim društvima-Analitika 1" +"767","kp_rrif767","kp_rrif76","view","account_type_view",,,"Prihodi od dane (prodane) robe u financijski lizing (najam)","Prihodi od dane (prodane) robe u financijski lizing (najam)" +"7670","kp_rrif7670","kp_rrif767","other","account_type_posl_prihod",,,"Prihodi od dane (prodane) robe u financijski lizing (najam)-a1","Prihodi od dane (prodane) robe u financijski lizing (najam)-Analitika 1" +"768","kp_rrif768","kp_rrif76","view","account_type_view",,,"Prihodi od preprodaje nekretnina i umjetnina","Prihodi od preprodaje nekretnina i umjetnina" +"7680","kp_rrif7680","kp_rrif768","other","account_type_posl_prihod",,,"Prihodi od preprodaje nekretnina i umjetnina-a1","Prihodi od preprodaje nekretnina i umjetnina-Analitika 1" +"769","kp_rrif769","kp_rrif76","view","account_type_view",,,"Ostali prihodi od prodaje roba i trgovačkih usluga","Ostali prihodi od prodaje roba i trgovačkih usluga" +"7690","kp_rrif7690","kp_rrif769","other","account_type_posl_prihod",,,"Prihodi od prikupljanja ambalaže","Prihodi od prikupljanja ambalaže" +"7691","kp_rrif7691","kp_rrif769","other","account_type_posl_prihod",,,"Prihodi od zbrinjavanja otpada","Prihodi od zbrinjavanja otpada" +"7692","kp_rrif7692","kp_rrif769","other","account_type_posl_prihod",,,"Prihodi od prodaje korisnog otpada","Prihodi od prodaje korisnog otpada" +"77","kp_rrif77","kp_rrif7","view","account_type_view",,,"FINANCIJSKI PRIHODI","FINANCIJSKI PRIHODI" +"770","kp_rrif770","kp_rrif77","view","account_type_view",,,"Kamate, tečajne razlike, dividende i sl. prihodi iz odnosa s povezanim poduzetnicima","Kamate, tečajne razlike, dividende i sl. prihodi iz odnosa s povezanim poduzetnicima" +"7700","kp_rrif7700","kp_rrif770","other","account_type_posl_prihod",,,"Prihodi od kamata od povezanih poduzetnika","Prihodi od kamata od povezanih poduzetnika" +"7701","kp_rrif7701","kp_rrif770","other","account_type_posl_prihod",,,"Prihodi od tečajnih razlika od povez. poduzet.","Prihodi od tečajnih razlika od povez. poduzet." +"7702","kp_rrif7702","kp_rrif770","other","account_type_posl_prihod",,,"Prihodi od dividende (dobitka) iz udjela u povezanim poduzetnicima","Prihodi od dividende (dobitka) iz udjela u povezanim poduzetnicima" +"7703","kp_rrif7703","kp_rrif770","other","account_type_posl_prihod",,,"Prihodi od valutne (indeksne) klauzule iz odnosa s povezanim poduzetnicima","Prihodi od valutne (indeksne) klauzule iz odnosa s povezanim poduzetnicima" +"7704","kp_rrif7704","kp_rrif770","other","account_type_posl_prihod",,,"Ostali financijski prihodi od povezanih poduzet","Ostali financijski prihodi od povezanih poduzet" +"7705","kp_rrif7705","kp_rrif770","other","account_type_posl_prihod",,,"Ostali financijski prihodi od povez. poduzetnika","Ostali financijski prihodi od povez. poduzetnika" +"7706","kp_rrif7706","kp_rrif770","other","account_type_posl_prihod",,,"Dobitci od prodaje udjela i dionica od povezanih poduzetnika","Dobitci od prodaje udjela i dionica od povezanih poduzetnika" +"771","kp_rrif771","kp_rrif77","view","account_type_view",,,"Prihodi od kamata","Prihodi od kamata" +"7710","kp_rrif7710","kp_rrif771","other","account_type_posl_prihod",,,"Prihodi od redovnih kamata","Prihodi od redovnih kamata" +"7711","kp_rrif7711","kp_rrif771","other","account_type_posl_prihod",,,"Prihodi od zateznih kamata","Prihodi od zateznih kamata" +"7712","kp_rrif7712","kp_rrif771","other","account_type_posl_prihod",,,"Prihodi od kamata iz financijske imovine i dr.","Prihodi od kamata iz financijske imovine i dr." +"7713","kp_rrif7713","kp_rrif771","other","account_type_posl_prihod",,,"Kamate na depozite i jamčevine","Kamate na depozite i jamčevine" +"772","kp_rrif772","kp_rrif77","view","account_type_view",,,"Prihodi od tečajnih razlika","Prihodi od tečajnih razlika" +"7720","kp_rrif7720","kp_rrif772","other","account_type_posl_prihod",,,"Pozitivne tečajne razlike iz tražbina i stanja deviza na računu","Pozitivne tečajne razlike iz tražbina i stanja deviza na računu" +"7721","kp_rrif7721","kp_rrif772","other","account_type_posl_prihod",,,"Pozitivne tečajne razlike iz nižih obveza prema inozemstvu","Pozitivne tečajne razlike iz nižih obveza prema inozemstvu" +"7722","kp_rrif7722","kp_rrif772","other","account_type_posl_prihod",,,"Prihodi od ostalih tečajnih razlika","Prihodi od ostalih tečajnih razlika" +"773","kp_rrif773","kp_rrif77","view","account_type_view",,,"Prihodi od dividende i dobitaka iz udjela","Prihodi od dividende i dobitaka iz udjela" +"7730","kp_rrif7730","kp_rrif773","other","account_type_posl_prihod",,,"Prihodi od dividendi","Prihodi od dividendi" +"7731","kp_rrif7731","kp_rrif773","other","account_type_posl_prihod",,,"Prihodi od udjela u dobitku u d.o.o. i dr.","Prihodi od udjela u dobitku u d.o.o. i dr." +"774","kp_rrif774","kp_rrif77","view","account_type_view",,,"Ostali financijski prihodi","Ostali financijski prihodi" +"7740","kp_rrif7740","kp_rrif774","other","account_type_posl_prihod",,,"Prihodi iz udjela u investicijskim i dr. fondovima","Prihodi iz udjela u investicijskim i dr. fondovima" +"7741","kp_rrif7741","kp_rrif774","other","account_type_posl_prihod",,,"Dobitci od prodaje dionica i udjela (s nepovez. društvima) i dr. vrijed. papira","Dobitci od prodaje dionica i udjela (s nepovez. društvima) i dr. vrijed. papira" +"7742","kp_rrif7742","kp_rrif774","other","account_type_posl_prihod",,,"Prihodi od primjene valutne (indeksne) klauzule","Prihodi od primjene valutne (indeksne) klauzule" +"7743","kp_rrif7743","kp_rrif774","other","account_type_posl_prihod",,,"Ostali financijski prihodi iz odnosa s nepovezanim poduzetnicima i dr. osobama","Ostali financijski prihodi iz odnosa s nepovezanim poduzetnicima i dr. osobama" +"7744","kp_rrif7744","kp_rrif774","other","account_type_posl_prihod",,,"Prihodi od prodaje ostale financijske imovine","Prihodi od prodaje ostale financijske imovine" +"775","kp_rrif775","kp_rrif77","view","account_type_view",,,"Dio prihoda od pridruženih poduzetnika i sudjelujućih interesa","Dio prihoda od pridruženih poduzetnika i sudjelujućih interesa" +"7750","kp_rrif7750","kp_rrif775","other","account_type_posl_prihod",,,"Financijski prihodi (dividende, dobitci) iz udjela u društvima do 20%","Financijski prihodi (dividende, dobitci) iz udjela u društvima do 20%" +"7751","kp_rrif7751","kp_rrif775","other","account_type_posl_prihod",,,"Prihodi od kamata, teč. razlika i dr. fin. prihoda iz odnosa s pridruženim poduz. i od udjela do 20%","Prihodi od kamata, tečajnih razlika i dr. fin. prihoda iz odnosa s pridruženim poduzetnicima i od društava u kojima se drži udio do 20%" +"776","kp_rrif776","kp_rrif77","view","account_type_view",,,"Nerealizirani dobitci (prihodi) od financijske imovine","Nerealizirani dobitci (prihodi) od financijske imovine" +"7760","kp_rrif7760","kp_rrif776","other","account_type_posl_prihod",,,"Prihodi iz procjene fin. imovine namijenjene za trgovanje (HSFI 15. t. 15.52. i MRS 39. t. 55a. i dr.)","Prihodi iz procjene fin. imovine namijenjene za trgovanje (HSFI 15. t. 15.52. i MRS 39. t. 55a. i dr.)" +"7761","kp_rrif7761","kp_rrif776","other","account_type_posl_prihod",,,"Dobitci iz promjene fer vrijednosti ulaganja u nekretnine (HSFI 7. i MRS 40)","Dobitci iz promjene fer vrijednosti ulaganja u nekretnine (HSFI 7. i MRS 40)" +"7762","kp_rrif7762","kp_rrif776","other","account_type_posl_prihod",,,"Dobitci iz promjene vrijednosti ostale imovine","Dobitci iz promjene vrijednosti ostale imovine" +"777","kp_rrif777","kp_rrif77","view","account_type_view",,,"Prihodi negativnog goodwilla","Prihodi negativnog goodwilla" +"7770","kp_rrif7770","kp_rrif777","other","account_type_posl_prihod",,,"Prihodi negativnog goodwilla-a1","Prihodi negativnog goodwilla-Analitika 1" +"778","kp_rrif778","kp_rrif77","view","account_type_view",,,"Ostali financijski prihodi","Ostali financijski prihodi" +"7780","kp_rrif7780","kp_rrif778","other","account_type_posl_prihod",,,"Prihodi iz burzovnih transakcija","Prihodi iz burzovnih transakcija" +"7781","kp_rrif7781","kp_rrif778","other","account_type_posl_prihod",,,"Prihodi iz faktoringa, forwarda, opcija i sl.","Prihodi iz faktoringa i sl." +"7782","kp_rrif7782","kp_rrif778","other","account_type_posl_prihod",,,"Prihodi od neplaćenih obveza - davanja (za šume, poreze, članarine, naknade i dr.)","Prihodi od neplaćenih obveza - davanja (za šume, poreze, članarine, naknade i dr.)" +"7783","kp_rrif7783","kp_rrif778","other","account_type_posl_prihod",,,"Prihodi iz fin. leasinga","Prihodi iz fin. leasinga" +"7784","kp_rrif7784","kp_rrif778","other","account_type_posl_prihod",,,"Prihodi od naplate životnog osiguranja","Prihodi od naplate životnog osiguranja" +"78","kp_rrif78","kp_rrif7","view","account_type_view",,,"OSTALI POSLOVNI I IZVANREDNI PRIHODI","OSTALI POSLOVNI I IZVANREDNI PRIHODI" +"780","kp_rrif780","kp_rrif78","view","account_type_view",,,"Prihodi od otpisa obveza i popusta","Prihodi od otpisa obveza i popusta" +"7800","kp_rrif7800","kp_rrif780","other","account_type_izv_prihod",,,"Otpisi obveza prema dobavljačima, obveza za primljene predujmove i sl.","Otpisi obveza prema dobavljačima, obveza za primljene predujmove i sl." +"7801","kp_rrif7801","kp_rrif780","other","account_type_izv_prihod",,,"Otpis obveza prema kreditorima","Otpis obveza prema kreditorima" +"7802","kp_rrif7802","kp_rrif780","other","account_type_izv_prihod",,,"Otpis obveza prema zaposlenicima","Otpis obveza prema zaposlenicima" +"7803","kp_rrif7803","kp_rrif780","other","account_type_izv_prihod",,,"Prihodi od zastare obveza","Prihodi od zastare obveza" +"7805","kp_rrif7805","kp_rrif780","other","account_type_izv_prihod",,,"Otpis ostalih obveza","Otpis ostalih obveza" +"7807","kp_rrif7807","kp_rrif780","other","account_type_izv_prihod",,,"Prihodi od naknadnih odobrenja - sniženja i popusta od dobavljača i dr.","Prihodi od naknadnih odobrenja - sniženja i popusta od dobavljača i dr." +"781","kp_rrif781","kp_rrif78","view","account_type_view",,,"Prihodi od rezidualnih imovinskih stavki, viškova i procjena","Prihodi od rezidualnih imovinskih stavki, viškova i procjena" +"7810","kp_rrif7810","kp_rrif781","other","account_type_izv_prihod",,,"Prihodi od prodaje otpisanih i rashodovanih sredstava rada (alata, opreme i sl.)","Prihodi od prodaje otpisanih i rashodovanih sredstava rada (alata, opreme i sl.)" +"7811","kp_rrif7811","kp_rrif781","other","account_type_izv_prihod",,,"Prihodi od prodaje dugotrajne materijalne imovine (iz uporabe a amortizirane)","Prihodi od prodaje dugotrajne materijalne imovine (iz uporabe i amortiz.)" +"7812","kp_rrif7812","kp_rrif781","other","account_type_izv_prihod",,,"Prihodi od prodaje dugotr. nemater. imovine (trgov. znak, patent i dr.) - iz uporabe","Prihodi od prodaje dugotr. nemater. imovine (trgov. znak, patent i dr.) - iz uporabe" +"7813","kp_rrif7813","kp_rrif781","other","account_type_izv_prihod",,,"Prihodi od ranije otpisanih zaliha po novoj procjeni (HSFI t. 10.38. i MRS 2, t. 33.)","Prihodi od ranije otpisanih zaliha po novoj procjeni (HSFI t. 10.38. i MRS 2, t. 33.)" +"7814","kp_rrif7814","kp_rrif781","other","account_type_izv_prihod",,,"Inventurni viškovi na robi, proizvodima i zalihama sirovina, materijala, dijelova i dugotrajne imovine","Inventurni viškovi na robi, proizvodima i zalihama sirovina, materijala, dijelova i dugotrajne imovine" +"7815","kp_rrif7815","kp_rrif781","other","account_type_izv_prihod",,,"Viškovi u blagajni (novac, vrijed. papiri i dr.)","Viškovi u blagajni (novac, vrijed. papiri i dr.)" +"7816","kp_rrif7816","kp_rrif781","other","account_type_izv_prihod",,,"Viškovi iz neidentificiranih novčanih doznaka u tekućem poslovanju","Viškovi iz neidentificiranih novčanih doznaka u tekućem poslovanju" +"7817","kp_rrif7817","kp_rrif781","other","account_type_izv_prihod",,,"Prihodi od prodaje ulaganja u nekretnine (MRS 40. t. 69.)","Prihodi od ulaganja u nekretnine (MRS 40. t. 69.)" +"7818","kp_rrif7818","kp_rrif781","other","account_type_izv_prihod",,,"Prihodi od procjene prometa (utrška) po nalazu poreznog nadzora","Prihodi od procjene prometa (utrška) po nalazu poreznog nadzora" +"7819","kp_rrif7819","kp_rrif781","other","account_type_izv_prihod",,,"Prihodi od ostalih primitaka bez nadoknade","Prihodi od ostalih primitaka bez nadoknade" +"782","kp_rrif782","kp_rrif78","view","account_type_view",,,"Prihodi od ukidanja rezerviranja i naknadno naplaćeni prihodi","Prihodi od ukidanja rezerviranja i naknadno naplaćeni prihodi" +"7820","kp_rrif7820","kp_rrif782","other","account_type_izv_prihod",,,"Prihodovanje dugoročnih rezerviranja","Prihodovanje dugoročnih rezerviranja" +"7821","kp_rrif7821","kp_rrif782","other","account_type_izv_prihod",,,"Naknadno utvrđeni prihodi","Naknadno utvrđeni prihodi" +"7822","kp_rrif7822","kp_rrif782","other","account_type_izv_prihod",,,"Ukidanje pasiv. vrem. razgraničenja","Ukidanje pasiv. vrem. razgraničenja" +"7824","kp_rrif7824","kp_rrif782","other","account_type_izv_prihod",,,"Prihodi od ukidanja troškova od kojih se odustalo","Prihodi od ukidanja troškova od kojih se odustalo" +"7825","kp_rrif7825","kp_rrif782","other","account_type_izv_prihod",,,"Prihodi od naknadno naplaćenih jamstava - garancija","Prihodi od naknadno naplaćenih jamstava - garancija" +"7826","kp_rrif7826","kp_rrif782","other","account_type_izv_prihod",,,"Prihodi od naknadno naplaćenih potraživanja iz prethodnih godina","Prihodi od naknadno naplaćenih potraživanja iz prethodnih godina" +"7827","kp_rrif7827","kp_rrif782","other","account_type_izv_prihod",,,"Prihodi od naplate iz ugovora po naknadnim priznanjima iz prošlih godina","Prihodi od naplate iz ugovora po naknadnim priznanjima iz prošlih godina" +"7828","kp_rrif7828","kp_rrif782","other","account_type_izv_prihod",,,"Prihodi od naknadno naplaćenih reklamacija","Prihodi od naknadno naplaćenih reklamacija" +"7829","kp_rrif7829","kp_rrif782","other","account_type_izv_prihod",,,"Prihodi od zaprimanja dobara koja su prodana u prethodnom obrač. razdoblju","Prihodi od zaprimanja dobara koja su prodana u prethodnom obrač. razdoblju" +"783","kp_rrif783","kp_rrif78","view","account_type_view",,,"Prihodi od refundac., dotacija, subvencija i nadoknada","Prihodi od refundac., dotacija, subvencija i nadoknada" +"7830","kp_rrif7830","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi od refundacije za rad radnika","Prihodi od refundacije za rad radnika" +"7831","kp_rrif7831","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi od naknada šteta iz tekućeg poslovanja","Prihodi od naknada šteta iz tekućeg poslovanja" +"7832","kp_rrif7832","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi od subvencija","Prihodi od subvencija" +"7833","kp_rrif7833","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi od dotacija i pomoći","Prihodi od dotacija i pomoći" +"7834","kp_rrif7834","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi s osnove basplatnog primitka opreme, nekretnina, zaliha i potraživanja","Prihodi s osnove basplatnog primitka opreme, nekretnina, zaliha i potraživanja" +"7835","kp_rrif7835","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi od naknada za jamstva","Prihodi od naknada za jamstva" +"7836","kp_rrif7836","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi od prefakturiranih troškova (npr. komunalnih, premija osiguranja i dr.)","Prihodi od prefakturiranih troškova (npr. komunalnih, premija osiguranja i dr.)" +"7837","kp_rrif7837","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi za pokriće gubitka","Prihodi za pokriće gubitka" +"7838","kp_rrif7838","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi za manjkove od odgovornih osoba","Prihodi za manjkove od odgovornih osoba" +"7839","kp_rrif7839","kp_rrif783","other","account_type_izv_prihod",,,"Prihodi od ostalih nadoknada iz poslovanja","Prihodi od ostalih nadoknada iz poslovanja" +"784","kp_rrif784","kp_rrif78","view","account_type_view",,,"Prihodi od revalorizacije - procjene","Prihodi od revalorizacije - procjene" +"7840","kp_rrif7840","kp_rrif784","other","account_type_izv_prihod",,,"Prihodi od revalorizacije zaliha","Prihodi od revalorizacije zaliha" +"7841","kp_rrif7841","kp_rrif784","other","account_type_izv_prihod",,,"Prihodi od revalorizacije financijske imovine raspoložive za prodaju","Prihodi od revalorizacije financijske imovine raspoložive za prodaju" +"7842","kp_rrif7842","kp_rrif784","other","account_type_izv_prihod",,,"Prihodi od ukidanja gubitka (MRS 36)","Prihodi od ukidanja gubitka (MRS 36)" +"7843","kp_rrif7843","kp_rrif784","other","account_type_izv_prihod",,,"Prihodi od procjene zaliha i dr. imovine","Prihodi od procjene zaliha i dr. imovine" +"7844","kp_rrif7844","kp_rrif784","other","account_type_izv_prihod",,,"Prihodi od procjene ostale imovine","Prihodi od procjene ostale imovine" +"785","kp_rrif785","kp_rrif78","view","account_type_view",,,"Ostali poslovni prihodi","Ostali poslovni prihodi" +"7850","kp_rrif7850","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi s osnove povrata poreza na promet","Prihodi s osnove povrata poreza na promet" +"7851","kp_rrif7851","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od ugovorenih i naplaćenih penala zbog neizvršenja roka u isporuci","Prihodi od ugovorenih i naplaćenih penala zbog neizvršenja roka u isporuci" +"7852","kp_rrif7852","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od nagrada za proizvod, uslugu, oblik i sl.","Prihodi od nagrada za proizvod, uslugu, oblik i sl." +"7853","kp_rrif7853","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od (nevraćenih) kaucija i depozita","Prihodi od (nevraćenih) kaucija i depozita" +"7854","kp_rrif7854","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od kapara, odustatnina i sl.","Prihodi od kapara, odustatnina i sl." +"7855","kp_rrif7855","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od vraćenih premija osiguranja","Prihodi od vraćenih premija osiguranja" +"7856","kp_rrif7856","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od financ. inženjeringa(projekt., financ. i izgr., kupoprodaja poduzeća i sl.) i provizija","Prihodi od financijskog inženjeringa (npr. projektiranje, financiranje i izgr. objekata, kupnja i prodaja poduzeća i sl.) i provizija" +"7857","kp_rrif7857","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od prodaje prava (patenata, licencija, koncesija, rente, imena, znaka i sl.)","Prihodi od prodaje prava (patenata, licencija, koncesija, rente, imena, znaka i sl.)" +"7858","kp_rrif7858","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od naplate šteta uništene imovine (požarom, poplavom i dr. višom silom)","Prihodi od naplate šteta uništene imovine (požarom, poplavom i dr. višom silom)" +"7859","kp_rrif7859","kp_rrif785","other","account_type_izv_prihod",,,"Prihodi od naplate šteta po sudskim procesima (zbog oduzete imovine,zlouporabe znaka,imena,prava i dr.)","Prihodi od naplate šteta po sudskim procesima (npr. zbog oduzete imovine, zlouporabe znaka, imena, prava i dr.)" +"786","kp_rrif786","kp_rrif78","view","account_type_view",,,"Prihodi od državnih potpora (HSFI 15 i MRS 20)","Prihodi od državnih potpora (HSFI 15 i MRS 20)" +"7860","kp_rrif7860","kp_rrif786","other","account_type_izv_prihod",,,"Prihodi od državnih potpora za pokriće troškova","Prihodi od državnih potpora za pokriće troškova" +"7861","kp_rrif7861","kp_rrif786","other","account_type_izv_prihod",,,"Prihodi (odgođeni) od državnih potpora za investicije (sredstva)","Prihodi od državnih potpora za investicije (sredstva)" +"7862","kp_rrif7862","kp_rrif786","other","account_type_izv_prihod",,,"Prihodi od državnih potpora za ostale određene namjene","Prihodi od državnih potpora za ostale određene namjene" +"787","kp_rrif787","kp_rrif78","view","account_type_view",,,"Dobitci od procjene poljoprivrednih proizvoda i biološke imovine (HSFI 17, t. 17.12 i MRS 41)","Dobitci od procjene poljoprivrednih proizvoda i biološke imovine (HSFI 17, t. 17.12 i MRS 41)" +"7870","kp_rrif7870","kp_rrif787","other","account_type_izv_prihod",,,"Dobitci od prirasta biološke imovine","Dobitci od prirasta biološke imovine" +"7871","kp_rrif7871","kp_rrif787","other","account_type_izv_prihod",,,"Dobitci od procjene biološke imovine","Dobitci od procjene biološke imovine" +"7872","kp_rrif7872","kp_rrif787","other","account_type_izv_prihod",,,"Dobitci od procjene poljoprivrednih proizvoda","Dobitci od procjene poljoprivrednih proizvoda" +"788","kp_rrif788","kp_rrif78","view","account_type_view",,,"Prihodi uporabe vlastitih proizvoda","Prihodi od uporabe vlastitih proizvoda" +"7880","kp_rrif7880","kp_rrif788","other","account_type_izv_prihod",,,"Prihodi uporabe vlastitih proizvoda i usluga za troškove","Prihodi uporabe vlastitih proizvoda i usluga za troškove" +"7881","kp_rrif7881","kp_rrif788","other","account_type_izv_prihod",,,"Prihodi od uporabe vlastitih proizvoda i usluga za dugotrajnu imovinu","Prihodi od uporabe vlastitih proizvoda i usluga za dugotrajnu imovinu" +"789","kp_rrif789","kp_rrif78","view","account_type_view",,,"Izvanredni - ostali prihodi (npr. veliki besplatni primitak, prihod koji nije proizašao iz redovitog poslovanja)","Izvanredni - ostali prihodi (npr. veliki besplatni primitak, prihod koji nije proizašao iz redovitog poslovanja)" +"7890","kp_rrif7890","kp_rrif789","other","account_type_izv_prihod",,,"Prihod od izvanredne prodaje značajnog dijela imovine","Prihod od izvanredne prodaje značajnog dijela imovine" +"7891","kp_rrif7891","kp_rrif789","other","account_type_izv_prihod",,,"Prihod od dugotrajne materijalne imovine namijenjene prodaji","Prihod od dugotrajne materijalne imovine namijenjene prodaji" +"7892","kp_rrif7892","kp_rrif789","other","account_type_izv_prihod",,,"Prihod od izvansudskih nagodbi","Prihod od izvansudskih nagodbi" +"7899","kp_rrif7899","kp_rrif789","other","account_type_izv_prihod",,,"Ostali nepredviđeni prihodi","Ostali nepredviđeni prihodi" +"79","kp_rrif79","kp_rrif7","view","account_type_view",,,"RAZLIKA PRIHODA I RASHODA FINANCIJSKE GODINE","RAZLIKA PRIHODA I RASHODA FINANCIJSKE GODINE" +"790","kp_rrif790","kp_rrif79","view","account_type_view",,,"Razlika prihoda i rashoda (iz cjelokupnog poslovanja)","Razlika prihoda i rashoda (iz cjelokupnog poslovanja)" +"7900","kp_rrif7900","kp_rrif790","other","account_type_other",,,"Razlika prihoda i rashoda (iz cjelokupnog poslovanja)-a1","Razlika prihoda i rashoda (iz cjelokupnog poslovanja)-Analitika 1" +"8","kp_rrif8","kp_rrif","view","account_type_view",,,"FINANCIJSKI REZULTAT POSLOVANJA","FINANCIJSKI REZULTAT POSLOVANJA" +"80","kp_rrif80","kp_rrif8","view","account_type_view",,,"DOBITAK ILI GUBITAK RAZDOBLJA","DOBITAK ILI GUBITAK RAZDOBLJA" +"800","kp_rrif800","kp_rrif80","view","account_type_view",,,"Dobitak prije oporezivanja","Dobitak prije oporezivanja" +"8000","kp_rrif8000","kp_rrif800","other","account_type_other",,,"Dobitak prije oporezivanja-a1","Dobitak prije oporezivanja-Analitika 1" +"801","kp_rrif801","kp_rrif80","view","account_type_view",,,"Gubitak prije oporezivanja","Gubitak prije oporezivanja" +"8010","kp_rrif8010","kp_rrif801","other","account_type_other",,,"Gubitak prije oporezivanja-a1","Gubitak prije oporezivanja-Analitika 1" +"803","kp_rrif803","kp_rrif80","view","account_type_view",,,"Porez na dobitak (gubitak)","Porez na dobitak (gubitak)" +"8030","kp_rrif8030","kp_rrif803","other","account_type_other",,,"Porez na dobitak (gubitak)-a1","Porez na dobitak (gubitak)-Analitika 1" +"804","kp_rrif804","kp_rrif80","view","account_type_view",,,"Dobitak ili gubitak razdoblja","Dobitak ili gubitak razdoblja" +"8040","kp_rrif8040","kp_rrif804","other","account_type_other",,,"Dobitak razdoblja (poslije poreza)","Dobitak razdoblja (poslije poreza)" +"8041","kp_rrif8041","kp_rrif804","other","account_type_other",,,"Gubitak razdoblja","Gubitak razdoblja" +"81","kp_rrif81","kp_rrif8","view","account_type_view",,,"DOBITAK ILI GUBITAK RAZDOBLJA KOJI PRIPADA DRUGIMA","DOBITAK ILI GUBITAK RAZDOBLJA KOJI PRIPADA DRUGIMA" +"810","kp_rrif810","kp_rrif81","view","account_type_view",,,"Dobitak pripisan imateljima kapitala matice","Dobitak pripisan imateljima kapitala matice" +"8100","kp_rrif8100","kp_rrif810","other","account_type_other",,,"Dobitak pripisan imateljima kapitala matice-a1","Dobitak pripisan imateljima kapitala matice-Analitika 1" +"811","kp_rrif811","kp_rrif81","view","account_type_view",,,"Gubitak koji tereti imatelje kapitala matice","Gubitak koji tereti imatelje kapitala matice" +"8110","kp_rrif8110","kp_rrif811","other","account_type_other",,,"Gubitak koji tereti imatelje kapitala matice-a1","Gubitak koji tereti imatelje kapitala matice-Analitika 1" +"813","kp_rrif813","kp_rrif81","view","account_type_view",,,"Dobitak pripisan manjinskom interesu","Dobitak pripisan manjinskom interesu" +"8130","kp_rrif8130","kp_rrif813","other","account_type_other",,,"Dobitak pripisan manjinskom interesu-a1","Dobitak pripisan manjinskom interesu-Analitika 1" +"814","kp_rrif814","kp_rrif81","view","account_type_view",,,"Gubitak koji tereti manjinski interes","Gubitak koji tereti manjinski interes" +"8140","kp_rrif8140","kp_rrif814","other","account_type_other",,,"Gubitak koji tereti manjinski interes-a1","Gubitak koji tereti manjinski interes-Analitika 1" +"9","kp_rrif9","kp_rrif","view","account_type_view",,,"KAPITAL I PRIČUVE TE IZVANBILANČNI ZAPISI","KAPITAL I PRIČUVE TE IZVANBILANČNI ZAPISI" +"90","kp_rrif90","kp_rrif9","view","account_type_view",,,"TEMELJNI - (UPISANI) KAPITAL","TEMELJNI - (UPISANI) KAPITAL" +"900","kp_rrif900","kp_rrif90","view","account_type_view",,,"Upisani temeljni kapital koji je plaćen","Upisani temeljni kapital koji je plaćen" +"9000","kp_rrif9000","kp_rrif900","other","account_type_kapital",,,"Upisani temeljni kapital članova d.o.o. (analitika po članovima)","Upisani temeljni kapital članova d.o.o. (analitika po članovima)" +"9001","kp_rrif9001","kp_rrif900","other","account_type_kapital",,,"Temeljni dionički kapital (obične dionice)","Temeljni dionički kapital (obične dionice)" +"9002","kp_rrif9002","kp_rrif900","other","account_type_kapital",,,"Temeljni dionički kapital (povlaštene dionice)","Temeljni dionički kapital (povlaštene dionice)" +"901","kp_rrif901","kp_rrif90","view","account_type_view",,,"Upisani temeljni kapital manjinskih članova","Upisani temeljni kapital manjinskih članova" +"9010","kp_rrif9010","kp_rrif901","other","account_type_kapital",,,"Upisani temeljni kapital manjinskih članova-a1","Upisani temeljni kapital manjinskih članova-Analitika 1" +"902","kp_rrif902","kp_rrif90","view","account_type_view",,,"Upisani kapital koji nije plaćen","Upisani kapital koji nije plaćen" +"9020","kp_rrif9020","kp_rrif902","other","account_type_kapital",,,"Upisani temeljni kapital koji je pozvan za uplatu (analitika po upisnicima)","Upisani temeljni kapital koji je pozvan za uplatu (analitika po upisnicima)" +"903","kp_rrif903","kp_rrif90","view","account_type_view",,,"Kapital (ulozi) članova javnog trgovačkog društva","Kapital (ulozi) članova javnog trgovačkog društva" +"9030","kp_rrif9030","kp_rrif903","other","account_type_kapital",,,"Kapital (ulozi) članova javnog trgovačkog društva-a1","Kapital (ulozi) članova javnog trgovačkog društva-Analitika 1" +"904","kp_rrif904","kp_rrif90","view","account_type_view",,,"Kapital (ulozi) komanditora komanditnog društva","Kapital (ulozi) komanditora komanditnog društva" +"9040","kp_rrif9040","kp_rrif904","other","account_type_kapital",,,"Kapital (ulozi) komanditora komanditnog društva-a1","Kapital (ulozi) komanditora komanditnog društva-Analitika 1" +"905","kp_rrif905","kp_rrif90","view","account_type_view",,,"Državni kapital u udjelima","Državni kapital u udjelima" +"9050","kp_rrif9050","kp_rrif905","other","account_type_kapital",,,"Državni kapital u udjelima-a1","Državni kapital u udjelima-Analitika 1" +"906","kp_rrif906","kp_rrif90","view","account_type_view",,,"Kapital članova zadruge","Kapital članova zadruge" +"9060","kp_rrif9060","kp_rrif906","other","account_type_kapital",,,"Kapital članova zadruge-a1","Kapital članova zadruge-Analitika 1" +"91","kp_rrif91","kp_rrif9","view","account_type_view",,,"KAPITALNE PRIČUVE","KAPITALNE PRIČUVE" +"910","kp_rrif910","kp_rrif91","view","account_type_view",,,"Uplaćeni udjeli - dionice iznad svote temeljnog kapitala","Uplaćeni udjeli - dionice iznad svote temeljnog kapitala" +"9100","kp_rrif9100","kp_rrif910","other","account_type_kapital",,,"Uplaćeni udjeli - dionice iznad svote temeljnog kapitala-a1","Uplaćeni udjeli - dionice iznad svote temeljnog kapitala-Analitika 1" +"911","kp_rrif911","kp_rrif91","view","account_type_view",,,"Kapitalne pričuve iz dodatnih uplata radi stjecanja posebnih prava u društvu(ili zamjenjivih obveznica)","Kapitalne pričuve iz dodatnih uplata radi stjecanja posebnih prava u društvu (ili zamjenjivih obveznica)" +"9110","kp_rrif9110","kp_rrif911","other","account_type_kapital",,,"Kapitalne pričuve iz dodatnih uplata radi stjecanja posebnih prava u društvu(ili zamjenjivih obveznica)-a1","Kapitalne pričuve iz dodatnih uplata radi stjecanja posebnih prava u društvu (ili zamjenjivih obveznica)-Analitika 1" +"912","kp_rrif912","kp_rrif91","view","account_type_view",,,"Kapitalne pričuve iz uplata dodatnih činidbi","Kapitalne pričuve iz uplata dodatnih činidbi" +"9120","kp_rrif9120","kp_rrif912","other","account_type_kapital",,,"Kapitalne pričuve iz uplata dodatnih činidbi-a1","Kapitalne pričuve iz uplata dodatnih činidbi-Analitika 1" +"913","kp_rrif913","kp_rrif91","view","account_type_view",,,"Kapitalne pričuve iz ostatka pri smanjenju temeljnog kapitala","Kapitalne pričuve iz ostatka pri smanjenju temeljnog kapitala" +"9130","kp_rrif9130","kp_rrif913","other","account_type_kapital",,,"Kapitalne pričuve iz ostatka pri smanjenju temeljnog kapitala-a1","Kapitalne pričuve iz ostatka pri smanjenju temeljnog kapitala-Analitika 1" +"914","kp_rrif914","kp_rrif91","view","account_type_view",,,"Kapitalne pričuve iz drugih izvora","Kapitalne pričuve iz drugih izvora" +"9140","kp_rrif9140","kp_rrif914","other","account_type_kapital",,,"Kapitalne pričuve iz drugih izvora-a1","Kapitalne pričuve iz drugih izvora-Analitika 1" +"915","kp_rrif915","kp_rrif91","view","account_type_view",,,"Kapitalni dobitak iz prodaje vlastitih udjela - dionica","Kapitalni dobitak iz prodaje vlastitih udjela - dionica" +"9150","kp_rrif9150","kp_rrif915","other","account_type_kapital",,,"Kapitalni dobitak iz prodaje vlastitih udjela - dionica-a1","Kapitalni dobitak iz prodaje vlastitih udjela - dionica-Analitika 1" +"916","kp_rrif916","kp_rrif91","view","account_type_view",,,"Kapitalni dobitak na prodane emitirane dionice","Kapitalni dobitak na prodane emitirane dionice" +"9160","kp_rrif9160","kp_rrif916","other","account_type_kapital",,,"Kapitalni dobitak na prodane emitirane dionice-a1","Kapitalni dobitak na prodane emitirane dionice-Analitika 1" +"917","kp_rrif917","kp_rrif91","view","account_type_view",,,"Kapitalne pričuve iz ulaganja tajnog člana društva (čl. 148. ZTD-a)","Kapitalne pričuve iz ulaganja tajnog člana društva (čl. 148. ZTD-a)" +"9170","kp_rrif9170","kp_rrif917","other","account_type_kapital",,,"Kapitalne pričuve iz ulaganja tajnog člana društva (čl. 148. ZTD-a)-a1","Kapitalne pričuve iz ulaganja tajnog člana društva (čl. 148. ZTD-a)-Analitika 1" +"919","kp_rrif919","kp_rrif91","view","account_type_view",,,"Kapital iz ulaganja obrtnika dobitaša","Kapital iz ulaganja obrtnika dobitaša" +"9190","kp_rrif9190","kp_rrif919","other","account_type_kapital",,,"Kapital iz ulaganja obrtnika dobitaša-a1","Kapital iz ulaganja obrtnika dobitaša-Analitika 1" +"92","kp_rrif92","kp_rrif9","view","account_type_view",,,"PRIČUVE IZ DOBITKA","PRIČUVE IZ DOBITKA" +"920","kp_rrif920","kp_rrif92","view","account_type_view",,,"Zakonske pričuve (u d.d.)","Zakonske pričuve (u d.d.)" +"9200","kp_rrif9200","kp_rrif920","other","account_type_kapital",,,"Pričuve prema ZTD","Pričuve prema ZTD" +"9201","kp_rrif9201","kp_rrif920","other","account_type_kapital",,,"Pričuve za povećanje temeljnog kapitala","Pričuve za povećanje temeljnog kapitala" +"9202","kp_rrif9202","kp_rrif920","other","account_type_kapital",,,"Pričuve za pokriće gubitka","Pričuve za pokriće gubitka" +"921","kp_rrif921","kp_rrif92","view","account_type_view",,,"Pričuve za vlastite dionice i udjele (čl. 233. i 406.a ZTD-a)","Pričuve za vlastite dionice i udjele (čl. 233. i 406.a ZTD-a)" +"9210","kp_rrif9210","kp_rrif921","other","account_type_kapital",,,"Pričuve za opcijske dionice za zaposlenike","Pričuve za opcijske dionice za zaposlenike" +"9211","kp_rrif9211","kp_rrif921","other","account_type_kapital",,,"Pričuve za otkupljene dionice radi obeštećenja dioničara","Pričuve za otkupljene dionice radi obeštećenja dioničara" +"9212","kp_rrif9212","kp_rrif921","other","account_type_kapital",,,"Pričuve za otkup dionica da bi se spriječila šteta i dr.","Pričuve za otkup dionica da bi se spriječila šteta i dr." +"9213","kp_rrif9213","kp_rrif921","other","account_type_kapital",,,"Pričuve za vlastite (trezorske) dionice i udjele","Pričuve za vlastite (trezorske) dionice i udjele" +"922","kp_rrif922","kp_rrif92","view","account_type_view",,,"Vlastite dionice i udjeli (odbitna- dugovna stavka)","Vlastite dionice i udjeli (odbitna- dugovna stavka)" +"9220","kp_rrif9220","kp_rrif922","other","account_type_kapital",,,"Otkupljene vlastite dionice","Otkupljene vlastite dionice" +"9221","kp_rrif9221","kp_rrif922","other","account_type_kapital",,,"Otkupljeni vlastiti udjeli","Otkupljeni vlastiti udjeli" +"9222","kp_rrif9222","kp_rrif922","other","account_type_kapital",,,"Vlastite dionice za opcijsku namjenu","Vlastite dionice za opcijsku namjenu" +"923","kp_rrif923","kp_rrif92","view","account_type_view",,,"Statutarne pričuve","Statutarne pričuve" +"9230","kp_rrif9230","kp_rrif923","other","account_type_kapital",,,"Pričuve za održavanje financijske stabilnosti društva, za razvojne aktivnosti i sl.","Pričuve za održavanje financijske stabilnosti društva, za razvojne aktivnosti i sl." +"9231","kp_rrif9231","kp_rrif923","other","account_type_kapital",,,"Pričuve za restrukturiranje","Pričuve za restrukturiranje" +"9232","kp_rrif9232","kp_rrif923","other","account_type_kapital",,,"Pričuve radi održavanja boniteta strukture izvora financiranja","Pričuve radi održavanja boniteta strukture izvora financiranja" +"924","kp_rrif924","kp_rrif92","view","account_type_view",,,"Ostale pričuve","Ostale pričuve" +"9240","kp_rrif9240","kp_rrif924","other","account_type_kapital",,,"Pričuve za pokriće gubitka u poslovanju","Pričuve za pokriće gubitka u poslovanju" +"9241","kp_rrif9241","kp_rrif924","other","account_type_kapital",,,"Pričuve za nagrade i sl.","Pričuve za nagrade i sl." +"9242","kp_rrif9242","kp_rrif924","other","account_type_kapital",,,"Slobodne pričuve iz neraspoređenog dobitka","Slobodne pričuve iz neraspoređenog dobitka" +"9243","kp_rrif9243","kp_rrif924","other","account_type_kapital",,,"Pričuve za nerealizirane dobitke iz udjela","Pričuve za nerealizirane dobitke iz udjela" +"93","kp_rrif93","kp_rrif9","view","account_type_view",,,"REVALORIZACIJSKE PRIČUVE","REVALORIZACIJSKE PRIČUVE" +"930","kp_rrif930","kp_rrif93","view","account_type_view",,,"Revalorizacijske pričuve","Revalorizacijske pričuve" +"9300","kp_rrif9300","kp_rrif930","other","account_type_kapital",,,"Revalorizacijske pričuve iz procjene dug. nemat. i mat. imovine (HSFIt.6.36.iMRS16,t.39.iMRS38,t.85)","Revalorizacijske pričuve iz procjene dugotrajne nematerijalne i materijalne imovine (HSFI t. 6.36. i MRS 16, t. 39. i MRS 38, t. 85.) (analitika prema revaloriziranim imovinskim stavkama)" +"9301","kp_rrif9301","kp_rrif930","other","account_type_kapital",,,"Pričuve iz revalorizacije financijske imovine","Pričuve iz revalorizacije financijske imovine" +"9303","kp_rrif9303","kp_rrif930","other","account_type_kapital",,,"Ostale revalorizacijske pričuve","Ostale revalorizacijske pričuve" +"931","kp_rrif931","kp_rrif93","view","account_type_view",,,"Revalorizacijske pričuve ranijih godina","Revalorizacijske pričuve ranijih godina" +"9310","kp_rrif9310","kp_rrif931","other","account_type_kapital",,,"Revalorizacijske pričuve iz razdoblja od 2001. do 2004.","Revalorizacijske pričuve iz razdoblja od 2001. do 2004." +"9311","kp_rrif9311","kp_rrif931","other","account_type_kapital",,,"Revalorizacijske pričuve nastale do kraja 2000.","Revalorizacijske pričuve nastale do kraja 2000." +"932","kp_rrif932","kp_rrif93","view","account_type_view",,,"Pričuve iz tečajnih razlika od ulaganja u inozemno poslovanje (MRS 21. t. 39.)","Pričuve iz tečajnih razlika od ulaganja u inozemno poslovanje (MRS 21. t. 39.)" +"9320","kp_rrif9320","kp_rrif932","other","account_type_kapital",,,"Pričuve iz tečajnih razlika od ulaganja u inozemno poslovanje (MRS 21. t. 39.)-a1","Pričuve iz tečajnih razlika od ulaganja u inozemno poslovanje (MRS 21. t. 39.)-Analitika 1" +"933","kp_rrif933","kp_rrif93","view","account_type_view",,,"Dobitci/gubitci od udjela u kapitalu do prestanka priznavanja (MRS 1. t. 95. i MRS 39. 55.b)","Dobitci/gubitci od udjela u kapitalu do prestanka priznavanja (MRS 1. t. 95. i MRS 39. 55.b)" +"9330","kp_rrif9330","kp_rrif933","other","account_type_kapital",,,"Dobitci/gubitci od udjela u kapitalu do prestanka priznavanja (MRS 1. t. 95. i MRS 39. 55.b)-a1","Dobitci/gubitci od udjela u kapitalu do prestanka priznavanja (MRS 1. t. 95. i MRS 39. 55.b)-Analitika 1" +"934","kp_rrif934","kp_rrif93","view","account_type_view",,,"Dobitci/gubitci iz zaštite novčanog toka do reklasifikacije (MRS 1. t. 95. i MRS 39. t. 100.)","Dobitci/gubitci iz zaštite novčanog toka do reklasifikacije (MRS 1. t. 95. i MRS 39. t. 100.)" +"9340","kp_rrif9340","kp_rrif934","other","account_type_kapital",,,"Dobitci/gubitci iz zaštite novčanog toka do reklasifikacije (MRS 1. t. 95. i MRS 39. t. 100.)-a1","Dobitci/gubitci iz zaštite novčanog toka do reklasifikacije (MRS 1. t. 95. i MRS 39. t. 100.)-Analitika 1" +"935","kp_rrif935","kp_rrif93","view","account_type_view",,,"Ostali akumulirani sveobuhvatni dobitci/gubitci - pričuve (MRS 1. t. 96.)","Ostali akumulirani sveobuhvatni dobitci/gubitci - pričuve (MRS 1. t. 96.)" +"9350","kp_rrif9350","kp_rrif935","other","account_type_kapital",,,"Ostali akumulirani sveobuhvatni dobitci/gubitci - pričuve (MRS 1. t. 96.)-a1","Ostali akumulirani sveobuhvatni dobitci/gubitci - pričuve (MRS 1. t. 96.)-Analitika 1" +"94","kp_rrif94","kp_rrif9","view","account_type_view",,,"ZADRŽANI DOBITAK ILI PRENESENI GUBITAK","ZADRŽANI DOBITAK ILI PRENESENI GUBITAK" +"940","kp_rrif940","kp_rrif94","view","account_type_view",,,"Zadržani dobitak (iz prethodnih godina)","Zadržani dobitak (iz prethodnih godina)" +"9400","kp_rrif9400","kp_rrif940","view","account_type_view",,,"Zadržani dobitci ostvareni do kraja 2000.","Zadržani dobitci ostvareni do kraja 2000." +"94000","kp_rrif94000","kp_rrif9400","other","account_type_kapital",,,"Zadržani dobitak članova društva (analitika po članovima)","Zadržani dobitak članova društva (analitika po članovima)" +"94001","kp_rrif94001","kp_rrif9400","other","account_type_kapital",,,"Zadržani dobitak - neisplaćena dividenda","Zadržani dobitak - neisplaćena dividenda" +"94002","kp_rrif94002","kp_rrif9400","other","account_type_kapital",,,"Zadržani dobitak koji se izuzima od isplate (npr. za investicije u imovinu)","Zadržani dobitak koji se izuzima od isplate (npr. za investicije u imovinu)" +"94003","kp_rrif94003","kp_rrif9400","other","account_type_kapital",,,"Zadržani dobitak koji čeka raspored","Zadržani dobitak koji čeka raspored" +"94004","kp_rrif94004","kp_rrif9400","other","account_type_kapital",,,"Zadržani dobitak za privatne troškove članova društva","Zadržani dobitak za privatne troškove članova društva" +"94005","kp_rrif94005","kp_rrif9400","other","account_type_kapital",,,"Zadržani dobitak za manjinske članove društva","Zadržani dobitak za manjinske članove društva" +"94006","kp_rrif94006","kp_rrif9400","other","account_type_kapital",,,"Zadržani dobitak tajnog člana društva","Zadržani dobitak tajnog člana društva" +"9401","kp_rrif9401","kp_rrif940","view","account_type_view",,,"Zadržani dobitak iz 2001. do 2004.","Zadržani dobitak iz 2001. do 2004." +"94010","kp_rrif94010","kp_rrif9401","other","account_type_kapital",,,"Zadržani dobitak članova društva (analitika po članovima)","Zadržani dobitak članova društva (analitika po članovima)" +"94011","kp_rrif94011","kp_rrif9401","other","account_type_kapital",,,"Zadržani dobitak - neispl. dividende","Zadržani dobitak - neispl. dividende" +"94012","kp_rrif94012","kp_rrif9401","other","account_type_kapital",,,"Zadržani dobitak izuzet od isplate (npr. za investicije u imovinu)","Zadržani dobitak izuzet od isplate (npr. za investicije u imovinu)" +"94013","kp_rrif94013","kp_rrif9401","other","account_type_kapital",,,"Neraspoređeni zadržani dobitak","Neraspoređeni zadržani dobitak" +"9402","kp_rrif9402","kp_rrif940","view","account_type_view",,,"Zadržani dobitak od 2005. i poslije","Zadržani dobitak od 2005. i poslije" +"94020","kp_rrif94020","kp_rrif9402","other","account_type_kapital",,,"Zadržani dobitak članova društva (analitika po članovima)","Zadržani dobitak članova društva (analitika po članovima)" +"94021","kp_rrif94021","kp_rrif9402","other","account_type_kapital",,,"Zadržani dobitak - neispl. dividenda","Zadržani dobitak - neispl. dividenda" +"94022","kp_rrif94022","kp_rrif9402","other","account_type_kapital",,,"Zadržani dobitak izuzet od isplate (npr. za investicije u imovinu)","Zadržani dobitak izuzet od isplate (npr. za investicije u imovinu)" +"94023","kp_rrif94023","kp_rrif9402","other","account_type_kapital",,,"Neraspoređeni zadržani dobitak","Neraspoređeni zadržani dobitak" +"9403","kp_rrif9403","kp_rrif940","other","account_type_kapital",,,"Zadržani dobitak oblikovan iz realizirane rev. pričuve","Zadržani dobitak oblikovan iz realizirane rev. pričuve" +"9404","kp_rrif9404","kp_rrif940","other","account_type_kapital",,,"Zadržani dobitak po prijedlogu uprave i N.O.","Zadržani dobitak po prijedlogu uprave i N.O." +"9405","kp_rrif9405","kp_rrif940","other","account_type_kapital",,,"Zadržani dobitak iz negativnog goodwilla","Zadržani dobitak iz negativnog goodwilla" +"941","kp_rrif941","kp_rrif94","view","account_type_view",,,"Preneseni gubitak (kumuliran u prethodnim godinama - analitika po članovima)","Preneseni gubitak (kumuliran u prethodnim godinama - analitika po članovima)" +"9410","kp_rrif9410","kp_rrif941","other","account_type_kapital",,,"Preneseni gubitak (iz godine 200_.)","Preneseni gubitak (iz godine 200_.)" +"9411","kp_rrif9411","kp_rrif941","other","account_type_kapital",,,"Preneseni gubitak (iz godine 201_.)","Preneseni gubitak (iz godine 201_.)" +"9417","kp_rrif9417","kp_rrif941","other","account_type_kapital",,,"Gubitak (dio) koji je iznad kapitala","Gubitak (dio) koji je iznad kapitala" +"95","kp_rrif95","kp_rrif9","view","account_type_view",,,"DOBITAK ILI GUBITAK POSLOVNE GODINE","DOBITAK ILI GUBITAK POSLOVNE GODINE" +"950","kp_rrif950","kp_rrif95","view","account_type_view",,,"Dobitak poslovne godine","Dobitak poslovne godine" +"9500","kp_rrif9500","kp_rrif950","other","account_type_kapital",,,"Dobitak financijske godine (neraspoređen)","Dobitak financijske godine (neraspoređen)" +"9501","kp_rrif9501","kp_rrif950","other","account_type_kapital",,,"Dobitak za isplate i izuzimanja u tijeku godine (analitika po članovima)","Dobitak za isplate i izuzimanja u tijeku godine (analitika po članovima)" +"9502","kp_rrif9502","kp_rrif950","other","account_type_kapital",,,"Dobitak - dividenda financijske godine (analitika prema članovima društva - dioničarima)","Dobitak - dividenda financijske godine (analitika prema članovima društva - dioničarima)" +"9504","kp_rrif9504","kp_rrif950","other","account_type_kapital",,,"Dobitak koji se privremeno ne isplaćuje po prijedlogu uprave i N.O.","Dobitak koji se privremeno ne isplaćuje po prijedlogu uprave i N.O." +"9505","kp_rrif9505","kp_rrif950","other","account_type_kapital",,,"Dobitak za manjinske članove društva","Dobitak za manjinske članove društva" +"9506","kp_rrif9506","kp_rrif950","other","account_type_kapital",,,"Dobitak za tajnog člana društva","Dobitak za tajnog člana društva" +"9507","kp_rrif9507","kp_rrif950","other","account_type_kapital",,,"Dobitak za nagrade zaposlenicima","Dobitak za nagrade zaposlenicima" +"9509","kp_rrif9509","kp_rrif950","other","account_type_kapital",,,"Dobitak iz privremenih razlika (odgođeni porezi)","Dobitak iz privremenih razlika (odgođeni porezi)" +"951","kp_rrif951","kp_rrif95","view","account_type_view",,,"Gubitak poslovne godine (analitika po članovima)","Gubitak poslovne godine (analitika po članovima)" +"9510","kp_rrif9510","kp_rrif951","other","account_type_kapital",,,"Gubitak koji se pokriva","Gubitak koji se pokriva" +"9511","kp_rrif9511","kp_rrif951","other","account_type_kapital",,,"Nepokriveni gubitak","Nepokriveni gubitak" +"9512","kp_rrif9512","kp_rrif951","other","account_type_kapital",,,"Gubitak iz privremenih razlika","Gubitak iz privremenih razlika" +"96","kp_rrif96","kp_rrif9","view","account_type_view",,,"MANJINSKI INTERES","MANJINSKI INTERES" +"960","kp_rrif960","kp_rrif96","view","account_type_view",,,"Manjinski interes","Manjinski interes" +"9600","kp_rrif9600","kp_rrif960","other","account_type_kapital",,,"Kapital manjinskog društva (privremeno u postupku konsolidacije kao dio koji nije pod kontrolom matice)","Kapital manjinskog društva (ovaj račun privremeno se rabi u postupku konsolidacije društva kao dio kapitala koji nije pod kontrolom matice)" +"99","kp_rrif99","kp_rrif9","view","account_type_view",,,"IZVANBILANČNI ZAPISI","IZVANBILANČNI ZAPISI" +"990","kp_rrif990","kp_rrif99","view","account_type_view",,,"Imovina - materijalna u optjecaju","Imovina - materijalna u optjecaju" +"9900","kp_rrif9900","kp_rrif990","other","account_type_other",,,"Primljena roba u komisiju i konsignaciju (tuđa)","Primljena roba u komisiju i konsignaciju (tuđa)" +"9901","kp_rrif9901","kp_rrif990","other","account_type_other",,,"Materijal i roba u doradi (tuđa)","Materijal i roba u doradi (tuđa)" +"9902","kp_rrif9902","kp_rrif990","other","account_type_other",,,"Pozajmica strojeva i alata","Pozajmica strojeva i alata" +"9903","kp_rrif9903","kp_rrif990","other","account_type_other",,,"Zaštitna odjeća i obuća na korištenju","Zaštitna odjeća i obuća na korištenju" +"9904","kp_rrif9904","kp_rrif990","other","account_type_other",,,"Roba u skladištu (tuđa)","Roba u skladištu (tuđa)" +"9905","kp_rrif9905","kp_rrif990","other","account_type_other",,,"Ambalaža na korištenju (tuđa)","Ambalaža na korištenju (tuđa)" +"9906","kp_rrif9906","kp_rrif990","other","account_type_other",,,"Vlasništvo ortačke zajednice","Vlasništvo ortačke zajednice" +"9907","kp_rrif9907","kp_rrif990","other","account_type_other",,,"Materijali za doradne - lohn-poslove","Materijali za doradne - lohn-poslove" +"9908","kp_rrif9908","kp_rrif990","other","account_type_other",,,"Roba u izvozu","Roba u izvozu" +"9909","kp_rrif9909","kp_rrif990","other","account_type_other",,,"Zgrade i zemljišta u zakupu","Zgrade i zemljišta u zakupu" +"991","kp_rrif991","kp_rrif99","view","account_type_view",,,"Prava","Prava" +"9910","kp_rrif9910","kp_rrif991","other","account_type_other",,,"Prava na korištenja","Prava na korištenja" +"9911","kp_rrif9911","kp_rrif991","other","account_type_other",,,"Krediti ugovoreni","Krediti ugovoreni" +"9912","kp_rrif9912","kp_rrif991","other","account_type_other",,,"Hipoteka na tuđoj imovini","Hipoteka na tuđoj imovini" +"9913","kp_rrif9913","kp_rrif991","other","account_type_other",,,"Materijalna prava","Materijalna prava" +"9914","kp_rrif9914","kp_rrif991","other","account_type_other",,,"Prava po loro akreditivima (domaći partneri)","Prava po loro akreditivima (domaći partneri)" +"9915","kp_rrif9915","kp_rrif991","other","account_type_other",,,"Prava po loro akreditivima (inozemni partneri)","Prava po loro akreditivima (inozemni partneri)" +"9916","kp_rrif9916","kp_rrif991","other","account_type_other",,,"Prava na ratne reparacije i štete od oduzete imovine","Prava na ratne reparacije i štete od oduzete imovine" +"992","kp_rrif992","kp_rrif99","view","account_type_view",,,"Vrijednosni papiri","Vrijednosni papiri" +"9920","kp_rrif9920","kp_rrif992","other","account_type_other",,,"Primljeni čekovi, mjenice za osiguranje otplate anuiteta za dobivene robne i financijske kredite","Primljeni čekovi, mjenice za osiguranje otplate anuiteta za dobivene robne i financijske kredite" +"9921","kp_rrif9921","kp_rrif992","other","account_type_other",,,"Primljena jamstva vjerovnika kao instrumenata plaćanja","Primljena jamstva vjerovnika kao instrumenata plaćanja" +"9922","kp_rrif9922","kp_rrif992","other","account_type_other",,,"Primljene zadužnice","Primljene zadužnice" +"9923","kp_rrif9923","kp_rrif992","other","account_type_other",,,"Ostali vrijednosni papiri koji nisu stavljeni u optjecaj","Ostali vrijednosni papiri koji nisu stavljeni u optjecaj" +"9924","kp_rrif9924","kp_rrif992","other","account_type_other",,,"Izdane zadužnice","Izdane zadužnice" +"9925","kp_rrif9925","kp_rrif992","other","account_type_other",,,"Izdane mjenice","Izdane mjenice" +"9926","kp_rrif9926","kp_rrif992","other","account_type_other",,,"Korištene garancije u tijeku","Korištene garancije u tijeku" +"9927","kp_rrif9927","kp_rrif992","other","account_type_other",,,"Tražbine od kupaca iz zastupničke prodaje","Tražbine od kupaca iz zastupničke prodaje" +"993","kp_rrif993","kp_rrif99","view","account_type_view",,,"Vrijednosnice u manipulaciji","Vrijednosnice u manipulaciji" +"9930","kp_rrif9930","kp_rrif993","other","account_type_other",,,"Obveznice i druge vrijednosti na skladištu (blagajni)","Obveznice i druge vrijednosti na skladištu (blagajni)" +"9931","kp_rrif9931","kp_rrif993","other","account_type_other",,,"Vrijednosni papiri na čuvanju (obveznice, dionice)","Vrijednosni papiri na čuvanju (obveznice, dionice)" +"9932","kp_rrif9932","kp_rrif993","other","account_type_other",,,"Blokovi ulaznica","Blokovi ulaznica" +"9933","kp_rrif9933","kp_rrif993","other","account_type_other",,,"Prodajna mjesta za izdane obveznice","Prodajna mjesta za izdane obveznice" +"994","kp_rrif994","kp_rrif99","view","account_type_view",,,"Obračun dobitka investicijskog pothvata","Obračun dobitka investicijskog pothvata" +"9940","kp_rrif9940","kp_rrif994","other","account_type_other",,,"Investicija - ulaganje - rashodi","Investicija - ulaganje - rashodi" +"9941","kp_rrif9941","kp_rrif994","other","account_type_other",,,"Prihod - priljev","Prihod - priljev" +"9942","kp_rrif9942","kp_rrif994","other","account_type_other",,,"Dobitak","Dobitak" +"9943","kp_rrif9943","kp_rrif994","other","account_type_other",,,"Porezi i druga davanja","Porezi i druga davanja" +"9944","kp_rrif9944","kp_rrif994","other","account_type_other",,,"Čisti dobitak","Čisti dobitak" +"9947","kp_rrif9947","kp_rrif994","other","account_type_other",,,"Trošak kamata budućeg razdoblja","Trošak kamata budućeg razdoblja" +"995","kp_rrif995","kp_rrif99","view","account_type_view",,,"Izvori materijalne imovine","Izvori materijalne imovine" +"9950","kp_rrif9950","kp_rrif995","other","account_type_other",,,"Obveze prema vlasnicima robe u komisiji i konsignaciji (tuđa sredstva)","Obveze prema vlasnicima robe u komisiji i konsignaciji (tuđa sredstva)" +"9951","kp_rrif9951","kp_rrif995","other","account_type_other",,,"Vlasnici materijala i robe u doradi","Vlasnici materijala i robe u doradi" +"9952","kp_rrif9952","kp_rrif995","other","account_type_other",,,"Vlasnici pozajmljenih strojeva i alata","Vlasnici pozajmljenih strojeva i alata" +"9953","kp_rrif9953","kp_rrif995","other","account_type_other",,,"Skladište zaštitne odjeće i obuće","Skladište zaštitne odjeće i obuće" +"9954","kp_rrif9954","kp_rrif995","other","account_type_other",,,"Vlasnici robe u našim skladištima","Vlasnici robe u našim skladištima" +"9955","kp_rrif9955","kp_rrif995","other","account_type_other",,,"Vlasnici ambalaže u korištenju","Vlasnici ambalaže u korištenju" +"9956","kp_rrif9956","kp_rrif995","other","account_type_other",,,"Ortaci - vlasništvo ortačke zajednice","Ortaci - vlasništvo ortačke zajednice" +"9957","kp_rrif9957","kp_rrif995","other","account_type_other",,,"Obveze za materijale u doradi - lohnu","Obveze za materijale u doradi - lohnu" +"9958","kp_rrif9958","kp_rrif995","other","account_type_other",,,"Obveze za robu u izvozu (tuđa roba)","Obveze za robu u izvozu (tuđa roba)" +"9959","kp_rrif9959","kp_rrif995","other","account_type_other",,,"Vlasnici zemljišta i zgrada u zakupu","Vlasnici zemljišta i zgrada u zakupu" +"996","kp_rrif996","kp_rrif99","view","account_type_view",,,"Izvori prava","Izvori prava" +"9960","kp_rrif9960","kp_rrif996","other","account_type_other",,,"Izvor prava na korištenje","Izvor prava na korištenje" +"9961","kp_rrif9961","kp_rrif996","other","account_type_other",,,"Krediti odobreni","Krediti odobreni" +"9962","kp_rrif9962","kp_rrif996","other","account_type_other",,,"Dužnici po hipoteci","Dužnici po hipoteci" +"9963","kp_rrif9963","kp_rrif996","other","account_type_other",,,"Ulagači u materijalna prava","Ulagači u materijalna prava" +"9964","kp_rrif9964","kp_rrif996","other","account_type_other",,,"Izvori prava loro-akreditiva (domaći partneri)","Izvori prava loro-akreditiva (domaći partneri)" +"9965","kp_rrif9965","kp_rrif996","other","account_type_other",,,"Izvori prava loro-akreditiva (inozemni partneri)","Izvori prava loro-akreditiva (inozemni partneri)" +"9966","kp_rrif9966","kp_rrif996","other","account_type_other",,,"Ratne reparacije i nadoknade šteta","Ratne reparacije i nadoknade šteta" +"9967","kp_rrif9967","kp_rrif996","other","account_type_other",,,"Obveze zastupnika iz prodaje prema nalogodavcu","Obveze zastupnika iz prodaje prema nalogodavcu" +"997","kp_rrif997","kp_rrif99","view","account_type_view",,,"Obveze za vrijednosne papire koji nisu stavljeni u optjecaj","Obveze za vrijednosne papire koji nisu stavljeni u optjecaj" +"9970","kp_rrif9970","kp_rrif997","other","account_type_other",,,"Obveze za čekove i mjenice za osiguranje otplate anuiteta za robne i financijske kredite","Obveze za čekove i mjenice za osiguranje otplate anuiteta za robne i financijske kredite" +"9971","kp_rrif9971","kp_rrif997","other","account_type_other",,,"Jamstva od dužnika kao instrument plaćanja","Jamstva od dužnika kao instrument plaćanja" +"9972","kp_rrif9972","kp_rrif997","other","account_type_other",,,"Obveze za primljene zadužnice","Obveze za primljene zadužnice" +"9973","kp_rrif9973","kp_rrif997","other","account_type_other",,,"Ostali vrijednosni papiri koji nisu stavljeni u optjecaj","Ostali vrijednosni papiri koji nisu stavljeni u optjecaj" +"9974","kp_rrif9974","kp_rrif997","other","account_type_other",,,"Obveze za izdane zadužnice","Obveze za izdane zadužnice" +"9975","kp_rrif9975","kp_rrif997","other","account_type_other",,,"Obveze za izdane mjenice","Obveze za izdane mjenice" +"9976","kp_rrif9976","kp_rrif997","other","account_type_other",,,"Obveze za korištene garancije u tijeku","Obveze za korištene garancije u tijeku" +"998","kp_rrif998","kp_rrif99","view","account_type_view",,,"Obveze za izdane vrijednosnice u manipulaciji","Obveze za izdane vrijednosnice u manipulaciji" +"9980","kp_rrif9980","kp_rrif998","other","account_type_other",,,"Obveznice i druge vrijednosnice","Obveznice i druge vrijednosnice" +"9981","kp_rrif9981","kp_rrif998","other","account_type_other",,,"Vrijednosni papiri (obveznice, dionice)","Vrijednosni papiri (obveznice, dionice)" +"9982","kp_rrif9982","kp_rrif998","other","account_type_other",,,"Vrijednost zalihe blokova ulaznica","Vrijednost zalihe blokova ulaznica" +"9983","kp_rrif9983","kp_rrif998","other","account_type_other",,,"Prodajna mjesta za izdane obveznice","Prodajna mjesta za izdane obveznice" +"9987","kp_rrif9987","kp_rrif998","other","account_type_other",,,"Kamate sadržane u vrijednosnicama ili obračunima","Kamate sadržane u vrijednosnicama ili obračunima" +"999","kp_rrif999","kp_rrif99","view","account_type_view",,,"Obveze s osnove investicijskog pothvata","Obveze s osnove investicijskog pothvata" +"9990","kp_rrif9990","kp_rrif999","other","account_type_other",,,"Obveze prema ulagačima","Obveze prema ulagačima" +"9991","kp_rrif9991","kp_rrif999","other","account_type_other",,,"Izvori prihoda - priljeva","Izvori prihoda - priljeva" +"9992","kp_rrif9992","kp_rrif999","other","account_type_other",,,"Ukalkulirani - planirani dobitak","Ukalkulirani - planirani dobitak" +"9993","kp_rrif9993","kp_rrif999","other","account_type_other",,,"Obveze za porez i druga javna davanja","Obveze za porez i druga javna davanja" +"9994","kp_rrif9994","kp_rrif999","other","account_type_other",,,"Obveze iz planiranog čistog dobitka","Obveze iz planiranog čistog dobitka" diff --git a/addons/l10n_hr/data/account.account.type.csv b/addons/l10n_hr/data/account.account.type.csv new file mode 100644 index 00000000000..35d55039de7 --- /dev/null +++ b/addons/l10n_hr/data/account.account.type.csv @@ -0,0 +1,26 @@ +"name","code","close_method","id","report_type" +"Obveze prema dobavljačima","obveze_dob","unreconciled","account_type_obveze_dob","liability" +"Potraživanja od kupaca","potrazivanja_kup","unreconciled","account_type_potraz_kup","asset" +"Potraživanja za upisani kapital","potraz_kapital","balance","account_type_upis_kapital","asset" +"Dugotrajna imovina","dugotrajna_imovina","balance","account_type_dug_imovina","asset" +"Kratkotrajna imovina","kratkotrajna_imovina","balance","account_type_kratk_imovina","asset" +"Aktivna vrem. Razgraničenja","aktivna_vrem_razgran","balance","account_type_aktiv_razgran","asset" +"Kapital i rezerve","kapital","balance","account_type_kapital","liability" +"Rezerviranja","rezerviranja","balance","account_type_rezervacije","liability" +"Ostalo","other","none","account_type_other","/" +"Sintetika","view","none","account_type_view","/" +"Poslovni prihodi","posl_prihodi","none","account_type_posl_prihod","income" +"Izvanredni prihodi","izv_prihodi","none","account_type_izv_prihod","income" +"Financijski prihodi","fin_prihodi","none","account_type_fin_prihod","income" +"Poslovni rashodi","posl_rashodi","none","account_type_posl_rashod","expense" +"Izvanredni rashodi","izv_rashodi","none","account_type_inv_rashod","expense" +"Financijski rashodi","fin_rashodi","none","account_type_fin_rashod","expense" +"Dugoročne obveze","dugorocne_obveze","balance","account_type_dug_obv","liability" +"Pasivna vrem. Razgraničenja","Pasivna-vrem-razgran","balance","account_type_pas_razgran","liability" +"Kratkoročne obveze","kratkorocne_obveze","balance","account_type_kratk_obveze","liability" +"Obveze za PDV","pdv","balance","account_type_pdv","liability" +"Potraživanja za pretporez","pretporez","balance","account_type_pretporez","asset" +"Aktiva","aktiva","none","account_type_aktiva","asset" +"Pasiva","pasiva","none","account_type_pasiva","liability" +"Prihod","prihod","none","account_type_prihod","income" +"Rashod","rashod","none","account_type_rashod","expense" diff --git a/addons/l10n_hr/data/account.fiscal.position.template.csv b/addons/l10n_hr/data/account.fiscal.position.template.csv new file mode 100644 index 00000000000..aa670628b38 --- /dev/null +++ b/addons/l10n_hr/data/account.fiscal.position.template.csv @@ -0,0 +1,4 @@ +".id","id","account_ids","account_ids/account_dest_id","account_ids/account_dest_id.id","account_ids/account_dest_id/id","account_ids.id","account_ids/position_id","account_ids/position_id.id","account_ids/position_id/id","account_ids/id","account_ids/account_src_id","account_ids/account_src_id.id","account_ids/account_src_id/id","tax_ids","tax_ids.id","tax_ids/position_id","tax_ids/id","tax_ids/tax_src_id","tax_ids/tax_src_id.id","tax_ids/tax_src_id/id","tax_ids/tax_dest_id","tax_ids/tax_dest_id.id","tax_ids/tax_dest_id/id","name","chart_template_id","chart_template_id.id","chart_template_id/id" +"1","__export__.account_fiscal_position_template_1","","","","","","","","","","","","","","","","","","","","","","","Domaći R1 partneri","RRIF-ov računski plan za poduzetnike","3","l10n_hr.l10n_hr_chart_template_rrif" +"2","__export__.account_fiscal_position_template_2","R2 partneri,R2 partneri","1200 Potraživanja od kupaca dobara","5026","l10n_hr.kp_rrif1200","1","R2 partneri","2","__export__.account_fiscal_position_template_2","__export__.account_fiscal_position_account_template_1","1200 Potraživanja od kupaca dobara","5026","l10n_hr.kp_rrif1200","R2 partneri,R2 partneri,R2 partneri,R2 partneri","1","R2 partneri","__export__.account_fiscal_position_tax_template_1","PDV 25%","94","l10n_hr.rrif_pdv_25","PDV 25%","94","l10n_hr.rrif_pdv_25","R2 partneri","RRIF-ov računski plan za poduzetnike","3","l10n_hr.l10n_hr_chart_template_rrif" +"3","__export__.account_fiscal_position_template_3","Inozemni,Inozemni","1210 Kupci dobara iz inozemstva","5037","l10n_hr.kp_rrif1210","3","Inozemni","3","__export__.account_fiscal_position_template_3","__export__.account_fiscal_position_account_template_3","1200 Potraživanja od kupaca dobara","5026","l10n_hr.kp_rrif1200","Inozemni,Inozemni,Inozemni,Inozemni","5","Inozemni","__export__.account_fiscal_position_tax_template_5","PDV 25%","94","l10n_hr.rrif_pdv_25","2.1. IZVOZNE - s pravom na odbit","109","l10n_hr.rrif_pdv_osl_izvoz_0","Inozemni","RRIF-ov računski plan za poduzetnike","3","l10n_hr.l10n_hr_chart_template_rrif" diff --git a/addons/l10n_hr/data/account.tax.code.template.csv b/addons/l10n_hr/data/account.tax.code.template.csv new file mode 100644 index 00000000000..aa5968b556f --- /dev/null +++ b/addons/l10n_hr/data/account.tax.code.template.csv @@ -0,0 +1,78 @@ +"id","code","sign","name","parent_id:id","info" +"pdv_code_porezi",,1,"POREZI",, +"pdv_code_nepdv","NEPDV",1,"Ostali porezi, carine, trošarine i sl.","pdv_code_porezi", +"pdv_code_pdv","PDV",0,"PDV","pdv_code_porezi", +"pdv_code_pdvob","PDVOB",0,"OBRAZAC PDV","pdv_code_pdv", +"pdv_code_opdvob","oPDVOB",0,"O S N O V I C A","pdv_code_pdvob","IV. UKUPNA POREZNA OBVEZA ZA POREZNO RAZDOBLJE:ZA UPLATU (II. - III.)" +"pdv_code_o1_2","o1+2",0,"Obračun isporuka (I+II)","pdv_code_opdvob","OBRAČUN POREZA U OBAVLJENIM ISPORUKAMA DOBARA I USLUGA U OBRAČUNSKOM RAZDOBLJU ISPORUKE – UKUPNO (I. + II.)" +"pdv_code_o1","o100",1,"I. Isporuke ne podliježu / oslobođene","pdv_code_o1_2","I. ISPORUKE KOJE NE PODLIJEŽU OPOREZIVANJU, KOJE SU OSLOBOĐENE I PO STOPI OD 0% - UKUPNO (1.+2.+3.)" +"pdv_code_o11","o110",1,"I.1. Koje ne podliježu oporezivanju","pdv_code_o1","1. KOJE NE PODLIJEŽU OPOREZIVANJU (čl. 2. u svezi s čl. 5. i čl. 8. st. 7. Zakona)" +"pdv_code_o12","o120",1,"I.2. Oslobođene ukupno","pdv_code_o1","2. OSLOBOĐENE POREZA – UKUPNO (2.1.+2.2.+2.3.+2.4.)" +"pdv_code_o121","o121",1,"I.2.1. Izvozne","pdv_code_o12","2.1. IZVOZNE – s pravom na odbitak pretporeza (čl. 13. st. 1. toč. 1. i čl. 14. Zakona )" +"pdv_code_o122","o122",1,"I.2.2. Isporuke dobara","pdv_code_o12","2.2. Isporuke dobara - za koje nije bio moguć odbitak pretporeza (čl. 11.b Zakona)" +"pdv_code_o123","o123",1,"I.2.3. Tuzemne - bez prava odbitka","pdv_code_o12","2.3. TUZEMNE – bez prava na odbitak pretporeza (čl. 11. i čl. 11.a Zakona)" +"pdv_code_o124","o124",1,"I.2.4. Ostale – s pravom odbitka","pdv_code_o12","2.4. OSTALE – s pravom na odbitak pretporeza (čl. 13. st. 1. toč. 2., čl. 13 a i čl. 13.b Zakona)" +"pdv_code_o13","o130",1,"I.3. Isporuke po stopi od 0%","pdv_code_o1","3. ISPORUKE PO STOPI OD 0% (čl. 10.a. Zakona)" +"pdv_code_o2","o200",1,"II. Oporezive isporuke","pdv_code_o1_2","II. OPOREZIVE ISPORUKE – UKUPNO (1.+2.+3.+4.)" +"pdv_code_o21","o210",1,"II.1 Izdani računi po stopi 10%","pdv_code_o2","1. ZA KOJE SU IZDANI RAČUNI I NEZARAČUNANE(čl. 2. st. 1. toč. 1a. i 1b., čl. 3. st. 5., čl. 4. st. 4., čl. 7. st. 1. i 4. i čl. 15. st. 8. Zakona) po stopi od 10%" +"pdv_code_o22","o220",1,"II.2 Izdani računi po stopi 22% i 23%","pdv_code_o2","2. ZA KOJE SU IZDANI RAČUNI I NEZARAČUNANE (čl. 2., čl. 7. st. 1. i 4. i čl. 15. st. 8. Zakona) po stopi od 22% i 23%" +"pdv_code_o23","o230",1,"II.3 Izdani računi po stopi 25%","pdv_code_o2","3. ZA KOJE SU IZDANI RAČUNI I NEZARAČUNANE(čl. 2. st. 1. toč. 1a. i 1b., čl. 3. st. 5., čl. 4. st. 4., čl. 7. st. 1. i 4.,čl. 15. st. 8., čl. 22.a i čl. 22.c Zakona) po stopi od 25%" +"pdv_code_o24","o240",1,"II.4 Nenaplaćeni izvoz","pdv_code_o2","4. NAKNADNO OSLOBOĐENJE IZVOZA U OKVIRU OSOBNOG PUTNIČKOG PROMETA (čl. 13. st. 1. toč. 4. Zakona)" +"pdv_code_o25","o250",1,"II.5 Oslobođenje izvoza – putnički promet","pdv_code_o2","4. NAKNADNO OSLOBOĐENJE IZVOZA U OKVIRU OSOBNOG PUTNIČKOG PROMETA (čl. 13. st. 1. toč. 4. Zakona)" +"pdv_code_o3","o300",0,"III. OBRAČUNANI PRETPOREZ","pdv_code_opdvob","III. OBRAČUNANI PRETPOREZ U PRIMLJENIM ISPORUKAMA DOBARA I USLUGA – UKUPNO (1.+2.+3.+4.+ 5.+6.+7.+8.)" +"pdv_code_o31","o310",1,"III.1. Pretporez 10%","pdv_code_o3","1. PRETPOREZ U PRIMLJENIM RAČUNIMA (čl. 20. st. 1., 9., 10. i 11. Zakona) po stopi od 10%" +"pdv_code_o32","o320",1,"III.2. Pretporez 22% i23%","pdv_code_o3","2. PRETPOREZ U PRIMLJENIM RAČUNIMA (čl. 20. st. 1., 9. i 10. Zakona) po stopi od 22% i 23%" +"pdv_code_o33","o330",1,"III.3. Pretporez 25%","pdv_code_o3","3. PRETPOREZ U PRIMLJENIM RAČUNIMA (čl. 20. st. 1., 9., 10., 11. i 12. Zakona) po stopi od 25%" +"pdv_code_o34","o340",1,"III.4. Plaćeni PP pri uvozu","pdv_code_o3","4. PLAĆENI PRETPOREZ PRI UVOZU (čl. 20. st. 2. odnosno čl. 7. st. 5. Zakona)" +"pdv_code_o35","o350",1,"III.5. Plaćeni PP na ino usluge 10%","pdv_code_o3","5. PLAĆENI PRETPOREZ NA USLUGE INOZEMNIH PODUZETNIKA (čl. 19. st. 2. Zakona) po stopi od 10%" +"pdv_code_o36","o360",1,"III.6. Plaćeni PP na ino usluge 22% i 23%","pdv_code_o3","6. PLAĆENI PRETPOREZ NA USLUGE INOZEMNIH PODUZETNIKA (čl. 19. st. 2. Zakona) po stopi od 22% i 23%" +"pdv_code_o37","o370",1,"III.7. Plaćeni PP na ino usluge 25%","pdv_code_o3","7. PLAĆENI PRETPOREZ NA USLUGE INOZEMNIH PODUZETNIKA (čl. 19. st. 2. Zakona) po stopi od 25%" +"pdv_code_o391","o391",1,"III.0. Pretporez 0%","pdv_code_o3","7.? PLAĆENI PRETPOREZ NA USLUGE INOZEMNIH PODUZETNIKA (čl. 19. st. 2. Zakona) po stopi od 25%" +"pdv_code_zpdv","zPDV",1,"PDV - OSTALO","pdv_code_pdv","Ostali podaci" +"pdv_code_z9","z900",1,"NEPRIZNATI PRETPOREZ ","pdv_code_zpdv", +"pdv_code_o91","o910",1,"NEPRIZNATI PRETPOREZ (osnovica 30 ili 70%)","pdv_code_z9","NP. NEPRIZNATI PRETPOREZ U PRIMLJENIM ISPORUKAMA DOBARA I USLUGA " +"pdv_code_o911","o911",1,"Nepriznati pretporez 10% (o)","pdv_code_o91","NP.1. NEPRIZNATI PRETPOREZ U PRIMLJENIM RAČUNIMA po stopi od 10%" +"pdv_code_o912","o912",1,"Nepriznati pretporez 22% i 23% (o)","pdv_code_o91","NP.2. NEPRIZNATI PRETPOREZ U PRIMLJENIM RAČUNIMA po stopi od 22% i 23%" +"pdv_code_o913","o913",1,"Nepriznati pretporez 25% (o)","pdv_code_o91","NP.3.NEPRIZNATI PRETPOREZ U PRIMLJENIM RAČUNIMA po stopi od 25%" +"pdv_code_o92","o920",1,"Pretporez koji još nije priznan (uključivo i neplaćeni R-2)","pdv_code_z9", +"pdv_code_o7","o700",1,"Ostali podaci","pdv_code_zpdv","Ostali podaci" +"pdv_code_o71","o710",1,"1. ZA ISPRAVAK PRETPOREZA","pdv_code_o7","1. ZA ISPRAVAK PRETPOREZA (UKUPNO 1.1.+1.2.+1.3.+1.4.+1.5.+1.6.)" +"pdv_code_oop11","o711",1,"1.1. NABAVA NEKRETNINA","pdv_code_o71","1.1. NABAVA NEKRETNINA – ISPORUČITELJ (PRODAVATELJ) NEKRETNINA" +"pdv_code_oop12","o712",1,"1.2. PRODAJA NEKRETNINA","pdv_code_o71","1.2. PRODAJA NEKRETNINA – PRIMATELJ (KUPAC) NEKRETNINA" +"pdv_code_oop13","o713",1,"1.3. NABAVA OSOBNIH VOZILA","pdv_code_o71","1.3. NABAVA OSOBNIH VOZILA (ZA PODUZETNIKE KOJIMA TRGOVINA AUTOMOBILIMA NIJE TEMELJNA DJELATNOST)" +"pdv_code_oop14","o714",1,"1.4. PRODAJA OSOBNIH VOZILA","pdv_code_o71","1.4. PRODAJA OSOBNIH VOZILA (ZA PODUZETNIKE KOJIMA TRGOVINA AUTOMOBILIMA NIJE TEMELJNA DJELATNOST)" +"pdv_code_oop15","o715",1,"1.5. NABAVA DUGOTRAJNE IMOVINE","pdv_code_o71","1.5. NABAVA OSTALE DUGOTRAJNE IMOVINE" +"pdv_code_oop16","o716",1,"1.6. PRODAJA DUGOTRAJNE IMOVINE","pdv_code_o71","1.6. PRODAJA OSTALE DUGOTRAJNE IMOVINE" +"pdv_code_oop2","o720",1,"2. OTUĐENJE/STJECANJE GOSPODARSKE CJELINE ILI POGONA","pdv_code_o7","2. OTUĐENJE/STJECANJE GOSPODARSKE CJELINE ILI POGONA" +"pdv_code_oop3","o730",1,"3. NABAVA DOBARA I USLUGA ZA REPREZENTACIJU","pdv_code_o7","3. NABAVA DOBARA I USLUGA ZA REPREZENTACIJU" +"pdv_code_oop4","o740",1,"4. NABAVA OSOBNIH VOZILA I DRUGIH SREDSTAVA ZA OSOBNI PRIJEVOZ ","pdv_code_o7","4. NABAVA OSOBNIH VOZILA I DRUGIH SREDSTAVA ZA OSOBNI PRIJEVOZ TE DOBARA I USLUGA POVEZANIH S TIM DOBRIMA" +"pdv_code_oop5","o750",1,"5. OSNOVICA ZA OBRAČUN VLASTITE POTROŠNJE ZA OSOBNA VOZILA NABAV","pdv_code_o7","5. OSNOVICA ZA OBRAČUN VLASTITE POTROŠNJE ZA OSOBNA VOZILA NABAVLJENA DO 31.12.2009." +"pdv_code_p6","pPDV",0,"PDV – POREZ – razlika za uplatu/preplata","pdv_code_pdvob", +"pdv_code_p5","p500",-1,"Uplaćeno u razdoblju","pdv_code_p6", +"pdv_code_p4","p400",1,"VI. POREZNA OBVEZA U RAZDOBLJU","pdv_code_p6","IV. UKUPNA POREZNA OBVEZA ZA POREZNO RAZDOBLJE:ZA UPLATU (II. - III.)" +"pdv_code_p1","p100",1,"I. Isporuke ne podliježu / oslobođene","pdv_code_p4","I. ISPORUKE KOJE NE PODLIJEŽU OPOREZIVANJU, KOJE SU OSLOBOĐENE I PO STOPI OD 0% - UKUPNO (1.+2.+3.)" +"pdv_code_p2","p200",1,"II. Oporezive isporuke","pdv_code_p4","II. OPOREZIVE ISPORUKE – UKUPNO (1.+2.+3.+4.)" +"pdv_code_p21","p210",1,"II.1 Izdani računi po stopi 10%","pdv_code_p2","1. ZA KOJE SU IZDANI RAČUNI I NEZARAČUNANE(čl. 2. st. 1. toč. 1a. i 1b., čl. 3. st. 5., čl. 4. st. 4., čl. 7. st. 1. i 4. i čl. 15. st. 8. Zakona) po stopi od 10%" +"pdv_code_p22","p220",1,"II.2 Izdani računi po stopi 22% i 23%","pdv_code_p2","2. ZA KOJE SU IZDANI RAČUNI I NEZARAČUNANE (čl. 2., čl. 7. st. 1. i 4. i čl. 15. st. 8. Zakona) po stopi od 22% i 23%" +"pdv_code_p23","p230",1,"II.3 Izdani računi po stopi 25%","pdv_code_p2","3. ZA KOJE SU IZDANI RAČUNI I NEZARAČUNANE(čl. 2. st. 1. toč. 1a. i 1b., čl. 3. st. 5., čl. 4. st. 4., čl. 7. st. 1. i 4.,čl. 15. st. 8., čl. 22.a i čl. 22.c Zakona) po stopi od 25%" +"pdv_code_p24","p240",1,"II.4 Oslobođenje izvoza – putnički promet","pdv_code_p2","4. NAKNADNO OSLOBOĐENJE IZVOZA U OKVIRU OSOBNOG PUTNIČKOG PROMETA (čl. 13. st. 1. toč. 4. Zakona)" +"pdv_code_p3","p300",-1,"III. OBRAČUNANI PRETPOREZ","pdv_code_p4","III. OBRAČUNANI PRETPOREZ U PRIMLJENIM ISPORUKAMA DOBARA I USLUGA – UKUPNO (1.+2.+3.+4.+ 5.+6.+7.+8.)" +"pdv_code_p31","p310",1,"III.1. Pretporez 10%","pdv_code_p3","1. PRETPOREZ U PRIMLJENIM RAČUNIMA (čl. 20. st. 1., 9., 10. i 11. Zakona) po stopi od 10%" +"pdv_code_p32","p320",1,"III.2. Pretporez 22% i 23%","pdv_code_p3","2. PRETPOREZ U PRIMLJENIM RAČUNIMA (čl. 20. st. 1., 9. i 10. Zakona) po stopi od 22% i 23%" +"pdv_code_p33","p330",1,"III.3. Pretporez 25%","pdv_code_p3","3. PRETPOREZ U PRIMLJENIM RAČUNIMA (čl. 20. st. 1., 9., 10., 11. i 12. Zakona) po stopi od 25%" +"pdv_code_p34","p340",1,"III.4. Plaćeni PP pri uvozu","pdv_code_p3","4. PLAĆENI PRETPOREZ PRI UVOZU (čl. 20. st. 2. odnosno čl. 7. st. 5. Zakona)" +"pdv_code_p35","p350",1,"III.5. Plaćeni PP na ino usluge 10%","pdv_code_p3","5. PLAĆENI PRETPOREZ NA USLUGE INOZEMNIH PODUZETNIKA (čl. 19. st. 2. Zakona) po stopi od 10%" +"pdv_code_p36","p360",1,"III.6. Plaćeni PP na ino usluge 22% i 23%","pdv_code_p3","6. PLAĆENI PRETPOREZ NA USLUGE INOZEMNIH PODUZETNIKA (čl. 19. st. 2. Zakona) po stopi od 22% i 23%" +"pdv_code_p37","p370",1,"III.7. Plaćeni PP na ino usluge 25%","pdv_code_p3","7. PLAĆENI PRETPOREZ NA USLUGE INOZEMNIH PODUZETNIKA (čl. 19. st. 2. Zakona) po stopi od 25%" +"pdv_code_p38","p380",1,"III.8. Ispravci pretporeza","pdv_code_p3","8. ISPRAVCI PRETPOREZA (čl. 20. st. 5. Zakona)" +"pdv_code_p9","p900",0,"NEPRIZNATI PRETPOREZ (porez)","pdv_code_z9","NP. NEPRIZNATI PRETPOREZ U PRIMLJENIM ISPORUKAMA DOBARA I USLUGA " +"pdv_code_p91","p910",1,"NEPRIZNATI PRETPOREZ (30 ili 70%)","pdv_code_p9","NP. NEPRIZNATI PRETPOREZ U PRIMLJENIM ISPORUKAMA DOBARA I USLUGA " +"pdv_code_p911","p911",1,"Nepriznati pretporez 10% (p)","pdv_code_p91","NP.1. NEPRIZNATI PRETPOREZ U PRIMLJENIM RAČUNIMA po stopi od 10%" +"pdv_code_p912","p912",1,"Nepriznati pretporez 22% i 23% (p)","pdv_code_p91","NP.2. NEPRIZNATI PRETPOREZ U PRIMLJENIM RAČUNIMA po stopi od 22% i 23%" +"pdv_code_p913","p913",1,"Nepriznati pretporez 25% (p)","pdv_code_p91","NP.3.NEPRIZNATI PRETPOREZ U PRIMLJENIM RAČUNIMA po stopi od 25%" +"pdv_code_p92","p920",1,"Pretporez koji još nije priznan (ukupno)","pdv_code_z9","Pretporez koji još nije priznan (ukupno)" +"pdv_code_p9201","p9201",1,"Pretporez koji još nije priznan (neplaćeni R2)","pdv_code_p92","Pretporez koji još nije priznan (neplaćeni R2)" +"pdv_code_p9202","p9202",1,"Pretporez koji još nije priznan (neplaćeni UVOZ dobara 25%)","pdv_code_p92","Pretporez koji još nije priznan (neplaćeni UVOZ dobara 25%)" +"pdv_code_p9203","p9203",1,"Pretporez koji još nije priznan (neplaćene INO usluge 25%)","pdv_code_p92","Pretporez koji još nije priznan (neplaćene INO usluge 25%)" +"pdv_code_p9204","p9204",1,"Pretporez koji još nije priznan (neplaćene INO usluge 10%)","pdv_code_p92","Pretporez koji još nije priznan (neplaćene INO usluge 10%)" +"pdv_code_potrosnja","POTROSNJA",1,"Porez na potrošnju","pdv_code_nepdv","Porez na potrošnju" diff --git a/addons/l10n_hr/data/account.tax.template.csv b/addons/l10n_hr/data/account.tax.template.csv new file mode 100644 index 00000000000..7289e25a5e3 --- /dev/null +++ b/addons/l10n_hr/data/account.tax.template.csv @@ -0,0 +1,62 @@ +"id","description","chart_template_id:id","name","amount","child_ids:id","parent_id:id","child_depend","type","account_collected_id:id","account_paid_id:id","type_tax_use","base_code_id:id","tax_code_id:id","ref_base_code_id:id","ref_tax_code_id:id","ref_tax_sign","tax_sign","base_sign","ref_base_sign","sequence" +"rrif_pdv_25","PDV 25%","l10n_hr_chart_template_rrif","25% PDV","0.25",,,"False","percent","kp_rrif24003","kp_rrif24003","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","10" +"rrif_pdv_25usl","PDV 25% Usluge","l10n_hr_chart_template_rrif","25% PDV usluge","0.25",,,"False","percent","kp_rrif24003","kp_rrif24003","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" +"rrif_pdv_23","PDV 23%","l10n_hr_chart_template_rrif","23% PDV","0.23",,,"False","percent","kp_rrif24002","kp_rrif24002","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" +"rrif_pdv_23usl","PDV 23% Usluge","l10n_hr_chart_template_rrif","23% PDV usluge","0.23",,,"False","percent","kp_rrif24002","kp_rrif24002","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" +"rrif_pdv_10","PDV 10%","l10n_hr_chart_template_rrif","10% PDV","0.10",,,"False","percent","kp_rrif24000","kp_rrif24000","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" +"rrif_pdv_0","PDV 0%","l10n_hr_chart_template_rrif","0% PDV","0.00",,,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_avans_25","PDV za predujam 25%","l10n_hr_chart_template_rrif","25% PDV (za predujam)","0.25",,,"False","percent","kp_rrif24013","kp_rrif24013","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" +"rrif_pdv_avans_23","PDV za predujam 23%","l10n_hr_chart_template_rrif","23% PDV (za predujam)","0.23",,,"False","percent","kp_rrif24012","kp_rrif24012","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" +"rrif_pdv_avans_10","PDV za predujam 10%","l10n_hr_chart_template_rrif","10% PDV (za predujam)","0.10",,,"False","percent","kp_rrif24010","kp_rrif24010","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" +"rrif_pdv_avans_0","PDV za predujam 0%","l10n_hr_chart_template_rrif","0% PDV (za predujam)","0.00",,,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_nezar_isp_25","PDV po nezaračunanim isporukama 25%","l10n_hr_chart_template_rrif","25% PDV za nezaračunane isp.","0.25",,,"False","percent","kp_rrif24033","kp_rrif24033","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" +"rrif_pdv_nezar_isp_23","PDV po nezaračunanim isporukama 23%","l10n_hr_chart_template_rrif","23% PDV za nezaračunane isp.","0.23",,,"False","percent","kp_rrif24032","kp_rrif24032","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" +"rrif_pdv_nezar_isp_10","PDV po nezaračunanim isporukama 10%","l10n_hr_chart_template_rrif","10% PDV za nezaračunane isp.","0.10",,,"False","percent","kp_rrif24030","kp_rrif24030","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" +"rrif_pdv_nezar_isp_0","PDV po nezaračunanim isporukama 0%","l10n_hr_chart_template_rrif","0% PDV za nezaračunane isp.","0.00",,,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_nepod_0","1. KOJE NE PODLIJEŽU OPOREZIVANJU (čl. 2. u svezi s čl. 5 i čl. 8 st. 7 Zakona)","l10n_hr_chart_template_rrif","0% Ne podliježe op.","0.00",,,"False","percent",,,"sale","pdv_code_o11",,"pdv_code_o11",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_izvoz_0","2.1. IZVOZNE - s pravom na odbitak pretporeza (čl. 13. st. 1. toč. 1. i čl. 14. Zakona)","l10n_hr_chart_template_rrif","0% osl. izvozne","0.00",,,"False","percent",,,"sale","pdv_code_o121",,"pdv_code_o121",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_medpri_0","2.2. U VEZI S MEĐUNARODNIM PRIJEVOZOM (čl. 13.b Zakona)","l10n_hr_chart_template_rrif","0% osl. međ. prijevoz","0.00",,,"False","percent",,,"sale","pdv_code_o122",,"pdv_code_o122",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_tuz_0","2.3. TUZEMNE - bez prava na odbitak pretporeza (čl. 11. i čl. 11a Zakona)","l10n_hr_chart_template_rrif","0% osl tuzemne","0.00",,,"False","percent",,,"sale","pdv_code_o123",,"pdv_code_o123",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_ost_0","2.4. OSTALO (čl. 13. st. 1. toč. 2. I čl. 13a Zakona) ","l10n_hr_chart_template_rrif","0% osl. ostalo","0.00",,,"False","percent",,,"sale","pdv_code_o124",,"pdv_code_o124",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_25","Pretporez 25% PDV","l10n_hr_chart_template_rrif","25% PDV pretporez","0.25",,,"False","percent","kp_rrif14003","kp_rrif14003","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","10" +"rrif_pp_25usl","Pretporez 25% PDV Usluge","l10n_hr_chart_template_rrif","25% PDV pretporez usluge","0.25",,,"False","percent","kp_rrif14003","kp_rrif14003","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_pp_23","Pretporez 23% PDV","l10n_hr_chart_template_rrif","23% PDV pretporez","0.23",,,"False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o32","pdv_code_p32","pdv_code_o32","pdv_code_p32","1.0","1.0","1.0","1.0","100" +"rrif_pp_23usl","Pretporez 23% PDV Usluge","l10n_hr_chart_template_rrif","23% PDV pretporez usluge","0.23",,,"False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o32","pdv_code_p32","pdv_code_o32","pdv_code_p32","1.0","1.0","1.0","1.0","100" +"rrif_pp_10","Pretporez 10% PDV","l10n_hr_chart_template_rrif","10% PDV pretporez","0.10",,,"False","percent","kp_rrif14000","kp_rrif14000","purchase","pdv_code_o31","pdv_code_p31","pdv_code_o31","pdv_code_p31","1.0","1.0","1.0","1.0","100" +"rrif_pp_0","Pretporez 0% PDV","l10n_hr_chart_template_rrif","0% PDV pretporez","0.00",,,"False","percent",,,"purchase","pdv_code_o391",,"pdv_code_o391",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_avans_25","Pretporez za predujam 25% PDV","l10n_hr_chart_template_rrif","25% PDV pretporez za predujam","0.25",,,"False","percent","kp_rrif14013","kp_rrif14013","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_pp_avans_23","Pretporez za predujam 23% PDV","l10n_hr_chart_template_rrif","23% PDV pretporez za predujam","0.23",,,"False","percent","kp_rrif14012","kp_rrif14012","purchase","pdv_code_o32","pdv_code_p32","pdv_code_o32","pdv_code_p32","1.0","1.0","1.0","1.0","100" +"rrif_pp_avans_10","Pretporez za predujam 10% PDV","l10n_hr_chart_template_rrif","10% PDV pretporez za predujam","0.10",,,"False","percent","kp_rrif14010","kp_rrif14010","purchase","pdv_code_o31","pdv_code_p31","pdv_code_o31","pdv_code_p31","1.0","1.0","1.0","1.0","100" +"rrif_pp_avans_0","Pretporez za predujam 0% PDV","l10n_hr_chart_template_rrif","0% PDV pretporez za predujam","0.00",,,"False","percent",,,"purchase","pdv_code_o391",,"pdv_code_o391",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_25","Plaćeni PDV 25% pri uvozu dobara","l10n_hr_chart_template_rrif","25% uvoz dobara","0.25",,,"False","percent","kp_rrif14023","kp_rrif14023","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_23","Plaćeni PDV 23% pri uvozu dobara","l10n_hr_chart_template_rrif","23% uvoz dobara","0.23",,,"False","percent","kp_rrif14022","kp_rrif14022","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_10","Plaćeni PDV 10% pri uvozu dobara","l10n_hr_chart_template_rrif","10% uvoz dobara","0.10",,,"False","percent","kp_rrif14020","kp_rrif14020","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_0","Plaćeni PDV 0% pri uvozu dobara","l10n_hr_chart_template_rrif","0% uvoz dobara","0.00",,,"False","percent",,,"purchase","pdv_code_o34",,"pdv_code_o34",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_ino_25","Plaćeni PDV 25% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","25% ino. usluge","0.25",,,"False","percent","kp_rrif14033","kp_rrif14033","purchase","pdv_code_o37","pdv_code_p37","pdv_code_o34","pdv_code_o37","1.0","1.0","1.0","1.0","100" +"rrif_pp_ino_23","Plaćeni PDV 23% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","23% ino. usluge","0.23",,,"False","percent","kp_rrif14032","kp_rrif14032","purchase","pdv_code_o36","pdv_code_p36","pdv_code_o34","pdv_code_o37","1.0","1.0","1.0","1.0","100" +"rrif_pp_ino_10","Plaćeni PDV 10% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","10% ino. usluge","0.10",,,"False","percent","kp_rrif14030","kp_rrif14030","purchase","pdv_code_o35","pdv_code_p35","pdv_code_o34","pdv_code_o35","1.0","1.0","1.0","1.0","100" +"rrif_pp_R2_25","25% R-2 dobavljač","l10n_hr_chart_template_rrif","25% R-2 dobavljač","0.25",,,"False","percent","kp_rrif1409","kp_rrif1409","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" +"rrif_pp_R2_23","23% R-2 dobavljač","l10n_hr_chart_template_rrif","23% R-2 dobavljač","0.23",,,"False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_samopdv_25","Samo PDV kod uvoza 25%","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 25%","0.25",,,"False","percent",,,"purchase","pdv_code_o913","pdv_code_p9202","pdv_code_o913","pdv_code_p9202","-1.0","-1.0","-1.0","-1.0","100" +"rrif_pp_uvoz_samopdv_25usl","Samo PDV kod uvoza 25% usluge","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 25% usluge","0.25",,,"False","percent",,,"purchase","pdv_code_o913","pdv_code_p9203","pdv_code_o913","pdv_code_p9203","-1.0","-1.0","-1.0","-1.0","100" +"rrif_pp_uvoz_samopdv_23","Samo PDV kod uvoza 23%","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 23%","0.23",,,"False","percent",,,"purchase","pdv_code_o912","pdv_code_p9203","pdv_code_o912","pdv_code_p9203","-1.0","-1.0","-1.0","-1.0","100" +"rrif_ppdnp1_3070_1","pp 30% Nepriznat 70% Priznat","l10n_hr_chart_template_rrif","pp 30% Nepriznat 70% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_2","pp 30% nepriznat","l10n_hr_chart_template_rrif","pp 30% nepriznat","0.30",,"rrif_ppdnp1_3070_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_3","pp 30% nep.(25%)","l10n_hr_chart_template_rrif","pp 30% nep.(25%)","0.25",,"rrif_ppdnp1_3070_30_2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_2","pp 70% priznat","l10n_hr_chart_template_rrif","Pp 70% priznat","0.70",,"rrif_ppdnp1_3070_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_3","pp 70% priz.(25%)","l10n_hr_chart_template_rrif","Pp 70% priz.(25%)","0.25",,"rrif_ppdnp1_3070_70_2","False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_1","pp 70% Nepriznat 30% Priznat","l10n_hr_chart_template_rrif","pp 70% Nepriznat 30% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_2","Pp 70% nepriznat","l10n_hr_chart_template_rrif","Pp 70% nepriznat","0.70",,"rrif_ppdnp1_7030_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_3","Pp 70% nep.(25%)","l10n_hr_chart_template_rrif","Pp 70% nep.(25%)","0.25",,"rrif_ppdnp1_7030_70_2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_2","Pp 30% priznat","l10n_hr_chart_template_rrif","Pp 30% priznat","0.30",,"rrif_ppdnp1_7030_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_3","Pp 30% priz.(25%)","l10n_hr_chart_template_rrif","Pp 30% priz.(25%)","0.25",,"rrif_ppdnp1_7030_30_2","False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_1_r2","R2 pp 30% Nepriznat 70% Priznat","l10n_hr_chart_template_rrif","R2 pp 30% Nepriznat 70% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_2_r2","R2 pp 30% nepriznat","l10n_hr_chart_template_rrif","R2 pp 30% nepriznat","0.30",,"rrif_ppdnp1_3070_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_3_r2","R2 pp 30% nep.(25%)","l10n_hr_chart_template_rrif","R2 pp 30% nep.(25%)","0.25",,"rrif_ppdnp1_3070_30_2_r2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_2_r2","R2 pp 70% priznat","l10n_hr_chart_template_rrif","R2 pp 70% priznat","0.70",,"rrif_ppdnp1_3070_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_3_r2","R2 pp 70% priz.(25%)","l10n_hr_chart_template_rrif","R2 pp 70% priz.(25%)","0.25",,"rrif_ppdnp1_3070_70_2_r2","False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_1_r2","R2 pp 70% Nepriznat 30% Priznat","l10n_hr_chart_template_rrif","R2 pp 70% Nepriznat 30% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_2_r2","R2 Pp 70% nepriznat","l10n_hr_chart_template_rrif","R2 Pp 70% nepriznat","0.70",,"rrif_ppdnp1_7030_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_3_r2","R2 Pp 70% nep.(25%)","l10n_hr_chart_template_rrif","R2 Pp 70% nep.(25%)","0.25",,"rrif_ppdnp1_7030_70_2_r2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_2_r2","R2 Pp 30% priznat","l10n_hr_chart_template_rrif","R2 Pp 30% priznat","0.30",,"rrif_ppdnp1_7030_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_3_r2","R2 Pp 30% priz.(25%)","l10n_hr_chart_template_rrif","R2 Pp 30% priz.(25%)","0.25",,"rrif_ppdnp1_7030_30_2_r2","False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" diff --git a/addons/l10n_hr/data/fiscal_position.xml b/addons/l10n_hr/data/fiscal_position.xml new file mode 100644 index 00000000000..df91a120a8b --- /dev/null +++ b/addons/l10n_hr/data/fiscal_position.xml @@ -0,0 +1,68 @@ + + + + + + R1 partneri + + + + + + + R2 partneri + + + + + + + + + + + + + + + + + + + + + + Inozemni + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/addons/l10n_hr/data/fiscal_position.xml.backup b/addons/l10n_hr/data/fiscal_position.xml.backup new file mode 100644 index 00000000000..8386a0d9808 --- /dev/null +++ b/addons/l10n_hr/data/fiscal_position.xml.backup @@ -0,0 +1,139 @@ + + + + + Bescarinska zona + + + + + + + + + + + + + + + + Domaći partneri R2 + + + + + + + + + + + Domaći partneri R1 + + + + + Strani partneri + + + + + + + + + + + + + + + + + + + + + + + + + Domaći partneri izvan sustava PDV-a + + + + + + + + + + + + + Carinska uprava + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/addons/l10n_hr/i18n/hr.po b/addons/l10n_hr/i18n/hr.po new file mode 100644 index 00000000000..9f7c1848ee1 --- /dev/null +++ b/addons/l10n_hr/i18n/hr.po @@ -0,0 +1,149 @@ +# Translation of OpenERP Server. +# This file contains the translation of the following modules: +# * l10n_hr +# +msgid "" +msgstr "" +"Project-Id-Version: OpenERP Server 6.1\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-03-20 18:16+0000\n" +"PO-Revision-Date: 2012-03-20 18:16+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pasiva +msgid "Pasiva" +msgstr "Pasiva" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiva +msgid "Aktiva" +msgstr "Aktiva" + +#. module: l10n_hr +#: model:ir.actions.todo,note:l10n_hr.config_call_account_template_hr_rrif +msgid "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" +" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" +msgstr "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" +" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_view +msgid "Sintetika" +msgstr "Sintetika" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_inv_rashod +msgid "Izvanredni rashodi" +msgstr "Izvanredni rashodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pdv +msgid "Obveze za PDV" +msgstr "Obveze za PDV" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_other +msgid "Ostalo" +msgstr "Ostalo" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pas_razgran +msgid "Pasivna vrem. Razgraničenja" +msgstr "Pasivna vrem. Razgraničenja" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_imovina +msgid "Kratkotrajna imovina" +msgstr "Kratkotrajna imovina" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_upis_kapital +msgid "Potraživanja za upisani kapital" +msgstr "Potraživanja za upisani kapital" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_obveze_dob +msgid "Obveze prema dobavljačima" +msgstr "Obveze prema dobavljačima" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kapital +msgid "Kapital i rezerve" +msgstr "Kapital i rezerve" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rezervacije +msgid "Rezerviranja" +msgstr "Rezerviranja" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_potraz_kup +msgid "Potraživanja od kupaca" +msgstr "Potraživanja od kupaca" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_imovina +msgid "Dugotrajna imovina" +msgstr "Dugotrajna imovina" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pretporez +msgid "Potraživanja za pretporez" +msgstr "Potraživanja za pretporez" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_prihod +msgid "Prihod" +msgstr "Prihod" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_prihod +msgid "Financijski prihodi" +msgstr "Financijski prihodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_rashod +msgid "Poslovni rashodi" +msgstr "Poslovni rashodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_obv +msgid "Dugoročne obveze" +msgstr "Dugoročne obveze" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rashod +msgid "Rashod" +msgstr "Rashod" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_prihod +msgid "Poslovni prihodi" +msgstr "Poslovni prihodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_obveze +msgid "Kratkoročne obveze" +msgstr "Kratkoročne obveze" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_rashod +msgid "Financijski rashodi" +msgstr "Financijski rashodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_izv_prihod +msgid "Izvanredni prihodi" +msgstr "Izvanredni prihodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiv_razgran +msgid "Aktivna vrem. Razgraničenja" +msgstr "Aktivna vrem. Razgraničenja" + diff --git a/addons/l10n_hr/i18n/l10n_hr.pot b/addons/l10n_hr/i18n/l10n_hr.pot new file mode 100644 index 00000000000..9f7c1848ee1 --- /dev/null +++ b/addons/l10n_hr/i18n/l10n_hr.pot @@ -0,0 +1,149 @@ +# Translation of OpenERP Server. +# This file contains the translation of the following modules: +# * l10n_hr +# +msgid "" +msgstr "" +"Project-Id-Version: OpenERP Server 6.1\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-03-20 18:16+0000\n" +"PO-Revision-Date: 2012-03-20 18:16+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pasiva +msgid "Pasiva" +msgstr "Pasiva" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiva +msgid "Aktiva" +msgstr "Aktiva" + +#. module: l10n_hr +#: model:ir.actions.todo,note:l10n_hr.config_call_account_template_hr_rrif +msgid "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" +" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" +msgstr "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" +" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_view +msgid "Sintetika" +msgstr "Sintetika" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_inv_rashod +msgid "Izvanredni rashodi" +msgstr "Izvanredni rashodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pdv +msgid "Obveze za PDV" +msgstr "Obveze za PDV" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_other +msgid "Ostalo" +msgstr "Ostalo" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pas_razgran +msgid "Pasivna vrem. Razgraničenja" +msgstr "Pasivna vrem. Razgraničenja" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_imovina +msgid "Kratkotrajna imovina" +msgstr "Kratkotrajna imovina" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_upis_kapital +msgid "Potraživanja za upisani kapital" +msgstr "Potraživanja za upisani kapital" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_obveze_dob +msgid "Obveze prema dobavljačima" +msgstr "Obveze prema dobavljačima" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kapital +msgid "Kapital i rezerve" +msgstr "Kapital i rezerve" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rezervacije +msgid "Rezerviranja" +msgstr "Rezerviranja" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_potraz_kup +msgid "Potraživanja od kupaca" +msgstr "Potraživanja od kupaca" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_imovina +msgid "Dugotrajna imovina" +msgstr "Dugotrajna imovina" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pretporez +msgid "Potraživanja za pretporez" +msgstr "Potraživanja za pretporez" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_prihod +msgid "Prihod" +msgstr "Prihod" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_prihod +msgid "Financijski prihodi" +msgstr "Financijski prihodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_rashod +msgid "Poslovni rashodi" +msgstr "Poslovni rashodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_obv +msgid "Dugoročne obveze" +msgstr "Dugoročne obveze" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rashod +msgid "Rashod" +msgstr "Rashod" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_prihod +msgid "Poslovni prihodi" +msgstr "Poslovni prihodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_obveze +msgid "Kratkoročne obveze" +msgstr "Kratkoročne obveze" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_rashod +msgid "Financijski rashodi" +msgstr "Financijski rashodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_izv_prihod +msgid "Izvanredni prihodi" +msgstr "Izvanredni prihodi" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiv_razgran +msgid "Aktivna vrem. Razgraničenja" +msgstr "Aktivna vrem. Razgraničenja" + diff --git a/addons/l10n_hr/l10n_hr_wizard.xml b/addons/l10n_hr/l10n_hr_wizard.xml new file mode 100755 index 00000000000..1f8a8763137 --- /dev/null +++ b/addons/l10n_hr/l10n_hr_wizard.xml @@ -0,0 +1,47 @@ + + + + + + RRIF-ov računski plan za poduzetnike + 0 + + + + + + + + + + + + + + + + + + + + + Generate Chart of Accounts from a Chart Template + Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku. + Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice + + automatic + + + + + + From 759416678b33a0caa5377f89b04b8acfc449c0b0 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 30 Nov 2012 15:57:14 +0100 Subject: [PATCH 02/41] [FIX]Currency constraint bzr revid: dle@openerp.com-20121130145714-d5k3cn95vh7nlc10 --- addons/l10n_be_coda/l10n_be_coda.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py index 1dab4ab1964..289e757a80d 100644 --- a/addons/l10n_be_coda/l10n_be_coda.py +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -30,7 +30,7 @@ class coda_bank_account(osv.osv): def _check_currency(self, cr, uid, ids, context=None): obj_cba = self.browse(cr, uid, ids[0], context=context) - if (obj_cba.state == 'normal') and obj_cba.journal and (obj_cba.currency != obj_cba.journal.currency): + if (obj_cba.state == 'normal') and obj_cba.journal and (obj_cba.currency != obj_cba.journal.currency and (not obj_cba.journal.currency and obj_cba.currency != obj_cba.company_id.currency_id)): return False return True From 6f3f1d4217abc1f14adb1e4dffd00da04516e5ab Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 30 Nov 2012 18:20:33 +0100 Subject: [PATCH 03/41] [MERGE](Sort of :D)From Luc De Meyer Zip from apps.openerp.com bzr revid: dle@openerp.com-20121130172033-dinqyw8arg79eh31 --- addons/l10n_be_coda/l10n_be_coda.py | 269 +-- addons/l10n_be_coda/l10n_be_coda_view.xml | 169 +- addons/l10n_be_coda/res_bank.py | 33 + addons/l10n_be_coda/res_bank_view.xml | 31 + .../wizard/account_coda_import.py | 1545 +++++++++++++---- 5 files changed, 1577 insertions(+), 470 deletions(-) create mode 100755 addons/l10n_be_coda/res_bank.py create mode 100755 addons/l10n_be_coda/res_bank_view.xml diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py index 289e757a80d..f9dfa3a686a 100644 --- a/addons/l10n_be_coda/l10n_be_coda.py +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -2,9 +2,9 @@ ############################################################################## # # OpenERP, Open Source Management Solution -# -# Copyright (c) 2011 Noviat nv/sa (www.noviat.be). All rights reserved. -# +# +# Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. +# # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the @@ -23,20 +23,29 @@ from osv import osv, fields import decimal_precision as dp from tools.translate import _ +import logging +_logger = logging.getLogger(__name__) class coda_bank_account(osv.osv): _name= 'coda.bank.account' _description= 'CODA Bank Account Configuration' + def _check_account_pain(self, cr, uid, context=None): + res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_pain'), ('state','=','installed')]) + return res and True or False + def _check_currency(self, cr, uid, ids, context=None): obj_cba = self.browse(cr, uid, ids[0], context=context) - if (obj_cba.state == 'normal') and obj_cba.journal and (obj_cba.currency != obj_cba.journal.currency and (not obj_cba.journal.currency and obj_cba.currency != obj_cba.company_id.currency_id)): - return False + if (obj_cba.state == 'normal') and obj_cba.journal: + if obj_cba.journal.currency and (obj_cba.currency != obj_cba.journal.currency): + return False + if not obj_cba.journal.currency and (obj_cba.currency != obj_cba.company_id.currency_id): + return False return True _columns = { 'name': fields.char('Name', size=64, required=True), - 'bank_id': fields.many2one('res.partner.bank', 'Bank Account', required=True, + 'bank_id': fields.many2one('res.partner.bank', 'Bank Account', required=True, help='Bank Account Number.\nThe CODA import function will find its CODA processing parameters on this number.'), 'description1': fields.char('Primary Account Description', size=35, help='The Primary or Secondary Account Description should match the corresponding Account Description in the CODA file.'), @@ -44,34 +53,47 @@ class coda_bank_account(osv.osv): help='The Primary or Secondary Account Description should match the corresponding Account Description in the CODA file.'), 'state': fields.selection([ ('normal', 'Normal'), - ('info', 'Info')], + ('info', 'Info')], 'Type', required=True, select=1, help='No Bank Statements will be generated for CODA Bank Statements from Bank Accounts of type \'Info\'.'), - 'journal': fields.many2one('account.journal', 'Journal', - domain=[('type', '=', 'bank')], + 'journal': fields.many2one('account.journal', 'Journal', + domain=[('type', '=', 'bank')], states={'normal':[('required',True)],'info':[('required',False)]}, help='Bank Journal for the Bank Statement'), 'currency': fields.many2one('res.currency', 'Currency', required=True, - help='The currency of the CODA Bank Statement'), + help='The currency of the CODA Bank Statement'), 'coda_st_naming': fields.char('Bank Statement Naming Policy', size=64, help="Define the rules to create the name of the Bank Statements generated by the CODA processing." \ - "\nE.g. %(code)s%(y)s/%(paper)s" + "\nE.g. %(code)s%(y)s/%(paper)s" \ "\n\nVariables:" \ "\nBank Journal Code: %(code)s" \ - "\nCurrent Year with Century: %(year)s" \ - "\nCurrent Year without Century: %(y)s" \ + "\nYear (of CODA 'New Balance Date') with Century: %(year)s" \ + "\nYear (of CODA 'New Balance Date') without Century: %(y)s" \ "\nCODA sequence number: %(coda)s" \ - "\nPaper Statement sequence number: %(paper)s"), - 'def_payable': fields.many2one('account.account', 'Default Payable Account', domain=[('type', '=', 'payable')], required=True, - help= 'Set here the payable account that will be used, by default, if the partner is not found.'), - 'def_receivable': fields.many2one('account.account', 'Default Receivable Account', domain=[('type', '=', 'receivable')], required=True, - help= 'Set here the receivable account that will be used, by default, if the partner is not found.',), + "\nPaper Statement sequence number (as specified on 'Old Balance' record): %(paper_ob)s" \ + "\nPaper Statement sequence number (as specified on 'New Balance' record): %(paper)s"), 'awaiting_account': fields.many2one('account.account', 'Default Account for Unrecognized Movement', domain=[('type', '!=', 'view')], required=True, help= 'Set here the default account that will be used if the partner cannot be unambiguously identified.'), 'transfer_account': fields.many2one('account.account', 'Default Internal Transfer Account', domain=[('code', 'like', '58%'), ('type', '!=', 'view')], required=True, help= 'Set here the default account that will be used for internal transfer between own bank accounts (e.g. transfer between current and deposit bank accounts).'), - 'find_bbacom': fields.boolean('Lookup Invoice', required=True, help='Partner lookup via the \'BBA\' Structured Communication field of the Invoice.'), - 'find_partner': fields.boolean('Lookup Partner', required=True, help='Partner lookup via Bank Account Number.'), + 'account_mapping_ids': fields.one2many('coda.account.mapping.rule', 'coda_bank_account_id', 'Account Mapping Rules'), + 'find_payment': fields.boolean('Lookup Payment Reference', + help='Invoice lookup and reconciliation via the SEPA EndToEndReference.' \ + '\nInstall the \'account_pain\' module if you want to take advantage of this feature.'), + 'find_bbacom': fields.boolean('Lookup Structured Communication of type \'BBA\'', + help='Partner lookup and reconciliation via the \'BBA\' Structured Communication.' \ + '\nA partial reconciliation will be created when there is no exact match between the Invoice and Bank Transaction amounts.'), + 'find_inv_number': fields.boolean('Lookup Invoice Number', + help='Partner lookup and reconciliation via the Invoice Number when a communication in free format is used.' \ + '\nA reconciliation will only be created in case of exact match between the Invoice and Bank Transaction amounts.'), + 'find_partner': fields.boolean('Lookup Partner', + help='Partner lookup via Bank Account Number in order to facilitate the reconciliation.'), + 'update_partner': fields.boolean('Update Partner Bank Accounts', + help='Update Partner record when the Counterparty\'s Bank Account has not been registered yet.'), + 'balance_start_enforce': fields.boolean('Prevent invalid Opening Balances', + help="Do not process Statements with an Opening Balance that doesn't match the previous Closing Balance."), + 'discard_dup': fields.boolean('Discard Duplicates', + help="Duplicate Bank Statements will be discarded. Select the corresponding 'CODA Bank Statement' in order to view the contents of such duplicates."), 'active': fields.boolean('Active', help='If the active field is set to False, it will allow you to hide the Bank Account without removing it.'), 'company_id': fields.many2one('res.company', 'Company', required=True), } @@ -79,9 +101,13 @@ class coda_bank_account(osv.osv): 'currency': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, 'state': 'normal', 'coda_st_naming': '%(code)s/%(y)s/%(coda)s', - 'active': True, + 'active': True, + 'find_payment': _check_account_pain, 'find_bbacom': True, - 'find_partner': True, + 'find_inv_number': True, + 'find_partner': True, + 'update_partner': True, + 'balance_start_enforce': True, 'company_id': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id, } _sql_constraints = [ @@ -107,19 +133,20 @@ class coda_bank_account(osv.osv): if not default: default = {} default = default.copy() - default.update( - journal_id=None, - description1=cba['description1'] or '', - description2=cba['description2'] or '', - name=_("%s (copy)") % (cba['name'] or ''), - state=cba['state']) - return super(coda_bank_account, self).copy(cr, uid, id, default, context) + default.update({'journal_id': None}) + default['description1'] = cba['description1'] or '' + default['description2'] = cba['description2'] or '' + default['name'] = (cba['name'] or '') + ' (copy)' + default['state'] = cba['state'] + return super(coda_bank_account, self).copy(cr, uid, id, default, context) def onchange_state(self, cr, uid, ids, state): return state =='info' and {'value': {'journal': None}} or {} coda_bank_account() + + class account_coda(osv.osv): _name = 'account.coda' _description = 'Object to store CODA Data Files' @@ -138,10 +165,10 @@ class account_coda(osv.osv): 'date': fields.date.context_today, 'user_id': lambda self,cr,uid,context: uid, 'company_id': lambda s,cr,uid,c: s.pool.get('res.company')._company_default_get(cr, uid, 'account.coda', context=c), - } + } _sql_constraints = [ ('coda_uniq', 'unique (name, coda_creation_date)', 'This CODA has already been imported !') - ] + ] def unlink(self, cr, uid, ids, context=None): if context is None: @@ -150,79 +177,73 @@ class account_coda(osv.osv): coda_st_obj = self.pool.get('coda.bank.statement') bank_st_obj = self.pool.get('account.bank.statement') for coda in self.browse(cr, uid, ids, context=context): - for coda_statement in coda.statement_ids: + for coda_statement in coda.statement_ids: if not context.get('coda_statement_unlink', False): if coda_st_obj.exists(cr, uid, coda_statement.id, context=context): - coda_st_obj.unlink(cr, uid, [coda_statement.id], context=context) + coda_st_obj.unlink(cr, uid, [coda_statement.id], context=context) if not context.get('bank_statement_unlink', False): if coda_st_obj.exists(cr, uid, coda_statement.id, context=context) and (coda_statement.type == 'normal') and bank_st_obj.exists(cr, uid, coda_statement.statement_id.id, context=context): - bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) + bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) context.update({'coda_unlink': False}) return super(account_coda, self).unlink(cr, uid, ids, context=context) - + account_coda() -class account_coda_trans_type(osv.osv): +class account_coda_trans_type(osv.osv): _name = 'account.coda.trans.type' _description = 'CODA transaction type' - _rec_name = 'type' + _rec_name = 'type' _columns = { 'type': fields.char('Transaction Type', size=1, required=True), 'parent_id': fields.many2one('account.coda.trans.type', 'Parent'), 'description': fields.text('Description', translate=True), } - account_coda_trans_type() -class account_coda_trans_code(osv.osv): +class account_coda_trans_code(osv.osv): _name = 'account.coda.trans.code' _description = 'CODA transaction code' - _rec_name = 'code' + _rec_name = 'code' _columns = { 'code': fields.char('Code', size=2, required=True, select=1), 'type': fields.selection([ ('code', 'Transaction Code'), - ('family', 'Transaction Family')], - 'Type', required=True, select=1), + ('family', 'Transaction Family')], + 'Type', required=True, select=1), 'parent_id': fields.many2one('account.coda.trans.code', 'Family', select=1), 'description': fields.char('Description', size=128, translate=True, select=2), 'comment': fields.text('Comment', translate=True), } - account_coda_trans_code() -class account_coda_trans_category(osv.osv): +class account_coda_trans_category(osv.osv): _name = 'account.coda.trans.category' _description = 'CODA transaction category' - _rec_name = 'category' + _rec_name = 'category' _columns = { 'category': fields.char('Transaction Category', size=3, required=True), 'description': fields.char('Description', size=256, translate=True), } - account_coda_trans_category() -class account_coda_comm_type(osv.osv): +class account_coda_comm_type(osv.osv): _name = 'account.coda.comm.type' _description = 'CODA structured communication type' - _rec_name = 'code' + _rec_name = 'code' _columns = { 'code': fields.char('Structured Communication Type', size=3, required=True, select=1), 'description': fields.char('Description', size=128, translate=True), } _sql_constraints = [ ('code_uniq', 'unique (code)','The Structured Communication Code must be unique !') - ] - + ] account_coda_comm_type() class coda_bank_statement(osv.osv): - _name = 'coda.bank.statement' - _description = 'CODA Bank Statement' - - def _default_journal_id(self, cr, uid, context=None): - if context is None: - context = {} + _name = 'coda.bank.statement' + _description = 'CODA Bank Statement' + + def _default_journal_id(self, cr, uid, context={}): if context.get('journal_id', False): return context['journal_id'] return False @@ -238,7 +259,7 @@ class coda_bank_statement(osv.osv): res[r] = round(res[r], 2) return res - def _get_period(self, cr, uid, context=None): + def _get_period(self, cr, uid, context={}): periods = self.pool.get('account.period').find(cr, uid) if periods: return periods[0] @@ -249,19 +270,22 @@ class coda_bank_statement(osv.osv): _columns = { 'name': fields.char('Name', size=64, required=True, readonly=True), 'date': fields.date('Date', required=True, readonly=True), + 'coda_creation_date': fields.date('CODA Creation Date', readonly=True), + 'old_balance_date': fields.date('Old Balance Date', readonly=True), + 'new_balance_date': fields.date('New Balance Date', readonly=True), 'coda_id': fields.many2one('account.coda', 'CODA Data File', ondelete='cascade'), 'type': fields.selection([ ('normal', 'Normal'), - ('info', 'Info')], + ('info', 'Info')], 'Type', required=True, readonly=True, help='No Bank Statements are associated with CODA Bank Statements of type \'Info\'.'), - 'statement_id': fields.many2one('account.bank.statement', 'Associated Bank Statement'), + 'statement_id': fields.many2one('account.bank.statement', 'Associated Bank Statement'), 'journal_id': fields.many2one('account.journal', 'Journal', readonly=True, domain=[('type', '=', 'bank')]), - 'coda_bank_account_id': fields.many2one('coda.bank.account', 'Bank Account', readonly=True), + 'coda_bank_account_id': fields.many2one('coda.bank.account', 'Bank Account', readonly=True), 'period_id': fields.many2one('account.period', 'Period', required=True, readonly=True), 'balance_start': fields.float('Starting Balance', digits_compute=dp.get_precision('Account'), readonly=True), 'balance_end_real': fields.float('Ending Balance', digits_compute=dp.get_precision('Account'), readonly=True), - 'balance_end': fields.function(_end_balance, method=True, store=True, string='Balance'), + 'balance_end': fields.function(_end_balance, method=True, store=True, string='Balance'), 'line_ids': fields.one2many('coda.bank.statement.line', 'statement_id', 'CODA Bank Statement lines', readonly=True), 'currency': fields.many2one('res.currency', 'Currency', required=True, readonly=True, @@ -269,14 +293,14 @@ class coda_bank_statement(osv.osv): 'company_id': fields.related('journal_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), } _defaults = { - 'type': 'normal', + 'type': 'normal', 'currency': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, 'journal_id': _default_journal_id, 'period_id': _get_period, } def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False): - if context is None: + if context is None: context = {} res = super(coda_bank_statement, self).search(cr, uid, args=args, offset=offset, limit=limit, order=order, context=context, count=count) @@ -290,20 +314,20 @@ class coda_bank_statement(osv.osv): context.update({'coda_statement_unlink': True}) coda_obj = self.pool.get('account.coda') bank_st_obj = self.pool.get('account.bank.statement') - + # find all CODA bank statements that are associated with the selected CODA bank statements via a common CODA file - new_ids = [] + new_ids = [] for coda_statement in self.browse(cr, uid, ids, context=context): if coda_obj.exists(cr, uid, coda_statement.coda_id.id, context=context): new_ids += [x.id for x in coda_obj.browse(cr, uid, coda_statement.coda_id.id, context=context).statement_ids] - # unlink CODA banks statements as well as associated bank statements and CODA files + # unlink CODA banks statements as well as associated bank statements and CODA files for coda_statement in self.browse(cr, uid, new_ids, context=context): - if coda_statement.statement_id.state == 'confirm': - raise osv.except_osv(_('Invalid Action!'), - _("Cannot delete CODA Bank Statement '%s' of journal '%s'." \ - "\nThe associated Bank Statement has already been confirmed." \ - "\nPlease undo this action first.") \ + if coda_statement.statement_id.state == 'confirm': + raise osv.except_osv(_('Invalid action !'), + _("Cannot delete CODA Bank Statement '%s' of Journal '%s'." \ + "\nThe associated Bank Statement has already been confirmed !" \ + "\nPlease undo this action first!") \ % (coda_statement.name, coda_statement.journal_id.name)) else: if not context.get('coda_unlink', False): @@ -311,11 +335,11 @@ class coda_bank_statement(osv.osv): coda_obj.unlink(cr, uid, [coda_statement.coda_id.id], context=context) if not context.get('bank_statement_unlink', False): if coda_statement.statement_id and bank_st_obj.exists(cr, uid, coda_statement.statement_id.id, context=context): - bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) + bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) context.update({'coda_statement_unlink': False}) return super(coda_bank_statement, self).unlink(cr, uid, new_ids, context=context) - + coda_bank_statement() class account_bank_statement(osv.osv): @@ -323,7 +347,10 @@ class account_bank_statement(osv.osv): _columns = { 'coda_statement_id': fields.many2one('coda.bank.statement', 'Associated CODA Bank Statement'), } - + _sql_constraints = [ + ('name_company_uniq', 'unique (name,company_id)', 'The name of the Bank Statement must be unique per company !') + ] + def unlink(self, cr, uid, ids, context=None): if context is None: context = {} @@ -332,15 +359,15 @@ class account_bank_statement(osv.osv): coda_st_obj = self.pool.get('coda.bank.statement') # find all statements that are associated with the selected bank statements via a common CODA file - ids_plus = [] + ids_plus = [] for statement in self.browse(cr, uid, ids, context=context): if statement.coda_statement_id: for x in coda_obj.browse(cr, uid, statement.coda_statement_id.coda_id.id, context=context).statement_ids: if x.type == 'normal': ids_plus += [x.statement_id.id] - + # unlink banks statements as well as associated CODA bank statements and CODA files - for statement in self.browse(cr, uid, ids_plus, context=context): + for statement in self.browse(cr, uid, ids_plus, context=context): if not context.get('coda_statement_unlink', False): if statement.coda_statement_id and coda_st_obj.exists(cr, uid, statement.coda_statement_id.id, context=context): coda_st_obj.unlink(cr, uid, [statement.coda_statement_id.id], context=context) @@ -354,63 +381,109 @@ class account_bank_statement(osv.osv): context.update({'bank_statement_unlink': False}) new_ids = list(set(ids + ids_plus)) return super(account_bank_statement, self).unlink(cr, uid, new_ids, context=context) - + account_bank_statement() class coda_bank_statement_line(osv.osv): - _name = 'coda.bank.statement.line' - _order = 'sequence' + _name = 'coda.bank.statement.line' + _order = 'sequence' _description = 'CODA Bank Statement Line' _columns = { 'name': fields.char('Communication', size=268, required=True), 'sequence': fields.integer('Sequence'), 'date': fields.date('Entry Date', required=True), - 'val_date': fields.date('Valuta Date'), - 'account_id': fields.many2one('account.account','Account'), # remove required=True + 'val_date': fields.date('Valuta Date'), + 'account_id': fields.many2one('account.account','Account'), 'type': fields.selection([ ('supplier','Supplier'), ('customer','Customer'), ('general','General'), - ('globalisation','Globalisation'), - ('information','Information'), - ('communication','Free Communication'), + ('globalisation','Globalisation'), + ('information','Information'), + ('communication','Free Communication'), ], 'Type', required=True), - 'globalisation_level': fields.integer('Globalisation Level', - help="The value which is mentioned (1 to 9), specifies the hierarchy level" - " of the globalisation of which this record is the first." - "\nThe same code will be repeated at the end of the globalisation."), - 'globalisation_amount': fields.float('Globalisation Amount', digits_compute=dp.get_precision('Account')), + 'globalisation_level': fields.integer('Globalisation Level', + help="The value which is mentioned (1 to 9), specifies the hierarchy level" + " of the globalisation of which this record is the first." + "\nThe same code will be repeated at the end of the globalisation."), + 'globalisation_amount': fields.float('Globalisation Amount', digits_compute=dp.get_precision('Account')), 'globalisation_id': fields.many2one('account.bank.statement.line.global', 'Globalisation ID', readonly=True, - help="Code to identify transactions belonging to the same globalisation level within a batch payment"), + help="Code to identify transactions belonging to the same globalisation level within a batch payment"), 'amount': fields.float('Amount', digits_compute=dp.get_precision('Account')), 'partner_id': fields.many2one('res.partner', 'Partner'), 'counterparty_name': fields.char('Counterparty Name', size=35), - 'counterparty_bic': fields.char('Counterparty BIC', size=11), - 'counterparty_number': fields.char('Counterparty Number', size=34), - 'counterparty_currency': fields.char('Counterparty Currency', size=3), + 'counterparty_bic': fields.char('Counterparty BIC', size=11), + 'counterparty_number': fields.char('Counterparty Number', size=34), + 'counterparty_currency': fields.char('Counterparty Currency', size=3), + 'payment_reference': fields.char('Payment Reference', size=35, + help="Payment Reference. For SEPA (SCT or SDD) transactions, the PaymentInformationIdentification "\ + "is recorded in this field pertaining to a globalisation, and the EndToEndReference for " \ + "simple transactions or for the details of a globalisation."), 'statement_id': fields.many2one('coda.bank.statement', 'CODA Bank Statement', select=True, required=True, ondelete='cascade'), 'coda_bank_account_id': fields.related('statement_id', 'coda_bank_account_id', type='many2one', relation='coda.bank.account', string='Bank Account', store=True, readonly=True), 'ref': fields.char('Reference', size=32), 'note': fields.text('Notes'), - 'company_id': fields.related('statement_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), + 'company_id': fields.related('statement_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), } def unlink(self, cr, uid, ids, context=None): if context is None: context = {} if context.get('block_statement_line_delete', False): - raise osv.except_osv('Warning', _('Delete operation not allowed.')) + raise osv.except_osv('Warning', _('Delete operation not allowed !')) return super(account_bank_statement_line, self).unlink(cr, uid, ids, context=context) -coda_bank_statement_line() +coda_bank_statement_line() class account_bank_statement_line_global(osv.osv): _inherit = 'account.bank.statement.line.global' _columns = { 'coda_statement_line_ids': fields.one2many('coda.bank.statement.line', 'globalisation_id', 'CODA Bank Statement Lines', readonly=True), } - account_bank_statement_line_global() +class coda_account_mapping_rule(osv.osv): + _name = 'coda.account.mapping.rule' + _description = 'Rules Engine to assign accounts during CODA parsing' + _order = 'sequence' + _columns = { + 'coda_bank_account_id': fields.many2one('coda.bank.account', 'CODA Bank Account', ondelete='cascade'), + 'sequence': fields.integer('Sequence', help='Determines the order of the rules to assign accounts'), + 'name': fields.char('Rule Name', size=128, required=True), + # matching criteria + 'trans_type_id': fields.many2one('account.coda.trans.type', 'Transaction Type'), + 'trans_family_id': fields.many2one('account.coda.trans.code', 'Transaction Family', domain=[('type', '=', 'family')]), + 'trans_code_id': fields.many2one('account.coda.trans.code', 'Transaction Code', domain=[('type', '=', 'code')]), + 'trans_category_id': fields.many2one('account.coda.trans.category', 'Transaction Category'), + 'struct_comm_type_id': fields.many2one('account.coda.comm.type', 'Structured Communication Type'), + 'partner_id': fields.many2one('res.partner', 'Partner', ondelete='cascade'), + # resulting general account + 'account_id': fields.many2one('account.account', 'Account', ondelete='cascade', required=True, domain=[('type', '!=', 'view')]), + 'active': fields.boolean('Active', help='Switch on/off this rule.'), + } + _defaults = { + 'active': True, + } + + def account_id_get(self, cr, uid, coda_bank_account_id, trans_type_id=None, trans_family_id=None, + trans_code_id=None, trans_category_id=None, struct_comm_type_id=None, partner_id=None, context=None): + cr.execute('SELECT account_id, trans_type_id, trans_family_id, trans_code_id, trans_category_id, struct_comm_type_id, partner_id ' \ + 'FROM coda_account_mapping_rule ' \ + 'WHERE active = TRUE AND coda_bank_account_id = %s ' \ + 'ORDER BY sequence' % coda_bank_account_id + ) + rules = cr.fetchall() + condition = '(not rule[1] or (trans_type_id == rule[1])) and (not rule[2] or (trans_family_id == rule[2])) ' \ + 'and (not rule[3] or (trans_code_id == rule[3])) and (not rule[4] or (trans_category_id == rule[4])) ' \ + 'and (not rule[5] or (struct_comm_type_id == rule[5])) and (not rule[6] or (partner_id == rule[6]))' + account_id = None + for rule in rules: + if eval(condition): + account_id = rule[0] + break + return account_id + +coda_account_mapping_rule() + # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/l10n_be_coda_view.xml b/addons/l10n_be_coda/l10n_be_coda_view.xml index 1f014400d3c..fb0a12b73fb 100644 --- a/addons/l10n_be_coda/l10n_be_coda_view.xml +++ b/addons/l10n_be_coda/l10n_be_coda_view.xml @@ -11,10 +11,11 @@ coda.bank.account - + + @@ -54,15 +55,52 @@ - - - - + + - + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + + + + + + + + + +
+
@@ -282,11 +320,12 @@ coda.bank.statement.list coda.bank.statement - + - - + + + @@ -299,61 +338,56 @@ coda.bank.statement.form coda.bank.statement -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -362,10 +396,12 @@ coda.bank.statement - - + + + + @@ -457,6 +493,7 @@ + diff --git a/addons/l10n_be_coda/res_bank.py b/addons/l10n_be_coda/res_bank.py new file mode 100755 index 00000000000..6a3581539e9 --- /dev/null +++ b/addons/l10n_be_coda/res_bank.py @@ -0,0 +1,33 @@ +# -*- encoding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# +# Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +from osv import fields, osv + +class res_bank(osv.osv): + _inherit = 'res.bank' + _columns = { + 'code': fields.char('Code', size=3, + help='Country specific Bank Code (used for bban to iban conversion).'), + } +res_bank() + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/res_bank_view.xml b/addons/l10n_be_coda/res_bank_view.xml new file mode 100755 index 00000000000..fe4a71d2bdb --- /dev/null +++ b/addons/l10n_be_coda/res_bank_view.xml @@ -0,0 +1,31 @@ + + + + + + res.bank.form.add.code + res.bank + + form + + + + + + + + + res.bank.tree.add.code + res.bank + + form + + + + + + + + + + diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 46c545f0f48..6f055ca3d92 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -2,9 +2,9 @@ ############################################################################## # # OpenERP, Open Source Management Solution -# -# Copyright (c) 2011 Noviat nv/sa (www.noviat.be). All rights reserved. -# +# +# Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. +# # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the @@ -24,11 +24,11 @@ import time import base64 from osv import fields,osv from tools.translate import _ -import logging +import netsvc import re from traceback import format_exception from sys import exc_info -from base_iban import base_iban +import logging _logger = logging.getLogger(__name__) class account_coda_import(osv.osv_memory): @@ -43,6 +43,10 @@ class account_coda_import(osv.osv_memory): 'coda_fname': lambda *a: '', } + def _check_account_payment(self, cr, uid, context=None): + res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_payment'), ('state','=','installed')]) + return res and True or False + def coda_parsing(self, cr, uid, ids, context=None, batch=False, codafile=None, codafilename=None): if context is None: context = {} @@ -53,12 +57,12 @@ class account_coda_import(osv.osv_memory): data=self.browse(cr,uid,ids)[0] try: codafile = data.coda_data - codafilename = data.coda_fname + codafilename = data.coda_fname except: - raise osv.except_osv(_('Error!'), _('Wizard in incorrect state. Please hit the Cancel button.')) + raise osv.except_osv(_('Error!'), _('Wizard in incorrect state. Please hit the Cancel button!')) return {} - currency_obj = self.pool.get('res.currency') + currency_obj = self.pool.get('res.currency') coda_bank_account_obj = self.pool.get('coda.bank.account') trans_type_obj = self.pool.get('account.coda.trans.type') trans_code_obj = self.pool.get('account.coda.trans.code') @@ -80,13 +84,23 @@ class account_coda_import(osv.osv_memory): voucher_line_obj = self.pool.get('account.voucher.line') seq_obj = self.pool.get('ir.sequence') mod_obj = self.pool.get('ir.model.data') + partner_obj = self.pool.get('res.partner') + account_mapping_obj = self.pool.get('coda.account.mapping.rule') + + if self._check_account_payment(cr, uid): + payment_line_obj = self.pool.get('payment.line') + else: + payment_line_obj = False + + wf_service = netsvc.LocalService('workflow') + be_country_id = self.pool.get('res.country').search(cr, uid, [('code', '=', 'BE')])[0] coda_bank_table = coda_bank_account_obj.read(cr, uid, coda_bank_account_obj.search(cr, uid, []), context=context) for coda_bank in coda_bank_table: coda_bank.update({'journal_code': coda_bank['journal'] and journal_obj.browse(cr, uid, coda_bank['journal'][0], context=context).code or ''}) coda_bank.update({'iban': partner_bank_obj.browse(cr, uid, coda_bank['bank_id'][0], context=context).iban}) coda_bank.update({'acc_number': partner_bank_obj.browse(cr, uid, coda_bank['bank_id'][0], context=context).acc_number}) - coda_bank.update({'currency_name': currency_obj.browse(cr, uid, coda_bank['currency'][0], context=context).name}) + coda_bank.update({'currency_name': currency_obj.browse(cr, uid, coda_bank['currency'][0], context=context).name}) trans_type_table = trans_type_obj.read(cr, uid, trans_type_obj.search(cr, uid, []), context=context) trans_code_table = trans_code_obj.read(cr, uid, trans_code_obj.search(cr, uid, []), context=context) trans_category_table = trans_category_obj.read(cr, uid, trans_category_obj.search(cr, uid, []), context=context) @@ -97,9 +111,10 @@ class account_coda_import(osv.osv_memory): err_log = '' coda_statements = [] recordlist = unicode(base64.decodestring(codafile), 'windows-1252', 'strict').split('\n') - + digits = self.pool.get('decimal.precision').precision_get(cr, uid, 'Account') + for line in recordlist: - + if not line: pass elif line[0] == '0': @@ -108,42 +123,35 @@ class account_coda_import(osv.osv_memory): coda_parsing_note = '' coda_statement_lines = {} st_line_seq = 0 - glob_lvl_stack = [0] # header data - coda_statement['currency'] = 'EUR' # default currency + coda_statement['currency'] = 'EUR' # default currency coda_statement['version'] = line[127] coda_version = line[127] if coda_version not in ['1','2']: - err_string = _('\nCODA V%s statements are not supported, please contact your bank.') % coda_version + err_string = _('\nCODA V%s statements are not supported, please contact your bank!') % coda_version err_code = 'R0001' if batch: return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) coda_statement['coda_statement_lines'] = {} coda_statement['date'] = str2date(line[5:11]) - period_id = period_obj.search(cr , uid, [('date_start' ,'<=', coda_statement['date']), ('date_stop','>=',coda_statement['date'])]) - if not period_id: - err_string = _("\nThe CODA creation date doesn't fall within a defined Accounting Period." \ - "\nPlease create the Accounting Period for date %s.") % coda_statement['date'] - err_code = 'R0002' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - coda_statement['period_id'] = period_id[0] + coda_statement['coda_creation_date'] = str2date(line[5:11]) + coda_statement['separate_application'] = line[83:88] + coda_statement['first_transaction_date'] = False coda_statement['state'] = 'draft' - + coda_id = coda_obj.search(cr, uid,[ ('name', '=', codafilename), ('coda_creation_date', '=', coda_statement['date']), ]) if coda_id: - err_string = _("\nCODA File with Filename '%s' and Creation Date '%s' has already been imported.") \ + err_string = _("\nCODA File with Filename '%s' and Creation Date '%s' has already been imported !") \ % (codafilename, coda_statement['date']) err_code = 'W0001' if batch: return (err_code, err_string) - raise osv.except_osv(_('Warning!'), err_string) - + raise osv.except_osv(_('Warning !'), err_string) + elif line[0] == '1': if coda_version == '1': coda_statement['acc_number'] = line[5:17] @@ -151,47 +159,56 @@ class account_coda_import(osv.osv_memory): coda_statement['currency'] = line[18:21] elif line[1] == '0': # Belgian bank account BBAN structure coda_statement['acc_number'] = line[5:17] - coda_statement['currency'] = line[18:21] + coda_statement['currency'] = line[18:21] elif line[1] == '1': # foreign bank account BBAN structure - err_string = _('\nForeign bank accounts with BBAN structure are not supported.') + err_string = _('\nForeign bank accounts with BBAN structure are not supported !') err_code = 'R1001' if batch: return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) elif line[1] == '2': # Belgian bank account IBAN structure - coda_statement['acc_number']=line[5:21] + coda_statement['acc_number']=line[5:21] coda_statement['currency'] = line[39:42] elif line[1] == '3': # foreign bank account IBAN structure - err_string = _('\nForeign bank accounts with IBAN structure are not supported.') + err_string = _('\nForeign bank accounts with IBAN structure are not supported !') err_code = 'R1002' if batch: return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) else: - err_string = _('\nUnsupported bank account structure.') + err_string = _('\nUnsupported bank account structure !') err_code = 'R1003' if batch: return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) coda_statement['description'] = line[90:125].strip() - cba_filter = lambda x: ((coda_statement['acc_number'] in (x['iban'] or '')) or (coda_statement['acc_number'] == x['acc_number'])) \ - and (coda_statement['currency'] == x['currency_name']) and (coda_statement['description'] == (x['description1'] or x['description2'] or '')) + cba_filter = lambda x: (coda_statement['acc_number'] in _get_acc_numbers(x['acc_number'])) \ + and (coda_statement['currency'] == x['currency_name']) and (coda_statement['description'] in [x['description1'] or '', x['description2'] or '']) coda_bank = filter(cba_filter, coda_bank_table) if coda_bank: - coda_bank = coda_bank[0] + coda_bank = coda_bank[0] coda_statement['type'] = coda_bank['state'] coda_statement['journal_id'] = coda_bank['journal'] and coda_bank['journal'][0] coda_statement['currency_id'] = coda_bank['currency'][0] - coda_statement['coda_bank_account_id'] = coda_bank['id'] - def_pay_acc = coda_bank['def_payable'][0] - def_rec_acc = coda_bank['def_receivable'][0] + coda_statement['coda_bank_account_id'] = coda_bank['id'] + coda_statement['account_mapping_ids'] = coda_bank['account_mapping_ids'] + coda_statement['coda_bank_params'] = coda_bank awaiting_acc = coda_bank['awaiting_account'][0] transfer_acc = coda_bank['transfer_account'][0] + find_payment = coda_bank['find_payment'] find_bbacom = coda_bank['find_bbacom'] + find_inv_number = coda_bank['find_inv_number'] find_partner = coda_bank['find_partner'] + update_partner = coda_bank['update_partner'] + coda_statement['balance_start_enforce'] = coda_bank['balance_start_enforce'] + coda_statement['discard_dup'] = coda_bank['discard_dup'] + company_id = coda_bank['company_id'][0] + company_bank_ids = partner_bank_obj.search(cr, uid, [('company_id', '=', company_id)]) + company_bank_accounts = partner_bank_obj.read(cr, uid, company_bank_ids, ['acc_number']) + company_bank_accounts = [x['acc_number'].replace(' ', '') for x in company_bank_accounts] else: - err_string = _("\nNo matching CODA Bank Account Configuration record found.") + \ - _("\nPlease check if the 'Bank Account Number', 'Currency' and 'Account Description' fields of your configuration record match with '%s', '%s' and '%s'.") \ + err_string = _("\nNo matching CODA Bank Account Configuration record found !") + \ + _("\nPlease check if the 'Bank Account Number', 'Currency' and 'Account Description' fields of your configuration record match with '%s', '%s' and '%s' !") \ % (coda_statement['acc_number'], coda_statement['currency'], coda_statement['description']) err_code = 'R1004' if batch: @@ -200,56 +217,72 @@ class account_coda_import(osv.osv_memory): bal_start = list2float(line[43:58]) # old balance data if line[42] == '1': # 1= Debit bal_start = - bal_start - coda_statement['balance_start'] = bal_start + coda_statement['balance_start'] = bal_start + coda_statement['old_balance_date'] = str2date(line[58:64]) coda_statement['acc_holder'] = line[64:90] - coda_statement['paper_seq_number'] = line[2:5] + coda_statement['paper_ob_seq_number'] = line[2:5] coda_statement['coda_seq_number'] = line[125:128] - if coda_bank['coda_st_naming']: - coda_statement['name'] = coda_bank['coda_st_naming'] % { - 'code': coda_bank['journal_code'] or '', - 'year': time.strftime('%Y'), - 'y': time.strftime('%y'), - 'coda': line[125:128], - 'paper': line[2:5], - } - else: - coda_statement['name'] = '/' elif line[0] == '2': # movement data record 2 + if line[1] == '1': # movement data record 2.1 st_line = {} st_line_seq = st_line_seq + 1 st_line['sequence'] = st_line_seq st_line['type'] = 'general' - st_line['reconcile'] = False + st_line['reconcile'] = False + st_line['trans_family'] = False st_line['struct_comm_type'] = '' + st_line['struct_comm_type_id'] = 0 st_line['struct_comm_type_desc'] = '' - st_line['struct_comm_101'] = '' + st_line['struct_comm_bba'] = '' st_line['communication'] = '' + st_line['payment_reference'] = '' st_line['partner_id'] = 0 st_line['account_id'] = 0 st_line['counterparty_name'] = '' - st_line['counterparty_bic'] = '' + st_line['counterparty_bic'] = '' st_line['counterparty_number'] = '' - st_line['counterparty_currency'] = '' + st_line['counterparty_currency'] = '' st_line['glob_lvl_flag'] = False st_line['globalisation_id'] = 0 st_line['globalisation_code'] = '' st_line['globalisation_amount'] = False st_line['amount'] = False - + st_line['ref'] = line[2:10] + st_line['ref_move'] = line[2:6] + st_line['ref_move_detail'] = line[6:10] + + if st_line_seq == 1: + main_move_stack = [st_line] # initialise main_move_stack (used to link 2.1 detail records to 2.1 main record + glob_lvl_stack = [0] # initialise globalisation stack + elif st_line['ref_move_detail'] == '0000': + glob_lvl_stack = [0] # re-initialise globalisation stack + st_line['trans_ref'] = line[10:31] st_line_amt = list2float(line[32:47]) if line[31] == '1': # 1=debit st_line_amt = - st_line_amt - # processing of amount depending on globalisation code + + st_line['trans_type'] = line[53] + trans_type = filter(lambda x: st_line['trans_type'] == x['type'], trans_type_table) + if not trans_type: + err_string = _('\nThe File contains an invalid CODA Transaction Type : %s!') % st_line['trans_type'] + err_code = 'R2001' + if batch: + return (err_code, err_string) + raise osv.except_osv(_('Data Error!'), err_string) + st_line['trans_type_id'] = trans_type[0]['id'] + st_line['trans_type_desc'] = trans_type[0]['description'] + + # processing of amount depending on globalisation code glob_lvl_flag = int(line[124]) - if glob_lvl_flag > 0: - if glob_lvl_stack[-1] == glob_lvl_flag: - st_line['glob_lvl_flag'] = glob_lvl_flag + if glob_lvl_flag > 0: + if glob_lvl_stack[-1] == glob_lvl_flag: + st_line['glob_lvl_flag'] = glob_lvl_flag st_line['amount'] = st_line_amt glob_lvl_stack.pop() else: @@ -257,199 +290,388 @@ class account_coda_import(osv.osv_memory): st_line['type'] = 'globalisation' st_line['glob_lvl_flag'] = glob_lvl_flag st_line['globalisation_amount'] = st_line_amt - st_line['account_id'] = None else: st_line['amount'] = st_line_amt - # positions 48-53 : Value date or 000000 if not known (DDMMYY) + + # The 'globalisation' concept can also be implemented without the globalisation level flag. + # This is e.g. used by Europabank to give the details of Card Payments. + if st_line['ref_move'] == main_move_stack[-1]['ref_move']: + if st_line['ref_move_detail'] == '9999': + # Current CODA parsing logic doesn't support > 9999 detail lines + err_string = _('\nTransaction Detail Limit reached!') + err_code = 'R2010' + if batch: + return (err_code, err_string) + raise osv.except_osv(_('Data Error!'), err_string) + elif st_line['ref_move_detail'] != '0000': + if glob_lvl_stack[-1] == 0: + # promote associated move record into a globalisation + glob_lvl_flag = 1 + glob_lvl_stack.append(glob_lvl_flag) + main_st_line_seq = main_move_stack[-1]['sequence'] + to_promote = coda_statement['coda_statement_lines'][main_st_line_seq] + if not main_move_stack[-1].get('detail_cnt'): + to_promote.update({ + 'type': 'globalisation', + 'glob_lvl_flag': glob_lvl_flag, + 'globalisation_amount': main_move_stack[-1]['amount'], + 'amount': False, + 'account_id': 0, + }) + main_move_stack[-1]['promoted'] = True + if not main_move_stack[-1].get('detail_cnt'): + main_move_stack[-1]['detail_cnt'] = 1 + else: + main_move_stack[-1]['detail_cnt'] += 1 + + # positions 48-53 : Valuta date or 000000 if not known (DDMMYY) st_line['val_date'] = str2date(line[47:53]) # positions 54-61 : transaction code - st_line['trans_type'] = line[53] - trans_type = filter(lambda x: st_line['trans_type'] == x['type'], trans_type_table) - if not trans_type: - err_string = _('\nThe File contains an invalid CODA Transaction Type : %s.') % st_line['trans_type'] - err_code = 'R2001' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - st_line['trans_type_desc'] = trans_type[0]['description'] st_line['trans_family'] = line[54:56] trans_family = filter(lambda x: (x['type'] == 'family') and (st_line['trans_family'] == x['code']), trans_code_table) if not trans_family: - err_string = _('\nThe File contains an invalid CODA Transaction Family : %s.') % st_line['trans_family'] + err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] err_code = 'R2002' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) + raise osv.except_osv(_('Data Error!'), err_string) + st_line['trans_family_id'] = trans_family[0]['id'] st_line['trans_family_desc'] = trans_family[0]['description'] st_line['trans_code'] = line[56:58] - trans_code = filter(lambda x: (x['type'] == 'code') and (st_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), + trans_code = filter(lambda x: (x['type'] == 'code') and (st_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), trans_code_table) if trans_code: + st_line['trans_code_id'] = trans_code[0]['id'] st_line['trans_code_desc'] = trans_code[0]['description'] else: + st_line['trans_code_id'] = None st_line['trans_code_desc'] = _('Transaction Code unknown, please consult your bank.') st_line['trans_category'] = line[58:61] trans_category = filter(lambda x: st_line['trans_category'] == x['category'], trans_category_table) if trans_category: + st_line['trans_category_id'] = trans_category[0]['id'] st_line['trans_category_desc'] = trans_category[0]['description'] else: - st_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') - # positions 61-115 : communication + st_line['trans_category_id'] = None + st_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') + # positions 61-115 : communication if line[61] == '1': st_line['struct_comm_type'] = line[62:65] comm_type = filter(lambda x: st_line['struct_comm_type'] == x['code'], comm_type_table) if not comm_type: - err_string = _('\nThe File contains an invalid Structured Communication Type : %s.') % st_line['struct_comm_type'] + err_string = _('\nThe File contains an invalid Structured Communication Type : %s!') % st_line['struct_comm_type'] err_code = 'R2003' if batch: return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) + st_line['struct_comm_type_id'] = comm_type[0]['id'] st_line['struct_comm_type_desc'] = comm_type[0]['description'] st_line['communication'] = st_line['name'] = line[65:115] - if st_line['struct_comm_type'] == '101': - bbacomm = line[65:77] - st_line['struct_comm_101'] = st_line['name'] = '+++' + bbacomm[0:3] + '/' + bbacomm[3:7] + '/' + bbacomm[7:] + '+++' + if st_line['struct_comm_type'] in ['101', '102']: + bbacomm = line[65:77] + st_line['struct_comm_bba'] = st_line['name'] = '+++' + bbacomm[0:3] + '/' + bbacomm[3:7] + '/' + bbacomm[7:] + '+++' else: st_line['communication'] = st_line['name'] = line[62:115] st_line['entry_date'] = str2date(line[115:121]) - # positions 122-124 not processed - coda_statement_lines[st_line_seq] = st_line + if st_line['sequence'] == 1: + coda_statement['first_transaction_date'] = st_line['entry_date'] + # positions 122-124 not processed + coda_statement_lines[st_line_seq] = st_line # store transaction + + if st_line['ref_move'] != main_move_stack[-1]['ref_move']: + if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): + # add closing globalisation level on previous detail record in order to correctly close + # moves that have been 'promoted' to globalisation + closeglobalise = coda_statement['coda_statement_lines'][st_line_seq-1] + closeglobalise.update({ + 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], + }) + else: + # demote record with globalisation code from 'globalisation' to 'general' when no detail records + # the same logic is repeated on the New Balance Record ('8 Record') in order to cope with CODA files + # containing a single 2.1 record that needs to be 'demoted'. + if main_move_stack[-1]['type'] == 'globalisation' and not main_move_stack[-1].get('detail_cnt'): + # demote record with globalisation code from 'globalisation' to 'general' when no detail records + main_st_line_seq = main_move_stack[-1]['sequence'] + to_demote = coda_statement['coda_statement_lines'][main_st_line_seq] + to_demote.update({ + 'type': 'general', + 'glob_lvl_flag': 0, + 'globalisation_amount': False, + 'amount': main_move_stack[-1]['globalisation_amount'], + }) + main_move_stack.pop() + main_move_stack.append(st_line) coda_statement['coda_statement_lines'] = coda_statement_lines + elif line[1] == '2': # movement data record 2.2 - if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: - err_string = _('\nCODA parsing error on movement data record 2.2, seq nr %s.' \ + if coda_statement['coda_statement_lines'][st_line_seq]['ref'][0:4] != line[2:6]: + err_string = _('\nCODA parsing error on movement data record 2.2, seq nr %s!' \ '\nPlease report this issue via your OpenERP support channel.') % line[2:10] err_code = 'R2004' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) + raise osv.except_osv(_('Error!'), err_string) coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:63] coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:63] + coda_statement['coda_statement_lines'][st_line_seq]['payment_reference'] = line[63:98].strip() coda_statement['coda_statement_lines'][st_line_seq]['counterparty_bic'] = line[98:109].strip() + elif line[1] == '3': # movement data record 2.3 - if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: - err_string = _('\nCODA parsing error on movement data record 2.3, seq nr %s.' \ + if coda_statement['coda_statement_lines'][st_line_seq]['ref'][0:4] != line[2:6]: + err_string = _('\nCODA parsing error on movement data record 2.3, seq nr %s!' \ '\nPlease report this issue via your OpenERP support channel.') % line[2:10] err_code = 'R2005' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) + raise osv.except_osv(_('Error!'), err_string) st_line = coda_statement_lines[st_line_seq] if coda_version == '1': - counterparty_number = line[10:22] + counterparty_number = line[10:22].strip() counterparty_name = line[47:125].strip() counterparty_currency = '' else: if line[22] == ' ': - counterparty_number = line[10:22] + counterparty_number = line[10:22].strip() counterparty_currency = line[23:26].strip() else: counterparty_number = line[10:44].strip() - counterparty_currency = line[44:47].strip() + counterparty_currency = line[44:47].strip() counterparty_name = line[47:82].strip() st_line['name'] += line[82:125] st_line['communication'] += line[82:125] st_line['counterparty_number'] = counterparty_number st_line['counterparty_currency'] = counterparty_currency st_line['counterparty_name'] = counterparty_name + """ + TO DO: + + replace code infra by check on flag 128 and copy info in Notes Field. + if counterparty_currency not in [coda_bank['currency_name'], '']: - err_string = _('\nCODA parsing error on movement data record 2.3, seq nr %s.' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] + err_string = _('\nCODA parsing error on movement data record 2.3, seq nr %s!' \ + '\nPlease report this issue via your OpenERP support channel.') % line[2:10] err_code = 'R2006' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) + raise osv.except_osv(_('Error!'), err_string) + """ - # partner matching and reconciliation - if st_line['type'] == 'general': + # invoice matching and reconciliation + if st_line['type'] == 'general': match = False - bank_ids = False - # prepare reconciliation for bba scor - reference = st_line['struct_comm_101'] - if reference and find_bbacom: - inv_ids = inv_obj.search(cr , uid, [('reference' ,'=', reference), ('reference_type' ,'=', 'bba')]) - if inv_ids: - invoice = inv_obj.browse(cr, uid, inv_ids[0]) - partner = invoice.partner_id - st_line['partner_id'] = partner.id - if invoice.type in ['in_invoice', 'in_refund']: - st_line['account_id'] = partner.property_account_payable.id or def_pay_acc - st_line['type'] = 'supplier' + payment_reference_match = False + inv_ids = None + partner_bank_ids = False + + # check payment reference in bank statement line against payment order lines + payment_reference = st_line['payment_reference'] + if payment_reference and find_payment and st_line['amount'] < 0: + payline_ids = payment_line_obj and payment_line_obj.search(cr, uid, [('name', '=', payment_reference)]) + if payline_ids: + if len(payline_ids) == 1: + payline = payment_line_obj.browse(cr, uid, payline_ids[0]) + match = True + payment_reference_match = True + st_line['partner_id'] = payline.partner_id.id + if payline.move_line_id: + st_line['reconcile'] = payline.move_line_id.id + st_line['account_id'] = payline.move_line_id.account_id.id + if payline._get_ml_inv_ref: + inv_type = payline.ml_inv_ref.type + st_line['type'] = inv_type == 'in_invoice' and 'supplier' or 'customer' + else: + st_line['type'] = 'general' else: - st_line['account_id'] = partner.property_account_receivable.id or def_rec_acc - st_line['type'] = 'customer' - if invoice.type in ['in_invoice', 'out_invoice']: - iml_ids = move_line_obj.search(cr, uid, [('move_id', '=', invoice.move_id.id), ('reconcile_id', '=', False), ('account_id.reconcile', '=', True)]) - if iml_ids: - st_line['reconcile'] = iml_ids[0] - match = True + err_string = _('\nThe CODA parsing detected a payment reference ambiguity while processing movement data record 2.3, seq nr %s!' \ + '\nPlease check your Payment Gateway configuration or contact your OpenERP support channel.') % line[2:10] + err_code = 'R2007' + if batch: + return (err_code, err_string) + raise osv.except_osv(_('Error!'), err_string) + + # check bba scor in bank statement line against open invoices + if st_line['struct_comm_bba'] and find_bbacom: + if st_line['amount'] > 0: + domain = [('type', 'in', ['out_invoice', 'in_refund'])] else: - coda_parsing_note += _("\n Bank Statement '%s' line '%s':" \ - "\n There is no invoice matching the Structured Communication '%s'." \ + domain = [('type', 'in', ['in_invoice', 'out_refund'])] + inv_ids = inv_obj.search(cr , uid, + domain + [('state', '=', 'open'), ('reference' ,'=', st_line['struct_comm_bba']), ('reference_type' ,'=', 'bba')]) + if not inv_ids: + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ + "\n There is no invoice matching the Structured Communication '%s'!" \ "\n Please verify and adjust the invoice and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ - % (coda_statement['name'], st_line['ref'], reference) - # lookup partner via counterparty_number + % (st_line['ref'], st_line['struct_comm_bba']) + elif len(inv_ids) == 1: + match = True + elif len(inv_ids) > 1: + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ + "\n There are multiple invoices matching the Structured Communication '%s'!" \ + "\n A manual reconciliation is required.") \ + % (st_line['ref'], st_line['struct_comm_bba']) + + # use free comm in bank statement line for lookup against open invoices + if not match and find_bbacom: + # extract possible bba scor from free form communication and try to find matching invoice + free_comm_digits = re.sub('\D', '', st_line['communication'] or '') + select = "SELECT id FROM (SELECT id, type, state, amount_total, number, reference_type, reference, " \ + "'%s'::text AS free_comm_digits FROM account_invoice) sq " \ + "WHERE state = 'open' AND reference_type = 'bba' " \ + "AND free_comm_digits LIKE '%%'||regexp_replace(reference, '\\\D', '', 'g')||'%%'" \ + % (free_comm_digits) + if st_line['amount'] > 0: + select2 = " AND type IN ('out_invoice', 'in_refund')" + else: + select2 = " AND type IN ('in_invoice', 'out_refund')" + cr.execute(select + select2) + res=cr.fetchall() + if res: + inv_ids = [x[0] for x in res] + if len(inv_ids) == 1: + match = True + if not match and st_line['communication'] and find_inv_number: + # check matching invoice number in free form communication combined with matching amount + free_comm = repl_special(st_line['communication'].strip()) + amount_fmt = '%.' + str(digits) + 'f' + if st_line['amount'] > 0: + amount_rounded = amount_fmt % round(st_line['amount'], digits) + else: + amount_rounded = amount_fmt % round(-st_line['amount'], digits) + select = "SELECT id FROM (SELECT id, type, state, amount_total, number, reference_type, reference, " \ + "'%s'::text AS free_comm FROM account_invoice) sq " \ + "WHERE state = 'open' AND amount_total = %s" \ + % (free_comm, amount_rounded) + # 'out_invoice', 'in_refund' + if st_line['amount'] > 0: + select2 = " AND type = 'out_invoice' AND free_comm ilike '%'||number||'%'" + cr.execute(select + select2) + res=cr.fetchall() + if res: + inv_ids = [x[0] for x in res] + else: + select2 = " AND type = 'in_refund' AND free_comm ilike '%'||reference||'%'" + cr.execute(select + select2) + res=cr.fetchall() + if res: + inv_ids = [x[0] for x in res] + # 'in_invoice', 'out_refund' + else: + select2 = " AND type = 'in_invoice' AND free_comm ilike '%'||reference||'%'" + cr.execute(select + select2) + res=cr.fetchall() + if res: + inv_ids = [x[0] for x in res] + else: + select2 = " AND type = 'out_refund' AND free_comm ilike '%'||number||'%'" + cr.execute(select + select2) + res=cr.fetchall() + if res: + inv_ids = [x[0] for x in res] + if inv_ids: + if len(inv_ids) == 1: + match = True + elif len(inv_ids) > 1: + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ + "\n There are multiple invoices matching the Invoice Amount and Reference." \ + "\n A manual reconciliation is required.") \ + % (st_line['ref']) + + if not payment_reference_match and match and inv_ids and len(inv_ids) == 1: + invoice = inv_obj.browse(cr, uid, inv_ids[0]) + partner = invoice.partner_id + st_line['partner_id'] = partner.id + if invoice.type in ['in_invoice', 'in_refund']: + st_line['account_id'] = partner.property_account_payable.id + st_line['type'] = 'supplier' + else: + st_line['account_id'] = partner.property_account_receivable.id + st_line['type'] = 'customer' + iml_ids = move_line_obj.search(cr, uid, [('move_id', '=', invoice.move_id.id), ('reconcile_id', '=', False), ('account_id.reconcile', '=', True)]) + if iml_ids: + st_line['reconcile'] = iml_ids[0] + else: + err_string = _('\nThe CODA parsing detected a database inconsistency while processing movement data record 2.3, seq nr %s!' \ + '\nPlease report this issue via your OpenERP support channel.') % line[2:10] + err_code = 'R2008' + if batch: + return (err_code, err_string) + raise osv.except_osv(_('Error!'), err_string) + + # lookup partner via counterparty_number when invoice lookup failed if not match and counterparty_number: - cba_filter = lambda x: ((counterparty_number in (x['iban'] or '')) or (counterparty_number == x['acc_number'])) \ - and (x['state'] == 'normal') - transfer_account = filter(cba_filter, coda_bank_table) + transfer_account = filter(lambda x: counterparty_number in x, company_bank_accounts) if transfer_account: st_line['account_id'] = transfer_acc match = True elif find_partner: - counterparty_number = base_iban._pretty_iban(base_iban._format_iban(counterparty_number)) - bank_ids = partner_bank_obj.search(cr,uid,[('acc_number','=', counterparty_number)]) - if not match and find_partner and bank_ids: - if len(bank_ids) > 1: - coda_parsing_note += _("\n Bank Statement '%s' line '%s':" \ - "\n No partner record assigned: There are multiple partners with the same Bank Account Number '%s'." \ + partner_bank_ids = partner_bank_obj.search(cr,uid,[('acc_number','=', counterparty_number)]) + if not match and find_partner and partner_bank_ids: + if len(partner_bank_ids) > 1: + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ + "\n No partner record assigned: There are multiple partners with the same Bank Account Number '%s'!" \ "\n Please correct the configuration and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ - % (coda_statement['name'], st_line['ref'], counterparty_number) - else: - bank = partner_bank_obj.browse(cr, uid, bank_ids[0], context) - st_line['partner_id'] = bank.partner_id.id + % (st_line['ref'], counterparty_number) + else: + partner_bank = partner_bank_obj.browse(cr, uid, partner_bank_ids[0], context) + st_line['partner_id'] = partner_bank.partner_id.id match = True if st_line['amount'] < 0: - st_line['account_id'] = bank.partner_id.property_account_payable.id or def_pay_acc + st_line['account_id'] = partner_bank.partner_id.property_account_payable.id st_line['type'] = 'supplier' else: - st_line['account_id'] = bank.partner_id.property_account_receivable.id or def_rec_acc + st_line['account_id'] = partner_bank.partner_id.property_account_receivable.id st_line['type'] = 'customer' elif not match and find_partner: if counterparty_number: - coda_parsing_note += _("\n Bank Statement '%s' line '%s':" \ - "\n The bank account '%s' is not defined for the partner '%s'." \ + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ + "\n The bank account '%s' is not defined for the partner '%s'!" \ "\n Please correct the configuration and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ - % (coda_statement['name'], st_line['ref'], - counterparty_number, counterparty_name) + % (st_line['ref'], counterparty_number, counterparty_name) else: - coda_parsing_note += _("\n Bank Statement '%s' line '%s':" \ - "\n No matching partner record found." \ + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ + "\n No matching partner record found!" \ "\n Please adjust the corresponding entry manually in the generated Bank Statement.") \ - % (coda_statement['name'], st_line['ref']) + % (st_line['ref']) st_line['account_id'] = awaiting_acc - # end of partner record lookup + + # add bank account to partner record + if match and st_line['account_id'] != transfer_acc and counterparty_number and update_partner: + partner_bank_ids = partner_bank_obj.search(cr,uid,[('acc_number','=', counterparty_number), ('partner_id', '=', st_line['partner_id'])], order='id') + if len(partner_bank_ids) > 1: + # clean up partner bank duplicates, keep most recently created + _logger.warn('Duplicate Bank Accounts for partner_id %s have been removed, ids = %s', + st_line['partner_id'], partner_bank_ids[:-1]) + partner_bank_obj.unlink(cr,uid, partner_bank_ids[:-1]) + if not partner_bank_ids: + feedback = update_partner_bank(self, cr, uid, st_line['counterparty_bic'], counterparty_number, st_line['partner_id'], counterparty_name) + if feedback: + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':") % st_line['ref'] + feedback + coda_statement_lines[st_line_seq] = st_line coda_statement['coda_statement_lines'] = coda_statement_lines + # end of processing movement data record 2.3 + else: # movement data record 2.x (x <> 1,2,3) - err_string = _('\nMovement data records of type 2.%s are not supported.') % line[1] - err_code = 'R2007' + err_string = _('\nMovement data records of type 2.%s are not supported !') % line[1] + err_code = 'R2009' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) + raise osv.except_osv(_('Data Error!'), err_string) elif line[0] == '3': # information data record 3 + if line[1] == '1': # information data record 3.1 info_line = {} info_line['entry_date'] = st_line['entry_date'] info_line['type'] = 'information' st_line_seq = st_line_seq + 1 - info_line['sequence'] = st_line_seq + info_line['sequence'] = st_line_seq info_line['struct_comm_type'] = '' info_line['struct_comm_type_desc'] = '' info_line['communication'] = '' @@ -463,19 +685,19 @@ class account_coda_import(osv.osv_memory): err_code = 'R3001' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - info_line['trans_type_desc'] = trans_type[0]['description'] + raise osv.except_osv(_('Data Error!'), err_string) + info_line['trans_type_desc'] = trans_type[0]['description'] info_line['trans_family'] = line[32:34] trans_family = filter(lambda x: (x['type'] == 'family') and (info_line['trans_family'] == x['code']), trans_code_table) if not trans_family: - err_string = _('\nThe File contains an invalid CODA Transaction Family : %s.') % st_line['trans_family'] + err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] err_code = 'R3002' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) + raise osv.except_osv(_('Data Error!'), err_string) info_line['trans_family_desc'] = trans_family[0]['description'] info_line['trans_code'] = line[34:36] - trans_code = filter(lambda x: (x['type'] == 'code') and (info_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id']), + trans_code = filter(lambda x: (x['type'] == 'code') and (info_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), trans_code_table) if trans_code: info_line['trans_code_desc'] = trans_code[0]['description'] @@ -486,13 +708,13 @@ class account_coda_import(osv.osv_memory): if trans_category: info_line['trans_category_desc'] = trans_category[0]['description'] else: - info_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') - # positions 40-113 : communication + info_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') + # positions 40-113 : communication if line[39] == '1': info_line['struct_comm_type'] = line[40:43] comm_type = filter(lambda x: info_line['struct_comm_type'] == x['code'], comm_type_table) if not comm_type: - err_string = _('\nThe File contains an invalid Structured Communication Type : %s.') % info_line['struct_comm_type'] + err_string = _('\nThe File contains an invalid Structured Communication Type : %s!') % info_line['struct_comm_type'] err_code = 'R3003' if batch: return (err_code, err_string) @@ -504,21 +726,23 @@ class account_coda_import(osv.osv_memory): # positions 114-128 not processed coda_statement_lines[st_line_seq] = info_line coda_statement['coda_statement_lines'] = coda_statement_lines + elif line[1] == '2': # information data record 3.2 if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: - err_string = _('\nCODA parsing error on information data record 3.2, seq nr %s.' \ + err_string = _('\nCODA parsing error on information data record 3.2, seq nr %s!' \ '\nPlease report this issue via your OpenERP support channel.') % line[2:10] err_code = 'R3004' if batch: return (err_code, err_string) raise osv.except_osv(_('Error!'), err_string) - coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:115] + coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:115] coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:115] + elif line[1] == '3': # information data record 3.3 if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: - err_string = _('\nCODA parsing error on information data record 3.3, seq nr %s.' \ + err_string = _('\nCODA parsing error on information data record 3.3, seq nr %s!' \ '\nPlease report this issue via your OpenERP support channel.') % line[2:10] err_code = 'R3005' if batch: @@ -526,7 +750,7 @@ class account_coda_import(osv.osv_memory): raise osv.except_osv(_('Error!'), err_string) coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:100] coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:100] - + elif line[0] == '4': # free communication data record 4 comm_line = {} @@ -537,21 +761,64 @@ class account_coda_import(osv.osv_memory): comm_line['communication'] = comm_line['name'] = line[32:112] coda_statement_lines[st_line_seq] = comm_line coda_statement['coda_statement_lines'] = coda_statement_lines - + elif line[0] == '8': # new balance record + last_transaction = main_move_stack[-1] + if last_transaction['type'] == 'globalisation' and not last_transaction.get('detail_cnt'): + # demote record with globalisation code from 'globalisation' to 'general' when no detail records + main_st_line_seq = main_move_stack[-1]['sequence'] + to_demote = coda_statement['coda_statement_lines'][main_st_line_seq] + to_demote.update({ + 'type': 'general', + 'glob_lvl_flag': 0, + 'globalisation_amount': False, + 'amount': main_move_stack[-1]['globalisation_amount'], + }) + # add closing globalisation level on previous detail record in order to correctly close + # moves that have been 'promoted' to globalisation + if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): + closeglobalise = coda_statement['coda_statement_lines'][st_line_seq-1] + closeglobalise.update({ + 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], + }) + coda_statement['paper_nb_seq_number'] = line[1:4] bal_end = list2float(line[42:57]) + coda_statement['new_balance_date'] = str2date(line[57:63]) if line[41] == '1': # 1=Debit bal_end = - bal_end coda_statement['balance_end_real'] = bal_end - + if coda_statement['new_balance_date']: + period_id = period_obj.search(cr , uid, [('date_start' ,'<=', coda_statement['new_balance_date']), ('date_stop','>=',coda_statement['new_balance_date'])]) + else: + period_id = period_obj.search(cr , uid, [('date_start' ,'<=', coda_statement['date']), ('date_stop','>=',coda_statement['date'])]) + if not period_id: + err_string = _("\nThe CODA Statement New Balance date doesn't fall within a defined Accounting Period!" \ + "\nPlease create the Accounting Period for date %s.") % coda_statement['new_balance_date'] + err_code = 'R0002' + if batch: + return (err_code, err_string) + raise osv.except_osv(_('Data Error!'), err_string) + coda_statement['period_id'] = period_id[0] + if coda_bank['coda_st_naming']: + coda_statement['name'] = coda_bank['coda_st_naming'] % { + 'code': coda_bank['journal_code'] or '', + 'year': coda_statement['new_balance_date'] and coda_statement['new_balance_date'][:4] or coda_statement['date'][:4], + 'y': coda_statement['new_balance_date'] and coda_statement['new_balance_date'][2:4] or coda_statement['date'][2:4], + 'coda': coda_statement['coda_seq_number'], + 'paper_ob': coda_statement['paper_ob_seq_number'], + 'paper': coda_statement['paper_nb_seq_number'], + } + else: + coda_statement['name'] = '/' + elif line[0] == '9': # footer record - coda_statement['balance_min'] = list2float(line[22:37]) + coda_statement['balance_min'] = list2float(line[22:37]) coda_statement['balance_plus'] = list2float(line[37:52]) if not bal_end: coda_statement['balance_end_real'] = coda_statement['balance_start'] + coda_statement['balance_plus'] - coda_statement['balance_min'] - if coda_parsing_note: + if coda_parsing_note: coda_statement['coda_parsing_note'] = '\nStatement Line matching results:' + coda_parsing_note else: coda_statement['coda_parsing_note'] = '' @@ -559,11 +826,11 @@ class account_coda_import(osv.osv_memory): #end for err_string = '' - err_code = '' + err_code = '' coda_id = 0 coda_note = '' line_note = '' - + try: coda_id = coda_obj.create(cr, uid,{ 'name' : codafilename, @@ -573,7 +840,7 @@ class account_coda_import(osv.osv_memory): 'user_id': uid, }) context.update({'coda_id': coda_id}) - + except osv.except_osv, e: cr.rollback() err_string = _('\nApplication Error : ') + str(e) @@ -587,78 +854,127 @@ class account_coda_import(osv.osv_memory): err_code = 'G0001' if batch: return (err_code, err_string) - raise osv.except_osv(_('CODA Import failed.'), err_string) + raise osv.except_osv(_('CODA Import failed !'), err_string) nb_err = 0 err_string = '' coda_st_ids = [] - bk_st_ids = [] - + bk_st_ids = [] + for statement in coda_statements: - + # The CODA Statement info is written to two objects: 'coda.bank.statement' and 'account.bank.statement' try: - + normal2info = False + lines = statement['coda_statement_lines'] + if not statement['first_transaction_date']: + normal2info = True # don't create a bank statement for CODA's without transactions + else: + line_vals = [x for x in lines.itervalues()] + transactions = filter(lambda x: (x['type'] in ['globalisation', 'general', 'supplier', 'customer']) and x['amount'], line_vals) + if not transactions: + normal2info = True # don't create a bank statement for CODA's without transactions + if normal2info: + statement['type'] = 'info' # don't create a bank statement for CODA's without transactions + statement['coda_parsing_note'] += _("\n\nThe CODA Statement %s does not contain transactions, hence no Bank Statement has been created." \ + "\nSelect the 'CODA Bank Statement' to check the contents of %s.") \ + %(statement['name'], statement['name']) + coda_st_id = coda_st_obj.create(cr, uid, { 'name': statement['name'], 'type': statement['type'], 'coda_bank_account_id': statement['coda_bank_account_id'], - 'currency': statement['currency_id'], + 'currency': statement['currency_id'], 'journal_id': statement['journal_id'], 'coda_id': coda_id, 'date': statement['date'], + 'coda_creation_date': statement['coda_creation_date'], 'period_id': statement['period_id'], + 'old_balance_date': statement['old_balance_date'], + 'new_balance_date': statement['new_balance_date'], 'balance_start': statement['balance_start'], 'balance_end_real': statement['balance_end_real'], - 'state':'draft', }) coda_st_ids.append(coda_st_id) - if statement['type'] == 'normal': + # check duplicates for CODA's of type 'normal' + discard = False + if statement['type'] == 'normal' and statement['discard_dup']: + dup_ids = bank_st_obj.search(cr, uid, [('name', '=', statement['name']), ('company_id', '=', company_id)]) + if dup_ids: + discard = True + statement['type'] = 'info' # don't create a bank statement for duplicates + statement['coda_parsing_note'] += _("\n\nThe Bank Statement %s already exists, hence no duplicate Bank Statement has been created." \ + "\nSelect the 'CODA Bank Statement' to check the contents of %s.") \ + %(statement['name'], statement['name']) + + # create only bank statement for CODA's of type 'normal' + if statement['type'] == 'normal' and not discard: context.update({'ebanking_import': 1}) journal = journal_obj.browse(cr, uid, statement['journal_id'], context=context) + balance_start_check_date = statement['first_transaction_date'] or statement['date'] cr.execute('SELECT balance_end_real \ FROM account_bank_statement \ WHERE journal_id = %s and date < %s \ - ORDER BY date DESC,id DESC LIMIT 1', (statement['journal_id'], statement['date'])) + ORDER BY date DESC,id DESC LIMIT 1', (statement['journal_id'], balance_start_check_date)) res = cr.fetchone() balance_start_check = res and res[0] if balance_start_check == None: if journal.default_debit_account_id and (journal.default_credit_account_id == journal.default_debit_account_id): balance_start_check = journal.default_debit_account_id.balance else: - nb_err += 1 - err_string += _('\nConfiguration Error!\nPlease verify the Default Debit and Credit Account settings in journal %s.') % journal.name + nb_err += 1 + err_string += _('\nConfiguration Error in journal %s!' \ + '\nPlease verify the Default Debit and Credit Account settings.') % journal.name break - if balance_start_check <> statement['balance_start']: - nb_err += 1 - err_string += _('\nThe CODA Statement %s Starting Balance (%.2f) does not correspond with the previous Closing Balance (%.2f) in journal %s.') \ - % (statement['name'], statement['balance_start'], balance_start_check, journal.name) + if balance_start_check <> statement['balance_start']: + balance_start_err_string = _('\nThe CODA Statement %s Starting Balance (%.2f) does not correspond with the previous Closing Balance (%.2f) in journal %s!') \ + % (statement['name'], statement['balance_start'], balance_start_check, journal.name) + if statement['balance_start_enforce']: + nb_err += 1 + err_string += balance_start_err_string break + else: + statement['coda_parsing_note'] += '\n' + balance_start_err_string - bk_st_id = bank_st_obj.create(cr, uid, { + st_vals = { 'name': statement['name'], 'journal_id': statement['journal_id'], 'coda_statement_id': coda_st_id, - 'date': statement['date'], + 'date': statement['new_balance_date'], 'period_id': statement['period_id'], 'balance_start': statement['balance_start'], 'balance_end_real': statement['balance_end_real'], 'state': 'draft', - }) + } + st_hook_error, st_vals = self._statement_hook(cr, uid, statement['coda_bank_params'], st_vals, context=context) + if st_hook_error: + nb_err += 1 + err_string += st_hook_error + break + bk_st_id = bank_st_obj.create(cr, uid, st_vals, context=context) bk_st_ids.append(bk_st_id) coda_st_obj.write(cr, uid, [coda_st_id], {'statement_id': bk_st_id}, context=context) - - glob_id_stack = [(0, '', 0, '')] # stack with tuples (glob_lvl_flag, glob_code, glob_id, glob_name) - lines = statement['coda_statement_lines'] + st_line_seq = 0 for x in lines: line = lines[x] + + if not line['type'] == 'communication': + if line['trans_family'] in st_line_name_families: + line['name'] = get_st_line_name(line, context) + if line['type'] == 'information': + if line['struct_comm_type'] in parse_comms_info: + line['name'], line['communication'] = parse_comm_info(self, cr, uid, line, comm_type_table, context) + elif line['struct_comm_type'] in parse_comms_move: + line['name'], line['communication'] = parse_comm_move(self, cr, uid, line, comm_type_table, context) + elif line['struct_comm_type'] in parse_comms_move: + line['name'], line['communication'] = parse_comm_move(self, cr, uid, line, comm_type_table, context) # handling non-transactional records : line['type'] in ['information', 'communication'] - + if line['type'] == 'information': line['globalisation_id'] = glob_id_stack[-1][2] @@ -674,25 +990,25 @@ class account_coda_import(osv.osv_memory): line['trans_category'], line['trans_category_desc'], line['struct_comm_type'], line['struct_comm_type_desc'], line['communication']) - + coda_st_line_id = coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], + 'ref': line['ref'], 'name': line['name'].strip() or '/', - 'type' : 'information', - 'date': line['entry_date'], + 'type' : 'information', + 'date': line['entry_date'], 'statement_id': coda_st_id, 'note': line_note, }) - + elif line['type'] == 'communication': line_note = _('Free Communication:\n %s') \ %(line['communication']) - + coda_st_line_id = coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], + 'ref': line['ref'], 'name': line['name'].strip() or '/', 'type' : 'communication', 'date': statement['date'], @@ -700,34 +1016,39 @@ class account_coda_import(osv.osv_memory): 'note': line_note, }) - # handling transactional records, # line['type'] in ['globalisation', 'general', 'supplier', 'customer'] + # handling transactional records, # line['type'] in ['globalisation', 'general', 'supplier', 'customer'] else: - + + if line['ref_move_detail'] == '0000': + glob_id_stack = [(0, '', 0, '')] # initialise stack with tuples (glob_lvl_flag, glob_code, glob_id, glob_name) + glob_lvl_flag = line['glob_lvl_flag'] - if glob_lvl_flag: - if glob_id_stack[-1][0] == glob_lvl_flag: + if glob_lvl_flag: + if glob_id_stack[-1][0] == glob_lvl_flag: line['globalisation_id'] = glob_id_stack[-1][2] glob_id_stack.pop() else: glob_name = line['name'].strip() or '/' glob_code = seq_obj.get(cr, uid, 'statement.line.global') glob_id = glob_obj.create(cr, uid, { - 'code': glob_code, + 'code': glob_code, 'name': glob_name, 'type': 'coda', 'parent_id': glob_id_stack[-1][2], 'amount': line['globalisation_amount'], + 'payment_reference': line['payment_reference'] }) line['globalisation_id'] = glob_id glob_id_stack.append((glob_lvl_flag, glob_code, glob_id, glob_name)) - - line_note = _('Partner name: %s \nPartner Account Number: %s' \ + + line_note = _('Partner Name: %s \nPartner Account Number: %s' \ '\nTransaction Type: %s - %s' \ '\nTransaction Family: %s - %s' \ '\nTransaction Code: %s - %s' \ '\nTransaction Category: %s - %s' \ '\nStructured Communication Type: %s - %s' \ + '\nPayment Reference: %s' \ '\nCommunication: %s') \ %(line['counterparty_name'], line['counterparty_number'], line['trans_type'], line['trans_type_desc'], @@ -735,135 +1056,208 @@ class account_coda_import(osv.osv_memory): line['trans_code'], line['trans_code_desc'], line['trans_category'], line['trans_category_desc'], line['struct_comm_type'], line['struct_comm_type_desc'], + line['payment_reference'], line['communication']) - + if line['type'] == 'globalisation': - + coda_st_line_id = coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], + 'ref': line['ref'], 'name': line['name'].strip() or '/', 'type' : 'globalisation', - 'val_date' : line['val_date'], + 'val_date' : line['val_date'], 'date': line['entry_date'], - 'globalisation_level': line['glob_lvl_flag'], - 'globalisation_amount': line['globalisation_amount'], - 'globalisation_id': line['globalisation_id'], + 'globalisation_level': line['glob_lvl_flag'], + 'globalisation_amount': line['globalisation_amount'], + 'globalisation_id': line['globalisation_id'], 'partner_id': line['partner_id'] or 0, 'account_id': line['account_id'], + 'payment_reference': line['payment_reference'], 'statement_id': coda_st_id, 'note': line_note, }) - else: # line['type'] in ['general', 'supplier', 'customer'] + else: # line['type'] in ['general', 'supplier', 'customer'] - if glob_lvl_flag == 0: + if glob_lvl_flag == 0: line['globalisation_id'] = glob_id_stack[-1][2] - if not line['account_id']: + if not line['account_id']: line['account_id'] = awaiting_acc - + coda_st_line_id = coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], - 'name': line['name'] or '/', + 'ref': line['ref'], + 'name': line['name'].strip() or '/', 'type' : line['type'], - 'val_date' : line['val_date'], + 'val_date' : line['val_date'], 'date': line['entry_date'], 'amount': line['amount'], 'partner_id': line['partner_id'] or 0, 'counterparty_name': line['counterparty_name'], - 'counterparty_bic': line['counterparty_bic'], - 'counterparty_number': line['counterparty_number'], - 'counterparty_currency': line['counterparty_currency'], + 'counterparty_bic': line['counterparty_bic'], + 'counterparty_number': line['counterparty_number'], + 'counterparty_currency': line['counterparty_currency'], 'account_id': line['account_id'], - 'globalisation_level': line['glob_lvl_flag'], - 'globalisation_id': line['globalisation_id'], + 'globalisation_level': line['glob_lvl_flag'], + 'globalisation_id': line['globalisation_id'], + 'payment_reference': line['payment_reference'], 'statement_id': coda_st_id, 'note': line_note, }) if statement['type'] == 'normal': - - st_line_seq += 1 - voucher_id = False - line_name = line['name'].strip() - if not line_name: - if line['globalisation_id']: - line_name = glob_id_stack[-1][3] - else: - line_name = '/' - - if line['reconcile']: - voucher_vals = { - 'type': line['type'] == 'supplier' and 'payment' or 'receipt', - 'name': line_name, - 'partner_id': line['partner_id'], - 'journal_id': statement['journal_id'], - 'account_id': journal.default_credit_account_id.id, - 'company_id': journal.company_id.id, - 'currency_id': journal.company_id.currency_id.id, - 'date': line['entry_date'], - 'amount': abs(line['amount']), - 'period_id': statement['period_id'], - } - voucher_id = voucher_obj.create(cr, uid, voucher_vals, context=context) - - move_line = move_line_obj.browse(cr, uid, line['reconcile'], context=context) - voucher_dict = voucher_obj.onchange_partner_id(cr, uid, [], - partner_id = line['partner_id'], - journal_id = statement['journal_id'], - price = abs(line['amount']), - currency_id = journal.company_id.currency_id.id, - ttype = line['type'] == 'supplier' and 'payment' or 'receipt', - date = line['val_date'], - context = context) - #_logger.warning('voucher_dict = %s' % voucher_dict) - voucher_line_vals = False - if voucher_dict['value']['line_ids']: - for line_dict in voucher_dict['value']['line_ids']: - if line_dict['move_line_id'] == move_line.id: - voucher_line_vals = line_dict - if voucher_line_vals: - voucher_line_vals.update({ - 'voucher_id': voucher_id, + if line['amount'] != 0.0: + st_line_seq += 1 + voucher_id = False + line_name = line['name'].strip() + if not line_name: + if line['globalisation_id']: + line_name = glob_id_stack[-1][3] or '/' + else: + line_name = '/' + + if line['reconcile']: + + move_line = move_line_obj.browse(cr, uid, line['reconcile'], context=context) + company_currency_id = journal.company_id.currency_id.id + currency_id = journal.currency.id + if currency_id and currency_id != company_currency_id: + multi_currency = True + else: + multi_currency = False + context_multi_currency = context.copy() + context_multi_currency.update({'date': line['entry_date']}) + + line_cr_ids = [] + line_dr_ids = [] + amount_remaining = abs(line['amount']) + + #for entry in entries: + if move_line.reconcile_partial_id: + amount_original = abs(move_line.amount_residual_currency) + else: + amount_original = move_line.credit or move_line.debit + if multi_currency: + if move_line.currency_id and move_line.amount_currency: + amount_original = abs(move_line.amount_currency) + else: + amount_original = currency_obj.compute(cr, uid, company_currency_id, currency_id, original_amount, context=context_multi_currency) + if amount_remaining > 0: + amount_voucher_line = min(amount_original, abs(amount_remaining)) + amount_remaining -= amount_voucher_line + else: + amount_voucher_line = 0.0 + voucher_line_vals = { + 'name': move_line.name, + 'account_id': move_line.account_id.id, + 'amount': amount_voucher_line, + 'reconcile': amount_voucher_line == amount_original, + 'type': move_line.credit and 'dr' or 'cr', + 'move_line_id': move_line.id, + } + if voucher_line_vals['type'] == 'cr': + line_cr_ids += [(0, 0, voucher_line_vals)] + else: + line_dr_ids += [(0, 0, voucher_line_vals)] + + voucher_vals = { + 'type': line['type'] == 'supplier' and 'payment' or 'receipt', + 'name': line_name, + 'date': line['val_date'], + 'journal_id': statement['journal_id'], + 'account_id': journal.default_credit_account_id.id, + 'line_cr_ids': line_cr_ids, + 'line_dr_ids': line_dr_ids, + 'pre_line': len(line_dr_ids) > 0 and True or False, + 'period_id': statement['period_id'], + 'currency_id': journal.currency and journal.currency.id or journal.company_id.currency_id.id, + 'company_id': journal.company_id.id, + 'state': 'draft', 'amount': abs(line['amount']), - }) - voucher_line_obj.create(cr, uid, voucher_line_vals, context=context) + 'reference': line['ref'], + 'number': statement['name'] + '/' + str(st_line_seq), + 'partner_id': line['partner_id'], + } + + #_logger.warn('voucher_vals=%s, context=%s', voucher_vals, context) + context['journal_id'] = journal.id # add journal to context for __get_payment_rate_currency method + if line_cr_ids or line_dr_ids: + voucher_id = voucher_obj.create(cr, uid, voucher_vals, context=context) + else: + raise osv.except_osv(_('Error!'), _("Reconcile error while processing line with ref '%s' ! " \ + "\nPlease report this issue via your OpenERP support channel.") % line['ref']) + + # override default account mapping by mappings defined in rules engine + if statement['account_mapping_ids']: + kwargs = { + 'coda_bank_account_id': statement['coda_bank_account_id'], + 'trans_type_id': line['trans_type_id'], + 'trans_family_id': line['trans_family_id'], + 'trans_code_id': line['trans_code_id'], + 'trans_category_id': line['trans_category_id'], + 'struct_comm_type_id': line['struct_comm_type_id'], + 'partner_id': line['partner_id'], + 'context': context, + } + account_id = account_mapping_obj.account_id_get(cr, uid, **kwargs) + if account_id: + line['account_id'] = account_id + + st_line_vals = { + 'ref': line['ref'], + 'name': line_name, + 'type' : line['type'], + 'val_date' : line['val_date'], + 'date': line['entry_date'], + 'amount': line['amount'], + 'partner_id': line['partner_id'] or 0, + 'counterparty_name': line['counterparty_name'], + 'counterparty_bic': line['counterparty_bic'], + 'counterparty_number': line['counterparty_number'], + 'counterparty_currency': line['counterparty_currency'], + 'account_id': line['account_id'], + 'globalisation_id': line['globalisation_id'], + 'payment_reference': line['payment_reference'], + 'statement_id': bk_st_id, + 'voucher_id': voucher_id, + 'note': line_note, + } + + st_lines_vals = self._st_line_hook(cr, uid, statement['coda_bank_params'], st_line_vals, context=context) + if not st_lines_vals: + # removal of lines by the _coda_parsing_hook currently not supported : + # this qould require resequencing/renaming of linked vouchers & moves as well as removal of associated voucher/moves + err_string += _('\nError in _st_line_hook while processing CODA Statement %s for Bank Account %s!') \ + % (statement['coda_seq_number'], (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description'])) + nb_err += 1 + for st_line_vals in st_lines_vals: + # To DO : update sequence of statement lines and naming of associated vouchers/moves when the hook returns multiple lines + st_line_vals.update({'sequence': st_line_seq}) + bank_st_line_id = bank_st_line_obj.create(cr, uid, st_line_vals, context=context) + if st_line_vals['voucher_id']: + voucher = voucher_obj.browse(cr, uid, st_line_vals['voucher_id'], context=context) + move_line = move_line_obj.browse(cr, uid, line['reconcile'], context=context) + if line['amount'] == (line['amount'] > 0 and move_line.debit or -move_line.credit): + wf_service.trg_validate(uid, 'account.voucher', st_line_vals['voucher_id'], 'proforma_voucher', cr) + if voucher.move_id: + move_line_obj.write(cr, uid, [x.id for x in voucher.move_ids], {'statement_id': bk_st_id}, context=context) - bank_st_line_id = bank_st_line_obj.create(cr, uid, { - 'sequence': st_line_seq, - 'ref': line['ref'], - 'name': line_name, - 'type' : line['type'], - 'val_date' : line['val_date'], - 'date': line['entry_date'], - 'amount': line['amount'], - 'partner_id': line['partner_id'] or 0, - 'counterparty_name': line['counterparty_name'], - 'counterparty_bic': line['counterparty_bic'], - 'counterparty_number': line['counterparty_number'], - 'counterparty_currency': line['counterparty_currency'], - 'account_id': line['account_id'], - 'globalisation_id': line['globalisation_id'], - 'statement_id': bk_st_id, - 'voucher_id': voucher_id, - 'note': line_note, - }) # end 'for x in lines' coda_st_obj.write(cr, uid, [coda_st_id], {}, context=context) # calculate balance st_balance = coda_st_obj.read(cr, uid, coda_st_id, ['balance_end', 'balance_end_real'], context=context) if st_balance['balance_end'] <> st_balance['balance_end_real']: - err_string += _('\nIncorrect ending Balance in CODA Statement %s for Bank Account %s.') \ + err_string += _('\nIncorrect ending Balance in CODA Statement %s for Bank Account %s!') \ % (statement['coda_seq_number'], (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description'])) if statement['type'] == 'normal': nb_err += 1 break else: statement['coda_parsing_note'] += '\n' + err_string - - if statement['type'] == 'normal': - bank_st_obj.button_dummy(cr, uid, [bk_st_id], context=context) # calculate balance + + if statement['type'] == 'normal': + bank_st_obj.button_dummy(cr, uid, [bk_st_id], context=context) # calculate balance journal_name = journal.name else: journal_name = _('None') @@ -879,33 +1273,38 @@ class account_coda_import(osv.osv_memory): %(journal_name, coda_version, statement['coda_seq_number'], - statement['paper_seq_number'], + statement['paper_nb_seq_number'], (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description']), statement['acc_holder'], statement['date'], float(statement['balance_start']), float(statement['balance_end_real']), - statement['coda_parsing_note']) + statement['coda_parsing_note'] % {'name':coda_statement['name']}) + if statement.get('separate_application') != '00000': + coda_note += _('\nCode Separate Application: %s') %statement['separate_application'] \ except osv.except_osv, e: cr.rollback() nb_err += 1 err_string += _('\nError ! ') + str(e) tb = ''.join(format_exception(*exc_info())) - _logger.error('Application Error while processing Statement %s\n%s' % (statement.get('name', '/'),tb)) + _logger.error('Application Error while processing Statement %s\n%s', + statement.get('name', '/'), tb) except Exception, e: cr.rollback() nb_err += 1 err_string += _('\nSystem Error : ') + str(e) tb = ''.join(format_exception(*exc_info())) - _logger.error('System Error while processing Statement %s\n%s' % (statement.get('name', '/'),tb)) + _logger.error('System Error while processing Statement %s\n%s', + statement.get('name', '/'),tb) except : cr.rollback() nb_err += 1 err_string = _('\nUnknown Error : ') + str(e) tb = ''.join(format_exception(*exc_info())) - _logger.error('Unknown Error while processing Statement %s\n%s' % (statement.get('name', '/'),tb)) + _logger.error('Unknown Error while processing Statement %s\n%s', + statement.get('name', '/'),tb) # end 'for statement in coda_statements' - + coda_note_header = _('CODA File is Imported :') coda_note_footer = _('\n\nNumber of statements : ') + str(len(coda_st_ids)) err_log = err_log + _('\nNumber of errors : ') + str(nb_err) + '\n' @@ -921,13 +1320,13 @@ class account_coda_import(osv.osv_memory): if batch: err_code = 'G0002' return (err_code, err_string) - raise osv.except_osv(_('CODA Import failed.'), err_string) - + raise osv.except_osv(_('CODA Import failed !'), err_string) + context.update({ 'bk_st_ids': bk_st_ids}) model_data_ids = mod_obj.search(cr, uid, [('model', '=', 'ir.ui.view'), ('name', '=', 'account_coda_import_result_view')], context=context) resource_id = mod_obj.read(cr, uid, model_data_ids, fields=['res_id'], context=context)[0]['res_id'] self.write(cr, uid, ids, {'note': note}, context=context) - + return { 'name': _('Import CODA File result'), 'res_id': ids[0], @@ -941,10 +1340,26 @@ class account_coda_import(osv.osv_memory): 'type': 'ir.actions.act_window', } + def _statement_hook(self, cr, uid, coda_bank_params, st_vals, context=None): + """ + Use this method to take customer specific actions based upon the bank statement data. + Returns: + st_hook_error : False or string with error message + st_vals + """ + return False, st_vals + + def _st_line_hook(self, cr, uid, coda_bank_params, st_line_vals, context=None): + """ + Use this method to adapt the statement line created by the + CODA parsing to customer specific needs. + """ + return [st_line_vals] + def action_open_coda_statements(self, cr, uid, ids, context=None): if context is None: context = {} - module, xml_id = 'l10n_be_coda', 'action_coda_bank_statements' + module, xml_id = 'account_coda', 'action_coda_bank_statements' res_model, res_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, module, xml_id) action = self.pool.get('ir.actions.act_window').read(cr, uid, res_id, context=context) domain = eval(action.get('domain') or '[]') @@ -962,11 +1377,21 @@ class account_coda_import(osv.osv_memory): domain += [('id','in', context.get('bk_st_ids', False))] action.update({'domain': domain}) return action - + account_coda_import() +def repl_special(s): + s = s.replace("\'", "\'" + "'") + return s + def str2date(date_str): - return time.strftime('%Y-%m-%d', time.strptime(date_str,'%d%m%y')) + try: + return time.strftime('%Y-%m-%d', time.strptime(date_str,'%d%m%y')) + except: + return False + +def str2time(time_str): + return time_str[:2] + ':' + time_str[2:] def str2float(str): try: @@ -975,9 +1400,517 @@ def str2float(str): return 0.0 def list2float(lst): - try: - return str2float((lambda s : s[:-3] + '.' + s[-3:])(lst)) - except: - return 0.0 + try: + return str2float((lambda s : s[:-3] + '.' + s[-3:])(lst)) + except: + return 0.0 -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: +def number2float(s, d): + try: + return float(s[:len(s)-d] + '.' + s[len(s)-d:]) + except: + return False + +def _get_acc_numbers(acc_number): + #TODO this method is needed because the iban and bank account fields have been merged together. But sometimes we + # need to retrieve the normal bank account from the IBAN. This should be globalized and defined as a method on the + # bank account class. Each country part of the IBAN area should define its own code to do so. + acc_number = acc_number.replace(' ', '') + if acc_number.lower().startswith('be'): + return [acc_number[4:], acc_number] + return [acc_number] + +from base_iban.base_iban import _ref_iban, _format_iban + +def calc_iban_checksum(country, bban): + bban = bban.replace(' ', '').upper() + country.upper() + '00' + base = '' + for c in bban: + if c.isdigit(): + base += c + else: + base += str(ord(c) - ord('A') + 10) + kk = 98 - int(base) % 97 + return str(kk).rjust(2, '0') + +def check_bban(country, bban): + if country == 'BE': + try: + int(bban) + except: + return False + if len(bban) != 12: + return False + return True + +def check_iban(iban): + """ + Check the IBAN number (logic partially based upon base_iban module, cf. is_iban_valid method) + """ + iban = _format_iban(iban).lower() + if iban[:2] not in _ref_iban: + return False + if len(iban) != len(_format_iban(_ref_iban[iban[:2]])): + return False + #the four first digits have to be shifted to the end + iban = iban[4:] + iban[:4] + #letters have to be transformed into numbers (a = 10, b = 11, ...) + iban2 = "" + for char in iban: + if char.isalpha(): + iban2 += str(ord(char)-87) + else: + iban2 += char + #iban is correct if modulo 97 == 1 + return int(iban2) % 97 == 1 + +def get_bank(self, cr, uid, bic, iban): + + country_obj = self.pool.get('res.country') + bank_obj = self.pool.get('res.bank') + + bank_id = False + bank_name = False + feedback = False + bank_country = iban[:2] + try: + bank_country_id = country_obj.search(cr, uid, [('code', '=', bank_country)])[0] + except: + feedback = _("\n Bank lookup failed due to missing Country definition for Country Code '%s' !") \ + % (bank_country) + else: + if iban[:2] == 'BE' and 'code' in bank_obj.fields_get_keys(cr, uid): + # To DO : extend for other countries + bank_code = iban[4:7] + if bic: + bank_ids = bank_obj.search(cr, uid, [('bic', '=', bic), ('code', '=', bank_code), ('country', '=', bank_country_id)]) + if bank_ids: + bank_id = bank_ids[0] + else: + bank_id = bank_obj.create(cr, uid, { + 'name': bic, + 'code': bank_code, + 'bic': bic, + 'country': bank_country_id, + }) + else: + bank_ids = bank_obj.search(cr, uid, [('code', '=', bank_code), ('country', '=', bank_country_id)]) + if bank_ids: + bank_id = bank_ids[0] + bank_data = bank_obj.read(cr, uid, bank_id, fields=['bic', 'name']) + bic = bank_data['bic'] + bank_name = bank_data['name'] + else: + country = country_obj.browse(cr, uid, bank_country_id) + feedback = _("\n Bank lookup failed. Please define a Bank with Code '%s' and Country '%s' !") \ + % (bank_code, country.name) + else: + if not bic: + feedback = _("\n Bank lookup failed due to missing BIC in Bank Statement for IBAN '%s' !") \ + % (iban) + else: + bank_ids = bank_obj.search(cr, uid, [('bic', '=', bic), ('country', '=', bank_country_id)]) + if not bank_ids: + bank_name = bic + bank_id = bank_obj.create(cr, uid, { + 'name': bank_name, + 'bic': bic, + 'country': bank_country_id, + }) + else: + bank_id = bank_ids[0] + + return bank_id, bic, bank_name, feedback + +def update_partner_bank(self, cr, uid, bic, iban, partner_id, counterparty_name): + partner_bank_obj = self.pool.get('res.partner.bank') + bank_id = False + feedback = False + if check_iban(iban): + bank_id, bic, bank_name, feedback = get_bank(self, cr, uid, bic, iban) + if not bank_id: + return feedback + else: + bban = iban + #convert belgian BBAN numbers to IBAN + if check_bban('BE', iban): + kk = calc_iban_checksum('BE', iban) + iban = 'BE' + kk + iban + bank_id, bic, bank_name, feedback = get_bank(self, cr, uid, bic, iban) + if not bank_id: + return feedback + + if bank_id: + partner_bank_id = partner_bank_obj.create(cr, uid, { + 'partner_id': partner_id, + 'name': counterparty_name, + 'bank': bank_id, + 'state': 'iban', + 'bank_bic': bic, + 'bank_name': bank_name, + 'acc_number': iban, + }) + return feedback + +indent = '\n' + 8*' ' +st_line_name_families = ['13', '35', '41', '80'] +parse_comms_move = ['100', '101', '102', '103', '105', '106', '107', '108', '111', '113', '114', '115', '121', '122', '123', '124', '125', '126', '127'] +parse_comms_info = ['001', '002', '004', '005', '006', '007', '107', '008', '009', '010', '011'] + +def get_st_line_name(line, context): + #_logger.warn('get_st_line_name - entry').warn('ref = %s, family = %s, code = %s, categ = %s', line['ref'], line['trans_family'], line['trans_code'], line['trans_category']) + st_line_name = line['name'] + + if line['trans_family'] == '35' and line['trans_code'] in ['01', '37']: + st_line_name = ', '.join([_('Closing'), line['trans_code_desc'], line['trans_category_desc']]) + + if line['trans_family'] in ['13', '41']: + st_line_name = ', '.join([line['trans_family_desc'], line['trans_code_desc'], line['trans_category_desc']]) + + if line['trans_family'] in ['80']: + st_line_name = ', '.join([line['trans_code_desc'], line['trans_category_desc']]) + + return st_line_name + +def parse_comm_move(self, cr, uid, line, comm_type_table, context): + #_logger.warn('parse_comm_move - entry, ref = %s, family = %s, code = %s, categ = %s, comm_type = %s, name = %s', line['ref'], line['trans_family'], line['trans_code'], line['trans_category'], line['struct_comm_type'], line['name']) + comm_type = line['struct_comm_type'] + comm = st_line_comm = line['communication'] + st_line_name = line['name'] + + if comm_type in ['115', '121', '122', '126']: + _logger.warn('The parsing of Structured Commmunication Type %s has not yet been implemented. ' \ + 'Please contact Noviat (info@noviat.be) for more information about the development roadmap', comm_type) + + if comm_type == '100': + st_line_name = _('Payment with ISO 11649 structured format communication') + st_line_comm = '\n' + indent + _('Payment with a structured format communication applying the ISO standard 11649') + ':' + st_line_comm += indent + _('Structured creditor reference to remittance information') + st_line_comm += indent + comm + + if comm_type in ['101', '102']: + st_line_name = st_line_comm = '+++' + comm[0:3] + '/' + comm[3:7] + '/' + comm[7:12] + '+++' + + if comm_type == '103': + st_line_name = ', '.join([line['trans_family_desc'], _('Number')]) + st_line_comm = comm + + if comm_type == '105': + st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] + amount_1 = list2float(comm[0:15]) + amount_2 = list2float(comm[15:30]) + rate = number2float(comm[30:42], 8) + currency = comm[42:45] + struct_format_comm = comm[45:57].strip() + country_code = comm[57:59] + amount_3 = list2float(comm[59:74]) + st_line_comm = '\n' + indent + st_line_name + indent + _('Gross amount in the currency of the account') + ': %.2f' % amount_1 + st_line_comm += indent + _('Gross amount in the original currency') + ': %.2f' % amount_2 + st_line_comm += indent + _('Rate') + ': %.4f' % rate + st_line_comm += indent + _('Currency') + ': %s' % currency + st_line_comm += indent + _('Structured format communication') + ': %s' % struct_format_comm + st_line_comm += indent + _('Country code of the principal') + ': %s' % country_code + st_line_comm += indent + _('Equivalent in EUR') + ': %.2f' % amount_3 + + if comm_type == '106': + if not st_line_name and line['trans_family'] not in st_line_name_families: + st_line_name = _('VAT, withholding tax on income, commission, etc.') + interest = comm[30:42].strip('0') + st_line_comm = '\n' + indent + st_line_name + indent + _('Equivalent in the currency of the account') + ': %.2f' % list2float(comm[0:15]) + st_line_comm += indent + _('Amount on which % is calculated') + ': %.2f' % list2float(comm[15:30]) + st_line_comm += indent + _('Percent') + ': %.4f' % number2float(comm[30:42], 8) + st_line_comm += indent + (comm[42] == 1 and _('Minimum applicable') or _('Minimum not applicable')) + st_line_comm += indent + _('Equivalent in EUR') + ': %.2f' % list2float(comm[43:58]) + + if comm_type == '107': + paid_refusals = { + '0': _('paid'), + '1': _('direct debit cancelled or nonexistent'), + '2': _('refusal - other reason'), + 'D': _('payer disagrees'), + 'E': _('direct debit number linked to another identification number of the creditor')} + st_line_name = _('Direct debit - DOM\'80') + direct_debit_number = comm[0:12].strip() + pivot_date = str2date(comm[12:18]) + comm_zone = comm[18:48] + paid_refusal = paid_refusals.get(comm[48], '') + creditor_number = comm[49:60].strip() + st_line_comm = '\n' + indent + st_line_name + indent + _('Direct Debit Number') + ': %s' % direct_debit_number + st_line_comm += indent + _('Central (Pivot) Date') + ': %s' % pivot_date + st_line_comm += indent + _('Communication Zone') + ': %s' % comm_zone + st_line_comm += indent + _('Paid or reason for refusal') + ': %s' % paid_refusal + st_line_comm += indent + _("Creditor's Number") + ': %s' % creditor_number + + if comm_type == '108': + st_line_name = _('Closing, period from %s to %s') % (str2date(comm[42:48]), str2date(comm[48:54])) + interest = comm[30:42].strip('0') + st_line_comm = '\n' + indent + st_line_name + indent + _('Equivalent in the currency of the account') + ': %.2f' % list2float(comm[0:15]) + if interest: + st_line_comm += indent + _('Interest rates, calculation basis') + ': %.2f' % list2float(comm[15:30]) + \ + indent + _('Interest') + ': %.2f' % list2float(comm[30:42]) + + if comm_type =='111': + card_schemes = { + '1': 'Bancontact/Mister Cash', + '2': _('Private'), + '3': 'Maestro', + '5': 'TINA', + '9': _('Other')} + trans_types = { + '1': _('Withdrawal'), + '2': _('Cumulative on network'), + '7': _('Distribution sector'), + '8': _('Teledata'), + '9': _('Fuel')} + st_line_name = _('POS credit - globalisation') + card_scheme = card_schemes.get(comm[0], '') + pos_number = comm[1:7].strip() + period_number = comm[7:10].strip() + first_sequence_number = comm[10:16].strip() + trans_first_date = str2date(comm[16:22]) + last_sequence_number = comm[22:28].strip() + trans_last_date = str2date(comm[28:34]) + trans_type = trans_types.get(comm[34], '') + terminal_name = comm[35:50].strip() + terminal_city = comm[51:60].strip() + st_line_comm = '\n' + indent + st_line_name + indent + _('Card Scheme') + ': %s' % card_scheme + st_line_comm += indent + _('POS Number') + ': %s' % pos_number + st_line_comm += indent + _('Period Number') + ': %s' % period_number + st_line_comm += indent + _('First Transaction Sequence Number') + ': %s' % first_sequence_number + st_line_comm += indent + _('Date of first transaction') + ': %s' % trans_first_date + st_line_comm += indent + _('Last Transaction Sequence Number') + ': %s' % last_sequence_number + st_line_comm += indent + _('Date of last transaction') + ': %s' % trans_last_date + st_line_comm += indent + _('Transaction Type') + ': %s' % trans_type + st_line_comm += indent + _('Terminal Identification') + ': %s' % terminal_name + ', ' + terminal_city + + if comm_type == '113': + card_schemes = { + '1': 'Bancontact/Mister Cash', + '2': 'Maestro', + '3': _('Private'), + '9': _('Other')} + trans_types = { + '1': _('Withdrawal'), + '2': _('Proton loading'), + '3': _('Reimbursement Proton balance'), + '4': _('Reversal of purchases'), + '7': _('Distribution sector'), + '8': _('Teledata'), + '9': _('Fuel')} + product_codes = { + '01': _('premium with lead substitute'), + '02': _('europremium'), + '03': _('diesel'), + '04': _('LPG'), + '06': _('premium plus 98 oct'), + '07': _('regular unleaded'), + '08': _('domestic fuel oil'), + '09': _('lubricants'), + '10': _('petrol'), + '11': _('premium 99+'), + '12': _('Avgas'), + '16': _('other types'), + } + st_line_name = _('ATM/POS debit') + card_number = comm[0:16].strip() + card_scheme = card_schemes.get(comm[16], '') + terminal_number = comm[17:23].strip() + sequence_number = comm[23:29].strip() + trans_date = comm[29:35].strip() and str2date(comm[29:35]) or '' + trans_hour = comm[35:39].strip() and str2time(comm[35:39]) or '' + trans_type = trans_types.get(comm[39], '') + terminal_name = comm[40:56].strip() + terminal_city = comm[56:66].strip() + orig_amount = comm[66:81].strip() and list2float(comm[66:81]) + rate = number2float(comm[81:93], 8) + currency = comm[93:96] + volume = number2float(comm[96:101], 2) + product_code = product_codes.get(comm[101:103], '') + unit_price = number2float(comm[103:108], 2) + st_line_comm = '\n' + indent + st_line_name + indent + _('Card Number') + ': %s' % card_number + st_line_comm += indent + _('Card Scheme') + ': %s' % card_scheme + if terminal_number: + st_line_comm += indent + _('Terminal Number') + ': %s' % terminal_number + st_line_comm += indent + _('Transaction Sequence Number') + ': %s' % sequence_number + st_line_comm += indent + _('Time') + ': %s' % trans_date + ' ' + trans_hour + st_line_comm += indent + _('Transaction Type') + ': %s' % trans_type + st_line_comm += indent + _('Terminal Identification') + ': %s' % terminal_name + ', ' + terminal_city + if orig_amount: + st_line_comm += indent + _('Original Amount') + ': %.2f' % orig_amount + st_line_comm += indent + _('Rate') + ': %.4f' % rate + st_line_comm += indent + _('Currency') + ': %s' % currency + if volume: + st_line_comm += indent + _('Volume') + ': %.2f' % volume + if product_code: + st_line_comm += indent + _('Product Code') + ': %s' % product_code + if unit_price: + st_line_comm += indent + _('Unit Price') + ': %.2f' % unit_price + + if comm_type == '114': + card_schemes = { + '1': 'Bancontact/Mister Cash', + '2': 'Maestro', + '3': _('Private'), + '5': 'TINA', + '9': _('Other')} + trans_types = { + '1': _('Withdrawal'), + '7': _('Distribution sector'), + '8': _('Teledata'), + '9': _('Fuel')} + st_line_name = _('POS credit - individual transaction') + card_scheme = card_schemes.get(comm[0], '') + pos_number = comm[1:7].strip() + period_number = comm[7:10].strip() + sequence_number = comm[10:16].strip() + trans_date = str2date(comm[16:22]) + trans_hour = str2time(comm[22:26]) + trans_type = trans_types.get(comm[26], '') + terminal_name = comm[27:43].strip() + terminal_city = comm[43:53].strip() + trans_reference = comm[53:69].strip() + st_line_comm = '\n' + indent + st_line_name + indent + _('Card Scheme') + ': %s' % card_scheme + st_line_comm += indent + _('POS Number') + ': %s' % pos_number + st_line_comm += indent + _('Period Number') + ': %s' % period_number + st_line_comm += indent + _('Transaction Sequence Number') + ': %s' % sequence_number + st_line_comm += indent + _('Time') + ': %s' % trans_date + ' ' + trans_hour + st_line_comm += indent + _('Transaction Type') + ': %s' % trans_type + st_line_comm += indent + _('Terminal Identification') + ': %s' % terminal_name + ', ' + terminal_city + st_line_comm += indent + _('Transaction Reference') + ': %s' % trans_reference + + if comm_type == '123': + starting_date = str2date(comm[0:6]) + maturity_date = comm[6:12] == '999999' and _('guarantee without fixed term') or str2date(comm[0:6]) + basic_amount = list2float(comm[12:27]) + percent = number2float(comm[27:39], 8) + term = comm[39:43].lstrip('0') + minimum = comm[43] == '1' and True or False + guarantee_number = comm[44:57].strip() + st_line_comm = '\n' + indent + st_line_name + indent + _('Starting Date') + ': %s' % starting_date + st_line_comm += indent + _('Maturity Date') + ': %s' % maturity_date + st_line_comm += indent + _('Basic Amount') + ': %.2f' % basic_amount + st_line_comm += indent + _('Percentage') + ': %.4f' % percent + st_line_comm += indent + _('Term in days') + ': %s' % term + st_line_comm += indent + (minimum and _('Minimum applicable') or _('Minimum not applicable')) + st_line_comm += indent + _('Guarantee Number') + ': %s' % guarantee_number + + if comm_type == '124': + card_issuers = { + '1': 'Mastercard', + '2': 'Visa', + '3': 'American Express', + '4': 'Diners Club', + '9': _('Other')} + st_line_name = _('Settlement credit cards') + card_number = comm[0:20].strip() + card_issuer = card_issuers.get(comm[20], '') + invoice_number = comm[21:33].strip() + identification_number = comm[33:48].strip() + date = comm[48:54].strip() and str2date(comm[48:54]) or '' + st_line_comm = '\n' + indent + st_line_name + indent + _('Card Number') + ': %s' % card_number + st_line_comm += indent + _('Issuing Institution') + ': %s' % card_issuer + st_line_comm += indent + _('Invoice Number') + ': %s' % invoice_number + st_line_comm += indent + _('Identification Number') + ': %s' % identification_number + st_line_comm += indent + _('Date') + ': %s' % date + + if comm_type == '125': + if line['trans_family'] not in st_line_name_families: + st_line_name = _('Credit') + credit_account = comm[0:27].strip() + if check_bban('BE', credit_account): + credit_account = '-'.join([credit_account[:3], credit_account[3:10], credit_account[10:]]) + old_balance = list2float(comm[27:42]) + new_balance = list2float(comm[42:57]) + amount = list2float(comm[57:72]) + currency = comm[72:75] + start_date = str2date(comm[75:81]) + end_date = str2date(comm[81:87]) + rate = number2float(comm[87:99], 8) + trans_reference = comm[99:112].strip() + st_line_comm = '\n' + indent + st_line_name + indent + _('Credit Account Number') + ': %s' % credit_account + st_line_comm += indent + _('Old Balance') + ': %.2f' % old_balance + st_line_comm += indent + _('New Balance') + ': %.2f' % new_balance + st_line_comm += indent + _('Amount') + ': %.2f' % amount + st_line_comm += indent + _('Currency') + ': %s' % currency + st_line_comm += indent + _('Starting Date') + ': %s' % start_date + st_line_comm += indent + _('End Date') + ': %s' % end_date + st_line_comm += indent + _('Nominal Interest Rate or Rate of Charge') + ': %.4f' % rate + st_line_comm += indent + _('Transaction Reference') + ': %s' % trans_reference + + if comm_type == '127': + direct_debit_types = { + '0': _('unspecified'), + '1': _('recurrent'), + '2': _('one-off'), + '3': _('1-st (recurrent)'), + '4': _('last (recurrent)')} + direct_debit_schemes = { + '0': _('unspecified'), + '1': _('SEPA core'), + '2': _('SEPA B2B')} + paid_refusals = { + '0': _('paid'), + '1': _('technical problem'), + '2': _('refusal - reason not specified'), + '3': _('debtor disagrees'), + '4': _('debtor\'s account problem')} + R_types = { + '0': _('paid'), + '1': _('reject'), + '2': _('return'), + '3': _('refund'), + '4': _('reversal'), + '5': _('cancellation')} + st_line_name = _('European direct debit (SEPA)') + settlement_date = str2date(comm[0:6]) + direct_debit_type = direct_debit_types.get(comm[6], '') + direct_debit_scheme = direct_debit_schemes.get(comm[7], '') + paid_refusal = paid_refusals.get(comm[8], '') + creditor_id = comm[9:44].strip() + mandate_ref = comm[44:79].strip() + comm_zone = comm[79:141] + R_type = R_types.get(comm[141], '') + reason = comm[142:146].strip() + st_line_comm = '\n' + indent + st_line_name + indent + _('Settlement_Date') + ': %s' % settlement_date + st_line_comm += indent + _('Direct Debit Type') + ': %s' % direct_debit_type + st_line_comm += indent + _('Direct Debit Scheme') + ': %s' % direct_debit_scheme + st_line_comm += indent + _('Paid or reason for refusal') + ': %s' % paid_refusal + st_line_comm += indent + _('Creditor\'s Identification Code') + ': %s' % creditor_id + st_line_comm += indent + _('Mandate Reference') + ': %s' % mandate_ref + st_line_comm += indent + _('Communication') + ': %s' % comm_zone + st_line_comm += indent + _('R transaction Type') + ': %s' % R_type + st_line_comm += indent + _('Reason') + ': %s' % reason + + return st_line_name, st_line_comm + +def parse_comm_info(self, cr, uid, line, comm_type_table, context): + comm_type = line['struct_comm_type'] + comm = st_line_comm = line['communication'] + st_line_name = line['name'] + + if comm_type == '001': + st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] + st_line_comm = '\n' + indent + st_line_name + indent + _('Name') + ': %s' % comm[0:70].strip() + st_line_comm += indent + _('Street') + ': %s' % comm[70:105].strip() + st_line_comm += indent + _('Locality') + ': %s' % comm[105:140].strip() + st_line_comm += indent + _('Identification Code') + ': %s' % comm[140:175].strip() + + if comm_type in ['002', '004', '005']: + st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] + st_line_comm = comm.strip() + + if comm_type == '006': + amount_sign = comm[48] + amount = (comm[48] == '1' and '-' or '') + ('%.2f' % list2float(comm[33:48])) + ' ' + comm[30:33] + st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] + st_line_comm = '\n' + indent + st_line_name + indent + _('Description of the detail') + ': %s' % comm[0:30].strip() + st_line_comm += indent + _('Amount') + ': %s' % amount + st_line_comm += indent + _('Category') + ': %s' % comm[49:52].strip() + + if comm_type not in ['001', '002', '004', '005', '006']: + _logger.warn('The parsing of Structured Commmunication Type %s has not yet been implemented. ' \ + 'Please contact Noviat (info@noviat.be) for more information about the development roadmap', comm_type) + + return st_line_name, st_line_comm + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file From d963fb81869b60044c69bb56b0511accbc249b86 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 30 Nov 2012 20:29:38 +0100 Subject: [PATCH 04/41] [FIX]Delete name_company_uniq constraint in bank statement bzr revid: dle@openerp.com-20121130192938-qj9wu6iztkg7helz --- addons/l10n_be_coda/l10n_be_coda.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py index f9dfa3a686a..f24536ab59f 100644 --- a/addons/l10n_be_coda/l10n_be_coda.py +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -347,9 +347,9 @@ class account_bank_statement(osv.osv): _columns = { 'coda_statement_id': fields.many2one('coda.bank.statement', 'Associated CODA Bank Statement'), } - _sql_constraints = [ - ('name_company_uniq', 'unique (name,company_id)', 'The name of the Bank Statement must be unique per company !') - ] + # _sql_constraints = [ + # ('name_company_uniq', 'unique (name,company_id)', 'The name of the Bank Statement must be unique per company !') + # ] def unlink(self, cr, uid, ids, context=None): if context is None: From 2bfd5ecdf750dfa4bcc1912ed9723e4228bc3ff5 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Mon, 3 Dec 2012 11:21:12 +0100 Subject: [PATCH 05/41] [FIX]Syntax according to sublime-linter, remove of unused variables bzr revid: dle@openerp.com-20121203102112-jsxy7th8v0bfolv4 --- addons/l10n_be_coda/l10n_be_coda.py | 200 +++--- addons/l10n_be_coda/res_bank.py | 5 +- .../wizard/account_coda_import.py | 586 +++++++++--------- 3 files changed, 406 insertions(+), 385 deletions(-) diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py index f24536ab59f..cc11c72cf06 100644 --- a/addons/l10n_be_coda/l10n_be_coda.py +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -2,9 +2,9 @@ ############################################################################## # # OpenERP, Open Source Management Solution -# +# # Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. -# +# # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the @@ -26,12 +26,13 @@ from tools.translate import _ import logging _logger = logging.getLogger(__name__) + class coda_bank_account(osv.osv): - _name= 'coda.bank.account' - _description= 'CODA Bank Account Configuration' + _name = 'coda.bank.account' + _description = 'CODA Bank Account Configuration' def _check_account_pain(self, cr, uid, context=None): - res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_pain'), ('state','=','installed')]) + res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_pain'), ('state', '=', 'installed')]) return res and True or False def _check_currency(self, cr, uid, ids, context=None): @@ -45,7 +46,7 @@ class coda_bank_account(osv.osv): _columns = { 'name': fields.char('Name', size=64, required=True), - 'bank_id': fields.many2one('res.partner.bank', 'Bank Account', required=True, + 'bank_id': fields.many2one('res.partner.bank', 'Bank Account', required=True, help='Bank Account Number.\nThe CODA import function will find its CODA processing parameters on this number.'), 'description1': fields.char('Primary Account Description', size=35, help='The Primary or Secondary Account Description should match the corresponding Account Description in the CODA file.'), @@ -53,15 +54,15 @@ class coda_bank_account(osv.osv): help='The Primary or Secondary Account Description should match the corresponding Account Description in the CODA file.'), 'state': fields.selection([ ('normal', 'Normal'), - ('info', 'Info')], + ('info', 'Info')], 'Type', required=True, select=1, help='No Bank Statements will be generated for CODA Bank Statements from Bank Accounts of type \'Info\'.'), - 'journal': fields.many2one('account.journal', 'Journal', - domain=[('type', '=', 'bank')], - states={'normal':[('required',True)],'info':[('required',False)]}, + 'journal': fields.many2one('account.journal', 'Journal', + domain=[('type', '=', 'bank')], + states={'normal': [('required', True)], 'info': [('required', False)]}, help='Bank Journal for the Bank Statement'), 'currency': fields.many2one('res.currency', 'Currency', required=True, - help='The currency of the CODA Bank Statement'), + help='The currency of the CODA Bank Statement'), 'coda_st_naming': fields.char('Bank Statement Naming Policy', size=64, help="Define the rules to create the name of the Bank Statements generated by the CODA processing." \ "\nE.g. %(code)s%(y)s/%(paper)s" \ @@ -73,14 +74,14 @@ class coda_bank_account(osv.osv): "\nPaper Statement sequence number (as specified on 'Old Balance' record): %(paper_ob)s" \ "\nPaper Statement sequence number (as specified on 'New Balance' record): %(paper)s"), 'awaiting_account': fields.many2one('account.account', 'Default Account for Unrecognized Movement', domain=[('type', '!=', 'view')], required=True, - help= 'Set here the default account that will be used if the partner cannot be unambiguously identified.'), + help='Set here the default account that will be used if the partner cannot be unambiguously identified.'), 'transfer_account': fields.many2one('account.account', 'Default Internal Transfer Account', domain=[('code', 'like', '58%'), ('type', '!=', 'view')], required=True, - help= 'Set here the default account that will be used for internal transfer between own bank accounts (e.g. transfer between current and deposit bank accounts).'), + help='Set here the default account that will be used for internal transfer between own bank accounts (e.g. transfer between current and deposit bank accounts).'), 'account_mapping_ids': fields.one2many('coda.account.mapping.rule', 'coda_bank_account_id', 'Account Mapping Rules'), - 'find_payment': fields.boolean('Lookup Payment Reference', + 'find_payment': fields.boolean('Lookup Payment Reference', help='Invoice lookup and reconciliation via the SEPA EndToEndReference.' \ '\nInstall the \'account_pain\' module if you want to take advantage of this feature.'), - 'find_bbacom': fields.boolean('Lookup Structured Communication of type \'BBA\'', + 'find_bbacom': fields.boolean('Lookup Structured Communication of type \'BBA\'', help='Partner lookup and reconciliation via the \'BBA\' Structured Communication.' \ '\nA partial reconciliation will be created when there is no exact match between the Invoice and Bank Transaction amounts.'), 'find_inv_number': fields.boolean('Lookup Invoice Number', @@ -93,22 +94,22 @@ class coda_bank_account(osv.osv): 'balance_start_enforce': fields.boolean('Prevent invalid Opening Balances', help="Do not process Statements with an Opening Balance that doesn't match the previous Closing Balance."), 'discard_dup': fields.boolean('Discard Duplicates', - help="Duplicate Bank Statements will be discarded. Select the corresponding 'CODA Bank Statement' in order to view the contents of such duplicates."), + help="Duplicate Bank Statements will be discarded. Select the corresponding 'CODA Bank Statement' in order to view the contents of such duplicates."), 'active': fields.boolean('Active', help='If the active field is set to False, it will allow you to hide the Bank Account without removing it.'), 'company_id': fields.many2one('res.company', 'Company', required=True), } _defaults = { - 'currency': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, + 'currency': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, 'state': 'normal', 'coda_st_naming': '%(code)s/%(y)s/%(coda)s', - 'active': True, + 'active': True, 'find_payment': _check_account_pain, 'find_bbacom': True, - 'find_inv_number': True, - 'find_partner': True, - 'update_partner': True, + 'find_inv_number': True, + 'find_partner': True, + 'update_partner': True, 'balance_start_enforce': True, - 'company_id': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id, + 'company_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id, } _sql_constraints = [ ('account_uniq_1', 'unique (bank_id, description1, currency)', 'The combination of Bank Account, Account Description and Currency must be unique !'), @@ -133,42 +134,41 @@ class coda_bank_account(osv.osv): if not default: default = {} default = default.copy() - default.update({'journal_id': None}) + default.update({'journal_id': None}) default['description1'] = cba['description1'] or '' default['description2'] = cba['description2'] or '' default['name'] = (cba['name'] or '') + ' (copy)' - default['state'] = cba['state'] - return super(coda_bank_account, self).copy(cr, uid, id, default, context) + default['state'] = cba['state'] + return super(coda_bank_account, self).copy(cr, uid, id, default, context) def onchange_state(self, cr, uid, ids, state): - return state =='info' and {'value': {'journal': None}} or {} + return state == 'info' and {'value': {'journal': None}} or {} coda_bank_account() - class account_coda(osv.osv): _name = 'account.coda' _description = 'Object to store CODA Data Files' _order = 'coda_creation_date desc' _columns = { - 'name': fields.char('CODA Filename',size=128, readonly=True), + 'name': fields.char('CODA Filename', size=128, readonly=True), 'coda_data': fields.binary('CODA File', readonly=True), - 'statement_ids': fields.one2many('coda.bank.statement','coda_id','Generated CODA Bank Statements', readonly=True), + 'statement_ids': fields.one2many('coda.bank.statement', 'coda_id', 'Generated CODA Bank Statements', readonly=True), 'note': fields.text('Import Log', readonly=True), 'coda_creation_date': fields.date('CODA Creation Date', readonly=True, select=True), 'date': fields.date('Import Date', readonly=True, select=True), - 'user_id': fields.many2one('res.users','User', readonly=True, select=True), + 'user_id': fields.many2one('res.users', 'User', readonly=True, select=True), 'company_id': fields.many2one('res.company', 'Company', readonly=True) } _defaults = { 'date': fields.date.context_today, - 'user_id': lambda self,cr,uid,context: uid, - 'company_id': lambda s,cr,uid,c: s.pool.get('res.company')._company_default_get(cr, uid, 'account.coda', context=c), - } + 'user_id': lambda self, cr, uid, context: uid, + 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'account.coda', context=c), + } _sql_constraints = [ ('coda_uniq', 'unique (name, coda_creation_date)', 'This CODA has already been imported !') - ] + ] def unlink(self, cr, uid, ids, context=None): if context is None: @@ -177,22 +177,23 @@ class account_coda(osv.osv): coda_st_obj = self.pool.get('coda.bank.statement') bank_st_obj = self.pool.get('account.bank.statement') for coda in self.browse(cr, uid, ids, context=context): - for coda_statement in coda.statement_ids: + for coda_statement in coda.statement_ids: if not context.get('coda_statement_unlink', False): if coda_st_obj.exists(cr, uid, coda_statement.id, context=context): - coda_st_obj.unlink(cr, uid, [coda_statement.id], context=context) + coda_st_obj.unlink(cr, uid, [coda_statement.id], context=context) if not context.get('bank_statement_unlink', False): if coda_st_obj.exists(cr, uid, coda_statement.id, context=context) and (coda_statement.type == 'normal') and bank_st_obj.exists(cr, uid, coda_statement.statement_id.id, context=context): - bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) + bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) context.update({'coda_unlink': False}) return super(account_coda, self).unlink(cr, uid, ids, context=context) - + account_coda() -class account_coda_trans_type(osv.osv): + +class account_coda_trans_type(osv.osv): _name = 'account.coda.trans.type' _description = 'CODA transaction type' - _rec_name = 'type' + _rec_name = 'type' _columns = { 'type': fields.char('Transaction Type', size=1, required=True), 'parent_id': fields.many2one('account.coda.trans.type', 'Parent'), @@ -200,49 +201,53 @@ class account_coda_trans_type(osv.osv): } account_coda_trans_type() -class account_coda_trans_code(osv.osv): + +class account_coda_trans_code(osv.osv): _name = 'account.coda.trans.code' _description = 'CODA transaction code' - _rec_name = 'code' + _rec_name = 'code' _columns = { 'code': fields.char('Code', size=2, required=True, select=1), 'type': fields.selection([ ('code', 'Transaction Code'), - ('family', 'Transaction Family')], - 'Type', required=True, select=1), + ('family', 'Transaction Family')], + 'Type', required=True, select=1), 'parent_id': fields.many2one('account.coda.trans.code', 'Family', select=1), 'description': fields.char('Description', size=128, translate=True, select=2), 'comment': fields.text('Comment', translate=True), } account_coda_trans_code() -class account_coda_trans_category(osv.osv): + +class account_coda_trans_category(osv.osv): _name = 'account.coda.trans.category' _description = 'CODA transaction category' - _rec_name = 'category' + _rec_name = 'category' _columns = { 'category': fields.char('Transaction Category', size=3, required=True), 'description': fields.char('Description', size=256, translate=True), } account_coda_trans_category() -class account_coda_comm_type(osv.osv): + +class account_coda_comm_type(osv.osv): _name = 'account.coda.comm.type' _description = 'CODA structured communication type' - _rec_name = 'code' + _rec_name = 'code' _columns = { 'code': fields.char('Structured Communication Type', size=3, required=True, select=1), 'description': fields.char('Description', size=128, translate=True), } _sql_constraints = [ - ('code_uniq', 'unique (code)','The Structured Communication Code must be unique !') + ('code_uniq', 'unique (code)', 'The Structured Communication Code must be unique !') ] account_coda_comm_type() + class coda_bank_statement(osv.osv): - _name = 'coda.bank.statement' - _description = 'CODA Bank Statement' - + _name = 'coda.bank.statement' + _description = 'CODA Bank Statement' + def _default_journal_id(self, cr, uid, context={}): if context.get('journal_id', False): return context['journal_id'] @@ -276,16 +281,16 @@ class coda_bank_statement(osv.osv): 'coda_id': fields.many2one('account.coda', 'CODA Data File', ondelete='cascade'), 'type': fields.selection([ ('normal', 'Normal'), - ('info', 'Info')], + ('info', 'Info')], 'Type', required=True, readonly=True, help='No Bank Statements are associated with CODA Bank Statements of type \'Info\'.'), - 'statement_id': fields.many2one('account.bank.statement', 'Associated Bank Statement'), + 'statement_id': fields.many2one('account.bank.statement', 'Associated Bank Statement'), 'journal_id': fields.many2one('account.journal', 'Journal', readonly=True, domain=[('type', '=', 'bank')]), - 'coda_bank_account_id': fields.many2one('coda.bank.account', 'Bank Account', readonly=True), + 'coda_bank_account_id': fields.many2one('coda.bank.account', 'Bank Account', readonly=True), 'period_id': fields.many2one('account.period', 'Period', required=True, readonly=True), 'balance_start': fields.float('Starting Balance', digits_compute=dp.get_precision('Account'), readonly=True), 'balance_end_real': fields.float('Ending Balance', digits_compute=dp.get_precision('Account'), readonly=True), - 'balance_end': fields.function(_end_balance, method=True, store=True, string='Balance'), + 'balance_end': fields.function(_end_balance, method=True, store=True, string='Balance'), 'line_ids': fields.one2many('coda.bank.statement.line', 'statement_id', 'CODA Bank Statement lines', readonly=True), 'currency': fields.many2one('res.currency', 'Currency', required=True, readonly=True, @@ -293,14 +298,14 @@ class coda_bank_statement(osv.osv): 'company_id': fields.related('journal_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), } _defaults = { - 'type': 'normal', - 'currency': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, + 'type': 'normal', + 'currency': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, 'journal_id': _default_journal_id, 'period_id': _get_period, } def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False): - if context is None: + if context is None: context = {} res = super(coda_bank_statement, self).search(cr, uid, args=args, offset=offset, limit=limit, order=order, context=context, count=count) @@ -314,16 +319,16 @@ class coda_bank_statement(osv.osv): context.update({'coda_statement_unlink': True}) coda_obj = self.pool.get('account.coda') bank_st_obj = self.pool.get('account.bank.statement') - + # find all CODA bank statements that are associated with the selected CODA bank statements via a common CODA file - new_ids = [] + new_ids = [] for coda_statement in self.browse(cr, uid, ids, context=context): if coda_obj.exists(cr, uid, coda_statement.coda_id.id, context=context): new_ids += [x.id for x in coda_obj.browse(cr, uid, coda_statement.coda_id.id, context=context).statement_ids] - # unlink CODA banks statements as well as associated bank statements and CODA files + # unlink CODA banks statements as well as associated bank statements and CODA files for coda_statement in self.browse(cr, uid, new_ids, context=context): - if coda_statement.statement_id.state == 'confirm': + if coda_statement.statement_id.state == 'confirm': raise osv.except_osv(_('Invalid action !'), _("Cannot delete CODA Bank Statement '%s' of Journal '%s'." \ "\nThe associated Bank Statement has already been confirmed !" \ @@ -335,13 +340,14 @@ class coda_bank_statement(osv.osv): coda_obj.unlink(cr, uid, [coda_statement.coda_id.id], context=context) if not context.get('bank_statement_unlink', False): if coda_statement.statement_id and bank_st_obj.exists(cr, uid, coda_statement.statement_id.id, context=context): - bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) + bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) context.update({'coda_statement_unlink': False}) return super(coda_bank_statement, self).unlink(cr, uid, new_ids, context=context) - + coda_bank_statement() + class account_bank_statement(osv.osv): _inherit = 'account.bank.statement' _columns = { @@ -350,7 +356,7 @@ class account_bank_statement(osv.osv): # _sql_constraints = [ # ('name_company_uniq', 'unique (name,company_id)', 'The name of the Bank Statement must be unique per company !') # ] - + def unlink(self, cr, uid, ids, context=None): if context is None: context = {} @@ -359,15 +365,15 @@ class account_bank_statement(osv.osv): coda_st_obj = self.pool.get('coda.bank.statement') # find all statements that are associated with the selected bank statements via a common CODA file - ids_plus = [] + ids_plus = [] for statement in self.browse(cr, uid, ids, context=context): if statement.coda_statement_id: for x in coda_obj.browse(cr, uid, statement.coda_statement_id.coda_id.id, context=context).statement_ids: if x.type == 'normal': ids_plus += [x.statement_id.id] - + # unlink banks statements as well as associated CODA bank statements and CODA files - for statement in self.browse(cr, uid, ids_plus, context=context): + for statement in self.browse(cr, uid, ids_plus, context=context): if not context.get('coda_statement_unlink', False): if statement.coda_statement_id and coda_st_obj.exists(cr, uid, statement.coda_statement_id.id, context=context): coda_st_obj.unlink(cr, uid, [statement.coda_statement_id.id], context=context) @@ -381,52 +387,54 @@ class account_bank_statement(osv.osv): context.update({'bank_statement_unlink': False}) new_ids = list(set(ids + ids_plus)) return super(account_bank_statement, self).unlink(cr, uid, new_ids, context=context) - + account_bank_statement() + class coda_bank_statement_line(osv.osv): - _name = 'coda.bank.statement.line' - _order = 'sequence' + _name = 'coda.bank.statement.line' + _order = 'sequence' _description = 'CODA Bank Statement Line' _columns = { 'name': fields.char('Communication', size=268, required=True), 'sequence': fields.integer('Sequence'), 'date': fields.date('Entry Date', required=True), - 'val_date': fields.date('Valuta Date'), - 'account_id': fields.many2one('account.account','Account'), + 'val_date': fields.date('Valuta Date'), + 'account_id': fields.many2one('account.account', 'Account'), 'type': fields.selection([ - ('supplier','Supplier'), - ('customer','Customer'), - ('general','General'), - ('globalisation','Globalisation'), - ('information','Information'), - ('communication','Free Communication'), + ('supplier', 'Supplier'), + ('customer', 'Customer'), + ('general', 'General'), + ('globalisation', 'Globalisation'), + ('information', 'Information'), + ('communication', 'Free Communication'), ], 'Type', required=True), - 'globalisation_level': fields.integer('Globalisation Level', + 'globalisation_level': fields.integer('Globalisation Level', help="The value which is mentioned (1 to 9), specifies the hierarchy level" " of the globalisation of which this record is the first." "\nThe same code will be repeated at the end of the globalisation."), - 'globalisation_amount': fields.float('Globalisation Amount', digits_compute=dp.get_precision('Account')), + 'globalisation_amount': fields.float('Globalisation Amount', digits_compute=dp.get_precision('Account')), 'globalisation_id': fields.many2one('account.bank.statement.line.global', 'Globalisation ID', readonly=True, - help="Code to identify transactions belonging to the same globalisation level within a batch payment"), + help="Code to identify transactions belonging to the same globalisation level within a batch payment"), 'amount': fields.float('Amount', digits_compute=dp.get_precision('Account')), 'partner_id': fields.many2one('res.partner', 'Partner'), 'counterparty_name': fields.char('Counterparty Name', size=35), - 'counterparty_bic': fields.char('Counterparty BIC', size=11), - 'counterparty_number': fields.char('Counterparty Number', size=34), - 'counterparty_currency': fields.char('Counterparty Currency', size=3), + 'counterparty_bic': fields.char('Counterparty BIC', size=11), + 'counterparty_number': fields.char('Counterparty Number', size=34), + 'counterparty_currency': fields.char('Counterparty Currency', size=3), 'payment_reference': fields.char('Payment Reference', size=35, help="Payment Reference. For SEPA (SCT or SDD) transactions, the PaymentInformationIdentification "\ "is recorded in this field pertaining to a globalisation, and the EndToEndReference for " \ - "simple transactions or for the details of a globalisation."), + "simple transactions or for the details of a globalisation."), 'statement_id': fields.many2one('coda.bank.statement', 'CODA Bank Statement', select=True, required=True, ondelete='cascade'), 'coda_bank_account_id': fields.related('statement_id', 'coda_bank_account_id', type='many2one', relation='coda.bank.account', string='Bank Account', store=True, readonly=True), 'ref': fields.char('Reference', size=32), 'note': fields.text('Notes'), - 'company_id': fields.related('statement_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), + 'company_id': fields.related('statement_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), } + #TODO : Check this function. account_bank_statement_line Seems undefined : ) def unlink(self, cr, uid, ids, context=None): if context is None: context = {} @@ -434,7 +442,8 @@ class coda_bank_statement_line(osv.osv): raise osv.except_osv('Warning', _('Delete operation not allowed !')) return super(account_bank_statement_line, self).unlink(cr, uid, ids, context=context) -coda_bank_statement_line() +coda_bank_statement_line() + class account_bank_statement_line_global(osv.osv): _inherit = 'account.bank.statement.line.global' @@ -443,6 +452,7 @@ class account_bank_statement_line_global(osv.osv): } account_bank_statement_line_global() + class coda_account_mapping_rule(osv.osv): _name = 'coda.account.mapping.rule' _description = 'Rules Engine to assign accounts during CODA parsing' @@ -450,7 +460,7 @@ class coda_account_mapping_rule(osv.osv): _columns = { 'coda_bank_account_id': fields.many2one('coda.bank.account', 'CODA Bank Account', ondelete='cascade'), 'sequence': fields.integer('Sequence', help='Determines the order of the rules to assign accounts'), - 'name': fields.char('Rule Name', size=128, required=True), + 'name': fields.char('Rule Name', size=128, required=True), # matching criteria 'trans_type_id': fields.many2one('account.coda.trans.type', 'Transaction Type'), 'trans_family_id': fields.many2one('account.coda.trans.code', 'Transaction Family', domain=[('type', '=', 'family')]), @@ -465,18 +475,18 @@ class coda_account_mapping_rule(osv.osv): _defaults = { 'active': True, } - - def account_id_get(self, cr, uid, coda_bank_account_id, trans_type_id=None, trans_family_id=None, - trans_code_id=None, trans_category_id=None, struct_comm_type_id=None, partner_id=None, context=None): + + def account_id_get(self, cr, uid, coda_bank_account_id, trans_type_id=None, trans_family_id=None, + trans_code_id=None, trans_category_id=None, struct_comm_type_id=None, partner_id=None, context=None): cr.execute('SELECT account_id, trans_type_id, trans_family_id, trans_code_id, trans_category_id, struct_comm_type_id, partner_id ' \ 'FROM coda_account_mapping_rule ' \ 'WHERE active = TRUE AND coda_bank_account_id = %s ' \ 'ORDER BY sequence' % coda_bank_account_id ) - rules = cr.fetchall() + rules = cr.fetchall() condition = '(not rule[1] or (trans_type_id == rule[1])) and (not rule[2] or (trans_family_id == rule[2])) ' \ 'and (not rule[3] or (trans_code_id == rule[3])) and (not rule[4] or (trans_category_id == rule[4])) ' \ - 'and (not rule[5] or (struct_comm_type_id == rule[5])) and (not rule[6] or (partner_id == rule[6]))' + 'and (not rule[5] or (struct_comm_type_id == rule[5])) and (not rule[6] or (partner_id == rule[6]))' account_id = None for rule in rules: if eval(condition): diff --git a/addons/l10n_be_coda/res_bank.py b/addons/l10n_be_coda/res_bank.py index 6a3581539e9..47e7fdf8569 100755 --- a/addons/l10n_be_coda/res_bank.py +++ b/addons/l10n_be_coda/res_bank.py @@ -2,9 +2,9 @@ ############################################################################## # # OpenERP, Open Source Management Solution -# +# # Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. -# +# # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the @@ -22,6 +22,7 @@ from osv import fields, osv + class res_bank(osv.osv): _inherit = 'res.bank' _columns = { diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 6f055ca3d92..ea7558e13da 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -2,9 +2,9 @@ ############################################################################## # # OpenERP, Open Source Management Solution -# +# # Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. -# +# # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the @@ -22,7 +22,7 @@ import time import base64 -from osv import fields,osv +from osv import fields, osv from tools.translate import _ import netsvc import re @@ -31,20 +31,21 @@ from sys import exc_info import logging _logger = logging.getLogger(__name__) + class account_coda_import(osv.osv_memory): _name = 'account.coda.import' _description = 'Import CODA File' _columns = { 'coda_data': fields.binary('CODA File', required=True), 'coda_fname': fields.char('CODA Filename', size=128, required=True), - 'note':fields.text('Log'), + 'note': fields.text('Log'), } _defaults = { 'coda_fname': lambda *a: '', } def _check_account_payment(self, cr, uid, context=None): - res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_payment'), ('state','=','installed')]) + res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_payment'), ('state', '=', 'installed')]) return res and True or False def coda_parsing(self, cr, uid, ids, context=None, batch=False, codafile=None, codafilename=None): @@ -54,15 +55,15 @@ class account_coda_import(osv.osv_memory): codafile = str(codafile) codafilename = codafilename else: - data=self.browse(cr,uid,ids)[0] + data = self.browse(cr, uid, ids)[0] try: codafile = data.coda_data - codafilename = data.coda_fname + codafilename = data.coda_fname except: raise osv.except_osv(_('Error!'), _('Wizard in incorrect state. Please hit the Cancel button!')) return {} - currency_obj = self.pool.get('res.currency') + currency_obj = self.pool.get('res.currency') coda_bank_account_obj = self.pool.get('coda.bank.account') trans_type_obj = self.pool.get('account.coda.trans.type') trans_code_obj = self.pool.get('account.coda.trans.code') @@ -78,29 +79,25 @@ class account_coda_import(osv.osv_memory): bank_st_line_obj = self.pool.get('account.bank.statement.line') glob_obj = self.pool.get('account.bank.statement.line.global') inv_obj = self.pool.get('account.invoice') - move_obj = self.pool.get('account.move') move_line_obj = self.pool.get('account.move.line') voucher_obj = self.pool.get('account.voucher') - voucher_line_obj = self.pool.get('account.voucher.line') seq_obj = self.pool.get('ir.sequence') mod_obj = self.pool.get('ir.model.data') - partner_obj = self.pool.get('res.partner') account_mapping_obj = self.pool.get('coda.account.mapping.rule') - + if self._check_account_payment(cr, uid): payment_line_obj = self.pool.get('payment.line') else: payment_line_obj = False - + wf_service = netsvc.LocalService('workflow') - be_country_id = self.pool.get('res.country').search(cr, uid, [('code', '=', 'BE')])[0] coda_bank_table = coda_bank_account_obj.read(cr, uid, coda_bank_account_obj.search(cr, uid, []), context=context) for coda_bank in coda_bank_table: coda_bank.update({'journal_code': coda_bank['journal'] and journal_obj.browse(cr, uid, coda_bank['journal'][0], context=context).code or ''}) coda_bank.update({'iban': partner_bank_obj.browse(cr, uid, coda_bank['bank_id'][0], context=context).iban}) coda_bank.update({'acc_number': partner_bank_obj.browse(cr, uid, coda_bank['bank_id'][0], context=context).acc_number}) - coda_bank.update({'currency_name': currency_obj.browse(cr, uid, coda_bank['currency'][0], context=context).name}) + coda_bank.update({'currency_name': currency_obj.browse(cr, uid, coda_bank['currency'][0], context=context).name}) trans_type_table = trans_type_obj.read(cr, uid, trans_type_obj.search(cr, uid, []), context=context) trans_code_table = trans_code_obj.read(cr, uid, trans_code_obj.search(cr, uid, []), context=context) trans_category_table = trans_category_obj.read(cr, uid, trans_category_obj.search(cr, uid, []), context=context) @@ -112,9 +109,9 @@ class account_coda_import(osv.osv_memory): coda_statements = [] recordlist = unicode(base64.decodestring(codafile), 'windows-1252', 'strict').split('\n') digits = self.pool.get('decimal.precision').precision_get(cr, uid, 'Account') - + for line in recordlist: - + if not line: pass elif line[0] == '0': @@ -124,10 +121,10 @@ class account_coda_import(osv.osv_memory): coda_statement_lines = {} st_line_seq = 0 # header data - coda_statement['currency'] = 'EUR' # default currency + coda_statement['currency'] = 'EUR' # default currency coda_statement['version'] = line[127] coda_version = line[127] - if coda_version not in ['1','2']: + if coda_version not in ['1', '2']: err_string = _('\nCODA V%s statements are not supported, please contact your bank!') % coda_version err_code = 'R0001' if batch: @@ -137,10 +134,10 @@ class account_coda_import(osv.osv_memory): coda_statement['date'] = str2date(line[5:11]) coda_statement['coda_creation_date'] = str2date(line[5:11]) coda_statement['separate_application'] = line[83:88] - coda_statement['first_transaction_date'] = False + coda_statement['first_transaction_date'] = False coda_statement['state'] = 'draft' - - coda_id = coda_obj.search(cr, uid,[ + + coda_id = coda_obj.search(cr, uid, [ ('name', '=', codafilename), ('coda_creation_date', '=', coda_statement['date']), ]) @@ -151,7 +148,7 @@ class account_coda_import(osv.osv_memory): if batch: return (err_code, err_string) raise osv.except_osv(_('Warning !'), err_string) - + elif line[0] == '1': if coda_version == '1': coda_statement['acc_number'] = line[5:17] @@ -159,7 +156,7 @@ class account_coda_import(osv.osv_memory): coda_statement['currency'] = line[18:21] elif line[1] == '0': # Belgian bank account BBAN structure coda_statement['acc_number'] = line[5:17] - coda_statement['currency'] = line[18:21] + coda_statement['currency'] = line[18:21] elif line[1] == '1': # foreign bank account BBAN structure err_string = _('\nForeign bank accounts with BBAN structure are not supported !') err_code = 'R1001' @@ -167,7 +164,7 @@ class account_coda_import(osv.osv_memory): return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) elif line[1] == '2': # Belgian bank account IBAN structure - coda_statement['acc_number']=line[5:21] + coda_statement['acc_number'] = line[5:21] coda_statement['currency'] = line[39:42] elif line[1] == '3': # foreign bank account IBAN structure err_string = _('\nForeign bank accounts with IBAN structure are not supported !') @@ -184,22 +181,22 @@ class account_coda_import(osv.osv_memory): coda_statement['description'] = line[90:125].strip() cba_filter = lambda x: (coda_statement['acc_number'] in _get_acc_numbers(x['acc_number'])) \ and (coda_statement['currency'] == x['currency_name']) and (coda_statement['description'] in [x['description1'] or '', x['description2'] or '']) - coda_bank = filter(cba_filter, coda_bank_table) + coda_bank = filter(cba_filter, coda_bank_table) if coda_bank: - coda_bank = coda_bank[0] + coda_bank = coda_bank[0] coda_statement['type'] = coda_bank['state'] coda_statement['journal_id'] = coda_bank['journal'] and coda_bank['journal'][0] coda_statement['currency_id'] = coda_bank['currency'][0] - coda_statement['coda_bank_account_id'] = coda_bank['id'] - coda_statement['account_mapping_ids'] = coda_bank['account_mapping_ids'] - coda_statement['coda_bank_params'] = coda_bank + coda_statement['coda_bank_account_id'] = coda_bank['id'] + coda_statement['account_mapping_ids'] = coda_bank['account_mapping_ids'] + coda_statement['coda_bank_params'] = coda_bank awaiting_acc = coda_bank['awaiting_account'][0] transfer_acc = coda_bank['transfer_account'][0] find_payment = coda_bank['find_payment'] find_bbacom = coda_bank['find_bbacom'] - find_inv_number = coda_bank['find_inv_number'] + find_inv_number = coda_bank['find_inv_number'] find_partner = coda_bank['find_partner'] - update_partner = coda_bank['update_partner'] + update_partner = coda_bank['update_partner'] coda_statement['balance_start_enforce'] = coda_bank['balance_start_enforce'] coda_statement['discard_dup'] = coda_bank['discard_dup'] company_id = coda_bank['company_id'][0] @@ -217,7 +214,7 @@ class account_coda_import(osv.osv_memory): bal_start = list2float(line[43:58]) # old balance data if line[42] == '1': # 1= Debit bal_start = - bal_start - coda_statement['balance_start'] = bal_start + coda_statement['balance_start'] = bal_start coda_statement['old_balance_date'] = str2date(line[58:64]) coda_statement['acc_holder'] = line[64:90] coda_statement['paper_ob_seq_number'] = line[2:5] @@ -225,50 +222,50 @@ class account_coda_import(osv.osv_memory): elif line[0] == '2': # movement data record 2 - + if line[1] == '1': # movement data record 2.1 st_line = {} st_line_seq = st_line_seq + 1 st_line['sequence'] = st_line_seq st_line['type'] = 'general' - st_line['reconcile'] = False + st_line['reconcile'] = False st_line['trans_family'] = False st_line['struct_comm_type'] = '' st_line['struct_comm_type_id'] = 0 st_line['struct_comm_type_desc'] = '' st_line['struct_comm_bba'] = '' st_line['communication'] = '' - st_line['payment_reference'] = '' + st_line['payment_reference'] = '' st_line['partner_id'] = 0 st_line['account_id'] = 0 st_line['counterparty_name'] = '' - st_line['counterparty_bic'] = '' + st_line['counterparty_bic'] = '' st_line['counterparty_number'] = '' - st_line['counterparty_currency'] = '' + st_line['counterparty_currency'] = '' st_line['glob_lvl_flag'] = False st_line['globalisation_id'] = 0 st_line['globalisation_code'] = '' st_line['globalisation_amount'] = False st_line['amount'] = False - + st_line['ref'] = line[2:10] st_line['ref_move'] = line[2:6] st_line['ref_move_detail'] = line[6:10] - + if st_line_seq == 1: - main_move_stack = [st_line] # initialise main_move_stack (used to link 2.1 detail records to 2.1 main record - glob_lvl_stack = [0] # initialise globalisation stack + main_move_stack = [st_line] # initialise main_move_stack (used to link 2.1 detail records to 2.1 main record + glob_lvl_stack = [0] # initialise globalisation stack elif st_line['ref_move_detail'] == '0000': - glob_lvl_stack = [0] # re-initialise globalisation stack - + glob_lvl_stack = [0] # re-initialise globalisation stack + st_line['trans_ref'] = line[10:31] st_line_amt = list2float(line[32:47]) if line[31] == '1': # 1=debit st_line_amt = - st_line_amt - + st_line['trans_type'] = line[53] - trans_type = filter(lambda x: st_line['trans_type'] == x['type'], trans_type_table) + trans_type = filter(lambda x: st_line['trans_type'] == x['type'], trans_type_table) if not trans_type: err_string = _('\nThe File contains an invalid CODA Transaction Type : %s!') % st_line['trans_type'] err_code = 'R2001' @@ -276,13 +273,13 @@ class account_coda_import(osv.osv_memory): return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) st_line['trans_type_id'] = trans_type[0]['id'] - st_line['trans_type_desc'] = trans_type[0]['description'] - - # processing of amount depending on globalisation code + st_line['trans_type_desc'] = trans_type[0]['description'] + + # processing of amount depending on globalisation code glob_lvl_flag = int(line[124]) - if glob_lvl_flag > 0: - if glob_lvl_stack[-1] == glob_lvl_flag: - st_line['glob_lvl_flag'] = glob_lvl_flag + if glob_lvl_flag > 0: + if glob_lvl_stack[-1] == glob_lvl_flag: + st_line['glob_lvl_flag'] = glob_lvl_flag st_line['amount'] = st_line_amt glob_lvl_stack.pop() else: @@ -292,7 +289,7 @@ class account_coda_import(osv.osv_memory): st_line['globalisation_amount'] = st_line_amt else: st_line['amount'] = st_line_amt - + # The 'globalisation' concept can also be implemented without the globalisation level flag. # This is e.g. used by Europabank to give the details of Card Payments. if st_line['ref_move'] == main_move_stack[-1]['ref_move']: @@ -303,7 +300,7 @@ class account_coda_import(osv.osv_memory): if batch: return (err_code, err_string) raise osv.except_osv(_('Data Error!'), err_string) - elif st_line['ref_move_detail'] != '0000': + elif st_line['ref_move_detail'] != '0000': if glob_lvl_stack[-1] == 0: # promote associated move record into a globalisation glob_lvl_flag = 1 @@ -319,7 +316,7 @@ class account_coda_import(osv.osv_memory): 'account_id': 0, }) main_move_stack[-1]['promoted'] = True - if not main_move_stack[-1].get('detail_cnt'): + if not main_move_stack[-1].get('detail_cnt'): main_move_stack[-1]['detail_cnt'] = 1 else: main_move_stack[-1]['detail_cnt'] += 1 @@ -328,17 +325,17 @@ class account_coda_import(osv.osv_memory): st_line['val_date'] = str2date(line[47:53]) # positions 54-61 : transaction code st_line['trans_family'] = line[54:56] - trans_family = filter(lambda x: (x['type'] == 'family') and (st_line['trans_family'] == x['code']), trans_code_table) + trans_family = filter(lambda x: (x['type'] == 'family') and (st_line['trans_family'] == x['code']), trans_code_table) if not trans_family: - err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] + err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] err_code = 'R2002' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) + raise osv.except_osv(_('Data Error!'), err_string) st_line['trans_family_id'] = trans_family[0]['id'] st_line['trans_family_desc'] = trans_family[0]['description'] st_line['trans_code'] = line[56:58] - trans_code = filter(lambda x: (x['type'] == 'code') and (st_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), + trans_code = filter(lambda x: (x['type'] == 'code') and (st_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), trans_code_table) if trans_code: st_line['trans_code_id'] = trans_code[0]['id'] @@ -347,17 +344,17 @@ class account_coda_import(osv.osv_memory): st_line['trans_code_id'] = None st_line['trans_code_desc'] = _('Transaction Code unknown, please consult your bank.') st_line['trans_category'] = line[58:61] - trans_category = filter(lambda x: st_line['trans_category'] == x['category'], trans_category_table) + trans_category = filter(lambda x: st_line['trans_category'] == x['category'], trans_category_table) if trans_category: st_line['trans_category_id'] = trans_category[0]['id'] st_line['trans_category_desc'] = trans_category[0]['description'] else: st_line['trans_category_id'] = None - st_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') - # positions 61-115 : communication + st_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') + # positions 61-115 : communication if line[61] == '1': st_line['struct_comm_type'] = line[62:65] - comm_type = filter(lambda x: st_line['struct_comm_type'] == x['code'], comm_type_table) + comm_type = filter(lambda x: st_line['struct_comm_type'] == x['code'], comm_type_table) if not comm_type: err_string = _('\nThe File contains an invalid Structured Communication Type : %s!') % st_line['struct_comm_type'] err_code = 'R2003' @@ -368,28 +365,28 @@ class account_coda_import(osv.osv_memory): st_line['struct_comm_type_desc'] = comm_type[0]['description'] st_line['communication'] = st_line['name'] = line[65:115] if st_line['struct_comm_type'] in ['101', '102']: - bbacomm = line[65:77] - st_line['struct_comm_bba'] = st_line['name'] = '+++' + bbacomm[0:3] + '/' + bbacomm[3:7] + '/' + bbacomm[7:] + '+++' + bbacomm = line[65:77] + st_line['struct_comm_bba'] = st_line['name'] = '+++' + bbacomm[0:3] + '/' + bbacomm[3:7] + '/' + bbacomm[7:] + '+++' else: st_line['communication'] = st_line['name'] = line[62:115] st_line['entry_date'] = str2date(line[115:121]) if st_line['sequence'] == 1: coda_statement['first_transaction_date'] = st_line['entry_date'] - # positions 122-124 not processed - coda_statement_lines[st_line_seq] = st_line # store transaction - + # positions 122-124 not processed + coda_statement_lines[st_line_seq] = st_line # store transaction + if st_line['ref_move'] != main_move_stack[-1]['ref_move']: if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): # add closing globalisation level on previous detail record in order to correctly close # moves that have been 'promoted' to globalisation - closeglobalise = coda_statement['coda_statement_lines'][st_line_seq-1] + closeglobalise = coda_statement['coda_statement_lines'][st_line_seq - 1] closeglobalise.update({ 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], }) else: # demote record with globalisation code from 'globalisation' to 'general' when no detail records # the same logic is repeated on the New Balance Record ('8 Record') in order to cope with CODA files - # containing a single 2.1 record that needs to be 'demoted'. + # containing a single 2.1 record that needs to be 'demoted'. if main_move_stack[-1]['type'] == 'globalisation' and not main_move_stack[-1].get('detail_cnt'): # demote record with globalisation code from 'globalisation' to 'general' when no detail records main_st_line_seq = main_move_stack[-1]['sequence'] @@ -403,7 +400,7 @@ class account_coda_import(osv.osv_memory): main_move_stack.pop() main_move_stack.append(st_line) coda_statement['coda_statement_lines'] = coda_statement_lines - + elif line[1] == '2': # movement data record 2.2 if coda_statement['coda_statement_lines'][st_line_seq]['ref'][0:4] != line[2:6]: @@ -412,12 +409,12 @@ class account_coda_import(osv.osv_memory): err_code = 'R2004' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) + raise osv.except_osv(_('Error!'), err_string) coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:63] coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:63] coda_statement['coda_statement_lines'][st_line_seq]['payment_reference'] = line[63:98].strip() coda_statement['coda_statement_lines'][st_line_seq]['counterparty_bic'] = line[98:109].strip() - + elif line[1] == '3': # movement data record 2.3 if coda_statement['coda_statement_lines'][st_line_seq]['ref'][0:4] != line[2:6]: @@ -426,7 +423,7 @@ class account_coda_import(osv.osv_memory): err_code = 'R2005' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) + raise osv.except_osv(_('Error!'), err_string) st_line = coda_statement_lines[st_line_seq] if coda_version == '1': counterparty_number = line[10:22].strip() @@ -438,7 +435,7 @@ class account_coda_import(osv.osv_memory): counterparty_currency = line[23:26].strip() else: counterparty_number = line[10:44].strip() - counterparty_currency = line[44:47].strip() + counterparty_currency = line[44:47].strip() counterparty_name = line[47:82].strip() st_line['name'] += line[82:125] st_line['communication'] += line[82:125] @@ -447,20 +444,20 @@ class account_coda_import(osv.osv_memory): st_line['counterparty_name'] = counterparty_name """ TO DO: - + replace code infra by check on flag 128 and copy info in Notes Field. - + if counterparty_currency not in [coda_bank['currency_name'], '']: err_string = _('\nCODA parsing error on movement data record 2.3, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] + '\nPlease report this issue via your OpenERP support channel.') % line[2:10] err_code = 'R2006' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) + raise osv.except_osv(_('Error!'), err_string) """ - # invoice matching and reconciliation - if st_line['type'] == 'general': + # invoice matching and reconciliation + if st_line['type'] == 'general': match = False payment_reference_match = False inv_ids = None @@ -480,17 +477,17 @@ class account_coda_import(osv.osv_memory): st_line['reconcile'] = payline.move_line_id.id st_line['account_id'] = payline.move_line_id.account_id.id if payline._get_ml_inv_ref: - inv_type = payline.ml_inv_ref.type + inv_type = payline.ml_inv_ref.type st_line['type'] = inv_type == 'in_invoice' and 'supplier' or 'customer' else: st_line['type'] = 'general' else: err_string = _('\nThe CODA parsing detected a payment reference ambiguity while processing movement data record 2.3, seq nr %s!' \ - '\nPlease check your Payment Gateway configuration or contact your OpenERP support channel.') % line[2:10] + '\nPlease check your Payment Gateway configuration or contact your OpenERP support channel.') % line[2:10] err_code = 'R2007' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) + raise osv.except_osv(_('Error!'), err_string) # check bba scor in bank statement line against open invoices if st_line['struct_comm_bba'] and find_bbacom: @@ -498,15 +495,15 @@ class account_coda_import(osv.osv_memory): domain = [('type', 'in', ['out_invoice', 'in_refund'])] else: domain = [('type', 'in', ['in_invoice', 'out_refund'])] - inv_ids = inv_obj.search(cr , uid, - domain + [('state', '=', 'open'), ('reference' ,'=', st_line['struct_comm_bba']), ('reference_type' ,'=', 'bba')]) + inv_ids = inv_obj.search(cr, uid, + domain + [('state', '=', 'open'), ('reference', '=', st_line['struct_comm_bba']), ('reference_type', '=', 'bba')]) if not inv_ids: coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ "\n There is no invoice matching the Structured Communication '%s'!" \ "\n Please verify and adjust the invoice and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ % (st_line['ref'], st_line['struct_comm_bba']) elif len(inv_ids) == 1: - match = True + match = True elif len(inv_ids) > 1: coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ "\n There are multiple invoices matching the Structured Communication '%s'!" \ @@ -527,7 +524,7 @@ class account_coda_import(osv.osv_memory): else: select2 = " AND type IN ('in_invoice', 'out_refund')" cr.execute(select + select2) - res=cr.fetchall() + res = cr.fetchall() if res: inv_ids = [x[0] for x in res] if len(inv_ids) == 1: @@ -548,26 +545,26 @@ class account_coda_import(osv.osv_memory): if st_line['amount'] > 0: select2 = " AND type = 'out_invoice' AND free_comm ilike '%'||number||'%'" cr.execute(select + select2) - res=cr.fetchall() + res = cr.fetchall() if res: inv_ids = [x[0] for x in res] - else: + else: select2 = " AND type = 'in_refund' AND free_comm ilike '%'||reference||'%'" cr.execute(select + select2) - res=cr.fetchall() + res = cr.fetchall() if res: inv_ids = [x[0] for x in res] # 'in_invoice', 'out_refund' else: select2 = " AND type = 'in_invoice' AND free_comm ilike '%'||reference||'%'" cr.execute(select + select2) - res=cr.fetchall() + res = cr.fetchall() if res: inv_ids = [x[0] for x in res] - else: + else: select2 = " AND type = 'out_refund' AND free_comm ilike '%'||number||'%'" cr.execute(select + select2) - res=cr.fetchall() + res = cr.fetchall() if res: inv_ids = [x[0] for x in res] if inv_ids: @@ -578,7 +575,7 @@ class account_coda_import(osv.osv_memory): "\n There are multiple invoices matching the Invoice Amount and Reference." \ "\n A manual reconciliation is required.") \ % (st_line['ref']) - + if not payment_reference_match and match and inv_ids and len(inv_ids) == 1: invoice = inv_obj.browse(cr, uid, inv_ids[0]) partner = invoice.partner_id @@ -594,27 +591,27 @@ class account_coda_import(osv.osv_memory): st_line['reconcile'] = iml_ids[0] else: err_string = _('\nThe CODA parsing detected a database inconsistency while processing movement data record 2.3, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] + '\nPlease report this issue via your OpenERP support channel.') % line[2:10] err_code = 'R2008' if batch: return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - - # lookup partner via counterparty_number when invoice lookup failed + raise osv.except_osv(_('Error!'), err_string) + + # lookup partner via counterparty_number when invoice lookup failed if not match and counterparty_number: - transfer_account = filter(lambda x: counterparty_number in x, company_bank_accounts) + transfer_account = filter(lambda x: counterparty_number in x, company_bank_accounts) if transfer_account: st_line['account_id'] = transfer_acc match = True elif find_partner: - partner_bank_ids = partner_bank_obj.search(cr,uid,[('acc_number','=', counterparty_number)]) + partner_bank_ids = partner_bank_obj.search(cr, uid, [('acc_number', '=', counterparty_number)]) if not match and find_partner and partner_bank_ids: if len(partner_bank_ids) > 1: coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ "\n No partner record assigned: There are multiple partners with the same Bank Account Number '%s'!" \ "\n Please correct the configuration and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ % (st_line['ref'], counterparty_number) - else: + else: partner_bank = partner_bank_obj.browse(cr, uid, partner_bank_ids[0], context) st_line['partner_id'] = partner_bank.partner_id.id match = True @@ -634,21 +631,21 @@ class account_coda_import(osv.osv_memory): coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ "\n No matching partner record found!" \ "\n Please adjust the corresponding entry manually in the generated Bank Statement.") \ - % (st_line['ref']) + % (st_line['ref']) st_line['account_id'] = awaiting_acc - + # add bank account to partner record if match and st_line['account_id'] != transfer_acc and counterparty_number and update_partner: - partner_bank_ids = partner_bank_obj.search(cr,uid,[('acc_number','=', counterparty_number), ('partner_id', '=', st_line['partner_id'])], order='id') + partner_bank_ids = partner_bank_obj.search(cr, uid, [('acc_number', '=', counterparty_number), ('partner_id', '=', st_line['partner_id'])], order='id') if len(partner_bank_ids) > 1: # clean up partner bank duplicates, keep most recently created - _logger.warn('Duplicate Bank Accounts for partner_id %s have been removed, ids = %s', + _logger.warn('Duplicate Bank Accounts for partner_id %s have been removed, ids = %s', st_line['partner_id'], partner_bank_ids[:-1]) - partner_bank_obj.unlink(cr,uid, partner_bank_ids[:-1]) + partner_bank_obj.unlink(cr, uid, partner_bank_ids[:-1]) if not partner_bank_ids: feedback = update_partner_bank(self, cr, uid, st_line['counterparty_bic'], counterparty_number, st_line['partner_id'], counterparty_name) - if feedback: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':") % st_line['ref'] + feedback + if feedback: + coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':") % st_line['ref'] + feedback coda_statement_lines[st_line_seq] = st_line coda_statement['coda_statement_lines'] = coda_statement_lines @@ -660,18 +657,18 @@ class account_coda_import(osv.osv_memory): err_code = 'R2009' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) + raise osv.except_osv(_('Data Error!'), err_string) elif line[0] == '3': # information data record 3 - + if line[1] == '1': # information data record 3.1 info_line = {} info_line['entry_date'] = st_line['entry_date'] info_line['type'] = 'information' st_line_seq = st_line_seq + 1 - info_line['sequence'] = st_line_seq + info_line['sequence'] = st_line_seq info_line['struct_comm_type'] = '' info_line['struct_comm_type_desc'] = '' info_line['communication'] = '' @@ -679,37 +676,37 @@ class account_coda_import(osv.osv_memory): info_line['trans_ref'] = line[10:31] # positions 32-38 : transaction code info_line['trans_type'] = line[31] - trans_type = filter(lambda x: info_line['trans_type'] == x['type'], trans_type_table) + trans_type = filter(lambda x: info_line['trans_type'] == x['type'], trans_type_table) if not trans_type: err_string = _('\nThe File contains an invalid CODA Transaction Type : %s!') % st_line['trans_type'] err_code = 'R3001' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - info_line['trans_type_desc'] = trans_type[0]['description'] + raise osv.except_osv(_('Data Error!'), err_string) + info_line['trans_type_desc'] = trans_type[0]['description'] info_line['trans_family'] = line[32:34] - trans_family = filter(lambda x: (x['type'] == 'family') and (info_line['trans_family'] == x['code']), trans_code_table) + trans_family = filter(lambda x: (x['type'] == 'family') and (info_line['trans_family'] == x['code']), trans_code_table) if not trans_family: - err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] + err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] err_code = 'R3002' if batch: return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) + raise osv.except_osv(_('Data Error!'), err_string) info_line['trans_family_desc'] = trans_family[0]['description'] info_line['trans_code'] = line[34:36] - trans_code = filter(lambda x: (x['type'] == 'code') and (info_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), + trans_code = filter(lambda x: (x['type'] == 'code') and (info_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), trans_code_table) if trans_code: info_line['trans_code_desc'] = trans_code[0]['description'] else: info_line['trans_code_desc'] = _('Transaction Code unknown, please consult your bank.') info_line['trans_category'] = line[36:39] - trans_category = filter(lambda x: info_line['trans_category'] == x['category'], trans_category_table) + trans_category = filter(lambda x: info_line['trans_category'] == x['category'], trans_category_table) if trans_category: info_line['trans_category_desc'] = trans_category[0]['description'] else: - info_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') - # positions 40-113 : communication + info_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') + # positions 40-113 : communication if line[39] == '1': info_line['struct_comm_type'] = line[40:43] comm_type = filter(lambda x: info_line['struct_comm_type'] == x['code'], comm_type_table) @@ -726,7 +723,7 @@ class account_coda_import(osv.osv_memory): # positions 114-128 not processed coda_statement_lines[st_line_seq] = info_line coda_statement['coda_statement_lines'] = coda_statement_lines - + elif line[1] == '2': # information data record 3.2 if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: @@ -736,9 +733,9 @@ class account_coda_import(osv.osv_memory): if batch: return (err_code, err_string) raise osv.except_osv(_('Error!'), err_string) - coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:115] + coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:115] coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:115] - + elif line[1] == '3': # information data record 3.3 if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: @@ -750,7 +747,7 @@ class account_coda_import(osv.osv_memory): raise osv.except_osv(_('Error!'), err_string) coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:100] coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:100] - + elif line[0] == '4': # free communication data record 4 comm_line = {} @@ -761,11 +758,11 @@ class account_coda_import(osv.osv_memory): comm_line['communication'] = comm_line['name'] = line[32:112] coda_statement_lines[st_line_seq] = comm_line coda_statement['coda_statement_lines'] = coda_statement_lines - + elif line[0] == '8': # new balance record last_transaction = main_move_stack[-1] - if last_transaction['type'] == 'globalisation' and not last_transaction.get('detail_cnt'): + if last_transaction['type'] == 'globalisation' and not last_transaction.get('detail_cnt'): # demote record with globalisation code from 'globalisation' to 'general' when no detail records main_st_line_seq = main_move_stack[-1]['sequence'] to_demote = coda_statement['coda_statement_lines'][main_st_line_seq] @@ -778,7 +775,7 @@ class account_coda_import(osv.osv_memory): # add closing globalisation level on previous detail record in order to correctly close # moves that have been 'promoted' to globalisation if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): - closeglobalise = coda_statement['coda_statement_lines'][st_line_seq-1] + closeglobalise = coda_statement['coda_statement_lines'][st_line_seq - 1] closeglobalise.update({ 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], }) @@ -788,10 +785,10 @@ class account_coda_import(osv.osv_memory): if line[41] == '1': # 1=Debit bal_end = - bal_end coda_statement['balance_end_real'] = bal_end - if coda_statement['new_balance_date']: - period_id = period_obj.search(cr , uid, [('date_start' ,'<=', coda_statement['new_balance_date']), ('date_stop','>=',coda_statement['new_balance_date'])]) + if coda_statement['new_balance_date']: + period_id = period_obj.search(cr, uid, [('date_start', '<=', coda_statement['new_balance_date']), ('date_stop', '>=', coda_statement['new_balance_date'])]) else: - period_id = period_obj.search(cr , uid, [('date_start' ,'<=', coda_statement['date']), ('date_stop','>=',coda_statement['date'])]) + period_id = period_obj.search(cr, uid, [('date_start', '<=', coda_statement['date']), ('date_stop', '>=', coda_statement['date'])]) if not period_id: err_string = _("\nThe CODA Statement New Balance date doesn't fall within a defined Accounting Period!" \ "\nPlease create the Accounting Period for date %s.") % coda_statement['new_balance_date'] @@ -802,7 +799,7 @@ class account_coda_import(osv.osv_memory): coda_statement['period_id'] = period_id[0] if coda_bank['coda_st_naming']: coda_statement['name'] = coda_bank['coda_st_naming'] % { - 'code': coda_bank['journal_code'] or '', + 'code': coda_bank['journal_code'] or '', 'year': coda_statement['new_balance_date'] and coda_statement['new_balance_date'][:4] or coda_statement['date'][:4], 'y': coda_statement['new_balance_date'] and coda_statement['new_balance_date'][2:4] or coda_statement['date'][2:4], 'coda': coda_statement['coda_seq_number'], @@ -811,14 +808,14 @@ class account_coda_import(osv.osv_memory): } else: coda_statement['name'] = '/' - + elif line[0] == '9': # footer record - coda_statement['balance_min'] = list2float(line[22:37]) + coda_statement['balance_min'] = list2float(line[22:37]) coda_statement['balance_plus'] = list2float(line[37:52]) if not bal_end: coda_statement['balance_end_real'] = coda_statement['balance_start'] + coda_statement['balance_plus'] - coda_statement['balance_min'] - if coda_parsing_note: + if coda_parsing_note: coda_statement['coda_parsing_note'] = '\nStatement Line matching results:' + coda_parsing_note else: coda_statement['coda_parsing_note'] = '' @@ -826,28 +823,28 @@ class account_coda_import(osv.osv_memory): #end for err_string = '' - err_code = '' + err_code = '' coda_id = 0 coda_note = '' line_note = '' - + try: - coda_id = coda_obj.create(cr, uid,{ - 'name' : codafilename, + coda_id = coda_obj.create(cr, uid, { + 'name': codafilename, 'coda_data': codafile, - 'coda_creation_date' : coda_statement['date'], + 'coda_creation_date': coda_statement['date'], 'date': fields.date.context_today(self, cr, uid, context=context), 'user_id': uid, }) context.update({'coda_id': coda_id}) - + except osv.except_osv, e: cr.rollback() err_string = _('\nApplication Error : ') + str(e) except Exception, e: cr.rollback() err_string = _('\nSystem Error : ') + str(e) - except : + except: cr.rollback() err_string = _('\nUnknown Error : ') + str(e) if err_string: @@ -859,40 +856,40 @@ class account_coda_import(osv.osv_memory): nb_err = 0 err_string = '' coda_st_ids = [] - bk_st_ids = [] - + bk_st_ids = [] + for statement in coda_statements: - + # The CODA Statement info is written to two objects: 'coda.bank.statement' and 'account.bank.statement' try: normal2info = False lines = statement['coda_statement_lines'] - if not statement['first_transaction_date']: - normal2info = True # don't create a bank statement for CODA's without transactions + if not statement['first_transaction_date']: + normal2info = True # don't create a bank statement for CODA's without transactions else: line_vals = [x for x in lines.itervalues()] transactions = filter(lambda x: (x['type'] in ['globalisation', 'general', 'supplier', 'customer']) and x['amount'], line_vals) if not transactions: - normal2info = True # don't create a bank statement for CODA's without transactions + normal2info = True # don't create a bank statement for CODA's without transactions if normal2info: - statement['type'] = 'info' # don't create a bank statement for CODA's without transactions + statement['type'] = 'info' # don't create a bank statement for CODA's without transactions statement['coda_parsing_note'] += _("\n\nThe CODA Statement %s does not contain transactions, hence no Bank Statement has been created." \ "\nSelect the 'CODA Bank Statement' to check the contents of %s.") \ - %(statement['name'], statement['name']) - + % (statement['name'], statement['name']) + coda_st_id = coda_st_obj.create(cr, uid, { 'name': statement['name'], 'type': statement['type'], 'coda_bank_account_id': statement['coda_bank_account_id'], - 'currency': statement['currency_id'], + 'currency': statement['currency_id'], 'journal_id': statement['journal_id'], 'coda_id': coda_id, 'date': statement['date'], 'coda_creation_date': statement['coda_creation_date'], 'period_id': statement['period_id'], 'old_balance_date': statement['old_balance_date'], - 'new_balance_date': statement['new_balance_date'], + 'new_balance_date': statement['new_balance_date'], 'balance_start': statement['balance_start'], 'balance_end_real': statement['balance_end_real'], }) @@ -904,10 +901,10 @@ class account_coda_import(osv.osv_memory): dup_ids = bank_st_obj.search(cr, uid, [('name', '=', statement['name']), ('company_id', '=', company_id)]) if dup_ids: discard = True - statement['type'] = 'info' # don't create a bank statement for duplicates + statement['type'] = 'info' # don't create a bank statement for duplicates statement['coda_parsing_note'] += _("\n\nThe Bank Statement %s already exists, hence no duplicate Bank Statement has been created." \ "\nSelect the 'CODA Bank Statement' to check the contents of %s.") \ - %(statement['name'], statement['name']) + % (statement['name'], statement['name']) # create only bank statement for CODA's of type 'normal' if statement['type'] == 'normal' and not discard: @@ -924,16 +921,16 @@ class account_coda_import(osv.osv_memory): if journal.default_debit_account_id and (journal.default_credit_account_id == journal.default_debit_account_id): balance_start_check = journal.default_debit_account_id.balance else: - nb_err += 1 + nb_err += 1 err_string += _('\nConfiguration Error in journal %s!' \ '\nPlease verify the Default Debit and Credit Account settings.') % journal.name break - if balance_start_check <> statement['balance_start']: + if balance_start_check != statement['balance_start']: balance_start_err_string = _('\nThe CODA Statement %s Starting Balance (%.2f) does not correspond with the previous Closing Balance (%.2f) in journal %s!') \ - % (statement['name'], statement['balance_start'], balance_start_check, journal.name) + % (statement['name'], statement['balance_start'], balance_start_check, journal.name) if statement['balance_start_enforce']: - nb_err += 1 - err_string += balance_start_err_string + nb_err += 1 + err_string += balance_start_err_string break else: statement['coda_parsing_note'] += '\n' + balance_start_err_string @@ -950,89 +947,90 @@ class account_coda_import(osv.osv_memory): } st_hook_error, st_vals = self._statement_hook(cr, uid, statement['coda_bank_params'], st_vals, context=context) if st_hook_error: - nb_err += 1 - err_string += st_hook_error + nb_err += 1 + err_string += st_hook_error break bk_st_id = bank_st_obj.create(cr, uid, st_vals, context=context) bk_st_ids.append(bk_st_id) coda_st_obj.write(cr, uid, [coda_st_id], {'statement_id': bk_st_id}, context=context) - + st_line_seq = 0 for x in lines: line = lines[x] - + if not line['type'] == 'communication': if line['trans_family'] in st_line_name_families: - line['name'] = get_st_line_name(line, context) + line['name'] = get_st_line_name(line, context) if line['type'] == 'information': if line['struct_comm_type'] in parse_comms_info: line['name'], line['communication'] = parse_comm_info(self, cr, uid, line, comm_type_table, context) elif line['struct_comm_type'] in parse_comms_move: - line['name'], line['communication'] = parse_comm_move(self, cr, uid, line, comm_type_table, context) + line['name'], line['communication'] = parse_comm_move(self, cr, uid, line, comm_type_table, context) elif line['struct_comm_type'] in parse_comms_move: line['name'], line['communication'] = parse_comm_move(self, cr, uid, line, comm_type_table, context) # handling non-transactional records : line['type'] in ['information', 'communication'] - + if line['type'] == 'information': - line['globalisation_id'] = glob_id_stack[-1][2] + #Check if this line can be deleted. glob_id_stack marked as undefined here + #line['globalisation_id'] = glob_id_stack[-1][2] line_note = _('Transaction Type' ': %s - %s' \ '\nTransaction Family: %s - %s' \ '\nTransaction Code: %s - %s' \ '\nTransaction Category: %s - %s' \ '\nStructured Communication Type: %s - %s' \ '\nCommunication: %s') \ - %(line['trans_type'], line['trans_type_desc'], + % (line['trans_type'], line['trans_type_desc'], line['trans_family'], line['trans_family_desc'], line['trans_code'], line['trans_code_desc'], line['trans_category'], line['trans_category_desc'], line['struct_comm_type'], line['struct_comm_type_desc'], line['communication']) - - coda_st_line_id = coda_st_line_obj.create(cr, uid, { + + coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], + 'ref': line['ref'], 'name': line['name'].strip() or '/', - 'type' : 'information', - 'date': line['entry_date'], + 'type': 'information', + 'date': line['entry_date'], 'statement_id': coda_st_id, 'note': line_note, }) - + elif line['type'] == 'communication': line_note = _('Free Communication:\n %s') \ - %(line['communication']) - - coda_st_line_id = coda_st_line_obj.create(cr, uid, { + % (line['communication']) + + coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], + 'ref': line['ref'], 'name': line['name'].strip() or '/', - 'type' : 'communication', + 'type': 'communication', 'date': statement['date'], 'statement_id': coda_st_id, 'note': line_note, }) - # handling transactional records, # line['type'] in ['globalisation', 'general', 'supplier', 'customer'] + # handling transactional records, # line['type'] in ['globalisation', 'general', 'supplier', 'customer'] else: - + if line['ref_move_detail'] == '0000': glob_id_stack = [(0, '', 0, '')] # initialise stack with tuples (glob_lvl_flag, glob_code, glob_id, glob_name) - + glob_lvl_flag = line['glob_lvl_flag'] - if glob_lvl_flag: - if glob_id_stack[-1][0] == glob_lvl_flag: + if glob_lvl_flag: + if glob_id_stack[-1][0] == glob_lvl_flag: line['globalisation_id'] = glob_id_stack[-1][2] glob_id_stack.pop() else: glob_name = line['name'].strip() or '/' glob_code = seq_obj.get(cr, uid, 'statement.line.global') glob_id = glob_obj.create(cr, uid, { - 'code': glob_code, + 'code': glob_code, 'name': glob_name, 'type': 'coda', 'parent_id': glob_id_stack[-1][2], @@ -1041,7 +1039,7 @@ class account_coda_import(osv.osv_memory): }) line['globalisation_id'] = glob_id glob_id_stack.append((glob_lvl_flag, glob_code, glob_id, glob_name)) - + line_note = _('Partner Name: %s \nPartner Account Number: %s' \ '\nTransaction Type: %s - %s' \ '\nTransaction Family: %s - %s' \ @@ -1050,64 +1048,64 @@ class account_coda_import(osv.osv_memory): '\nStructured Communication Type: %s - %s' \ '\nPayment Reference: %s' \ '\nCommunication: %s') \ - %(line['counterparty_name'], line['counterparty_number'], + % (line['counterparty_name'], line['counterparty_number'], line['trans_type'], line['trans_type_desc'], line['trans_family'], line['trans_family_desc'], line['trans_code'], line['trans_code_desc'], line['trans_category'], line['trans_category_desc'], line['struct_comm_type'], line['struct_comm_type_desc'], - line['payment_reference'], + line['payment_reference'], line['communication']) - + if line['type'] == 'globalisation': - - coda_st_line_id = coda_st_line_obj.create(cr, uid, { + + coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], + 'ref': line['ref'], 'name': line['name'].strip() or '/', - 'type' : 'globalisation', - 'val_date' : line['val_date'], + 'type': 'globalisation', + 'val_date': line['val_date'], 'date': line['entry_date'], - 'globalisation_level': line['glob_lvl_flag'], - 'globalisation_amount': line['globalisation_amount'], - 'globalisation_id': line['globalisation_id'], + 'globalisation_level': line['glob_lvl_flag'], + 'globalisation_amount': line['globalisation_amount'], + 'globalisation_id': line['globalisation_id'], 'partner_id': line['partner_id'] or 0, 'account_id': line['account_id'], - 'payment_reference': line['payment_reference'], + 'payment_reference': line['payment_reference'], 'statement_id': coda_st_id, 'note': line_note, }) - else: # line['type'] in ['general', 'supplier', 'customer'] + else: # line['type'] in ['general', 'supplier', 'customer'] - if glob_lvl_flag == 0: + if glob_lvl_flag == 0: line['globalisation_id'] = glob_id_stack[-1][2] - if not line['account_id']: + if not line['account_id']: line['account_id'] = awaiting_acc - - coda_st_line_id = coda_st_line_obj.create(cr, uid, { + + coda_st_line_obj.create(cr, uid, { 'sequence': line['sequence'], - 'ref': line['ref'], - 'name': line['name'].strip() or '/', - 'type' : line['type'], - 'val_date' : line['val_date'], + 'ref': line['ref'], + 'name': line['name'].strip() or '/', + 'type': line['type'], + 'val_date': line['val_date'], 'date': line['entry_date'], 'amount': line['amount'], 'partner_id': line['partner_id'] or 0, 'counterparty_name': line['counterparty_name'], - 'counterparty_bic': line['counterparty_bic'], - 'counterparty_number': line['counterparty_number'], - 'counterparty_currency': line['counterparty_currency'], + 'counterparty_bic': line['counterparty_bic'], + 'counterparty_number': line['counterparty_number'], + 'counterparty_currency': line['counterparty_currency'], 'account_id': line['account_id'], - 'globalisation_level': line['glob_lvl_flag'], - 'globalisation_id': line['globalisation_id'], - 'payment_reference': line['payment_reference'], + 'globalisation_level': line['glob_lvl_flag'], + 'globalisation_id': line['globalisation_id'], + 'payment_reference': line['payment_reference'], 'statement_id': coda_st_id, 'note': line_note, }) if statement['type'] == 'normal': - if line['amount'] != 0.0: + if line['amount'] != 0.0: st_line_seq += 1 voucher_id = False line_name = line['name'].strip() @@ -1116,9 +1114,9 @@ class account_coda_import(osv.osv_memory): line_name = glob_id_stack[-1][3] or '/' else: line_name = '/' - + if line['reconcile']: - + move_line = move_line_obj.browse(cr, uid, line['reconcile'], context=context) company_currency_id = journal.company_id.currency_id.id currency_id = journal.currency.id @@ -1128,11 +1126,11 @@ class account_coda_import(osv.osv_memory): multi_currency = False context_multi_currency = context.copy() context_multi_currency.update({'date': line['entry_date']}) - + line_cr_ids = [] line_dr_ids = [] - amount_remaining = abs(line['amount']) - + amount_remaining = abs(line['amount']) + #for entry in entries: if move_line.reconcile_partial_id: amount_original = abs(move_line.amount_residual_currency) @@ -1142,7 +1140,7 @@ class account_coda_import(osv.osv_memory): if move_line.currency_id and move_line.amount_currency: amount_original = abs(move_line.amount_currency) else: - amount_original = currency_obj.compute(cr, uid, company_currency_id, currency_id, original_amount, context=context_multi_currency) + amount_original = currency_obj.compute(cr, uid, company_currency_id, currency_id, amount_original, context=context_multi_currency) if amount_remaining > 0: amount_voucher_line = min(amount_original, abs(amount_remaining)) amount_remaining -= amount_voucher_line @@ -1160,8 +1158,8 @@ class account_coda_import(osv.osv_memory): line_cr_ids += [(0, 0, voucher_line_vals)] else: line_dr_ids += [(0, 0, voucher_line_vals)] - - voucher_vals = { + + voucher_vals = { 'type': line['type'] == 'supplier' and 'payment' or 'receipt', 'name': line_name, 'date': line['val_date'], @@ -1179,9 +1177,9 @@ class account_coda_import(osv.osv_memory): 'number': statement['name'] + '/' + str(st_line_seq), 'partner_id': line['partner_id'], } - + #_logger.warn('voucher_vals=%s, context=%s', voucher_vals, context) - context['journal_id'] = journal.id # add journal to context for __get_payment_rate_currency method + context['journal_id'] = journal.id # add journal to context for __get_payment_rate_currency method if line_cr_ids or line_dr_ids: voucher_id = voucher_obj.create(cr, uid, voucher_vals, context=context) else: @@ -1205,25 +1203,25 @@ class account_coda_import(osv.osv_memory): line['account_id'] = account_id st_line_vals = { - 'ref': line['ref'], + 'ref': line['ref'], 'name': line_name, - 'type' : line['type'], - 'val_date' : line['val_date'], + 'type': line['type'], + 'val_date': line['val_date'], 'date': line['entry_date'], 'amount': line['amount'], 'partner_id': line['partner_id'] or 0, 'counterparty_name': line['counterparty_name'], - 'counterparty_bic': line['counterparty_bic'], - 'counterparty_number': line['counterparty_number'], - 'counterparty_currency': line['counterparty_currency'], + 'counterparty_bic': line['counterparty_bic'], + 'counterparty_number': line['counterparty_number'], + 'counterparty_currency': line['counterparty_currency'], 'account_id': line['account_id'], - 'globalisation_id': line['globalisation_id'], - 'payment_reference': line['payment_reference'], + 'globalisation_id': line['globalisation_id'], + 'payment_reference': line['payment_reference'], 'statement_id': bk_st_id, 'voucher_id': voucher_id, 'note': line_note, } - + st_lines_vals = self._st_line_hook(cr, uid, statement['coda_bank_params'], st_line_vals, context=context) if not st_lines_vals: # removal of lines by the _coda_parsing_hook currently not supported : @@ -1234,7 +1232,7 @@ class account_coda_import(osv.osv_memory): for st_line_vals in st_lines_vals: # To DO : update sequence of statement lines and naming of associated vouchers/moves when the hook returns multiple lines st_line_vals.update({'sequence': st_line_seq}) - bank_st_line_id = bank_st_line_obj.create(cr, uid, st_line_vals, context=context) + bank_st_line_obj.create(cr, uid, st_line_vals, context=context) if st_line_vals['voucher_id']: voucher = voucher_obj.browse(cr, uid, st_line_vals['voucher_id'], context=context) move_line = move_line_obj.browse(cr, uid, line['reconcile'], context=context) @@ -1247,7 +1245,7 @@ class account_coda_import(osv.osv_memory): coda_st_obj.write(cr, uid, [coda_st_id], {}, context=context) # calculate balance st_balance = coda_st_obj.read(cr, uid, coda_st_id, ['balance_end', 'balance_end_real'], context=context) - if st_balance['balance_end'] <> st_balance['balance_end_real']: + if st_balance['balance_end'] != st_balance['balance_end_real']: err_string += _('\nIncorrect ending Balance in CODA Statement %s for Bank Account %s!') \ % (statement['coda_seq_number'], (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description'])) if statement['type'] == 'normal': @@ -1255,9 +1253,9 @@ class account_coda_import(osv.osv_memory): break else: statement['coda_parsing_note'] += '\n' + err_string - - if statement['type'] == 'normal': - bank_st_obj.button_dummy(cr, uid, [bk_st_id], context=context) # calculate balance + + if statement['type'] == 'normal': + bank_st_obj.button_dummy(cr, uid, [bk_st_id], context=context) # calculate balance journal_name = journal.name else: journal_name = _('None') @@ -1270,16 +1268,16 @@ class account_coda_import(osv.osv_memory): '\nAccount Holder Name: %s' \ '\nDate: %s, Starting Balance: %.2f, Ending Balance: %.2f' \ '%s') \ - %(journal_name, + % (journal_name, coda_version, statement['coda_seq_number'], statement['paper_nb_seq_number'], (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description']), statement['acc_holder'], statement['date'], float(statement['balance_start']), float(statement['balance_end_real']), - statement['coda_parsing_note'] % {'name':coda_statement['name']}) + statement['coda_parsing_note'] % {'name': coda_statement['name']}) if statement.get('separate_application') != '00000': - coda_note += _('\nCode Separate Application: %s') %statement['separate_application'] \ + coda_note += _('\nCode Separate Application: %s') % statement['separate_application'] \ except osv.except_osv, e: cr.rollback() @@ -1293,25 +1291,25 @@ class account_coda_import(osv.osv_memory): nb_err += 1 err_string += _('\nSystem Error : ') + str(e) tb = ''.join(format_exception(*exc_info())) - _logger.error('System Error while processing Statement %s\n%s', - statement.get('name', '/'),tb) - except : + _logger.error('System Error while processing Statement %s\n%s', + statement.get('name', '/'), tb) + except: cr.rollback() nb_err += 1 err_string = _('\nUnknown Error : ') + str(e) tb = ''.join(format_exception(*exc_info())) _logger.error('Unknown Error while processing Statement %s\n%s', - statement.get('name', '/'),tb) + statement.get('name', '/'), tb) # end 'for statement in coda_statements' - + coda_note_header = _('CODA File is Imported :') coda_note_footer = _('\n\nNumber of statements : ') + str(len(coda_st_ids)) err_log = err_log + _('\nNumber of errors : ') + str(nb_err) + '\n' if not nb_err: note = coda_note_header + coda_note + coda_note_footer - coda_obj.write(cr, uid,[coda_id],{'note': note }) + coda_obj.write(cr, uid, [coda_id], {'note': note}) cr.commit() if batch: return None @@ -1321,12 +1319,12 @@ class account_coda_import(osv.osv_memory): err_code = 'G0002' return (err_code, err_string) raise osv.except_osv(_('CODA Import failed !'), err_string) - - context.update({ 'bk_st_ids': bk_st_ids}) + + context.update({'bk_st_ids': bk_st_ids}) model_data_ids = mod_obj.search(cr, uid, [('model', '=', 'ir.ui.view'), ('name', '=', 'account_coda_import_result_view')], context=context) resource_id = mod_obj.read(cr, uid, model_data_ids, fields=['res_id'], context=context)[0]['res_id'] self.write(cr, uid, ids, {'note': note}, context=context) - + return { 'name': _('Import CODA File result'), 'res_id': ids[0], @@ -1341,16 +1339,16 @@ class account_coda_import(osv.osv_memory): } def _statement_hook(self, cr, uid, coda_bank_params, st_vals, context=None): - """ + """ Use this method to take customer specific actions based upon the bank statement data. Returns: st_hook_error : False or string with error message - st_vals + st_vals """ return False, st_vals def _st_line_hook(self, cr, uid, coda_bank_params, st_line_vals, context=None): - """ + """ Use this method to adapt the statement line created by the CODA parsing to customer specific needs. """ @@ -1374,43 +1372,50 @@ class account_coda_import(osv.osv_memory): res_model, res_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, module, xml_id) action = self.pool.get('ir.actions.act_window').read(cr, uid, res_id, context=context) domain = eval(action.get('domain') or '[]') - domain += [('id','in', context.get('bk_st_ids', False))] + domain += [('id', 'in', context.get('bk_st_ids', False))] action.update({'domain': domain}) return action - + account_coda_import() + def repl_special(s): s = s.replace("\'", "\'" + "'") return s + def str2date(date_str): try: - return time.strftime('%Y-%m-%d', time.strptime(date_str,'%d%m%y')) + return time.strftime('%Y-%m-%d', time.strptime(date_str, '%d%m%y')) except: return False + def str2time(time_str): return time_str[:2] + ':' + time_str[2:] + def str2float(str): try: return float(str) except: return 0.0 + def list2float(lst): try: - return str2float((lambda s : s[:-3] + '.' + s[-3:])(lst)) + return str2float((lambda s: s[:-3] + '.' + s[-3:])(lst)) except: return 0.0 + def number2float(s, d): try: - return float(s[:len(s)-d] + '.' + s[len(s)-d:]) + return float(s[:len(s) - d] + '.' + s[len(s) - d:]) except: return False + def _get_acc_numbers(acc_number): #TODO this method is needed because the iban and bank account fields have been merged together. But sometimes we # need to retrieve the normal bank account from the IBAN. This should be globalized and defined as a method on the @@ -1422,6 +1427,7 @@ def _get_acc_numbers(acc_number): from base_iban.base_iban import _ref_iban, _format_iban + def calc_iban_checksum(country, bban): bban = bban.replace(' ', '').upper() + country.upper() + '00' base = '' @@ -1433,16 +1439,18 @@ def calc_iban_checksum(country, bban): kk = 98 - int(base) % 97 return str(kk).rjust(2, '0') + def check_bban(country, bban): if country == 'BE': try: int(bban) except: - return False + return False if len(bban) != 12: return False return True + def check_iban(iban): """ Check the IBAN number (logic partially based upon base_iban module, cf. is_iban_valid method) @@ -1458,20 +1466,21 @@ def check_iban(iban): iban2 = "" for char in iban: if char.isalpha(): - iban2 += str(ord(char)-87) + iban2 += str(ord(char) - 87) else: iban2 += char #iban is correct if modulo 97 == 1 return int(iban2) % 97 == 1 + def get_bank(self, cr, uid, bic, iban): - country_obj = self.pool.get('res.country') + country_obj = self.pool.get('res.country') bank_obj = self.pool.get('res.bank') bank_id = False bank_name = False - feedback = False + feedback = False bank_country = iban[:2] try: bank_country_id = country_obj.search(cr, uid, [('code', '=', bank_country)])[0] @@ -1505,7 +1514,7 @@ def get_bank(self, cr, uid, bic, iban): feedback = _("\n Bank lookup failed. Please define a Bank with Code '%s' and Country '%s' !") \ % (bank_code, country.name) else: - if not bic: + if not bic: feedback = _("\n Bank lookup failed due to missing BIC in Bank Statement for IBAN '%s' !") \ % (iban) else: @@ -1518,10 +1527,11 @@ def get_bank(self, cr, uid, bic, iban): 'country': bank_country_id, }) else: - bank_id = bank_ids[0] - + bank_id = bank_ids[0] + return bank_id, bic, bank_name, feedback - + + def update_partner_bank(self, cr, uid, bic, iban, partner_id, counterparty_name): partner_bank_obj = self.pool.get('res.partner.bank') bank_id = False @@ -1531,7 +1541,6 @@ def update_partner_bank(self, cr, uid, bic, iban, partner_id, counterparty_name) if not bank_id: return feedback else: - bban = iban #convert belgian BBAN numbers to IBAN if check_bban('BE', iban): kk = calc_iban_checksum('BE', iban) @@ -1541,22 +1550,23 @@ def update_partner_bank(self, cr, uid, bic, iban, partner_id, counterparty_name) return feedback if bank_id: - partner_bank_id = partner_bank_obj.create(cr, uid, { + partner_bank_obj.create(cr, uid, { 'partner_id': partner_id, 'name': counterparty_name, 'bank': bank_id, 'state': 'iban', 'bank_bic': bic, - 'bank_name': bank_name, + 'bank_name': bank_name, 'acc_number': iban, }) return feedback -indent = '\n' + 8*' ' +indent = '\n' + 8 * ' ' st_line_name_families = ['13', '35', '41', '80'] parse_comms_move = ['100', '101', '102', '103', '105', '106', '107', '108', '111', '113', '114', '115', '121', '122', '123', '124', '125', '126', '127'] parse_comms_info = ['001', '002', '004', '005', '006', '007', '107', '008', '009', '010', '011'] + def get_st_line_name(line, context): #_logger.warn('get_st_line_name - entry').warn('ref = %s, family = %s, code = %s, categ = %s', line['ref'], line['trans_family'], line['trans_code'], line['trans_category']) st_line_name = line['name'] @@ -1572,6 +1582,7 @@ def get_st_line_name(line, context): return st_line_name + def parse_comm_move(self, cr, uid, line, comm_type_table, context): #_logger.warn('parse_comm_move - entry, ref = %s, family = %s, code = %s, categ = %s, comm_type = %s, name = %s', line['ref'], line['trans_family'], line['trans_code'], line['trans_category'], line['struct_comm_type'], line['name']) comm_type = line['struct_comm_type'] @@ -1628,7 +1639,7 @@ def parse_comm_move(self, cr, uid, line, comm_type_table, context): '1': _('direct debit cancelled or nonexistent'), '2': _('refusal - other reason'), 'D': _('payer disagrees'), - 'E': _('direct debit number linked to another identification number of the creditor')} + 'E': _('direct debit number linked to another identification number of the creditor')} st_line_name = _('Direct debit - DOM\'80') direct_debit_number = comm[0:12].strip() pivot_date = str2date(comm[12:18]) @@ -1649,7 +1660,7 @@ def parse_comm_move(self, cr, uid, line, comm_type_table, context): st_line_comm += indent + _('Interest rates, calculation basis') + ': %.2f' % list2float(comm[15:30]) + \ indent + _('Interest') + ': %.2f' % list2float(comm[30:42]) - if comm_type =='111': + if comm_type == '111': card_schemes = { '1': 'Bancontact/Mister Cash', '2': _('Private'), @@ -1781,10 +1792,10 @@ def parse_comm_move(self, cr, uid, line, comm_type_table, context): if comm_type == '123': starting_date = str2date(comm[0:6]) maturity_date = comm[6:12] == '999999' and _('guarantee without fixed term') or str2date(comm[0:6]) - basic_amount = list2float(comm[12:27]) + basic_amount = list2float(comm[12:27]) percent = number2float(comm[27:39], 8) term = comm[39:43].lstrip('0') - minimum = comm[43] == '1' and True or False + minimum = comm[43] == '1' and True or False guarantee_number = comm[44:57].strip() st_line_comm = '\n' + indent + st_line_name + indent + _('Starting Date') + ': %s' % starting_date st_line_comm += indent + _('Maturity Date') + ': %s' % maturity_date @@ -1793,7 +1804,7 @@ def parse_comm_move(self, cr, uid, line, comm_type_table, context): st_line_comm += indent + _('Term in days') + ': %s' % term st_line_comm += indent + (minimum and _('Minimum applicable') or _('Minimum not applicable')) st_line_comm += indent + _('Guarantee Number') + ': %s' % guarantee_number - + if comm_type == '124': card_issuers = { '1': 'Mastercard', @@ -1812,7 +1823,7 @@ def parse_comm_move(self, cr, uid, line, comm_type_table, context): st_line_comm += indent + _('Invoice Number') + ': %s' % invoice_number st_line_comm += indent + _('Identification Number') + ': %s' % identification_number st_line_comm += indent + _('Date') + ': %s' % date - + if comm_type == '125': if line['trans_family'] not in st_line_name_families: st_line_name = _('Credit') @@ -1836,31 +1847,31 @@ def parse_comm_move(self, cr, uid, line, comm_type_table, context): st_line_comm += indent + _('End Date') + ': %s' % end_date st_line_comm += indent + _('Nominal Interest Rate or Rate of Charge') + ': %.4f' % rate st_line_comm += indent + _('Transaction Reference') + ': %s' % trans_reference - + if comm_type == '127': direct_debit_types = { '0': _('unspecified'), '1': _('recurrent'), '2': _('one-off'), '3': _('1-st (recurrent)'), - '4': _('last (recurrent)')} + '4': _('last (recurrent)')} direct_debit_schemes = { '0': _('unspecified'), '1': _('SEPA core'), - '2': _('SEPA B2B')} + '2': _('SEPA B2B')} paid_refusals = { '0': _('paid'), '1': _('technical problem'), '2': _('refusal - reason not specified'), '3': _('debtor disagrees'), - '4': _('debtor\'s account problem')} + '4': _('debtor\'s account problem')} R_types = { '0': _('paid'), '1': _('reject'), '2': _('return'), '3': _('refund'), '4': _('reversal'), - '5': _('cancellation')} + '5': _('cancellation')} st_line_name = _('European direct debit (SEPA)') settlement_date = str2date(comm[0:6]) direct_debit_type = direct_debit_types.get(comm[6], '') @@ -1880,14 +1891,15 @@ def parse_comm_move(self, cr, uid, line, comm_type_table, context): st_line_comm += indent + _('Communication') + ': %s' % comm_zone st_line_comm += indent + _('R transaction Type') + ': %s' % R_type st_line_comm += indent + _('Reason') + ': %s' % reason - + return st_line_name, st_line_comm + def parse_comm_info(self, cr, uid, line, comm_type_table, context): comm_type = line['struct_comm_type'] comm = st_line_comm = line['communication'] st_line_name = line['name'] - + if comm_type == '001': st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] st_line_comm = '\n' + indent + st_line_name + indent + _('Name') + ': %s' % comm[0:70].strip() @@ -1900,7 +1912,6 @@ def parse_comm_info(self, cr, uid, line, comm_type_table, context): st_line_comm = comm.strip() if comm_type == '006': - amount_sign = comm[48] amount = (comm[48] == '1' and '-' or '') + ('%.2f' % list2float(comm[33:48])) + ' ' + comm[30:33] st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] st_line_comm = '\n' + indent + st_line_name + indent + _('Description of the detail') + ': %s' % comm[0:30].strip() @@ -1912,5 +1923,4 @@ def parse_comm_info(self, cr, uid, line, comm_type_table, context): 'Please contact Noviat (info@noviat.be) for more information about the development roadmap', comm_type) return st_line_name, st_line_comm - -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: From 5d44b0f624c6fe354529a4aa265d9bca373daff1 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Mon, 3 Dec 2012 17:51:39 +0100 Subject: [PATCH 06/41] [FIX]Unexisting payment reference, wrong operator in sql req bzr revid: dle@openerp.com-20121203165139-qov9jfk91wxv3qb9 --- addons/l10n_be_coda/l10n_be_coda_view.xml | 2 +- addons/l10n_be_coda/wizard/account_coda_import.py | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/addons/l10n_be_coda/l10n_be_coda_view.xml b/addons/l10n_be_coda/l10n_be_coda_view.xml index fb0a12b73fb..1ef09862c3d 100644 --- a/addons/l10n_be_coda/l10n_be_coda_view.xml +++ b/addons/l10n_be_coda/l10n_be_coda_view.xml @@ -246,7 +246,7 @@ - + diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index ea7558e13da..5a1b530d38c 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -913,7 +913,7 @@ class account_coda_import(osv.osv_memory): balance_start_check_date = statement['first_transaction_date'] or statement['date'] cr.execute('SELECT balance_end_real \ FROM account_bank_statement \ - WHERE journal_id = %s and date < %s \ + WHERE journal_id = %s and date <= %s \ ORDER BY date DESC,id DESC LIMIT 1', (statement['journal_id'], balance_start_check_date)) res = cr.fetchone() balance_start_check = res and res[0] @@ -975,7 +975,7 @@ class account_coda_import(osv.osv_memory): if line['type'] == 'information': #Check if this line can be deleted. glob_id_stack marked as undefined here - #line['globalisation_id'] = glob_id_stack[-1][2] + line['globalisation_id'] = glob_id_stack[-1][2] line_note = _('Transaction Type' ': %s - %s' \ '\nTransaction Family: %s - %s' \ '\nTransaction Code: %s - %s' \ @@ -1035,7 +1035,6 @@ class account_coda_import(osv.osv_memory): 'type': 'coda', 'parent_id': glob_id_stack[-1][2], 'amount': line['globalisation_amount'], - 'payment_reference': line['payment_reference'] }) line['globalisation_id'] = glob_id glob_id_stack.append((glob_lvl_flag, glob_code, glob_id, glob_name)) @@ -1201,7 +1200,6 @@ class account_coda_import(osv.osv_memory): account_id = account_mapping_obj.account_id_get(cr, uid, **kwargs) if account_id: line['account_id'] = account_id - st_line_vals = { 'ref': line['ref'], 'name': line_name, @@ -1216,7 +1214,6 @@ class account_coda_import(osv.osv_memory): 'counterparty_currency': line['counterparty_currency'], 'account_id': line['account_id'], 'globalisation_id': line['globalisation_id'], - 'payment_reference': line['payment_reference'], 'statement_id': bk_st_id, 'voucher_id': voucher_id, 'note': line_note, From 0b32c75f74bec07d3e52fa2651a1929cc168e79b Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Tue, 4 Dec 2012 18:59:48 +0100 Subject: [PATCH 07/41] [REF]Whole code of coda parser bzr revid: dle@openerp.com-20121204175948-ckz5s05dgqgv0tq1 --- addons/account/account_bank_statement.py | 2 +- addons/l10n_be_coda/wizard/__init__.py | 2 +- .../wizard/account_coda_import.py | 7 +- .../wizard/account_coda_import_dle.py | 331 ++++++++++++++++++ 4 files changed, 339 insertions(+), 3 deletions(-) create mode 100644 addons/l10n_be_coda/wizard/account_coda_import_dle.py diff --git a/addons/account/account_bank_statement.py b/addons/account/account_bank_statement.py index e7e3f740067..60f2b230c05 100644 --- a/addons/account/account_bank_statement.py +++ b/addons/account/account_bank_statement.py @@ -546,7 +546,7 @@ class account_bank_statement_line(osv.osv): _name = "account.bank.statement.line" _description = "Bank Statement Line" _columns = { - 'name': fields.char('Communication', size=64, required=True), + 'name': fields.char('Communication', size=256, required=True), 'date': fields.date('Date', required=True), 'amount': fields.float('Amount', digits_compute=dp.get_precision('Account')), 'type': fields.selection([ diff --git a/addons/l10n_be_coda/wizard/__init__.py b/addons/l10n_be_coda/wizard/__init__.py index e3038609b80..3851606707b 100644 --- a/addons/l10n_be_coda/wizard/__init__.py +++ b/addons/l10n_be_coda/wizard/__init__.py @@ -20,6 +20,6 @@ # ############################################################################## -import account_coda_import +import account_coda_import_dle # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 5a1b530d38c..fdd56204f77 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -973,6 +973,8 @@ class account_coda_import(osv.osv_memory): # handling non-transactional records : line['type'] in ['information', 'communication'] if line['type'] == 'information': + if line['ref_move_detail'] == '0000': + glob_id_stack = [(0, '', 0, '')] # initialise stack with tuples (glob_lvl_flag, glob_code, glob_id, glob_name) #Check if this line can be deleted. glob_id_stack marked as undefined here line['globalisation_id'] = glob_id_stack[-1][2] @@ -1349,12 +1351,15 @@ class account_coda_import(osv.osv_memory): Use this method to adapt the statement line created by the CODA parsing to customer specific needs. """ + print 'PLZ DISPLAY SOMETHING RIGHTPLZPLZPLZ' + print st_line_vals['name'] + print st_line_vals['counterparty_name'] return [st_line_vals] def action_open_coda_statements(self, cr, uid, ids, context=None): if context is None: context = {} - module, xml_id = 'account_coda', 'action_coda_bank_statements' + module, xml_id = 'l10n_be_coda', 'action_coda_bank_statements' res_model, res_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, module, xml_id) action = self.pool.get('ir.actions.act_window').read(cr, uid, res_id, context=context) domain = eval(action.get('domain') or '[]') diff --git a/addons/l10n_be_coda/wizard/account_coda_import_dle.py b/addons/l10n_be_coda/wizard/account_coda_import_dle.py new file mode 100644 index 00000000000..be8bb147698 --- /dev/null +++ b/addons/l10n_be_coda/wizard/account_coda_import_dle.py @@ -0,0 +1,331 @@ +# -*- encoding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# +# Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +import base64 +from osv import fields, osv +from tools.translate import _ +import time +import tools +import logging +_logger = logging.getLogger(__name__) + + +class account_coda_import(osv.osv_memory): + _name = 'account.coda.import' + _description = 'Import CODA File' + _columns = { + 'coda_data': fields.binary('CODA File', required=True), + 'coda_fname': fields.char('CODA Filename', size=128, required=True), + 'note': fields.text('Log'), + } + _defaults = { + 'coda_fname': lambda *a: '', + } + + def coda_parsing(self, cr, uid, ids, context=None, batch=False, codafile=None, codafilename=None): + if context is None: + context = {} + if batch: + codafile = str(codafile) + codafilename = codafilename + else: + data = self.browse(cr, uid, ids)[0] + try: + codafile = data.coda_data + codafilename = data.coda_fname + except: + raise osv.except_osv(_('Error!'), _('Wizard in incorrect state. Please hit the Cancel button!')) + return {} + recordlist = unicode(base64.decodestring(codafile), 'windows-1252', 'strict').split('\n') + statements = [] + for line in recordlist: + if not line: + continue + elif line[0] == '0': + #Begin of a new Bank statement + statement = {} + statements.append(statement) + statement['error'] = False + statement['errors'] = [] + statement['version'] = line[127] + if statement['version'] not in ['1', '2']: + statement['error'] = True + statement['errors'].append(('R0001', _('CODA V%s statements are not supported, please contact your bank!') % statement['version'])) + continue + statement['lines'] = [] + statement['date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[5:11]), '%d%m%y')) + statement['separateApplication'] = rmspaces(line[83:88]) + elif not statement['error']: + if line[0] == '1': + #Statement details + if statement['version'] == '1': + statement['accountNumber'] = rmspaces(line[5:17]) + statement['currency'] = rmspaces(line[18:21]) + elif statement['version'] == '2': + if line[1] == '0': # Belgian bank account BBAN structure + statement['accountNumber'] = rmspaces(line[5:17]) + statement['currency'] = rmspaces(line[18:21]) + elif line[1] == '1': # foreign bank account BBAN structure + statement['error'] = True + statement['errors'].append(('R1001', _('Foreign bank accounts with BBAN structure are not supported !'))) + continue + elif line[1] == '2': # Belgian bank account IBAN structure + statement['accountNumber'] = rmspaces(line[5:21]) + statement['currency'] = rmspaces(line[39:42]) + elif line[1] == '3': # foreign bank account IBAN structure + statement['error'] = True + statement['errors'].append(('R1002', _('Foreign bank accounts with IBAN structure are not supported !'))) + continue + else: # Something else, not supported + statement['error'] = True + statement['errors'].append(('R1003', _('\nUnsupported bank account structure !'))) + continue + statement['description'] = rmspaces(line[90:125]) + statement['balance_start'] = float(rmspaces(line[43:58])) / 1000 + statement['balance_start_date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[58:64]), '%d%m%y')) + statement['accountHolder'] = rmspaces(line[64:90]) + statement['paperSeqNumber'] = rmspaces(line[2:5]) + statement['codaSeqNumber'] = rmspaces(line[125:128]) + elif line[0] == '2': + if line[1] == '1': + #New statement line + statementLine = {} + statementLine['type'] = 'general' + statementLine['ref'] = rmspaces(line[2:10]) + statementLine['ref_move'] = rmspaces(line[2:6]) + statementLine['ref_move_detail'] = rmspaces(line[6:10]) + statementLine['sequence'] = len(statement['lines']) + 1 + if statementLine['sequence'] == 1: + main_move_stack = [statementLine] + glob_lvl_stack = [0] # initialise globalisation stack + elif statementLine['ref_move_detail'] == '0000': + glob_lvl_stack = [0] # re-initialise globalisation stack + statementLine['transactionRef'] = rmspaces(line[10:31]) + statementLine['debit'] = line[31] # 0 = Credit, 1 = Debit + statementLine['amount'] = float(rmspaces(line[32:47])) / 1000 + if statementLine['debit'] == '1': + statementLine['amount'] = - statementLine['amount'] + statementLine['transactionType'] = line[53] + #TODO Handling severals transactions types + statementLine['transactionDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[47:53]), '%d%m%y')) + statementLine['transactionFamily'] = rmspaces(line[54:56]) + #TODO Handling severals transactions Family + statementLine['transactionCode'] = rmspaces(line[56:58]) + #TODO Handling severals transactions code + statementLine['transactionCategory'] = rmspaces(line[58:61]) + #TODO Handling severals transactions category + statementLine['communication'] = rmspaces(line[65:115]) + #TODO Handling structured communication + statementLine['entryDate'] = rmspaces(line[115:121]) + + glob_lvl_flag = int(line[124]) + if glob_lvl_flag > 0: + if glob_lvl_stack[-1] == glob_lvl_flag: + statementLine['glob_lvl_flag'] = glob_lvl_flag + statementLine['amount'] = statementLine['amount'] + glob_lvl_stack.pop() + else: + glob_lvl_stack.append(glob_lvl_flag) + statementLine['type'] = 'globalisation' + statementLine['glob_lvl_flag'] = glob_lvl_flag + statementLine['globalisation_amount'] = statementLine['amount'] + del statementLine['amount'] + + # The 'globalisation' concept can also be implemented without the globalisation level flag. + # This is e.g. used by Europabank to give the details of Card Payments. + if statementLine['ref_move'] == main_move_stack[-1]['ref_move']: + if statementLine['ref_move_detail'] == '9999': + statement['error'] = True + statement['errors'].append(('R1003', _('\nUnsupported bank account structure !'))) + continue + elif statementLine['ref_move_detail'] != '0000': + if glob_lvl_stack[-1] == 0: + # promote associated move record into a globalisation + glob_lvl_flag = 1 + glob_lvl_stack.append(glob_lvl_flag) + main_st_line_seq = main_move_stack[-1]['sequence'] + to_promote = statement['lines'][main_st_line_seq] + if not main_move_stack[-1].get('detail_cnt'): + to_promote.update({ + 'type': 'globalisation', + 'glob_lvl_flag': glob_lvl_flag, + 'globalisation_amount': main_move_stack[-1]['amount'], + 'amount': False, + 'account_id': 0, + }) + main_move_stack[-1]['promoted'] = True + if not main_move_stack[-1].get('detail_cnt'): + main_move_stack[-1]['detail_cnt'] = 1 + else: + main_move_stack[-1]['detail_cnt'] += 1 + + statement['lines'].append(statementLine) + + if statementLine['ref_move'] != main_move_stack[-1]['ref_move']: + if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): + # add closing globalisation level on previous detail record in order to correctly close + # moves that have been 'promoted' to globalisation + closeglobalise = statement['lines'][len(statement['lines']) - 1] + closeglobalise.update({ + 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], + }) + else: + # demote record with globalisation code from 'globalisation' to 'general' when no detail records + # the same logic is repeated on the New Balance Record ('8 Record') in order to cope with CODA files + # containing a single 2.1 record that needs to be 'demoted'. + if main_move_stack[-1]['type'] == 'globalisation' and not main_move_stack[-1].get('detail_cnt'): + # demote record with globalisation code from 'globalisation' to 'general' when no detail records + main_st_line_seq = main_move_stack[-1]['sequence'] + to_demote = statement['lines'][main_st_line_seq] + to_demote.update({ + 'type': 'general', + 'glob_lvl_flag': 0, + 'globalisation_amount': False, + 'amount': main_move_stack[-1]['globalisation_amount'], + }) + main_move_stack.pop() + main_move_stack.append(statementLine) + elif line[1] == '2': + if statement['lines'][-1]['ref'][0:4] != line[2:6]: + statement['error'] = True + statement['errors'].append(('R2004', _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) + continue + statement['lines'][-1]['communication'] += rmspaces(line[10:63]) + statement['lines'][-1]['payment_reference'] = rmspaces(line[63:98]) + statement['lines'][-1]['counterparty_bic'] = rmspaces(line[98:109]) + elif line[1] == '3': + if statement['lines'][-1]['ref'][0:4] != line[2:6]: + statement['error'] = True + statement['errors'].append(('R2004', _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) + continue + if statement['version'] == '1': + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) + statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:125]) + statement['lines'][-1]['counterpartyCurrency'] = '' + else: + if line[22] == ' ': + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) + statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[23:26]) + else: + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:44]) + statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[44:47]) + statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:82]) + statement['lines'][-1]['communication'] += rmspaces(line[82:125]) + else: + # movement data record 2.x (x != 1,2,3) + statement['error'] = True + statement['errors'].append(('R2009', _('\nMovement data records of type 2.%s are not supported !') % line[1])) + elif line[0] == '3': + if line[1] == '1': + infoLine = {} + infoLine['entryDate'] = statement['lines'][-1]['entryDate'] + infoLine['type'] = 'information' + infoLine['sequence'] = len(statement['lines']) + 1 + infoLine['ref'] = rmspaces(line[2:10]) + infoLine['transactionRef'] = rmspaces(line[10:31]) + infoLine['transactionType'] = line[31] + infoLine['transactionFamily'] = rmspaces(line[32:34]) + infoLine['transactionCode'] = rmspaces(line[34:36]) + infoLine['transactioncategory'] = rmspaces(line[36:39]) + infoLine['communication'] = rmspaces(line[40:113]) + statement['lines'].append(infoLine) + elif line[1] == '2': + if statement['lines'][-1]['ref'] != rmspaces(line[2:10]): + statement['error'] = True + statement['errors'].append(('R3004', _('CODA parsing error on information data record 3.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) + continue + statement['lines'][-1]['communication'] += rmspaces(line[10:100]) + elif line[1] == '3': + if statement['lines'][-1]['ref'] != rmspaces(line[2:10]): + statement['error'] = True + statement['errors'].append(('R3005', _('CODA parsing error on information data record 3.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) + continue + statement['lines'][-1]['communication'] += rmspaces(line[10:100]) + elif line[0] == '4': + comm_line = {} + comm_line['type'] = 'communication' + comm_line['sequence'] = len(statement['lines']) + 1 + comm_line['ref'] = rmspaces(line[2:10]) + comm_line['communication'] = rmspaces(line[32:112]) + statement['lines'].append(comm_line) + elif line[0] == '8': + # new balance record + last_transaction = main_move_stack[-1] + if last_transaction['type'] == 'globalisation' and not last_transaction.get('detail_cnt'): + # demote record with globalisation code from 'globalisation' to 'general' when no detail records + main_st_line_seq = main_move_stack[-1]['sequence'] + to_demote = statement['lines'][main_st_line_seq] + to_demote.update({ + 'type': 'general', + 'glob_lvl_flag': 0, + 'globalisation_amount': False, + 'amount': main_move_stack[-1]['globalisation_amount'], + }) + # add closing globalisation level on previous detail record in order to correctly close + # moves that have been 'promoted' to globalisation + if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): + closeglobalise = statement['lines'][-1] + closeglobalise.update({ + 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], + }) + statement['debit'] = line[41] + statement['paperSeqNumber'] = rmspaces(line[1:4]) + statement['balance_end_real'] = float(rmspaces(line[42:57])) / 1000 + statement['balance_end_realDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[57:63]), '%d%m%y')) + if statement['debit'] == '1': # 1=Debit + statement['balance_end_real'] = - statement['balance_end_real'] + if statement['balance_end_realDate']: + period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['balance_end_realDate']), ('date_stop', '>=', statement['balance_end_realDate'])]) + else: + period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['date']), ('date_stop', '>=', statement['date'])]) + if not period_id and len(period_id) == 0: + statement['error'] = True + statement['errors'].append(('R0002', _("The CODA Statement New Balance date doesn't fall within a defined Accounting Period! Please create the Accounting Period for date %s.") % statement['balance_end_realDate'])) + continue + statement['period_id'] = period_id[0] + elif line[0] == '9': + statement['balanceMin'] = float(rmspaces(line[22:37])) / 1000 + statement['balancePlus'] = float(rmspaces(line[37:52])) / 1000 + if not statement['balance_end_real']: + statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] + for i, statement in enumerate(statements): + print '---STATEMENT #' + str(i) + '---' + print statement + if not statement['error']: + data = { + 'name': '[' + statement['date'] + ']' + statement['description'], + 'date': statement['date'], + 'journal_id': 18, + 'period_id': statement['period_id'], + 'balance_start': statement['balance_start'], + 'balance_end_real': statement['balance_end_real'], + 'account_id': 1 + } + self.pool.get('account.bank.statement').create(cr, uid, data, context=context) + +account_coda_import() + + +def rmspaces(s): + return " ".join(s.split()) + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: From 652f81427e71ba307211ef951ad4913fcd5c6842 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Wed, 5 Dec 2012 18:06:50 +0100 Subject: [PATCH 08/41] [IMP]Parser algorithm improvement bzr revid: dle@openerp.com-20121205170650-a6ydpo9qa14d2c55 --- addons/account/account_bank_statement.py | 2 +- addons/account/account_view.xml | 2 +- .../wizard/account_coda_import.py | 3 +- .../wizard/account_coda_import_dle.py | 903 +++++++++++++----- 4 files changed, 659 insertions(+), 251 deletions(-) diff --git a/addons/account/account_bank_statement.py b/addons/account/account_bank_statement.py index 60f2b230c05..db6795a70c8 100644 --- a/addons/account/account_bank_statement.py +++ b/addons/account/account_bank_statement.py @@ -546,7 +546,7 @@ class account_bank_statement_line(osv.osv): _name = "account.bank.statement.line" _description = "Bank Statement Line" _columns = { - 'name': fields.char('Communication', size=256, required=True), + 'name': fields.char('Communication',size=64, required=True), 'date': fields.date('Date', required=True), 'amount': fields.float('Amount', digits_compute=dp.get_precision('Account')), 'type': fields.selection([ diff --git a/addons/account/account_view.xml b/addons/account/account_view.xml index e2c45af8cba..562c1ad6fa1 100644 --- a/addons/account/account_view.xml +++ b/addons/account/account_view.xml @@ -575,7 +575,7 @@ - + diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index fdd56204f77..bb165cf1656 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -973,8 +973,7 @@ class account_coda_import(osv.osv_memory): # handling non-transactional records : line['type'] in ['information', 'communication'] if line['type'] == 'information': - if line['ref_move_detail'] == '0000': - glob_id_stack = [(0, '', 0, '')] # initialise stack with tuples (glob_lvl_flag, glob_code, glob_id, glob_name) + #Check if this line can be deleted. glob_id_stack marked as undefined here line['globalisation_id'] = glob_id_stack[-1][2] diff --git a/addons/l10n_be_coda/wizard/account_coda_import_dle.py b/addons/l10n_be_coda/wizard/account_coda_import_dle.py index be8bb147698..432008fa58e 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import_dle.py +++ b/addons/l10n_be_coda/wizard/account_coda_import_dle.py @@ -45,6 +45,7 @@ class account_coda_import(osv.osv_memory): if context is None: context = {} if batch: + print codafile = str(codafile) codafilename = codafilename else: @@ -59,273 +60,681 @@ class account_coda_import(osv.osv_memory): statements = [] for line in recordlist: if not line: - continue + pass elif line[0] == '0': #Begin of a new Bank statement statement = {} statements.append(statement) - statement['error'] = False - statement['errors'] = [] statement['version'] = line[127] if statement['version'] not in ['1', '2']: - statement['error'] = True - statement['errors'].append(('R0001', _('CODA V%s statements are not supported, please contact your bank!') % statement['version'])) - continue + raise osv.except_osv(_('Error R001!'), _('CODA V%s statements are not supported, please contact your bank!') % statement['version']) + statement['globalisation_stack'] = [] statement['lines'] = [] statement['date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[5:11]), '%d%m%y')) statement['separateApplication'] = rmspaces(line[83:88]) - elif not statement['error']: - if line[0] == '1': - #Statement details - if statement['version'] == '1': + elif line[0] == '1': + #Statement details + if statement['version'] == '1': + statement['accountNumber'] = rmspaces(line[5:17]) + statement['currency'] = rmspaces(line[18:21]) + elif statement['version'] == '2': + if line[1] == '0': # Belgian bank account BBAN structure statement['accountNumber'] = rmspaces(line[5:17]) statement['currency'] = rmspaces(line[18:21]) - elif statement['version'] == '2': - if line[1] == '0': # Belgian bank account BBAN structure - statement['accountNumber'] = rmspaces(line[5:17]) - statement['currency'] = rmspaces(line[18:21]) - elif line[1] == '1': # foreign bank account BBAN structure - statement['error'] = True - statement['errors'].append(('R1001', _('Foreign bank accounts with BBAN structure are not supported !'))) - continue - elif line[1] == '2': # Belgian bank account IBAN structure - statement['accountNumber'] = rmspaces(line[5:21]) - statement['currency'] = rmspaces(line[39:42]) - elif line[1] == '3': # foreign bank account IBAN structure - statement['error'] = True - statement['errors'].append(('R1002', _('Foreign bank accounts with IBAN structure are not supported !'))) - continue - else: # Something else, not supported - statement['error'] = True - statement['errors'].append(('R1003', _('\nUnsupported bank account structure !'))) - continue - statement['description'] = rmspaces(line[90:125]) - statement['balance_start'] = float(rmspaces(line[43:58])) / 1000 - statement['balance_start_date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[58:64]), '%d%m%y')) - statement['accountHolder'] = rmspaces(line[64:90]) - statement['paperSeqNumber'] = rmspaces(line[2:5]) - statement['codaSeqNumber'] = rmspaces(line[125:128]) - elif line[0] == '2': - if line[1] == '1': - #New statement line - statementLine = {} - statementLine['type'] = 'general' - statementLine['ref'] = rmspaces(line[2:10]) - statementLine['ref_move'] = rmspaces(line[2:6]) - statementLine['ref_move_detail'] = rmspaces(line[6:10]) - statementLine['sequence'] = len(statement['lines']) + 1 - if statementLine['sequence'] == 1: - main_move_stack = [statementLine] - glob_lvl_stack = [0] # initialise globalisation stack - elif statementLine['ref_move_detail'] == '0000': - glob_lvl_stack = [0] # re-initialise globalisation stack - statementLine['transactionRef'] = rmspaces(line[10:31]) - statementLine['debit'] = line[31] # 0 = Credit, 1 = Debit - statementLine['amount'] = float(rmspaces(line[32:47])) / 1000 - if statementLine['debit'] == '1': - statementLine['amount'] = - statementLine['amount'] - statementLine['transactionType'] = line[53] - #TODO Handling severals transactions types - statementLine['transactionDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[47:53]), '%d%m%y')) - statementLine['transactionFamily'] = rmspaces(line[54:56]) - #TODO Handling severals transactions Family - statementLine['transactionCode'] = rmspaces(line[56:58]) - #TODO Handling severals transactions code - statementLine['transactionCategory'] = rmspaces(line[58:61]) - #TODO Handling severals transactions category - statementLine['communication'] = rmspaces(line[65:115]) - #TODO Handling structured communication - statementLine['entryDate'] = rmspaces(line[115:121]) - - glob_lvl_flag = int(line[124]) - if glob_lvl_flag > 0: - if glob_lvl_stack[-1] == glob_lvl_flag: - statementLine['glob_lvl_flag'] = glob_lvl_flag - statementLine['amount'] = statementLine['amount'] - glob_lvl_stack.pop() - else: - glob_lvl_stack.append(glob_lvl_flag) - statementLine['type'] = 'globalisation' - statementLine['glob_lvl_flag'] = glob_lvl_flag - statementLine['globalisation_amount'] = statementLine['amount'] - del statementLine['amount'] - - # The 'globalisation' concept can also be implemented without the globalisation level flag. - # This is e.g. used by Europabank to give the details of Card Payments. - if statementLine['ref_move'] == main_move_stack[-1]['ref_move']: - if statementLine['ref_move_detail'] == '9999': - statement['error'] = True - statement['errors'].append(('R1003', _('\nUnsupported bank account structure !'))) - continue - elif statementLine['ref_move_detail'] != '0000': - if glob_lvl_stack[-1] == 0: - # promote associated move record into a globalisation - glob_lvl_flag = 1 - glob_lvl_stack.append(glob_lvl_flag) - main_st_line_seq = main_move_stack[-1]['sequence'] - to_promote = statement['lines'][main_st_line_seq] - if not main_move_stack[-1].get('detail_cnt'): - to_promote.update({ - 'type': 'globalisation', - 'glob_lvl_flag': glob_lvl_flag, - 'globalisation_amount': main_move_stack[-1]['amount'], - 'amount': False, - 'account_id': 0, - }) - main_move_stack[-1]['promoted'] = True - if not main_move_stack[-1].get('detail_cnt'): - main_move_stack[-1]['detail_cnt'] = 1 - else: - main_move_stack[-1]['detail_cnt'] += 1 - - statement['lines'].append(statementLine) - - if statementLine['ref_move'] != main_move_stack[-1]['ref_move']: - if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): - # add closing globalisation level on previous detail record in order to correctly close - # moves that have been 'promoted' to globalisation - closeglobalise = statement['lines'][len(statement['lines']) - 1] - closeglobalise.update({ - 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], - }) - else: - # demote record with globalisation code from 'globalisation' to 'general' when no detail records - # the same logic is repeated on the New Balance Record ('8 Record') in order to cope with CODA files - # containing a single 2.1 record that needs to be 'demoted'. - if main_move_stack[-1]['type'] == 'globalisation' and not main_move_stack[-1].get('detail_cnt'): - # demote record with globalisation code from 'globalisation' to 'general' when no detail records - main_st_line_seq = main_move_stack[-1]['sequence'] - to_demote = statement['lines'][main_st_line_seq] - to_demote.update({ - 'type': 'general', - 'glob_lvl_flag': 0, - 'globalisation_amount': False, - 'amount': main_move_stack[-1]['globalisation_amount'], - }) - main_move_stack.pop() - main_move_stack.append(statementLine) - elif line[1] == '2': - if statement['lines'][-1]['ref'][0:4] != line[2:6]: - statement['error'] = True - statement['errors'].append(('R2004', _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) - continue - statement['lines'][-1]['communication'] += rmspaces(line[10:63]) - statement['lines'][-1]['payment_reference'] = rmspaces(line[63:98]) - statement['lines'][-1]['counterparty_bic'] = rmspaces(line[98:109]) - elif line[1] == '3': - if statement['lines'][-1]['ref'][0:4] != line[2:6]: - statement['error'] = True - statement['errors'].append(('R2004', _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) - continue - if statement['version'] == '1': - statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) - statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:125]) - statement['lines'][-1]['counterpartyCurrency'] = '' + elif line[1] == '1': # foreign bank account BBAN structure + raise osv.except_osv(_('Error R1001!'), _('Foreign bank accounts with BBAN structure are not supported !')) + elif line[1] == '2': # Belgian bank account IBAN structure + statement['accountNumber'] = rmspaces(line[5:21]) + statement['currency'] = rmspaces(line[39:42]) + elif line[1] == '3': # foreign bank account IBAN structure + raise osv.except_osv(_('Error R1002!'), _('Foreign bank accounts with IBAN structure are not supported !')) + else: # Something else, not supported + raise osv.except_osv(_('Error R1003!'), _('\nUnsupported bank account structure !')) + statement['description'] = rmspaces(line[90:125]) + statement['balance_start'] = float(rmspaces(line[43:58])) / 1000 + statement['balance_start_date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[58:64]), '%d%m%y')) + statement['accountHolder'] = rmspaces(line[64:90]) + statement['paperSeqNumber'] = rmspaces(line[2:5]) + statement['codaSeqNumber'] = rmspaces(line[125:128]) + elif line[0] == '2': + if line[1] == '1': + #New statement line + statementLine = {} + statementLine['type'] = 'general' + statementLine['ref'] = rmspaces(line[2:10]) + statementLine['ref_move'] = rmspaces(line[2:6]) + statementLine['ref_move_detail'] = rmspaces(line[6:10]) + statementLine['sequence'] = len(statement['lines']) + 1 + statementLine['transactionRef'] = rmspaces(line[10:31]) + statementLine['debit'] = line[31] # 0 = Credit, 1 = Debit + statementLine['amount'] = float(rmspaces(line[32:47])) / 1000 + if statementLine['debit'] == '1': + statementLine['amount'] = - statementLine['amount'] + statementLine['transaction_type'] = line[53] + if statementLine['transaction_type'] not in transaction_types: + raise osv.except_osv(_('Error R2001!'), _('The File contains an invalid CODA Transaction Type : %s!') % statementLine['transaction_type']) + statementLine['transactionDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[47:53]), '%d%m%y')) + statementLine['transaction_family'] = rmspaces(line[54:56]) + #TODO Handling severals transactions Family + statementLine['transaction_code'] = rmspaces(line[56:58]) + #TODO Handling severals transactions code + statementLine['transaction_category'] = rmspaces(line[58:61]) + #TODO Handling severals transactions category + statementLine['communication'] = rmspaces(line[62:115]) + #TODO Handling structured communication + statementLine['entryDate'] = rmspaces(line[115:121]) + statementLine['type'] = 'normal' + statementLine['globalisation'] = int(line[124]) + if len(statement['globalisation_stack']) > 0: + statementLine['communication'] = "\n".join([statement['globalisation_stack'][-1]['communication'], statementLine['communication']]) + if statementLine['globalisation'] > 0: + if len(statement['globalisation_stack']) > 0 and statement['globalisation_stack'][-1]['globalisation'] == statementLine['globalisation']: + # Destack + statement['globalisation_stack'].pop() else: - if line[22] == ' ': - statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) - statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[23:26]) - else: - statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:44]) - statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[44:47]) - statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:82]) - statement['lines'][-1]['communication'] += rmspaces(line[82:125]) + #Stack + statementLine['type'] = 'globalisation' + statement['globalisation_stack'].append(statementLine) + statement['lines'].append(statementLine) + elif line[1] == '2': + if statement['lines'][-1]['ref'][0:4] != line[2:6]: + raise osv.except_osv(_('Error R2004!'), _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + statement['lines'][-1]['communication'] += rmspaces(line[10:63]) + statement['lines'][-1]['payment_reference'] = rmspaces(line[63:98]) + statement['lines'][-1]['counterparty_bic'] = rmspaces(line[98:109]) + elif line[1] == '3': + if statement['lines'][-1]['ref'][0:4] != line[2:6]: + raise osv.except_osv(_('Error R2005!'), _('CODA parsing error on movement data record 2.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + if statement['version'] == '1': + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) + statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:125]) + statement['lines'][-1]['counterpartyCurrency'] = '' else: - # movement data record 2.x (x != 1,2,3) - statement['error'] = True - statement['errors'].append(('R2009', _('\nMovement data records of type 2.%s are not supported !') % line[1])) - elif line[0] == '3': - if line[1] == '1': - infoLine = {} - infoLine['entryDate'] = statement['lines'][-1]['entryDate'] - infoLine['type'] = 'information' - infoLine['sequence'] = len(statement['lines']) + 1 - infoLine['ref'] = rmspaces(line[2:10]) - infoLine['transactionRef'] = rmspaces(line[10:31]) - infoLine['transactionType'] = line[31] - infoLine['transactionFamily'] = rmspaces(line[32:34]) - infoLine['transactionCode'] = rmspaces(line[34:36]) - infoLine['transactioncategory'] = rmspaces(line[36:39]) - infoLine['communication'] = rmspaces(line[40:113]) - statement['lines'].append(infoLine) - elif line[1] == '2': - if statement['lines'][-1]['ref'] != rmspaces(line[2:10]): - statement['error'] = True - statement['errors'].append(('R3004', _('CODA parsing error on information data record 3.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) - continue - statement['lines'][-1]['communication'] += rmspaces(line[10:100]) - elif line[1] == '3': - if statement['lines'][-1]['ref'] != rmspaces(line[2:10]): - statement['error'] = True - statement['errors'].append(('R3005', _('CODA parsing error on information data record 3.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10])) - continue - statement['lines'][-1]['communication'] += rmspaces(line[10:100]) - elif line[0] == '4': - comm_line = {} - comm_line['type'] = 'communication' - comm_line['sequence'] = len(statement['lines']) + 1 - comm_line['ref'] = rmspaces(line[2:10]) - comm_line['communication'] = rmspaces(line[32:112]) - statement['lines'].append(comm_line) - elif line[0] == '8': - # new balance record - last_transaction = main_move_stack[-1] - if last_transaction['type'] == 'globalisation' and not last_transaction.get('detail_cnt'): - # demote record with globalisation code from 'globalisation' to 'general' when no detail records - main_st_line_seq = main_move_stack[-1]['sequence'] - to_demote = statement['lines'][main_st_line_seq] - to_demote.update({ - 'type': 'general', - 'glob_lvl_flag': 0, - 'globalisation_amount': False, - 'amount': main_move_stack[-1]['globalisation_amount'], - }) - # add closing globalisation level on previous detail record in order to correctly close - # moves that have been 'promoted' to globalisation - if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): - closeglobalise = statement['lines'][-1] - closeglobalise.update({ - 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], - }) - statement['debit'] = line[41] - statement['paperSeqNumber'] = rmspaces(line[1:4]) - statement['balance_end_real'] = float(rmspaces(line[42:57])) / 1000 - statement['balance_end_realDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[57:63]), '%d%m%y')) - if statement['debit'] == '1': # 1=Debit - statement['balance_end_real'] = - statement['balance_end_real'] - if statement['balance_end_realDate']: - period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['balance_end_realDate']), ('date_stop', '>=', statement['balance_end_realDate'])]) - else: - period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['date']), ('date_stop', '>=', statement['date'])]) - if not period_id and len(period_id) == 0: - statement['error'] = True - statement['errors'].append(('R0002', _("The CODA Statement New Balance date doesn't fall within a defined Accounting Period! Please create the Accounting Period for date %s.") % statement['balance_end_realDate'])) - continue - statement['period_id'] = period_id[0] - elif line[0] == '9': - statement['balanceMin'] = float(rmspaces(line[22:37])) / 1000 - statement['balancePlus'] = float(rmspaces(line[37:52])) / 1000 - if not statement['balance_end_real']: - statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] + if line[22] == ' ': + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) + statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[23:26]) + else: + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:44]) + statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[44:47]) + statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:82]) + statement['lines'][-1]['communication'] += rmspaces(line[82:125]) + else: + # movement data record 2.x (x != 1,2,3) + raise osv.except_osv(_('Error R2009!'), _('\nMovement data records of type 2.%s are not supported !') % line[1]) + elif line[0] == '3': + if line[1] == '1': + infoLine = {} + infoLine['entryDate'] = statement['lines'][-1]['entryDate'] + infoLine['type'] = 'information' + infoLine['sequence'] = len(statement['lines']) + 1 + infoLine['ref'] = rmspaces(line[2:10]) + infoLine['transactionRef'] = rmspaces(line[10:31]) + infoLine['transaction_type'] = line[31] + infoLine['transaction_family'] = rmspaces(line[32:34]) + infoLine['transaction_code'] = rmspaces(line[34:36]) + infoLine['transaction_category'] = rmspaces(line[36:39]) + infoLine['communication'] = rmspaces(line[40:113]) + infoLine['amount'] = 0.0 + infoLine['type'] = 'information' + statement['lines'].append(infoLine) + elif line[1] == '2': + if infoLine['ref'] != rmspaces(line[2:10]): + raise osv.except_osv(_('Error R3004!'), _('CODA parsing error on information data record 3.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + statement['lines'][-1]['communication'] += rmspaces(line[10:100]) + elif line[1] == '3': + if infoLine['ref'] != rmspaces(line[2:10]): + raise osv.except_osv(_('Error R3005!'), _('CODA parsing error on information data record 3.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + statement['lines'][-1]['communication'] += rmspaces(line[10:100]) + elif line[0] == '4': + comm_line = {} + comm_line['type'] = 'communication' + comm_line['sequence'] = len(statement['lines']) + 1 + comm_line['ref'] = rmspaces(line[2:10]) + comm_line['communication'] = rmspaces(line[32:112]) + comm_line['amount'] = 0.0 + comm_line['type'] = 'communication' + statement['lines'].append(comm_line) + elif line[0] == '8': + # new balance record + statement['debit'] = line[41] + statement['paperSeqNumber'] = rmspaces(line[1:4]) + statement['balance_end_real'] = float(rmspaces(line[42:57])) / 1000 + statement['balance_end_realDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[57:63]), '%d%m%y')) + if statement['debit'] == '1': # 1=Debit + statement['balance_end_real'] = - statement['balance_end_real'] + if statement['balance_end_realDate']: + period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['balance_end_realDate']), ('date_stop', '>=', statement['balance_end_realDate'])]) + else: + period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['date']), ('date_stop', '>=', statement['date'])]) + if not period_id and len(period_id) == 0: + raise osv.except_osv(_('Error R0002!'), _("The CODA Statement New Balance date doesn't fall within a defined Accounting Period! Please create the Accounting Period for date %s.") % statement['balance_end_realDate']) + statement['period_id'] = period_id[0] + elif line[0] == '9': + statement['balanceMin'] = float(rmspaces(line[22:37])) / 1000 + statement['balancePlus'] = float(rmspaces(line[37:52])) / 1000 + if not statement['balance_end_real']: + statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] for i, statement in enumerate(statements): - print '---STATEMENT #' + str(i) + '---' + # print '---STATEMENT #' + str(i) + '---' print statement - if not statement['error']: - data = { - 'name': '[' + statement['date'] + ']' + statement['description'], - 'date': statement['date'], - 'journal_id': 18, - 'period_id': statement['period_id'], - 'balance_start': statement['balance_start'], - 'balance_end_real': statement['balance_end_real'], - 'account_id': 1 - } - self.pool.get('account.bank.statement').create(cr, uid, data, context=context) + data = { + 'name': '[' + statement['date'] + ']' + statement['description'], + 'date': statement['date'], + 'journal_id': 18, + 'period_id': statement['period_id'], + 'balance_start': statement['balance_start'], + 'balance_end_real': statement['balance_end_real'], + 'account_id': 1 + } + statement['id'] = self.pool.get('account.bank.statement').create(cr, uid, data, context=context) + for line in statement['lines']: + if line['type'] == 'normal': + counterparty = [] + if 'counterpartyName' in line: + counterparty.append(line['counterpartyName']) + if 'counterpartyNumber' in line: + counterparty.append(line['counterpartyNumber']) + if len(counterparty) > 0: + counterparty = '[' + ' / '.join(counterparty) + ']' + else: + counterparty = '/' + if line['transaction_type'] in transaction_types: + line['transaction_type'] = transaction_types[line['transaction_type']][1] + if line['transaction_category'] in transaction_categories: + line['transaction_category'] = transaction_categories[line['transaction_category']] + if line['transaction_family'] in transaction_codes: + transaction_family = transaction_codes[line['transaction_family']] + line['transaction_family'] = transaction_family[0] + if line['transaction_code'] in transaction_family[1]: + line['transaction_code'] = transaction_family[1][line['transaction_code']] + note = [] + note.append(_('Counter Party') + ': ' + counterparty) + note.append(_('Communication') + ': ' + line['communication']) + note.append(_('Transaction type') + ': ' + line['transaction_type']) + note.append(_('Transaction family') + ': ' + line['transaction_family']) + note.append(_('Transaction code') + ': ' + line['transaction_code']) + note.append(_('Transaction category') + ': ' + line['transaction_category']) + + try: + if 'counterpartyNumber' in line and int(line['counterpartyNumber']) == 0: + line['counterpartyNumber'] = False + except: + pass + if 'counterpartyNumber' in line and line['counterpartyNumber']: + ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) + if ids and len(ids) > 0: + partner_id = self.pool.get('res.partner.bank').browse(cr, uid, ids[0],context=context).partner_id.id + else: + partner_id = None + + data = { + 'name': line['communication'], + 'note': "\n".join(note), + 'date': line['entryDate'], + 'amount': line['amount'], + # 'type': '', + 'partner_id': partner_id, + 'account_id': 1, + 'statement_id': statement['id'], + # 'analytic_account_id': '', + # 'move_ids': '', + 'ref': line['ref'], + 'sequence': line['sequence'], + } + self.pool.get('account.bank.statement.line').create(cr, uid, data, context=context) account_coda_import() +transaction_types = { + "0": ["", _("Simple amount without detailed data; e.g. : an individual credit transfer [free of charges].")], + "1": ["", _("Amount as totalised by the customer; e.g. a file regrouping payments of wages or payments made to suppliers or a file regrouping collections for which the customer is ]debited or credited with one single amount. As a matter of principle, this type is also used when no detailed data is following [type 5].")], + "5": ["1", _("Detail of 1. Standard procedure is no detailing. However, the customer may ask for detailed data to be included into his file after the overall record [type 1].")], + "2": ["", _("Amount as totalised by the bank; e.g. : the total amount of a series of credit transfers with a structured communication As a matter of principle, this type will also be used when no detailed data [type 6 or 7] is following.")], + "6": ["2", _("Detail of 2. Simple amount without detailed data. Normally, data of this kind comes after type 2. The customer may ask for a separate file containing the detailed data. In that case, one will speak of a ‘separate application’. The records in a separate application keep type 6.")], + "7": ["2", _("Detail of 2. Simple account with detailed data The records in a separate application keep type 7.")], + "9": ["7", _("Detail of 7. The records in a separate application keep type 9.")], + "3": ["", _("Simple amount with detailed data; e.g. in case of charges for cross-border credit transfers.")], + "8": ["3", _("Detail of 3.")], +} + +transaction_codes = { + "00": [_("Undefined transactions"), { + "89": _("Cancellation of a transaction"), + "87": _("Costs refunded"), + "85": _("Correction"), + "83": _("Value correction"), + "39": _("Cancellation of a transaction"), + "37": _("Costs"), + "35": _("Correction"), + "33": _("Value correction"), + "00": _("Undefined transaction") + }], + "01": [_("Domestic or local SEPA credit transfers"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "66": _("Financial centralization"), + "64": _("Transfer to your account"), + "62": _("Unpaid postal order"), + "60": _("Non-presented circular cheque"), + "54": _("Unexecutable transfer order"), + "52": _("Payment in your favour"), + "51": _("Transfer in your favour – initiated by the bank"), + "50": _("Transfer in your favour"), + "49": _("Cancellation or correction"), + "39": _("Your issue circular cheque"), + "37": _("Costs"), + "17": _("Financial centralisation"), + "15": _("Balance due insurance premium"), + "13": _("Transfer from your account"), + "11": _("Your semi-standing order – payment to employees"), + "09": _("Your semi-standing order"), + "07": _("Collective transfer"), + "05": _("Payment of wages etc."), + "03": _("Standing order"), + "02": _("Individual transfer order initiated by the bank"), + "01": _("Individual transfer order]"), + }], + "03": [_("Cheques"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of cheque-related costs"), + "68": _("Credit of a payment via electronic purse"), + "66": _("Remittance of cheque by your branch - credit under usual reserve"), + "64": _("Reversal of settlement of credit card"), + "63": _("Second credit of unpaid cheque"), + "62": _("Reversal of cheque"), + "60": _("Reversal of voucher"), + "58": _("Remittance of cheques, vouchers, etc. credit after collection"), + "56": _("Non-presented certified cheques"), + "52": _("First credit of cheques, vouchers, luncheon vouchers, postal orders, credit under usual reserve"), + "50": _("Credit of a payment via terminal"), + "49": _("Cancellation or correction"), + "39": _("Provisionally unpaid due to other reason than manual presentation"), + "38": _("Provisionally unpaid"), + "37": _("Cheque-related costs"), + "35": _("Cash advance"), + "19": _("Settlement of credit cards"), + "17": _("Your certified cheque"), + "15": _("Your purchase bank cheque"), + "13": _("Eurocheque written out abroad"), + "11": _("Department store cheque"), + "09": _("Unpaid voucher"), + "07": _("Definitely unpaid cheque"), + "05": _("Payment of voucher"), + "03": _("Your purchase by payment card"), + "01": _("Payment of your cheque"), + }], + "04": [_("Cards"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "68": _("Credit after Proton payments"), + "55": _("Income from payments by GSM"), + "53": _("Cash deposit at an ATM"), + "52": _("Loading GSM cards"), + "51": _("Unloading Proton"), + "50": _("Credit after a payment at a terminal"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "08": _("Payment by means of a payment card outside the Eurozone"), + "07": _("Payment by GSM"), + "06": _("Payment with tank card"), + "05": _("Loading Proton"), + "04": _("Cash withdrawal from an ATM"), + "03": _("Settlement credit cards"), + "02": _("Payment by means of a payment card within the Eurozone"), + "01": _("Loading a GSM card"), + }], + "05": [_("Direct debit"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "58": _("Reversal"), + "56": _("Unexecutable reimbursement"), + "54": _("Reimbursement"), + "52": _("Credit under usual reserve"), + "50": _("Credit after collection"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "05": _("Reimbursement"), + "03": _("Unpaid debt"), + "01": _("Payment"), + }], + "07": [_("Domestic commercial paper"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "86": _("Payment after cession"), + "64": _("Warrant"), + "58": _("Remittance of supplier's bill without guarantee"), + "56": _("Remittance of supplier's bill with guarantee"), + "54": _("Remittance of commercial paper for discount"), + "52": _("Remittance of commercial paper - credit under usual reserve"), + "50": _("Remittance of commercial paper - credit after collection"), + "49": _("Cancellation or correction"), + "39": _("Return of an irregular bill of exchange"), + "37": _("Costs related to commercial paper"), + "14": _("Warrant fallen due"), + "12": _("Safe custody"), + "10": _("Renewal of agreed maturity date"), + "09": _("Agio on supplier's bill"), + "08": _("Payment in advance"), + "07": _("Unpaid commercial paper"), + "06": _("Extension of maturity date"), + "05": _("Commercial paper claimed back"), + "03": _("Payment receipt card"), + "01": _("Payment commercial paper"), + }], + "09": [_("Counter transactions"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Sale of traveller’s cheque"), + "68": _("Difference in payment"), + "66": _("Repurchase of petrol coupons"), + "64": _("Your winning lottery ticket"), + "62": _("Sale of gold/pieces under usual reserve"), + "60": _("Sale of foreign bank notes"), + "58": _("Payment by your branch/agents"), + "56": _("Reserve"), + "54": _("Your payment ATM"), + "52": _("Payment night safe"), + "50": _("Cash payment"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "25": _("Purchase of traveller’s cheque"), + "21": _("Cash withdrawal on card (PROTON)"), + "19": _("Difference in payment"), + "17": _("Purchase of fiscal stamps"), + "15": _("Your purchase of lottery tickets"), + "13": _("Cash withdrawal by your branch or agents"), + "11": _("Your purchase of luncheon vouchers"), + "09": _("Purchase of petrol coupons"), + "07": _("Purchase of gold/pieces"), + "05": _("Purchase of foreign bank notes"), + "03": _("Cash withdrawal by card (ATM)"), + "01": _("Cash withdrawal"), + }], + "11": [_("Securities"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Settlement of securities"), + "68": _("Compensation for missing coupon"), + "66": _("Retrocession of issue commission"), + "64": _("Your issue"), + "62": _("Interim interest on subscription"), + "58": _("Repayable securities from a deposit or delivered at the counter - credit under usual reserve"), + "56": _("Reserve"), + "52": _("Payment of coupons from a deposit or settlement of coupons delivered over the counter - credit under usual reserve"), + "51": _("Tender"), + "50": _("Sale of securities"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "19": _("Regularisation costs"), + "17": _("Management fee"), + "15": _("Interim interest on subscription"), + "13": _("Your repurchase of issue"), + "11": _("Payable coupons/repayable securities"), + "09": _("Settlement of securities"), + "06": _("Share option plan – exercising an option"), + "05": _("Partial payment subscription"), + "04": _("Issues"), + "03": _("Subscription to securities"), + "02": _("Tenders"), + "01": _("Purchase of securities"), + }], + "13": [_("Credit"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Settlement of discount bank acceptance"), + "68": _("Documentary export credits"), + "62": _("Term loan"), + "60": _("Settlement of mortgage loan"), + "56": _("Subsidy"), + "55": _("Fixed advance – interest only"), + "54": _("Fixed advance – capital and interest"), + "50": _("Settlement of instalment credit"), + "49": _("Cancellation or correction"), + "37": _("Credit-related costs"), + "21": _("Other credit applications"), + "19": _("Documentary import credits"), + "15": _("Your repayment hire-purchase and similar claims"), + "13": _("Settlement of bank acceptances"), + "11": _("Your repayment mortgage loan"), + "07": _("Your repayment instalment credits"), + "05": _("Settlement of fixed advance"), + "02": _("Long-term loan"), + "01": _("Short-term loan"), + }], + "30": [_("Various transactions"), { + "99": _("Cancellation or correction"), + "89": _("Undefined transaction"), + "87": _("Reimbursement of costs"), + "83": _("Value (date) correction"), + "55": _("Interest term investment"), + "54": _("Capital and/or interest term investment"), + "52": _("Forward sale of foreign exchange"), + "50": _("Spot sale of foreign exchange"), + "49": _("Cancellation or correction"), + "39": _("Undefined transaction"), + "37": _("Costs"), + "33": _("Value (date) correction"), + "05": _("Capital and/or interest term investment"), + "03": _("Forward purchase of foreign exchange"), + "01": _("Spot purchase of foreign exchange"), + }], + "35": [_("Closing (periodical settlements for interest, costs,…)"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "50": _("Closing"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "01": _("Closing"), + }], + "41": [_("International credit transfers - non-SEPA credit transfers"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "66": _("Financial centralisation (credit)"), + "64": _("Transfer to your account"), + "50": _("Transfer"), + "49": _("Cancellation or correction"), + "38": _("Costs relating to incoming foreign and non-SEPA transfers"), + "37": _("Costs relating to outgoing foreign transfers and non-SEPA transfers"), + "17": _("Financial centralisation (debit)"), + "13": _("Transfer from your account"), + "07": _("Collective transfers"), + "05": _("Collective payments of wages"), + "03": _("Standing order"), + "01": _("Transfer"), + }], + "43": [_("Foreign cheques"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Purchase of traveller’s cheque"), + "62": _("Reversal of cheques"), + "58": _("Remittance of foreign cheque credit after collection"), + "52": _("Remittance of foreign cheque credit under usual reserve"), + "49": _("Cancellation or correction"), + "37": _("Costs relating to payment of foreign cheques"), + "15": _("Purchase of an international bank cheque"), + "07": _("Unpaid foreign cheque"), + "01": _("Payment of a foreign cheque"), + }], + "47": [_("Foreign commercial paper"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "64": _("Warrant"), + "62": _("Remittance of documents abroad - credit after collection"), + "60": _("Remittance of documents abroad - credit under usual reserve"), + "58": _("Idem without guarantee"), + "56": _("Remittance of guaranteed foreign supplier's bill"), + "54": _("Discount abroad"), + "52": _("Remittance of foreign bill credit under usual reserve"), + "50": _("Remittance of foreign bill credit after collection"), + "49": _("Cancellation or correction"), + "37": _("Costs relating to the payment of a foreign bill"), + "14": _("Warrant fallen due"), + "13": _("Discount foreign supplier's bills"), + "11": _("Payment documents abroad"), + "07": _("Unpaid foreign bill"), + "06": _("Extension"), + "05": _("Bill claimed back"), + "01": _("Payment of foreign bill"), + }], + "49": [_("Foreign counter transactions"), {"03": _("ATM withdrawal")}], + "80": [_("Separately charged costs and provisions"), { + "01": _("Guarantee card charges"), + "02": _("Costs relating to electronic output"), + "03": _("Payment card charges"), + "04": _("Costs for holding a documentary cash credit"), + "05": _("Card charges"), + "06": _("Damage relating to bills and cheques"), + "07": _("Insurance costs"), + "08": _("Registering compensation for savings accounts"), + "09": _("Postage"), + "10": _("Purchase of Smartcard"), + "11": _("Costs for the safe custody of correspondence"), + "12": _("Costs for opening a bank guarantee"), + "13": _("Renting of safes"), + "14": _("Handling costs instalment credit"), + "15": _("Night safe"), + "16": _("Bank confirmation to revisor or accountant"), + "17": _("Charge for safe custody"), + "18": _("Trade information"), + "19": _("Special charge for safe custody"), + "20": _("Drawing up a certificate"), + "21": _("Pay-packet charges"), + "22": _("Management/custody"), + "23": _("Research costs"), + "24": _("Participation in and management of interest refund system"), + "25": _("Renting of direct debit box"), + "26": _("Travel insurance premium"), + "27": _("Subscription fee"), + "29": _("Information charges"), + "31": _("Writ service fee"), + "33": _("Miscellaneous fees and commissions"), + "35": _("Costs"), + "37": _("Access right to database"), + "39": _("Surety fee"), + "41": _("Research costs"), + "43": _("Printing of forms"), + "45": _("Documentary credit charges"), + "47": _("Charging fees for transactions"), + "49": _("Cancellation or correction"), + "99": _("Cancellation or correction"), + }], +} + +transaction_categories = { + "000": _("Net amount"), + "001": _("Interest received"), + "002": _("Interest paid"), + "003": _("Credit commission"), + "004": _("Postage"), + "005": _("Renting of letterbox"), + "006": _("Various fees/commissions"), + "007": _("Access right to database"), + "008": _("Information charges"), + "009": _("Travelling expenses"), + "010": _("Writ service fee"), + "011": _("VAT"), + "012": _("Exchange commission"), + "013": _("Payment commission"), + "014": _("Collection commission"), + "015": _("Correspondent charges"), + "016": _("BLIW/IBLC dues"), + "017": _("Research costs"), + "018": _("Tental guarantee charges"), + "019": _("Tax on physical delivery"), + "020": _("Costs of physical delivery"), + "021": _("Costs for drawing up a bank cheque"), + "022": _("Priority costs"), + "023": _("Exercising fee"), + "024": _("Growth premium"), + "025": _("Individual entry for exchange charges"), + "026": _("Handling commission"), + "027": _("Charges for unpaid bills"), + "028": _("Fidelity premium"), + "029": _("Protest charges"), + "030": _("Account insurance"), + "031": _("Charges foreign cheque"), + "032": _("Drawing up a circular cheque"), + "033": _("Charges for a foreign bill"), + "034": _("Reinvestment fee"), + "035": _("Charges foreign documentary bill"), + "036": _("Costs relating to a refused cheque"), + "037": _("Commission for handling charges"), + "039": _("Telecommunications"), + "041": _("Credit card costs"), + "042": _("Payment card costs"), + "043": _("Insurance costs"), + "045": _("Handling costs"), + "047": _("Charges extension bill"), + "049": _("Fiscal stamps/stamp duty"), + "050": _("Capital term investment"), + "051": _("Withholding tax"), + "052": _("Residence state tax"), + "053": _("Printing of forms"), + "055": _("Repayment loan or credit capital"), + "057": _("Interest subsidy"), + "058": _("Capital premium"), + "059": _("Default interest"), + "061": _("Charging fees for transactions"), + "063": _("Rounding differences"), + "065": _("Interest payment advice"), + "066": _("Fixed loan advance - reimbursement"), + "067": _("Fixed loan advance - extension"), + "068": _("Countervalue of an entry"), + "069": _("Forward arbitrage contracts : sum to be supplied by customer"), + "070": _("Forward arbitrage contracts : sum to be supplied by bank"), + "071": _("Fixed loan advance - availability"), + "072": _("Countervalue of commission to third party"), + "073": _("Costs of ATM abroad"), + "074": _("Mailing costs"), + "100": _("Gross amount"), + "200": _("Overall documentary credit charges"), + "201": _("Advice notice commission"), + "202": _("Advising commission | Additional advising commission"), + "203": _("Confirmation fee | Additional confirmation fee | Commitment fee | Flat fee | Confirmation reservation commission | Additional reservation commission"), + "204": _("Amendment fee"), + "205": _("Documentary payment commission | Document commission | Drawdown fee | Negotiation fee"), + "206": _("Surety fee/payment under reserve"), + "207": _("Non-conformity fee"), + "208": _("Commitment fee deferred payment"), + "209": _("Transfer commission"), + "210": _("Commitment fee"), + "211": _("Credit arrangement fee | Additional credit arrangement fee"), + "212": _("Warehousing fee"), + "213": _("Financing fee"), + "214": _("Issue commission (delivery order)"), + "400": _("Acceptance fee"), + "401": _("Visa charges"), + "402": _("Certification costs"), + "403": _("Minimum discount rate"), + "404": _("Discount commission"), + "405": _("Bill guarantee commission"), + "406": _("Collection charges"), + "407": _("Costs Article 45"), + "408": _("Cover commission"), + "409": _("Safe deposit charges"), + "410": _("Reclamation charges"), + "411": _("Fixed collection charge"), + "412": _("Advice of expiry charges"), + "413": _("Acceptance charges"), + "414": _("Regularisation charges"), + "415": _("Surety fee"), + "416": _("Charges for the deposit of security"), + "418": _("Endorsement commission"), + "419": _("Bank service fee"), + "420": _("Retention charges"), + "425": _("Foreign broker's commission"), + "426": _("Belgian broker's commission"), + "427": _("Belgian Stock Exchange tax"), + "428": _("Interest accrued"), + "429": _("Foreign Stock Exchange tax"), + "430": _("Recovery of foreign tax"), + "431": _("Delivery of a copy"), +} + def rmspaces(s): return " ".join(s.split()) + + # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: From 4333defecd2f1b780cc72449084dd2e8de3caf0b Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Wed, 5 Dec 2012 18:38:01 +0100 Subject: [PATCH 09/41] [DEL]All old object and views which are now useless bzr revid: dle@openerp.com-20121205173801-9abvk3u03mxvwp91 --- addons/l10n_be_coda/__init__.py | 1 - addons/l10n_be_coda/__openerp__.py | 6 - addons/l10n_be_coda/l10n_be_coda.py | 499 ---- .../l10n_be_coda/l10n_be_coda_comm_type.xml | 140 - .../l10n_be_coda_trans_category.xml | 440 --- .../l10n_be_coda/l10n_be_coda_trans_code.xml | 1914 ------------- .../l10n_be_coda/l10n_be_coda_trans_type.xml | 49 - addons/l10n_be_coda/l10n_be_coda_view.xml | 549 +--- addons/l10n_be_coda/l10n_be_coda_wizard.xml | 14 - addons/l10n_be_coda/res_bank.py | 34 - addons/l10n_be_coda/res_bank_view.xml | 31 - .../security/account_security.xml | 11 - .../l10n_be_coda/security/ir.model.access.csv | 17 - addons/l10n_be_coda/wizard/__init__.py | 2 +- .../wizard/account_coda_import.py | 2481 +++++------------ .../wizard/account_coda_import_dle.py | 740 ----- 16 files changed, 652 insertions(+), 6276 deletions(-) delete mode 100644 addons/l10n_be_coda/l10n_be_coda.py delete mode 100644 addons/l10n_be_coda/l10n_be_coda_comm_type.xml delete mode 100644 addons/l10n_be_coda/l10n_be_coda_trans_category.xml delete mode 100644 addons/l10n_be_coda/l10n_be_coda_trans_code.xml delete mode 100644 addons/l10n_be_coda/l10n_be_coda_trans_type.xml delete mode 100755 addons/l10n_be_coda/res_bank.py delete mode 100755 addons/l10n_be_coda/res_bank_view.xml delete mode 100644 addons/l10n_be_coda/security/account_security.xml delete mode 100644 addons/l10n_be_coda/security/ir.model.access.csv delete mode 100644 addons/l10n_be_coda/wizard/account_coda_import_dle.py diff --git a/addons/l10n_be_coda/__init__.py b/addons/l10n_be_coda/__init__.py index 4a58b8ad059..c737eb79536 100644 --- a/addons/l10n_be_coda/__init__.py +++ b/addons/l10n_be_coda/__init__.py @@ -20,7 +20,6 @@ # ############################################################################## -import l10n_be_coda import wizard # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/__openerp__.py b/addons/l10n_be_coda/__openerp__.py index 2c8931f484c..14e1bf6e443 100644 --- a/addons/l10n_be_coda/__openerp__.py +++ b/addons/l10n_be_coda/__openerp__.py @@ -93,12 +93,6 @@ If required, you can manually adjust the descriptions via the CODA configuration 'depends': ['account_voucher','base_iban', 'l10n_be_invoice_bba', 'account_bank_statement_extensions'], 'demo': [], 'data': [ - 'l10n_be_coda_trans_type.xml', - 'l10n_be_coda_trans_code.xml', - 'l10n_be_coda_trans_category.xml', - 'l10n_be_coda_comm_type.xml', - 'security/ir.model.access.csv', - 'security/account_security.xml', 'l10n_be_coda_wizard.xml', 'l10n_be_coda_view.xml', ], diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py deleted file mode 100644 index cc11c72cf06..00000000000 --- a/addons/l10n_be_coda/l10n_be_coda.py +++ /dev/null @@ -1,499 +0,0 @@ -# -*- encoding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## - -from osv import osv, fields -import decimal_precision as dp -from tools.translate import _ -import logging -_logger = logging.getLogger(__name__) - - -class coda_bank_account(osv.osv): - _name = 'coda.bank.account' - _description = 'CODA Bank Account Configuration' - - def _check_account_pain(self, cr, uid, context=None): - res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_pain'), ('state', '=', 'installed')]) - return res and True or False - - def _check_currency(self, cr, uid, ids, context=None): - obj_cba = self.browse(cr, uid, ids[0], context=context) - if (obj_cba.state == 'normal') and obj_cba.journal: - if obj_cba.journal.currency and (obj_cba.currency != obj_cba.journal.currency): - return False - if not obj_cba.journal.currency and (obj_cba.currency != obj_cba.company_id.currency_id): - return False - return True - - _columns = { - 'name': fields.char('Name', size=64, required=True), - 'bank_id': fields.many2one('res.partner.bank', 'Bank Account', required=True, - help='Bank Account Number.\nThe CODA import function will find its CODA processing parameters on this number.'), - 'description1': fields.char('Primary Account Description', size=35, - help='The Primary or Secondary Account Description should match the corresponding Account Description in the CODA file.'), - 'description2': fields.char('Secondary Account Description', size=35, - help='The Primary or Secondary Account Description should match the corresponding Account Description in the CODA file.'), - 'state': fields.selection([ - ('normal', 'Normal'), - ('info', 'Info')], - 'Type', required=True, select=1, - help='No Bank Statements will be generated for CODA Bank Statements from Bank Accounts of type \'Info\'.'), - 'journal': fields.many2one('account.journal', 'Journal', - domain=[('type', '=', 'bank')], - states={'normal': [('required', True)], 'info': [('required', False)]}, - help='Bank Journal for the Bank Statement'), - 'currency': fields.many2one('res.currency', 'Currency', required=True, - help='The currency of the CODA Bank Statement'), - 'coda_st_naming': fields.char('Bank Statement Naming Policy', size=64, - help="Define the rules to create the name of the Bank Statements generated by the CODA processing." \ - "\nE.g. %(code)s%(y)s/%(paper)s" \ - "\n\nVariables:" \ - "\nBank Journal Code: %(code)s" \ - "\nYear (of CODA 'New Balance Date') with Century: %(year)s" \ - "\nYear (of CODA 'New Balance Date') without Century: %(y)s" \ - "\nCODA sequence number: %(coda)s" \ - "\nPaper Statement sequence number (as specified on 'Old Balance' record): %(paper_ob)s" \ - "\nPaper Statement sequence number (as specified on 'New Balance' record): %(paper)s"), - 'awaiting_account': fields.many2one('account.account', 'Default Account for Unrecognized Movement', domain=[('type', '!=', 'view')], required=True, - help='Set here the default account that will be used if the partner cannot be unambiguously identified.'), - 'transfer_account': fields.many2one('account.account', 'Default Internal Transfer Account', domain=[('code', 'like', '58%'), ('type', '!=', 'view')], required=True, - help='Set here the default account that will be used for internal transfer between own bank accounts (e.g. transfer between current and deposit bank accounts).'), - 'account_mapping_ids': fields.one2many('coda.account.mapping.rule', 'coda_bank_account_id', 'Account Mapping Rules'), - 'find_payment': fields.boolean('Lookup Payment Reference', - help='Invoice lookup and reconciliation via the SEPA EndToEndReference.' \ - '\nInstall the \'account_pain\' module if you want to take advantage of this feature.'), - 'find_bbacom': fields.boolean('Lookup Structured Communication of type \'BBA\'', - help='Partner lookup and reconciliation via the \'BBA\' Structured Communication.' \ - '\nA partial reconciliation will be created when there is no exact match between the Invoice and Bank Transaction amounts.'), - 'find_inv_number': fields.boolean('Lookup Invoice Number', - help='Partner lookup and reconciliation via the Invoice Number when a communication in free format is used.' \ - '\nA reconciliation will only be created in case of exact match between the Invoice and Bank Transaction amounts.'), - 'find_partner': fields.boolean('Lookup Partner', - help='Partner lookup via Bank Account Number in order to facilitate the reconciliation.'), - 'update_partner': fields.boolean('Update Partner Bank Accounts', - help='Update Partner record when the Counterparty\'s Bank Account has not been registered yet.'), - 'balance_start_enforce': fields.boolean('Prevent invalid Opening Balances', - help="Do not process Statements with an Opening Balance that doesn't match the previous Closing Balance."), - 'discard_dup': fields.boolean('Discard Duplicates', - help="Duplicate Bank Statements will be discarded. Select the corresponding 'CODA Bank Statement' in order to view the contents of such duplicates."), - 'active': fields.boolean('Active', help='If the active field is set to False, it will allow you to hide the Bank Account without removing it.'), - 'company_id': fields.many2one('res.company', 'Company', required=True), - } - _defaults = { - 'currency': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, - 'state': 'normal', - 'coda_st_naming': '%(code)s/%(y)s/%(coda)s', - 'active': True, - 'find_payment': _check_account_pain, - 'find_bbacom': True, - 'find_inv_number': True, - 'find_partner': True, - 'update_partner': True, - 'balance_start_enforce': True, - 'company_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id, - } - _sql_constraints = [ - ('account_uniq_1', 'unique (bank_id, description1, currency)', 'The combination of Bank Account, Account Description and Currency must be unique !'), - ('account_uniq_2', 'unique (bank_id, description2, currency)', 'The combination of Bank Account, Account Description and Currency must be unique !'), - ] - _constraints = [ - (_check_currency, '\n\nConfiguration Error! \nThe Bank Account Currency should match the Journal Currency !', ['currency', 'journal']), - ] - _order = 'name' - - def name_get(self, cr, uid, ids, context=None): - res = [] - if not len(ids): - return res - for id in self.browse(cr, uid, ids, context=context): - res.append((id.id, (id.bank_id.iban or id.bank_id.acc_number) + ' (' + id.currency.name + ')' + \ - (id.description1 and (' - ' + id.description1) or ''))) - return res - - def copy(self, cr, uid, id, default=None, context=None): - cba = self.browse(cr, uid, id, context=context) - if not default: - default = {} - default = default.copy() - default.update({'journal_id': None}) - default['description1'] = cba['description1'] or '' - default['description2'] = cba['description2'] or '' - default['name'] = (cba['name'] or '') + ' (copy)' - default['state'] = cba['state'] - return super(coda_bank_account, self).copy(cr, uid, id, default, context) - - def onchange_state(self, cr, uid, ids, state): - return state == 'info' and {'value': {'journal': None}} or {} - -coda_bank_account() - - -class account_coda(osv.osv): - _name = 'account.coda' - _description = 'Object to store CODA Data Files' - _order = 'coda_creation_date desc' - _columns = { - 'name': fields.char('CODA Filename', size=128, readonly=True), - 'coda_data': fields.binary('CODA File', readonly=True), - 'statement_ids': fields.one2many('coda.bank.statement', 'coda_id', 'Generated CODA Bank Statements', readonly=True), - 'note': fields.text('Import Log', readonly=True), - 'coda_creation_date': fields.date('CODA Creation Date', readonly=True, select=True), - 'date': fields.date('Import Date', readonly=True, select=True), - 'user_id': fields.many2one('res.users', 'User', readonly=True, select=True), - 'company_id': fields.many2one('res.company', 'Company', readonly=True) - } - _defaults = { - 'date': fields.date.context_today, - 'user_id': lambda self, cr, uid, context: uid, - 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'account.coda', context=c), - } - _sql_constraints = [ - ('coda_uniq', 'unique (name, coda_creation_date)', 'This CODA has already been imported !') - ] - - def unlink(self, cr, uid, ids, context=None): - if context is None: - context = {} - context.update({'coda_unlink': True}) - coda_st_obj = self.pool.get('coda.bank.statement') - bank_st_obj = self.pool.get('account.bank.statement') - for coda in self.browse(cr, uid, ids, context=context): - for coda_statement in coda.statement_ids: - if not context.get('coda_statement_unlink', False): - if coda_st_obj.exists(cr, uid, coda_statement.id, context=context): - coda_st_obj.unlink(cr, uid, [coda_statement.id], context=context) - if not context.get('bank_statement_unlink', False): - if coda_st_obj.exists(cr, uid, coda_statement.id, context=context) and (coda_statement.type == 'normal') and bank_st_obj.exists(cr, uid, coda_statement.statement_id.id, context=context): - bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) - context.update({'coda_unlink': False}) - return super(account_coda, self).unlink(cr, uid, ids, context=context) - -account_coda() - - -class account_coda_trans_type(osv.osv): - _name = 'account.coda.trans.type' - _description = 'CODA transaction type' - _rec_name = 'type' - _columns = { - 'type': fields.char('Transaction Type', size=1, required=True), - 'parent_id': fields.many2one('account.coda.trans.type', 'Parent'), - 'description': fields.text('Description', translate=True), - } -account_coda_trans_type() - - -class account_coda_trans_code(osv.osv): - _name = 'account.coda.trans.code' - _description = 'CODA transaction code' - _rec_name = 'code' - _columns = { - 'code': fields.char('Code', size=2, required=True, select=1), - 'type': fields.selection([ - ('code', 'Transaction Code'), - ('family', 'Transaction Family')], - 'Type', required=True, select=1), - 'parent_id': fields.many2one('account.coda.trans.code', 'Family', select=1), - 'description': fields.char('Description', size=128, translate=True, select=2), - 'comment': fields.text('Comment', translate=True), - } -account_coda_trans_code() - - -class account_coda_trans_category(osv.osv): - _name = 'account.coda.trans.category' - _description = 'CODA transaction category' - _rec_name = 'category' - _columns = { - 'category': fields.char('Transaction Category', size=3, required=True), - 'description': fields.char('Description', size=256, translate=True), - } -account_coda_trans_category() - - -class account_coda_comm_type(osv.osv): - _name = 'account.coda.comm.type' - _description = 'CODA structured communication type' - _rec_name = 'code' - _columns = { - 'code': fields.char('Structured Communication Type', size=3, required=True, select=1), - 'description': fields.char('Description', size=128, translate=True), - } - _sql_constraints = [ - ('code_uniq', 'unique (code)', 'The Structured Communication Code must be unique !') - ] -account_coda_comm_type() - - -class coda_bank_statement(osv.osv): - _name = 'coda.bank.statement' - _description = 'CODA Bank Statement' - - def _default_journal_id(self, cr, uid, context={}): - if context.get('journal_id', False): - return context['journal_id'] - return False - - def _end_balance(self, cursor, user, ids, name, attr, context=None): - res = {} - statements = self.browse(cursor, user, ids, context=context) - for statement in statements: - res[statement.id] = statement.balance_start - for line in statement.line_ids: - res[statement.id] += line.amount - for r in res: - res[r] = round(res[r], 2) - return res - - def _get_period(self, cr, uid, context={}): - periods = self.pool.get('account.period').find(cr, uid) - if periods: - return periods[0] - else: - return False - - _order = 'date desc' - _columns = { - 'name': fields.char('Name', size=64, required=True, readonly=True), - 'date': fields.date('Date', required=True, readonly=True), - 'coda_creation_date': fields.date('CODA Creation Date', readonly=True), - 'old_balance_date': fields.date('Old Balance Date', readonly=True), - 'new_balance_date': fields.date('New Balance Date', readonly=True), - 'coda_id': fields.many2one('account.coda', 'CODA Data File', ondelete='cascade'), - 'type': fields.selection([ - ('normal', 'Normal'), - ('info', 'Info')], - 'Type', required=True, readonly=True, - help='No Bank Statements are associated with CODA Bank Statements of type \'Info\'.'), - 'statement_id': fields.many2one('account.bank.statement', 'Associated Bank Statement'), - 'journal_id': fields.many2one('account.journal', 'Journal', readonly=True, domain=[('type', '=', 'bank')]), - 'coda_bank_account_id': fields.many2one('coda.bank.account', 'Bank Account', readonly=True), - 'period_id': fields.many2one('account.period', 'Period', required=True, readonly=True), - 'balance_start': fields.float('Starting Balance', digits_compute=dp.get_precision('Account'), readonly=True), - 'balance_end_real': fields.float('Ending Balance', digits_compute=dp.get_precision('Account'), readonly=True), - 'balance_end': fields.function(_end_balance, method=True, store=True, string='Balance'), - 'line_ids': fields.one2many('coda.bank.statement.line', - 'statement_id', 'CODA Bank Statement lines', readonly=True), - 'currency': fields.many2one('res.currency', 'Currency', required=True, readonly=True, - help='The currency of the CODA Bank Statement'), - 'company_id': fields.related('journal_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), - } - _defaults = { - 'type': 'normal', - 'currency': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.currency_id.id, - 'journal_id': _default_journal_id, - 'period_id': _get_period, - } - - def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False): - if context is None: - context = {} - res = super(coda_bank_statement, self).search(cr, uid, args=args, offset=offset, limit=limit, order=order, - context=context, count=count) - if context.get('bank_statement', False) and not res: - raise osv.except_osv('Warning', _('No CODA Bank Statement found for this Bank Statement!')) - return res - - def unlink(self, cr, uid, ids, context=None): - if context is None: - context = {} - context.update({'coda_statement_unlink': True}) - coda_obj = self.pool.get('account.coda') - bank_st_obj = self.pool.get('account.bank.statement') - - # find all CODA bank statements that are associated with the selected CODA bank statements via a common CODA file - new_ids = [] - for coda_statement in self.browse(cr, uid, ids, context=context): - if coda_obj.exists(cr, uid, coda_statement.coda_id.id, context=context): - new_ids += [x.id for x in coda_obj.browse(cr, uid, coda_statement.coda_id.id, context=context).statement_ids] - - # unlink CODA banks statements as well as associated bank statements and CODA files - for coda_statement in self.browse(cr, uid, new_ids, context=context): - if coda_statement.statement_id.state == 'confirm': - raise osv.except_osv(_('Invalid action !'), - _("Cannot delete CODA Bank Statement '%s' of Journal '%s'." \ - "\nThe associated Bank Statement has already been confirmed !" \ - "\nPlease undo this action first!") \ - % (coda_statement.name, coda_statement.journal_id.name)) - else: - if not context.get('coda_unlink', False): - if coda_statement.coda_id and coda_obj.exists(cr, uid, coda_statement.coda_id.id, context=context): - coda_obj.unlink(cr, uid, [coda_statement.coda_id.id], context=context) - if not context.get('bank_statement_unlink', False): - if coda_statement.statement_id and bank_st_obj.exists(cr, uid, coda_statement.statement_id.id, context=context): - bank_st_obj.unlink(cr, uid, [coda_statement.statement_id.id], context=context) - - context.update({'coda_statement_unlink': False}) - return super(coda_bank_statement, self).unlink(cr, uid, new_ids, context=context) - -coda_bank_statement() - - -class account_bank_statement(osv.osv): - _inherit = 'account.bank.statement' - _columns = { - 'coda_statement_id': fields.many2one('coda.bank.statement', 'Associated CODA Bank Statement'), - } - # _sql_constraints = [ - # ('name_company_uniq', 'unique (name,company_id)', 'The name of the Bank Statement must be unique per company !') - # ] - - def unlink(self, cr, uid, ids, context=None): - if context is None: - context = {} - context.update({'bank_statement_unlink': True}) - coda_obj = self.pool.get('account.coda') - coda_st_obj = self.pool.get('coda.bank.statement') - - # find all statements that are associated with the selected bank statements via a common CODA file - ids_plus = [] - for statement in self.browse(cr, uid, ids, context=context): - if statement.coda_statement_id: - for x in coda_obj.browse(cr, uid, statement.coda_statement_id.coda_id.id, context=context).statement_ids: - if x.type == 'normal': - ids_plus += [x.statement_id.id] - - # unlink banks statements as well as associated CODA bank statements and CODA files - for statement in self.browse(cr, uid, ids_plus, context=context): - if not context.get('coda_statement_unlink', False): - if statement.coda_statement_id and coda_st_obj.exists(cr, uid, statement.coda_statement_id.id, context=context): - coda_st_obj.unlink(cr, uid, [statement.coda_statement_id.id], context=context) - if not context.get('coda_unlink', False): - if statement.coda_statement_id \ - and coda_st_obj.exists(cr, uid, statement.coda_statement_id.id, context=context) \ - and statement.coda_statement_id.coda_id \ - and coda_obj.exists(cr, uid, statement.coda_statement_id.coda_id.id, context=context): - coda_obj.unlink(cr, uid, [statement.coda_statement_id.coda_id.id], context=context) - - context.update({'bank_statement_unlink': False}) - new_ids = list(set(ids + ids_plus)) - return super(account_bank_statement, self).unlink(cr, uid, new_ids, context=context) - -account_bank_statement() - - -class coda_bank_statement_line(osv.osv): - _name = 'coda.bank.statement.line' - _order = 'sequence' - _description = 'CODA Bank Statement Line' - _columns = { - 'name': fields.char('Communication', size=268, required=True), - 'sequence': fields.integer('Sequence'), - 'date': fields.date('Entry Date', required=True), - 'val_date': fields.date('Valuta Date'), - 'account_id': fields.many2one('account.account', 'Account'), - 'type': fields.selection([ - ('supplier', 'Supplier'), - ('customer', 'Customer'), - ('general', 'General'), - ('globalisation', 'Globalisation'), - ('information', 'Information'), - ('communication', 'Free Communication'), - ], 'Type', required=True), - 'globalisation_level': fields.integer('Globalisation Level', - help="The value which is mentioned (1 to 9), specifies the hierarchy level" - " of the globalisation of which this record is the first." - "\nThe same code will be repeated at the end of the globalisation."), - 'globalisation_amount': fields.float('Globalisation Amount', digits_compute=dp.get_precision('Account')), - 'globalisation_id': fields.many2one('account.bank.statement.line.global', 'Globalisation ID', readonly=True, - help="Code to identify transactions belonging to the same globalisation level within a batch payment"), - 'amount': fields.float('Amount', digits_compute=dp.get_precision('Account')), - 'partner_id': fields.many2one('res.partner', 'Partner'), - 'counterparty_name': fields.char('Counterparty Name', size=35), - 'counterparty_bic': fields.char('Counterparty BIC', size=11), - 'counterparty_number': fields.char('Counterparty Number', size=34), - 'counterparty_currency': fields.char('Counterparty Currency', size=3), - 'payment_reference': fields.char('Payment Reference', size=35, - help="Payment Reference. For SEPA (SCT or SDD) transactions, the PaymentInformationIdentification "\ - "is recorded in this field pertaining to a globalisation, and the EndToEndReference for " \ - "simple transactions or for the details of a globalisation."), - 'statement_id': fields.many2one('coda.bank.statement', 'CODA Bank Statement', - select=True, required=True, ondelete='cascade'), - 'coda_bank_account_id': fields.related('statement_id', 'coda_bank_account_id', type='many2one', relation='coda.bank.account', string='Bank Account', store=True, readonly=True), - 'ref': fields.char('Reference', size=32), - 'note': fields.text('Notes'), - 'company_id': fields.related('statement_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True), - } - - #TODO : Check this function. account_bank_statement_line Seems undefined : ) - def unlink(self, cr, uid, ids, context=None): - if context is None: - context = {} - if context.get('block_statement_line_delete', False): - raise osv.except_osv('Warning', _('Delete operation not allowed !')) - return super(account_bank_statement_line, self).unlink(cr, uid, ids, context=context) - -coda_bank_statement_line() - - -class account_bank_statement_line_global(osv.osv): - _inherit = 'account.bank.statement.line.global' - _columns = { - 'coda_statement_line_ids': fields.one2many('coda.bank.statement.line', 'globalisation_id', 'CODA Bank Statement Lines', readonly=True), - } -account_bank_statement_line_global() - - -class coda_account_mapping_rule(osv.osv): - _name = 'coda.account.mapping.rule' - _description = 'Rules Engine to assign accounts during CODA parsing' - _order = 'sequence' - _columns = { - 'coda_bank_account_id': fields.many2one('coda.bank.account', 'CODA Bank Account', ondelete='cascade'), - 'sequence': fields.integer('Sequence', help='Determines the order of the rules to assign accounts'), - 'name': fields.char('Rule Name', size=128, required=True), - # matching criteria - 'trans_type_id': fields.many2one('account.coda.trans.type', 'Transaction Type'), - 'trans_family_id': fields.many2one('account.coda.trans.code', 'Transaction Family', domain=[('type', '=', 'family')]), - 'trans_code_id': fields.many2one('account.coda.trans.code', 'Transaction Code', domain=[('type', '=', 'code')]), - 'trans_category_id': fields.many2one('account.coda.trans.category', 'Transaction Category'), - 'struct_comm_type_id': fields.many2one('account.coda.comm.type', 'Structured Communication Type'), - 'partner_id': fields.many2one('res.partner', 'Partner', ondelete='cascade'), - # resulting general account - 'account_id': fields.many2one('account.account', 'Account', ondelete='cascade', required=True, domain=[('type', '!=', 'view')]), - 'active': fields.boolean('Active', help='Switch on/off this rule.'), - } - _defaults = { - 'active': True, - } - - def account_id_get(self, cr, uid, coda_bank_account_id, trans_type_id=None, trans_family_id=None, - trans_code_id=None, trans_category_id=None, struct_comm_type_id=None, partner_id=None, context=None): - cr.execute('SELECT account_id, trans_type_id, trans_family_id, trans_code_id, trans_category_id, struct_comm_type_id, partner_id ' \ - 'FROM coda_account_mapping_rule ' \ - 'WHERE active = TRUE AND coda_bank_account_id = %s ' \ - 'ORDER BY sequence' % coda_bank_account_id - ) - rules = cr.fetchall() - condition = '(not rule[1] or (trans_type_id == rule[1])) and (not rule[2] or (trans_family_id == rule[2])) ' \ - 'and (not rule[3] or (trans_code_id == rule[3])) and (not rule[4] or (trans_category_id == rule[4])) ' \ - 'and (not rule[5] or (struct_comm_type_id == rule[5])) and (not rule[6] or (partner_id == rule[6]))' - account_id = None - for rule in rules: - if eval(condition): - account_id = rule[0] - break - return account_id - -coda_account_mapping_rule() - -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/l10n_be_coda_comm_type.xml b/addons/l10n_be_coda/l10n_be_coda_comm_type.xml deleted file mode 100644 index 9a042ec48d2..00000000000 --- a/addons/l10n_be_coda/l10n_be_coda_comm_type.xml +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - - 001 - Data concerning the counterparty - - - 002 - Communication of the bank - - - 003 - RBP data - - - 004 - Counterparty’s banker - - - 005 - Data concerning the correspondent - - - 006 - Information concerning the detail amount - - - 007 - Information concerning the detail cash - - - 008 - Identification of the de ultimate beneficiary/creditor (SEPA SCT/SDD) - - - 009 - Identification of the de ultimate ordering customer/debtor (SEPA SCT/SDD) - - - 010 - Information pertaining to sale or purchase of securities - - - 011 - Information pertaining to coupons - - - 100 - (SEPA) payment with a structured format communication applying the ISO standard 11649: Structured creditor reference to remittance information - - - 101 - Credit transfer or cash payment with structured format communication - - - 102 - Credit transfer or cash payment with reconstituted structured format communication - - - 103 - number (e.g. of the cheque, of the card, etc.) - - - 104 - Equivalent in EUR - - - 105 - original amount of the transaction - - - 106 - Method of calculation (VAT, withholding tax on income, commission, etc.) - - - 107 - Direct debit – DOM’80 - - - 108 - Closing - - - 111 - POS credit – Globalisation - - - 112 - ATM payment (usually Eurocheque card) - - - 113 - ATM/POS debit - - - 114 - POS credit - individual transaction - - - 115 - Terminal cash deposit - - - 120 - Correction of a transaction - - - 121 - Commercial bills - - - 122 - Bills - calculation of interest - - - 123 - Fees and commissions - - - 124 - Number of the credit card - - - 125 - Credit - - - 126 - Term investments - - - 127 - European direct debit (SEPA) - - - - diff --git a/addons/l10n_be_coda/l10n_be_coda_trans_category.xml b/addons/l10n_be_coda/l10n_be_coda_trans_category.xml deleted file mode 100644 index 192240cf8aa..00000000000 --- a/addons/l10n_be_coda/l10n_be_coda_trans_category.xml +++ /dev/null @@ -1,440 +0,0 @@ - - - - - - - 000 - Net amount - - - 001 - Interest received - - - 002 - Interest paid - - - 003 - Credit commission - - - 004 - Postage - - - 005 - Renting of letterbox - - - 006 - Various fees/commissions - - - 007 - Access right to database - - - 008 - Information charges - - - 009 - Travelling expenses - - - 010 - Writ service fee - - - 011 - VAT - - - 012 - Exchange commission - - - 013 - Payment commission - - - 014 - Collection commission - - - 015 - Correspondent charges - - - 016 - BLIW/IBLC dues - - - 017 - Research costs - - - 018 - Tental guarantee charges - - - 019 - Tax on physical delivery - - - 020 - Costs of physical delivery - - - 021 - Costs for drawing up a bank cheque - - - 022 - Priority costs - - - 023 - Exercising fee - - - 024 - Growth premium - - - 025 - Individual entry for exchange charges - - - 026 - Handling commission - - - 027 - Charges for unpaid bills - - - 028 - Fidelity premium - - - 029 - Protest charges - - - 030 - Account insurance - - - 031 - Charges foreign cheque - - - 032 - Drawing up a circular cheque - - - 033 - Charges for a foreign bill - - - 034 - Reinvestment fee - - - 035 - Charges foreign documentary bill - - - 036 - Costs relating to a refused cheque - - - 037 - Commission for handling charges - - - 039 - Telecommunications - - - 041 - Credit card costs - - - 042 - Payment card costs - - - 043 - Insurance costs - - - 045 - Handling costs - - - 047 - Charges extension bill - - - 049 - Fiscal stamps/stamp duty - - - 050 - Capital term investment - - - 051 - Withholding tax - - - 052 - Residence state tax - - - 053 - Printing of forms - - - 055 - Repayment loan or credit capital - - - 057 - Interest subsidy - - - 058 - Capital premium - - - 059 - Default interest - - - 061 - Charging fees for transactions - - - 063 - Rounding differences - - - 065 - Interest payment advice - - - 066 - Fixed loan advance - reimbursement - - - 067 - Fixed loan advance - extension - - - 068 - Countervalue of an entry - - - 069 - Forward arbitrage contracts : sum to be supplied by customer - - - 070 - Forward arbitrage contracts : sum to be supplied by bank - - - 071 - Fixed loan advance - availability - - - 072 - Countervalue of commission to third party - - - 073 - Costs of ATM abroad - - - 074 - Mailing costs - - - 100 - Gross amount - - - 200 - Overall documentary credit charges - - - 201 - Advice notice commission - - - 202 - Advising commission | Additional advising commission - - - 203 - Confirmation fee | Additional confirmation fee | Commitment fee | Flat fee | Confirmation reservation commission | Additional reservation commission - - - 204 - Amendment fee - - - 205 - Documentary payment commission | Document commission | Drawdown fee | Negotiation fee - - - 206 - Surety fee/payment under reserve - - - 207 - Non-conformity fee - - - 208 - Commitment fee deferred payment - - - 209 - Transfer commission - - - 210 - Commitment fee - - - 211 - Credit arrangement fee | Additional credit arrangement fee - - - 212 - Warehousing fee - - - 213 - Financing fee - - - 214 - Issue commission (delivery order) - - - 400 - Acceptance fee - - - 401 - Visa charges - - - 402 - Certification costs - - - 403 - Minimum discount rate - - - 404 - Discount commission - - - 405 - Bill guarantee commission - - - 406 - Collection charges - - - 407 - Costs Article 45 - - - 408 - Cover commission - - - 409 - Safe deposit charges - - - 410 - Reclamation charges - - - 411 - Fixed collection charge - - - 412 - Advice of expiry charges - - - 413 - Acceptance charges - - - 414 - Regularisation charges - - - 415 - Surety fee - - - 416 - Charges for the deposit of security - - - 418 - Endorsement commission - - - 419 - Bank service fee - - - 420 - Retention charges - - - 425 - Foreign broker's commission - - - 426 - Belgian broker's commission - - - 427 - Belgian Stock Exchange tax - - - 428 - Interest accrued - - - 429 - Foreign Stock Exchange tax - - - 430 - Recovery of foreign tax - - - 431 - Delivery of a copy - - - - diff --git a/addons/l10n_be_coda/l10n_be_coda_trans_code.xml b/addons/l10n_be_coda/l10n_be_coda_trans_code.xml deleted file mode 100644 index b2b23d59bef..00000000000 --- a/addons/l10n_be_coda/l10n_be_coda_trans_code.xml +++ /dev/null @@ -1,1914 +0,0 @@ - - - - - - - 00 - family - Undefined transactions - - - 00 - code - - Undefined transaction - - - 33 - code - - Value correction - - - 35 - code - - Correction - - - 37 - code - - Costs - - - 39 - code - - Cancellation of a transaction - - - 83 - code - - Value correction - - - 85 - code - - Correction - - - 87 - code - - Costs refunded - - - 89 - code - - Cancellation of a transaction - - - 01 - family - Domestic or local SEPA credit transfers - - - 01 - code - - Individual transfer order - Credit transfer given by the customer on paper or electronically, even if the execution date of this transfer is in the future. Domestic payments as well as euro payments meeting the requirements. - - - 02 - code - - Individual transfer order initiated by the bank - The bank takes the initiative for debiting the customer’s account. - - - 03 - code - - Standing order - Credit transfer for which the order has been given once and which is carried out again at regular intervals without any change. - - - 05 - code - - Payment of wages, etc. - The principal will be debited for the total amount of the file entered. - - - 07 - code - - Collective transfer - The principal will be debited for the total amount of the file entered. - - - 09 - code - - Your semi-standing order - - - 11 - code - - Your semi-standing order – payment to employees - - - 13 - code - - Transfer from your account - Transfer from one account to another account of the same customer at the bank's or the customer's initiative (intracompany). - - - 15 - code - - Balance due insurance premium - - - 17 - code - - Financial centralisation - In case of centralisation by the bank, type 2 will be allotted to this transaction. This total can be followed by the detailed movement. - - - 37 - code - - Costs - - - 39 - code - - Your issue circular cheque - To be used for issued circular cheques given in consignment - - - 49 - code - - Cancellation or correction - - - 50 - code - - Transfer in your favour - - - 51 - code - - Transfer in your favour – initiated by the bank - The bank takes the initiative for crediting the customer’s account. - - - 52 - code - - Payment in your favour - Payment by a third person - - - 54 - code - - Unexecutable transfer order - - - 60 - code - - Non-presented circular cheque - - - 62 - code - - Unpaid postal order - - - 64 - code - - Transfer to your account - Intracompany - - - 66 - code - - Financial centralization - In case of centralisation by the bank, type 2 will be allotted to this transaction. This total can be followed by the detailed movement. - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 03 - family - Cheques - - - 01 - code - - Payment of your cheque - - - 03 - code - - Your purchase by payment card - - - 05 - code - - Payment of voucher - Payment of holiday pay, etc. - - - 07 - code - - Definitely unpaid cheque - - - 09 - code - - Unpaid voucher - - - 11 - code - - Department store cheque - - - 13 - code - - Eurocheque written out abroad - - - 15 - code - - Your purchase bank cheque - Cheque drawn by the bank on itself, usually with charges. - - - 17 - code - - Your certified cheque - Amount of the cheque; if any, charges receive code 37 - - - 19 - code - - Settlement of credit cards - - - 35 - code - - Cash advance - - - 37 - code - - Cheque-related costs - - - 38 - code - - Provisionally unpaid - - - 39 - code - - Provisionally unpaid due to other reason than manual presentation - - - 49 - code - - Cancellation or correction - - - 50 - code - - Credit of a payment via terminal - - - 52 - code - - First credit of cheques, vouchers, luncheon vouchers, postal orders, credit under usual reserve - - - 56 - code - - Non-presented certified cheques - - - 58 - code - - Remittance of cheques, vouchers, etc. credit after collection - Also for vouchers, postal orders, anything but bills of exchange, acquittances, promissory notes, etc. - - - 60 - code - - Reversal of voucher - - - 62 - code - - Reversal of cheque - cheques debited on account, but debit cancelled afterwards for lack of cover (double debit/contra-entry of transaction 01 or 05) - - - 63 - code - - Second credit of unpaid cheque - - - 64 - code - - Reversal of settlement of credit card - - - 66 - code - - Remittance of cheque by your branch - credit under usual reserve - - - 68 - code - - Credit of a payment via electronic purse - - - 87 - code - - Reimbursement of cheque-related costs - Overall amount, VAT included - - - 99 - code - - Cancellation or correction - - - 04 - family - Cards - - - 01 - code - - Loading a GSM card - Debit customer who is loading - - - 02 - code - - Payment by means of a payment card within the Eurozone - Eurozone = countries which have the euro as their official currency - - - 03 - code - - Settlement credit cards - See annexe III : communication 124 - - - 04 - code - - Cash withdrawal from an ATM - At home as well as abroad - - - 05 - code - - Loading Proton - - - 06 - code - - Payment with tank card - - - 07 - code - - Payment by GSM - - - 08 - code - - Payment by means of a payment card outside the Eurozone - Eurozone = countries which have the euro as their official currency - - - 37 - code - - Costs - Various costs for possessing or using a payment card - - - 49 - code - - Cancellation or correction - - - 50 - code - - Credit after a payment at a terminal - Except Proton - - - 51 - code - - Unloading Proton - - - 52 - code - - Loading GSM cards - Credit provider - - - 53 - code - - Cash deposit at an ATM - - - 55 - code - - Income from payments by GSM - - - 68 - code - - Credit after Proton payments - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 05 - family - Direct debit - - - 01 - code - - Payment - - - 03 - code - - Unpaid debt - - - 05 - code - - Reimbursement - - - 37 - code - - Costs - - - 49 - code - - Cancellation or correction - - - 50 - code - - Credit after collection - - - 52 - code - - Credit under usual reserve - - - 54 - code - - Reimbursement - - - 56 - code - - Unexecutable reimbursement - - - 58 - code - - Reversal - (cancellation of an undue debit of the debtor at the initiative of the financial institution or the debtor for lack of cover) - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 07 - family - Domestic commercial paper - - - 01 - code - - Payment commercial paper - Bills of exchange, acquittances, promissory notes; debit of the drawee - - - 03 - code - - Payment receipt card - - - 05 - code - - Commercial paper claimed back - Bill claimed back at the drawer's request (bill claimed back before maturity date) - - - 06 - code - - Extension of maturity date - Costs chargeable to the remitter - - - 07 - code - - Unpaid commercial paper - Contra-entry of a direct credit or of a discount - - - 08 - code - - Payment in advance - Debit of the remitter when the drawee pays in advance directly to the remitter (regards bank acceptances) - - - 09 - code - - Agio on supplier's bill - Debit of the agios to the account of the drawee - - - 10 - code - - Renewal of agreed maturity date - - - 12 - code - - Safe custody - - - 14 - code - - Warrant fallen due - - - 37 - code - - Costs related to commercial paper - If any, detail in the category (e.g. costs for presentation for acceptance, etc.) - - - 39 - code - - Return of an irregular bill of exchange - Debit of the drawer after credit under usual reserve or discount - - - 49 - code - - Cancellation or correction - - - 50 - code - - Remittance of commercial paper - credit after collection - Credit of the remitter - - - 52 - code - - Remittance of commercial paper - credit under usual reserve - - - 54 - code - - Remittance of commercial paper for discount - Among other things advances or promissory notes - - - 56 - code - - Remittance of supplier's bill with guarantee - - - 58 - code - - Remittance of supplier's bill without guarantee - - - 64 - code - - Warrant - - - 86 - code - - Payment after cession - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 09 - family - Counter transactions - - - 01 - code - - Cash withdrawal - Withdrawal by counter cheque or receipt; cash remitted by the bank clerk - - - 03 - code - - Cash withdrawal by card (ATM) - - - 05 - code - - Purchase of foreign bank notes - - - 07 - code - - Purchase of gold/pieces - - - 09 - code - - Purchase of petrol coupons - - - 11 - code - - Your purchase of luncheon vouchers - - - 13 - code - - Cash withdrawal by your branch or agents - On the account of the head office - - - 15 - code - - Your purchase of lottery tickets - - - 17 - code - - Purchase of fiscal stamps - - - 19 - code - - Difference in payment - Used in case of payments accepted under reserve of count, result of overcrediting - - - 21 - code - - Cash withdrawal on card (PROTON) - - - 25 - code - - Purchase of traveller’s cheque - - - 37 - code - - Costs - - - 49 - code - - Cancellation or correction - - - 50 - code - - Cash payment - For own account - the comment for the client is given in the communication; also for mixed payments (cash + cheques) - not to be communicated to the clients; for payments made by a third person: see family 01 - - - 52 - code - - Payment night safe - - - 54 - code - - Your payment ATM - - - 56 - code - - Reserve - - - 58 - code - - Payment by your branch/agents - Takes priority over transaction 52 (hence a payment made by an agent in a night safe = 58 and not 52) - - - 60 - code - - Sale of foreign bank notes - - - 62 - code - - Sale of gold/pieces under usual reserve - - - 64 - code - - Your winning lottery ticket - - - 66 - code - - Repurchase of petrol coupons - - - 68 - code - - Difference in payment - In case of payment accepted under reserve of count; result of undercrediting - see also transaction 19 - - - 70 - code - - Sale of traveller’s cheque - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 11 - family - Securities - - - 01 - code - - Purchase of securities - Purchase of domestic or foreign securities, including subscription rights, certificates, etc. - - - 02 - code - - Tenders - Payment to the bank on maturity date - - - 03 - code - - Subscription to securities - Bonds, shares, tap issues of CDs, with or without payment of interest, etc. - - - 04 - code - - Issues - - - 05 - code - - Partial payment subscription - Debit of the subscriber for the complementary payment of partly-paid shares - - - 06 - code - - Share option plan – exercising an option - - - 09 - code - - Settlement of securities - For professionals (stockbrokers) only, whoever the issuer may be (Belgian or foreigner) - - - 11 - code - - Payable coupons/repayable securities - Debit of the issuer by the bank in charge of the financial service - - - 13 - code - - Your repurchase of issue - Unissued part (see 64) - - - 15 - code - - Interim interest on subscription - In case of subscription before the interest due date - - - 17 - code - - Management fee - - - 19 - code - - Regularisation costs - - - 37 - code - - Costs - - - 49 - code - - Cancellation or correction - - - 50 - code - - Sale of securities - - - 51 - code - - Tender - Company issues paper in return for cash - - - 52 - code - - Payment of coupons from a deposit or settlement of coupons delivered over the counter - credit under usual reserve - Whatever the currency of the security - - - 56 - code - - Reserve - - - 58 - code - - Repayable securities from a deposit or delivered at the counter - credit under usual reserve - - - 62 - code - - Interim interest on subscription - When reimbursed separately to the subscriber - - - 64 - code - - Your issue - Amount paid to the issuer by the bank in charge of the placement (firm underwriting or not); also used for the payment in full of partly-paid shares, see transaction 05 - - - 66 - code - - Retrocession of issue commission - For professionals such as insurances and stockbrokers - - - 68 - code - - Compensation for missing coupon - In case coupons attached to a purchased security are missing - - - 70 - code - - Settlement of securities - Only with stockbrokers when they deliver the securities to the bank - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 13 - family - Credit - - - 01 - code - - Short-term loan - Capital and/or interest (specified by the category) - - - 02 - code - - Long-term loan - - - 05 - code - - Settlement of fixed advance - Full or partial reimbursement of a fixed advance at maturity date - - - 07 - code - - Your repayment instalment credits - Often by standing order or direct debit. In case of direct debit, family 13 is used. - - - 11 - code - - Your repayment mortgage loan - - - 13 - code - - Settlement of bank acceptances - - - 15 - code - - Your repayment hire-purchase and similar claims - Hire-purchase agreement under which the financial institution is the lessor - - - 19 - code - - Documentary import credits - - - 21 - code - - Other credit applications - - - 37 - code - - Credit-related costs - - - 49 - code - - Cancellation or correction - - - 50 - code - - Settlement of instalment credit - - - 54 - code - - Fixed advance – capital and interest - - - 55 - code - - Fixed advance – interest only - - - 56 - code - - Subsidy - Interest or capital subsidy - - - 60 - code - - Settlement of mortgage loan - - - 62 - code - - Term loan - - - 68 - code - - Documentary export credits - - - 70 - code - - Settlement of discount bank acceptance - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 30 - family - Various transactions - - - 01 - code - - Spot purchase of foreign exchange - - - 03 - code - - Forward purchase of foreign exchange - - - 05 - code - - Capital and/or interest term investment - - - 33 - code - - Value (date) correction - - - 37 - code - - Costs - - - 39 - code - - Undefined transaction - - - 49 - code - - Cancellation or correction - - - 50 - code - - Spot sale of foreign exchange - - - 52 - code - - Forward sale of foreign exchange - - - 54 - code - - Capital and/or interest term investment - - - 55 - code - - Interest term investment - - - 83 - code - - Value (date) correction - - - 87 - code - - Reimbursement of costs - - - 89 - code - - Undefined transaction - - - 99 - code - - Cancellation or correction - - - 35 - family - Closing (periodical settlements for interest, costs,…) - - - 01 - code - - Closing - - - 37 - code - - Costs - - - 49 - code - - Cancellation or correction - - - 50 - code - - Closing - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 41 - family - International credit transfers - non-SEPA credit transfers - - - 01 - code - - Transfer - - - 03 - code - - Standing order - - - 05 - code - - Collective payments of wages - - - 07 - code - - Collective transfers - - - 13 - code - - Transfer from your account - Intracompany - - - 17 - code - - Financial centralisation (debit) - - - 37 - code - - Costs relating to outgoing foreign transfers and non-SEPA transfers - - - 38 - code - - Costs relating to incoming foreign and non-SEPA transfers - - - 49 - code - - Cancellation or correction - - - 50 - code - - Transfer - - - 64 - code - - Transfer to your account - Intracompany - - - 66 - code - - Financial centralisation (credit) - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 43 - family - Foreign cheques - - - 01 - code - - Payment of a foreign cheque - Debit of a cheque in foreign currency or in EUR in favour of a foreigner - - - 07 - code - - Unpaid foreign cheque - Foreign cheque remitted for collection that returns unpaid - - - 15 - code - - Purchase of an international bank cheque - - - 37 - code - - Costs relating to payment of foreign cheques - - - 49 - code - - Cancellation or correction - - - 52 - code - - Remittance of foreign cheque credit under usual reserve - - - 58 - code - - Remittance of foreign cheque credit after collection - - - 62 - code - - Reversal of cheques - - - 70 - code - - Purchase of traveller’s cheque - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 47 - family - Foreign commercial paper - - - 01 - code - - Payment of foreign bill - - - 05 - code - - Bill claimed back - - - 06 - code - - Extension - - - 07 - code - - Unpaid foreign bill - - - 11 - code - - Payment documents abroad - Bills of lading - - - 13 - code - - Discount foreign supplier's bills - Debit customer, payment of agios, interest, exchange commission, etc. - - - 14 - code - - Warrant fallen due - - - 37 - code - - Costs relating to the payment of a foreign bill - - - 49 - code - - Cancellation or correction - - - 50 - code - - Remittance of foreign bill credit after collection - - - 52 - code - - Remittance of foreign bill credit under usual reserve - - - 54 - code - - Discount abroad - - - 56 - code - - Remittance of guaranteed foreign supplier's bill - - - 58 - code - - Idem without guarantee - - - 60 - code - - Remittance of documents abroad - credit under usual reserve - - - 62 - code - - Remittance of documents abroad - credit after collection - - - 64 - code - - Warrant - - - 87 - code - - Reimbursement of costs - - - 99 - code - - Cancellation or correction - - - 49 - family - Foreign counter transactions - - - 03 - code - - ATM withdrawal - - - 80 - family - Separately charged costs and provisions - - - 01 - code - - Guarantee card charges - - - 02 - code - - Costs relating to electronic output - - - 03 - code - - Payment card charges - - - 04 - code - - Costs for holding a documentary cash credit - - - 05 - code - - Card charges - - - 06 - code - - Damage relating to bills and cheques - - - 07 - code - - Insurance costs - - insurance costs of account holders against fatal accidents - passing-on of several insurance costs - - - 08 - code - - Registering compensation for savings accounts - - - 09 - code - - Postage - Postage recouped to the debit of the customer (including forwarding charges) - - - 10 - code - - Purchase of Smartcard - - - 11 - code - - Costs for the safe custody of correspondence - Costs chargeable to clients who ask to have their correspondence kept at their disposal at the bank's counter - - - 12 - code - - Costs for opening a bank guarantee - - - 13 - code - - Renting of safes - Commission for renting a safe deposit box - - - 14 - code - - Handling costs instalment credit - - - 15 - code - - Night safe - Commission collected to the debit of the customer to whom the bank delivers a key which gives access to the night safe - - - 16 - code - - Bank confirmation to revisor or accountant - - - 17 - code - - Charge for safe custody - Collected for unsealed deposit of securities, and other parcels - - - 18 - code - - Trade information - - - 19 - code - - Special charge for safe custody - Collected for securities, gold, pass-books, etc. placed in safe custody - - - 20 - code - - Drawing up a certificate - - - 21 - code - - Pay-packet charges - Charges for preparing pay packets - - - 22 - code - - Management/custody - - - 23 - code - - Research costs - Costs charged for all kinds of research (information on past transactions, address retrieval, ...) - - - 24 - code - - Participation in and management of interest refund system - - - 25 - code - - Renting of direct debit box - Commission for the renting of boxes put at the disposal for the correspondence - - - 26 - code - - Travel insurance premium - - - 27 - code - - Subscription fee - For publications of the financial institution - - - 29 - code - - Information charges - Charges collected for: - commercial information - sundry information - - - 31 - code - - Writ service fee - E.g. for signing invoices - - - 33 - code - - Miscellaneous fees and commissions - Costs not specified otherwise, often with a manual communication (e.g. for collecting, ordering funds). VAT excluded = type 0 VAT included = type 3 (at least 3 articles) - - - 35 - code - - Costs - Costs charged for calculating the amount of the tax to be paid (e.g. Fiscomat). - - - 37 - code - - Access right to database - Fixed right, either one-off or periodical; for details, see "categories" - - - 39 - code - - Surety fee - Agios on guarantees given - - - 41 - code - - Research costs - - - 43 - code - - Printing of forms - - - 45 - code - - Documentary credit charges - - - 47 - code - - Charging fees for transactions - - - 49 - code - - Cancellation or correction - - - 99 - code - - Cancellation or correction - - - - diff --git a/addons/l10n_be_coda/l10n_be_coda_trans_type.xml b/addons/l10n_be_coda/l10n_be_coda_trans_type.xml deleted file mode 100644 index 9be29ce622a..00000000000 --- a/addons/l10n_be_coda/l10n_be_coda_trans_type.xml +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - - 0 - Simple amount without detailed data; e.g. : an individual credit transfer (free of charges). - - - 1 - Amount as totalised by the customer; e.g. a file regrouping payments of wages or payments made to suppliers or a file regrouping collections for which the customer is debited or credited with one single amount. As a matter of principle, this type is also used when no detailed data is following (type 5). - - - 5 - - Detail of 1. Standard procedure is no detailing. However, the customer may ask for detailed data to be included into his file after the overall record (type 1). - - - 2 - Amount as totalised by the bank; e.g. : the total amount of a series of credit transfers with a structured communication As a matter of principle, this type will also be used when no detailed data (type 6 or 7) is following. - - - 6 - - Detail of 2. Simple amount without detailed data. Normally, data of this kind comes after type 2. The customer may ask for a separate file containing the detailed data. In that case, one will speak of a ‘separate application’. The records in a separate application keep type 6. - - - 7 - - Detail of 2. Simple account with detailed data The records in a separate application keep type 7. - - - 9 - - Detail of 7. The records in a separate application keep type 9. - - - 3 - Simple amount with detailed data; e.g. in case of charges for cross-border credit transfers. - - - 8 - - Detail of 3. - - - - diff --git a/addons/l10n_be_coda/l10n_be_coda_view.xml b/addons/l10n_be_coda/l10n_be_coda_view.xml index 1ef09862c3d..9a362cd6fc4 100644 --- a/addons/l10n_be_coda/l10n_be_coda_view.xml +++ b/addons/l10n_be_coda/l10n_be_coda_view.xml @@ -1,547 +1,6 @@ - - - - - - - - coda.bank.account.search - coda.bank.account - - - - - - - - - - - - - - - - - - - coda.bank.account.list - coda.bank.account - - - - - - - - - - - - - coda.bank.account.form - coda.bank.account - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
-
- - CODA Bank Account Configuration - coda.bank.account - form - tree,form - - - - - - - account.coda.trans.type.tree - account.coda.trans.type - - - - - - - - - - account.coda.trans.type.form - account.coda.trans.type - -
- - - - - -
-
-
- - CODA Transaction Types - ir.actions.act_window - account.coda.trans.type - form - tree,form - - - - - - account.coda.trans.code.tree - account.coda.trans.code - - - - - - - - - - - account.coda.trans.code.form - account.coda.trans.code - -
- - - - - - - - -
-
- - CODA Transaction Codes - ir.actions.act_window - account.coda.trans.code - form - tree,form - - - - - - account.coda.trans.category.tree - account.coda.trans.category - - - - - - - - - account.coda.trans.category.form - account.coda.trans.category - -
- - - - -
- - CODA Transaction Categories - ir.actions.act_window - account.coda.trans.category - form - tree,form - - - - - - account.coda.comm.type.tree - account.coda.comm.type - - - - - - - - - account.coda.comm.type.form - account.coda.comm.type - -
- - - - -
- - CODA Structured Communication Types - ir.actions.act_window - account.coda.comm.type - form - tree,form - - - - - - - - - - account.coda.tree - account.coda - - - - - - - - - - - - - account.coda.form - account.coda - -
- - - - - - - - - - - - - -
-
-
- - - account.coda.search - account.coda - - - - - - - - - - - - - - - - - Imported CODA Files - ir.actions.act_window - account.coda - form - tree,form - - - - - - - - - coda.bank.statement.list - coda.bank.statement - - - - - - - - - - - - - - - - - coda.bank.statement.form - coda.bank.statement - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - coda.bank.statement.search - coda.bank.statement - - - - - - - - - - - - - - - - - - - - - CODA Bank Statements - ir.actions.act_window - coda.bank.statement - form - tree,form - - - The CODA Bank Statements contain the information encoded in their originating CODA file in a human readable format. The Bank Statements associated with a CODA contain the subset of the CODA Bank Statement data that is required for the creation of the Accounting Entries. - - - - - - - - coda.bank.statement.line.list - coda.bank.statement.line - - - - - - - - - - - - - - - - - - - - - coda.bank.statement.line.form - coda.bank.statement.line - -
- - - - - - - - - - - - - - - - - - -
- - - coda.bank.statement.line.filter - coda.bank.statement.line - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - CODA Statement Lines - coda.bank.statement.line - form - tree,form - {'block_statement_line_delete' : 1} - - - - - - - - - - - - -
-
+ + + + \ No newline at end of file diff --git a/addons/l10n_be_coda/l10n_be_coda_wizard.xml b/addons/l10n_be_coda/l10n_be_coda_wizard.xml index 76178820d9c..427e0c1991e 100644 --- a/addons/l10n_be_coda/l10n_be_coda_wizard.xml +++ b/addons/l10n_be_coda/l10n_be_coda_wizard.xml @@ -49,20 +49,6 @@ new
- - - - diff --git a/addons/l10n_be_coda/res_bank.py b/addons/l10n_be_coda/res_bank.py deleted file mode 100755 index 47e7fdf8569..00000000000 --- a/addons/l10n_be_coda/res_bank.py +++ /dev/null @@ -1,34 +0,0 @@ -# -*- encoding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## - -from osv import fields, osv - - -class res_bank(osv.osv): - _inherit = 'res.bank' - _columns = { - 'code': fields.char('Code', size=3, - help='Country specific Bank Code (used for bban to iban conversion).'), - } -res_bank() - -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/res_bank_view.xml b/addons/l10n_be_coda/res_bank_view.xml deleted file mode 100755 index fe4a71d2bdb..00000000000 --- a/addons/l10n_be_coda/res_bank_view.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - res.bank.form.add.code - res.bank - - form - - - - - - - - - res.bank.tree.add.code - res.bank - - form - - - - - - - - - - diff --git a/addons/l10n_be_coda/security/account_security.xml b/addons/l10n_be_coda/security/account_security.xml deleted file mode 100644 index b8fdd32ebe6..00000000000 --- a/addons/l10n_be_coda/security/account_security.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - Account Coda model company rule - - - ['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])] - - - diff --git a/addons/l10n_be_coda/security/ir.model.access.csv b/addons/l10n_be_coda/security/ir.model.access.csv deleted file mode 100644 index 89ee65048fb..00000000000 --- a/addons/l10n_be_coda/security/ir.model.access.csv +++ /dev/null @@ -1,17 +0,0 @@ -id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink -access_account_coda_manager,account.coda manager,model_account_coda,account.group_account_manager,1,1,1,1 -access_account_coda_user,account.coda user,model_account_coda,account.group_account_user,1,0,0,0 -access_account_coda_trans_type_manager,account.coda.trans.type manager,model_account_coda_trans_type,account.group_account_manager,1,1,1,1 -access_account_coda_trans_type_user,account.coda.trans.type user,model_account_coda_trans_type,account.group_account_user,1,0,0,0 -access_account_coda_trans_code_manager,account.coda.trans.code manager,model_account_coda_trans_code,account.group_account_manager,1,1,1,1 -access_account_coda_trans_code_user,account.coda.trans.code user,model_account_coda_trans_code,account.group_account_user,1,0,0,0 -access_account_coda_trans_category_manager,account.coda.trans.category manager,model_account_coda_trans_category,account.group_account_manager,1,1,1,1 -access_account_coda_trans_category_user,account.coda.trans.category user,model_account_coda_trans_category,account.group_account_user,1,0,0,0 -access_account_coda_comm_type_manager,account.coda.comm.type manager,model_account_coda_comm_type,account.group_account_manager,1,1,1,1 -access_account_coda_comm_type_user,account.coda.comm.type user,model_account_coda_comm_type,account.group_account_user,1,0,0,0 -access_coda_bank_account_manager,coda.bank.account manager,model_coda_bank_account,account.group_account_manager,1,1,1,1 -access_coda_bank_account_user,coda.bank.account user,model_coda_bank_account,account.group_account_user,1,0,0,0 -access_coda_bank_statement_manager,coda.bank.statement manager,model_coda_bank_statement,account.group_account_manager,1,1,1,1 -access_coda_bank_statement_user,coda.bank.statement user,model_coda_bank_statement,account.group_account_user,1,0,0,0 -access_coda_bank_statement_line_manager,coda.bank.statement.line manager,model_coda_bank_statement_line,account.group_account_manager,1,1,1,1 -access_coda_bank_statement_line_user,coda.bank.statement.line user,model_coda_bank_statement_line,account.group_account_user,1,0,0,0 diff --git a/addons/l10n_be_coda/wizard/__init__.py b/addons/l10n_be_coda/wizard/__init__.py index 3851606707b..e3038609b80 100644 --- a/addons/l10n_be_coda/wizard/__init__.py +++ b/addons/l10n_be_coda/wizard/__init__.py @@ -20,6 +20,6 @@ # ############################################################################## -import account_coda_import_dle +import account_coda_import # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index bb165cf1656..b63b29701d8 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -20,14 +20,11 @@ # ############################################################################## -import time import base64 from osv import fields, osv from tools.translate import _ -import netsvc -import re -from traceback import format_exception -from sys import exc_info +import time +import tools import logging _logger = logging.getLogger(__name__) @@ -44,14 +41,11 @@ class account_coda_import(osv.osv_memory): 'coda_fname': lambda *a: '', } - def _check_account_payment(self, cr, uid, context=None): - res = self.pool.get('ir.module.module').search(cr, uid, [('name', '=', 'account_payment'), ('state', '=', 'installed')]) - return res and True or False - def coda_parsing(self, cr, uid, ids, context=None, batch=False, codafile=None, codafilename=None): if context is None: context = {} if batch: + print codafile = str(codafile) codafilename = codafilename else: @@ -62,1866 +56,685 @@ class account_coda_import(osv.osv_memory): except: raise osv.except_osv(_('Error!'), _('Wizard in incorrect state. Please hit the Cancel button!')) return {} - - currency_obj = self.pool.get('res.currency') - coda_bank_account_obj = self.pool.get('coda.bank.account') - trans_type_obj = self.pool.get('account.coda.trans.type') - trans_code_obj = self.pool.get('account.coda.trans.code') - trans_category_obj = self.pool.get('account.coda.trans.category') - comm_type_obj = self.pool.get('account.coda.comm.type') - journal_obj = self.pool.get('account.journal') - period_obj = self.pool.get('account.period') - partner_bank_obj = self.pool.get('res.partner.bank') - coda_obj = self.pool.get('account.coda') - coda_st_obj = self.pool.get('coda.bank.statement') - coda_st_line_obj = self.pool.get('coda.bank.statement.line') - bank_st_obj = self.pool.get('account.bank.statement') - bank_st_line_obj = self.pool.get('account.bank.statement.line') - glob_obj = self.pool.get('account.bank.statement.line.global') - inv_obj = self.pool.get('account.invoice') - move_line_obj = self.pool.get('account.move.line') - voucher_obj = self.pool.get('account.voucher') - seq_obj = self.pool.get('ir.sequence') - mod_obj = self.pool.get('ir.model.data') - account_mapping_obj = self.pool.get('coda.account.mapping.rule') - - if self._check_account_payment(cr, uid): - payment_line_obj = self.pool.get('payment.line') - else: - payment_line_obj = False - - wf_service = netsvc.LocalService('workflow') - - coda_bank_table = coda_bank_account_obj.read(cr, uid, coda_bank_account_obj.search(cr, uid, []), context=context) - for coda_bank in coda_bank_table: - coda_bank.update({'journal_code': coda_bank['journal'] and journal_obj.browse(cr, uid, coda_bank['journal'][0], context=context).code or ''}) - coda_bank.update({'iban': partner_bank_obj.browse(cr, uid, coda_bank['bank_id'][0], context=context).iban}) - coda_bank.update({'acc_number': partner_bank_obj.browse(cr, uid, coda_bank['bank_id'][0], context=context).acc_number}) - coda_bank.update({'currency_name': currency_obj.browse(cr, uid, coda_bank['currency'][0], context=context).name}) - trans_type_table = trans_type_obj.read(cr, uid, trans_type_obj.search(cr, uid, []), context=context) - trans_code_table = trans_code_obj.read(cr, uid, trans_code_obj.search(cr, uid, []), context=context) - trans_category_table = trans_category_obj.read(cr, uid, trans_category_obj.search(cr, uid, []), context=context) - comm_type_table = comm_type_obj.read(cr, uid, comm_type_obj.search(cr, uid, []), context=context) - - err_string = '' - err_code = None - err_log = '' - coda_statements = [] recordlist = unicode(base64.decodestring(codafile), 'windows-1252', 'strict').split('\n') - digits = self.pool.get('decimal.precision').precision_get(cr, uid, 'Account') - + statements = [] for line in recordlist: - if not line: pass elif line[0] == '0': - # start of a new statement within the CODA file - coda_statement = {} - coda_parsing_note = '' - coda_statement_lines = {} - st_line_seq = 0 - # header data - coda_statement['currency'] = 'EUR' # default currency - coda_statement['version'] = line[127] - coda_version = line[127] - if coda_version not in ['1', '2']: - err_string = _('\nCODA V%s statements are not supported, please contact your bank!') % coda_version - err_code = 'R0001' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - coda_statement['coda_statement_lines'] = {} - coda_statement['date'] = str2date(line[5:11]) - coda_statement['coda_creation_date'] = str2date(line[5:11]) - coda_statement['separate_application'] = line[83:88] - coda_statement['first_transaction_date'] = False - coda_statement['state'] = 'draft' - - coda_id = coda_obj.search(cr, uid, [ - ('name', '=', codafilename), - ('coda_creation_date', '=', coda_statement['date']), - ]) - if coda_id: - err_string = _("\nCODA File with Filename '%s' and Creation Date '%s' has already been imported !") \ - % (codafilename, coda_statement['date']) - err_code = 'W0001' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Warning !'), err_string) - + #Begin of a new Bank statement + statement = {} + statements.append(statement) + statement['version'] = line[127] + if statement['version'] not in ['1', '2']: + raise osv.except_osv(_('Error R001!'), _('CODA V%s statements are not supported, please contact your bank!') % statement['version']) + statement['globalisation_stack'] = [] + statement['lines'] = [] + statement['date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[5:11]), '%d%m%y')) + statement['separateApplication'] = rmspaces(line[83:88]) elif line[0] == '1': - if coda_version == '1': - coda_statement['acc_number'] = line[5:17] - if line[18:21].strip(): - coda_statement['currency'] = line[18:21] - elif line[1] == '0': # Belgian bank account BBAN structure - coda_statement['acc_number'] = line[5:17] - coda_statement['currency'] = line[18:21] - elif line[1] == '1': # foreign bank account BBAN structure - err_string = _('\nForeign bank accounts with BBAN structure are not supported !') - err_code = 'R1001' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - elif line[1] == '2': # Belgian bank account IBAN structure - coda_statement['acc_number'] = line[5:21] - coda_statement['currency'] = line[39:42] - elif line[1] == '3': # foreign bank account IBAN structure - err_string = _('\nForeign bank accounts with IBAN structure are not supported !') - err_code = 'R1002' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - else: - err_string = _('\nUnsupported bank account structure !') - err_code = 'R1003' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - coda_statement['description'] = line[90:125].strip() - cba_filter = lambda x: (coda_statement['acc_number'] in _get_acc_numbers(x['acc_number'])) \ - and (coda_statement['currency'] == x['currency_name']) and (coda_statement['description'] in [x['description1'] or '', x['description2'] or '']) - coda_bank = filter(cba_filter, coda_bank_table) - if coda_bank: - coda_bank = coda_bank[0] - coda_statement['type'] = coda_bank['state'] - coda_statement['journal_id'] = coda_bank['journal'] and coda_bank['journal'][0] - coda_statement['currency_id'] = coda_bank['currency'][0] - coda_statement['coda_bank_account_id'] = coda_bank['id'] - coda_statement['account_mapping_ids'] = coda_bank['account_mapping_ids'] - coda_statement['coda_bank_params'] = coda_bank - awaiting_acc = coda_bank['awaiting_account'][0] - transfer_acc = coda_bank['transfer_account'][0] - find_payment = coda_bank['find_payment'] - find_bbacom = coda_bank['find_bbacom'] - find_inv_number = coda_bank['find_inv_number'] - find_partner = coda_bank['find_partner'] - update_partner = coda_bank['update_partner'] - coda_statement['balance_start_enforce'] = coda_bank['balance_start_enforce'] - coda_statement['discard_dup'] = coda_bank['discard_dup'] - company_id = coda_bank['company_id'][0] - company_bank_ids = partner_bank_obj.search(cr, uid, [('company_id', '=', company_id)]) - company_bank_accounts = partner_bank_obj.read(cr, uid, company_bank_ids, ['acc_number']) - company_bank_accounts = [x['acc_number'].replace(' ', '') for x in company_bank_accounts] - else: - err_string = _("\nNo matching CODA Bank Account Configuration record found !") + \ - _("\nPlease check if the 'Bank Account Number', 'Currency' and 'Account Description' fields of your configuration record match with '%s', '%s' and '%s' !") \ - % (coda_statement['acc_number'], coda_statement['currency'], coda_statement['description']) - err_code = 'R1004' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - bal_start = list2float(line[43:58]) # old balance data - if line[42] == '1': # 1= Debit - bal_start = - bal_start - coda_statement['balance_start'] = bal_start - coda_statement['old_balance_date'] = str2date(line[58:64]) - coda_statement['acc_holder'] = line[64:90] - coda_statement['paper_ob_seq_number'] = line[2:5] - coda_statement['coda_seq_number'] = line[125:128] - + #Statement details + if statement['version'] == '1': + statement['accountNumber'] = rmspaces(line[5:17]) + statement['currency'] = rmspaces(line[18:21]) + elif statement['version'] == '2': + if line[1] == '0': # Belgian bank account BBAN structure + statement['accountNumber'] = rmspaces(line[5:17]) + statement['currency'] = rmspaces(line[18:21]) + elif line[1] == '1': # foreign bank account BBAN structure + raise osv.except_osv(_('Error R1001!'), _('Foreign bank accounts with BBAN structure are not supported !')) + elif line[1] == '2': # Belgian bank account IBAN structure + statement['accountNumber'] = rmspaces(line[5:21]) + statement['currency'] = rmspaces(line[39:42]) + elif line[1] == '3': # foreign bank account IBAN structure + raise osv.except_osv(_('Error R1002!'), _('Foreign bank accounts with IBAN structure are not supported !')) + else: # Something else, not supported + raise osv.except_osv(_('Error R1003!'), _('Unsupported bank account structure !')) + statement['description'] = rmspaces(line[90:125]) + statement['balance_start'] = float(rmspaces(line[43:58])) / 1000 + statement['balance_start_date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[58:64]), '%d%m%y')) + statement['accountHolder'] = rmspaces(line[64:90]) + statement['paperSeqNumber'] = rmspaces(line[2:5]) + statement['codaSeqNumber'] = rmspaces(line[125:128]) elif line[0] == '2': - # movement data record 2 - if line[1] == '1': - # movement data record 2.1 - st_line = {} - st_line_seq = st_line_seq + 1 - st_line['sequence'] = st_line_seq - st_line['type'] = 'general' - st_line['reconcile'] = False - st_line['trans_family'] = False - st_line['struct_comm_type'] = '' - st_line['struct_comm_type_id'] = 0 - st_line['struct_comm_type_desc'] = '' - st_line['struct_comm_bba'] = '' - st_line['communication'] = '' - st_line['payment_reference'] = '' - st_line['partner_id'] = 0 - st_line['account_id'] = 0 - st_line['counterparty_name'] = '' - st_line['counterparty_bic'] = '' - st_line['counterparty_number'] = '' - st_line['counterparty_currency'] = '' - st_line['glob_lvl_flag'] = False - st_line['globalisation_id'] = 0 - st_line['globalisation_code'] = '' - st_line['globalisation_amount'] = False - st_line['amount'] = False - - st_line['ref'] = line[2:10] - st_line['ref_move'] = line[2:6] - st_line['ref_move_detail'] = line[6:10] - - if st_line_seq == 1: - main_move_stack = [st_line] # initialise main_move_stack (used to link 2.1 detail records to 2.1 main record - glob_lvl_stack = [0] # initialise globalisation stack - elif st_line['ref_move_detail'] == '0000': - glob_lvl_stack = [0] # re-initialise globalisation stack - - st_line['trans_ref'] = line[10:31] - st_line_amt = list2float(line[32:47]) - if line[31] == '1': # 1=debit - st_line_amt = - st_line_amt - - st_line['trans_type'] = line[53] - trans_type = filter(lambda x: st_line['trans_type'] == x['type'], trans_type_table) - if not trans_type: - err_string = _('\nThe File contains an invalid CODA Transaction Type : %s!') % st_line['trans_type'] - err_code = 'R2001' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - st_line['trans_type_id'] = trans_type[0]['id'] - st_line['trans_type_desc'] = trans_type[0]['description'] - - # processing of amount depending on globalisation code - glob_lvl_flag = int(line[124]) - if glob_lvl_flag > 0: - if glob_lvl_stack[-1] == glob_lvl_flag: - st_line['glob_lvl_flag'] = glob_lvl_flag - st_line['amount'] = st_line_amt - glob_lvl_stack.pop() + #New statement line + statementLine = {} + statementLine['type'] = 'general' + statementLine['ref'] = rmspaces(line[2:10]) + statementLine['ref_move'] = rmspaces(line[2:6]) + statementLine['ref_move_detail'] = rmspaces(line[6:10]) + statementLine['sequence'] = len(statement['lines']) + 1 + statementLine['transactionRef'] = rmspaces(line[10:31]) + statementLine['debit'] = line[31] # 0 = Credit, 1 = Debit + statementLine['amount'] = float(rmspaces(line[32:47])) / 1000 + if statementLine['debit'] == '1': + statementLine['amount'] = - statementLine['amount'] + statementLine['transaction_type'] = line[53] + if statementLine['transaction_type'] not in transaction_types: + raise osv.except_osv(_('Error R2001!'), _('The File contains an invalid CODA Transaction Type : %s!') % statementLine['transaction_type']) + statementLine['transactionDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[47:53]), '%d%m%y')) + statementLine['transaction_family'] = rmspaces(line[54:56]) + #TODO Handling severals transactions Family + statementLine['transaction_code'] = rmspaces(line[56:58]) + #TODO Handling severals transactions code + statementLine['transaction_category'] = rmspaces(line[58:61]) + #TODO Handling severals transactions category + statementLine['communication'] = rmspaces(line[62:115]) + #TODO Handling structured communication + statementLine['entryDate'] = rmspaces(line[115:121]) + statementLine['type'] = 'normal' + statementLine['globalisation'] = int(line[124]) + if len(statement['globalisation_stack']) > 0 and statementLine['communication'] != '': + statementLine['communication'] = "\n".join([statement['globalisation_stack'][-1]['communication'], statementLine['communication']]) + if statementLine['globalisation'] > 0: + if len(statement['globalisation_stack']) > 0 and statement['globalisation_stack'][-1]['globalisation'] == statementLine['globalisation']: + # Destack + statement['globalisation_stack'].pop() else: - glob_lvl_stack.append(glob_lvl_flag) - st_line['type'] = 'globalisation' - st_line['glob_lvl_flag'] = glob_lvl_flag - st_line['globalisation_amount'] = st_line_amt - else: - st_line['amount'] = st_line_amt - - # The 'globalisation' concept can also be implemented without the globalisation level flag. - # This is e.g. used by Europabank to give the details of Card Payments. - if st_line['ref_move'] == main_move_stack[-1]['ref_move']: - if st_line['ref_move_detail'] == '9999': - # Current CODA parsing logic doesn't support > 9999 detail lines - err_string = _('\nTransaction Detail Limit reached!') - err_code = 'R2010' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - elif st_line['ref_move_detail'] != '0000': - if glob_lvl_stack[-1] == 0: - # promote associated move record into a globalisation - glob_lvl_flag = 1 - glob_lvl_stack.append(glob_lvl_flag) - main_st_line_seq = main_move_stack[-1]['sequence'] - to_promote = coda_statement['coda_statement_lines'][main_st_line_seq] - if not main_move_stack[-1].get('detail_cnt'): - to_promote.update({ - 'type': 'globalisation', - 'glob_lvl_flag': glob_lvl_flag, - 'globalisation_amount': main_move_stack[-1]['amount'], - 'amount': False, - 'account_id': 0, - }) - main_move_stack[-1]['promoted'] = True - if not main_move_stack[-1].get('detail_cnt'): - main_move_stack[-1]['detail_cnt'] = 1 - else: - main_move_stack[-1]['detail_cnt'] += 1 - - # positions 48-53 : Valuta date or 000000 if not known (DDMMYY) - st_line['val_date'] = str2date(line[47:53]) - # positions 54-61 : transaction code - st_line['trans_family'] = line[54:56] - trans_family = filter(lambda x: (x['type'] == 'family') and (st_line['trans_family'] == x['code']), trans_code_table) - if not trans_family: - err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] - err_code = 'R2002' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - st_line['trans_family_id'] = trans_family[0]['id'] - st_line['trans_family_desc'] = trans_family[0]['description'] - st_line['trans_code'] = line[56:58] - trans_code = filter(lambda x: (x['type'] == 'code') and (st_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), - trans_code_table) - if trans_code: - st_line['trans_code_id'] = trans_code[0]['id'] - st_line['trans_code_desc'] = trans_code[0]['description'] - else: - st_line['trans_code_id'] = None - st_line['trans_code_desc'] = _('Transaction Code unknown, please consult your bank.') - st_line['trans_category'] = line[58:61] - trans_category = filter(lambda x: st_line['trans_category'] == x['category'], trans_category_table) - if trans_category: - st_line['trans_category_id'] = trans_category[0]['id'] - st_line['trans_category_desc'] = trans_category[0]['description'] - else: - st_line['trans_category_id'] = None - st_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') - # positions 61-115 : communication - if line[61] == '1': - st_line['struct_comm_type'] = line[62:65] - comm_type = filter(lambda x: st_line['struct_comm_type'] == x['code'], comm_type_table) - if not comm_type: - err_string = _('\nThe File contains an invalid Structured Communication Type : %s!') % st_line['struct_comm_type'] - err_code = 'R2003' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - st_line['struct_comm_type_id'] = comm_type[0]['id'] - st_line['struct_comm_type_desc'] = comm_type[0]['description'] - st_line['communication'] = st_line['name'] = line[65:115] - if st_line['struct_comm_type'] in ['101', '102']: - bbacomm = line[65:77] - st_line['struct_comm_bba'] = st_line['name'] = '+++' + bbacomm[0:3] + '/' + bbacomm[3:7] + '/' + bbacomm[7:] + '+++' - else: - st_line['communication'] = st_line['name'] = line[62:115] - st_line['entry_date'] = str2date(line[115:121]) - if st_line['sequence'] == 1: - coda_statement['first_transaction_date'] = st_line['entry_date'] - # positions 122-124 not processed - coda_statement_lines[st_line_seq] = st_line # store transaction - - if st_line['ref_move'] != main_move_stack[-1]['ref_move']: - if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): - # add closing globalisation level on previous detail record in order to correctly close - # moves that have been 'promoted' to globalisation - closeglobalise = coda_statement['coda_statement_lines'][st_line_seq - 1] - closeglobalise.update({ - 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], - }) - else: - # demote record with globalisation code from 'globalisation' to 'general' when no detail records - # the same logic is repeated on the New Balance Record ('8 Record') in order to cope with CODA files - # containing a single 2.1 record that needs to be 'demoted'. - if main_move_stack[-1]['type'] == 'globalisation' and not main_move_stack[-1].get('detail_cnt'): - # demote record with globalisation code from 'globalisation' to 'general' when no detail records - main_st_line_seq = main_move_stack[-1]['sequence'] - to_demote = coda_statement['coda_statement_lines'][main_st_line_seq] - to_demote.update({ - 'type': 'general', - 'glob_lvl_flag': 0, - 'globalisation_amount': False, - 'amount': main_move_stack[-1]['globalisation_amount'], - }) - main_move_stack.pop() - main_move_stack.append(st_line) - coda_statement['coda_statement_lines'] = coda_statement_lines - + #Stack + statementLine['type'] = 'globalisation' + statement['globalisation_stack'].append(statementLine) + statement['lines'].append(statementLine) elif line[1] == '2': - # movement data record 2.2 - if coda_statement['coda_statement_lines'][st_line_seq]['ref'][0:4] != line[2:6]: - err_string = _('\nCODA parsing error on movement data record 2.2, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] - err_code = 'R2004' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:63] - coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:63] - coda_statement['coda_statement_lines'][st_line_seq]['payment_reference'] = line[63:98].strip() - coda_statement['coda_statement_lines'][st_line_seq]['counterparty_bic'] = line[98:109].strip() - + if statement['lines'][-1]['ref'][0:4] != line[2:6]: + raise osv.except_osv(_('Error R2004!'), _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + statement['lines'][-1]['communication'] += rmspaces(line[10:63]) + statement['lines'][-1]['payment_reference'] = rmspaces(line[63:98]) + statement['lines'][-1]['counterparty_bic'] = rmspaces(line[98:109]) elif line[1] == '3': - # movement data record 2.3 - if coda_statement['coda_statement_lines'][st_line_seq]['ref'][0:4] != line[2:6]: - err_string = _('\nCODA parsing error on movement data record 2.3, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] - err_code = 'R2005' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - st_line = coda_statement_lines[st_line_seq] - if coda_version == '1': - counterparty_number = line[10:22].strip() - counterparty_name = line[47:125].strip() - counterparty_currency = '' + if statement['lines'][-1]['ref'][0:4] != line[2:6]: + raise osv.except_osv(_('Error R2005!'), _('CODA parsing error on movement data record 2.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + if statement['version'] == '1': + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) + statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:125]) + statement['lines'][-1]['counterpartyCurrency'] = '' else: if line[22] == ' ': - counterparty_number = line[10:22].strip() - counterparty_currency = line[23:26].strip() + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) + statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[23:26]) else: - counterparty_number = line[10:44].strip() - counterparty_currency = line[44:47].strip() - counterparty_name = line[47:82].strip() - st_line['name'] += line[82:125] - st_line['communication'] += line[82:125] - st_line['counterparty_number'] = counterparty_number - st_line['counterparty_currency'] = counterparty_currency - st_line['counterparty_name'] = counterparty_name - """ - TO DO: - - replace code infra by check on flag 128 and copy info in Notes Field. - - if counterparty_currency not in [coda_bank['currency_name'], '']: - err_string = _('\nCODA parsing error on movement data record 2.3, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] - err_code = 'R2006' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - """ - - # invoice matching and reconciliation - if st_line['type'] == 'general': - match = False - payment_reference_match = False - inv_ids = None - partner_bank_ids = False - - # check payment reference in bank statement line against payment order lines - payment_reference = st_line['payment_reference'] - if payment_reference and find_payment and st_line['amount'] < 0: - payline_ids = payment_line_obj and payment_line_obj.search(cr, uid, [('name', '=', payment_reference)]) - if payline_ids: - if len(payline_ids) == 1: - payline = payment_line_obj.browse(cr, uid, payline_ids[0]) - match = True - payment_reference_match = True - st_line['partner_id'] = payline.partner_id.id - if payline.move_line_id: - st_line['reconcile'] = payline.move_line_id.id - st_line['account_id'] = payline.move_line_id.account_id.id - if payline._get_ml_inv_ref: - inv_type = payline.ml_inv_ref.type - st_line['type'] = inv_type == 'in_invoice' and 'supplier' or 'customer' - else: - st_line['type'] = 'general' - else: - err_string = _('\nThe CODA parsing detected a payment reference ambiguity while processing movement data record 2.3, seq nr %s!' \ - '\nPlease check your Payment Gateway configuration or contact your OpenERP support channel.') % line[2:10] - err_code = 'R2007' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - - # check bba scor in bank statement line against open invoices - if st_line['struct_comm_bba'] and find_bbacom: - if st_line['amount'] > 0: - domain = [('type', 'in', ['out_invoice', 'in_refund'])] - else: - domain = [('type', 'in', ['in_invoice', 'out_refund'])] - inv_ids = inv_obj.search(cr, uid, - domain + [('state', '=', 'open'), ('reference', '=', st_line['struct_comm_bba']), ('reference_type', '=', 'bba')]) - if not inv_ids: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ - "\n There is no invoice matching the Structured Communication '%s'!" \ - "\n Please verify and adjust the invoice and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ - % (st_line['ref'], st_line['struct_comm_bba']) - elif len(inv_ids) == 1: - match = True - elif len(inv_ids) > 1: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ - "\n There are multiple invoices matching the Structured Communication '%s'!" \ - "\n A manual reconciliation is required.") \ - % (st_line['ref'], st_line['struct_comm_bba']) - - # use free comm in bank statement line for lookup against open invoices - if not match and find_bbacom: - # extract possible bba scor from free form communication and try to find matching invoice - free_comm_digits = re.sub('\D', '', st_line['communication'] or '') - select = "SELECT id FROM (SELECT id, type, state, amount_total, number, reference_type, reference, " \ - "'%s'::text AS free_comm_digits FROM account_invoice) sq " \ - "WHERE state = 'open' AND reference_type = 'bba' " \ - "AND free_comm_digits LIKE '%%'||regexp_replace(reference, '\\\D', '', 'g')||'%%'" \ - % (free_comm_digits) - if st_line['amount'] > 0: - select2 = " AND type IN ('out_invoice', 'in_refund')" - else: - select2 = " AND type IN ('in_invoice', 'out_refund')" - cr.execute(select + select2) - res = cr.fetchall() - if res: - inv_ids = [x[0] for x in res] - if len(inv_ids) == 1: - match = True - if not match and st_line['communication'] and find_inv_number: - # check matching invoice number in free form communication combined with matching amount - free_comm = repl_special(st_line['communication'].strip()) - amount_fmt = '%.' + str(digits) + 'f' - if st_line['amount'] > 0: - amount_rounded = amount_fmt % round(st_line['amount'], digits) - else: - amount_rounded = amount_fmt % round(-st_line['amount'], digits) - select = "SELECT id FROM (SELECT id, type, state, amount_total, number, reference_type, reference, " \ - "'%s'::text AS free_comm FROM account_invoice) sq " \ - "WHERE state = 'open' AND amount_total = %s" \ - % (free_comm, amount_rounded) - # 'out_invoice', 'in_refund' - if st_line['amount'] > 0: - select2 = " AND type = 'out_invoice' AND free_comm ilike '%'||number||'%'" - cr.execute(select + select2) - res = cr.fetchall() - if res: - inv_ids = [x[0] for x in res] - else: - select2 = " AND type = 'in_refund' AND free_comm ilike '%'||reference||'%'" - cr.execute(select + select2) - res = cr.fetchall() - if res: - inv_ids = [x[0] for x in res] - # 'in_invoice', 'out_refund' - else: - select2 = " AND type = 'in_invoice' AND free_comm ilike '%'||reference||'%'" - cr.execute(select + select2) - res = cr.fetchall() - if res: - inv_ids = [x[0] for x in res] - else: - select2 = " AND type = 'out_refund' AND free_comm ilike '%'||number||'%'" - cr.execute(select + select2) - res = cr.fetchall() - if res: - inv_ids = [x[0] for x in res] - if inv_ids: - if len(inv_ids) == 1: - match = True - elif len(inv_ids) > 1: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ - "\n There are multiple invoices matching the Invoice Amount and Reference." \ - "\n A manual reconciliation is required.") \ - % (st_line['ref']) - - if not payment_reference_match and match and inv_ids and len(inv_ids) == 1: - invoice = inv_obj.browse(cr, uid, inv_ids[0]) - partner = invoice.partner_id - st_line['partner_id'] = partner.id - if invoice.type in ['in_invoice', 'in_refund']: - st_line['account_id'] = partner.property_account_payable.id - st_line['type'] = 'supplier' - else: - st_line['account_id'] = partner.property_account_receivable.id - st_line['type'] = 'customer' - iml_ids = move_line_obj.search(cr, uid, [('move_id', '=', invoice.move_id.id), ('reconcile_id', '=', False), ('account_id.reconcile', '=', True)]) - if iml_ids: - st_line['reconcile'] = iml_ids[0] - else: - err_string = _('\nThe CODA parsing detected a database inconsistency while processing movement data record 2.3, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] - err_code = 'R2008' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - - # lookup partner via counterparty_number when invoice lookup failed - if not match and counterparty_number: - transfer_account = filter(lambda x: counterparty_number in x, company_bank_accounts) - if transfer_account: - st_line['account_id'] = transfer_acc - match = True - elif find_partner: - partner_bank_ids = partner_bank_obj.search(cr, uid, [('acc_number', '=', counterparty_number)]) - if not match and find_partner and partner_bank_ids: - if len(partner_bank_ids) > 1: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ - "\n No partner record assigned: There are multiple partners with the same Bank Account Number '%s'!" \ - "\n Please correct the configuration and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ - % (st_line['ref'], counterparty_number) - else: - partner_bank = partner_bank_obj.browse(cr, uid, partner_bank_ids[0], context) - st_line['partner_id'] = partner_bank.partner_id.id - match = True - if st_line['amount'] < 0: - st_line['account_id'] = partner_bank.partner_id.property_account_payable.id - st_line['type'] = 'supplier' - else: - st_line['account_id'] = partner_bank.partner_id.property_account_receivable.id - st_line['type'] = 'customer' - elif not match and find_partner: - if counterparty_number: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ - "\n The bank account '%s' is not defined for the partner '%s'!" \ - "\n Please correct the configuration and perform the import again or otherwise change the corresponding entry manually in the generated Bank Statement.") \ - % (st_line['ref'], counterparty_number, counterparty_name) - else: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':" \ - "\n No matching partner record found!" \ - "\n Please adjust the corresponding entry manually in the generated Bank Statement.") \ - % (st_line['ref']) - st_line['account_id'] = awaiting_acc - - # add bank account to partner record - if match and st_line['account_id'] != transfer_acc and counterparty_number and update_partner: - partner_bank_ids = partner_bank_obj.search(cr, uid, [('acc_number', '=', counterparty_number), ('partner_id', '=', st_line['partner_id'])], order='id') - if len(partner_bank_ids) > 1: - # clean up partner bank duplicates, keep most recently created - _logger.warn('Duplicate Bank Accounts for partner_id %s have been removed, ids = %s', - st_line['partner_id'], partner_bank_ids[:-1]) - partner_bank_obj.unlink(cr, uid, partner_bank_ids[:-1]) - if not partner_bank_ids: - feedback = update_partner_bank(self, cr, uid, st_line['counterparty_bic'], counterparty_number, st_line['partner_id'], counterparty_name) - if feedback: - coda_parsing_note += _("\n Bank Statement '%%(name)s' line '%s':") % st_line['ref'] + feedback - - coda_statement_lines[st_line_seq] = st_line - coda_statement['coda_statement_lines'] = coda_statement_lines - # end of processing movement data record 2.3 - + statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:44]) + statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[44:47]) + statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:82]) + statement['lines'][-1]['communication'] += rmspaces(line[82:125]) else: - # movement data record 2.x (x <> 1,2,3) - err_string = _('\nMovement data records of type 2.%s are not supported !') % line[1] - err_code = 'R2009' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - + # movement data record 2.x (x != 1,2,3) + raise osv.except_osv(_('Error R2009!'), _('\nMovement data records of type 2.%s are not supported !') % line[1]) elif line[0] == '3': - # information data record 3 - if line[1] == '1': - # information data record 3.1 - info_line = {} - info_line['entry_date'] = st_line['entry_date'] - info_line['type'] = 'information' - st_line_seq = st_line_seq + 1 - info_line['sequence'] = st_line_seq - info_line['struct_comm_type'] = '' - info_line['struct_comm_type_desc'] = '' - info_line['communication'] = '' - info_line['ref'] = line[2:10] - info_line['trans_ref'] = line[10:31] - # positions 32-38 : transaction code - info_line['trans_type'] = line[31] - trans_type = filter(lambda x: info_line['trans_type'] == x['type'], trans_type_table) - if not trans_type: - err_string = _('\nThe File contains an invalid CODA Transaction Type : %s!') % st_line['trans_type'] - err_code = 'R3001' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - info_line['trans_type_desc'] = trans_type[0]['description'] - info_line['trans_family'] = line[32:34] - trans_family = filter(lambda x: (x['type'] == 'family') and (info_line['trans_family'] == x['code']), trans_code_table) - if not trans_family: - err_string = _('\nThe File contains an invalid CODA Transaction Family : %s!') % st_line['trans_family'] - err_code = 'R3002' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - info_line['trans_family_desc'] = trans_family[0]['description'] - info_line['trans_code'] = line[34:36] - trans_code = filter(lambda x: (x['type'] == 'code') and (info_line['trans_code'] == x['code']) and (trans_family[0]['id'] == x['parent_id'][0]), - trans_code_table) - if trans_code: - info_line['trans_code_desc'] = trans_code[0]['description'] - else: - info_line['trans_code_desc'] = _('Transaction Code unknown, please consult your bank.') - info_line['trans_category'] = line[36:39] - trans_category = filter(lambda x: info_line['trans_category'] == x['category'], trans_category_table) - if trans_category: - info_line['trans_category_desc'] = trans_category[0]['description'] - else: - info_line['trans_category_desc'] = _('Transaction Category unknown, please consult your bank.') - # positions 40-113 : communication - if line[39] == '1': - info_line['struct_comm_type'] = line[40:43] - comm_type = filter(lambda x: info_line['struct_comm_type'] == x['code'], comm_type_table) - if not comm_type: - err_string = _('\nThe File contains an invalid Structured Communication Type : %s!') % info_line['struct_comm_type'] - err_code = 'R3003' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - info_line['struct_comm_type_desc'] = comm_type[0]['description'] - info_line['communication'] = info_line['name'] = line[43:113] - else: - info_line['communication'] = info_line['name'] = line[40:113] - # positions 114-128 not processed - coda_statement_lines[st_line_seq] = info_line - coda_statement['coda_statement_lines'] = coda_statement_lines - + infoLine = {} + infoLine['entryDate'] = statement['lines'][-1]['entryDate'] + infoLine['type'] = 'information' + infoLine['sequence'] = len(statement['lines']) + 1 + infoLine['ref'] = rmspaces(line[2:10]) + infoLine['transactionRef'] = rmspaces(line[10:31]) + infoLine['transaction_type'] = line[31] + infoLine['transaction_family'] = rmspaces(line[32:34]) + infoLine['transaction_code'] = rmspaces(line[34:36]) + infoLine['transaction_category'] = rmspaces(line[36:39]) + infoLine['communication'] = rmspaces(line[40:113]) + infoLine['amount'] = 0.0 + infoLine['type'] = 'information' + statement['lines'].append(infoLine) elif line[1] == '2': - # information data record 3.2 - if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: - err_string = _('\nCODA parsing error on information data record 3.2, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] - err_code = 'R3004' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:115] - coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:115] - + if infoLine['ref'] != rmspaces(line[2:10]): + raise osv.except_osv(_('Error R3004!'), _('CODA parsing error on information data record 3.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + statement['lines'][-1]['communication'] += rmspaces(line[10:100]) elif line[1] == '3': - # information data record 3.3 - if coda_statement['coda_statement_lines'][st_line_seq]['ref'] != line[2:10]: - err_string = _('\nCODA parsing error on information data record 3.3, seq nr %s!' \ - '\nPlease report this issue via your OpenERP support channel.') % line[2:10] - err_code = 'R3005' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Error!'), err_string) - coda_statement['coda_statement_lines'][st_line_seq]['name'] += line[10:100] - coda_statement['coda_statement_lines'][st_line_seq]['communication'] += line[10:100] - + if infoLine['ref'] != rmspaces(line[2:10]): + raise osv.except_osv(_('Error R3005!'), _('CODA parsing error on information data record 3.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + statement['lines'][-1]['communication'] += rmspaces(line[10:100]) elif line[0] == '4': - # free communication data record 4 - comm_line = {} - comm_line['type'] = 'communication' - st_line_seq = st_line_seq + 1 - comm_line['sequence'] = st_line_seq - comm_line['ref'] = line[2:10] - comm_line['communication'] = comm_line['name'] = line[32:112] - coda_statement_lines[st_line_seq] = comm_line - coda_statement['coda_statement_lines'] = coda_statement_lines - + comm_line = {} + comm_line['type'] = 'communication' + comm_line['sequence'] = len(statement['lines']) + 1 + comm_line['ref'] = rmspaces(line[2:10]) + comm_line['communication'] = rmspaces(line[32:112]) + comm_line['amount'] = 0.0 + comm_line['type'] = 'communication' + statement['lines'].append(comm_line) elif line[0] == '8': # new balance record - last_transaction = main_move_stack[-1] - if last_transaction['type'] == 'globalisation' and not last_transaction.get('detail_cnt'): - # demote record with globalisation code from 'globalisation' to 'general' when no detail records - main_st_line_seq = main_move_stack[-1]['sequence'] - to_demote = coda_statement['coda_statement_lines'][main_st_line_seq] - to_demote.update({ - 'type': 'general', - 'glob_lvl_flag': 0, - 'globalisation_amount': False, - 'amount': main_move_stack[-1]['globalisation_amount'], - }) - # add closing globalisation level on previous detail record in order to correctly close - # moves that have been 'promoted' to globalisation - if main_move_stack[-1].get('detail_cnt') and main_move_stack[-1].get('promoted'): - closeglobalise = coda_statement['coda_statement_lines'][st_line_seq - 1] - closeglobalise.update({ - 'glob_lvl_flag': main_move_stack[-1]['glob_lvl_flag'], - }) - coda_statement['paper_nb_seq_number'] = line[1:4] - bal_end = list2float(line[42:57]) - coda_statement['new_balance_date'] = str2date(line[57:63]) - if line[41] == '1': # 1=Debit - bal_end = - bal_end - coda_statement['balance_end_real'] = bal_end - if coda_statement['new_balance_date']: - period_id = period_obj.search(cr, uid, [('date_start', '<=', coda_statement['new_balance_date']), ('date_stop', '>=', coda_statement['new_balance_date'])]) + statement['debit'] = line[41] + statement['paperSeqNumber'] = rmspaces(line[1:4]) + statement['balance_end_real'] = float(rmspaces(line[42:57])) / 1000 + statement['balance_end_realDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[57:63]), '%d%m%y')) + if statement['debit'] == '1': # 1=Debit + statement['balance_end_real'] = - statement['balance_end_real'] + if statement['balance_end_realDate']: + period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['balance_end_realDate']), ('date_stop', '>=', statement['balance_end_realDate'])]) else: - period_id = period_obj.search(cr, uid, [('date_start', '<=', coda_statement['date']), ('date_stop', '>=', coda_statement['date'])]) - if not period_id: - err_string = _("\nThe CODA Statement New Balance date doesn't fall within a defined Accounting Period!" \ - "\nPlease create the Accounting Period for date %s.") % coda_statement['new_balance_date'] - err_code = 'R0002' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('Data Error!'), err_string) - coda_statement['period_id'] = period_id[0] - if coda_bank['coda_st_naming']: - coda_statement['name'] = coda_bank['coda_st_naming'] % { - 'code': coda_bank['journal_code'] or '', - 'year': coda_statement['new_balance_date'] and coda_statement['new_balance_date'][:4] or coda_statement['date'][:4], - 'y': coda_statement['new_balance_date'] and coda_statement['new_balance_date'][2:4] or coda_statement['date'][2:4], - 'coda': coda_statement['coda_seq_number'], - 'paper_ob': coda_statement['paper_ob_seq_number'], - 'paper': coda_statement['paper_nb_seq_number'], - } - else: - coda_statement['name'] = '/' - + period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['date']), ('date_stop', '>=', statement['date'])]) + if not period_id and len(period_id) == 0: + raise osv.except_osv(_('Error R0002!'), _("The CODA Statement New Balance date doesn't fall within a defined Accounting Period! Please create the Accounting Period for date %s.") % statement['balance_end_realDate']) + statement['period_id'] = period_id[0] elif line[0] == '9': - # footer record - coda_statement['balance_min'] = list2float(line[22:37]) - coda_statement['balance_plus'] = list2float(line[37:52]) - if not bal_end: - coda_statement['balance_end_real'] = coda_statement['balance_start'] + coda_statement['balance_plus'] - coda_statement['balance_min'] - if coda_parsing_note: - coda_statement['coda_parsing_note'] = '\nStatement Line matching results:' + coda_parsing_note - else: - coda_statement['coda_parsing_note'] = '' - coda_statements.append(coda_statement) - #end for + statement['balanceMin'] = float(rmspaces(line[22:37])) / 1000 + statement['balancePlus'] = float(rmspaces(line[37:52])) / 1000 + if not statement['balance_end_real']: + statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] + for i, statement in enumerate(statements): + # print '---STATEMENT #' + str(i) + '---' + print statement + data = { + 'name': '[' + statement['date'] + ']' + statement['description'], + 'date': statement['date'], + 'journal_id': 18, + 'period_id': statement['period_id'], + 'balance_start': statement['balance_start'], + 'balance_end_real': statement['balance_end_real'], + 'account_id': 1 + } + statement['id'] = self.pool.get('account.bank.statement').create(cr, uid, data, context=context) + for line in statement['lines']: + if line['type'] == 'normal': + counterparty = [] + if 'counterpartyName' in line: + counterparty.append(line['counterpartyName']) + if 'counterpartyNumber' in line: + counterparty.append(line['counterpartyNumber']) + if len(counterparty) > 0: + counterparty = '[' + ' / '.join(counterparty) + ']' + else: + counterparty = '/' + if line['transaction_type'] in transaction_types: + line['transaction_type'] = transaction_types[line['transaction_type']][1] + if line['transaction_category'] in transaction_categories: + line['transaction_category'] = transaction_categories[line['transaction_category']] + if line['transaction_family'] in transaction_codes: + transaction_family = transaction_codes[line['transaction_family']] + line['transaction_family'] = transaction_family[0] + if line['transaction_code'] in transaction_family[1]: + line['transaction_code'] = transaction_family[1][line['transaction_code']] + note = [] + note.append(_('Counter Party') + ': ' + counterparty) + note.append(_('Communication') + ': ' + line['communication']) + note.append(_('Transaction type') + ': ' + line['transaction_type']) + note.append(_('Transaction family') + ': ' + line['transaction_family']) + note.append(_('Transaction code') + ': ' + line['transaction_code']) + note.append(_('Transaction category') + ': ' + line['transaction_category']) - err_string = '' - err_code = '' - coda_id = 0 - coda_note = '' - line_note = '' - - try: - coda_id = coda_obj.create(cr, uid, { - 'name': codafilename, - 'coda_data': codafile, - 'coda_creation_date': coda_statement['date'], - 'date': fields.date.context_today(self, cr, uid, context=context), - 'user_id': uid, - }) - context.update({'coda_id': coda_id}) - - except osv.except_osv, e: - cr.rollback() - err_string = _('\nApplication Error : ') + str(e) - except Exception, e: - cr.rollback() - err_string = _('\nSystem Error : ') + str(e) - except: - cr.rollback() - err_string = _('\nUnknown Error : ') + str(e) - if err_string: - err_code = 'G0001' - if batch: - return (err_code, err_string) - raise osv.except_osv(_('CODA Import failed !'), err_string) - - nb_err = 0 - err_string = '' - coda_st_ids = [] - bk_st_ids = [] - - for statement in coda_statements: - - # The CODA Statement info is written to two objects: 'coda.bank.statement' and 'account.bank.statement' - - try: - normal2info = False - lines = statement['coda_statement_lines'] - if not statement['first_transaction_date']: - normal2info = True # don't create a bank statement for CODA's without transactions - else: - line_vals = [x for x in lines.itervalues()] - transactions = filter(lambda x: (x['type'] in ['globalisation', 'general', 'supplier', 'customer']) and x['amount'], line_vals) - if not transactions: - normal2info = True # don't create a bank statement for CODA's without transactions - if normal2info: - statement['type'] = 'info' # don't create a bank statement for CODA's without transactions - statement['coda_parsing_note'] += _("\n\nThe CODA Statement %s does not contain transactions, hence no Bank Statement has been created." \ - "\nSelect the 'CODA Bank Statement' to check the contents of %s.") \ - % (statement['name'], statement['name']) - - coda_st_id = coda_st_obj.create(cr, uid, { - 'name': statement['name'], - 'type': statement['type'], - 'coda_bank_account_id': statement['coda_bank_account_id'], - 'currency': statement['currency_id'], - 'journal_id': statement['journal_id'], - 'coda_id': coda_id, - 'date': statement['date'], - 'coda_creation_date': statement['coda_creation_date'], - 'period_id': statement['period_id'], - 'old_balance_date': statement['old_balance_date'], - 'new_balance_date': statement['new_balance_date'], - 'balance_start': statement['balance_start'], - 'balance_end_real': statement['balance_end_real'], - }) - coda_st_ids.append(coda_st_id) - - # check duplicates for CODA's of type 'normal' - discard = False - if statement['type'] == 'normal' and statement['discard_dup']: - dup_ids = bank_st_obj.search(cr, uid, [('name', '=', statement['name']), ('company_id', '=', company_id)]) - if dup_ids: - discard = True - statement['type'] = 'info' # don't create a bank statement for duplicates - statement['coda_parsing_note'] += _("\n\nThe Bank Statement %s already exists, hence no duplicate Bank Statement has been created." \ - "\nSelect the 'CODA Bank Statement' to check the contents of %s.") \ - % (statement['name'], statement['name']) - - # create only bank statement for CODA's of type 'normal' - if statement['type'] == 'normal' and not discard: - context.update({'ebanking_import': 1}) - journal = journal_obj.browse(cr, uid, statement['journal_id'], context=context) - balance_start_check_date = statement['first_transaction_date'] or statement['date'] - cr.execute('SELECT balance_end_real \ - FROM account_bank_statement \ - WHERE journal_id = %s and date <= %s \ - ORDER BY date DESC,id DESC LIMIT 1', (statement['journal_id'], balance_start_check_date)) - res = cr.fetchone() - balance_start_check = res and res[0] - if balance_start_check == None: - if journal.default_debit_account_id and (journal.default_credit_account_id == journal.default_debit_account_id): - balance_start_check = journal.default_debit_account_id.balance + try: + if 'counterpartyNumber' in line and int(line['counterpartyNumber']) == 0: + line['counterpartyNumber'] = False + except: + pass + if 'counterpartyNumber' in line and line['counterpartyNumber']: + ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) + if ids and len(ids) > 0: + partner_id = self.pool.get('res.partner.bank').browse(cr, uid, ids[0],context=context).partner_id.id else: - nb_err += 1 - err_string += _('\nConfiguration Error in journal %s!' \ - '\nPlease verify the Default Debit and Credit Account settings.') % journal.name - break - if balance_start_check != statement['balance_start']: - balance_start_err_string = _('\nThe CODA Statement %s Starting Balance (%.2f) does not correspond with the previous Closing Balance (%.2f) in journal %s!') \ - % (statement['name'], statement['balance_start'], balance_start_check, journal.name) - if statement['balance_start_enforce']: - nb_err += 1 - err_string += balance_start_err_string - break - else: - statement['coda_parsing_note'] += '\n' + balance_start_err_string + partner_id = None - st_vals = { - 'name': statement['name'], - 'journal_id': statement['journal_id'], - 'coda_statement_id': coda_st_id, - 'date': statement['new_balance_date'], - 'period_id': statement['period_id'], - 'balance_start': statement['balance_start'], - 'balance_end_real': statement['balance_end_real'], - 'state': 'draft', + data = { + 'name': line['communication'], + 'note': "\n".join(note), + 'date': line['entryDate'], + 'amount': line['amount'], + # 'type': '', + 'partner_id': partner_id, + 'account_id': 1, + 'statement_id': statement['id'], + # 'analytic_account_id': '', + # 'move_ids': '', + 'ref': line['ref'], + 'sequence': line['sequence'], } - st_hook_error, st_vals = self._statement_hook(cr, uid, statement['coda_bank_params'], st_vals, context=context) - if st_hook_error: - nb_err += 1 - err_string += st_hook_error - break - bk_st_id = bank_st_obj.create(cr, uid, st_vals, context=context) - bk_st_ids.append(bk_st_id) - coda_st_obj.write(cr, uid, [coda_st_id], {'statement_id': bk_st_id}, context=context) - - st_line_seq = 0 - - for x in lines: - line = lines[x] - - if not line['type'] == 'communication': - if line['trans_family'] in st_line_name_families: - line['name'] = get_st_line_name(line, context) - if line['type'] == 'information': - if line['struct_comm_type'] in parse_comms_info: - line['name'], line['communication'] = parse_comm_info(self, cr, uid, line, comm_type_table, context) - elif line['struct_comm_type'] in parse_comms_move: - line['name'], line['communication'] = parse_comm_move(self, cr, uid, line, comm_type_table, context) - elif line['struct_comm_type'] in parse_comms_move: - line['name'], line['communication'] = parse_comm_move(self, cr, uid, line, comm_type_table, context) - - # handling non-transactional records : line['type'] in ['information', 'communication'] - - if line['type'] == 'information': - - - #Check if this line can be deleted. glob_id_stack marked as undefined here - line['globalisation_id'] = glob_id_stack[-1][2] - line_note = _('Transaction Type' ': %s - %s' \ - '\nTransaction Family: %s - %s' \ - '\nTransaction Code: %s - %s' \ - '\nTransaction Category: %s - %s' \ - '\nStructured Communication Type: %s - %s' \ - '\nCommunication: %s') \ - % (line['trans_type'], line['trans_type_desc'], - line['trans_family'], line['trans_family_desc'], - line['trans_code'], line['trans_code_desc'], - line['trans_category'], line['trans_category_desc'], - line['struct_comm_type'], line['struct_comm_type_desc'], - line['communication']) - - coda_st_line_obj.create(cr, uid, { - 'sequence': line['sequence'], - 'ref': line['ref'], - 'name': line['name'].strip() or '/', - 'type': 'information', - 'date': line['entry_date'], - 'statement_id': coda_st_id, - 'note': line_note, - }) - - elif line['type'] == 'communication': - - line_note = _('Free Communication:\n %s') \ - % (line['communication']) - - coda_st_line_obj.create(cr, uid, { - 'sequence': line['sequence'], - 'ref': line['ref'], - 'name': line['name'].strip() or '/', - 'type': 'communication', - 'date': statement['date'], - 'statement_id': coda_st_id, - 'note': line_note, - }) - - # handling transactional records, # line['type'] in ['globalisation', 'general', 'supplier', 'customer'] - - else: - - if line['ref_move_detail'] == '0000': - glob_id_stack = [(0, '', 0, '')] # initialise stack with tuples (glob_lvl_flag, glob_code, glob_id, glob_name) - - glob_lvl_flag = line['glob_lvl_flag'] - if glob_lvl_flag: - if glob_id_stack[-1][0] == glob_lvl_flag: - line['globalisation_id'] = glob_id_stack[-1][2] - glob_id_stack.pop() - else: - glob_name = line['name'].strip() or '/' - glob_code = seq_obj.get(cr, uid, 'statement.line.global') - glob_id = glob_obj.create(cr, uid, { - 'code': glob_code, - 'name': glob_name, - 'type': 'coda', - 'parent_id': glob_id_stack[-1][2], - 'amount': line['globalisation_amount'], - }) - line['globalisation_id'] = glob_id - glob_id_stack.append((glob_lvl_flag, glob_code, glob_id, glob_name)) - - line_note = _('Partner Name: %s \nPartner Account Number: %s' \ - '\nTransaction Type: %s - %s' \ - '\nTransaction Family: %s - %s' \ - '\nTransaction Code: %s - %s' \ - '\nTransaction Category: %s - %s' \ - '\nStructured Communication Type: %s - %s' \ - '\nPayment Reference: %s' \ - '\nCommunication: %s') \ - % (line['counterparty_name'], line['counterparty_number'], - line['trans_type'], line['trans_type_desc'], - line['trans_family'], line['trans_family_desc'], - line['trans_code'], line['trans_code_desc'], - line['trans_category'], line['trans_category_desc'], - line['struct_comm_type'], line['struct_comm_type_desc'], - line['payment_reference'], - line['communication']) - - if line['type'] == 'globalisation': - - coda_st_line_obj.create(cr, uid, { - 'sequence': line['sequence'], - 'ref': line['ref'], - 'name': line['name'].strip() or '/', - 'type': 'globalisation', - 'val_date': line['val_date'], - 'date': line['entry_date'], - 'globalisation_level': line['glob_lvl_flag'], - 'globalisation_amount': line['globalisation_amount'], - 'globalisation_id': line['globalisation_id'], - 'partner_id': line['partner_id'] or 0, - 'account_id': line['account_id'], - 'payment_reference': line['payment_reference'], - 'statement_id': coda_st_id, - 'note': line_note, - }) - - else: # line['type'] in ['general', 'supplier', 'customer'] - - if glob_lvl_flag == 0: - line['globalisation_id'] = glob_id_stack[-1][2] - if not line['account_id']: - line['account_id'] = awaiting_acc - - coda_st_line_obj.create(cr, uid, { - 'sequence': line['sequence'], - 'ref': line['ref'], - 'name': line['name'].strip() or '/', - 'type': line['type'], - 'val_date': line['val_date'], - 'date': line['entry_date'], - 'amount': line['amount'], - 'partner_id': line['partner_id'] or 0, - 'counterparty_name': line['counterparty_name'], - 'counterparty_bic': line['counterparty_bic'], - 'counterparty_number': line['counterparty_number'], - 'counterparty_currency': line['counterparty_currency'], - 'account_id': line['account_id'], - 'globalisation_level': line['glob_lvl_flag'], - 'globalisation_id': line['globalisation_id'], - 'payment_reference': line['payment_reference'], - 'statement_id': coda_st_id, - 'note': line_note, - }) - - if statement['type'] == 'normal': - if line['amount'] != 0.0: - st_line_seq += 1 - voucher_id = False - line_name = line['name'].strip() - if not line_name: - if line['globalisation_id']: - line_name = glob_id_stack[-1][3] or '/' - else: - line_name = '/' - - if line['reconcile']: - - move_line = move_line_obj.browse(cr, uid, line['reconcile'], context=context) - company_currency_id = journal.company_id.currency_id.id - currency_id = journal.currency.id - if currency_id and currency_id != company_currency_id: - multi_currency = True - else: - multi_currency = False - context_multi_currency = context.copy() - context_multi_currency.update({'date': line['entry_date']}) - - line_cr_ids = [] - line_dr_ids = [] - amount_remaining = abs(line['amount']) - - #for entry in entries: - if move_line.reconcile_partial_id: - amount_original = abs(move_line.amount_residual_currency) - else: - amount_original = move_line.credit or move_line.debit - if multi_currency: - if move_line.currency_id and move_line.amount_currency: - amount_original = abs(move_line.amount_currency) - else: - amount_original = currency_obj.compute(cr, uid, company_currency_id, currency_id, amount_original, context=context_multi_currency) - if amount_remaining > 0: - amount_voucher_line = min(amount_original, abs(amount_remaining)) - amount_remaining -= amount_voucher_line - else: - amount_voucher_line = 0.0 - voucher_line_vals = { - 'name': move_line.name, - 'account_id': move_line.account_id.id, - 'amount': amount_voucher_line, - 'reconcile': amount_voucher_line == amount_original, - 'type': move_line.credit and 'dr' or 'cr', - 'move_line_id': move_line.id, - } - if voucher_line_vals['type'] == 'cr': - line_cr_ids += [(0, 0, voucher_line_vals)] - else: - line_dr_ids += [(0, 0, voucher_line_vals)] - - voucher_vals = { - 'type': line['type'] == 'supplier' and 'payment' or 'receipt', - 'name': line_name, - 'date': line['val_date'], - 'journal_id': statement['journal_id'], - 'account_id': journal.default_credit_account_id.id, - 'line_cr_ids': line_cr_ids, - 'line_dr_ids': line_dr_ids, - 'pre_line': len(line_dr_ids) > 0 and True or False, - 'period_id': statement['period_id'], - 'currency_id': journal.currency and journal.currency.id or journal.company_id.currency_id.id, - 'company_id': journal.company_id.id, - 'state': 'draft', - 'amount': abs(line['amount']), - 'reference': line['ref'], - 'number': statement['name'] + '/' + str(st_line_seq), - 'partner_id': line['partner_id'], - } - - #_logger.warn('voucher_vals=%s, context=%s', voucher_vals, context) - context['journal_id'] = journal.id # add journal to context for __get_payment_rate_currency method - if line_cr_ids or line_dr_ids: - voucher_id = voucher_obj.create(cr, uid, voucher_vals, context=context) - else: - raise osv.except_osv(_('Error!'), _("Reconcile error while processing line with ref '%s' ! " \ - "\nPlease report this issue via your OpenERP support channel.") % line['ref']) - - # override default account mapping by mappings defined in rules engine - if statement['account_mapping_ids']: - kwargs = { - 'coda_bank_account_id': statement['coda_bank_account_id'], - 'trans_type_id': line['trans_type_id'], - 'trans_family_id': line['trans_family_id'], - 'trans_code_id': line['trans_code_id'], - 'trans_category_id': line['trans_category_id'], - 'struct_comm_type_id': line['struct_comm_type_id'], - 'partner_id': line['partner_id'], - 'context': context, - } - account_id = account_mapping_obj.account_id_get(cr, uid, **kwargs) - if account_id: - line['account_id'] = account_id - st_line_vals = { - 'ref': line['ref'], - 'name': line_name, - 'type': line['type'], - 'val_date': line['val_date'], - 'date': line['entry_date'], - 'amount': line['amount'], - 'partner_id': line['partner_id'] or 0, - 'counterparty_name': line['counterparty_name'], - 'counterparty_bic': line['counterparty_bic'], - 'counterparty_number': line['counterparty_number'], - 'counterparty_currency': line['counterparty_currency'], - 'account_id': line['account_id'], - 'globalisation_id': line['globalisation_id'], - 'statement_id': bk_st_id, - 'voucher_id': voucher_id, - 'note': line_note, - } - - st_lines_vals = self._st_line_hook(cr, uid, statement['coda_bank_params'], st_line_vals, context=context) - if not st_lines_vals: - # removal of lines by the _coda_parsing_hook currently not supported : - # this qould require resequencing/renaming of linked vouchers & moves as well as removal of associated voucher/moves - err_string += _('\nError in _st_line_hook while processing CODA Statement %s for Bank Account %s!') \ - % (statement['coda_seq_number'], (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description'])) - nb_err += 1 - for st_line_vals in st_lines_vals: - # To DO : update sequence of statement lines and naming of associated vouchers/moves when the hook returns multiple lines - st_line_vals.update({'sequence': st_line_seq}) - bank_st_line_obj.create(cr, uid, st_line_vals, context=context) - if st_line_vals['voucher_id']: - voucher = voucher_obj.browse(cr, uid, st_line_vals['voucher_id'], context=context) - move_line = move_line_obj.browse(cr, uid, line['reconcile'], context=context) - if line['amount'] == (line['amount'] > 0 and move_line.debit or -move_line.credit): - wf_service.trg_validate(uid, 'account.voucher', st_line_vals['voucher_id'], 'proforma_voucher', cr) - if voucher.move_id: - move_line_obj.write(cr, uid, [x.id for x in voucher.move_ids], {'statement_id': bk_st_id}, context=context) - - # end 'for x in lines' - - coda_st_obj.write(cr, uid, [coda_st_id], {}, context=context) # calculate balance - st_balance = coda_st_obj.read(cr, uid, coda_st_id, ['balance_end', 'balance_end_real'], context=context) - if st_balance['balance_end'] != st_balance['balance_end_real']: - err_string += _('\nIncorrect ending Balance in CODA Statement %s for Bank Account %s!') \ - % (statement['coda_seq_number'], (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description'])) - if statement['type'] == 'normal': - nb_err += 1 - break - else: - statement['coda_parsing_note'] += '\n' + err_string - - if statement['type'] == 'normal': - bank_st_obj.button_dummy(cr, uid, [bk_st_id], context=context) # calculate balance - journal_name = journal.name - else: - journal_name = _('None') - coda_note = coda_note + \ - _('\n\nBank Journal: %s' \ - '\nCODA Version: %s' \ - '\nCODA Sequence Number: %s' \ - '\nPaper Statement Sequence Number: %s' \ - '\nBank Account: %s' \ - '\nAccount Holder Name: %s' \ - '\nDate: %s, Starting Balance: %.2f, Ending Balance: %.2f' \ - '%s') \ - % (journal_name, - coda_version, - statement['coda_seq_number'], - statement['paper_nb_seq_number'], - (statement['acc_number'] + ' (' + statement['currency'] + ') - ' + statement['description']), - statement['acc_holder'], - statement['date'], float(statement['balance_start']), float(statement['balance_end_real']), - statement['coda_parsing_note'] % {'name': coda_statement['name']}) - if statement.get('separate_application') != '00000': - coda_note += _('\nCode Separate Application: %s') % statement['separate_application'] \ - - except osv.except_osv, e: - cr.rollback() - nb_err += 1 - err_string += _('\nError ! ') + str(e) - tb = ''.join(format_exception(*exc_info())) - _logger.error('Application Error while processing Statement %s\n%s', - statement.get('name', '/'), tb) - except Exception, e: - cr.rollback() - nb_err += 1 - err_string += _('\nSystem Error : ') + str(e) - tb = ''.join(format_exception(*exc_info())) - _logger.error('System Error while processing Statement %s\n%s', - statement.get('name', '/'), tb) - except: - cr.rollback() - nb_err += 1 - err_string = _('\nUnknown Error : ') + str(e) - tb = ''.join(format_exception(*exc_info())) - _logger.error('Unknown Error while processing Statement %s\n%s', - statement.get('name', '/'), tb) - - # end 'for statement in coda_statements' - - coda_note_header = _('CODA File is Imported :') - coda_note_footer = _('\n\nNumber of statements : ') + str(len(coda_st_ids)) - err_log = err_log + _('\nNumber of errors : ') + str(nb_err) + '\n' - - if not nb_err: - note = coda_note_header + coda_note + coda_note_footer - coda_obj.write(cr, uid, [coda_id], {'note': note}) - cr.commit() - if batch: - return None - else: - cr.rollback() - if batch: - err_code = 'G0002' - return (err_code, err_string) - raise osv.except_osv(_('CODA Import failed !'), err_string) - - context.update({'bk_st_ids': bk_st_ids}) - model_data_ids = mod_obj.search(cr, uid, [('model', '=', 'ir.ui.view'), ('name', '=', 'account_coda_import_result_view')], context=context) - resource_id = mod_obj.read(cr, uid, model_data_ids, fields=['res_id'], context=context)[0]['res_id'] - self.write(cr, uid, ids, {'note': note}, context=context) - - return { - 'name': _('Import CODA File result'), - 'res_id': ids[0], - 'view_type': 'form', - 'view_mode': 'form', - 'res_model': 'account.coda.import', - 'view_id': False, - 'target': 'new', - 'views': [(resource_id, 'form')], - 'context': context, - 'type': 'ir.actions.act_window', - } - - def _statement_hook(self, cr, uid, coda_bank_params, st_vals, context=None): - """ - Use this method to take customer specific actions based upon the bank statement data. - Returns: - st_hook_error : False or string with error message - st_vals - """ - return False, st_vals - - def _st_line_hook(self, cr, uid, coda_bank_params, st_line_vals, context=None): - """ - Use this method to adapt the statement line created by the - CODA parsing to customer specific needs. - """ - print 'PLZ DISPLAY SOMETHING RIGHTPLZPLZPLZ' - print st_line_vals['name'] - print st_line_vals['counterparty_name'] - return [st_line_vals] - - def action_open_coda_statements(self, cr, uid, ids, context=None): - if context is None: - context = {} - module, xml_id = 'l10n_be_coda', 'action_coda_bank_statements' - res_model, res_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, module, xml_id) - action = self.pool.get('ir.actions.act_window').read(cr, uid, res_id, context=context) - domain = eval(action.get('domain') or '[]') - domain += [('coda_id', '=', context.get('coda_id', False))] - action.update({'domain': domain}) - return action - - def action_open_bank_statements(self, cr, uid, ids, context=None): - if context is None: - context = {} - module, xml_id = 'account', 'action_bank_statement_tree' - res_model, res_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, module, xml_id) - action = self.pool.get('ir.actions.act_window').read(cr, uid, res_id, context=context) - domain = eval(action.get('domain') or '[]') - domain += [('id', 'in', context.get('bk_st_ids', False))] - action.update({'domain': domain}) - return action + self.pool.get('account.bank.statement.line').create(cr, uid, data, context=context) account_coda_import() +transaction_types = { + "0": ["", _("Simple amount without detailed data; e.g. : an individual credit transfer [free of charges].")], + "1": ["", _("Amount as totalised by the customer; e.g. a file regrouping payments of wages or payments made to suppliers or a file regrouping collections for which the customer is ]debited or credited with one single amount. As a matter of principle, this type is also used when no detailed data is following [type 5].")], + "5": ["1", _("Detail of 1. Standard procedure is no detailing. However, the customer may ask for detailed data to be included into his file after the overall record [type 1].")], + "2": ["", _("Amount as totalised by the bank; e.g. : the total amount of a series of credit transfers with a structured communication As a matter of principle, this type will also be used when no detailed data [type 6 or 7] is following.")], + "6": ["2", _("Detail of 2. Simple amount without detailed data. Normally, data of this kind comes after type 2. The customer may ask for a separate file containing the detailed data. In that case, one will speak of a ‘separate application’. The records in a separate application keep type 6.")], + "7": ["2", _("Detail of 2. Simple account with detailed data The records in a separate application keep type 7.")], + "9": ["7", _("Detail of 7. The records in a separate application keep type 9.")], + "3": ["", _("Simple amount with detailed data; e.g. in case of charges for cross-border credit transfers.")], + "8": ["3", _("Detail of 3.")], +} -def repl_special(s): - s = s.replace("\'", "\'" + "'") - return s +transaction_codes = { + "00": [_("Undefined transactions"), { + "89": _("Cancellation of a transaction"), + "87": _("Costs refunded"), + "85": _("Correction"), + "83": _("Value correction"), + "39": _("Cancellation of a transaction"), + "37": _("Costs"), + "35": _("Correction"), + "33": _("Value correction"), + "00": _("Undefined transaction") + }], + "01": [_("Domestic or local SEPA credit transfers"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "66": _("Financial centralization"), + "64": _("Transfer to your account"), + "62": _("Unpaid postal order"), + "60": _("Non-presented circular cheque"), + "54": _("Unexecutable transfer order"), + "52": _("Payment in your favour"), + "51": _("Transfer in your favour – initiated by the bank"), + "50": _("Transfer in your favour"), + "49": _("Cancellation or correction"), + "39": _("Your issue circular cheque"), + "37": _("Costs"), + "17": _("Financial centralisation"), + "15": _("Balance due insurance premium"), + "13": _("Transfer from your account"), + "11": _("Your semi-standing order – payment to employees"), + "09": _("Your semi-standing order"), + "07": _("Collective transfer"), + "05": _("Payment of wages etc."), + "03": _("Standing order"), + "02": _("Individual transfer order initiated by the bank"), + "01": _("Individual transfer order]"), + }], + "03": [_("Cheques"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of cheque-related costs"), + "68": _("Credit of a payment via electronic purse"), + "66": _("Remittance of cheque by your branch - credit under usual reserve"), + "64": _("Reversal of settlement of credit card"), + "63": _("Second credit of unpaid cheque"), + "62": _("Reversal of cheque"), + "60": _("Reversal of voucher"), + "58": _("Remittance of cheques, vouchers, etc. credit after collection"), + "56": _("Non-presented certified cheques"), + "52": _("First credit of cheques, vouchers, luncheon vouchers, postal orders, credit under usual reserve"), + "50": _("Credit of a payment via terminal"), + "49": _("Cancellation or correction"), + "39": _("Provisionally unpaid due to other reason than manual presentation"), + "38": _("Provisionally unpaid"), + "37": _("Cheque-related costs"), + "35": _("Cash advance"), + "19": _("Settlement of credit cards"), + "17": _("Your certified cheque"), + "15": _("Your purchase bank cheque"), + "13": _("Eurocheque written out abroad"), + "11": _("Department store cheque"), + "09": _("Unpaid voucher"), + "07": _("Definitely unpaid cheque"), + "05": _("Payment of voucher"), + "03": _("Your purchase by payment card"), + "01": _("Payment of your cheque"), + }], + "04": [_("Cards"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "68": _("Credit after Proton payments"), + "55": _("Income from payments by GSM"), + "53": _("Cash deposit at an ATM"), + "52": _("Loading GSM cards"), + "51": _("Unloading Proton"), + "50": _("Credit after a payment at a terminal"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "08": _("Payment by means of a payment card outside the Eurozone"), + "07": _("Payment by GSM"), + "06": _("Payment with tank card"), + "05": _("Loading Proton"), + "04": _("Cash withdrawal from an ATM"), + "03": _("Settlement credit cards"), + "02": _("Payment by means of a payment card within the Eurozone"), + "01": _("Loading a GSM card"), + }], + "05": [_("Direct debit"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "58": _("Reversal"), + "56": _("Unexecutable reimbursement"), + "54": _("Reimbursement"), + "52": _("Credit under usual reserve"), + "50": _("Credit after collection"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "05": _("Reimbursement"), + "03": _("Unpaid debt"), + "01": _("Payment"), + }], + "07": [_("Domestic commercial paper"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "86": _("Payment after cession"), + "64": _("Warrant"), + "58": _("Remittance of supplier's bill without guarantee"), + "56": _("Remittance of supplier's bill with guarantee"), + "54": _("Remittance of commercial paper for discount"), + "52": _("Remittance of commercial paper - credit under usual reserve"), + "50": _("Remittance of commercial paper - credit after collection"), + "49": _("Cancellation or correction"), + "39": _("Return of an irregular bill of exchange"), + "37": _("Costs related to commercial paper"), + "14": _("Warrant fallen due"), + "12": _("Safe custody"), + "10": _("Renewal of agreed maturity date"), + "09": _("Agio on supplier's bill"), + "08": _("Payment in advance"), + "07": _("Unpaid commercial paper"), + "06": _("Extension of maturity date"), + "05": _("Commercial paper claimed back"), + "03": _("Payment receipt card"), + "01": _("Payment commercial paper"), + }], + "09": [_("Counter transactions"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Sale of traveller’s cheque"), + "68": _("Difference in payment"), + "66": _("Repurchase of petrol coupons"), + "64": _("Your winning lottery ticket"), + "62": _("Sale of gold/pieces under usual reserve"), + "60": _("Sale of foreign bank notes"), + "58": _("Payment by your branch/agents"), + "56": _("Reserve"), + "54": _("Your payment ATM"), + "52": _("Payment night safe"), + "50": _("Cash payment"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "25": _("Purchase of traveller’s cheque"), + "21": _("Cash withdrawal on card (PROTON)"), + "19": _("Difference in payment"), + "17": _("Purchase of fiscal stamps"), + "15": _("Your purchase of lottery tickets"), + "13": _("Cash withdrawal by your branch or agents"), + "11": _("Your purchase of luncheon vouchers"), + "09": _("Purchase of petrol coupons"), + "07": _("Purchase of gold/pieces"), + "05": _("Purchase of foreign bank notes"), + "03": _("Cash withdrawal by card (ATM)"), + "01": _("Cash withdrawal"), + }], + "11": [_("Securities"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Settlement of securities"), + "68": _("Compensation for missing coupon"), + "66": _("Retrocession of issue commission"), + "64": _("Your issue"), + "62": _("Interim interest on subscription"), + "58": _("Repayable securities from a deposit or delivered at the counter - credit under usual reserve"), + "56": _("Reserve"), + "52": _("Payment of coupons from a deposit or settlement of coupons delivered over the counter - credit under usual reserve"), + "51": _("Tender"), + "50": _("Sale of securities"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "19": _("Regularisation costs"), + "17": _("Management fee"), + "15": _("Interim interest on subscription"), + "13": _("Your repurchase of issue"), + "11": _("Payable coupons/repayable securities"), + "09": _("Settlement of securities"), + "06": _("Share option plan – exercising an option"), + "05": _("Partial payment subscription"), + "04": _("Issues"), + "03": _("Subscription to securities"), + "02": _("Tenders"), + "01": _("Purchase of securities"), + }], + "13": [_("Credit"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Settlement of discount bank acceptance"), + "68": _("Documentary export credits"), + "62": _("Term loan"), + "60": _("Settlement of mortgage loan"), + "56": _("Subsidy"), + "55": _("Fixed advance – interest only"), + "54": _("Fixed advance – capital and interest"), + "50": _("Settlement of instalment credit"), + "49": _("Cancellation or correction"), + "37": _("Credit-related costs"), + "21": _("Other credit applications"), + "19": _("Documentary import credits"), + "15": _("Your repayment hire-purchase and similar claims"), + "13": _("Settlement of bank acceptances"), + "11": _("Your repayment mortgage loan"), + "07": _("Your repayment instalment credits"), + "05": _("Settlement of fixed advance"), + "02": _("Long-term loan"), + "01": _("Short-term loan"), + }], + "30": [_("Various transactions"), { + "99": _("Cancellation or correction"), + "89": _("Undefined transaction"), + "87": _("Reimbursement of costs"), + "83": _("Value (date) correction"), + "55": _("Interest term investment"), + "54": _("Capital and/or interest term investment"), + "52": _("Forward sale of foreign exchange"), + "50": _("Spot sale of foreign exchange"), + "49": _("Cancellation or correction"), + "39": _("Undefined transaction"), + "37": _("Costs"), + "33": _("Value (date) correction"), + "05": _("Capital and/or interest term investment"), + "03": _("Forward purchase of foreign exchange"), + "01": _("Spot purchase of foreign exchange"), + }], + "35": [_("Closing (periodical settlements for interest, costs,…)"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "50": _("Closing"), + "49": _("Cancellation or correction"), + "37": _("Costs"), + "01": _("Closing"), + }], + "41": [_("International credit transfers - non-SEPA credit transfers"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "66": _("Financial centralisation (credit)"), + "64": _("Transfer to your account"), + "50": _("Transfer"), + "49": _("Cancellation or correction"), + "38": _("Costs relating to incoming foreign and non-SEPA transfers"), + "37": _("Costs relating to outgoing foreign transfers and non-SEPA transfers"), + "17": _("Financial centralisation (debit)"), + "13": _("Transfer from your account"), + "07": _("Collective transfers"), + "05": _("Collective payments of wages"), + "03": _("Standing order"), + "01": _("Transfer"), + }], + "43": [_("Foreign cheques"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "70": _("Purchase of traveller’s cheque"), + "62": _("Reversal of cheques"), + "58": _("Remittance of foreign cheque credit after collection"), + "52": _("Remittance of foreign cheque credit under usual reserve"), + "49": _("Cancellation or correction"), + "37": _("Costs relating to payment of foreign cheques"), + "15": _("Purchase of an international bank cheque"), + "07": _("Unpaid foreign cheque"), + "01": _("Payment of a foreign cheque"), + }], + "47": [_("Foreign commercial paper"), { + "99": _("Cancellation or correction"), + "87": _("Reimbursement of costs"), + "64": _("Warrant"), + "62": _("Remittance of documents abroad - credit after collection"), + "60": _("Remittance of documents abroad - credit under usual reserve"), + "58": _("Idem without guarantee"), + "56": _("Remittance of guaranteed foreign supplier's bill"), + "54": _("Discount abroad"), + "52": _("Remittance of foreign bill credit under usual reserve"), + "50": _("Remittance of foreign bill credit after collection"), + "49": _("Cancellation or correction"), + "37": _("Costs relating to the payment of a foreign bill"), + "14": _("Warrant fallen due"), + "13": _("Discount foreign supplier's bills"), + "11": _("Payment documents abroad"), + "07": _("Unpaid foreign bill"), + "06": _("Extension"), + "05": _("Bill claimed back"), + "01": _("Payment of foreign bill"), + }], + "49": [_("Foreign counter transactions"), {"03": _("ATM withdrawal")}], + "80": [_("Separately charged costs and provisions"), { + "01": _("Guarantee card charges"), + "02": _("Costs relating to electronic output"), + "03": _("Payment card charges"), + "04": _("Costs for holding a documentary cash credit"), + "05": _("Card charges"), + "06": _("Damage relating to bills and cheques"), + "07": _("Insurance costs"), + "08": _("Registering compensation for savings accounts"), + "09": _("Postage"), + "10": _("Purchase of Smartcard"), + "11": _("Costs for the safe custody of correspondence"), + "12": _("Costs for opening a bank guarantee"), + "13": _("Renting of safes"), + "14": _("Handling costs instalment credit"), + "15": _("Night safe"), + "16": _("Bank confirmation to revisor or accountant"), + "17": _("Charge for safe custody"), + "18": _("Trade information"), + "19": _("Special charge for safe custody"), + "20": _("Drawing up a certificate"), + "21": _("Pay-packet charges"), + "22": _("Management/custody"), + "23": _("Research costs"), + "24": _("Participation in and management of interest refund system"), + "25": _("Renting of direct debit box"), + "26": _("Travel insurance premium"), + "27": _("Subscription fee"), + "29": _("Information charges"), + "31": _("Writ service fee"), + "33": _("Miscellaneous fees and commissions"), + "35": _("Costs"), + "37": _("Access right to database"), + "39": _("Surety fee"), + "41": _("Research costs"), + "43": _("Printing of forms"), + "45": _("Documentary credit charges"), + "47": _("Charging fees for transactions"), + "49": _("Cancellation or correction"), + "99": _("Cancellation or correction"), + }], +} + +transaction_categories = { + "000": _("Net amount"), + "001": _("Interest received"), + "002": _("Interest paid"), + "003": _("Credit commission"), + "004": _("Postage"), + "005": _("Renting of letterbox"), + "006": _("Various fees/commissions"), + "007": _("Access right to database"), + "008": _("Information charges"), + "009": _("Travelling expenses"), + "010": _("Writ service fee"), + "011": _("VAT"), + "012": _("Exchange commission"), + "013": _("Payment commission"), + "014": _("Collection commission"), + "015": _("Correspondent charges"), + "016": _("BLIW/IBLC dues"), + "017": _("Research costs"), + "018": _("Tental guarantee charges"), + "019": _("Tax on physical delivery"), + "020": _("Costs of physical delivery"), + "021": _("Costs for drawing up a bank cheque"), + "022": _("Priority costs"), + "023": _("Exercising fee"), + "024": _("Growth premium"), + "025": _("Individual entry for exchange charges"), + "026": _("Handling commission"), + "027": _("Charges for unpaid bills"), + "028": _("Fidelity premium"), + "029": _("Protest charges"), + "030": _("Account insurance"), + "031": _("Charges foreign cheque"), + "032": _("Drawing up a circular cheque"), + "033": _("Charges for a foreign bill"), + "034": _("Reinvestment fee"), + "035": _("Charges foreign documentary bill"), + "036": _("Costs relating to a refused cheque"), + "037": _("Commission for handling charges"), + "039": _("Telecommunications"), + "041": _("Credit card costs"), + "042": _("Payment card costs"), + "043": _("Insurance costs"), + "045": _("Handling costs"), + "047": _("Charges extension bill"), + "049": _("Fiscal stamps/stamp duty"), + "050": _("Capital term investment"), + "051": _("Withholding tax"), + "052": _("Residence state tax"), + "053": _("Printing of forms"), + "055": _("Repayment loan or credit capital"), + "057": _("Interest subsidy"), + "058": _("Capital premium"), + "059": _("Default interest"), + "061": _("Charging fees for transactions"), + "063": _("Rounding differences"), + "065": _("Interest payment advice"), + "066": _("Fixed loan advance - reimbursement"), + "067": _("Fixed loan advance - extension"), + "068": _("Countervalue of an entry"), + "069": _("Forward arbitrage contracts : sum to be supplied by customer"), + "070": _("Forward arbitrage contracts : sum to be supplied by bank"), + "071": _("Fixed loan advance - availability"), + "072": _("Countervalue of commission to third party"), + "073": _("Costs of ATM abroad"), + "074": _("Mailing costs"), + "100": _("Gross amount"), + "200": _("Overall documentary credit charges"), + "201": _("Advice notice commission"), + "202": _("Advising commission | Additional advising commission"), + "203": _("Confirmation fee | Additional confirmation fee | Commitment fee | Flat fee | Confirmation reservation commission | Additional reservation commission"), + "204": _("Amendment fee"), + "205": _("Documentary payment commission | Document commission | Drawdown fee | Negotiation fee"), + "206": _("Surety fee/payment under reserve"), + "207": _("Non-conformity fee"), + "208": _("Commitment fee deferred payment"), + "209": _("Transfer commission"), + "210": _("Commitment fee"), + "211": _("Credit arrangement fee | Additional credit arrangement fee"), + "212": _("Warehousing fee"), + "213": _("Financing fee"), + "214": _("Issue commission (delivery order)"), + "400": _("Acceptance fee"), + "401": _("Visa charges"), + "402": _("Certification costs"), + "403": _("Minimum discount rate"), + "404": _("Discount commission"), + "405": _("Bill guarantee commission"), + "406": _("Collection charges"), + "407": _("Costs Article 45"), + "408": _("Cover commission"), + "409": _("Safe deposit charges"), + "410": _("Reclamation charges"), + "411": _("Fixed collection charge"), + "412": _("Advice of expiry charges"), + "413": _("Acceptance charges"), + "414": _("Regularisation charges"), + "415": _("Surety fee"), + "416": _("Charges for the deposit of security"), + "418": _("Endorsement commission"), + "419": _("Bank service fee"), + "420": _("Retention charges"), + "425": _("Foreign broker's commission"), + "426": _("Belgian broker's commission"), + "427": _("Belgian Stock Exchange tax"), + "428": _("Interest accrued"), + "429": _("Foreign Stock Exchange tax"), + "430": _("Recovery of foreign tax"), + "431": _("Delivery of a copy"), +} -def str2date(date_str): - try: - return time.strftime('%Y-%m-%d', time.strptime(date_str, '%d%m%y')) - except: - return False +def rmspaces(s): + return " ".join(s.split()) -def str2time(time_str): - return time_str[:2] + ':' + time_str[2:] - -def str2float(str): - try: - return float(str) - except: - return 0.0 - - -def list2float(lst): - try: - return str2float((lambda s: s[:-3] + '.' + s[-3:])(lst)) - except: - return 0.0 - - -def number2float(s, d): - try: - return float(s[:len(s) - d] + '.' + s[len(s) - d:]) - except: - return False - - -def _get_acc_numbers(acc_number): - #TODO this method is needed because the iban and bank account fields have been merged together. But sometimes we - # need to retrieve the normal bank account from the IBAN. This should be globalized and defined as a method on the - # bank account class. Each country part of the IBAN area should define its own code to do so. - acc_number = acc_number.replace(' ', '') - if acc_number.lower().startswith('be'): - return [acc_number[4:], acc_number] - return [acc_number] - -from base_iban.base_iban import _ref_iban, _format_iban - - -def calc_iban_checksum(country, bban): - bban = bban.replace(' ', '').upper() + country.upper() + '00' - base = '' - for c in bban: - if c.isdigit(): - base += c - else: - base += str(ord(c) - ord('A') + 10) - kk = 98 - int(base) % 97 - return str(kk).rjust(2, '0') - - -def check_bban(country, bban): - if country == 'BE': - try: - int(bban) - except: - return False - if len(bban) != 12: - return False - return True - - -def check_iban(iban): - """ - Check the IBAN number (logic partially based upon base_iban module, cf. is_iban_valid method) - """ - iban = _format_iban(iban).lower() - if iban[:2] not in _ref_iban: - return False - if len(iban) != len(_format_iban(_ref_iban[iban[:2]])): - return False - #the four first digits have to be shifted to the end - iban = iban[4:] + iban[:4] - #letters have to be transformed into numbers (a = 10, b = 11, ...) - iban2 = "" - for char in iban: - if char.isalpha(): - iban2 += str(ord(char) - 87) - else: - iban2 += char - #iban is correct if modulo 97 == 1 - return int(iban2) % 97 == 1 - - -def get_bank(self, cr, uid, bic, iban): - - country_obj = self.pool.get('res.country') - bank_obj = self.pool.get('res.bank') - - bank_id = False - bank_name = False - feedback = False - bank_country = iban[:2] - try: - bank_country_id = country_obj.search(cr, uid, [('code', '=', bank_country)])[0] - except: - feedback = _("\n Bank lookup failed due to missing Country definition for Country Code '%s' !") \ - % (bank_country) - else: - if iban[:2] == 'BE' and 'code' in bank_obj.fields_get_keys(cr, uid): - # To DO : extend for other countries - bank_code = iban[4:7] - if bic: - bank_ids = bank_obj.search(cr, uid, [('bic', '=', bic), ('code', '=', bank_code), ('country', '=', bank_country_id)]) - if bank_ids: - bank_id = bank_ids[0] - else: - bank_id = bank_obj.create(cr, uid, { - 'name': bic, - 'code': bank_code, - 'bic': bic, - 'country': bank_country_id, - }) - else: - bank_ids = bank_obj.search(cr, uid, [('code', '=', bank_code), ('country', '=', bank_country_id)]) - if bank_ids: - bank_id = bank_ids[0] - bank_data = bank_obj.read(cr, uid, bank_id, fields=['bic', 'name']) - bic = bank_data['bic'] - bank_name = bank_data['name'] - else: - country = country_obj.browse(cr, uid, bank_country_id) - feedback = _("\n Bank lookup failed. Please define a Bank with Code '%s' and Country '%s' !") \ - % (bank_code, country.name) - else: - if not bic: - feedback = _("\n Bank lookup failed due to missing BIC in Bank Statement for IBAN '%s' !") \ - % (iban) - else: - bank_ids = bank_obj.search(cr, uid, [('bic', '=', bic), ('country', '=', bank_country_id)]) - if not bank_ids: - bank_name = bic - bank_id = bank_obj.create(cr, uid, { - 'name': bank_name, - 'bic': bic, - 'country': bank_country_id, - }) - else: - bank_id = bank_ids[0] - - return bank_id, bic, bank_name, feedback - - -def update_partner_bank(self, cr, uid, bic, iban, partner_id, counterparty_name): - partner_bank_obj = self.pool.get('res.partner.bank') - bank_id = False - feedback = False - if check_iban(iban): - bank_id, bic, bank_name, feedback = get_bank(self, cr, uid, bic, iban) - if not bank_id: - return feedback - else: - #convert belgian BBAN numbers to IBAN - if check_bban('BE', iban): - kk = calc_iban_checksum('BE', iban) - iban = 'BE' + kk + iban - bank_id, bic, bank_name, feedback = get_bank(self, cr, uid, bic, iban) - if not bank_id: - return feedback - - if bank_id: - partner_bank_obj.create(cr, uid, { - 'partner_id': partner_id, - 'name': counterparty_name, - 'bank': bank_id, - 'state': 'iban', - 'bank_bic': bic, - 'bank_name': bank_name, - 'acc_number': iban, - }) - return feedback - -indent = '\n' + 8 * ' ' -st_line_name_families = ['13', '35', '41', '80'] -parse_comms_move = ['100', '101', '102', '103', '105', '106', '107', '108', '111', '113', '114', '115', '121', '122', '123', '124', '125', '126', '127'] -parse_comms_info = ['001', '002', '004', '005', '006', '007', '107', '008', '009', '010', '011'] - - -def get_st_line_name(line, context): - #_logger.warn('get_st_line_name - entry').warn('ref = %s, family = %s, code = %s, categ = %s', line['ref'], line['trans_family'], line['trans_code'], line['trans_category']) - st_line_name = line['name'] - - if line['trans_family'] == '35' and line['trans_code'] in ['01', '37']: - st_line_name = ', '.join([_('Closing'), line['trans_code_desc'], line['trans_category_desc']]) - - if line['trans_family'] in ['13', '41']: - st_line_name = ', '.join([line['trans_family_desc'], line['trans_code_desc'], line['trans_category_desc']]) - - if line['trans_family'] in ['80']: - st_line_name = ', '.join([line['trans_code_desc'], line['trans_category_desc']]) - - return st_line_name - - -def parse_comm_move(self, cr, uid, line, comm_type_table, context): - #_logger.warn('parse_comm_move - entry, ref = %s, family = %s, code = %s, categ = %s, comm_type = %s, name = %s', line['ref'], line['trans_family'], line['trans_code'], line['trans_category'], line['struct_comm_type'], line['name']) - comm_type = line['struct_comm_type'] - comm = st_line_comm = line['communication'] - st_line_name = line['name'] - - if comm_type in ['115', '121', '122', '126']: - _logger.warn('The parsing of Structured Commmunication Type %s has not yet been implemented. ' \ - 'Please contact Noviat (info@noviat.be) for more information about the development roadmap', comm_type) - - if comm_type == '100': - st_line_name = _('Payment with ISO 11649 structured format communication') - st_line_comm = '\n' + indent + _('Payment with a structured format communication applying the ISO standard 11649') + ':' - st_line_comm += indent + _('Structured creditor reference to remittance information') - st_line_comm += indent + comm - - if comm_type in ['101', '102']: - st_line_name = st_line_comm = '+++' + comm[0:3] + '/' + comm[3:7] + '/' + comm[7:12] + '+++' - - if comm_type == '103': - st_line_name = ', '.join([line['trans_family_desc'], _('Number')]) - st_line_comm = comm - - if comm_type == '105': - st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] - amount_1 = list2float(comm[0:15]) - amount_2 = list2float(comm[15:30]) - rate = number2float(comm[30:42], 8) - currency = comm[42:45] - struct_format_comm = comm[45:57].strip() - country_code = comm[57:59] - amount_3 = list2float(comm[59:74]) - st_line_comm = '\n' + indent + st_line_name + indent + _('Gross amount in the currency of the account') + ': %.2f' % amount_1 - st_line_comm += indent + _('Gross amount in the original currency') + ': %.2f' % amount_2 - st_line_comm += indent + _('Rate') + ': %.4f' % rate - st_line_comm += indent + _('Currency') + ': %s' % currency - st_line_comm += indent + _('Structured format communication') + ': %s' % struct_format_comm - st_line_comm += indent + _('Country code of the principal') + ': %s' % country_code - st_line_comm += indent + _('Equivalent in EUR') + ': %.2f' % amount_3 - - if comm_type == '106': - if not st_line_name and line['trans_family'] not in st_line_name_families: - st_line_name = _('VAT, withholding tax on income, commission, etc.') - interest = comm[30:42].strip('0') - st_line_comm = '\n' + indent + st_line_name + indent + _('Equivalent in the currency of the account') + ': %.2f' % list2float(comm[0:15]) - st_line_comm += indent + _('Amount on which % is calculated') + ': %.2f' % list2float(comm[15:30]) - st_line_comm += indent + _('Percent') + ': %.4f' % number2float(comm[30:42], 8) - st_line_comm += indent + (comm[42] == 1 and _('Minimum applicable') or _('Minimum not applicable')) - st_line_comm += indent + _('Equivalent in EUR') + ': %.2f' % list2float(comm[43:58]) - - if comm_type == '107': - paid_refusals = { - '0': _('paid'), - '1': _('direct debit cancelled or nonexistent'), - '2': _('refusal - other reason'), - 'D': _('payer disagrees'), - 'E': _('direct debit number linked to another identification number of the creditor')} - st_line_name = _('Direct debit - DOM\'80') - direct_debit_number = comm[0:12].strip() - pivot_date = str2date(comm[12:18]) - comm_zone = comm[18:48] - paid_refusal = paid_refusals.get(comm[48], '') - creditor_number = comm[49:60].strip() - st_line_comm = '\n' + indent + st_line_name + indent + _('Direct Debit Number') + ': %s' % direct_debit_number - st_line_comm += indent + _('Central (Pivot) Date') + ': %s' % pivot_date - st_line_comm += indent + _('Communication Zone') + ': %s' % comm_zone - st_line_comm += indent + _('Paid or reason for refusal') + ': %s' % paid_refusal - st_line_comm += indent + _("Creditor's Number") + ': %s' % creditor_number - - if comm_type == '108': - st_line_name = _('Closing, period from %s to %s') % (str2date(comm[42:48]), str2date(comm[48:54])) - interest = comm[30:42].strip('0') - st_line_comm = '\n' + indent + st_line_name + indent + _('Equivalent in the currency of the account') + ': %.2f' % list2float(comm[0:15]) - if interest: - st_line_comm += indent + _('Interest rates, calculation basis') + ': %.2f' % list2float(comm[15:30]) + \ - indent + _('Interest') + ': %.2f' % list2float(comm[30:42]) - - if comm_type == '111': - card_schemes = { - '1': 'Bancontact/Mister Cash', - '2': _('Private'), - '3': 'Maestro', - '5': 'TINA', - '9': _('Other')} - trans_types = { - '1': _('Withdrawal'), - '2': _('Cumulative on network'), - '7': _('Distribution sector'), - '8': _('Teledata'), - '9': _('Fuel')} - st_line_name = _('POS credit - globalisation') - card_scheme = card_schemes.get(comm[0], '') - pos_number = comm[1:7].strip() - period_number = comm[7:10].strip() - first_sequence_number = comm[10:16].strip() - trans_first_date = str2date(comm[16:22]) - last_sequence_number = comm[22:28].strip() - trans_last_date = str2date(comm[28:34]) - trans_type = trans_types.get(comm[34], '') - terminal_name = comm[35:50].strip() - terminal_city = comm[51:60].strip() - st_line_comm = '\n' + indent + st_line_name + indent + _('Card Scheme') + ': %s' % card_scheme - st_line_comm += indent + _('POS Number') + ': %s' % pos_number - st_line_comm += indent + _('Period Number') + ': %s' % period_number - st_line_comm += indent + _('First Transaction Sequence Number') + ': %s' % first_sequence_number - st_line_comm += indent + _('Date of first transaction') + ': %s' % trans_first_date - st_line_comm += indent + _('Last Transaction Sequence Number') + ': %s' % last_sequence_number - st_line_comm += indent + _('Date of last transaction') + ': %s' % trans_last_date - st_line_comm += indent + _('Transaction Type') + ': %s' % trans_type - st_line_comm += indent + _('Terminal Identification') + ': %s' % terminal_name + ', ' + terminal_city - - if comm_type == '113': - card_schemes = { - '1': 'Bancontact/Mister Cash', - '2': 'Maestro', - '3': _('Private'), - '9': _('Other')} - trans_types = { - '1': _('Withdrawal'), - '2': _('Proton loading'), - '3': _('Reimbursement Proton balance'), - '4': _('Reversal of purchases'), - '7': _('Distribution sector'), - '8': _('Teledata'), - '9': _('Fuel')} - product_codes = { - '01': _('premium with lead substitute'), - '02': _('europremium'), - '03': _('diesel'), - '04': _('LPG'), - '06': _('premium plus 98 oct'), - '07': _('regular unleaded'), - '08': _('domestic fuel oil'), - '09': _('lubricants'), - '10': _('petrol'), - '11': _('premium 99+'), - '12': _('Avgas'), - '16': _('other types'), - } - st_line_name = _('ATM/POS debit') - card_number = comm[0:16].strip() - card_scheme = card_schemes.get(comm[16], '') - terminal_number = comm[17:23].strip() - sequence_number = comm[23:29].strip() - trans_date = comm[29:35].strip() and str2date(comm[29:35]) or '' - trans_hour = comm[35:39].strip() and str2time(comm[35:39]) or '' - trans_type = trans_types.get(comm[39], '') - terminal_name = comm[40:56].strip() - terminal_city = comm[56:66].strip() - orig_amount = comm[66:81].strip() and list2float(comm[66:81]) - rate = number2float(comm[81:93], 8) - currency = comm[93:96] - volume = number2float(comm[96:101], 2) - product_code = product_codes.get(comm[101:103], '') - unit_price = number2float(comm[103:108], 2) - st_line_comm = '\n' + indent + st_line_name + indent + _('Card Number') + ': %s' % card_number - st_line_comm += indent + _('Card Scheme') + ': %s' % card_scheme - if terminal_number: - st_line_comm += indent + _('Terminal Number') + ': %s' % terminal_number - st_line_comm += indent + _('Transaction Sequence Number') + ': %s' % sequence_number - st_line_comm += indent + _('Time') + ': %s' % trans_date + ' ' + trans_hour - st_line_comm += indent + _('Transaction Type') + ': %s' % trans_type - st_line_comm += indent + _('Terminal Identification') + ': %s' % terminal_name + ', ' + terminal_city - if orig_amount: - st_line_comm += indent + _('Original Amount') + ': %.2f' % orig_amount - st_line_comm += indent + _('Rate') + ': %.4f' % rate - st_line_comm += indent + _('Currency') + ': %s' % currency - if volume: - st_line_comm += indent + _('Volume') + ': %.2f' % volume - if product_code: - st_line_comm += indent + _('Product Code') + ': %s' % product_code - if unit_price: - st_line_comm += indent + _('Unit Price') + ': %.2f' % unit_price - - if comm_type == '114': - card_schemes = { - '1': 'Bancontact/Mister Cash', - '2': 'Maestro', - '3': _('Private'), - '5': 'TINA', - '9': _('Other')} - trans_types = { - '1': _('Withdrawal'), - '7': _('Distribution sector'), - '8': _('Teledata'), - '9': _('Fuel')} - st_line_name = _('POS credit - individual transaction') - card_scheme = card_schemes.get(comm[0], '') - pos_number = comm[1:7].strip() - period_number = comm[7:10].strip() - sequence_number = comm[10:16].strip() - trans_date = str2date(comm[16:22]) - trans_hour = str2time(comm[22:26]) - trans_type = trans_types.get(comm[26], '') - terminal_name = comm[27:43].strip() - terminal_city = comm[43:53].strip() - trans_reference = comm[53:69].strip() - st_line_comm = '\n' + indent + st_line_name + indent + _('Card Scheme') + ': %s' % card_scheme - st_line_comm += indent + _('POS Number') + ': %s' % pos_number - st_line_comm += indent + _('Period Number') + ': %s' % period_number - st_line_comm += indent + _('Transaction Sequence Number') + ': %s' % sequence_number - st_line_comm += indent + _('Time') + ': %s' % trans_date + ' ' + trans_hour - st_line_comm += indent + _('Transaction Type') + ': %s' % trans_type - st_line_comm += indent + _('Terminal Identification') + ': %s' % terminal_name + ', ' + terminal_city - st_line_comm += indent + _('Transaction Reference') + ': %s' % trans_reference - - if comm_type == '123': - starting_date = str2date(comm[0:6]) - maturity_date = comm[6:12] == '999999' and _('guarantee without fixed term') or str2date(comm[0:6]) - basic_amount = list2float(comm[12:27]) - percent = number2float(comm[27:39], 8) - term = comm[39:43].lstrip('0') - minimum = comm[43] == '1' and True or False - guarantee_number = comm[44:57].strip() - st_line_comm = '\n' + indent + st_line_name + indent + _('Starting Date') + ': %s' % starting_date - st_line_comm += indent + _('Maturity Date') + ': %s' % maturity_date - st_line_comm += indent + _('Basic Amount') + ': %.2f' % basic_amount - st_line_comm += indent + _('Percentage') + ': %.4f' % percent - st_line_comm += indent + _('Term in days') + ': %s' % term - st_line_comm += indent + (minimum and _('Minimum applicable') or _('Minimum not applicable')) - st_line_comm += indent + _('Guarantee Number') + ': %s' % guarantee_number - - if comm_type == '124': - card_issuers = { - '1': 'Mastercard', - '2': 'Visa', - '3': 'American Express', - '4': 'Diners Club', - '9': _('Other')} - st_line_name = _('Settlement credit cards') - card_number = comm[0:20].strip() - card_issuer = card_issuers.get(comm[20], '') - invoice_number = comm[21:33].strip() - identification_number = comm[33:48].strip() - date = comm[48:54].strip() and str2date(comm[48:54]) or '' - st_line_comm = '\n' + indent + st_line_name + indent + _('Card Number') + ': %s' % card_number - st_line_comm += indent + _('Issuing Institution') + ': %s' % card_issuer - st_line_comm += indent + _('Invoice Number') + ': %s' % invoice_number - st_line_comm += indent + _('Identification Number') + ': %s' % identification_number - st_line_comm += indent + _('Date') + ': %s' % date - - if comm_type == '125': - if line['trans_family'] not in st_line_name_families: - st_line_name = _('Credit') - credit_account = comm[0:27].strip() - if check_bban('BE', credit_account): - credit_account = '-'.join([credit_account[:3], credit_account[3:10], credit_account[10:]]) - old_balance = list2float(comm[27:42]) - new_balance = list2float(comm[42:57]) - amount = list2float(comm[57:72]) - currency = comm[72:75] - start_date = str2date(comm[75:81]) - end_date = str2date(comm[81:87]) - rate = number2float(comm[87:99], 8) - trans_reference = comm[99:112].strip() - st_line_comm = '\n' + indent + st_line_name + indent + _('Credit Account Number') + ': %s' % credit_account - st_line_comm += indent + _('Old Balance') + ': %.2f' % old_balance - st_line_comm += indent + _('New Balance') + ': %.2f' % new_balance - st_line_comm += indent + _('Amount') + ': %.2f' % amount - st_line_comm += indent + _('Currency') + ': %s' % currency - st_line_comm += indent + _('Starting Date') + ': %s' % start_date - st_line_comm += indent + _('End Date') + ': %s' % end_date - st_line_comm += indent + _('Nominal Interest Rate or Rate of Charge') + ': %.4f' % rate - st_line_comm += indent + _('Transaction Reference') + ': %s' % trans_reference - - if comm_type == '127': - direct_debit_types = { - '0': _('unspecified'), - '1': _('recurrent'), - '2': _('one-off'), - '3': _('1-st (recurrent)'), - '4': _('last (recurrent)')} - direct_debit_schemes = { - '0': _('unspecified'), - '1': _('SEPA core'), - '2': _('SEPA B2B')} - paid_refusals = { - '0': _('paid'), - '1': _('technical problem'), - '2': _('refusal - reason not specified'), - '3': _('debtor disagrees'), - '4': _('debtor\'s account problem')} - R_types = { - '0': _('paid'), - '1': _('reject'), - '2': _('return'), - '3': _('refund'), - '4': _('reversal'), - '5': _('cancellation')} - st_line_name = _('European direct debit (SEPA)') - settlement_date = str2date(comm[0:6]) - direct_debit_type = direct_debit_types.get(comm[6], '') - direct_debit_scheme = direct_debit_schemes.get(comm[7], '') - paid_refusal = paid_refusals.get(comm[8], '') - creditor_id = comm[9:44].strip() - mandate_ref = comm[44:79].strip() - comm_zone = comm[79:141] - R_type = R_types.get(comm[141], '') - reason = comm[142:146].strip() - st_line_comm = '\n' + indent + st_line_name + indent + _('Settlement_Date') + ': %s' % settlement_date - st_line_comm += indent + _('Direct Debit Type') + ': %s' % direct_debit_type - st_line_comm += indent + _('Direct Debit Scheme') + ': %s' % direct_debit_scheme - st_line_comm += indent + _('Paid or reason for refusal') + ': %s' % paid_refusal - st_line_comm += indent + _('Creditor\'s Identification Code') + ': %s' % creditor_id - st_line_comm += indent + _('Mandate Reference') + ': %s' % mandate_ref - st_line_comm += indent + _('Communication') + ': %s' % comm_zone - st_line_comm += indent + _('R transaction Type') + ': %s' % R_type - st_line_comm += indent + _('Reason') + ': %s' % reason - - return st_line_name, st_line_comm - - -def parse_comm_info(self, cr, uid, line, comm_type_table, context): - comm_type = line['struct_comm_type'] - comm = st_line_comm = line['communication'] - st_line_name = line['name'] - - if comm_type == '001': - st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] - st_line_comm = '\n' + indent + st_line_name + indent + _('Name') + ': %s' % comm[0:70].strip() - st_line_comm += indent + _('Street') + ': %s' % comm[70:105].strip() - st_line_comm += indent + _('Locality') + ': %s' % comm[105:140].strip() - st_line_comm += indent + _('Identification Code') + ': %s' % comm[140:175].strip() - - if comm_type in ['002', '004', '005']: - st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] - st_line_comm = comm.strip() - - if comm_type == '006': - amount = (comm[48] == '1' and '-' or '') + ('%.2f' % list2float(comm[33:48])) + ' ' + comm[30:33] - st_line_name = filter(lambda x: comm_type == x['code'], comm_type_table)[0]['description'] - st_line_comm = '\n' + indent + st_line_name + indent + _('Description of the detail') + ': %s' % comm[0:30].strip() - st_line_comm += indent + _('Amount') + ': %s' % amount - st_line_comm += indent + _('Category') + ': %s' % comm[49:52].strip() - - if comm_type not in ['001', '002', '004', '005', '006']: - _logger.warn('The parsing of Structured Commmunication Type %s has not yet been implemented. ' \ - 'Please contact Noviat (info@noviat.be) for more information about the development roadmap', comm_type) - - return st_line_name, st_line_comm # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/wizard/account_coda_import_dle.py b/addons/l10n_be_coda/wizard/account_coda_import_dle.py deleted file mode 100644 index 432008fa58e..00000000000 --- a/addons/l10n_be_coda/wizard/account_coda_import_dle.py +++ /dev/null @@ -1,740 +0,0 @@ -# -*- encoding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Noviat nv/sa (www.noviat.be). All rights reserved. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## - -import base64 -from osv import fields, osv -from tools.translate import _ -import time -import tools -import logging -_logger = logging.getLogger(__name__) - - -class account_coda_import(osv.osv_memory): - _name = 'account.coda.import' - _description = 'Import CODA File' - _columns = { - 'coda_data': fields.binary('CODA File', required=True), - 'coda_fname': fields.char('CODA Filename', size=128, required=True), - 'note': fields.text('Log'), - } - _defaults = { - 'coda_fname': lambda *a: '', - } - - def coda_parsing(self, cr, uid, ids, context=None, batch=False, codafile=None, codafilename=None): - if context is None: - context = {} - if batch: - print - codafile = str(codafile) - codafilename = codafilename - else: - data = self.browse(cr, uid, ids)[0] - try: - codafile = data.coda_data - codafilename = data.coda_fname - except: - raise osv.except_osv(_('Error!'), _('Wizard in incorrect state. Please hit the Cancel button!')) - return {} - recordlist = unicode(base64.decodestring(codafile), 'windows-1252', 'strict').split('\n') - statements = [] - for line in recordlist: - if not line: - pass - elif line[0] == '0': - #Begin of a new Bank statement - statement = {} - statements.append(statement) - statement['version'] = line[127] - if statement['version'] not in ['1', '2']: - raise osv.except_osv(_('Error R001!'), _('CODA V%s statements are not supported, please contact your bank!') % statement['version']) - statement['globalisation_stack'] = [] - statement['lines'] = [] - statement['date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[5:11]), '%d%m%y')) - statement['separateApplication'] = rmspaces(line[83:88]) - elif line[0] == '1': - #Statement details - if statement['version'] == '1': - statement['accountNumber'] = rmspaces(line[5:17]) - statement['currency'] = rmspaces(line[18:21]) - elif statement['version'] == '2': - if line[1] == '0': # Belgian bank account BBAN structure - statement['accountNumber'] = rmspaces(line[5:17]) - statement['currency'] = rmspaces(line[18:21]) - elif line[1] == '1': # foreign bank account BBAN structure - raise osv.except_osv(_('Error R1001!'), _('Foreign bank accounts with BBAN structure are not supported !')) - elif line[1] == '2': # Belgian bank account IBAN structure - statement['accountNumber'] = rmspaces(line[5:21]) - statement['currency'] = rmspaces(line[39:42]) - elif line[1] == '3': # foreign bank account IBAN structure - raise osv.except_osv(_('Error R1002!'), _('Foreign bank accounts with IBAN structure are not supported !')) - else: # Something else, not supported - raise osv.except_osv(_('Error R1003!'), _('\nUnsupported bank account structure !')) - statement['description'] = rmspaces(line[90:125]) - statement['balance_start'] = float(rmspaces(line[43:58])) / 1000 - statement['balance_start_date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[58:64]), '%d%m%y')) - statement['accountHolder'] = rmspaces(line[64:90]) - statement['paperSeqNumber'] = rmspaces(line[2:5]) - statement['codaSeqNumber'] = rmspaces(line[125:128]) - elif line[0] == '2': - if line[1] == '1': - #New statement line - statementLine = {} - statementLine['type'] = 'general' - statementLine['ref'] = rmspaces(line[2:10]) - statementLine['ref_move'] = rmspaces(line[2:6]) - statementLine['ref_move_detail'] = rmspaces(line[6:10]) - statementLine['sequence'] = len(statement['lines']) + 1 - statementLine['transactionRef'] = rmspaces(line[10:31]) - statementLine['debit'] = line[31] # 0 = Credit, 1 = Debit - statementLine['amount'] = float(rmspaces(line[32:47])) / 1000 - if statementLine['debit'] == '1': - statementLine['amount'] = - statementLine['amount'] - statementLine['transaction_type'] = line[53] - if statementLine['transaction_type'] not in transaction_types: - raise osv.except_osv(_('Error R2001!'), _('The File contains an invalid CODA Transaction Type : %s!') % statementLine['transaction_type']) - statementLine['transactionDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[47:53]), '%d%m%y')) - statementLine['transaction_family'] = rmspaces(line[54:56]) - #TODO Handling severals transactions Family - statementLine['transaction_code'] = rmspaces(line[56:58]) - #TODO Handling severals transactions code - statementLine['transaction_category'] = rmspaces(line[58:61]) - #TODO Handling severals transactions category - statementLine['communication'] = rmspaces(line[62:115]) - #TODO Handling structured communication - statementLine['entryDate'] = rmspaces(line[115:121]) - statementLine['type'] = 'normal' - statementLine['globalisation'] = int(line[124]) - if len(statement['globalisation_stack']) > 0: - statementLine['communication'] = "\n".join([statement['globalisation_stack'][-1]['communication'], statementLine['communication']]) - if statementLine['globalisation'] > 0: - if len(statement['globalisation_stack']) > 0 and statement['globalisation_stack'][-1]['globalisation'] == statementLine['globalisation']: - # Destack - statement['globalisation_stack'].pop() - else: - #Stack - statementLine['type'] = 'globalisation' - statement['globalisation_stack'].append(statementLine) - statement['lines'].append(statementLine) - elif line[1] == '2': - if statement['lines'][-1]['ref'][0:4] != line[2:6]: - raise osv.except_osv(_('Error R2004!'), _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) - statement['lines'][-1]['communication'] += rmspaces(line[10:63]) - statement['lines'][-1]['payment_reference'] = rmspaces(line[63:98]) - statement['lines'][-1]['counterparty_bic'] = rmspaces(line[98:109]) - elif line[1] == '3': - if statement['lines'][-1]['ref'][0:4] != line[2:6]: - raise osv.except_osv(_('Error R2005!'), _('CODA parsing error on movement data record 2.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) - if statement['version'] == '1': - statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) - statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:125]) - statement['lines'][-1]['counterpartyCurrency'] = '' - else: - if line[22] == ' ': - statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) - statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[23:26]) - else: - statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:44]) - statement['lines'][-1]['counterpartyCurrency'] = rmspaces(line[44:47]) - statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:82]) - statement['lines'][-1]['communication'] += rmspaces(line[82:125]) - else: - # movement data record 2.x (x != 1,2,3) - raise osv.except_osv(_('Error R2009!'), _('\nMovement data records of type 2.%s are not supported !') % line[1]) - elif line[0] == '3': - if line[1] == '1': - infoLine = {} - infoLine['entryDate'] = statement['lines'][-1]['entryDate'] - infoLine['type'] = 'information' - infoLine['sequence'] = len(statement['lines']) + 1 - infoLine['ref'] = rmspaces(line[2:10]) - infoLine['transactionRef'] = rmspaces(line[10:31]) - infoLine['transaction_type'] = line[31] - infoLine['transaction_family'] = rmspaces(line[32:34]) - infoLine['transaction_code'] = rmspaces(line[34:36]) - infoLine['transaction_category'] = rmspaces(line[36:39]) - infoLine['communication'] = rmspaces(line[40:113]) - infoLine['amount'] = 0.0 - infoLine['type'] = 'information' - statement['lines'].append(infoLine) - elif line[1] == '2': - if infoLine['ref'] != rmspaces(line[2:10]): - raise osv.except_osv(_('Error R3004!'), _('CODA parsing error on information data record 3.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) - statement['lines'][-1]['communication'] += rmspaces(line[10:100]) - elif line[1] == '3': - if infoLine['ref'] != rmspaces(line[2:10]): - raise osv.except_osv(_('Error R3005!'), _('CODA parsing error on information data record 3.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) - statement['lines'][-1]['communication'] += rmspaces(line[10:100]) - elif line[0] == '4': - comm_line = {} - comm_line['type'] = 'communication' - comm_line['sequence'] = len(statement['lines']) + 1 - comm_line['ref'] = rmspaces(line[2:10]) - comm_line['communication'] = rmspaces(line[32:112]) - comm_line['amount'] = 0.0 - comm_line['type'] = 'communication' - statement['lines'].append(comm_line) - elif line[0] == '8': - # new balance record - statement['debit'] = line[41] - statement['paperSeqNumber'] = rmspaces(line[1:4]) - statement['balance_end_real'] = float(rmspaces(line[42:57])) / 1000 - statement['balance_end_realDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[57:63]), '%d%m%y')) - if statement['debit'] == '1': # 1=Debit - statement['balance_end_real'] = - statement['balance_end_real'] - if statement['balance_end_realDate']: - period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['balance_end_realDate']), ('date_stop', '>=', statement['balance_end_realDate'])]) - else: - period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['date']), ('date_stop', '>=', statement['date'])]) - if not period_id and len(period_id) == 0: - raise osv.except_osv(_('Error R0002!'), _("The CODA Statement New Balance date doesn't fall within a defined Accounting Period! Please create the Accounting Period for date %s.") % statement['balance_end_realDate']) - statement['period_id'] = period_id[0] - elif line[0] == '9': - statement['balanceMin'] = float(rmspaces(line[22:37])) / 1000 - statement['balancePlus'] = float(rmspaces(line[37:52])) / 1000 - if not statement['balance_end_real']: - statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] - for i, statement in enumerate(statements): - # print '---STATEMENT #' + str(i) + '---' - print statement - data = { - 'name': '[' + statement['date'] + ']' + statement['description'], - 'date': statement['date'], - 'journal_id': 18, - 'period_id': statement['period_id'], - 'balance_start': statement['balance_start'], - 'balance_end_real': statement['balance_end_real'], - 'account_id': 1 - } - statement['id'] = self.pool.get('account.bank.statement').create(cr, uid, data, context=context) - for line in statement['lines']: - if line['type'] == 'normal': - counterparty = [] - if 'counterpartyName' in line: - counterparty.append(line['counterpartyName']) - if 'counterpartyNumber' in line: - counterparty.append(line['counterpartyNumber']) - if len(counterparty) > 0: - counterparty = '[' + ' / '.join(counterparty) + ']' - else: - counterparty = '/' - if line['transaction_type'] in transaction_types: - line['transaction_type'] = transaction_types[line['transaction_type']][1] - if line['transaction_category'] in transaction_categories: - line['transaction_category'] = transaction_categories[line['transaction_category']] - if line['transaction_family'] in transaction_codes: - transaction_family = transaction_codes[line['transaction_family']] - line['transaction_family'] = transaction_family[0] - if line['transaction_code'] in transaction_family[1]: - line['transaction_code'] = transaction_family[1][line['transaction_code']] - note = [] - note.append(_('Counter Party') + ': ' + counterparty) - note.append(_('Communication') + ': ' + line['communication']) - note.append(_('Transaction type') + ': ' + line['transaction_type']) - note.append(_('Transaction family') + ': ' + line['transaction_family']) - note.append(_('Transaction code') + ': ' + line['transaction_code']) - note.append(_('Transaction category') + ': ' + line['transaction_category']) - - try: - if 'counterpartyNumber' in line and int(line['counterpartyNumber']) == 0: - line['counterpartyNumber'] = False - except: - pass - if 'counterpartyNumber' in line and line['counterpartyNumber']: - ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) - if ids and len(ids) > 0: - partner_id = self.pool.get('res.partner.bank').browse(cr, uid, ids[0],context=context).partner_id.id - else: - partner_id = None - - data = { - 'name': line['communication'], - 'note': "\n".join(note), - 'date': line['entryDate'], - 'amount': line['amount'], - # 'type': '', - 'partner_id': partner_id, - 'account_id': 1, - 'statement_id': statement['id'], - # 'analytic_account_id': '', - # 'move_ids': '', - 'ref': line['ref'], - 'sequence': line['sequence'], - } - self.pool.get('account.bank.statement.line').create(cr, uid, data, context=context) - -account_coda_import() - -transaction_types = { - "0": ["", _("Simple amount without detailed data; e.g. : an individual credit transfer [free of charges].")], - "1": ["", _("Amount as totalised by the customer; e.g. a file regrouping payments of wages or payments made to suppliers or a file regrouping collections for which the customer is ]debited or credited with one single amount. As a matter of principle, this type is also used when no detailed data is following [type 5].")], - "5": ["1", _("Detail of 1. Standard procedure is no detailing. However, the customer may ask for detailed data to be included into his file after the overall record [type 1].")], - "2": ["", _("Amount as totalised by the bank; e.g. : the total amount of a series of credit transfers with a structured communication As a matter of principle, this type will also be used when no detailed data [type 6 or 7] is following.")], - "6": ["2", _("Detail of 2. Simple amount without detailed data. Normally, data of this kind comes after type 2. The customer may ask for a separate file containing the detailed data. In that case, one will speak of a ‘separate application’. The records in a separate application keep type 6.")], - "7": ["2", _("Detail of 2. Simple account with detailed data The records in a separate application keep type 7.")], - "9": ["7", _("Detail of 7. The records in a separate application keep type 9.")], - "3": ["", _("Simple amount with detailed data; e.g. in case of charges for cross-border credit transfers.")], - "8": ["3", _("Detail of 3.")], -} - -transaction_codes = { - "00": [_("Undefined transactions"), { - "89": _("Cancellation of a transaction"), - "87": _("Costs refunded"), - "85": _("Correction"), - "83": _("Value correction"), - "39": _("Cancellation of a transaction"), - "37": _("Costs"), - "35": _("Correction"), - "33": _("Value correction"), - "00": _("Undefined transaction") - }], - "01": [_("Domestic or local SEPA credit transfers"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "66": _("Financial centralization"), - "64": _("Transfer to your account"), - "62": _("Unpaid postal order"), - "60": _("Non-presented circular cheque"), - "54": _("Unexecutable transfer order"), - "52": _("Payment in your favour"), - "51": _("Transfer in your favour – initiated by the bank"), - "50": _("Transfer in your favour"), - "49": _("Cancellation or correction"), - "39": _("Your issue circular cheque"), - "37": _("Costs"), - "17": _("Financial centralisation"), - "15": _("Balance due insurance premium"), - "13": _("Transfer from your account"), - "11": _("Your semi-standing order – payment to employees"), - "09": _("Your semi-standing order"), - "07": _("Collective transfer"), - "05": _("Payment of wages etc."), - "03": _("Standing order"), - "02": _("Individual transfer order initiated by the bank"), - "01": _("Individual transfer order]"), - }], - "03": [_("Cheques"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of cheque-related costs"), - "68": _("Credit of a payment via electronic purse"), - "66": _("Remittance of cheque by your branch - credit under usual reserve"), - "64": _("Reversal of settlement of credit card"), - "63": _("Second credit of unpaid cheque"), - "62": _("Reversal of cheque"), - "60": _("Reversal of voucher"), - "58": _("Remittance of cheques, vouchers, etc. credit after collection"), - "56": _("Non-presented certified cheques"), - "52": _("First credit of cheques, vouchers, luncheon vouchers, postal orders, credit under usual reserve"), - "50": _("Credit of a payment via terminal"), - "49": _("Cancellation or correction"), - "39": _("Provisionally unpaid due to other reason than manual presentation"), - "38": _("Provisionally unpaid"), - "37": _("Cheque-related costs"), - "35": _("Cash advance"), - "19": _("Settlement of credit cards"), - "17": _("Your certified cheque"), - "15": _("Your purchase bank cheque"), - "13": _("Eurocheque written out abroad"), - "11": _("Department store cheque"), - "09": _("Unpaid voucher"), - "07": _("Definitely unpaid cheque"), - "05": _("Payment of voucher"), - "03": _("Your purchase by payment card"), - "01": _("Payment of your cheque"), - }], - "04": [_("Cards"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "68": _("Credit after Proton payments"), - "55": _("Income from payments by GSM"), - "53": _("Cash deposit at an ATM"), - "52": _("Loading GSM cards"), - "51": _("Unloading Proton"), - "50": _("Credit after a payment at a terminal"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "08": _("Payment by means of a payment card outside the Eurozone"), - "07": _("Payment by GSM"), - "06": _("Payment with tank card"), - "05": _("Loading Proton"), - "04": _("Cash withdrawal from an ATM"), - "03": _("Settlement credit cards"), - "02": _("Payment by means of a payment card within the Eurozone"), - "01": _("Loading a GSM card"), - }], - "05": [_("Direct debit"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "58": _("Reversal"), - "56": _("Unexecutable reimbursement"), - "54": _("Reimbursement"), - "52": _("Credit under usual reserve"), - "50": _("Credit after collection"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "05": _("Reimbursement"), - "03": _("Unpaid debt"), - "01": _("Payment"), - }], - "07": [_("Domestic commercial paper"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "86": _("Payment after cession"), - "64": _("Warrant"), - "58": _("Remittance of supplier's bill without guarantee"), - "56": _("Remittance of supplier's bill with guarantee"), - "54": _("Remittance of commercial paper for discount"), - "52": _("Remittance of commercial paper - credit under usual reserve"), - "50": _("Remittance of commercial paper - credit after collection"), - "49": _("Cancellation or correction"), - "39": _("Return of an irregular bill of exchange"), - "37": _("Costs related to commercial paper"), - "14": _("Warrant fallen due"), - "12": _("Safe custody"), - "10": _("Renewal of agreed maturity date"), - "09": _("Agio on supplier's bill"), - "08": _("Payment in advance"), - "07": _("Unpaid commercial paper"), - "06": _("Extension of maturity date"), - "05": _("Commercial paper claimed back"), - "03": _("Payment receipt card"), - "01": _("Payment commercial paper"), - }], - "09": [_("Counter transactions"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Sale of traveller’s cheque"), - "68": _("Difference in payment"), - "66": _("Repurchase of petrol coupons"), - "64": _("Your winning lottery ticket"), - "62": _("Sale of gold/pieces under usual reserve"), - "60": _("Sale of foreign bank notes"), - "58": _("Payment by your branch/agents"), - "56": _("Reserve"), - "54": _("Your payment ATM"), - "52": _("Payment night safe"), - "50": _("Cash payment"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "25": _("Purchase of traveller’s cheque"), - "21": _("Cash withdrawal on card (PROTON)"), - "19": _("Difference in payment"), - "17": _("Purchase of fiscal stamps"), - "15": _("Your purchase of lottery tickets"), - "13": _("Cash withdrawal by your branch or agents"), - "11": _("Your purchase of luncheon vouchers"), - "09": _("Purchase of petrol coupons"), - "07": _("Purchase of gold/pieces"), - "05": _("Purchase of foreign bank notes"), - "03": _("Cash withdrawal by card (ATM)"), - "01": _("Cash withdrawal"), - }], - "11": [_("Securities"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Settlement of securities"), - "68": _("Compensation for missing coupon"), - "66": _("Retrocession of issue commission"), - "64": _("Your issue"), - "62": _("Interim interest on subscription"), - "58": _("Repayable securities from a deposit or delivered at the counter - credit under usual reserve"), - "56": _("Reserve"), - "52": _("Payment of coupons from a deposit or settlement of coupons delivered over the counter - credit under usual reserve"), - "51": _("Tender"), - "50": _("Sale of securities"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "19": _("Regularisation costs"), - "17": _("Management fee"), - "15": _("Interim interest on subscription"), - "13": _("Your repurchase of issue"), - "11": _("Payable coupons/repayable securities"), - "09": _("Settlement of securities"), - "06": _("Share option plan – exercising an option"), - "05": _("Partial payment subscription"), - "04": _("Issues"), - "03": _("Subscription to securities"), - "02": _("Tenders"), - "01": _("Purchase of securities"), - }], - "13": [_("Credit"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Settlement of discount bank acceptance"), - "68": _("Documentary export credits"), - "62": _("Term loan"), - "60": _("Settlement of mortgage loan"), - "56": _("Subsidy"), - "55": _("Fixed advance – interest only"), - "54": _("Fixed advance – capital and interest"), - "50": _("Settlement of instalment credit"), - "49": _("Cancellation or correction"), - "37": _("Credit-related costs"), - "21": _("Other credit applications"), - "19": _("Documentary import credits"), - "15": _("Your repayment hire-purchase and similar claims"), - "13": _("Settlement of bank acceptances"), - "11": _("Your repayment mortgage loan"), - "07": _("Your repayment instalment credits"), - "05": _("Settlement of fixed advance"), - "02": _("Long-term loan"), - "01": _("Short-term loan"), - }], - "30": [_("Various transactions"), { - "99": _("Cancellation or correction"), - "89": _("Undefined transaction"), - "87": _("Reimbursement of costs"), - "83": _("Value (date) correction"), - "55": _("Interest term investment"), - "54": _("Capital and/or interest term investment"), - "52": _("Forward sale of foreign exchange"), - "50": _("Spot sale of foreign exchange"), - "49": _("Cancellation or correction"), - "39": _("Undefined transaction"), - "37": _("Costs"), - "33": _("Value (date) correction"), - "05": _("Capital and/or interest term investment"), - "03": _("Forward purchase of foreign exchange"), - "01": _("Spot purchase of foreign exchange"), - }], - "35": [_("Closing (periodical settlements for interest, costs,…)"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "50": _("Closing"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "01": _("Closing"), - }], - "41": [_("International credit transfers - non-SEPA credit transfers"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "66": _("Financial centralisation (credit)"), - "64": _("Transfer to your account"), - "50": _("Transfer"), - "49": _("Cancellation or correction"), - "38": _("Costs relating to incoming foreign and non-SEPA transfers"), - "37": _("Costs relating to outgoing foreign transfers and non-SEPA transfers"), - "17": _("Financial centralisation (debit)"), - "13": _("Transfer from your account"), - "07": _("Collective transfers"), - "05": _("Collective payments of wages"), - "03": _("Standing order"), - "01": _("Transfer"), - }], - "43": [_("Foreign cheques"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Purchase of traveller’s cheque"), - "62": _("Reversal of cheques"), - "58": _("Remittance of foreign cheque credit after collection"), - "52": _("Remittance of foreign cheque credit under usual reserve"), - "49": _("Cancellation or correction"), - "37": _("Costs relating to payment of foreign cheques"), - "15": _("Purchase of an international bank cheque"), - "07": _("Unpaid foreign cheque"), - "01": _("Payment of a foreign cheque"), - }], - "47": [_("Foreign commercial paper"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "64": _("Warrant"), - "62": _("Remittance of documents abroad - credit after collection"), - "60": _("Remittance of documents abroad - credit under usual reserve"), - "58": _("Idem without guarantee"), - "56": _("Remittance of guaranteed foreign supplier's bill"), - "54": _("Discount abroad"), - "52": _("Remittance of foreign bill credit under usual reserve"), - "50": _("Remittance of foreign bill credit after collection"), - "49": _("Cancellation or correction"), - "37": _("Costs relating to the payment of a foreign bill"), - "14": _("Warrant fallen due"), - "13": _("Discount foreign supplier's bills"), - "11": _("Payment documents abroad"), - "07": _("Unpaid foreign bill"), - "06": _("Extension"), - "05": _("Bill claimed back"), - "01": _("Payment of foreign bill"), - }], - "49": [_("Foreign counter transactions"), {"03": _("ATM withdrawal")}], - "80": [_("Separately charged costs and provisions"), { - "01": _("Guarantee card charges"), - "02": _("Costs relating to electronic output"), - "03": _("Payment card charges"), - "04": _("Costs for holding a documentary cash credit"), - "05": _("Card charges"), - "06": _("Damage relating to bills and cheques"), - "07": _("Insurance costs"), - "08": _("Registering compensation for savings accounts"), - "09": _("Postage"), - "10": _("Purchase of Smartcard"), - "11": _("Costs for the safe custody of correspondence"), - "12": _("Costs for opening a bank guarantee"), - "13": _("Renting of safes"), - "14": _("Handling costs instalment credit"), - "15": _("Night safe"), - "16": _("Bank confirmation to revisor or accountant"), - "17": _("Charge for safe custody"), - "18": _("Trade information"), - "19": _("Special charge for safe custody"), - "20": _("Drawing up a certificate"), - "21": _("Pay-packet charges"), - "22": _("Management/custody"), - "23": _("Research costs"), - "24": _("Participation in and management of interest refund system"), - "25": _("Renting of direct debit box"), - "26": _("Travel insurance premium"), - "27": _("Subscription fee"), - "29": _("Information charges"), - "31": _("Writ service fee"), - "33": _("Miscellaneous fees and commissions"), - "35": _("Costs"), - "37": _("Access right to database"), - "39": _("Surety fee"), - "41": _("Research costs"), - "43": _("Printing of forms"), - "45": _("Documentary credit charges"), - "47": _("Charging fees for transactions"), - "49": _("Cancellation or correction"), - "99": _("Cancellation or correction"), - }], -} - -transaction_categories = { - "000": _("Net amount"), - "001": _("Interest received"), - "002": _("Interest paid"), - "003": _("Credit commission"), - "004": _("Postage"), - "005": _("Renting of letterbox"), - "006": _("Various fees/commissions"), - "007": _("Access right to database"), - "008": _("Information charges"), - "009": _("Travelling expenses"), - "010": _("Writ service fee"), - "011": _("VAT"), - "012": _("Exchange commission"), - "013": _("Payment commission"), - "014": _("Collection commission"), - "015": _("Correspondent charges"), - "016": _("BLIW/IBLC dues"), - "017": _("Research costs"), - "018": _("Tental guarantee charges"), - "019": _("Tax on physical delivery"), - "020": _("Costs of physical delivery"), - "021": _("Costs for drawing up a bank cheque"), - "022": _("Priority costs"), - "023": _("Exercising fee"), - "024": _("Growth premium"), - "025": _("Individual entry for exchange charges"), - "026": _("Handling commission"), - "027": _("Charges for unpaid bills"), - "028": _("Fidelity premium"), - "029": _("Protest charges"), - "030": _("Account insurance"), - "031": _("Charges foreign cheque"), - "032": _("Drawing up a circular cheque"), - "033": _("Charges for a foreign bill"), - "034": _("Reinvestment fee"), - "035": _("Charges foreign documentary bill"), - "036": _("Costs relating to a refused cheque"), - "037": _("Commission for handling charges"), - "039": _("Telecommunications"), - "041": _("Credit card costs"), - "042": _("Payment card costs"), - "043": _("Insurance costs"), - "045": _("Handling costs"), - "047": _("Charges extension bill"), - "049": _("Fiscal stamps/stamp duty"), - "050": _("Capital term investment"), - "051": _("Withholding tax"), - "052": _("Residence state tax"), - "053": _("Printing of forms"), - "055": _("Repayment loan or credit capital"), - "057": _("Interest subsidy"), - "058": _("Capital premium"), - "059": _("Default interest"), - "061": _("Charging fees for transactions"), - "063": _("Rounding differences"), - "065": _("Interest payment advice"), - "066": _("Fixed loan advance - reimbursement"), - "067": _("Fixed loan advance - extension"), - "068": _("Countervalue of an entry"), - "069": _("Forward arbitrage contracts : sum to be supplied by customer"), - "070": _("Forward arbitrage contracts : sum to be supplied by bank"), - "071": _("Fixed loan advance - availability"), - "072": _("Countervalue of commission to third party"), - "073": _("Costs of ATM abroad"), - "074": _("Mailing costs"), - "100": _("Gross amount"), - "200": _("Overall documentary credit charges"), - "201": _("Advice notice commission"), - "202": _("Advising commission | Additional advising commission"), - "203": _("Confirmation fee | Additional confirmation fee | Commitment fee | Flat fee | Confirmation reservation commission | Additional reservation commission"), - "204": _("Amendment fee"), - "205": _("Documentary payment commission | Document commission | Drawdown fee | Negotiation fee"), - "206": _("Surety fee/payment under reserve"), - "207": _("Non-conformity fee"), - "208": _("Commitment fee deferred payment"), - "209": _("Transfer commission"), - "210": _("Commitment fee"), - "211": _("Credit arrangement fee | Additional credit arrangement fee"), - "212": _("Warehousing fee"), - "213": _("Financing fee"), - "214": _("Issue commission (delivery order)"), - "400": _("Acceptance fee"), - "401": _("Visa charges"), - "402": _("Certification costs"), - "403": _("Minimum discount rate"), - "404": _("Discount commission"), - "405": _("Bill guarantee commission"), - "406": _("Collection charges"), - "407": _("Costs Article 45"), - "408": _("Cover commission"), - "409": _("Safe deposit charges"), - "410": _("Reclamation charges"), - "411": _("Fixed collection charge"), - "412": _("Advice of expiry charges"), - "413": _("Acceptance charges"), - "414": _("Regularisation charges"), - "415": _("Surety fee"), - "416": _("Charges for the deposit of security"), - "418": _("Endorsement commission"), - "419": _("Bank service fee"), - "420": _("Retention charges"), - "425": _("Foreign broker's commission"), - "426": _("Belgian broker's commission"), - "427": _("Belgian Stock Exchange tax"), - "428": _("Interest accrued"), - "429": _("Foreign Stock Exchange tax"), - "430": _("Recovery of foreign tax"), - "431": _("Delivery of a copy"), -} - - -def rmspaces(s): - return " ".join(s.split()) - - - -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: From 819a8f3887ed5ba29930ce40131e4a83648694c9 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Wed, 5 Dec 2012 19:02:02 +0100 Subject: [PATCH 10/41] [FIX]name missing in tree bank statement line bzr revid: dle@openerp.com-20121205180202-amy4yrqotuu0ta5e --- addons/account/account_view.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/account/account_view.xml b/addons/account/account_view.xml index 562c1ad6fa1..235ded29094 100644 --- a/addons/account/account_view.xml +++ b/addons/account/account_view.xml @@ -574,6 +574,7 @@ + From 28b988940f65d2e114442cfbe57a27a1bac83252 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Wed, 5 Dec 2012 20:21:43 +0100 Subject: [PATCH 11/41] [FIX]Removing _(translate) from transaction code, family, categories + Matching bank account number bzr revid: dle@openerp.com-20121205192143-9qxazjf743z42ycw --- .../wizard/account_coda_import.py | 898 +++++++++--------- 1 file changed, 450 insertions(+), 448 deletions(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 0bde26e1f44..2286caf8f68 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -45,7 +45,6 @@ class account_coda_import(osv.osv_memory): if context is None: context = {} if batch: - print codafile = str(codafile) codafilename = codafilename else: @@ -54,7 +53,7 @@ class account_coda_import(osv.osv_memory): codafile = data.coda_data codafilename = data.coda_fname except: - raise osv.except_osv(_('Error!'), _('Wizard in incorrect state. Please hit the Cancel button!')) + raise osv.except_osv(_('Error'), _('Wizard in incorrect state. Please hit the Cancel button')) return {} recordlist = unicode(base64.decodestring(codafile), 'windows-1252', 'strict').split('\n') statements = [] @@ -67,7 +66,7 @@ class account_coda_import(osv.osv_memory): statements.append(statement) statement['version'] = line[127] if statement['version'] not in ['1', '2']: - raise osv.except_osv(_('Error R001!'), _('CODA V%s statements are not supported, please contact your bank!') % statement['version']) + raise osv.except_osv(_('Error') + 'R001', _('CODA V%s statements are not supported, please contact your bank') % statement['version']) statement['globalisation_stack'] = [] statement['lines'] = [] statement['date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[5:11]), '%d%m%y')) @@ -75,21 +74,31 @@ class account_coda_import(osv.osv_memory): elif line[0] == '1': #Statement details if statement['version'] == '1': - statement['accountNumber'] = rmspaces(line[5:17]) + statement['acc_number'] = rmspaces(line[5:17]) statement['currency'] = rmspaces(line[18:21]) elif statement['version'] == '2': if line[1] == '0': # Belgian bank account BBAN structure - statement['accountNumber'] = rmspaces(line[5:17]) + statement['acc_number'] = rmspaces(line[5:17]) statement['currency'] = rmspaces(line[18:21]) elif line[1] == '1': # foreign bank account BBAN structure - raise osv.except_osv(_('Error R1001!'), _('Foreign bank accounts with BBAN structure are not supported !')) + raise osv.except_osv(_('Error') + 'R1001', _('Foreign bank accounts with BBAN structure are not supported ')) elif line[1] == '2': # Belgian bank account IBAN structure - statement['accountNumber'] = rmspaces(line[5:21]) + statement['acc_number'] = rmspaces(line[5:21]) statement['currency'] = rmspaces(line[39:42]) elif line[1] == '3': # foreign bank account IBAN structure - raise osv.except_osv(_('Error R1002!'), _('Foreign bank accounts with IBAN structure are not supported !')) + raise osv.except_osv(_('Error') + 'R1002', _('Foreign bank accounts with IBAN structure are not supported ')) else: # Something else, not supported - raise osv.except_osv(_('Error R1003!'), _('Unsupported bank account structure !')) + raise osv.except_osv(_('Error') + 'R1003', _('Unsupported bank account structure ')) + ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', statement['acc_number'])]) + not_found_except = osv.except_osv(_('Error') + 'R1004', _("No matching CODA Bank Account Configuration record found. Please check if the 'Bank Account Number' and 'Currency' fields of your configuration record match with '%s' and '%s'.") % (statement['acc_number'], statement['currency'])) + if ids and len(ids) > 0: + bank_accs = self.pool.get('res.partner.bank').browse(cr, uid, ids) + for bank_acc in bank_accs: + statement['journal_id'] = bank_acc.journal_id + if (statement['journal_id'].currency and statement['journal_id'].currency.name != statement['currency']) and (not statement['journal_id'].currency and statement['journal_id'].company_id.currency_id.name != statement['currency']): + raise not_found_except + else: + raise not_found_except statement['description'] = rmspaces(line[90:125]) statement['balance_start'] = float(rmspaces(line[43:58])) / 1000 statement['balance_start_date'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[58:64]), '%d%m%y')) @@ -112,16 +121,12 @@ class account_coda_import(osv.osv_memory): statementLine['amount'] = - statementLine['amount'] statementLine['transaction_type'] = line[53] if statementLine['transaction_type'] not in transaction_types: - raise osv.except_osv(_('Error R2001!'), _('The File contains an invalid CODA Transaction Type : %s!') % statementLine['transaction_type']) + raise osv.except_osv(_('Error') + 'R2001', _('The File contains an invalid CODA Transaction Type : %s') % statementLine['transaction_type']) statementLine['transactionDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[47:53]), '%d%m%y')) statementLine['transaction_family'] = rmspaces(line[54:56]) - #TODO Handling severals transactions Family statementLine['transaction_code'] = rmspaces(line[56:58]) - #TODO Handling severals transactions code statementLine['transaction_category'] = rmspaces(line[58:61]) - #TODO Handling severals transactions category statementLine['communication'] = rmspaces(line[62:115]) - #TODO Handling structured communication statementLine['entryDate'] = rmspaces(line[115:121]) statementLine['type'] = 'normal' statementLine['globalisation'] = int(line[124]) @@ -138,13 +143,13 @@ class account_coda_import(osv.osv_memory): statement['lines'].append(statementLine) elif line[1] == '2': if statement['lines'][-1]['ref'][0:4] != line[2:6]: - raise osv.except_osv(_('Error R2004!'), _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + raise osv.except_osv(_('Error') + 'R2004', _('CODA parsing error on movement data record 2.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) statement['lines'][-1]['communication'] += rmspaces(line[10:63]) statement['lines'][-1]['payment_reference'] = rmspaces(line[63:98]) statement['lines'][-1]['counterparty_bic'] = rmspaces(line[98:109]) elif line[1] == '3': if statement['lines'][-1]['ref'][0:4] != line[2:6]: - raise osv.except_osv(_('Error R2005!'), _('CODA parsing error on movement data record 2.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + raise osv.except_osv(_('Error') + 'R2005', _('CODA parsing error on movement data record 2.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) if statement['version'] == '1': statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:125]) @@ -160,7 +165,7 @@ class account_coda_import(osv.osv_memory): statement['lines'][-1]['communication'] += rmspaces(line[82:125]) else: # movement data record 2.x (x != 1,2,3) - raise osv.except_osv(_('Error R2009!'), _('\nMovement data records of type 2.%s are not supported !') % line[1]) + raise osv.except_osv(_('Error') + 'R2006', _('\nMovement data records of type 2.%s are not supported ') % line[1]) elif line[0] == '3': if line[1] == '1': infoLine = {} @@ -179,11 +184,11 @@ class account_coda_import(osv.osv_memory): statement['lines'].append(infoLine) elif line[1] == '2': if infoLine['ref'] != rmspaces(line[2:10]): - raise osv.except_osv(_('Error R3004!'), _('CODA parsing error on information data record 3.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + raise osv.except_osv(_('Error') + 'R3004', _('CODA parsing error on information data record 3.2, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) statement['lines'][-1]['communication'] += rmspaces(line[10:100]) elif line[1] == '3': if infoLine['ref'] != rmspaces(line[2:10]): - raise osv.except_osv(_('Error R3005!'), _('CODA parsing error on information data record 3.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) + raise osv.except_osv(_('Error') + 'R3005', _('CODA parsing error on information data record 3.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) statement['lines'][-1]['communication'] += rmspaces(line[10:100]) elif line[0] == '4': comm_line = {} @@ -207,7 +212,7 @@ class account_coda_import(osv.osv_memory): else: period_id = self.pool.get('account.period').search(cr, uid, [('date_start', '<=', statement['date']), ('date_stop', '>=', statement['date'])]) if not period_id and len(period_id) == 0: - raise osv.except_osv(_('Error R0002!'), _("The CODA Statement New Balance date doesn't fall within a defined Accounting Period! Please create the Accounting Period for date %s.") % statement['balance_end_realDate']) + raise osv.except_osv(_('Error') + 'R0002', _("The CODA Statement New Balance date doesn't fall within a defined Accounting Period! Please create the Accounting Period for date %s.") % statement['balance_end_realDate']) statement['period_id'] = period_id[0] elif line[0] == '9': statement['balanceMin'] = float(rmspaces(line[22:37])) / 1000 @@ -215,16 +220,13 @@ class account_coda_import(osv.osv_memory): if not statement['balance_end_real']: statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] for i, statement in enumerate(statements): - # print '---STATEMENT #' + str(i) + '---' - print statement data = { 'name': '[' + statement['date'] + ']' + statement['description'], 'date': statement['date'], - 'journal_id': 18, + 'journal_id': statement['journal_id'].id, 'period_id': statement['period_id'], 'balance_start': statement['balance_start'], 'balance_end_real': statement['balance_end_real'], - 'account_id': 1 } statement['id'] = self.pool.get('account.bank.statement').create(cr, uid, data, context=context) for line in statement['lines']: @@ -264,7 +266,7 @@ class account_coda_import(osv.osv_memory): if 'counterpartyNumber' in line and line['counterpartyNumber']: ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) if ids and len(ids) > 0: - partner_id = self.pool.get('res.partner.bank').browse(cr, uid, ids[0],context=context).partner_id.id + partner_id = self.pool.get('res.partner.bank').browse(cr, uid, ids[0], context=context).partner_id.id else: partner_id = None @@ -275,7 +277,7 @@ class account_coda_import(osv.osv_memory): 'amount': line['amount'], # 'type': '', 'partner_id': partner_id, - 'account_id': 1, + 'account_id': 1, # TODO 'statement_id': statement['id'], # 'analytic_account_id': '', # 'move_ids': '', @@ -287,449 +289,449 @@ class account_coda_import(osv.osv_memory): account_coda_import() transaction_types = { - "0": ["", _("Simple amount without detailed data; e.g. : an individual credit transfer [free of charges].")], - "1": ["", _("Amount as totalised by the customer; e.g. a file regrouping payments of wages or payments made to suppliers or a file regrouping collections for which the customer is ]debited or credited with one single amount. As a matter of principle, this type is also used when no detailed data is following [type 5].")], - "5": ["1", _("Detail of 1. Standard procedure is no detailing. However, the customer may ask for detailed data to be included into his file after the overall record [type 1].")], - "2": ["", _("Amount as totalised by the bank; e.g. : the total amount of a series of credit transfers with a structured communication As a matter of principle, this type will also be used when no detailed data [type 6 or 7] is following.")], - "6": ["2", _("Detail of 2. Simple amount without detailed data. Normally, data of this kind comes after type 2. The customer may ask for a separate file containing the detailed data. In that case, one will speak of a ‘separate application’. The records in a separate application keep type 6.")], - "7": ["2", _("Detail of 2. Simple account with detailed data The records in a separate application keep type 7.")], - "9": ["7", _("Detail of 7. The records in a separate application keep type 9.")], - "3": ["", _("Simple amount with detailed data; e.g. in case of charges for cross-border credit transfers.")], - "8": ["3", _("Detail of 3.")], + "0": ["", "Simple amount without detailed data; e.g. : an individual credit transfer [free of charges]."], + "1": ["", "Amount as totalised by the customer; e.g. a file regrouping payments of wages or payments made to suppliers or a file regrouping collections for which the customer is ]debited or credited with one single amount. As a matter of principle, this type is also used when no detailed data is following [type 5]."], + "5": ["1", "Detail of 1. Standard procedure is no detailing. However, the customer may ask for detailed data to be included into his file after the overall record [type 1]."], + "2": ["", "Amount as totalised by the bank; e.g. : the total amount of a series of credit transfers with a structured communication As a matter of principle, this type will also be used when no detailed data [type 6 or 7] is following."], + "6": ["2", "Detail of 2. Simple amount without detailed data. Normally, data of this kind comes after type 2. The customer may ask for a separate file containing the detailed data. In that case, one will speak of a ‘separate application’. The records in a separate application keep type 6."], + "7": ["2", "Detail of 2. Simple account with detailed data The records in a separate application keep type 7."], + "9": ["7", "Detail of 7. The records in a separate application keep type 9."], + "3": ["", "Simple amount with detailed data; e.g. in case of charges for cross-border credit transfers."], + "8": ["3", "Detail of 3."], } transaction_codes = { - "00": [_("Undefined transactions"), { - "89": _("Cancellation of a transaction"), - "87": _("Costs refunded"), - "85": _("Correction"), - "83": _("Value correction"), - "39": _("Cancellation of a transaction"), - "37": _("Costs"), - "35": _("Correction"), - "33": _("Value correction"), - "00": _("Undefined transaction") + "00": ["Undefined transactions", { + "89": "Cancellation of a transaction", + "87": "Costs refunded", + "85": "Correction", + "83": "Value correction", + "39": "Cancellation of a transaction", + "37": "Costs", + "35": "Correction", + "33": "Value correction", + "00": "Undefined transaction", }], - "01": [_("Domestic or local SEPA credit transfers"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "66": _("Financial centralization"), - "64": _("Transfer to your account"), - "62": _("Unpaid postal order"), - "60": _("Non-presented circular cheque"), - "54": _("Unexecutable transfer order"), - "52": _("Payment in your favour"), - "51": _("Transfer in your favour – initiated by the bank"), - "50": _("Transfer in your favour"), - "49": _("Cancellation or correction"), - "39": _("Your issue circular cheque"), - "37": _("Costs"), - "17": _("Financial centralisation"), - "15": _("Balance due insurance premium"), - "13": _("Transfer from your account"), - "11": _("Your semi-standing order – payment to employees"), - "09": _("Your semi-standing order"), - "07": _("Collective transfer"), - "05": _("Payment of wages etc."), - "03": _("Standing order"), - "02": _("Individual transfer order initiated by the bank"), - "01": _("Individual transfer order]"), + "01": ["Domestic or local SEPA credit transfers", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "66": "Financial centralization", + "64": "Transfer to your account", + "62": "Unpaid postal order", + "60": "Non-presented circular cheque", + "54": "Unexecutable transfer order", + "52": "Payment in your favour", + "51": "Transfer in your favour – initiated by the bank", + "50": "Transfer in your favour", + "49": "Cancellation or correction", + "39": "Your issue circular cheque", + "37": "Costs", + "17": "Financial centralisation", + "15": "Balance due insurance premium", + "13": "Transfer from your account", + "11": "Your semi-standing order – payment to employees", + "09": "Your semi-standing order", + "07": "Collective transfer", + "05": "Payment of wages etc.", + "03": "Standing order", + "02": "Individual transfer order initiated by the bank", + "01": "Individual transfer order", }], - "03": [_("Cheques"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of cheque-related costs"), - "68": _("Credit of a payment via electronic purse"), - "66": _("Remittance of cheque by your branch - credit under usual reserve"), - "64": _("Reversal of settlement of credit card"), - "63": _("Second credit of unpaid cheque"), - "62": _("Reversal of cheque"), - "60": _("Reversal of voucher"), - "58": _("Remittance of cheques, vouchers, etc. credit after collection"), - "56": _("Non-presented certified cheques"), - "52": _("First credit of cheques, vouchers, luncheon vouchers, postal orders, credit under usual reserve"), - "50": _("Credit of a payment via terminal"), - "49": _("Cancellation or correction"), - "39": _("Provisionally unpaid due to other reason than manual presentation"), - "38": _("Provisionally unpaid"), - "37": _("Cheque-related costs"), - "35": _("Cash advance"), - "19": _("Settlement of credit cards"), - "17": _("Your certified cheque"), - "15": _("Your purchase bank cheque"), - "13": _("Eurocheque written out abroad"), - "11": _("Department store cheque"), - "09": _("Unpaid voucher"), - "07": _("Definitely unpaid cheque"), - "05": _("Payment of voucher"), - "03": _("Your purchase by payment card"), - "01": _("Payment of your cheque"), + "03": ["Cheques", { + "99": "Cancellation or correction", + "87": "Reimbursement of cheque-related costs", + "68": "Credit of a payment via electronic purse", + "66": "Remittance of cheque by your branch - credit under usual reserve", + "64": "Reversal of settlement of credit card", + "63": "Second credit of unpaid cheque", + "62": "Reversal of cheque", + "60": "Reversal of voucher", + "58": "Remittance of cheques, vouchers, etc. credit after collection", + "56": "Non-presented certified cheques", + "52": "First credit of cheques, vouchers, luncheon vouchers, postal orders, credit under usual reserve", + "50": "Credit of a payment via terminal", + "49": "Cancellation or correction", + "39": "Provisionally unpaid due to other reason than manual presentation", + "38": "Provisionally unpaid", + "37": "Cheque-related costs", + "35": "Cash advance", + "19": "Settlement of credit cards", + "17": "Your certified cheque", + "15": "Your purchase bank cheque", + "13": "Eurocheque written out abroad", + "11": "Department store cheque", + "09": "Unpaid voucher", + "07": "Definitely unpaid cheque", + "05": "Payment of voucher", + "03": "Your purchase by payment card", + "01": "Payment of your cheque", }], - "04": [_("Cards"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "68": _("Credit after Proton payments"), - "55": _("Income from payments by GSM"), - "53": _("Cash deposit at an ATM"), - "52": _("Loading GSM cards"), - "51": _("Unloading Proton"), - "50": _("Credit after a payment at a terminal"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "08": _("Payment by means of a payment card outside the Eurozone"), - "07": _("Payment by GSM"), - "06": _("Payment with tank card"), - "05": _("Loading Proton"), - "04": _("Cash withdrawal from an ATM"), - "03": _("Settlement credit cards"), - "02": _("Payment by means of a payment card within the Eurozone"), - "01": _("Loading a GSM card"), + "04": ["Cards", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "68": "Credit after Proton payments", + "55": "Income from payments by GSM", + "53": "Cash deposit at an ATM", + "52": "Loading GSM cards", + "51": "Unloading Proton", + "50": "Credit after a payment at a terminal", + "49": "Cancellation or correction", + "37": "Costs", + "08": "Payment by means of a payment card outside the Eurozone", + "07": "Payment by GSM", + "06": "Payment with tank card", + "05": "Loading Proton", + "04": "Cash withdrawal from an ATM", + "03": "Settlement credit cards", + "02": "Payment by means of a payment card within the Eurozone", + "01": "Loading a GSM card", }], - "05": [_("Direct debit"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "58": _("Reversal"), - "56": _("Unexecutable reimbursement"), - "54": _("Reimbursement"), - "52": _("Credit under usual reserve"), - "50": _("Credit after collection"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "05": _("Reimbursement"), - "03": _("Unpaid debt"), - "01": _("Payment"), + "05": ["Direct debit", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "58": "Reversal", + "56": "Unexecutable reimbursement", + "54": "Reimbursement", + "52": "Credit under usual reserve", + "50": "Credit after collection", + "49": "Cancellation or correction", + "37": "Costs", + "05": "Reimbursement", + "03": "Unpaid debt", + "01": "Payment", }], - "07": [_("Domestic commercial paper"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "86": _("Payment after cession"), - "64": _("Warrant"), - "58": _("Remittance of supplier's bill without guarantee"), - "56": _("Remittance of supplier's bill with guarantee"), - "54": _("Remittance of commercial paper for discount"), - "52": _("Remittance of commercial paper - credit under usual reserve"), - "50": _("Remittance of commercial paper - credit after collection"), - "49": _("Cancellation or correction"), - "39": _("Return of an irregular bill of exchange"), - "37": _("Costs related to commercial paper"), - "14": _("Warrant fallen due"), - "12": _("Safe custody"), - "10": _("Renewal of agreed maturity date"), - "09": _("Agio on supplier's bill"), - "08": _("Payment in advance"), - "07": _("Unpaid commercial paper"), - "06": _("Extension of maturity date"), - "05": _("Commercial paper claimed back"), - "03": _("Payment receipt card"), - "01": _("Payment commercial paper"), + "07": ["Domestic commercial paper", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "86": "Payment after cession", + "64": "Warrant", + "58": "Remittance of supplier's bill without guarantee", + "56": "Remittance of supplier's bill with guarantee", + "54": "Remittance of commercial paper for discount", + "52": "Remittance of commercial paper - credit under usual reserve", + "50": "Remittance of commercial paper - credit after collection", + "49": "Cancellation or correction", + "39": "Return of an irregular bill of exchange", + "37": "Costs related to commercial paper", + "14": "Warrant fallen due", + "12": "Safe custody", + "10": "Renewal of agreed maturity date", + "09": "Agio on supplier's bill", + "08": "Payment in advance", + "07": "Unpaid commercial paper", + "06": "Extension of maturity date", + "05": "Commercial paper claimed back", + "03": "Payment receipt card", + "01": "Payment commercial paper", }], - "09": [_("Counter transactions"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Sale of traveller’s cheque"), - "68": _("Difference in payment"), - "66": _("Repurchase of petrol coupons"), - "64": _("Your winning lottery ticket"), - "62": _("Sale of gold/pieces under usual reserve"), - "60": _("Sale of foreign bank notes"), - "58": _("Payment by your branch/agents"), - "56": _("Reserve"), - "54": _("Your payment ATM"), - "52": _("Payment night safe"), - "50": _("Cash payment"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "25": _("Purchase of traveller’s cheque"), - "21": _("Cash withdrawal on card (PROTON)"), - "19": _("Difference in payment"), - "17": _("Purchase of fiscal stamps"), - "15": _("Your purchase of lottery tickets"), - "13": _("Cash withdrawal by your branch or agents"), - "11": _("Your purchase of luncheon vouchers"), - "09": _("Purchase of petrol coupons"), - "07": _("Purchase of gold/pieces"), - "05": _("Purchase of foreign bank notes"), - "03": _("Cash withdrawal by card (ATM)"), - "01": _("Cash withdrawal"), + "09": ["Counter transactions", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "70": "Sale of traveller’s cheque", + "68": "Difference in payment", + "66": "Repurchase of petrol coupons", + "64": "Your winning lottery ticket", + "62": "Sale of gold/pieces under usual reserve", + "60": "Sale of foreign bank notes", + "58": "Payment by your branch/agents", + "56": "Reserve", + "54": "Your payment ATM", + "52": "Payment night safe", + "50": "Cash payment", + "49": "Cancellation or correction", + "37": "Costs", + "25": "Purchase of traveller’s cheque", + "21": "Cash withdrawal on card (PROTON)", + "19": "Difference in payment", + "17": "Purchase of fiscal stamps", + "15": "Your purchase of lottery tickets", + "13": "Cash withdrawal by your branch or agents", + "11": "Your purchase of luncheon vouchers", + "09": "Purchase of petrol coupons", + "07": "Purchase of gold/pieces", + "05": "Purchase of foreign bank notes", + "03": "Cash withdrawal by card (ATM)", + "01": "Cash withdrawal", }], - "11": [_("Securities"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Settlement of securities"), - "68": _("Compensation for missing coupon"), - "66": _("Retrocession of issue commission"), - "64": _("Your issue"), - "62": _("Interim interest on subscription"), - "58": _("Repayable securities from a deposit or delivered at the counter - credit under usual reserve"), - "56": _("Reserve"), - "52": _("Payment of coupons from a deposit or settlement of coupons delivered over the counter - credit under usual reserve"), - "51": _("Tender"), - "50": _("Sale of securities"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "19": _("Regularisation costs"), - "17": _("Management fee"), - "15": _("Interim interest on subscription"), - "13": _("Your repurchase of issue"), - "11": _("Payable coupons/repayable securities"), - "09": _("Settlement of securities"), - "06": _("Share option plan – exercising an option"), - "05": _("Partial payment subscription"), - "04": _("Issues"), - "03": _("Subscription to securities"), - "02": _("Tenders"), - "01": _("Purchase of securities"), + "11": ["Securities", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "70": "Settlement of securities", + "68": "Compensation for missing coupon", + "66": "Retrocession of issue commission", + "64": "Your issue", + "62": "Interim interest on subscription", + "58": "Repayable securities from a deposit or delivered at the counter - credit under usual reserve", + "56": "Reserve", + "52": "Payment of coupons from a deposit or settlement of coupons delivered over the counter - credit under usual reserve", + "51": "Tender", + "50": "Sale of securities", + "49": "Cancellation or correction", + "37": "Costs", + "19": "Regularisation costs", + "17": "Management fee", + "15": "Interim interest on subscription", + "13": "Your repurchase of issue", + "11": "Payable coupons/repayable securities", + "09": "Settlement of securities", + "06": "Share option plan – exercising an option", + "05": "Partial payment subscription", + "04": "Issues", + "03": "Subscription to securities", + "02": "Tenders", + "01": "Purchase of securities", }], - "13": [_("Credit"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Settlement of discount bank acceptance"), - "68": _("Documentary export credits"), - "62": _("Term loan"), - "60": _("Settlement of mortgage loan"), - "56": _("Subsidy"), - "55": _("Fixed advance – interest only"), - "54": _("Fixed advance – capital and interest"), - "50": _("Settlement of instalment credit"), - "49": _("Cancellation or correction"), - "37": _("Credit-related costs"), - "21": _("Other credit applications"), - "19": _("Documentary import credits"), - "15": _("Your repayment hire-purchase and similar claims"), - "13": _("Settlement of bank acceptances"), - "11": _("Your repayment mortgage loan"), - "07": _("Your repayment instalment credits"), - "05": _("Settlement of fixed advance"), - "02": _("Long-term loan"), - "01": _("Short-term loan"), + "13": ["Credit", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "70": "Settlement of discount bank acceptance", + "68": "Documentary export credits", + "62": "Term loan", + "60": "Settlement of mortgage loan", + "56": "Subsidy", + "55": "Fixed advance – interest only", + "54": "Fixed advance – capital and interest", + "50": "Settlement of instalment credit", + "49": "Cancellation or correction", + "37": "Credit-related costs", + "21": "Other credit applications", + "19": "Documentary import credits", + "15": "Your repayment hire-purchase and similar claims", + "13": "Settlement of bank acceptances", + "11": "Your repayment mortgage loan", + "07": "Your repayment instalment credits", + "05": "Settlement of fixed advance", + "02": "Long-term loan", + "01": "Short-term loan", }], - "30": [_("Various transactions"), { - "99": _("Cancellation or correction"), - "89": _("Undefined transaction"), - "87": _("Reimbursement of costs"), - "83": _("Value (date) correction"), - "55": _("Interest term investment"), - "54": _("Capital and/or interest term investment"), - "52": _("Forward sale of foreign exchange"), - "50": _("Spot sale of foreign exchange"), - "49": _("Cancellation or correction"), - "39": _("Undefined transaction"), - "37": _("Costs"), - "33": _("Value (date) correction"), - "05": _("Capital and/or interest term investment"), - "03": _("Forward purchase of foreign exchange"), - "01": _("Spot purchase of foreign exchange"), + "30": ["Various transactions", { + "99": "Cancellation or correction", + "89": "Undefined transaction", + "87": "Reimbursement of costs", + "83": "Value (date) correction", + "55": "Interest term investment", + "54": "Capital and/or interest term investment", + "52": "Forward sale of foreign exchange", + "50": "Spot sale of foreign exchange", + "49": "Cancellation or correction", + "39": "Undefined transaction", + "37": "Costs", + "33": "Value (date) correction", + "05": "Capital and/or interest term investment", + "03": "Forward purchase of foreign exchange", + "01": "Spot purchase of foreign exchange", }], - "35": [_("Closing (periodical settlements for interest, costs,…)"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "50": _("Closing"), - "49": _("Cancellation or correction"), - "37": _("Costs"), - "01": _("Closing"), + "35": ["Closing (periodical settlements for interest, costs,…)", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "50": "Closing", + "49": "Cancellation or correction", + "37": "Costs", + "01": "Closing", }], - "41": [_("International credit transfers - non-SEPA credit transfers"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "66": _("Financial centralisation (credit)"), - "64": _("Transfer to your account"), - "50": _("Transfer"), - "49": _("Cancellation or correction"), - "38": _("Costs relating to incoming foreign and non-SEPA transfers"), - "37": _("Costs relating to outgoing foreign transfers and non-SEPA transfers"), - "17": _("Financial centralisation (debit)"), - "13": _("Transfer from your account"), - "07": _("Collective transfers"), - "05": _("Collective payments of wages"), - "03": _("Standing order"), - "01": _("Transfer"), + "41": ["International credit transfers - non-SEPA credit transfers", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "66": "Financial centralisation (credit)", + "64": "Transfer to your account", + "50": "Transfer", + "49": "Cancellation or correction", + "38": "Costs relating to incoming foreign and non-SEPA transfers", + "37": "Costs relating to outgoing foreign transfers and non-SEPA transfers", + "17": "Financial centralisation (debit)", + "13": "Transfer from your account", + "07": "Collective transfers", + "05": "Collective payments of wages", + "03": "Standing order", + "01": "Transfer", }], - "43": [_("Foreign cheques"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "70": _("Purchase of traveller’s cheque"), - "62": _("Reversal of cheques"), - "58": _("Remittance of foreign cheque credit after collection"), - "52": _("Remittance of foreign cheque credit under usual reserve"), - "49": _("Cancellation or correction"), - "37": _("Costs relating to payment of foreign cheques"), - "15": _("Purchase of an international bank cheque"), - "07": _("Unpaid foreign cheque"), - "01": _("Payment of a foreign cheque"), + "43": ["Foreign cheques", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "70": "Purchase of traveller’s cheque", + "62": "Reversal of cheques", + "58": "Remittance of foreign cheque credit after collection", + "52": "Remittance of foreign cheque credit under usual reserve", + "49": "Cancellation or correction", + "37": "Costs relating to payment of foreign cheques", + "15": "Purchase of an international bank cheque", + "07": "Unpaid foreign cheque", + "01": "Payment of a foreign cheque", }], - "47": [_("Foreign commercial paper"), { - "99": _("Cancellation or correction"), - "87": _("Reimbursement of costs"), - "64": _("Warrant"), - "62": _("Remittance of documents abroad - credit after collection"), - "60": _("Remittance of documents abroad - credit under usual reserve"), - "58": _("Idem without guarantee"), - "56": _("Remittance of guaranteed foreign supplier's bill"), - "54": _("Discount abroad"), - "52": _("Remittance of foreign bill credit under usual reserve"), - "50": _("Remittance of foreign bill credit after collection"), - "49": _("Cancellation or correction"), - "37": _("Costs relating to the payment of a foreign bill"), - "14": _("Warrant fallen due"), - "13": _("Discount foreign supplier's bills"), - "11": _("Payment documents abroad"), - "07": _("Unpaid foreign bill"), - "06": _("Extension"), - "05": _("Bill claimed back"), - "01": _("Payment of foreign bill"), + "47": ["Foreign commercial paper", { + "99": "Cancellation or correction", + "87": "Reimbursement of costs", + "64": "Warrant", + "62": "Remittance of documents abroad - credit after collection", + "60": "Remittance of documents abroad - credit under usual reserve", + "58": "Idem without guarantee", + "56": "Remittance of guaranteed foreign supplier's bill", + "54": "Discount abroad", + "52": "Remittance of foreign bill credit under usual reserve", + "50": "Remittance of foreign bill credit after collection", + "49": "Cancellation or correction", + "37": "Costs relating to the payment of a foreign bill", + "14": "Warrant fallen due", + "13": "Discount foreign supplier's bills", + "11": "Payment documents abroad", + "07": "Unpaid foreign bill", + "06": "Extension", + "05": "Bill claimed back", + "01": "Payment of foreign bill", }], - "49": [_("Foreign counter transactions"), {"03": _("ATM withdrawal")}], - "80": [_("Separately charged costs and provisions"), { - "01": _("Guarantee card charges"), - "02": _("Costs relating to electronic output"), - "03": _("Payment card charges"), - "04": _("Costs for holding a documentary cash credit"), - "05": _("Card charges"), - "06": _("Damage relating to bills and cheques"), - "07": _("Insurance costs"), - "08": _("Registering compensation for savings accounts"), - "09": _("Postage"), - "10": _("Purchase of Smartcard"), - "11": _("Costs for the safe custody of correspondence"), - "12": _("Costs for opening a bank guarantee"), - "13": _("Renting of safes"), - "14": _("Handling costs instalment credit"), - "15": _("Night safe"), - "16": _("Bank confirmation to revisor or accountant"), - "17": _("Charge for safe custody"), - "18": _("Trade information"), - "19": _("Special charge for safe custody"), - "20": _("Drawing up a certificate"), - "21": _("Pay-packet charges"), - "22": _("Management/custody"), - "23": _("Research costs"), - "24": _("Participation in and management of interest refund system"), - "25": _("Renting of direct debit box"), - "26": _("Travel insurance premium"), - "27": _("Subscription fee"), - "29": _("Information charges"), - "31": _("Writ service fee"), - "33": _("Miscellaneous fees and commissions"), - "35": _("Costs"), - "37": _("Access right to database"), - "39": _("Surety fee"), - "41": _("Research costs"), - "43": _("Printing of forms"), - "45": _("Documentary credit charges"), - "47": _("Charging fees for transactions"), - "49": _("Cancellation or correction"), - "99": _("Cancellation or correction"), + "49": ["Foreign counter transactions", {"03": "ATM withdrawal"}], + "80": ["Separately charged costs and provisions", { + "01": "Guarantee card charges", + "02": "Costs relating to electronic output", + "03": "Payment card charges", + "04": "Costs for holding a documentary cash credit", + "05": "Card charges", + "06": "Damage relating to bills and cheques", + "07": "Insurance costs", + "08": "Registering compensation for savings accounts", + "09": "Postage", + "10": "Purchase of Smartcard", + "11": "Costs for the safe custody of correspondence", + "12": "Costs for opening a bank guarantee", + "13": "Renting of safes", + "14": "Handling costs instalment credit", + "15": "Night safe", + "16": "Bank confirmation to revisor or accountant", + "17": "Charge for safe custody", + "18": "Trade information", + "19": "Special charge for safe custody", + "20": "Drawing up a certificate", + "21": "Pay-packet charges", + "22": "Management/custody", + "23": "Research costs", + "24": "Participation in and management of interest refund system", + "25": "Renting of direct debit box", + "26": "Travel insurance premium", + "27": "Subscription fee", + "29": "Information charges", + "31": "Writ service fee", + "33": "Miscellaneous fees and commissions", + "35": "Costs", + "37": "Access right to database", + "39": "Surety fee", + "41": "Research costs", + "43": "Printing of forms", + "45": "Documentary credit charges", + "47": "Charging fees for transactions", + "49": "Cancellation or correction", + "99": "Cancellation or correction", }], } transaction_categories = { - "000": _("Net amount"), - "001": _("Interest received"), - "002": _("Interest paid"), - "003": _("Credit commission"), - "004": _("Postage"), - "005": _("Renting of letterbox"), - "006": _("Various fees/commissions"), - "007": _("Access right to database"), - "008": _("Information charges"), - "009": _("Travelling expenses"), - "010": _("Writ service fee"), - "011": _("VAT"), - "012": _("Exchange commission"), - "013": _("Payment commission"), - "014": _("Collection commission"), - "015": _("Correspondent charges"), - "016": _("BLIW/IBLC dues"), - "017": _("Research costs"), - "018": _("Tental guarantee charges"), - "019": _("Tax on physical delivery"), - "020": _("Costs of physical delivery"), - "021": _("Costs for drawing up a bank cheque"), - "022": _("Priority costs"), - "023": _("Exercising fee"), - "024": _("Growth premium"), - "025": _("Individual entry for exchange charges"), - "026": _("Handling commission"), - "027": _("Charges for unpaid bills"), - "028": _("Fidelity premium"), - "029": _("Protest charges"), - "030": _("Account insurance"), - "031": _("Charges foreign cheque"), - "032": _("Drawing up a circular cheque"), - "033": _("Charges for a foreign bill"), - "034": _("Reinvestment fee"), - "035": _("Charges foreign documentary bill"), - "036": _("Costs relating to a refused cheque"), - "037": _("Commission for handling charges"), - "039": _("Telecommunications"), - "041": _("Credit card costs"), - "042": _("Payment card costs"), - "043": _("Insurance costs"), - "045": _("Handling costs"), - "047": _("Charges extension bill"), - "049": _("Fiscal stamps/stamp duty"), - "050": _("Capital term investment"), - "051": _("Withholding tax"), - "052": _("Residence state tax"), - "053": _("Printing of forms"), - "055": _("Repayment loan or credit capital"), - "057": _("Interest subsidy"), - "058": _("Capital premium"), - "059": _("Default interest"), - "061": _("Charging fees for transactions"), - "063": _("Rounding differences"), - "065": _("Interest payment advice"), - "066": _("Fixed loan advance - reimbursement"), - "067": _("Fixed loan advance - extension"), - "068": _("Countervalue of an entry"), - "069": _("Forward arbitrage contracts : sum to be supplied by customer"), - "070": _("Forward arbitrage contracts : sum to be supplied by bank"), - "071": _("Fixed loan advance - availability"), - "072": _("Countervalue of commission to third party"), - "073": _("Costs of ATM abroad"), - "074": _("Mailing costs"), - "100": _("Gross amount"), - "200": _("Overall documentary credit charges"), - "201": _("Advice notice commission"), - "202": _("Advising commission | Additional advising commission"), - "203": _("Confirmation fee | Additional confirmation fee | Commitment fee | Flat fee | Confirmation reservation commission | Additional reservation commission"), - "204": _("Amendment fee"), - "205": _("Documentary payment commission | Document commission | Drawdown fee | Negotiation fee"), - "206": _("Surety fee/payment under reserve"), - "207": _("Non-conformity fee"), - "208": _("Commitment fee deferred payment"), - "209": _("Transfer commission"), - "210": _("Commitment fee"), - "211": _("Credit arrangement fee | Additional credit arrangement fee"), - "212": _("Warehousing fee"), - "213": _("Financing fee"), - "214": _("Issue commission (delivery order)"), - "400": _("Acceptance fee"), - "401": _("Visa charges"), - "402": _("Certification costs"), - "403": _("Minimum discount rate"), - "404": _("Discount commission"), - "405": _("Bill guarantee commission"), - "406": _("Collection charges"), - "407": _("Costs Article 45"), - "408": _("Cover commission"), - "409": _("Safe deposit charges"), - "410": _("Reclamation charges"), - "411": _("Fixed collection charge"), - "412": _("Advice of expiry charges"), - "413": _("Acceptance charges"), - "414": _("Regularisation charges"), - "415": _("Surety fee"), - "416": _("Charges for the deposit of security"), - "418": _("Endorsement commission"), - "419": _("Bank service fee"), - "420": _("Retention charges"), - "425": _("Foreign broker's commission"), - "426": _("Belgian broker's commission"), - "427": _("Belgian Stock Exchange tax"), - "428": _("Interest accrued"), - "429": _("Foreign Stock Exchange tax"), - "430": _("Recovery of foreign tax"), - "431": _("Delivery of a copy"), + "000": "Net amount", + "001": "Interest received", + "002": "Interest paid", + "003": "Credit commission", + "004": "Postage", + "005": "Renting of letterbox", + "006": "Various fees/commissions", + "007": "Access right to database", + "008": "Information charges", + "009": "Travelling expenses", + "010": "Writ service fee", + "011": "VAT", + "012": "Exchange commission", + "013": "Payment commission", + "014": "Collection commission", + "015": "Correspondent charges", + "016": "BLIW/IBLC dues", + "017": "Research costs", + "018": "Tental guarantee charges", + "019": "Tax on physical delivery", + "020": "Costs of physical delivery", + "021": "Costs for drawing up a bank cheque", + "022": "Priority costs", + "023": "Exercising fee", + "024": "Growth premium", + "025": "Individual entry for exchange charges", + "026": "Handling commission", + "027": "Charges for unpaid bills", + "028": "Fidelity premium", + "029": "Protest charges", + "030": "Account insurance", + "031": "Charges foreign cheque", + "032": "Drawing up a circular cheque", + "033": "Charges for a foreign bill", + "034": "Reinvestment fee", + "035": "Charges foreign documentary bill", + "036": "Costs relating to a refused cheque", + "037": "Commission for handling charges", + "039": "Telecommunications", + "041": "Credit card costs", + "042": "Payment card costs", + "043": "Insurance costs", + "045": "Handling costs", + "047": "Charges extension bill", + "049": "Fiscal stamps/stamp duty", + "050": "Capital term investment", + "051": "Withholding tax", + "052": "Residence state tax", + "053": "Printing of forms", + "055": "Repayment loan or credit capital", + "057": "Interest subsidy", + "058": "Capital premium", + "059": "Default interest", + "061": "Charging fees for transactions", + "063": "Rounding differences", + "065": "Interest payment advice", + "066": "Fixed loan advance - reimbursement", + "067": "Fixed loan advance - extension", + "068": "Countervalue of an entry", + "069": "Forward arbitrage contracts : sum to be supplied by customer", + "070": "Forward arbitrage contracts : sum to be supplied by bank", + "071": "Fixed loan advance - availability", + "072": "Countervalue of commission to third party", + "073": "Costs of ATM abroad", + "074": "Mailing costs", + "100": "Gross amount", + "200": "Overall documentary credit charges", + "201": "Advice notice commission", + "202": "Advising commission | Additional advising commission", + "203": "Confirmation fee | Additional confirmation fee | Commitment fee | Flat fee | Confirmation reservation commission | Additional reservation commission", + "204": "Amendment fee", + "205": "Documentary payment commission | Document commission | Drawdown fee | Negotiation fee", + "206": "Surety fee/payment under reserve", + "207": "Non-conformity fee", + "208": "Commitment fee deferred payment", + "209": "Transfer commission", + "210": "Commitment fee", + "211": "Credit arrangement fee | Additional credit arrangement fee", + "212": "Warehousing fee", + "213": "Financing fee", + "214": "Issue commission (delivery order)", + "400": "Acceptance fee", + "401": "Visa charges", + "402": "Certification costs", + "403": "Minimum discount rate", + "404": "Discount commission", + "405": "Bill guarantee commission", + "406": "Collection charges", + "407": "Costs Article 45", + "408": "Cover commission", + "409": "Safe deposit charges", + "410": "Reclamation charges", + "411": "Fixed collection charge", + "412": "Advice of expiry charges", + "413": "Acceptance charges", + "414": "Regularisation charges", + "415": "Surety fee", + "416": "Charges for the deposit of security", + "418": "Endorsement commission", + "419": "Bank service fee", + "420": "Retention charges", + "425": "Foreign broker's commission", + "426": "Belgian broker's commission", + "427": "Belgian Stock Exchange tax", + "428": "Interest accrued", + "429": "Foreign Stock Exchange tax", + "430": "Recovery of foreign tax", + "431": "Delivery of a copy", } From 7232c1f986718bf9808af4d625dd163637cb3ac1 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 12:18:16 +0100 Subject: [PATCH 12/41] [DEL]Useless dependances + [ADD]Statement journal depending on bank account, statement line account depending on bank accont or partner if setted, statement line type bzr revid: dle@openerp.com-20121206111816-c0t7mfy1x6seezev --- addons/l10n_be_coda/__openerp__.py | 2 +- .../wizard/account_coda_import.py | 26 ++++++++++++++----- 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/addons/l10n_be_coda/__openerp__.py b/addons/l10n_be_coda/__openerp__.py index 14e1bf6e443..0cb29bcc002 100644 --- a/addons/l10n_be_coda/__openerp__.py +++ b/addons/l10n_be_coda/__openerp__.py @@ -90,7 +90,7 @@ V2.2 specifications. If required, you can manually adjust the descriptions via the CODA configuration menu. ''', 'images' : ['images/coda_logs.jpeg','images/import_coda_logs.jpeg'], - 'depends': ['account_voucher','base_iban', 'l10n_be_invoice_bba', 'account_bank_statement_extensions'], + 'depends': ['account_voucher','base_iban', 'l10n_be_invoice_bba',], 'demo': [], 'data': [ 'l10n_be_coda_wizard.xml', diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 2286caf8f68..eac8f83e6da 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -262,25 +262,39 @@ class account_coda_import(osv.osv_memory): line['counterpartyNumber'] = False except: pass + partner = None partner_id = None if 'counterpartyNumber' in line and line['counterpartyNumber']: ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) if ids and len(ids) > 0: - partner_id = self.pool.get('res.partner.bank').browse(cr, uid, ids[0], context=context).partner_id.id + partner = self.pool.get('res.partner.bank').browse(cr, uid, ids[0], context=context).partner_id + partner_id = partner.id + if partner: + if partner.customer: + line['type'] = 'customer' else: - partner_id = None + line['type'] = 'supplier' + if line['debit'] == '1': + line['account'] = partner.property_account_payable.id + else: + line['account'] = partner.property_account_receivable.id + else: + line['type'] = 'general' + if line['debit'] == '1': + line['account'] = statement['journal_id'].default_debit_account_id.id + else: + line['account'] = statement['journal_id'].default_credit_account_id.id + data = { 'name': line['communication'], 'note': "\n".join(note), 'date': line['entryDate'], 'amount': line['amount'], - # 'type': '', + 'type': line['type'], 'partner_id': partner_id, - 'account_id': 1, # TODO + 'account_id': line['account'], 'statement_id': statement['id'], - # 'analytic_account_id': '', - # 'move_ids': '', 'ref': line['ref'], 'sequence': line['sequence'], } From d8a949edffc9e3f973680b4bd95f49f7a1e114b1 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 12:27:02 +0100 Subject: [PATCH 13/41] [ADD]Structured communications bzr revid: dle@openerp.com-20121206112702-ii47dx25r7amegrq --- addons/l10n_be_coda/wizard/account_coda_import.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index eac8f83e6da..fdabf9e8615 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -126,7 +126,11 @@ class account_coda_import(osv.osv_memory): statementLine['transaction_family'] = rmspaces(line[54:56]) statementLine['transaction_code'] = rmspaces(line[56:58]) statementLine['transaction_category'] = rmspaces(line[58:61]) - statementLine['communication'] = rmspaces(line[62:115]) + if line[61] == '1': + #Structured communication + statementLine['communication'] = '+++' + line[65:68] + '/' + line[68:72] + '/' + line[72:77] + '+++' + else: + statementLine['communication'] = rmspaces(line[62:115]) statementLine['entryDate'] = rmspaces(line[115:121]) statementLine['type'] = 'normal' statementLine['globalisation'] = int(line[124]) From 0fc6e5480bef93c8729d39c04444c22fd1b6a3fa Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 16:12:07 +0100 Subject: [PATCH 14/41] [FIX]Name field displayed back in bank statement form (instead of displaying notes), handling structured communication types, defining account depending on partner found thanks to invoice or bank account bzr revid: dle@openerp.com-20121206151207-o8zxzfoybmlv3u6b --- addons/account/account_view.xml | 3 +- .../wizard/account_coda_import.py | 140 +++++++++++++----- 2 files changed, 106 insertions(+), 37 deletions(-) diff --git a/addons/account/account_view.xml b/addons/account/account_view.xml index 7d18961a5a3..6d3519cc461 100644 --- a/addons/account/account_view.xml +++ b/addons/account/account_view.xml @@ -574,9 +574,8 @@ - - + diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index fdabf9e8615..d0ecefa6a9b 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -128,8 +128,12 @@ class account_coda_import(osv.osv_memory): statementLine['transaction_category'] = rmspaces(line[58:61]) if line[61] == '1': #Structured communication + statementLine['communication_struct'] = True + statementLine['communication_type'] = line[62:65] statementLine['communication'] = '+++' + line[65:68] + '/' + line[68:72] + '/' + line[72:77] + '+++' else: + #Non-structured communication + statementLine['communication_struct'] = False statementLine['communication'] = rmspaces(line[62:115]) statementLine['entryDate'] = rmspaces(line[115:121]) statementLine['type'] = 'normal' @@ -156,7 +160,8 @@ class account_coda_import(osv.osv_memory): raise osv.except_osv(_('Error') + 'R2005', _('CODA parsing error on movement data record 2.3, seq nr %s! Please report this issue via your OpenERP support channel.') % line[2:10]) if statement['version'] == '1': statement['lines'][-1]['counterpartyNumber'] = rmspaces(line[10:22]) - statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:125]) + statement['lines'][-1]['counterpartyName'] = rmspaces(line[47:73]) + statement['lines'][-1]['counterpartyAddress'] = rmspaces(line[73:125]) statement['lines'][-1]['counterpartyCurrency'] = '' else: if line[22] == ' ': @@ -235,15 +240,76 @@ class account_coda_import(osv.osv_memory): statement['id'] = self.pool.get('account.bank.statement').create(cr, uid, data, context=context) for line in statement['lines']: if line['type'] == 'normal': + note = [] counterparty = [] if 'counterpartyName' in line: counterparty.append(line['counterpartyName']) - if 'counterpartyNumber' in line: + try: + if 'counterpartyNumber' in line and int(line['counterpartyNumber']) == 0: + line['counterpartyNumber'] = False + except: + pass + if 'counterpartyNumber' in line and line['counterpartyNumber']: counterparty.append(line['counterpartyNumber']) if len(counterparty) > 0: counterparty = '[' + ' / '.join(counterparty) + ']' else: counterparty = '/' + note.append(_('Counter Party') + ': ' + counterparty) + + partner = None + partner_id = None + invoice = False + if line['communication_struct'] and 'communication_type' in line and line['communication_type'] == '101': + ids = self.pool.get('account.invoice').search(cr, uid, [('reference', '=', line['communication']), ('reference_type', '=', 'bba')]) + if ids: + invoice = self.pool.get('account.invoice').browse(cr, uid, ids[0]) + partner = invoice.partner_id + partner_id = partner.id + if invoice.type in ['in_invoice', 'in_refund']: + line['type'] = 'supplier' + else: + line['type'] = 'customer' + if 'counterpartyNumber' in line and line['counterpartyNumber']: + ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) + if ids and len(ids) > 0: + partner = self.pool.get('res.partner.bank').browse(cr, uid, ids[0], context=context).partner_id + partner_id = partner.id + if not invoice: + if partner.customer and line['debit'] == '0': + line['type'] = 'customer' + elif partner.supplier and line['debit'] == '1': + line['type'] = 'supplier' + else: + line['type'] = 'general' + # if line['debit'] == '1': + # line['account'] = partner.property_account_payable.id + # else: + # line['account'] = partner.property_account_receivable.id + if partner: + if line['type'] == 'customer': + line['account'] = partner.property_account_receivable.id + elif line['type'] == 'supplier': + line['account'] = partner.property_account_payable.id + else: + if line['debit'] == '1': + line['account'] = partner.property_account_payable.id + else: + line['account'] = partner.property_account_receivable.id + note.append(_('Communication') + ': ' + line['communication']) + if not partner: + line['type'] = 'general' + if line['debit'] == '1': + line['account'] = statement['journal_id'].default_debit_account_id.id + else: + line['account'] = statement['journal_id'].default_credit_account_id.id + note.append(_('Communication') + ': ' + line['communication']) + if 'communication_type' in line: + if line['communication_type'] in communication_types: + line['communication_type'] = communication_types[line['communication_type']] + else: + line['communication_type'] = 'Unknown' + note.append(_('Communication Type') + ': ' + line['communication_type']) if line['transaction_type'] in transaction_types: line['transaction_type'] = transaction_types[line['transaction_type']][1] if line['transaction_category'] in transaction_categories: @@ -253,45 +319,13 @@ class account_coda_import(osv.osv_memory): line['transaction_family'] = transaction_family[0] if line['transaction_code'] in transaction_family[1]: line['transaction_code'] = transaction_family[1][line['transaction_code']] - note = [] - note.append(_('Counter Party') + ': ' + counterparty) - note.append(_('Communication') + ': ' + line['communication']) note.append(_('Transaction type') + ': ' + line['transaction_type']) note.append(_('Transaction family') + ': ' + line['transaction_family']) note.append(_('Transaction code') + ': ' + line['transaction_code']) note.append(_('Transaction category') + ': ' + line['transaction_category']) - try: - if 'counterpartyNumber' in line and int(line['counterpartyNumber']) == 0: - line['counterpartyNumber'] = False - except: - pass - partner = None - partner_id = None - if 'counterpartyNumber' in line and line['counterpartyNumber']: - ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) - if ids and len(ids) > 0: - partner = self.pool.get('res.partner.bank').browse(cr, uid, ids[0], context=context).partner_id - partner_id = partner.id - if partner: - if partner.customer: - line['type'] = 'customer' - else: - line['type'] = 'supplier' - if line['debit'] == '1': - line['account'] = partner.property_account_payable.id - else: - line['account'] = partner.property_account_receivable.id - else: - line['type'] = 'general' - if line['debit'] == '1': - line['account'] = statement['journal_id'].default_debit_account_id.id - else: - line['account'] = statement['journal_id'].default_credit_account_id.id - - data = { - 'name': line['communication'], + 'name': counterparty + '\n' + line['communication'], 'note': "\n".join(note), 'date': line['entryDate'], 'amount': line['amount'], @@ -752,6 +786,42 @@ transaction_categories = { "431": "Delivery of a copy", } +communication_types = { + "001": "Data concerning the counterparty", + "002": "Communication of the bank", + "003": "RBP data", + "004": "Counterparty’s banker", + "005": "Data concerning the correspondent", + "006": "Information concerning the detail amount", + "007": "Information concerning the detail cash", + "008": "Identification of the de ultimate beneficiary/creditor (SEPA SCT/SDD)", + "009": "Identification of the de ultimate ordering customer/debtor (SEPA SCT/SDD)", + "010": "Information pertaining to sale or purchase of securities", + "011": "Information pertaining to coupons", + "100": "(SEPA) payment with a structured format communication applying the ISO standard 11649: Structured creditor reference to remittan", + "101": "Credit transfer or cash payment with structured format communication", + "102": "Credit transfer or cash payment with reconstituted structured format communication", + "103": "number (e.g. of the cheque, of the card, etc.)", + "104": "Equivalent in EUR", + "105": "original amount of the transaction", + "106": "Method of calculation (VAT, withholding tax on income, commission, etc.)", + "107": "Direct debit – DOM’80", + "108": "Closing", + "111": "POS credit – Globalisation", + "112": "ATM payment (usually Eurocheque card)", + "113": "ATM/POS debit", + "114": "POS credit - individual transaction", + "115": "Terminal cash deposit", + "120": "Correction of a transaction", + "121": "Commercial bills", + "122": "Bills - calculation of interest", + "123": "Fees and commissions", + "124": "Number of the credit card", + "125": "Credit", + "126": "Term investments", + "127": "European direct debit (SEPA)", +} + def rmspaces(s): return " ".join(s.split()) From 512a5c5ed6eb135b6005b549e1c93500bb6c1b1d Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 16:12:54 +0100 Subject: [PATCH 15/41] [DEL]Useless comment bzr revid: dle@openerp.com-20121206151254-qtedm28bxagp4shy --- addons/l10n_be_coda/wizard/account_coda_import.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index d0ecefa6a9b..5e6df14ffb4 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -282,10 +282,6 @@ class account_coda_import(osv.osv_memory): line['type'] = 'supplier' else: line['type'] = 'general' - # if line['debit'] == '1': - # line['account'] = partner.property_account_payable.id - # else: - # line['account'] = partner.property_account_receivable.id if partner: if line['type'] == 'customer': line['account'] = partner.property_account_receivable.id From 15b03bb0b684c4118adca60844ddcaaad3244e3b Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 16:55:24 +0100 Subject: [PATCH 16/41] [FIX]Name and note field not well structured bzr revid: dle@openerp.com-20121206155524-hha9r6ab931b3cj9 --- .../wizard/account_coda_import.py | 33 ++++++++++--------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 5e6df14ffb4..aab468adcc9 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -241,21 +241,23 @@ class account_coda_import(osv.osv_memory): for line in statement['lines']: if line['type'] == 'normal': note = [] - counterparty = [] - if 'counterpartyName' in line: - counterparty.append(line['counterpartyName']) - try: - if 'counterpartyNumber' in line and int(line['counterpartyNumber']) == 0: - line['counterpartyNumber'] = False - except: - pass - if 'counterpartyNumber' in line and line['counterpartyNumber']: - counterparty.append(line['counterpartyNumber']) - if len(counterparty) > 0: - counterparty = '[' + ' / '.join(counterparty) + ']' + if 'counterpartyName' in line and line['counterpartyName'] != '': + note.append(_('Counter Party') + ': ' + line['counterpartyName']) else: - counterparty = '/' - note.append(_('Counter Party') + ': ' + counterparty) + line['counterpartyName'] = False + if 'counterpartyNumber' in line and line['counterpartyNumber'] != '': + try: + if int(line['counterpartyNumber']) == 0: + line['counterpartyNumber'] = False + except: + pass + if line['counterpartyNumber']: + note.append(_('Counter Party Account') + ': ' + line['counterpartyNumber']) + else: + line['counterpartyNumber'] = False + + if 'counterpartyAddress' in line and line['counterpartyAddress'] != '': + note.append(_('Counter Party Address') + ': ' + line['counterpartyAddress']) partner = None partner_id = None @@ -292,7 +294,6 @@ class account_coda_import(osv.osv_memory): line['account'] = partner.property_account_payable.id else: line['account'] = partner.property_account_receivable.id - note.append(_('Communication') + ': ' + line['communication']) if not partner: line['type'] = 'general' if line['debit'] == '1': @@ -321,7 +322,7 @@ class account_coda_import(osv.osv_memory): note.append(_('Transaction category') + ': ' + line['transaction_category']) data = { - 'name': counterparty + '\n' + line['communication'], + 'name': "\n".join(filter(None, [line['counterpartyName'], line['communication']])), 'note': "\n".join(note), 'date': line['entryDate'], 'amount': line['amount'], From 8f9ff4d19acd91ec63cd6a478ebaa1b2f677d6c4 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 16:59:37 +0100 Subject: [PATCH 17/41] [FIX]Entry date not parsed by strftime :( bzr revid: dle@openerp.com-20121206155937-8ngexk7iulkt04va --- addons/l10n_be_coda/wizard/account_coda_import.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index aab468adcc9..81bd2458496 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -135,7 +135,7 @@ class account_coda_import(osv.osv_memory): #Non-structured communication statementLine['communication_struct'] = False statementLine['communication'] = rmspaces(line[62:115]) - statementLine['entryDate'] = rmspaces(line[115:121]) + statementLine['entryDate'] = time.strftime(tools.DEFAULT_SERVER_DATE_FORMAT, time.strptime(rmspaces(line[115:121]), '%d%m%y')) statementLine['type'] = 'normal' statementLine['globalisation'] = int(line[124]) if len(statement['globalisation_stack']) > 0 and statementLine['communication'] != '': From f876c1993068b4087e5d49a536da118db40f7e50 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 17:49:28 +0100 Subject: [PATCH 18/41] [ADD]Create voucher bzr revid: dle@openerp.com-20121206164928-axdnk309y2o3zwrr --- .../wizard/account_coda_import.py | 26 ++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 81bd2458496..f1fcc8fd760 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -258,6 +258,7 @@ class account_coda_import(osv.osv_memory): if 'counterpartyAddress' in line and line['counterpartyAddress'] != '': note.append(_('Counter Party Address') + ': ' + line['counterpartyAddress']) + line['name'] = "\n".join(filter(None, [line['counterpartyName'], line['communication']])) partner = None partner_id = None @@ -268,10 +269,29 @@ class account_coda_import(osv.osv_memory): invoice = self.pool.get('account.invoice').browse(cr, uid, ids[0]) partner = invoice.partner_id partner_id = partner.id - if invoice.type in ['in_invoice', 'in_refund']: + # voucher_vals = { + # 'type': line['type'] == 'supplier' and 'payment' or 'receipt', + # 'name': line_name, + # 'partner_id': line['partner_id'], + # 'journal_id': statement['journal_id'], + # 'account_id': journal.default_credit_account_id.id, + # 'company_id': journal.company_id.id, + # 'currency_id': journal.company_id.currency_id.id, + # 'date': line['entry_date'], + # 'amount': abs(line['amount']), + # 'period_id': statement['period_id'], + # } + context = {'line_type': line['type'], 'default_type': line['amount'] < 0 and 'payment' or 'receipt', 'type': line['amount'] < 0 and 'payment' or 'receipt', 'default_partner_id': partner_id, 'default_journal_id': statement['journal_id'].id, 'default_amount': abs(line['amount']), 'default_reference': line['ref'], 'default_date': line['entryDate'], 'default_name': line['name'], 'default_active': False} + if invoice.type in ['in_invoice', 'in_refund'] and line['debit'] == '1': line['type'] = 'supplier' - else: + print 'Supplier' + print self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_payable.id}, context=context) + elif invoice.type in ['out_invoice'] and line['debit'] == '0': line['type'] = 'customer' + print 'Customer' + print self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_receivable.id}, context=context) + else: + line['type'] = 'general' if 'counterpartyNumber' in line and line['counterpartyNumber']: ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) if ids and len(ids) > 0: @@ -322,7 +342,7 @@ class account_coda_import(osv.osv_memory): note.append(_('Transaction category') + ': ' + line['transaction_category']) data = { - 'name': "\n".join(filter(None, [line['counterpartyName'], line['communication']])), + 'name': line['name'], 'note': "\n".join(note), 'date': line['entryDate'], 'amount': line['amount'], From 6cb854df33e7ec5f543c9c13a68065b4a9b288b5 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Thu, 6 Dec 2012 18:35:30 +0100 Subject: [PATCH 19/41] [ADD]Voucher creation bzr revid: dle@openerp.com-20121206173530-s46asy6pomk6if4t --- .../wizard/account_coda_import.py | 33 +++++++++---------- 1 file changed, 15 insertions(+), 18 deletions(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index f1fcc8fd760..6de8bdc8104 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -269,27 +269,22 @@ class account_coda_import(osv.osv_memory): invoice = self.pool.get('account.invoice').browse(cr, uid, ids[0]) partner = invoice.partner_id partner_id = partner.id - # voucher_vals = { - # 'type': line['type'] == 'supplier' and 'payment' or 'receipt', - # 'name': line_name, - # 'partner_id': line['partner_id'], - # 'journal_id': statement['journal_id'], - # 'account_id': journal.default_credit_account_id.id, - # 'company_id': journal.company_id.id, - # 'currency_id': journal.company_id.currency_id.id, - # 'date': line['entry_date'], - # 'amount': abs(line['amount']), - # 'period_id': statement['period_id'], - # } - context = {'line_type': line['type'], 'default_type': line['amount'] < 0 and 'payment' or 'receipt', 'type': line['amount'] < 0 and 'payment' or 'receipt', 'default_partner_id': partner_id, 'default_journal_id': statement['journal_id'].id, 'default_amount': abs(line['amount']), 'default_reference': line['ref'], 'default_date': line['entryDate'], 'default_name': line['name'], 'default_active': False} + context = { + 'default_partner_id': partner_id, + 'default_amount': abs(line['amount']), + 'default_number': invoice.name, + 'close_after_process': True, + 'invoice_type': invoice.type, + 'invoice_id': invoice.id, + 'default_type': invoice.type in ['out_invoice', 'out_refund'] and 'receipt' or 'payment', + 'type': invoice.type in ['out_invoice', 'out_refund'] and 'receipt' or 'payment' + } if invoice.type in ['in_invoice', 'in_refund'] and line['debit'] == '1': line['type'] = 'supplier' - print 'Supplier' - print self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_payable.id}, context=context) + line['voucher_id'] = self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_payable.id, 'journal_id': statement['journal_id'].id}, context=context) elif invoice.type in ['out_invoice'] and line['debit'] == '0': line['type'] = 'customer' - print 'Customer' - print self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_receivable.id}, context=context) + line['voucher_id'] = self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_receivable.id, 'journal_id': statement['journal_id'].id}, context=context) else: line['type'] = 'general' if 'counterpartyNumber' in line and line['counterpartyNumber']: @@ -340,7 +335,8 @@ class account_coda_import(osv.osv_memory): note.append(_('Transaction family') + ': ' + line['transaction_family']) note.append(_('Transaction code') + ': ' + line['transaction_code']) note.append(_('Transaction category') + ': ' + line['transaction_category']) - + if 'voucher_id' not in line: + line['voucher_id'] = None data = { 'name': line['name'], 'note': "\n".join(note), @@ -352,6 +348,7 @@ class account_coda_import(osv.osv_memory): 'statement_id': statement['id'], 'ref': line['ref'], 'sequence': line['sequence'], + 'voucher_id': line['voucher_id'], } self.pool.get('account.bank.statement.line').create(cr, uid, data, context=context) From bee5426c7093e3292441a214882e0207b7f9d8b0 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 7 Dec 2012 13:58:38 +0100 Subject: [PATCH 20/41] [FIX]Voucher and voucher line bzr revid: dle@openerp.com-20121207125838-n36yyge5d1vm65ir --- .../wizard/account_coda_import.py | 49 ++++++++++++++----- 1 file changed, 36 insertions(+), 13 deletions(-) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 6de8bdc8104..97d99b89e83 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -269,24 +269,47 @@ class account_coda_import(osv.osv_memory): invoice = self.pool.get('account.invoice').browse(cr, uid, ids[0]) partner = invoice.partner_id partner_id = partner.id - context = { - 'default_partner_id': partner_id, - 'default_amount': abs(line['amount']), - 'default_number': invoice.name, - 'close_after_process': True, - 'invoice_type': invoice.type, - 'invoice_id': invoice.id, - 'default_type': invoice.type in ['out_invoice', 'out_refund'] and 'receipt' or 'payment', - 'type': invoice.type in ['out_invoice', 'out_refund'] and 'receipt' or 'payment' - } + if invoice.type in ['in_invoice', 'in_refund'] and line['debit'] == '1': line['type'] = 'supplier' - line['voucher_id'] = self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_payable.id, 'journal_id': statement['journal_id'].id}, context=context) - elif invoice.type in ['out_invoice'] and line['debit'] == '0': + elif invoice.type in ['out_invoice', 'out_refund'] and line['debit'] == '0': line['type'] = 'customer' - line['voucher_id'] = self.pool.get('account.voucher').create(cr, uid, {'account_id': partner.property_account_receivable.id, 'journal_id': statement['journal_id'].id}, context=context) else: line['type'] = 'general' + line['reconcile'] = False + if invoice.type in ['in_invoice', 'out_invoice']: + iml_ids = self.pool.get('account.move.line').search(cr, uid, [('move_id', '=', invoice.move_id.id), ('reconcile_id', '=', False), ('account_id.reconcile', '=', True)]) + if iml_ids: + line['reconcile'] = iml_ids[0] + if line['reconcile']: + voucher_vals = { + 'type': line['type'] == 'supplier' and 'payment' or 'receipt', + 'name': line['name'], + 'partner_id': partner_id, + 'journal_id': statement['journal_id'].id, + 'account_id': statement['journal_id'].default_credit_account_id.id, + 'company_id': statement['journal_id'].company_id.id, + 'currency_id': statement['journal_id'].company_id.currency_id.id, + 'date': line['entryDate'], + 'amount': abs(line['amount']), + 'period_id': statement['period_id'], + 'invoice_id': invoice.id, + } + context['invoice_id'] = invoice.id + voucher_vals.update(self.pool.get('account.voucher').onchange_partner_id(cr, uid, [], + partner_id=partner_id, + journal_id=statement['journal_id'].id, + amount=abs(line['amount']), + currency_id=statement['journal_id'].company_id.currency_id.id, + ttype=line['type'] == 'supplier' and 'payment' or 'receipt', + date=line['transactionDate'], + context=context + )['value']) + line_drs = [] + for line_dr in voucher_vals['line_dr_ids']: + line_drs.append((0, 0, line_dr)) + voucher_vals['line_dr_ids'] = line_drs + line['voucher_id'] = self.pool.get('account.voucher').create(cr, uid, voucher_vals, context=context) if 'counterpartyNumber' in line and line['counterpartyNumber']: ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) if ids and len(ids) > 0: From a0a3f862cca0c64dfd19053fb51c68b78ab17ede Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 7 Dec 2012 15:14:50 +0100 Subject: [PATCH 21/41] [ADD]CODA Notes and statement lines views bzr revid: dle@openerp.com-20121207141450-i5kzwm1ojvkw42hy --- addons/l10n_be_coda/__init__.py | 1 + addons/l10n_be_coda/l10n_be_coda_view.xml | 93 ++++++++++++++++++- .../wizard/account_coda_import.py | 26 ++++-- 3 files changed, 110 insertions(+), 10 deletions(-) diff --git a/addons/l10n_be_coda/__init__.py b/addons/l10n_be_coda/__init__.py index c737eb79536..4a58b8ad059 100644 --- a/addons/l10n_be_coda/__init__.py +++ b/addons/l10n_be_coda/__init__.py @@ -20,6 +20,7 @@ # ############################################################################## +import l10n_be_coda import wizard # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/l10n_be_coda_view.xml b/addons/l10n_be_coda/l10n_be_coda_view.xml index 9a362cd6fc4..d4c896064a6 100644 --- a/addons/l10n_be_coda/l10n_be_coda_view.xml +++ b/addons/l10n_be_coda/l10n_be_coda_view.xml @@ -1,6 +1,97 @@ - + + account.bank.statement.form + account.bank.statement + + + + + + + + + + + bank.statement.line.coda.form + account.bank.statement.line + 10 + +
+ + + + + + + + + + + + + + + +
+ + account.bank.statement.line.coda.tree + account.bank.statement.line + 10 + + + + + + + + + + + + + + + + + + bank.statement.line.coda.filter + account.bank.statement.line + + + + + + + + + + + + + + + + + + + + + + + + + Bank Statement Lines + account.bank.statement.line + form + tree,form + {'block_statement_line_delete' : 1} + + + + + +
\ No newline at end of file diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 97d99b89e83..9513d7accc2 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -188,8 +188,6 @@ class account_coda_import(osv.osv_memory): infoLine['transaction_code'] = rmspaces(line[34:36]) infoLine['transaction_category'] = rmspaces(line[36:39]) infoLine['communication'] = rmspaces(line[40:113]) - infoLine['amount'] = 0.0 - infoLine['type'] = 'information' statement['lines'].append(infoLine) elif line[1] == '2': if infoLine['ref'] != rmspaces(line[2:10]): @@ -205,8 +203,6 @@ class account_coda_import(osv.osv_memory): comm_line['sequence'] = len(statement['lines']) + 1 comm_line['ref'] = rmspaces(line[2:10]) comm_line['communication'] = rmspaces(line[32:112]) - comm_line['amount'] = 0.0 - comm_line['type'] = 'communication' statement['lines'].append(comm_line) elif line[0] == '8': # new balance record @@ -229,6 +225,7 @@ class account_coda_import(osv.osv_memory): if not statement['balance_end_real']: statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] for i, statement in enumerate(statements): + statement['coda_note'] = '' data = { 'name': '[' + statement['date'] + ']' + statement['description'], 'date': statement['date'], @@ -239,7 +236,20 @@ class account_coda_import(osv.osv_memory): } statement['id'] = self.pool.get('account.bank.statement').create(cr, uid, data, context=context) for line in statement['lines']: - if line['type'] == 'normal': + if line['type'] == 'information': + if line['transaction_type'] in transaction_types: + line['transaction_type'] = transaction_types[line['transaction_type']][1] + if line['transaction_category'] in transaction_categories: + line['transaction_category'] = transaction_categories[line['transaction_category']] + if line['transaction_family'] in transaction_codes: + transaction_family = transaction_codes[line['transaction_family']] + line['transaction_family'] = transaction_family[0] + if line['transaction_code'] in transaction_family[1]: + line['transaction_code'] = transaction_family[1][line['transaction_code']] + statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Date: ' + str(line['entryDate']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'],'\n']) + elif line['type'] == 'communication': + statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'],'\n']) + elif line['type'] == 'normal': note = [] if 'counterpartyName' in line and line['counterpartyName'] != '': note.append(_('Counter Party') + ': ' + line['counterpartyName']) @@ -259,7 +269,6 @@ class account_coda_import(osv.osv_memory): if 'counterpartyAddress' in line and line['counterpartyAddress'] != '': note.append(_('Counter Party Address') + ': ' + line['counterpartyAddress']) line['name'] = "\n".join(filter(None, [line['counterpartyName'], line['communication']])) - partner = None partner_id = None invoice = False @@ -342,8 +351,6 @@ class account_coda_import(osv.osv_memory): if 'communication_type' in line: if line['communication_type'] in communication_types: line['communication_type'] = communication_types[line['communication_type']] - else: - line['communication_type'] = 'Unknown' note.append(_('Communication Type') + ': ' + line['communication_type']) if line['transaction_type'] in transaction_types: line['transaction_type'] = transaction_types[line['transaction_type']][1] @@ -374,7 +381,8 @@ class account_coda_import(osv.osv_memory): 'voucher_id': line['voucher_id'], } self.pool.get('account.bank.statement.line').create(cr, uid, data, context=context) - + if statement['coda_note'] != '': + self.pool.get('account.bank.statement').write(cr, uid, [statement['id']], {'coda_note': statement['coda_note']}, context=context) account_coda_import() transaction_types = { From 16bfe104aa6d1b49e685930b645b1017704d993e Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 7 Dec 2012 15:15:09 +0100 Subject: [PATCH 22/41] [ADD]coda py file bzr revid: dle@openerp.com-20121207141509-7i8evz7i5dn00b11 --- addons/l10n_be_coda/l10n_be_coda.py | 34 +++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 addons/l10n_be_coda/l10n_be_coda.py diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py new file mode 100644 index 00000000000..e22bec27aab --- /dev/null +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -0,0 +1,34 @@ +# -*- encoding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# +# Copyright (c) 2011 Noviat nv/sa (www.noviat.be). All rights reserved. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +from osv import osv, fields + + +class account_bank_statement(osv.osv): + _inherit = 'account.bank.statement' + _columns = { + 'coda_note': fields.text('CODA Notes'), + } + +account_bank_statement() + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: From 8825ea3ae64180c89c15651ad19e2c28af55c32c Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 7 Dec 2012 15:31:44 +0100 Subject: [PATCH 23/41] [FIX]coda note with int not str, import wizard returns to banks statement tree bzr revid: dle@openerp.com-20121207143144-13vfmr4o37e1rntb --- addons/l10n_be_coda/l10n_be_coda_wizard.xml | 19 ------------------- .../wizard/account_coda_import.py | 18 +++++++++++++----- 2 files changed, 13 insertions(+), 24 deletions(-) diff --git a/addons/l10n_be_coda/l10n_be_coda_wizard.xml b/addons/l10n_be_coda/l10n_be_coda_wizard.xml index 427e0c1991e..92b16db0e88 100644 --- a/addons/l10n_be_coda/l10n_be_coda_wizard.xml +++ b/addons/l10n_be_coda/l10n_be_coda_wizard.xml @@ -21,25 +21,6 @@
- - Import CODA File - account.coda.import - 2 - -
-
-
- - - -
-
-
- Import CODA File ir.actions.act_window diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 9513d7accc2..1118f5a4ae6 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -89,10 +89,10 @@ class account_coda_import(osv.osv_memory): raise osv.except_osv(_('Error') + 'R1002', _('Foreign bank accounts with IBAN structure are not supported ')) else: # Something else, not supported raise osv.except_osv(_('Error') + 'R1003', _('Unsupported bank account structure ')) - ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', statement['acc_number'])]) + bank_ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', statement['acc_number'])]) not_found_except = osv.except_osv(_('Error') + 'R1004', _("No matching CODA Bank Account Configuration record found. Please check if the 'Bank Account Number' and 'Currency' fields of your configuration record match with '%s' and '%s'.") % (statement['acc_number'], statement['currency'])) - if ids and len(ids) > 0: - bank_accs = self.pool.get('res.partner.bank').browse(cr, uid, ids) + if bank_ids and len(bank_ids) > 0: + bank_accs = self.pool.get('res.partner.bank').browse(cr, uid, bank_ids) for bank_acc in bank_accs: statement['journal_id'] = bank_acc.journal_id if (statement['journal_id'].currency and statement['journal_id'].currency.name != statement['currency']) and (not statement['journal_id'].currency and statement['journal_id'].company_id.currency_id.name != statement['currency']): @@ -246,9 +246,9 @@ class account_coda_import(osv.osv_memory): line['transaction_family'] = transaction_family[0] if line['transaction_code'] in transaction_family[1]: line['transaction_code'] = transaction_family[1][line['transaction_code']] - statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Date: ' + str(line['entryDate']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'],'\n']) + statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Date: ' + str(line['entryDate']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'], '\n']) elif line['type'] == 'communication': - statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'],'\n']) + statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'], '\n']) elif line['type'] == 'normal': note = [] if 'counterpartyName' in line and line['counterpartyName'] != '': @@ -383,6 +383,14 @@ class account_coda_import(osv.osv_memory): self.pool.get('account.bank.statement.line').create(cr, uid, data, context=context) if statement['coda_note'] != '': self.pool.get('account.bank.statement').write(cr, uid, [statement['id']], {'coda_note': statement['coda_note']}, context=context) + return { + 'view_type': 'form', + 'view_mode': 'tree', + 'res_model': 'account.bank.statement', + 'view_id': False, + 'context': context, + 'type': 'ir.actions.act_window', + } account_coda_import() transaction_types = { From fbcdfed860176b6c5af35c9a8d6843d8c938e633 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Fri, 7 Dec 2012 15:55:19 +0100 Subject: [PATCH 24/41] [FIX]Groups technical for CODA Notes and bank statement lines, form added to view mode for views after import, coda note information reference bzr revid: dle@openerp.com-20121207145519-4vbb1otng09wj3kg --- addons/l10n_be_coda/l10n_be_coda_view.xml | 4 ++-- addons/l10n_be_coda/l10n_be_coda_wizard.xml | 10 +++++----- addons/l10n_be_coda/wizard/account_coda_import.py | 6 +++--- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/addons/l10n_be_coda/l10n_be_coda_view.xml b/addons/l10n_be_coda/l10n_be_coda_view.xml index d4c896064a6..538332b37d2 100644 --- a/addons/l10n_be_coda/l10n_be_coda_view.xml +++ b/addons/l10n_be_coda/l10n_be_coda_view.xml @@ -7,7 +7,7 @@ - + @@ -91,7 +91,7 @@ - + \ No newline at end of file diff --git a/addons/l10n_be_coda/l10n_be_coda_wizard.xml b/addons/l10n_be_coda/l10n_be_coda_wizard.xml index 92b16db0e88..dddc18bb30a 100644 --- a/addons/l10n_be_coda/l10n_be_coda_wizard.xml +++ b/addons/l10n_be_coda/l10n_be_coda_wizard.xml @@ -8,15 +8,15 @@ 1
-
-
+
+
diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 1118f5a4ae6..7d50e4ba0d3 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -246,9 +246,9 @@ class account_coda_import(osv.osv_memory): line['transaction_family'] = transaction_family[0] if line['transaction_code'] in transaction_family[1]: line['transaction_code'] = transaction_family[1][line['transaction_code']] - statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Date: ' + str(line['entryDate']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'], '\n']) + statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' with Ref. ' + str(line['ref']), 'Date: ' + str(line['entryDate']), 'Communication: ' + line['communication'], '']) elif line['type'] == 'communication': - statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' #' + str(line['sequence']), 'Ref: ' + str(line['ref']), 'Communication: ' + line['communication'], '\n']) + statement['coda_note'] = "\n".join([statement['coda_note'], line['type'].title() + ' with Ref. ' + str(line['ref']), 'Ref: ', 'Communication: ' + line['communication'], '']) elif line['type'] == 'normal': note = [] if 'counterpartyName' in line and line['counterpartyName'] != '': @@ -385,7 +385,7 @@ class account_coda_import(osv.osv_memory): self.pool.get('account.bank.statement').write(cr, uid, [statement['id']], {'coda_note': statement['coda_note']}, context=context) return { 'view_type': 'form', - 'view_mode': 'tree', + 'view_mode': 'tree,form', 'res_model': 'account.bank.statement', 'view_id': False, 'context': context, From 62bb893da70b757813fc20a49a64ed527394cddf Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Sat, 8 Dec 2012 12:08:02 +0100 Subject: [PATCH 25/41] [FIX]Mmissing adding magic number for credit lines in voucher bzr revid: dle@openerp.com-20121208110802-226tomv7ni26r0nh --- addons/l10n_be_coda/wizard/account_coda_import.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 7d50e4ba0d3..d27b28c315c 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -318,6 +318,10 @@ class account_coda_import(osv.osv_memory): for line_dr in voucher_vals['line_dr_ids']: line_drs.append((0, 0, line_dr)) voucher_vals['line_dr_ids'] = line_drs + line_crs = [] + for line_cr in voucher_vals['line_cr_ids']: + line_crs.append((0, 0, line_cr)) + voucher_vals['line_cr_ids'] = line_crs line['voucher_id'] = self.pool.get('account.voucher').create(cr, uid, voucher_vals, context=context) if 'counterpartyNumber' in line and line['counterpartyNumber']: ids = self.pool.get('res.partner.bank').search(cr, uid, [('acc_number', '=', str(line['counterpartyNumber']))]) From 1370e3c6558544a5899c5839847abc71aa9fe199 Mon Sep 17 00:00:00 2001 From: Goran Kliska Date: Mon, 10 Dec 2012 09:56:28 +0100 Subject: [PATCH 26/41] l10n_hr for 7.0 bzr revid: goran.kliska@slobodni-programi.hr-20121210085628-5ojrmijras80h0u1 --- addons/l10n_hr/__init__.py | 6 +- addons/l10n_hr/__openerp__.py | 44 +++--- addons/l10n_hr/data/account.tax.template.csv | 112 ++++++------- .../l10n_hr/data/fiscal_position.xml.backup | 139 ---------------- ...ition.xml => fiscal_position_template.xml} | 102 ++++++------ addons/l10n_hr/i18n/hr.po | 149 ------------------ addons/l10n_hr/i18n/l10n_hr.pot | 149 ------------------ addons/l10n_hr/l10n_hr_chart_template.xml | 22 +++ addons/l10n_hr/l10n_hr_wizard.xml | 55 +------ addons/l10n_hr/static/src/img/icon.png | Bin 0 -> 17892 bytes 10 files changed, 161 insertions(+), 617 deletions(-) delete mode 100644 addons/l10n_hr/data/fiscal_position.xml.backup rename addons/l10n_hr/data/{fiscal_position.xml => fiscal_position_template.xml} (50%) delete mode 100644 addons/l10n_hr/i18n/hr.po delete mode 100644 addons/l10n_hr/i18n/l10n_hr.pot create mode 100755 addons/l10n_hr/l10n_hr_chart_template.xml mode change 100755 => 100644 addons/l10n_hr/l10n_hr_wizard.xml create mode 100644 addons/l10n_hr/static/src/img/icon.png diff --git a/addons/l10n_hr/__init__.py b/addons/l10n_hr/__init__.py index e559ab15644..4628f79342d 100644 --- a/addons/l10n_hr/__init__.py +++ b/addons/l10n_hr/__init__.py @@ -4,9 +4,9 @@ # OpenERP, Open Source Management Solution # Module: l10n_hr # Author: Goran Kliska -# mail: gkliskaATgmail.com +# mail: goran.kliska(AT)slobodni-programi.hr # Copyright (C) 2011- Slobodni programi d.o.o., Zagreb -# Contributions: +# Contributions: # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as @@ -24,4 +24,4 @@ ############################################################################## -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_hr/__openerp__.py b/addons/l10n_hr/__openerp__.py index ec0f6269364..05c3d69593c 100644 --- a/addons/l10n_hr/__openerp__.py +++ b/addons/l10n_hr/__openerp__.py @@ -4,10 +4,10 @@ # OpenERP, Open Source Management Solution # Module: l10n_hr # Author: Goran Kliska -# mail: gkliskaATgmail.com +# mail: goran.kliska(AT)slobodni-programi.hr # Copyright: Slobodni programi d.o.o., Zagreb -# Contributions: -# Tomislav Bošnjaković, Storm Computers d.o.o. : +# Contributions: +# Tomislav Bošnjaković, Storm Computers d.o.o. : # - account types # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as @@ -25,8 +25,8 @@ ############################################################################## { - "name" : "Croatia - RRIF's 2012 chat of accounts", - "description" : """ + "name": "Croatia - RRIF 2012 COA", + "description": """ Croatian localisation. ====================== @@ -34,8 +34,8 @@ Author: Goran Kliska, Slobodni programi d.o.o., Zagreb http://www.slobodni-programi.hr Contributions: - Infokom d.o.o. - Storm Computers d.o.o. + Tomislav Bošnjaković, Storm Computers: tipovi konta + Ivan Vađić, Slobodni programi: tipovi konta Description: @@ -45,39 +45,35 @@ RRIF-ov računski plan za poduzetnike za 2012. Vrste konta Kontni plan prema RRIF-u, dorađen u smislu kraćenja naziva i dodavanja analitika Porezne grupe prema poreznoj prijavi -Porezi PDV-a -Ostali porezi (samo češće korišteni) povezani s kontima kontnog plana +Porezi PDV obrasca +Ostali porezi +Osnovne fiskalne pozicije Izvori podataka: http://www.rrif.hr/dok/preuzimanje/rrif-rp2011.rar http://www.rrif.hr/dok/preuzimanje/rrif-rp2012.rar - - """, - "version" : "2012.1", - "author" : "OpenERP Croatian Community", - "category" : 'Localization/Account Charts', - "website": "https://code.launchpad.net/openobject-croatia" , + "version": "12.2", + "author": "OpenERP Croatian Community", + "category": 'Localization/Account Charts', + "website": "https://code.launchpad.net/openobject-croatia", 'depends': [ 'account', - 'base_vat', - 'base_iban', 'account_chart', -# 'account_coda', ], - 'init_xml': [], - 'update_xml': [ + 'data': [ 'data/account.account.type.csv', 'data/account.tax.code.template.csv', 'data/account.account.template.csv', + 'l10n_hr_chart_template.xml', 'l10n_hr_wizard.xml', 'data/account.tax.template.csv', - 'data/fiscal_position.xml', - ], - "demo_xml" : [], - 'test' : [], + 'data/fiscal_position_template.xml', + ], + "demo": [], + 'test': [], "active": False, "installable": True, } diff --git a/addons/l10n_hr/data/account.tax.template.csv b/addons/l10n_hr/data/account.tax.template.csv index 7289e25a5e3..b038cebfc39 100644 --- a/addons/l10n_hr/data/account.tax.template.csv +++ b/addons/l10n_hr/data/account.tax.template.csv @@ -1,62 +1,50 @@ -"id","description","chart_template_id:id","name","amount","child_ids:id","parent_id:id","child_depend","type","account_collected_id:id","account_paid_id:id","type_tax_use","base_code_id:id","tax_code_id:id","ref_base_code_id:id","ref_tax_code_id:id","ref_tax_sign","tax_sign","base_sign","ref_base_sign","sequence" -"rrif_pdv_25","PDV 25%","l10n_hr_chart_template_rrif","25% PDV","0.25",,,"False","percent","kp_rrif24003","kp_rrif24003","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","10" -"rrif_pdv_25usl","PDV 25% Usluge","l10n_hr_chart_template_rrif","25% PDV usluge","0.25",,,"False","percent","kp_rrif24003","kp_rrif24003","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" -"rrif_pdv_23","PDV 23%","l10n_hr_chart_template_rrif","23% PDV","0.23",,,"False","percent","kp_rrif24002","kp_rrif24002","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" -"rrif_pdv_23usl","PDV 23% Usluge","l10n_hr_chart_template_rrif","23% PDV usluge","0.23",,,"False","percent","kp_rrif24002","kp_rrif24002","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" -"rrif_pdv_10","PDV 10%","l10n_hr_chart_template_rrif","10% PDV","0.10",,,"False","percent","kp_rrif24000","kp_rrif24000","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" -"rrif_pdv_0","PDV 0%","l10n_hr_chart_template_rrif","0% PDV","0.00",,,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" -"rrif_pdv_avans_25","PDV za predujam 25%","l10n_hr_chart_template_rrif","25% PDV (za predujam)","0.25",,,"False","percent","kp_rrif24013","kp_rrif24013","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" -"rrif_pdv_avans_23","PDV za predujam 23%","l10n_hr_chart_template_rrif","23% PDV (za predujam)","0.23",,,"False","percent","kp_rrif24012","kp_rrif24012","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" -"rrif_pdv_avans_10","PDV za predujam 10%","l10n_hr_chart_template_rrif","10% PDV (za predujam)","0.10",,,"False","percent","kp_rrif24010","kp_rrif24010","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" -"rrif_pdv_avans_0","PDV za predujam 0%","l10n_hr_chart_template_rrif","0% PDV (za predujam)","0.00",,,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" -"rrif_pdv_nezar_isp_25","PDV po nezaračunanim isporukama 25%","l10n_hr_chart_template_rrif","25% PDV za nezaračunane isp.","0.25",,,"False","percent","kp_rrif24033","kp_rrif24033","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" -"rrif_pdv_nezar_isp_23","PDV po nezaračunanim isporukama 23%","l10n_hr_chart_template_rrif","23% PDV za nezaračunane isp.","0.23",,,"False","percent","kp_rrif24032","kp_rrif24032","sale","pdv_code_o22","pdv_code_p22","pdv_code_o22","pdv_code_p22","1.0","1.0","1.0","1.0","100" -"rrif_pdv_nezar_isp_10","PDV po nezaračunanim isporukama 10%","l10n_hr_chart_template_rrif","10% PDV za nezaračunane isp.","0.10",,,"False","percent","kp_rrif24030","kp_rrif24030","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" -"rrif_pdv_nezar_isp_0","PDV po nezaračunanim isporukama 0%","l10n_hr_chart_template_rrif","0% PDV za nezaračunane isp.","0.00",,,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" -"rrif_pdv_nepod_0","1. KOJE NE PODLIJEŽU OPOREZIVANJU (čl. 2. u svezi s čl. 5 i čl. 8 st. 7 Zakona)","l10n_hr_chart_template_rrif","0% Ne podliježe op.","0.00",,,"False","percent",,,"sale","pdv_code_o11",,"pdv_code_o11",,"1.0","1.0","1.0","1.0","100" -"rrif_pdv_osl_izvoz_0","2.1. IZVOZNE - s pravom na odbitak pretporeza (čl. 13. st. 1. toč. 1. i čl. 14. Zakona)","l10n_hr_chart_template_rrif","0% osl. izvozne","0.00",,,"False","percent",,,"sale","pdv_code_o121",,"pdv_code_o121",,"1.0","1.0","1.0","1.0","100" -"rrif_pdv_osl_medpri_0","2.2. U VEZI S MEĐUNARODNIM PRIJEVOZOM (čl. 13.b Zakona)","l10n_hr_chart_template_rrif","0% osl. međ. prijevoz","0.00",,,"False","percent",,,"sale","pdv_code_o122",,"pdv_code_o122",,"1.0","1.0","1.0","1.0","100" -"rrif_pdv_osl_tuz_0","2.3. TUZEMNE - bez prava na odbitak pretporeza (čl. 11. i čl. 11a Zakona)","l10n_hr_chart_template_rrif","0% osl tuzemne","0.00",,,"False","percent",,,"sale","pdv_code_o123",,"pdv_code_o123",,"1.0","1.0","1.0","1.0","100" -"rrif_pdv_osl_ost_0","2.4. OSTALO (čl. 13. st. 1. toč. 2. I čl. 13a Zakona) ","l10n_hr_chart_template_rrif","0% osl. ostalo","0.00",,,"False","percent",,,"sale","pdv_code_o124",,"pdv_code_o124",,"1.0","1.0","1.0","1.0","100" -"rrif_pp_25","Pretporez 25% PDV","l10n_hr_chart_template_rrif","25% PDV pretporez","0.25",,,"False","percent","kp_rrif14003","kp_rrif14003","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","10" -"rrif_pp_25usl","Pretporez 25% PDV Usluge","l10n_hr_chart_template_rrif","25% PDV pretporez usluge","0.25",,,"False","percent","kp_rrif14003","kp_rrif14003","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" -"rrif_pp_23","Pretporez 23% PDV","l10n_hr_chart_template_rrif","23% PDV pretporez","0.23",,,"False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o32","pdv_code_p32","pdv_code_o32","pdv_code_p32","1.0","1.0","1.0","1.0","100" -"rrif_pp_23usl","Pretporez 23% PDV Usluge","l10n_hr_chart_template_rrif","23% PDV pretporez usluge","0.23",,,"False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o32","pdv_code_p32","pdv_code_o32","pdv_code_p32","1.0","1.0","1.0","1.0","100" -"rrif_pp_10","Pretporez 10% PDV","l10n_hr_chart_template_rrif","10% PDV pretporez","0.10",,,"False","percent","kp_rrif14000","kp_rrif14000","purchase","pdv_code_o31","pdv_code_p31","pdv_code_o31","pdv_code_p31","1.0","1.0","1.0","1.0","100" -"rrif_pp_0","Pretporez 0% PDV","l10n_hr_chart_template_rrif","0% PDV pretporez","0.00",,,"False","percent",,,"purchase","pdv_code_o391",,"pdv_code_o391",,"1.0","1.0","1.0","1.0","100" -"rrif_pp_avans_25","Pretporez za predujam 25% PDV","l10n_hr_chart_template_rrif","25% PDV pretporez za predujam","0.25",,,"False","percent","kp_rrif14013","kp_rrif14013","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" -"rrif_pp_avans_23","Pretporez za predujam 23% PDV","l10n_hr_chart_template_rrif","23% PDV pretporez za predujam","0.23",,,"False","percent","kp_rrif14012","kp_rrif14012","purchase","pdv_code_o32","pdv_code_p32","pdv_code_o32","pdv_code_p32","1.0","1.0","1.0","1.0","100" -"rrif_pp_avans_10","Pretporez za predujam 10% PDV","l10n_hr_chart_template_rrif","10% PDV pretporez za predujam","0.10",,,"False","percent","kp_rrif14010","kp_rrif14010","purchase","pdv_code_o31","pdv_code_p31","pdv_code_o31","pdv_code_p31","1.0","1.0","1.0","1.0","100" -"rrif_pp_avans_0","Pretporez za predujam 0% PDV","l10n_hr_chart_template_rrif","0% PDV pretporez za predujam","0.00",,,"False","percent",,,"purchase","pdv_code_o391",,"pdv_code_o391",,"1.0","1.0","1.0","1.0","100" -"rrif_pp_uvoz_25","Plaćeni PDV 25% pri uvozu dobara","l10n_hr_chart_template_rrif","25% uvoz dobara","0.25",,,"False","percent","kp_rrif14023","kp_rrif14023","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" -"rrif_pp_uvoz_23","Plaćeni PDV 23% pri uvozu dobara","l10n_hr_chart_template_rrif","23% uvoz dobara","0.23",,,"False","percent","kp_rrif14022","kp_rrif14022","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" -"rrif_pp_uvoz_10","Plaćeni PDV 10% pri uvozu dobara","l10n_hr_chart_template_rrif","10% uvoz dobara","0.10",,,"False","percent","kp_rrif14020","kp_rrif14020","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" -"rrif_pp_uvoz_0","Plaćeni PDV 0% pri uvozu dobara","l10n_hr_chart_template_rrif","0% uvoz dobara","0.00",,,"False","percent",,,"purchase","pdv_code_o34",,"pdv_code_o34",,"1.0","1.0","1.0","1.0","100" -"rrif_pp_ino_25","Plaćeni PDV 25% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","25% ino. usluge","0.25",,,"False","percent","kp_rrif14033","kp_rrif14033","purchase","pdv_code_o37","pdv_code_p37","pdv_code_o34","pdv_code_o37","1.0","1.0","1.0","1.0","100" -"rrif_pp_ino_23","Plaćeni PDV 23% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","23% ino. usluge","0.23",,,"False","percent","kp_rrif14032","kp_rrif14032","purchase","pdv_code_o36","pdv_code_p36","pdv_code_o34","pdv_code_o37","1.0","1.0","1.0","1.0","100" -"rrif_pp_ino_10","Plaćeni PDV 10% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","10% ino. usluge","0.10",,,"False","percent","kp_rrif14030","kp_rrif14030","purchase","pdv_code_o35","pdv_code_p35","pdv_code_o34","pdv_code_o35","1.0","1.0","1.0","1.0","100" -"rrif_pp_R2_25","25% R-2 dobavljač","l10n_hr_chart_template_rrif","25% R-2 dobavljač","0.25",,,"False","percent","kp_rrif1409","kp_rrif1409","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" -"rrif_pp_R2_23","23% R-2 dobavljač","l10n_hr_chart_template_rrif","23% R-2 dobavljač","0.23",,,"False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" -"rrif_pp_uvoz_samopdv_25","Samo PDV kod uvoza 25%","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 25%","0.25",,,"False","percent",,,"purchase","pdv_code_o913","pdv_code_p9202","pdv_code_o913","pdv_code_p9202","-1.0","-1.0","-1.0","-1.0","100" -"rrif_pp_uvoz_samopdv_25usl","Samo PDV kod uvoza 25% usluge","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 25% usluge","0.25",,,"False","percent",,,"purchase","pdv_code_o913","pdv_code_p9203","pdv_code_o913","pdv_code_p9203","-1.0","-1.0","-1.0","-1.0","100" -"rrif_pp_uvoz_samopdv_23","Samo PDV kod uvoza 23%","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 23%","0.23",,,"False","percent",,,"purchase","pdv_code_o912","pdv_code_p9203","pdv_code_o912","pdv_code_p9203","-1.0","-1.0","-1.0","-1.0","100" -"rrif_ppdnp1_3070_1","pp 30% Nepriznat 70% Priznat","l10n_hr_chart_template_rrif","pp 30% Nepriznat 70% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_30_2","pp 30% nepriznat","l10n_hr_chart_template_rrif","pp 30% nepriznat","0.30",,"rrif_ppdnp1_3070_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_30_3","pp 30% nep.(25%)","l10n_hr_chart_template_rrif","pp 30% nep.(25%)","0.25",,"rrif_ppdnp1_3070_30_2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_70_2","pp 70% priznat","l10n_hr_chart_template_rrif","Pp 70% priznat","0.70",,"rrif_ppdnp1_3070_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_70_3","pp 70% priz.(25%)","l10n_hr_chart_template_rrif","Pp 70% priz.(25%)","0.25",,"rrif_ppdnp1_3070_70_2","False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_1","pp 70% Nepriznat 30% Priznat","l10n_hr_chart_template_rrif","pp 70% Nepriznat 30% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_70_2","Pp 70% nepriznat","l10n_hr_chart_template_rrif","Pp 70% nepriznat","0.70",,"rrif_ppdnp1_7030_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_70_3","Pp 70% nep.(25%)","l10n_hr_chart_template_rrif","Pp 70% nep.(25%)","0.25",,"rrif_ppdnp1_7030_70_2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_30_2","Pp 30% priznat","l10n_hr_chart_template_rrif","Pp 30% priznat","0.30",,"rrif_ppdnp1_7030_1","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_30_3","Pp 30% priz.(25%)","l10n_hr_chart_template_rrif","Pp 30% priz.(25%)","0.25",,"rrif_ppdnp1_7030_30_2","False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_1_r2","R2 pp 30% Nepriznat 70% Priznat","l10n_hr_chart_template_rrif","R2 pp 30% Nepriznat 70% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_30_2_r2","R2 pp 30% nepriznat","l10n_hr_chart_template_rrif","R2 pp 30% nepriznat","0.30",,"rrif_ppdnp1_3070_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_30_3_r2","R2 pp 30% nep.(25%)","l10n_hr_chart_template_rrif","R2 pp 30% nep.(25%)","0.25",,"rrif_ppdnp1_3070_30_2_r2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_70_2_r2","R2 pp 70% priznat","l10n_hr_chart_template_rrif","R2 pp 70% priznat","0.70",,"rrif_ppdnp1_3070_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_3070_70_3_r2","R2 pp 70% priz.(25%)","l10n_hr_chart_template_rrif","R2 pp 70% priz.(25%)","0.25",,"rrif_ppdnp1_3070_70_2_r2","False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_1_r2","R2 pp 70% Nepriznat 30% Priznat","l10n_hr_chart_template_rrif","R2 pp 70% Nepriznat 30% Priznat","1.0",,,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_70_2_r2","R2 Pp 70% nepriznat","l10n_hr_chart_template_rrif","R2 Pp 70% nepriznat","0.70",,"rrif_ppdnp1_7030_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_70_3_r2","R2 Pp 70% nep.(25%)","l10n_hr_chart_template_rrif","R2 Pp 70% nep.(25%)","0.25",,"rrif_ppdnp1_7030_70_2_r2","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_30_2_r2","R2 Pp 30% priznat","l10n_hr_chart_template_rrif","R2 Pp 30% priznat","0.30",,"rrif_ppdnp1_7030_1_r2","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" -"rrif_ppdnp1_7030_30_3_r2","R2 Pp 30% priz.(25%)","l10n_hr_chart_template_rrif","R2 Pp 30% priz.(25%)","0.25",,"rrif_ppdnp1_7030_30_2_r2","False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" +"id","description","chart_template_id/id","name","amount","parent_id","child_depend","type","account_collected_id/id","account_paid_id/id","type_tax_use","base_code_id/id","tax_code_id/id","ref_base_code_id/id","ref_tax_code_id/id","ref_tax_sign","tax_sign","base_sign","ref_base_sign","sequence" +"rrif_pdv_25","PDV 25%","l10n_hr_chart_template_rrif","25% PDV","0.25",,"False","percent","kp_rrif24003","kp_rrif24003","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","10" +"rrif_pdv_25usl","PDV 25% Usluge","l10n_hr_chart_template_rrif","25% PDV usluge","0.25",,"False","percent","kp_rrif24003","kp_rrif24003","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" +"rrif_pdv_10","PDV 10%","l10n_hr_chart_template_rrif","10% PDV","0.10",,"False","percent","kp_rrif24000","kp_rrif24000","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" +"rrif_pdv_0","PDV 0%","l10n_hr_chart_template_rrif","0% PDV","0.00",,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_avans_25","PDV za predujam 25%","l10n_hr_chart_template_rrif","25% PDV (za predujam)","0.25",,"False","percent","kp_rrif24013","kp_rrif24013","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" +"rrif_pdv_avans_10","PDV za predujam 10%","l10n_hr_chart_template_rrif","10% PDV (za predujam)","0.10",,"False","percent","kp_rrif24010","kp_rrif24010","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" +"rrif_pdv_avans_0","PDV za predujam 0%","l10n_hr_chart_template_rrif","0% PDV (za predujam)","0.00",,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_nezar_isp_25","PDV po nezaračunanim isporukama 25%","l10n_hr_chart_template_rrif","25% PDV za nezaračunane isp.","0.25",,"False","percent","kp_rrif24033","kp_rrif24033","sale","pdv_code_o23","pdv_code_p23","pdv_code_o23","pdv_code_p23","1.0","1.0","1.0","1.0","100" +"rrif_pdv_nezar_isp_10","PDV po nezaračunanim isporukama 10%","l10n_hr_chart_template_rrif","10% PDV za nezaračunane isp.","0.10",,"False","percent","kp_rrif24030","kp_rrif24030","sale","pdv_code_o21","pdv_code_p21","pdv_code_o21","pdv_code_p21","1.0","1.0","1.0","1.0","100" +"rrif_pdv_nezar_isp_0","PDV po nezaračunanim isporukama 0%","l10n_hr_chart_template_rrif","0% PDV za nezaračunane isp.","0.00",,"False","percent",,,"sale","pdv_code_o13",,"pdv_code_o13",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_nepod_0","1. KOJE NE PODLIJEŽU OPOREZIVANJU (čl. 2. u svezi s čl. 5 i čl. 8 st. 7 Zakona)","l10n_hr_chart_template_rrif","0% Ne podliježe op.","0.00",,"False","percent",,,"sale","pdv_code_o11",,"pdv_code_o11",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_izvoz_0","2.1. IZVOZNE - s pravom na odbitak pretporeza (čl. 13. st. 1. toč. 1. i čl. 14. Zakona)","l10n_hr_chart_template_rrif","0% osl. izvozne","0.00",,"False","percent",,,"sale","pdv_code_o121",,"pdv_code_o121",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_medpri_0","2.2. U VEZI S MEĐUNARODNIM PRIJEVOZOM (čl. 13.b Zakona)","l10n_hr_chart_template_rrif","0% osl. međ. prijevoz","0.00",,"False","percent",,,"sale","pdv_code_o122",,"pdv_code_o122",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_tuz_0","2.3. TUZEMNE - bez prava na odbitak pretporeza (čl. 11. i čl. 11a Zakona)","l10n_hr_chart_template_rrif","0% osl tuzemne","0.00",,"False","percent",,,"sale","pdv_code_o123",,"pdv_code_o123",,"1.0","1.0","1.0","1.0","100" +"rrif_pdv_osl_ost_0","2.4. OSTALO (čl. 13. st. 1. toč. 2. I čl. 13a Zakona) ","l10n_hr_chart_template_rrif","0% osl. ostalo","0.00",,"False","percent",,,"sale","pdv_code_o124",,"pdv_code_o124",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_25","Pretporez 25% PDV","l10n_hr_chart_template_rrif","25% PDV pretporez","0.25",,"False","percent","kp_rrif14003","kp_rrif14003","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","10" +"rrif_pp_25usl","Pretporez 25% PDV Usluge","l10n_hr_chart_template_rrif","25% PDV pretporez usluge","0.25",,"False","percent","kp_rrif14003","kp_rrif14003","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_pp_10","Pretporez 10% PDV","l10n_hr_chart_template_rrif","10% PDV pretporez","0.10",,"False","percent","kp_rrif14000","kp_rrif14000","purchase","pdv_code_o31","pdv_code_p31","pdv_code_o31","pdv_code_p31","1.0","1.0","1.0","1.0","100" +"rrif_pp_0","Pretporez 0% PDV","l10n_hr_chart_template_rrif","0% PDV pretporez","0.00",,"False","percent",,,"purchase","pdv_code_o391",,"pdv_code_o391",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_avans_25","Pretporez za predujam 25% PDV","l10n_hr_chart_template_rrif","25% PDV pretporez za predujam","0.25",,"False","percent","kp_rrif14013","kp_rrif14013","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_pp_avans_0","Pretporez za predujam 0% PDV","l10n_hr_chart_template_rrif","0% PDV pretporez za predujam","0.00",,"False","percent",,,"purchase","pdv_code_o391",,"pdv_code_o391",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_25","Plaćeni PDV 25% pri uvozu dobara","l10n_hr_chart_template_rrif","25% uvoz dobara","0.25",,"False","percent","kp_rrif14023","kp_rrif14023","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_10","Plaćeni PDV 10% pri uvozu dobara","l10n_hr_chart_template_rrif","10% uvoz dobara","0.10",,"False","percent","kp_rrif14020","kp_rrif14020","purchase","pdv_code_o34","pdv_code_p34","pdv_code_o34","pdv_code_p34","1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_0","Plaćeni PDV 0% pri uvozu dobara","l10n_hr_chart_template_rrif","0% uvoz dobara","0.00",,"False","percent",,,"purchase","pdv_code_o34",,"pdv_code_o34",,"1.0","1.0","1.0","1.0","100" +"rrif_pp_ino_25","Plaćeni PDV 25% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","25% ino. usluge","0.25",,"False","percent","kp_rrif14033","kp_rrif14033","purchase","pdv_code_o37","pdv_code_p37","pdv_code_o34","pdv_code_o37","1.0","1.0","1.0","1.0","100" +"rrif_pp_ino_10","Plaćeni PDV 10% na usluge inozemnih poduzetnika","l10n_hr_chart_template_rrif","10% ino. usluge","0.10",,"False","percent","kp_rrif14030","kp_rrif14030","purchase","pdv_code_o35","pdv_code_p35","pdv_code_o34","pdv_code_o35","1.0","1.0","1.0","1.0","100" +"rrif_ppr2_25","25% R-2 dobavljač","l10n_hr_chart_template_rrif","25% R-2 dobavljač","0.25",,"False","percent","kp_rrif1409","kp_rrif1409","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" +"rrif_pp_uvoz_samopdv_25","Samo PDV kod uvoza 25%","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 25%","0.25",,"False","percent",,,"purchase","pdv_code_o913","pdv_code_p9202","pdv_code_o913","pdv_code_p9202","-1.0","-1.0","-1.0","-1.0","100" +"rrif_pp_uvoz_samopdv_25usl","Samo PDV kod uvoza 25% usluge","l10n_hr_chart_template_rrif","Samo PDV kod uvoza 25% usluge","0.25",,"False","percent",,,"purchase","pdv_code_o913","pdv_code_p9203","pdv_code_o913","pdv_code_p9203","-1.0","-1.0","-1.0","-1.0","100" +"rrif_ppdnp1_3070_1","pp 30% Nepriznat 70% Priznat","l10n_hr_chart_template_rrif","pp 30% Nepriznat 70% Priznat","1.0",,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_2","pp 30% nepriznat","l10n_hr_chart_template_rrif","pp 30% nepriznat","0.30","pp 30% Nepriznat 70% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_3","pp 30% nep.(25%)","l10n_hr_chart_template_rrif","pp 30% nep.(25%)","0.25","pp 30% nepriznat","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_2","pp 70% priznat","l10n_hr_chart_template_rrif","Pp 70% priznat","0.70","pp 30% Nepriznat 70% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_3","pp 70% priz.(25%)","l10n_hr_chart_template_rrif","Pp 70% priz.(25%)","0.25","Pp 70% priznat","False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_1","pp 70% Nepriznat 30% Priznat","l10n_hr_chart_template_rrif","pp 70% Nepriznat 30% Priznat","1.0",,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_2","Pp 70% nepriznat","l10n_hr_chart_template_rrif","Pp 70% nepriznat","0.70","pp 70% Nepriznat 30% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_3","Pp 70% nep.(25%)","l10n_hr_chart_template_rrif","Pp 70% nep.(25%)","0.25","Pp 70% nepriznat","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_2","Pp 30% priznat","l10n_hr_chart_template_rrif","Pp 30% priznat","0.30","pp 70% Nepriznat 30% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_3","Pp 30% priz.(25%)","l10n_hr_chart_template_rrif","Pp 30% priz.(25%)","0.25","Pp 30% priznat","False","percent","kp_rrif14002","kp_rrif14002","purchase","pdv_code_o33","pdv_code_p33","pdv_code_o33","pdv_code_p33","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_1_r2","R2 pp 30% Nepriznat 70% Priznat","l10n_hr_chart_template_rrif","R2 pp 30% Nepriznat 70% Priznat","1.0",,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_2_r2","R2 pp 30% nepriznat","l10n_hr_chart_template_rrif","R2 pp 30% nepriznat","0.30","R2 pp 30% Nepriznat 70% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_30_3_r2","R2 pp 30% nep.(25%)","l10n_hr_chart_template_rrif","R2 pp 30% nep.(25%)","0.25","R2 pp 30% nepriznat","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_2_r2","R2 pp 70% priznat","l10n_hr_chart_template_rrif","R2 pp 70% priznat","0.70","R2 pp 30% Nepriznat 70% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_3070_70_3_r2","R2 pp 70% priz.(25%)","l10n_hr_chart_template_rrif","R2 pp 70% priz.(25%)","0.25","R2 pp 70% priznat","False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_1_r2","R2 pp 70% Nepriznat 30% Priznat","l10n_hr_chart_template_rrif","R2 pp 70% Nepriznat 30% Priznat","1.0",,"True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_2_r2","R2 Pp 70% nepriznat","l10n_hr_chart_template_rrif","R2 Pp 70% nepriznat","0.70","R2 pp 70% Nepriznat 30% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_70_3_r2","R2 Pp 70% nep.(25%)","l10n_hr_chart_template_rrif","R2 Pp 70% nep.(25%)","0.25","R2 Pp 70% nepriznat","False","percent",,,"purchase","pdv_code_o913","pdv_code_p913","pdv_code_o913","pdv_code_p913","1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_2_r2","R2 Pp 30% priznat","l10n_hr_chart_template_rrif","R2 Pp 30% priznat","0.30","R2 pp 70% Nepriznat 30% Priznat","True","percent",,,"purchase",,,,,"1.0","1.0","1.0","1.0","100" +"rrif_ppdnp1_7030_30_3_r2","R2 Pp 30% priz.(25%)","l10n_hr_chart_template_rrif","R2 Pp 30% priz.(25%)","0.25","R2 Pp 30% priznat","False","percent","kp_rrif1408","kp_rrif1408","purchase","pdv_code_o92","pdv_code_p9201","pdv_code_o92","pdv_code_p9201","1.0","1.0","1.0","1.0","100" diff --git a/addons/l10n_hr/data/fiscal_position.xml.backup b/addons/l10n_hr/data/fiscal_position.xml.backup deleted file mode 100644 index 8386a0d9808..00000000000 --- a/addons/l10n_hr/data/fiscal_position.xml.backup +++ /dev/null @@ -1,139 +0,0 @@ - - - - - Bescarinska zona - - - - - - - - - - - - - - - - Domaći partneri R2 - - - - - - - - - - - Domaći partneri R1 - - - - - Strani partneri - - - - - - - - - - - - - - - - - - - - - - - - - Domaći partneri izvan sustava PDV-a - - - - - - - - - - - - - Carinska uprava - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/addons/l10n_hr/data/fiscal_position.xml b/addons/l10n_hr/data/fiscal_position_template.xml similarity index 50% rename from addons/l10n_hr/data/fiscal_position.xml rename to addons/l10n_hr/data/fiscal_position_template.xml index df91a120a8b..5a74fc0cc2d 100644 --- a/addons/l10n_hr/data/fiscal_position.xml +++ b/addons/l10n_hr/data/fiscal_position_template.xml @@ -1,68 +1,82 @@ - - + + R1 partneri - - - - + + R2 partneri - - - - - - - - - - - - - - - - - - + + + EU Inozemni + + + Inozemni - - - - - - - - - - - - - + + + + + + + - - - + + + + - - + + + + + + + + + + + + - - + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/addons/l10n_hr/i18n/hr.po b/addons/l10n_hr/i18n/hr.po deleted file mode 100644 index 9f7c1848ee1..00000000000 --- a/addons/l10n_hr/i18n/hr.po +++ /dev/null @@ -1,149 +0,0 @@ -# Translation of OpenERP Server. -# This file contains the translation of the following modules: -# * l10n_hr -# -msgid "" -msgstr "" -"Project-Id-Version: OpenERP Server 6.1\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-03-20 18:16+0000\n" -"PO-Revision-Date: 2012-03-20 18:16+0000\n" -"Last-Translator: <>\n" -"Language-Team: \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Plural-Forms: \n" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pasiva -msgid "Pasiva" -msgstr "Pasiva" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_aktiva -msgid "Aktiva" -msgstr "Aktiva" - -#. module: l10n_hr -#: model:ir.actions.todo,note:l10n_hr.config_call_account_template_hr_rrif -msgid "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" -" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" -msgstr "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" -" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_view -msgid "Sintetika" -msgstr "Sintetika" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_inv_rashod -msgid "Izvanredni rashodi" -msgstr "Izvanredni rashodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pdv -msgid "Obveze za PDV" -msgstr "Obveze za PDV" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_other -msgid "Ostalo" -msgstr "Ostalo" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pas_razgran -msgid "Pasivna vrem. Razgraničenja" -msgstr "Pasivna vrem. Razgraničenja" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_kratk_imovina -msgid "Kratkotrajna imovina" -msgstr "Kratkotrajna imovina" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_upis_kapital -msgid "Potraživanja za upisani kapital" -msgstr "Potraživanja za upisani kapital" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_obveze_dob -msgid "Obveze prema dobavljačima" -msgstr "Obveze prema dobavljačima" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_kapital -msgid "Kapital i rezerve" -msgstr "Kapital i rezerve" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_rezervacije -msgid "Rezerviranja" -msgstr "Rezerviranja" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_potraz_kup -msgid "Potraživanja od kupaca" -msgstr "Potraživanja od kupaca" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_dug_imovina -msgid "Dugotrajna imovina" -msgstr "Dugotrajna imovina" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pretporez -msgid "Potraživanja za pretporez" -msgstr "Potraživanja za pretporez" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_prihod -msgid "Prihod" -msgstr "Prihod" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_fin_prihod -msgid "Financijski prihodi" -msgstr "Financijski prihodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_posl_rashod -msgid "Poslovni rashodi" -msgstr "Poslovni rashodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_dug_obv -msgid "Dugoročne obveze" -msgstr "Dugoročne obveze" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_rashod -msgid "Rashod" -msgstr "Rashod" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_posl_prihod -msgid "Poslovni prihodi" -msgstr "Poslovni prihodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_kratk_obveze -msgid "Kratkoročne obveze" -msgstr "Kratkoročne obveze" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_fin_rashod -msgid "Financijski rashodi" -msgstr "Financijski rashodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_izv_prihod -msgid "Izvanredni prihodi" -msgstr "Izvanredni prihodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_aktiv_razgran -msgid "Aktivna vrem. Razgraničenja" -msgstr "Aktivna vrem. Razgraničenja" - diff --git a/addons/l10n_hr/i18n/l10n_hr.pot b/addons/l10n_hr/i18n/l10n_hr.pot deleted file mode 100644 index 9f7c1848ee1..00000000000 --- a/addons/l10n_hr/i18n/l10n_hr.pot +++ /dev/null @@ -1,149 +0,0 @@ -# Translation of OpenERP Server. -# This file contains the translation of the following modules: -# * l10n_hr -# -msgid "" -msgstr "" -"Project-Id-Version: OpenERP Server 6.1\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2012-03-20 18:16+0000\n" -"PO-Revision-Date: 2012-03-20 18:16+0000\n" -"Last-Translator: <>\n" -"Language-Team: \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Plural-Forms: \n" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pasiva -msgid "Pasiva" -msgstr "Pasiva" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_aktiva -msgid "Aktiva" -msgstr "Aktiva" - -#. module: l10n_hr -#: model:ir.actions.todo,note:l10n_hr.config_call_account_template_hr_rrif -msgid "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" -" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" -msgstr "Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku.\n" -" Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_view -msgid "Sintetika" -msgstr "Sintetika" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_inv_rashod -msgid "Izvanredni rashodi" -msgstr "Izvanredni rashodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pdv -msgid "Obveze za PDV" -msgstr "Obveze za PDV" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_other -msgid "Ostalo" -msgstr "Ostalo" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pas_razgran -msgid "Pasivna vrem. Razgraničenja" -msgstr "Pasivna vrem. Razgraničenja" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_kratk_imovina -msgid "Kratkotrajna imovina" -msgstr "Kratkotrajna imovina" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_upis_kapital -msgid "Potraživanja za upisani kapital" -msgstr "Potraživanja za upisani kapital" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_obveze_dob -msgid "Obveze prema dobavljačima" -msgstr "Obveze prema dobavljačima" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_kapital -msgid "Kapital i rezerve" -msgstr "Kapital i rezerve" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_rezervacije -msgid "Rezerviranja" -msgstr "Rezerviranja" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_potraz_kup -msgid "Potraživanja od kupaca" -msgstr "Potraživanja od kupaca" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_dug_imovina -msgid "Dugotrajna imovina" -msgstr "Dugotrajna imovina" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_pretporez -msgid "Potraživanja za pretporez" -msgstr "Potraživanja za pretporez" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_prihod -msgid "Prihod" -msgstr "Prihod" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_fin_prihod -msgid "Financijski prihodi" -msgstr "Financijski prihodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_posl_rashod -msgid "Poslovni rashodi" -msgstr "Poslovni rashodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_dug_obv -msgid "Dugoročne obveze" -msgstr "Dugoročne obveze" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_rashod -msgid "Rashod" -msgstr "Rashod" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_posl_prihod -msgid "Poslovni prihodi" -msgstr "Poslovni prihodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_kratk_obveze -msgid "Kratkoročne obveze" -msgstr "Kratkoročne obveze" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_fin_rashod -msgid "Financijski rashodi" -msgstr "Financijski rashodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_izv_prihod -msgid "Izvanredni prihodi" -msgstr "Izvanredni prihodi" - -#. module: l10n_hr -#: model:account.account.type,name:l10n_hr.account_type_aktiv_razgran -msgid "Aktivna vrem. Razgraničenja" -msgstr "Aktivna vrem. Razgraničenja" - diff --git a/addons/l10n_hr/l10n_hr_chart_template.xml b/addons/l10n_hr/l10n_hr_chart_template.xml new file mode 100755 index 00000000000..5532aff9037 --- /dev/null +++ b/addons/l10n_hr/l10n_hr_chart_template.xml @@ -0,0 +1,22 @@ + + + + + + RRIF-ov računski plan za poduzetnike + 0 + + + + + + + + + + + + + + + diff --git a/addons/l10n_hr/l10n_hr_wizard.xml b/addons/l10n_hr/l10n_hr_wizard.xml old mode 100755 new mode 100644 index 1f8a8763137..b736f241607 --- a/addons/l10n_hr/l10n_hr_wizard.xml +++ b/addons/l10n_hr/l10n_hr_wizard.xml @@ -1,47 +1,8 @@ - - - - - - RRIF-ov računski plan za poduzetnike - 0 - - - - - - - - - - - - - - - - - - - - - Generate Chart of Accounts from a Chart Template - Generiranje kontnog plana iz predloška. Asistent će pitati za tvrtku, predložak kontnog plana, broj znamenki šifre konta, bankovne račune, valute i kreirati novi kontni plan za odabranu tvrtku. - Isti čarobnjak se može pokrenuti i naknadno iz izbornika Računovodstvo/Postava/Financijsko računovodstvo/Postava nove tvrtke - podružnice - - automatic - - - - - - + + + + + open + + + diff --git a/addons/l10n_hr/static/src/img/icon.png b/addons/l10n_hr/static/src/img/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..8b0db59f104b4cbd38f7b3c9ffcc8422b88c5701 GIT binary patch literal 17892 zcmcG$RaE9q&_0Me4DJl>?(XjH?(RCcySux)ySp>E!!WoH`eHBq`F-E+)$ZM%y{M#; zbf1$-s{5(xdXgw51xZ9WTsROA5JYJyF%=LHP`YpZ4F>FcoBHFr^m_;Dsv;=@&N(5k z`h5WFB&F>N0s@cvpMWmy`hS3c5P?XG39ET+UG;h9nyY6)zFm9GcU7rqy3YsQP_SjC zQ^cDgD-8xl7FNcBLop4;7N;PTWMW_=lZ8YEN~shV9&Ln%&v$iKcP}BH<`V4hb>zMF z30^1!hX35#uBl0@?{>f3Q}xMf>+c%~tZhR^Ms7R|93h8+fgwZqU-|z}+4wBv(F+L- zB!DxEL(n89GKxrMa{Ge>v(e;%4h9Vl=0OKb4~O+X=aGZp{-?osD8M?ty-2LprszvTau@|jQ+4vQ^92g-!6T~|gDX@gro+kXXBjrLHEk%)lu?>MVr^rZ-fJaMZ`a|#@b}nU&E;~!TOjCl1 z9M{TGIpK$s~NOOnCP{EMWe70b&h! ze1;{>j*P*|ynHcI2~AqT534wR1=Y=05ifzHLCMOdHgSWCSE5Xkh_T)GWOJ`E&nMbT zVJ#A?q+0ASG8+85YO$ZdcdTn)K_x|R){D`?sjgz_9C8In6K%+dp`fQyyUE|Y0%U#q zfsTYec4NW-LH5U>A9G)aj!vgyF}P7ar6krtJ$%i^gf7rlql+(mIN%9t@ifWa@W6L^Af_R*qI~BNPOol^2 z->ZJO6S`jX(ax35Fz9-n61eQu$Ew9rq%Psk;X#fv7c~nZ&bKY;=};>Jj^^8+!k7(gVW)KNj){XPy=```N*{lCgw1D*!273(vby&6IoKG5sQ+Sb=NB|4a5aF_WOd7+Wq_NDd{Xur3h6T z?~?+TV0P4^7Xl}bHcgiv!*8<>QZ9lVQ|lhk2wK>Mg(2Hv)|`LkCu=*xMogC~0u42- z$5pWwvqMQdtZ*xjUmR7T-;F*doi&P6T4bI<$Gll{A6d=VY5&Ms?}rIbK&n{(I5c6I z_pH-lbXUEUKcQYQ35zabEX3@DjiS|GDR2blstH|J^5Mjnxt|3_Xwf*n~ro>^;&ORur&gY@a)KG0;3kA=1 z_N-=drMZWrYrx#O4Y%I!U+sGxBhI-&>~K{fe49#473?m%^g7BT-X_h8x#yujaVjW{ z#o%Ua>}MLFSBIhiwBg(`lCBEE$BL?|P_}mYbwT*k*DZ|e?$(jH91U4fF1#p-(i~oF zwfe_E|6Pz^ZDyawLAHQyy*~3p^33DiMDEke^vqg4=)`5OvGY_CvKInR)KHf$ zLK1U!-_~TlZrdHHB;ls}oJ}S={5l`cLJFwitsli|eSLMubq!9Dv#U9OGi>(cQ=5LA&4uT&rkHfTH zPxtuMFk!i?9nnm<*K;&QvuZ_BE|7z#A8!|$&jOEFvW9%dzJ8FdOGzmmYMr1Hye}7iv$;C!iiXJF4kxE_( zJXK)f^E>KoZ^`*SF35iIEn!)P#jbJJ8zEkd_qZfJMkL=NXLbj!@M#u7?be1H*b`H{|*Ul%)XVe}LW%vk*xT zSEbg99oLnRY`ULnPy96CdQ#(ez3{_}@bB{g!m^(BYCbveeE^Hw<72q!!i9zjz=zc7 zNNSW9CKPSnhZ3H{I$6{if8^0POT$9R_HQbb6?4CvS)*Lk(TI7y6OCL_kYMD1}kjZN)D zc1Z)4%)=?$rfO8D9r5eUr{YFWxBJc1(k$m44mTFgI7uX1IqiAv*ju|8l{v z3wT=24>xnh$U0^j{EEb>x{Do05x2M5=Y{!vh>*Dch@Z9}N6qbw{s>5d<^znM9Ns5|;lf6X7$6==7 zX|6w})I%n&TmHqz1(yff5OoJ4nCe@WCih6mXjX__$M|@E8h1$dX#5?A;r$ci+1st6 zfa-|;d(cO+1z5A7uy*OgqNhe>dNYDt7o~f;fo^6@HQeO(R^jpbIVa}G-}`uhzQq+` za9i9`@a*RVe*%c7(?B?>8e;Wv7}q|ZTyoWXBwXI@I<^%xjDHYtl`J^J1Jf%GrFlUy_+@_FmgBR23T6c{-Ip_a z!D56ZZ9}L|gDOWZxUnNzOtV;Q>8iY%{sFpO*iC6fw#FIi*y{HV7 zj85`+cCE6-*=`3#mcqbqMrOAEY|+Uk=@{>iGFEv@aNR z8{p;azMGn)legX~Zmx?i0Uu7svVv_JcW+JGS?TO3-I`!>O8dY=*ZtR~-rCZ7jPaiE zDx+>`%b{wPZ_M9So~IwAlJY0dfYW6Jl%u1WwzbS_n}a{ZK=aft+UEUy{8&lNeTb{rA{FR;U%%ndb7i!qcP1#bck8pQFg0sVQW#{ zRb57W4*;;D_l`?3;yyE#+?7Mqi#NK`{Y&XnYJ|xo%heakJWPUD1k=>M)7R`1r4Pej z;-E>jU0`t|dz*M=2x_}~F~qxJ7HOgAE%+e7t=)YtW=wAdbIfl*T+$Yctv}Nyl@`>V z;JygbknV9#Yo(_ab#o-VfS1|tE~KQvG4MXzE4aM`<`iZ^V?t_Co^{qKp`~Ul)0Nt< zdrMNL!*I)E^TX`PQ3gxFbR>bz!+;nyx+JNU;_&4KK-l&czK`BvhY3rItHFM5g`yt1 zyoOBsnZWrvO#ae~4vJmuyXSO9x$# z^VOF?$w|uA>a#r^vsGW}rbR7R1XlWd-+B&{O7EspCrLtQg@4W<1BXDukYjB($<;u+ zGa^5H#?(y48BP@(nTZGRBkN8{{y3+cT*`>{h36loyAGn+nC_VUF@5-ZxdVkE*-iev z9xXf}_SS-VPW>w?W$)$j>cX_*YgvG@LiV}0DfFr|+Yb6Mq#aFw)+GxfPr6L z8L|VUf15GA*^;T6cM<8GxQ4zAiPV%oIGJ!Ib2-Ee$ii}^Z0ZQqKRQV%^WDcM3JeSz z;zV|kI3!mpR2Uc-%gFlNhSdvd1UvDxJLG0x(z&&pNJ?{t(tq+gTX^g@CQ3u6{o0F^ zA_gzmtwWfyR*8E7VXPxPH2kZYapye0R9EUMVHGu0d3E#3z{v0G=)Mn7@Uj^z@qHF1(U-=|<6~-ec`S6EAvE~%o*&r6!*BnvoKf5N+H_~%FvRd9D{n0+SYpXhC<%-T*R#W%0j@kYNAE?qHB0tB z7@i-k?vmyBRpf3bFU7DEyTHX5$Y!!N@U+!Tio{>~fM)5?{h=A3C4`PV?t0oZvIR@F zV?aiBbK*e$qT7=Kh1{CtcJox{$k!;)XEA46dWKGP%&`|X;9+z81G;G<(v6mVi&eXd z)whhVsi+&IY#K#<`KcrY`mq&ON<(!XPJdw{ZC~@*CH*1IWW8n)!g#unS?ThMk@=<} z=0ZiOi^4u}t1NA}d3yNuZb|SHs{3-RZz2Y(Ie#J?tBysV(SjAgW%l&2{?Nb2M-c5( zF{hQ}sVR?Aa|f%>8KB}f#^QwA$+O?KCM6s@P~ZI3!267aZ$;zBG$~!$_&j9;)h#Xo zYo$7!>5wlU^)yxvS$ zec4>8ZHHy9-0p^sp_vR{gWC#=kS`sxro^otVuHpe&4DcKc2oAkR4 zO9ILpq28qzB@jz3b|1t@+vr zyHlk>y3Wv8!TY0OLVTba$1-8GGpzhA33Kjy^VmC3~432Yu zGl`TYbBRddmF^r4Nru408pppHz;auuC)VCIVe`ZU&djdGpDLE}b@_N<8F`V!R7A@w zilfwZ%+=QNZ_xGe@Ee%Gc1sm#RT%6-Jr*^IJs9--MJr7-c7b#hmO zMqiZBZ6_~qA4FJAwEC?#%;{uBA1uy_S5Ooap>MR4{Cu&x8!B)E;!zADKaxCe%71z5 zn*KmAALg*$H2rrLQ8C+l7f4-$^&#(f*$ts}awAS=Hw!_&qhORyVu!CHQ+fZ3q6`Oq zYp(^cV5m=;doi}gElGa`a(grXAbz~g%$|Kh!!rLzyz}nyL>mvjamUSQ7b$F|(Ru1b zSbJ3|woWM+D-Cl!(@FQ+c6aJ_EgkE?=yHumcP(~3qv< z`bL~pQ}#6$hjD+S=zXramGo)4DYLWmNiTgo`)`hS+hjBi-L5h`ZeIQ|EPK*Qn9oK$ zyiu7g(M+xGkN@!ZIJ2#&eI2iHff}~!y5`uL;sBhNp}YU zH=4A}mZv9%3Hrt$ta1cZ3y)*GK|2W}& z{+#c}YfvT=-?EvGqRMBcB9c*EfXcwV|GeNlu@(C5(Uu{iFwU9Y=D zGndO;l@7L9J?O3)4C|SX=>I&pY>4vOnG9|23?&66ra<@)Z6044U`$WNg~j*0RkqK7 z$LtXSw^-(%a;YA1Eafc-R{P3*84gcv&lfl2$uYeC?#pMw>6Uj^scE6BdFk zgW|_62}nU#eHQa#f*m!7_3H?Xd>^Ix8FvIOlTg=#{$-f(hqn_q7&epZU^*X;oEAYl z9Z1#+W$}k7)vjwS*KU0&nJOVlJN@*Y9uQo>Z9xBJV#Fs?#K!aM!vjC2!sjG(w4|Sr zzwY_F&-~X~KD=i9g{=l-&u84;)0R+H5H643+R9?UK(Tyf9e$b}KIqS;(u$aMv9w*}JLPgX&RE<-W!8Hol^!xpNs~x( zjZTaE#6xWMkd)-|lKaHMhwHNrpR08G80mY#hT+EJ($H}POTfk{I@R2rm4?zhPLI!3 zuU`eaPw{U3`=(TC+@+Mme&cO6HMEt9K|tw?3!g2J7O@21w3em>^3rf%8i~M!Q=fWe zlgv+HdAvsStvf=KAmHSZe;HZXg{U`|;)TDV z;Tm(RQKCypyMnr7$&=_rtLw0qKc?lC=dJL6V$Ep&kUtycNs&4cH^pd34(%cQ+gr)# zPB~n#Mok$_PN|+vPpgO?ZAb0t6z2!V-AX;YRyZ%nSBk7f`~3 zXP1QiMN=mze?~NjdAE3b1z;rn9NQ=4HW$wc{vmLmrfX1;>=ub=Dd_6C-39oleUAzd z5Y(Rl(6Mm<;^-(>GO=}&-XoI@0x#WDw4)U@IkvjZr{)0iJ$Loz zReSN&Li3Fdr}O=1iw8S>J9Aosk+2rR=Ze72J~(U#S}9})ca{TB z{g?zie-zrGvU0B)GGA;>j>i1ssZn$11sfgQVqa@#I973MKR&A-Sb8+InL%!OVs|lx z2ETVq-=W#A#_ieG7Q4^7uTDb?Nil!HQi##8xM>H1;bP}vub1QP=z;UP9p4*%fSr!Z z%(OLf3Otftldy;XL(y(R_6Jr@8ldMRr@>Qk^-%X=r|7w`zbAjODSihOJJ-*6Cpzi}i z`3qf@OC3hU4?M161p#=DpS~BC>4F_WqQ*~4H39Y!H;qm#q7l}?2G~2VV=?gd1OySc zDSNM>?CxkSWSZRZs6?bxal=b*1rdA)ji2&+edsj!0gp$9pDqROhFh7d`TQndg3k_} zJpo=%8lq07Dp)?ZFZrfh9ms*ms7V)MpSNcSR?Oe^3N5P`M=bxDKejw}o{*5#)7^Z5=1lGgU zUQm>ysf~+awins53rAbeeTF5;_ph&iwyCv;h?CvUnP=1G>F0j`zp(_tctE*MzxT0Z zIg;a=;*RdXd(^7uXVnO&H!3?>F2-)dZ%I5g6FoLuWrkGK?5H^ZV#||S&iu^}U_i~+ z$2wItUSg6Nb+NelvJ?uM4lxvJ|87q?CW?}3f!_s1O76o38YO+MGjLekU#UWU&rqx2 zEx2(Z;0})m#<1V!WoIIPiaQ#6p#{a?hl0~dcjE}iZ~!4m!HG%QKq!LFT$kd45U025 zw+xqGk}!LmbX!Q(E1V^gd`P}HJ8>hRLNtQdUP*(z*s){yzAPG&z$aw5_kwM5 znn_>r_blVjM#NT-0qkzepj+sGG!zU{MTVz(q3e(c87;4>!Q_k}>F)B~;IW|Z6kHF8B)_G8V;L^Va$5hWxf3vahjnRg| z-;}l95L+mks)oOC2i~UtP|jnhNz?oF{21M-i|QO)l7R>c4GMK+&8#+EqM(q=e0ntO z?=J@U$gXqUjj-(wuKwe8#M0G!kx*PV;);oNh@b5T)Hns+9BG(biQ zOUPSzFmF}zc`$AT9Pb5M$}#oqCK1@Vbh~(NcSoV1R`F;d>rXE^Vm@h-{o?EOq$%5= z#zINRRi;f#NQ~MYSOn@T>?^wFxlhn|C}(riC?c zi`FBcI5EE?6QJ&)!7Rx3eCW^3UB8o9=>XP#aI}IX`3|JVT^AqknPdI{9|IPjp=eUY z>g0pq;c*gKs>K_`?UiWMVwzYaBr@M^Px-u`Q6d#Jdjx!BYw@?YH(q4gmXio7K~uEIZ-7<~2Ks(t@07M=cF$oErs+@T^hPo(FR zWK>T=D^$@&6|*mAbwD_&EfN#)^OskiR^E5pmo{DzQVx2NmlonC8Ft-!smEoIS`Msa za5BS{NUuY68MwR$&ou6mM28x@{w2J@Zky^46R)@93BNL}1W--JW#UEr3PhL9nh z{*SjWRchFvld{xDhnEZ9zvui*RTO+rCfo_m5-d;QCWD>a0rGo1uK+we{Oz_vNhm@Z z7)cZO3xKblK!AW)tZIfDNihA|T9yFTu{N2WnmEP?#JW{H8`v07fliBrnpj0jB+D3r zn>U+PEwM1w9$81YAD70xTS~6D?Oye|?0sBi+*YnlmA{Z{rilZaB#DVu1xfEW6bg9> zMwM6$R@#rL zW`dv_Y-@2e6Ii106kN-Mb=W%TwW0b`{FR2km|+d^IRC3hgWi6+*h{G=PKPe+^ zo<5$lgqgtvV0F=5UxT{fpKq)2c|C{K@)GzSO8XAhFMs}ueRLR-u)2xGV={(MFLS%9 zH%pSn%hW+_qh0!41y70=gkj^564!$6sxn1U`w}xj$aFW32Q_f7 z*pE{M>mK5m7kW4mR`ZX7DDJrbVrV7moIx(H9%Vp0^fSRYd1KFkL zZrc9W>ktyu915e1BO0fRa0=+I?)!2tPA#mUs>=43fZ<@ca>w*qeymlfp@ zzApRge;AC60pP-V2YM9-E?ZcIhhOWK?^)6bH@D{0B6>S$;TJUF78@5^V)Z z<367UcyTTBz8+SOeupzQBh{Y;hDDA8K3;AiWaYJ7%JX{F5YDNzB3cSWr0K+iT{ajz z+~C<=jEj-h@}=-teT(kpD+vSy4^M%&!saMT2$Bj#X)YEV#AJ@j%BiHPqiRz-EagGW zVToVFm?U{UIS|9>+t{0GR{XXW>&d{G0=^Rab^d(9&5M4|4$X}3Wm;+T35RGoD@I(C zVFIX*7n5r_{E56LJJ;>lFxLD4ub24!Lqq+6w*^I#8rX@l_<9*^`XPS%Q%u={#)lha*^TX3jo2JABb@;9}=B#IGfMpa%+jE=C&*(o?;n5M$W zcjz6>^tmW93+i6i^MFmJe4@GAtNxPX%AAxi6ZjPx5;k`45y~b)()3*BaH>Ul%5ME? zB<$@gJPns_s69TRi^_VnGI442M1Ln6qEsE6sw>-CH~gZFYgSYpGRnZcs^o6 zHj-m?+HrSW%~~`CoH8HjHoIe9t17?lUkk3eZBm_RrYztoa z7T(-r_UIw6Rn;#(<(h5pPX&3;KV03G^NKN>&l0?Zwkn}#7%1L}s#6?X zDQsePuEmYZ1Ya`c%|PfqA&*6+kNzwap*D=2)CGFebH(7jLUE&SURW(js2)IUGgtr7 zYZjAWl|zw5NRE?0S59p~Ke*9zTw*({o=e~1?bskZi5UB*A&t$W*UOEp_V4<;$~_EI zJ4z9yrXE}Xc-6E{a0|w= z#?-&>5JQSchmV&^JZquwMR$K)L>H`qHoemqf@j!jOI|ileLCv79JI2_pWFLBM|hft za&+^AcH#ixZ^5BKy3>spOsJ8-pOAxqaCursqBj&6C^Y=P^8c!Mq9lqyWvfp5#%s@) z64qW$Nc~|J^i^diHK_zO>o?6FgHkHtwkaQrxVMiWh6YE3800pSdrf(2Dlk+Q(rAl< zp|;Cfz(U^gtFeCiFrub9H{dl5U6YIL3WqpsU46hSt&N8ykG7P0N2NP(MIC2wjVPBuw?neJVq*iiM-zpxL1`7vm`pLovNVF>F-zFO{_X>!hNx(^uHWl+k0D}%5kWz zj${eOAv_hA@%_&P=_YrahIT0*Fmad=$4#qHm6D>X&}am0R(8o;8cj1;aB8EJnZ<6L z5y?#)xa7^~%UZ)an^4YEQ`nTuAjNOY(Hu*dLbLb2xfPNkJ@!Cr+elNQ;n4&!k#cpN zthFR!?8{uU`3x1Es5pu_2XxaEI62UijklwP+`tp@5IFVZWz46Du-c%`L=<-Spgvg- zPKa5=5KKDH4g{-qY6Uvl(oFGA!}W3TBnM|zDRdhu00SLK`@G9(L(I($aw=1zljJbA zV97dd5gI|F%1PG>^Lm|>RNFfbNh=oE|JYa-RTq$mAP;^p?3ZE3ix@nE7d=a{>fcq~CK6^C?c z?jrCj8Ly%iPWaus(5N>|$S0m$vCjDm&M`#UskDcf*L?M!*O@;wHB?U#k{(i)HaDgU z@AvlxE=C8yS@@n0qsY2UdL!AU*;)fG9(UJziBN}iA0OC+cIO8F;&ZzUbi1vdTNc~2 z<%*Rsc_iS7v1{rGH@&Z@KI^@Q#+jItT2?0!^cad`Y$o4c&q(I$OxH|D)uZX2Gzg=v zi4Ywip^Dh1isQe&()#E8-qJ}2dnnr2z{0h*Lh_2PWt3qmteG)v3+S34*)}l^*S1il z?Bq~HCy$^DI?P?uj+sdR$vAN%?JmZ}c3}-vOaN~NmvC#%RMr5HCv=6EcA80}rn$-mv89n` zbQAg3ut_N`qiMp><3B_a=a`(Y;&Lm0^$ZoF?UT~15>Zpo)rNe#T}@bj=I0J1h0+etNEV+cL#q_@v>RIAntChbRe8%Cf_Q<0GK|;9;x6i|WG6)L^ z5gGrl{6CdJ-UKIw7Ybu~37Eu1%x!#C6FIt^iE#Q8=r=Z{>7=p#0?HtSk4o4^ur@05 zX0fA45a~+PrX?`;6rLt)_j;;8iD5!G4m6#%_H5%+>fuI*yO<2_aVZIvLnxsk0F63K zr9Cqv3h~AA9OCGbPH-Hvmg!J-mKW&vsD~I|@OZ7svC`;x(+=)$9**~u7JpdArxu)7 zO#us*yGzY5<@S)go*Z2}BXea7qdURCedSh|T_=hIdaZy+;IFquHO=kVE^9C=)Y&jU z!FDp|S20UMCXpz#-9F-_V1gUa&8xezzOj3zZ#G=+! z*oLBVx>UrPsn#K(#dBH3MtM%SknQGy#iTOXjtmn?tpdCW*hhjW=}JTg@y#XM(OI7% z30qU?t|bEE?*k_EPa&L1R{lAqJohbAI!-buV#+eOkO;@Qu9E16d<#l7)KYU@8!N>y z)WkL_)0r~Th-jt@th2sP_2l7YFc_v3A5vLT$VT*64l=%+0Y|Je_H?9z?9)^JQu|0` zAA*HpYc>Ozu%^mK_$6R#A~H-4H@oJ<9K4_;{GON+hM#B6ZUGl(KghBPhXUSBpc z)L?N~saT6}caHwp!iAthq25epDsgO&5FLq#T!J@x+qd41X?EcI%w{GqlIV0G7P4{Z zsk5G0(fXessye=N2zkPz^3ab`OCimkD*zV-`FQOYy^O=H;Ll69j281Ta1&#{-d!yW zKlOEG5?zQdHe@18Ay38PssvxpQd9xBh8YaC_{>0T^>JU{G6pi%*m z-o0ngg#v>Z;;9!4f1F6H^u5AvK#7xBQbxa2!!eh|Fhv}qm)y5bHw94CHpJ6dvX5LR zHtE-9Ry7$8Fj%Lo;V*NavaKgAeRgq&s@8uGa%}Xs5wN&yQ!W&$GGFIpw%^6j2=T?U zfsaqpJn^-5D{1czOD>e5@6@)5C2aR`v{ECn67vuuGdKWtndzI3ENgr;dlx`Rr+Y)? z(^cEo%e5^kHB{H_(+UTjjdM)#-b$a-XxcILKR9Oq+Sd|0Rq!|A9@Y~bIuEg|zqdg< zssev1v^?^peRVwcZkxGD5QItPZ)AGZ6F8_YzutSC=9F`@J*rWuOt7|zd(CSoN@-(~kC*H+gxw=1Fkzgq-!j3@> zJm{AXo9F3)ppRrB#jyE*JY(lvyWuS*yPwEXounb7gM;61!ZX=r4!mc8N69vh`5+qt z0`*2}7ar7D=o?uUCK5iMqCTY^Ze9hmfUi}cF6E@nv^WM%C z7GqjmTcCtsJ&E8zCy6Qj*M>CCInpt=XhnaD#vz*?3wiKhxO0ipRMsU3i~s&gzowNk zT|lOkKKEJiRvR$RN9PLqOq0TDg8!E|prPlC@|e~#&`I~b;8@YL7c)`qW*L^Wd? z4ip+?Hr3ISCh(ELHMc+HGeaH7YLq6(bk&-xC~<|7)>_ zX(TD~_q5oYEVwltv$LK9b(rc@$JR7;8Bs(!Lb2m$kzV4!zk7i5kf; z)=iq}Zxxw5Vv1o(PPz zAvivEC%?nlLFDV4C=R9CigaFqUW{hIUseKm3Q5Xbvo}eSkXF{x$@Lmi^HO-IU(_uk zrddW32(Cv;cpQ=Hw1_y{pUg&xg3%&lnWj-ji+nl^k_a)Fm-$nAqXK55!@#zY0B>9v z5{)X%=hZIhzYc^l!wRg)^LM!@rRI6yn)DR!!6^?1Iz>J&52x}z|Aa4mneW{DhLWLp zyGMTG15LD94dvMrZZ;j@BYyfhEon0TedrsqQdnH;H&u1@&wRH;Sb7s?obRSkIX*{A zcsBgthoHXzN0}#RtK{^PYQEQ8$n*WozzEkk_F2hL>nb?YomM0CGXpL(5V4GDG-8T( zqmp=14u*Q>26&v;P@V>MwL@OjkWTpf16btyz9KRxmn~e20`GQCGdnU5(2=EH6gHF> zXe~KPEPOZY+?XA^`(5P8dZVW--YF|M#@Vh5p1&T`;3B=Zx)qnCf|wN!uQpP=tL)IR zMP)2_D#BIv4aXyjHe%;chZ>Q<) z)w^!@!d$!3G!1L6n^|A#m4t@J<-Ubq3&B%xJV8Qq4rFCpewC$@Q;lt+ zf*G-iS)oBKv<>I|m0W`^I;>?*fu?SBQma@`YvbZIhg4y6obs#rA6mubi7$uYNSUa$ z-$v%9^Pj{X@$*~@1$6P*hMjhnpMvZ@k0^zqRsl?jUG6l!Y}R(%cCM9B+0Eye1LIo> zJ%BB)wTKepdDmb+MK*gFrt2PMyB^2(7o%}m9FC=P{Iy?Vz!6&40aa?Z1FbnFAh) zM71uX$!`UOkTbPk#c?^QchSa=Jrrwgb7n;Q^n)*7!U{CR?FV2D$s5y#xttc-{0U|E41&b`{paM z%I;>_A8}?<2|w-cN9=zIROOtk6!>)pa{hq-{?13zfG4`$ev$MaP~+qN*ymc^=C)GM zr6B|DoRbg*tS)TzWw({6_miF50=QP)lf=bIw^mo(-`o6dW{D=K7MZa?y$ORiX6OJodn|>*zB&va}0i*CA&8cPMK~ z_#mJ{jctn^uhwEP3bfRM3JU$g5}~ro?g^Wd_s{g6-#mw(k;wO+c20dmw>~GYkR$y@id*#Od&gh`i)6RiT#E}J%Iv$9^|E>_NSFn zD%6m;Yo9N5_4LAEmg z&|C)w>sgD#4wv2hXXCU*I@YORNC+k8esck7=f!q$yMl-``%PAEkG}?k-P1?8g}8bn z-8yl=|5cuK;1|azEY%g-9nq66yF}Xs9sa)oFne}I#yzLG=HO*-)k~Uat;{fRq zN8JB2cK&Q*K~XNO5=uSXd%uf*6NA>KaxK^?MOZG(3^V-q@* z%C)fbz)0456Dwxvb?c0w4Ifj4t-$zVy>(FP>InrKo=Q$LxBpLj^5dlIM@iJ?7t0CuK%d(5HEfYmY=rncBY<`eBMiU9PI5kFTN(B*#&Y;Cv`~K6u^Zp)SAG{QKZE9Oe z1eFiyA&wO4f)zF8O`P?S7o+)cjYZ>g)pRbokNIOj4(BIZvxrG)v&|@l-}w%8#|}iP z_*+>LoOB2bfIC}*?|Cvt^;B}RlH9a~c!*{OB7VAyB&FZuW{20m+_`81X9=?crYl9k zQopTU@be6fm!2Bw2@AeAX&q)G5^Kph?3d>!dC$L`o_qjzpB2_6=Z|5YU)xfVKYBUz z!mg`Ba}Rlj!qlp?kiJ|22LHkoZ#~}mYZ7>vFR#hRs0cC0Wl*Wx8l(SdB&CnlW@VmF zv|B;ZSeLXxb$T_9y}neM!x|48nWe31l(00hP0(KgVXOckvM`dRe9dVstrlitzGD(4 zT3G>e`hBPV_dhqCpF<93f$N2_U`YOt*V~z}h;Z$!@NGf}ZU#g=ruO?p6CMurnDcy= z&xo3}JWst#>8mvJamnuZil~Ub}60`Tn29+6DLQQT>6%Ms`wY ze(xL>a-AdgibRv0ajfIG+VR>JL%yCn#x3c?`R~0H7#{H1eXR<<9o4$NpNUX5$xUD)>PC(*0_;^q@JVj2VJQuU>+DSfjZM1> zZAk6k2X`9wyn&u4f2^Jn2aqWXc6po2HI(#6J02d14P5_zW8d-LWp!UeY(zF@g^dpc z(O_Y&PvI7NIe7DweiSIzY3bU7ITpdctP7}ztbFW4qc6VsUuRlZDaIpx-P2H&Zc%{Sn60Ca@;_W=F-eJdmz2Xguk^A<_{X8zN7m5s+Tl*yf zn7YOyc~OyYw4yh;5)_eVteb=p<|eYvL@5^lG#hHuXy*M|OPC;Zd0zq0q&n%MRUf@C za7nLbjT=9FXDj-mB91J6rew<>jsrDP?yU50-BA$&N%3E+b(#xjx}4Xa+jxq6$32ZW z`_s7ZQ#R${p{x-}EgOj_RzZmE#V4*xq*%PDRArS69jyt!s=vF#ug z?z$_LGFz*ue_QZ$ENOtJ?>rg>t_e&HrU{f*bKM@%)JvR{Ox~`0gnhLnUlFO*^Mzij zhDye5Exd`40#2sncy$;1`f-2pCi0eZbWK4pZUE6FmQ4wujTV_Gcr8 zIX+8=ZWbisGEEjzaDQ2GqMCVJoeN!yA~mVe({LbjLk(}XA;4G_5HyW_x|JUbQm&L+ z%##H#S+~7sUuejHgw!%Ovc7?%9jybBDr`W-j)%*Jl&sj(o9Sp@ycpJ%ovBCj_U?Xj zd*Bu?JKS5DEc@bSEP&k%5mrd)@5% z*~jo})Uuej{@uoRtHY8`d+2nrSCn_H2_f~F@?Goy?5Eqx4zuqCTU?h!K9;UJ$)ft_ zzupYN@KC-zdEagQBQb%rjr>iM%t$KW7sl8wQ_t{r7i-Pz3 zI2LPn&?C1+Jod%$o+~cd_b1MnQ68?|2b@fK3mnYe@qhW=>gb7!IT#FLj=!5X)Ar1| zSsrFN9wxiEx$bE?g@_2|?-BeYW7l|Ise@5bV6Qk+r$Ebzdnc+?G_rhRO8vimDY<@f z6|ddl1;6XB8(Ux4Y=71C>Rr_<3yZ(q`tkPlZT-E)CEs5ypa1^ukBZz~JOBL3e*Hc! zRDb`AsUO^q6{mmyZz1KrzIl2OztPvI%uFBs<(|Bins8Ejhj}k(l&h<#uP2)YEs1uFcsInk4w2`O#H= z3oh=fEAA~{6@2M*;+wOZE^O|7eE;5SyPccLH$3}xXzACJ&r*M%ntHNz`RldaxwlRA zey~^H?cd*1V<-DHw?sQ#Zu{-?+m~HCJ^9tY=H~ZhZMVy>oHM^0|GWO$>Fu-D@-Nqa z(`WW6bFIkXO;YkxPj6jq!#0g+^!Xx2Frm3oo2J zudR7EE9X{myZwIC`W>}@{w}Nhap&U0C9}8gnsxov#v)e!GeT(HoO=-^C39DinIiB(@(eP32&H2=EMW1(5&VIF|aBuZJZ?0Zi zH}lQ9b#rwrrrcG?xuA7YBh)~vf5D=>(<%BrOIHL<{=aDU@>5d5dMp~RTefbibm%c# zbwPb%xA?9z%&A4&*6_@W$xLVEpR9Q3vYJm4$GSf%E3+2P^{7~HoUnQ7sk)3! z`q7(M4A+(1Zu_LLe2(`dEz8O7n~Q$V)R{e@FNsHe`l}@x{jWuSx%EfeuC|K3s`Pc| zeudbb$%n&IS$ceb>YD5~tDL+?>$b=!;Sf+{P-5v2 zU=U<-;b`DsRAO;x0kRdGfNTLpAe&re|1I5A_?R|a;F#JW! Date: Mon, 10 Dec 2012 12:17:36 +0100 Subject: [PATCH 27/41] Translation bzr revid: goran.kliska@slobodni-programi.hr-20121210111736-4mu0odxtubiv716y --- addons/l10n_hr/i18n/hr.po | 142 ++++++++++++++++++++++++++++++++ addons/l10n_hr/i18n/l10n_hr.pot | 142 ++++++++++++++++++++++++++++++++ 2 files changed, 284 insertions(+) create mode 100644 addons/l10n_hr/i18n/hr.po create mode 100644 addons/l10n_hr/i18n/l10n_hr.pot diff --git a/addons/l10n_hr/i18n/hr.po b/addons/l10n_hr/i18n/hr.po new file mode 100644 index 00000000000..59270390071 --- /dev/null +++ b/addons/l10n_hr/i18n/hr.po @@ -0,0 +1,142 @@ +# Translation of OpenERP Server. +# This file contains the translation of the following modules: +# * l10n_hr +# +msgid "" +msgstr "" +"Project-Id-Version: OpenERP Server 7.0alpha\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-10 11:08+0000\n" +"PO-Revision-Date: 2012-12-10 11:08+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pasiva +msgid "Pasiva" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiva +msgid "Aktiva" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_view +msgid "Sintetika" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_inv_rashod +msgid "Izvanredni rashodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pdv +msgid "Obveze za PDV" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_other +msgid "Ostalo" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pas_razgran +msgid "Pasivna vrem. Razgraničenja" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_imovina +msgid "Kratkotrajna imovina" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_upis_kapital +msgid "Potraživanja za upisani kapital" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_obveze_dob +msgid "Obveze prema dobavljačima" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kapital +msgid "Kapital i rezerve" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rezervacije +msgid "Rezerviranja" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_potraz_kup +msgid "Potraživanja od kupaca" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_imovina +msgid "Dugotrajna imovina" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pretporez +msgid "Potraživanja za pretporez" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_prihod +msgid "Prihod" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_prihod +msgid "Financijski prihodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_rashod +msgid "Poslovni rashodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_obv +msgid "Dugoročne obveze" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rashod +msgid "Rashod" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_prihod +msgid "Poslovni prihodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_obveze +msgid "Kratkoročne obveze" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_rashod +msgid "Financijski rashodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_izv_prihod +msgid "Izvanredni prihodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiv_razgran +msgid "Aktivna vrem. Razgraničenja" +msgstr "" + diff --git a/addons/l10n_hr/i18n/l10n_hr.pot b/addons/l10n_hr/i18n/l10n_hr.pot new file mode 100644 index 00000000000..59270390071 --- /dev/null +++ b/addons/l10n_hr/i18n/l10n_hr.pot @@ -0,0 +1,142 @@ +# Translation of OpenERP Server. +# This file contains the translation of the following modules: +# * l10n_hr +# +msgid "" +msgstr "" +"Project-Id-Version: OpenERP Server 7.0alpha\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2012-12-10 11:08+0000\n" +"PO-Revision-Date: 2012-12-10 11:08+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pasiva +msgid "Pasiva" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiva +msgid "Aktiva" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_view +msgid "Sintetika" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_inv_rashod +msgid "Izvanredni rashodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pdv +msgid "Obveze za PDV" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_other +msgid "Ostalo" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pas_razgran +msgid "Pasivna vrem. Razgraničenja" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_imovina +msgid "Kratkotrajna imovina" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_upis_kapital +msgid "Potraživanja za upisani kapital" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_obveze_dob +msgid "Obveze prema dobavljačima" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kapital +msgid "Kapital i rezerve" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rezervacije +msgid "Rezerviranja" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_potraz_kup +msgid "Potraživanja od kupaca" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_imovina +msgid "Dugotrajna imovina" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_pretporez +msgid "Potraživanja za pretporez" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_prihod +msgid "Prihod" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_prihod +msgid "Financijski prihodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_rashod +msgid "Poslovni rashodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_dug_obv +msgid "Dugoročne obveze" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_rashod +msgid "Rashod" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_posl_prihod +msgid "Poslovni prihodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_kratk_obveze +msgid "Kratkoročne obveze" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_fin_rashod +msgid "Financijski rashodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_izv_prihod +msgid "Izvanredni prihodi" +msgstr "" + +#. module: l10n_hr +#: model:account.account.type,name:l10n_hr.account_type_aktiv_razgran +msgid "Aktivna vrem. Razgraničenja" +msgstr "" + From 07527e1503b93926ab2cecc15d78d4705ac897a3 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Mon, 10 Dec 2012 13:22:47 +0100 Subject: [PATCH 28/41] [ADD]Check start balance option bzr revid: dle@openerp.com-20121210122247-qb2sa1k183wrxh3d --- addons/l10n_be_coda/l10n_be_coda_view.xml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/addons/l10n_be_coda/l10n_be_coda_view.xml b/addons/l10n_be_coda/l10n_be_coda_view.xml index 538332b37d2..4cb863d234a 100644 --- a/addons/l10n_be_coda/l10n_be_coda_view.xml +++ b/addons/l10n_be_coda/l10n_be_coda_view.xml @@ -2,7 +2,7 @@ - account.bank.statement.form + account.bank.statement.coda.form account.bank.statement @@ -13,6 +13,18 @@ + + res.partner.bank.coda.form + res.partner.bank + + + + + + + + + bank.statement.line.coda.form account.bank.statement.line From 54a39ac1b1ef5ebe7071afccdf3a25e097f70833 Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Mon, 10 Dec 2012 13:55:17 +0100 Subject: [PATCH 29/41] [ADD]Missing py bzr revid: dle@openerp.com-20121210125517-z4ehmco5dkmdxhmf --- addons/l10n_be_coda/l10n_be_coda.py | 42 +++++++++++++++++++ .../wizard/account_coda_import.py | 16 ++++++- 2 files changed, 56 insertions(+), 2 deletions(-) create mode 100644 addons/l10n_be_coda/l10n_be_coda.py diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py new file mode 100644 index 00000000000..13b67e76bfd --- /dev/null +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -0,0 +1,42 @@ +# -*- encoding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# +# Copyright (c) 2011 Noviat nv/sa (www.noviat.be). All rights reserved. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +from osv import osv, fields + + +class account_bank_statement(osv.osv): + _inherit = 'account.bank.statement' + _columns = { + 'coda_note': fields.text('CODA Notes'), + } + + +class res_bank(osv.osv): + _inherit = 'res.partner.bank' + _columns = { + 'balance_start_enforce': fields.boolean('Prevent invalid Opening Balances', + help="Do not process Statements with an Opening Balance that doesn't match the previous Closing Balance."), + } + +account_bank_statement() + +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index d27b28c315c..671a0a93335 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -94,9 +94,12 @@ class account_coda_import(osv.osv_memory): if bank_ids and len(bank_ids) > 0: bank_accs = self.pool.get('res.partner.bank').browse(cr, uid, bank_ids) for bank_acc in bank_accs: - statement['journal_id'] = bank_acc.journal_id - if (statement['journal_id'].currency and statement['journal_id'].currency.name != statement['currency']) and (not statement['journal_id'].currency and statement['journal_id'].company_id.currency_id.name != statement['currency']): + if (bank_acc.journal_id.currency and bank_acc.journal_id.currency.name != statement['currency']) and (not bank_acc.journal_id.currency and bank_acc.journal_id.company_id.currency_id.name != statement['currency']): raise not_found_except + else: + statement['journal_id'] = bank_acc.journal_id + statement['bank_account'] = bank_acc + break else: raise not_found_except statement['description'] = rmspaces(line[90:125]) @@ -225,6 +228,15 @@ class account_coda_import(osv.osv_memory): if not statement['balance_end_real']: statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] for i, statement in enumerate(statements): + balance_start_check_date = (len(statement['lines']) > 0 and statement['lines'][0]['entryDate']) or statement['date'] + cr.execute('SELECT balance_end_real \ + FROM account_bank_statement \ + WHERE journal_id = %s and date <= %s \ + ORDER BY date DESC,id DESC LIMIT 1', (statement['journal_id'].id, balance_start_check_date)) + print statement['bank_account'].balance_start_enforce + res = cr.fetchone() + balance_start_check = res and res[0] + print balance_start_check statement['coda_note'] = '' data = { 'name': '[' + statement['date'] + ']' + statement['description'], From 257db6feffb77844274828246af7eb1fee415a0b Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Mon, 10 Dec 2012 14:33:34 +0100 Subject: [PATCH 30/41] [ADD]Balance check bzr revid: dle@openerp.com-20121210133334-jxepuwxf9safyeur --- addons/l10n_be_coda/l10n_be_coda.py | 6 +++--- addons/l10n_be_coda/wizard/account_coda_import.py | 15 ++++++++++++--- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py index 13b67e76bfd..0b8bbf1bc24 100644 --- a/addons/l10n_be_coda/l10n_be_coda.py +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -27,14 +27,14 @@ class account_bank_statement(osv.osv): _inherit = 'account.bank.statement' _columns = { 'coda_note': fields.text('CODA Notes'), - } + } class res_bank(osv.osv): _inherit = 'res.partner.bank' _columns = { - 'balance_start_enforce': fields.boolean('Prevent invalid Opening Balances', - help="Do not process Statements with an Opening Balance that doesn't match the previous Closing Balance."), + 'balance_start_enforce': fields.boolean('Prevent invalid Opening Balances', + help="Do not process Statements with an Opening Balance that doesn't match the previous Closing Balance."), } account_bank_statement() diff --git a/addons/l10n_be_coda/wizard/account_coda_import.py b/addons/l10n_be_coda/wizard/account_coda_import.py index 671a0a93335..45b09e1a42f 100644 --- a/addons/l10n_be_coda/wizard/account_coda_import.py +++ b/addons/l10n_be_coda/wizard/account_coda_import.py @@ -228,16 +228,25 @@ class account_coda_import(osv.osv_memory): if not statement['balance_end_real']: statement['balance_end_real'] = statement['balance_start'] + statement['balancePlus'] - statement['balanceMin'] for i, statement in enumerate(statements): + statement['coda_note'] = '' balance_start_check_date = (len(statement['lines']) > 0 and statement['lines'][0]['entryDate']) or statement['date'] cr.execute('SELECT balance_end_real \ FROM account_bank_statement \ WHERE journal_id = %s and date <= %s \ ORDER BY date DESC,id DESC LIMIT 1', (statement['journal_id'].id, balance_start_check_date)) - print statement['bank_account'].balance_start_enforce res = cr.fetchone() balance_start_check = res and res[0] - print balance_start_check - statement['coda_note'] = '' + if balance_start_check == None: + if statement['journal_id'].default_debit_account_id and (statement['journal_id'].default_credit_account_id == statement['journal_id'].default_debit_account_id): + balance_start_check = statement['journal_id'].default_debit_account_id.balance + else: + raise osv.except_osv(_('Error'), _("Configuration Error in journal %s!\nPlease verify the Default Debit and Credit Account settings.") % statement['journal_id'].name) + if balance_start_check != statement['balance_start']: + balance_start_enforce_err = _("The CODA Statement %s Starting Balance (%.2f) does not correspond with the previous Closing Balance (%.2f) in journal %s!") % (statement['description'] + ' #' + statement['paperSeqNumber'], statement['balance_start'], balance_start_check, statement['journal_id'].name) + if statement['bank_account'].balance_start_enforce: + raise osv.except_osv(_('Error'), balance_start_enforce_err) + else: + statement['coda_note'] = balance_start_enforce_err data = { 'name': '[' + statement['date'] + ']' + statement['description'], 'date': statement['date'], From 73ba51f7af51c713b462b8bc766a0e7b6eef14ad Mon Sep 17 00:00:00 2001 From: "dle@openerp.com" <> Date: Mon, 10 Dec 2012 15:06:20 +0100 Subject: [PATCH 31/41] [DEL]Transaction families, code, types, categories, communication types, check balance end option bzr revid: dle@openerp.com-20121210140620-upq370zuvsetoojw --- addons/l10n_be_coda/l10n_be_coda.py | 8 - addons/l10n_be_coda/l10n_be_coda_view.xml | 12 - addons/l10n_be_coda/l10n_be_coda_wizard.xml | 1 - .../wizard/account_coda_import.py | 526 +----------------- 4 files changed, 6 insertions(+), 541 deletions(-) diff --git a/addons/l10n_be_coda/l10n_be_coda.py b/addons/l10n_be_coda/l10n_be_coda.py index 0b8bbf1bc24..40792dd3d24 100644 --- a/addons/l10n_be_coda/l10n_be_coda.py +++ b/addons/l10n_be_coda/l10n_be_coda.py @@ -29,14 +29,6 @@ class account_bank_statement(osv.osv): 'coda_note': fields.text('CODA Notes'), } - -class res_bank(osv.osv): - _inherit = 'res.partner.bank' - _columns = { - 'balance_start_enforce': fields.boolean('Prevent invalid Opening Balances', - help="Do not process Statements with an Opening Balance that doesn't match the previous Closing Balance."), - } - account_bank_statement() # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/l10n_be_coda/l10n_be_coda_view.xml b/addons/l10n_be_coda/l10n_be_coda_view.xml index 4cb863d234a..2464e5e9082 100644 --- a/addons/l10n_be_coda/l10n_be_coda_view.xml +++ b/addons/l10n_be_coda/l10n_be_coda_view.xml @@ -13,18 +13,6 @@
- - res.partner.bank.coda.form - res.partner.bank - - - - - - - - - bank.statement.line.coda.form account.bank.statement.line diff --git a/addons/l10n_be_coda/l10n_be_coda_wizard.xml b/addons/l10n_be_coda/l10n_be_coda_wizard.xml index dddc18bb30a..6e53a4d2ff0 100644 --- a/addons/l10n_be_coda/l10n_be_coda_wizard.xml +++ b/addons/l10n_be_coda/l10n_be_coda_wizard.xml @@ -10,7 +10,6 @@
-