Joseph Caburnay d9fafdd08e [FIX] web: should update group count when deleting records
**Issue:**

- Open a list view and group the records. Notice the count per group.
- BUG: When deleting a record under a group, the count in the group
  is not updated.

**Solution:**

When calling `deleteRecords` in the `DynamicGroupList`, we call
`deleteRecords` on each group's `list`. This "list" can be
`DynamicGroupList` or `DynamicRecordsList`. Regardless which instance
calls the `deleteRecords` method, we should take the number of the
deleted records and subtract it from the group's current count.

If it turned out that the calling object is a `DynamicGroupList`,
we should make sure that it returns the ids of the deleted records
so that the parent group can update its count as well, that's why
we are collecting the deleted record ids.

It's not so easy to follow but we can roughly imagine the structure
this way:

DynamicGroupList
-> DynamicGroupList[]
   -> DynamicRecordsList[]

Deleting items from the inner dynamic records list should result to
update of the parent group list, and eventually, to the update of the
root group list.

X-original-commit: 865c1b37f7986f00b85c9e8135e46cc4b2ac70da
Part-of: odoo/odoo#106317
2022-11-23 13:25:02 +01:00
2022-10-06 14:56:52 +02:00
2022-11-22 19:10:06 +01:00
…
2015-09-08 17:58:38 +02:00

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%