One2Many Checkbox Selector | One2many Custom Button | Multi-Select Widget | One2Many Selection | Checkbox Widget | Odoo Selection Widget
by AVERIANS https://www.averians.com$ 40.75
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 242 |
| Technical Name |
ais_one2many_checkbox |
| License | See License tab |
| Website | https://www.averians.com |
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 242 |
| Technical Name |
ais_one2many_checkbox |
| License | See License tab |
| Website | https://www.averians.com |
One2Many Checkbox Selector | One2many Custom Button | Multi-Select Widget | One2Many Selection | Checkbox Widget | Odoo Selection Widget
This module Adds a checkbox selection functionality to One2Many fields with customizable action buttons for bulk operations.
01
Basic Usage.
Add the widget to any One2Many field in your form view to enable checkbox selection.
<field name="child_ids" widget="ais_checkbox_selector"/>
02
Checkbox Selection.
Each row in the One2Many list displays a checkbox. Select individual records or use the header checkbox to select all records at once.
<field name="child_ids" widget="ais_checkbox_selector"/>
03
Custom Action Button.
Configure a custom action button that appears when records are selected. Specify the button label and the Python method to call.
<field name="child_ids"
widget="ais_checkbox_selector"
options="{'action_method': 'process_selected_children', 'action_button_label': 'Process Selected'}"/>
04
Python Implementation.
Access selected record IDs in your Python method using the context:
def process_selected_children(self):
selected_ids = self.env.context.get('active_selections', [])
selected_records = self.env['child.model'].browse(selected_ids)
# Perform your custom logic here
for record in selected_records:
record.write({'processed': True})
return True
Get Help From Us!
One2Many Checkbox Selector | One2many Custom Button | Multi-Select Widget | One2Many Selection | Checkbox Widget | Odoo Selection Widget
- This module Adds a checkbox selection functionality to One2Many fields with customizable action buttons for bulk operations.
Features
- Checkbox column in One2Many list views
- Bulk selection/deselection functionality
- Context-based access to selected record IDs
Usage
Add widget="ais_checkbox_selector" to your One2Many field in XML views:
- <field name="your_one2many_field" widget="ais_checkbox_selector">
- <list>
<field name="name"/>
</list>
</field>
Retrieve selections in Python: active_selections = self.env.context.get('active_selections', [])
Installation
- Copy ais_one2many_checkbox module to addons folder
- Install the module normally like other modules.
Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module