How to add the same job position in some contacts using server action.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Comptabilité
- Inventaire
- PoS
- Projet
- MRP
Cette question a été signalée
Hi Jordan,
Find the IDs of contacts for whom you need to change the job position and update the target_partner_ids list.
target_partner_ids = [1869,1870,1871]
partner_ids = env['res.partner'].search([('id', 'in', target_partner_ids)])
for partner in partner_ids :
partner.write({
'function':'Sales'
})
Or
Create a server action, select 'Contacts' as the model, update the Python code, and click on 'Create Contextual Action
Go to Contacts, select the contacts you want to change, click on 'Action,' and select the server action created.

Hope it helps,
Kiran K
Hi,
1. Create a new server action.

2. Select the contacts and click the 'Consultant job position' button

Please refer to this blog :https://www.cybrosys.com/blog/how-to-create-configure-server-actions-in-the-odoo-15
Hope it helps
Vous appréciez la discussion ? Ne vous contentez pas de lire, rejoignez-nous !
Créez un compte dès aujourd'hui pour profiter de fonctionnalités exclusives et échanger avec notre formidable communauté !
S'inscrire