Commit Graph
1848 Commits
Author SHA1 Message Date
maximilien(malb) af7d4a6926 [IMP] account: payment missing currency symbol
With recent JS change on "group" the currency symbol was missing. By adding the currency_id field invisible in the arch the problem is solved.

Task-id:3089285

closes odoo/odoo#107106

Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
2022-12-20 11:29:13 +01:00
william-andre 1aa35de41a [FIX] account: required default account on journal
The default account was marked as required in the view (bold underline)
but the validation didn't happen. This made it possible to set up
journals without that required field.
Since owl, only the last `required` attribute is remembered, so we need
to define it at least correctly on the last field declaration.

Related:
48ef812a63
bd6b98a65f

opw-3061073

closes odoo/odoo#108173

X-original-commit: 7628888d61843ed9e9b76039884572e923ba382f
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
2022-12-16 16:17:51 +01:00
Paolo Gatti 9000c01f82 [FIX] account: Currency field if no accounting is set on the user
The currency field shows as a badly aligned "in USD".
This PR adds a proper handling of the combinations
of accounting and multi_currency groups.

Original PR in v15: https://github.com/odoo/odoo/pull/104013

closes odoo/odoo#108101

X-original-commit: d2363794411bbc9147b8ff0d519d588a3814e582
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
Signed-off-by: Paolo Gatti (pgi) <pgi@odoo.com>
2022-12-15 21:18:51 +01:00
hupo-odoo 9f0b0b3d8a [IMP] account: Improved bill dashboard payment status visibility
The condition to visualize the payment status on the dashboard of account moves has been improved (this dashboard can be accessed by clicking on the Vendor Bill Journal and removing the filter for example). The reason for this change is that for a lot of different entries the payment status is indicated as "Not paid" even though no payment is expected for those entries. Moreover, this status will not change even though a payment is registered, which is counter intuitive (for payment line PBNK for example). This commit therefore improves the condition to visualize The payment status.

task-3091141
PR number-107329

closes odoo/odoo#107329

Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
2022-12-15 09:34:47 +01:00
Ricardo Gomes Rodrigues (rigr) e54510cb8b [IMP] account{,_edi{,_ubl_cii}}: harmonize invoice upload
This commit aims at:

1. Fixing a bug where the invoice would be uploaded in the wrong journal
------------------------------------------------------------------------
To reproduce:
- Go to Customer invoices
- Upload an invoice (with an embedded FacturX)
- The journal is set to Vendor Bill

2. Letting the FacturX move type override the user-chosen move type
-------------------------------------------------------------------
Currently, if the user uploads a credit note in a customer invoice journal,
the document is not created and set to the OCR. This is due to a restrictive check
which has been removed. Therefore, when the move type is defined in the FacturX XML,
we will use it to override the user choice so that the document is always created
within the right journal.

3. Harmonizing the invoice upload between the Accounting and the Documents apps and avoid code duplication
----------------------------------------------------------------------------------------------------------
Currently, the flow of uploading an invoice from the Accounting app and the Documents app is different.
Indeed, if one uploads an invoice in the Document app and click on the "Create invoice",
the document is sent directly to the OCR. Now, instead, we will pass this document to the same upload method
of the Accounting (which will try to create the invoice from the FacturX XML if present).
Therefore, the flow will now be the same from the two apps for better harmonization.

4. Adding a 4th button in the Documents app to create a Vendor refund
---------------------------------------------------------------------
Currently, there are 3 buttons to create a customer invoice, a credit note, a vendor bill, but no vendor refund.
This is due to a duplicate xmlid which has now been fixed allowing the 4th button to be seen in the UI.

5. Adding a button "Switch into customer invoice/vendor bill" button in the account.move's form view
----------------------------------------------------------------------------------------------------
Currently, the user has access to a "Switch into credit note/refund" but not the reverse button to
go from a credit note/refund to an invoice/bill. This is now the case.

Task id 2961932

closes odoo/odoo#103427

Related: odoo/enterprise#32890
Signed-off-by: William André (wan) <wan@odoo.com>
2022-12-14 22:03:52 +01:00
PoMa fda341dc62 [FIX] account,account_accountant: Journal items in kanban not visible
Journal Items menu was not visible out of debug mode, now it is visible

 Closes PR #105704

closes odoo/odoo#107668

X-original-commit: fbedc97a5479bace8b23122fc423abdeb2c1757a
Related: odoo/enterprise#34876
Signed-off-by: Laurent Smet <las@odoo.com>
2022-12-13 13:51:35 +01:00
Guillaume (guva) e858ce0d86 [FIX] account: card color kanban view
The kanban cards did not take the class
oe_kanban_color.
This is because it was set on the child div
instead of the parent one.

opw-3069024

closes odoo/odoo#107778

X-original-commit: 9078761d10289446cfd3881e9df9061075441440
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2022-12-12 19:18:34 +01:00
Shawcker 6826fa3ed2 [FIX] account: 'Browse available countries' link style
Currently, the style for the link 'Browse available countries' you have on the accounting dashboard when no chart of accounts is installed for your company has no link style. This means it has the same styling as any other text, and makes it hard to actually know it's a link.

This commit adds a class to this link to give it a distinct style.

Task id=3094593

closes odoo/odoo#107653

X-original-commit: cc431997944ba90f61e543c73caaac5aeeb6f5c1
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
2022-12-09 22:05:57 +01:00
Ricardo Gomes Rodrigues (rigr) 6b396c84e5 [IMP] account,l10n_*: clean country-specific fields from views
Many country-specific fields were displayed while a company with another country was selected (in case of a multi-company environment).

These country-specific fields are now visible only if one of the selected companies with said country is selected.

closes odoo/odoo#106221

Related: odoo/enterprise#34226
Signed-off-by: John Laterre (jol) <jol@odoo.com>
2022-12-09 11:48:42 +01:00
gawa-odoo 670ef3d505 [IMP] analytic: make some fields of applicability rules invisible
When filling a Sales Order applicability rule line, the financial
account prefix is useless, as it will not be used.
Thus we can make it invisible in the case of business_domain corresponding to sales and purchases.

task-3040927

closes odoo/odoo#105014

Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2022-12-07 18:28:53 +01:00
Camille Spiritus 7509b27bde [FIX] account: fix invoice's pdf borders
Since BS5 integration in v16.0, the pdf of the invoices has changed. Borders would be present in the body of the invoice and the total detail.

Came back to v15 display by using the table-borderless class on those elements.

closes odoo/odoo#107257

X-original-commit: 1a46b6f9231c5d49d70bfa9eb8d434c1f092c1c7
Signed-off-by: Laurent Smet <las@odoo.com>
Signed-off-by: Camille Spiritus (casp) <casp@odoo.com>
2022-12-06 09:26:08 +01:00
maximilien(malb) d151158637 [IMP] account, account_asset: account move views with assets
This PR add a new page "Accounting Documents" with the journal entry, the list view asset_id and the statement_line_id. This make the first page more concise and allow the related asset to be more visible and simple to work with.

closes odoo/odoo#107205

Task-id: 3075466
Related: odoo/enterprise#34642
Signed-off-by: John Laterre (jol) <jol@odoo.com>
2022-12-05 14:04:08 +01:00
william-andre 13f98fc7c0 [REV] account: fix the report invoice template
This reverts 0e958ccd85

Using the id instead of the previous xpath makes it less natural.
It was also conflicting with `l10n_au` which was replacing that part
with something else, removing the id.

closes odoo/odoo#107186

Related: odoo/enterprise#34635
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2022-12-04 14:32:15 +01:00
Nicolas (vin) 0e958ccd85 [FIX] l10n_pe: fix the report invoice template
At the moment, a wrong xpath is causing the l10n_pe
modules installation to fail.
Correct it and ensure that it works.

See https://github.com/odoo/enterprise/pull/34464

closes odoo/odoo#107096

Related: odoo/enterprise#34603
Signed-off-by: William André (wan) <wan@odoo.com>
2022-12-02 15:34:48 +01:00
Jorge Pinna PuissantandMichael Mattiello (mcm) c7c2959449 [IMP] web, *: simplification and standardization of the settings arch
The aim of this commit is to simplify and standardize the settings archs.

To do this, a small DSL exclusively for the settings was created. This
new DSL introduces 3 tags: `app`, `block` and `setting`.

The `app` tag is used to declare the application on the settings view.
It creates an entry with its logo on the sidebar of the view. It also
acts as delimiter when searching.

```xml
    <app string="CRM" name="crm">
    ...
    </app>
```

- `string` : The "display" name of the application.
- `name` : The technical name of the application (the name of the module).
- `logo` *optional* : The relative path to the logo. If not set, the
        logo is created using the `name` parameter :
        `/{name}/static/description/icon.png`.

The `block` tag is used to declare a group of settings. This group can
have a title and a description/help.

```xml
    <block title="Title of group Bar">
    ...
    </block>
```

- `title` *optional* : The title of the block of settings (the old h2),
        you can perform research on its text.
- `help` *optional* : The description/help of the block of settings
        (the old h3), you can perform research on its text.

The `setting` tag is used to declare the setting itself. The first field
in the setting is used as the main field (optional). This field is
placed on the left panel (if it's a boolean field) or on the top of the
right panel (otherwise). The field is also used to create the setting
label if a `string` is not defined. The `setting` tag can also contain
more elements (e.g. html), all of these elements are rendered in the
right panel.

```xml
    <setting string="this is bar">
        <field name="bar"/>
        ...More elements
    </setting>
```

- `type` *optional* : By default, a setting is visually separated on two
        panels (left and right), and is used to edit a given field. By
        defining `type='header'`, a special kind of setting is rendered
        instead. This setting is used to modify the scope of the other
        settings. For example, on the website application, this setting
        is used to indicate to which website the other settings apply.
        The header setting is visually represented as a yellow banner on
        the top of the screen.
- `string` *optional* : The text used as label of the setting. If it's
        not defined, the first field is used as label.
- `title` *optional* : The text used as tooltip.
- `help` *optional* : The help/description of the setting. This text is
        displayed just below the setting label (with classname
        `text-muted`).
- `company_dependent` *optional* : If this attribute is set to "1" an
        icon is displayed next to the setting label to explicit that
        this setting is company-specific.
- `documentation` *optional* :  If this attribute is set, an icon is
        added next to the setting label, this icon is a link to the
        documentation. Note that you can use relative or absolute path.
        The relative path is relative to
        `https://www.odoo.com/documentation/server_version`, so it's not
        necessary to hard-code the server version on the arch anymore.

closes odoo/odoo#106425

Task-id: 3081367
Related: odoo/enterprise#34337
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Co-authored-by: "Michael Mattiello (mcm)" <mcm@odoo.com>
2022-12-02 14:40:25 +01:00
maximilien(malb) e660b4db6d [IMP] accounting: invoice view modifications
Following some user brain tests analysis, the following small modifications have been implemented to improve the usability of the app.

* Delete the quick create option of the payment terms
* Change the name of the payment column in the invoice menu
* Removing the tags of the payment column when the state is different of posted
* When only one currency is activated the currency symbol wasn't displayed anymore cause of recent change on the js side with "group", by adding the field currency_id invisible in the arch the problem is solved

closes odoo/odoo#106903

Task-id: 3085423
Related: odoo/enterprise#34558
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
2022-12-02 11:37:59 +01:00
Dylan Kiss (dyki) 3f38d903e9 [FIX] account,l10n_{au,in,gcc_invoice}: distinguish credit note titles
Currently we distinguish customer invoice titles based on the state they are in: draft, posted or cancelled.
For the customer credit notes we did not have this dinstinction.

This fix makes sure that the title of a credit note is also adapted based on its state.

[task-3067251](https://www.odoo.com/web#id=3067251&cids=1&menu_id=4720&action=4043&model=project.task&view_type=form)

closes odoo/odoo#106692

Related: odoo/enterprise#34464
Signed-off-by: John Laterre (jol) <jol@odoo.com>
2022-11-29 16:19:46 +01:00
Antoine Dupuis (andu) d76e3bb82e [IMP] account: Change 'Miscellaneous' menu to 'Journals'
In Odoo 16, we redesigned the `Accounting > Miscellaneous` menu to
provide a convenient interface for inspecting any journal entry or
journal item.

As such, it no longer makes sense to call it 'Miscellaneous'.

This commit aligns the name with the new functionality.

We also remove the default filter of the 'Journal Entries' view, which
restricted it to miscellaneous entries, and replace it with a filter
on posted entries, consistent with the purpose of conveniently
inspecting the accounting journals.

closes odoo/odoo#106749

Task: 3083921
X-original-commit: ee551d74557b889a463bd7dff234ff5f12539e4a
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2022-11-28 20:50:25 +01:00
Shawcker a3e9c525f5 [FIX] account: qr_code_urls bug in report invoice template
To reproduce:

1) activate qr code on invoices
2) print an invoice with a qr code
3) print a followup letter, and attach the printed invoice

-> error due to missing 'qr_code_urls' variable in invoice template

This can happen with any report calling this template, thus we decided to set the qr_code_urls
inside the `report_invoice_document` template directly, so we never need to set it again in _get_report_values()
This allows to remove the following report classes (done in master due to stable policy)
- `ReportInvoiceWithoutPayment`
- `ReportInvoiceWithPayment`
- `PosInvoiceReport` (not even used anywhere)

closes odoo/odoo#106605

X-original-commit: a87460bdb82b7b2ab88f397f3506d0f380d86cfd
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2022-11-25 19:51:57 +01:00
smdc-odoo 163933c590 [FIX] account: Simplify the bank statement synchronisation on dashboard
When the bank journal is set to automated online synchronization, we
also want to be able to configure it when no online bank is set.

task-3043449

closes odoo/odoo#106189

Related: odoo/enterprise#34208
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
2022-11-25 17:56:05 +01:00
maximilien(malb) a24e3de28c [FIX] account: coa kanban bug
Before this PR, going to the coa in kanban view was broken with an infinite white screen. The error was that the template tried to display the account type and without the .value is resulted in an owl error.
It's now corrected, we can now access the kanban view of the COA.

I also changed a bit the size of column so that the name of the account stay a maximum in one line

closes odoo/odoo#106391

Signed-off-by: Josse Colpaert <jco@odoo.com>
2022-11-24 13:28:57 +01:00
Claire Bretton (clbr) a963ea8a02 [FIX] account: fix dashboard graphs alignment
Graphs were not aligned depending on data. They will now stick to bottom of the card and fill consistently the space above.

closes odoo/odoo#106276

Task: 3071124
X-original-commit: f39904cbe8db3a4788b6771e2f4591d94dd38363
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
2022-11-23 07:22:42 +01:00
Hubert Van de Walle (huvw) 7562ff4915 [FIX] account,sale_management: Uom should not be displayed when disabled
Steps to reproduce
==================

- Use a mobile phone / mobile view in devtools
- Go to Accounting > Customer invoices
- Click on one item
-> A traceback occurs, the uom is missing

Cause of the issue
==================

The field is declared as
  `<field name="product_uom" groups="uom.group_uom"/>`

The raw value is accessed with
  `<t t-esc="record.product_uom.value"/>`

Solution
========

Add the missing group

opw-3070671

closes odoo/odoo#106066

X-original-commit: 6563e7b077ade8da333b710578a23ee8ac23a025
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
2022-11-18 17:03:59 +01:00
aliya 1d1b7c3c60 [IMP] account: remove is_off_balance
We don't need `is_off_balance` field on `account.account` as the same thing can be checked with `account_type`.

closes odoo/odoo#105131

Related: odoo/enterprise#33693
Related: odoo/upgrade#4013
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2022-11-17 13:57:11 +01:00
Habib (ayh) 0eeee27a82 [FIX] account: view arch should not contain owl directives
The Accounting Journal Dashboard Kanban view contains direct owl components and directives. This should not be the case as it may cause problems with studio.

This commit replaces the direct owl with
1. a view widget for the file uploader buttons.
2. the kanban record template is extended to add the dropzone and file uploader with context

Task-3040946

closes odoo/odoo#105575

X-original-commit: 5de857d56c5f4cff318ed6b6c7dd15bf426e6a18
Related: odoo/enterprise#33877
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Ayob Habib (ayh) <ayh@odoo.com>
2022-11-10 22:22:07 +01:00
niyasraphy 1709cba800 [FIX] sale,purchase,stock,account: partner form warning alignment
closes odoo/odoo#105511

X-original-commit: 6aa86c92c7ee7d46c54250960c2b34753e13b8be
Signed-off-by: William André (wan) <wan@odoo.com>
2022-11-10 00:27:59 +01:00
maximilien(malb) 246666fe7d [FIX] account: Account group search bar
The search bar had a trace back when searching on a name, and searching on the code prefix did not work.

This was not working because using str(self) does not work in v16, str is not defined in filter domain.

By removing the str and adapting the filter domain logic, it now works as it should. And the behavior of version 15 is restored

closes odoo/odoo#105381

Task-id: 3058778
X-original-commit: 9173e4da3912f8e46f163cc0d38a4a037b591c60
Signed-off-by: John Laterre (jol) <jol@odoo.com>
Signed-off-by: Maximilien La Barre (malb) <malb@odoo.com>
2022-11-09 14:00:33 +01:00
oco-odoo db0672fa49 [FIX] account: forbid quick create on tax tags on account.move's form
Those tags should only be created by the tax reports; creating them manually makes no sense.

closes odoo/odoo#105227

X-original-commit: 116c8090da9d900c04c9257269b42c462ec77f98
Signed-off-by: Laurent Smet <las@odoo.com>
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
2022-11-08 11:39:56 +01:00
Ricardo Gomes Rodrigues (rigr) 6a10ad1c3c [FIX] account: highest number warning display
Before this commit, the highest number warning was displayed on multiple lines.

This commit fixes this by inlining the name of the invoice with the highest number.

closes odoo/odoo#105194

X-original-commit: 9938389734110474a6356654a01990d774a832b8
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
Signed-off-by: Ricardo Gomes Rodrigues (rigr) <rigr@odoo.com>
2022-11-07 17:59:48 +01:00
Camille Spiritus 6757ac3f7c [FIX] account: reintroduce transfer_account_id in config view
During the Early Payment Discount task, the transfer_account_id field was mistakenly removed from res_config_settings_views.xml.

Reintroducing it as intended.

closes odoo/odoo#105146

X-original-commit: 86b73a7b1696d13330cbee063424d989b585fe5c
Signed-off-by: Laurent Smet <las@odoo.com>
2022-11-07 14:52:48 +01:00
niyasraphy 22a2847aec [FIX] account: invoice report duplicated values
closes odoo/odoo#104871

X-original-commit: 56d00814fed92782dca9425c4471382d26004198
Signed-off-by: Camille Spiritus (casp) <casp@odoo.com>
2022-11-04 09:52:57 +01:00
aliya 65b4e0b332 [FIX] account: fix account journal form
Bank statements import-specific fields are now displayed above the form because of the invisible bank_statements_source. Adding a group name on the form allows better inheriting.

task-3046427

closes odoo/odoo#104709

X-original-commit: 684567c4dc56c2379ba19cebec96e582287b37d1
Related: odoo/enterprise#33492
Signed-off-by: John Laterre (jol) <jol@odoo.com>
Signed-off-by: Aliya Tastemirova (alta) <alta@odoo.com>
2022-11-02 13:36:08 +01:00
PoMa d57c55c173 [IMP] account: UX improvements
Remove quick create from the places that is either not needed or not possible
Task #2850996

closes odoo/odoo#104640

X-original-commit: ae0a11a8ce3c35542ba5ae8f6366018b88ec40d5
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
Signed-off-by: Pouya Malekinejad (poma) <poma@odoo.com>
2022-11-02 10:40:24 +01:00
Laurent Smet 154622af07 [FIX] account: Fix groups in account.move form
When having only invoicing but being in multi-currency, the journal is not visible but "in USD" is displayed.

X-original-commit: e813b559121792f03f555b1126f5627570913b96
Part-of: odoo/odoo#104389
2022-10-28 08:22:56 +02:00
Pierrot (prro) e2fe60e717 [IMP] account: update Jitems partner edit condition
The condition for multi-editing the partner has now changed.
The partner cannot be changed on a line that has parts in a
(partial) reconciliation.

closes odoo/odoo#104258

X-original-commit: 1b30777ab63998d1c0b64b655e717d74b3648bcf
Signed-off-by: William André (wan) <wan@odoo.com>
2022-10-27 11:38:55 +02:00
Julien Alardot (jual) e76c76169b [IMP] {account_*, l10n_*}: t-esc to t-out
Due to the deprecation of t-esc to the unique use
of t-out in the rendering template, this replace
every usage of it and ensures everything continues to
work as inteded. Removing deprecation warnings
polluting terminal

deprecation commit: odoo/odoo:9ce5bc8881ae06b613ef61eb07453b224f62bae6

closes odoo/odoo#103731

Related: odoo/enterprise#33037
Signed-off-by: William André (wan) <wan@odoo.com>
2022-10-25 18:44:57 +02:00
maximilien(malb) 9d24f5f481 [FIX] account: payment term visual improvement
The payment terms view needed a bit a change so this PR change a few things:

* Make the title of the payment terms bigger like the other view in odoo
* Group the company, note and display on invoice so that they are aligned
* removing the section Terms and the span

This PR also change the display of payment terms on invoice when printing or previewing them. Now :
* If there is one line (no cash discount) it's not displayed
* If there is one lone with cash discount) it's displayed
* If more than one line then displayed
Before this PR it was presented with a table but now the line are displayed like a list.

closes odoo/odoo#103778

Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2022-10-24 14:12:14 +02:00
maximilien(malb) 5f00654491 [FIX] account: reconcile model display improvement
Most of the dropdown of the account reconcile model view were weirdly displayed, the case was too small for the text, by removing the class oe_inline most of the dropdown were fixed, and for the other just a slight modification on the width did the job.

Also on the left column the two first line were not aligned with the rest, same for the right column on the first line, now it's fixed but I had to put the invisible in the field

Other thing, the counterpart entries were too much on the left of the page due to a useless group, it's now removed

Also change some display name and added the translation

closes odoo/odoo#103682

Task-id: 3000402
X-original-commit: 487cc0959991d804a48f44b914540786a85f180f
Signed-off-by: Laurent Smet <las@odoo.com>
Signed-off-by: Maximilien La Barre (malb) <malb@odoo.com>
2022-10-21 14:06:16 +02:00
Mountain Tran beeb1143d0 [IMP] account: Consistent in terms of UX
In Product Category, income/expense Account only select accounts with Internal Group is income/expense.
But in Product, income/expense Account don't have that domain (although the domain above is not wrong).
=> This in my opinion causes confusion for users when using
The way to handle it, I will remove the domain part in the income/expense account to match the experience

closes odoo/odoo#103588

X-original-commit: f736f50548438cf144c7882651043fbccad72c98
Signed-off-by: Laurent Smet <las@odoo.com>
2022-10-20 12:19:28 +02:00
Nicolas (vin) 418a0c734d [FIX] account: fix the label for due date
The label for due date was targeting invoice_payment_term_id
instead of due date, thus not profiting from the readonly rules
and being muted when it should not.

closes odoo/odoo#103344

X-original-commit: 9da25683e918838609ffdac87c979f883d11d027
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
Signed-off-by: Nicolas Viseur <vin@odoo.com>
2022-10-20 08:23:49 +02:00
Lucas Perais f489eb9226 [FIX] account: adapt account_move form arch to form view grid
Before this commit, when creating a new account move, there were spaces at the
beginning of both left and right form inner groups. This was due to the new form grid
in which each element declared as child of the inner group will be a cell.

After this commit, the account move form view is correct.

closes odoo/odoo#103396

X-original-commit: d3fee87e5bb1966e32e366a8b1bf480601b5d76c
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2022-10-18 14:15:10 +02:00
maximilien(malb) 0c3bde91dd [FIX] account: fix label on account tax
The label for the two list views was displayed behind them, the margin  bottom allows to put the list view below.

closes odoo/odoo#103394

X-original-commit: 41d97d8ffaba938555f90cbf2f9ffc2de1881e10
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
Signed-off-by: Maximilien La Barre (malb) <malb@odoo.com>
2022-10-18 14:15:05 +02:00
maximilien(malb) 8f7565601c [FIX] account: top button display fix
Multiple button had weird display where the number was not aligned with the text, and the spacing between the number and the text was missing

closes odoo/odoo#103336

X-original-commit: 92e923c8ef4419206dd78a61720a0df5c98b8f59
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
Signed-off-by: Maximilien La Barre (malb) <malb@odoo.com>
2022-10-18 11:21:10 +02:00
gawa-odoo b8dca3b174 [IMP] analytic, *: Json field for analytic distribution
The `analytic_distribution` field is a Json.
It was stored temporarily as a char.

Search is not available yet, so we do queries by hand when we need to search on keys.

Also added a constraint on account_analytic_distribution_model,
so we don't have models with accounts specific to a company when the model has no company or another company.
It would cause an issue when looking at the models from another company.

X-original-commit: 7064c95aa04e5138bb12ae97acfee04ebb67cc0e
Part-of: odoo/odoo#103097
2022-10-17 10:11:09 +02:00
william-andre ae2fcda9e8 [FIX] account: quick encoding
The computation of the taxes in the context of quick encoding wasn't
working properly.
* The value was not updated in the widget when it was updated
  programatically.
* The payment terms were created twice because of the `new` method on
  account.move.line
* The taxes should be updated both when we create a new line manually
  and when we update the quick encoding fields
* Generally speaking, it should be all controlled from the invoice, not
  from the lines

To test and reproduce: use a tax of 21% with an invoice line of 100.0

X-original-commit: 48c068a2d76c302fdddda7125b7244c670b4a77c
Part-of: odoo/odoo#103081
2022-10-11 17:59:43 +02:00
Habib (ayh) 9042101413 [IMP] account: analytic distribution validation
Analytic distributions that contain mandatory plans should be blocked from posting.
However, automatic flows (for example subscription invoices) should not be blocked.
For this reason, the context is used to determine whether the distribution should be validated.

closes odoo/odoo#102720

X-original-commit: 7b11af76598c0782ac2097d3cbeb718962be2537
Signed-off-by: William André (wan) <wan@odoo.com>
2022-10-11 13:15:20 +02:00
Damien Bouvy e647a2de09 [IMP] *: adapt to grid form views
The recent switch from tables to css grids for form views `group` nodes
has introduced several inconsistencies/issues with several views accross
modules - these will not be the last fixes.

closes odoo/odoo#102174

X-original-commit: 836568dfd59886a6d52f15e0e2109709903b6803
Related: odoo/enterprise#32295
Signed-off-by: Bouvy Damien (dbo) <dbo@odoo.com>
2022-10-11 13:15:12 +02:00
gawa-odoo ba4b71427f [IMP] analytic,*: changes on applicability and make fields visible
Add choices for the business domain on applicability rules, so rules are more precise
Also put 'general' as domain from the view when it's what should have been.
Make analytic field visible since owl migration (for sale and purchase)

closes odoo/odoo#102461

X-original-commit: c5867d5009a7fb448fff1be487b9e9c3e7945d4b
Related: odoo/enterprise#32421
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Wala Gauthier (gawa) <gawa@odoo.com>
2022-10-10 14:04:43 +02:00
Laurent Smet bf97e2d172 [IMP] account: Remove 'cumulated_balance' from aml tree view for performances
closes odoo/odoo#102733

X-original-commit: 652292a4788f6aca978ed97682577024ba53d7d0
Related: odoo/enterprise#32550
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
Signed-off-by: Laurent Smet <las@odoo.com>
2022-10-10 09:48:21 +02:00
Nicolas (vin) 94beb218ea [FIX] account: do not allow to create a country in the settings
The fiscal country field could be used to create a new res country or
open the form view and allow to change things such as the country code.
This is obviously an issue and shouldn't be allowed.

closes odoo/odoo#102708

X-original-commit: 0881199fba43e01d6d7613eff00549eac5827480
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
Signed-off-by: Nicolas Viseur <vin@odoo.com>
2022-10-09 16:34:42 +02:00