| 1 |
<?xml version="1.0" encoding="utf-8"?> |
| 2 |
<odoo> |
| 3 |
<record id="res_config_settings_form_inherit_l10n_ro_edi" model="ir.ui.view"> |
| 4 |
<field name="name">res.config.settings.form.inherit.l10n.ro.edi</field> |
| 5 |
<field name="model">res.config.settings</field> |
| 6 |
<field name="inherit_id" ref="account.res_config_settings_view_form"/> |
| 7 |
<field name="arch" type="xml"> |
| 8 |
<xpath expr="//block[@id='invoicing_settings']" position="after"> |
| 9 |
<block title="Romanian E-Factura" id="l10n_ro_edi_settings" invisible="country_code != 'RO'"> |
| 10 |
<div class="col-12 col-lg-12 o_setting_box"> |
| 11 |
<div class="o_setting_right_pane border-0"> |
| 12 |
<div class="mb-2"> |
| 13 |
<span class="o_form_label"> |
| 14 |
E-Factura Details |
| 15 |
</span> |
| 16 |
<span class="fa fa-lg fa-building-o" title="Values set here are company-specific."/> |
| 17 |
</div> |
| 18 |
<div class="text-muted oe_inline mb-3"> |
| 19 |
<div class="mb-1"> |
| 20 |
<div>Data needed to generate token for sending RO-CIUS to Romanian government</div> |
| 21 |
<div> |
| 22 |
To benefit from this feature, you must have a digital signature USB token from |
| 23 |
Romania connected with an ANAF account |
| 24 |
</div> |
| 25 |
</div> |
| 26 |
<ul> |
| 27 |
<li> |
| 28 |
Go to <a href="https://pfinternet.anaf.ro/" target="_blank">https://pfinternet.anaf.ro/</a>. |
| 29 |
Login or Sign Up if you don't have an account yet |
| 30 |
</li> |
| 31 |
<li>Go to "Editare profil Oauth"</li> |
| 32 |
<li>Generate a new Client data |
| 33 |
<ul> |
| 34 |
<li>Fill "Denumire Aplicatie" with any desired name for your registration data</li> |
| 35 |
<li> |
| 36 |
Fill "Callback URL 1" with the following URL: |
| 37 |
<br/><field name="l10n_ro_edi_callback_url" widget="text" class="w-100 text-success"/> |
| 38 |
</li> |
| 39 |
<li id="serviciu">In "Serviciu", select the option "E-Factura"</li> |
| 40 |
<li>Submit the form by clicking on "Generare Client ID"</li> |
| 41 |
</ul> |
| 42 |
</li> |
| 43 |
<li>Copy the generated Client ID and Client Secret to the fields below</li> |
| 44 |
<li>With the digital signature USB token inserted, generate the token using the button below</li> |
| 45 |
</ul> |
| 46 |
</div> |
| 47 |
<div class="row"> |
| 48 |
<label for="l10n_ro_edi_client_id" string="Client ID" class="col-lg-3 o_light_label"/> |
| 49 |
<field name="l10n_ro_edi_client_id"/> |
| 50 |
</div> |
| 51 |
<div class="row"> |
| 52 |
<label for="l10n_ro_edi_client_secret" class="col-lg-3 o_light_label"/> |
| 53 |
<field name="l10n_ro_edi_client_secret"/> |
| 54 |
</div> |
| 55 |
<div class="row"> |
| 56 |
<label for="l10n_ro_edi_access_token" class="col-lg-3 o_light_label"/> |
| 57 |
<field name="l10n_ro_edi_access_token"/> |
| 58 |
</div> |
| 59 |
<div class="row"> |
| 60 |
<label for="l10n_ro_edi_refresh_token" class="col-lg-3 o_light_label"/> |
| 61 |
<field name="l10n_ro_edi_refresh_token"/> |
| 62 |
</div> |
| 63 |
<div class="row"> |
| 64 |
<label for="l10n_ro_edi_access_expiry_date" class="col-lg-3 o_light_label"/> |
| 65 |
<field name="l10n_ro_edi_access_expiry_date"/> |
| 66 |
</div> |
| 67 |
<div class="row"> |
| 68 |
<label for="l10n_ro_edi_refresh_expiry_date" class="col-lg-3 o_light_label"/> |
| 69 |
<field name="l10n_ro_edi_refresh_expiry_date"/> |
| 70 |
</div> |
| 71 |
<div class="my-3" invisible="l10n_ro_edi_access_token"> |
| 72 |
<button name="button_l10n_ro_edi_generate_token" |
| 73 |
type="object" |
| 74 |
string="Generate Token" |
| 75 |
class="btn btn-primary"/> |
| 76 |
</div> |
| 77 |
<div class="row"> |
| 78 |
<label for="l10n_ro_edi_anaf_imported_inv_journal_id" class="col-lg-3 o_light_label" string="Import Vendor Bills in : "/> |
| 79 |
<field name="l10n_ro_edi_anaf_imported_inv_journal_id" domain="[('type', '=', 'purchase'), ('active', '=', True)]"/> |
| 80 |
</div> |
| 81 |
<setting id="l10n_ro_edi_test_env_setting" class="mt-3" |
| 82 |
help="Activate test environment for sending E-Factura to SPV"> |
| 83 |
<field name="l10n_ro_edi_test_env"/> |
| 84 |
</setting> |
| 85 |
</div> |
| 86 |
</div> |
| 87 |
</block> |
| 88 |
</xpath> |
| 89 |
</field> |
| 90 |
</record> |
| 91 |
</odoo> |