Skip to main content

Romania - Partner Create by VAT

Project description

Odoo Community Association

Romania - Partner Create by VAT

Mature License: AGPL-3 OCA/l10n-romania Translate me on Weblate Try me on Runboat

This module allows you to create the partners (companies) based on their VAT number. It will complete the name, address of the partner from ANAF webservice.

ANAF https://webservicesp.anaf.ro/PlatitorTvaRest/api/v8/ws/tva


1. CUI (Codul Unic de Înregistrare)

CUI-ul este “CNP-ul” unei firme. Este numărul atribuit de Registrul Comerțului (sau de Ministerul Finanțelor, după caz) în momentul în care o entitate juridică este înființată.

  • Format: Este alcătuit dintr-un șir de cifre (între 2 și 10 cifre).

  • Cine îl are: Toate entitățile juridice (SRL, PFA, ONG, etc.).

  • Rol: Identifică în mod unic firma în fața autorităților și a partenerilor de afaceri.

2. CIF (Codul de Identificare Fiscală)

CIF-ul este, în esență, denumirea generică pentru codul de identificare al unui plătitor de taxe.

  • Confuzia frecventă: Pentru o firmă (SRL), CUI și CIF sunt de cele mai multe ori același număr. Termenul “CIF” este folosit mai des de ANAF, în timp ce “CUI” este folosit de Registrul Comerțului.

  • Cazuri speciale: Alte entități care nu sunt firme (de exemplu, asociațiile de proprietari sau instituțiile publice) primesc un CIF pentru a putea plăti taxe și impozite.

3. VAT ID (Codul de TVA)

VAT ID (sau codul de înregistrare în scopuri de TVA) reprezintă CUI-ul/CIF-ul firmei tale, dar cu prefixul de țară (pentru România, acesta este RO) atașat în față.

  • Exemplu: Dacă CUI-ul firmei tale este 12345678, VAT ID-ul va fi RO12345678.

  • Importanță: Nu toate firmele au un VAT ID automat. O firmă are un cod de TVA doar dacă:

    1. A depășit plafonul de scutire de TVA (300.000 lei cifră de afaceri).

    2. A ales să devină plătitoare de TVA prin opțiune.

    3. S-a înregistrat pentru operațiuni intracomunitare (achiziții/vânzări de servicii sau bunuri în UE).


Rezumat comparativ

Termen

Ce înseamnă

Exemplu

CUI

Identificatorul oficial al firmei.

12345678

CIF

Termenul fiscal pentru CUI.

12345678

VAT ID

CUI-ul cu prefixul de țară (doar pentru firmele plătitoare de TVA).

RO12345678

Notă: Dacă o firmă nu este plătitoare de TVA, pe facturile emise de ea va apărea doar numărul simplu (CUI), fără prefixul “RO”.

Table of contents

Installation

To install this module, you need to:

  • clone the branch 16.0 of the repository https://github.com/OCA/l10n-romania

  • add the path to this repository in your configuration (addons-path)

  • update the module list

  • search for “Romania - Partner Create by VAT” in your addons

  • install the module

Usage

Put the VAT number in the partner’s form and if it’s a romanian company, it will fetch data available on ANAF website.

Configuration parameters

The ANAF lookup (res.partner._get_Anaf) reads the following keys from ir.config_parameter. All keys are optional — sensible defaults are used when they are not set.

Key

Default

Purpose

l10n_ro_partner_create_by_vat.anaf_url

https://webservicesp.anaf.ro/api/PlatitorTvaRest/v9/tva

Endpoint queried for a single VAT number (or a small list). Override only if ANAF publishes a new URL or you want to route the call through a proxy.

l10n_ro_partner_create_by_vat.anaf_api_key

(empty)

API key for ANAF endpoints that require authentication. When empty, the request is sent unauthenticated. The same key is reused by the bulk sync in l10n_ro_fiscal_validation, so set it once and both flows use it.

l10n_ro_partner_create_by_vat.anaf_api_key_header_tag

x-api-key

Name of the HTTP header that carries the API key. Only meaningful when l10n_ro_partner_create_by_vat.anaf_api_key is set; change it if ANAF requires a different header name (e.g. Authorization).

Set these from Settings → Technical → Parameters → System Parameters or via a data file / shell, e.g.:

self.env["ir.config_parameter"].sudo().set_param(
    "l10n_ro_partner_create_by_vat.anaf_api_key", "your-key-here",
)
Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed feedback.

Do not contact contributors directly about support or help with technical issues.

Credits

Authors

  • NextERP Romania

  • Forest and Biomass Romania

Contributors

Do not contact contributors directly about support or help with technical issues.

Maintainers

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

Current maintainer:

feketemihai

This module is part of the OCA/l10n-romania project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

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

File details

Details for the file odoo_addon_l10n_ro_partner_create_by_vat-19.0.0.8.0-py3-none-any.whl.

File metadata

File hashes

Hashes for odoo_addon_l10n_ro_partner_create_by_vat-19.0.0.8.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a78a566f5aa3ed2d293275fd9eaa465e6e2b11a72d491e338229a1650adf8e70
MD5 c7f4b24556384db2e2efbf5a15a050f9
BLAKE2b-256 4d5e98b25f397c2cc792d182b9c291b4d96088d51de43762c16e9bdba07e3ed3

See more details on using hashes here.

Supported by

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