How to make the assignment fields (user and team);
2- filled in automatically, depending on the logged in user?
- User 1 is connected
- User 1 belongs to Team A
when creating a contract the following fields must be filled:
- Assigned *: User 1
- Team *: A
Infos: SuiteCRM 7.1.5
Field level functionality cannot be achieved with the out of the box security suite that comes with SuiteCRM.
You would need to develop custom functionality.
Starting with the first part of the problem:
How to make the selection of the user and the team required when entering?
In order to make ‘assigned_to’ required you need to create a new manifest file under /www/custom/Extension/modules/your_module_name/Ext/Vardefs/sugarfield_assigned_to.php
Then make a quick repair and it’s done
Sorry dpccrt87, I was wrong in the code, this is the correct one
I put my module name, forgot to remove it, now it should work with your module name
it’s good, it works, thank you very much,
But now, I would like to know how to capture departement, and binding suppliers??
For that you need to go to /var/www/custom/Extension/modules/your_module/Ext/Vardefs
and Edit the relationshipt that corresponds to the fields you want to make required and then you need to add ‘required’ => true, in the name relation like this example
$dictionary["your_module"]["fields"]["accounts_your_module_name"] = array (
'name' => 'accounts_your_module_name',
'type' => 'relate',
'required' => true,
'source' => 'non-db',
'vname' => 'LBL_ACCOUNTS_YOUR_MODULE_FROM_ACCOUNTS_TITLE',
'save' => true,
'id_name' => 'accounts_your_module_IDA',
'link' => 'accounts_your_module',
'table' => 'accounts',
'module' => 'Accounts',
'rname' => 'name',
Always run quick repair after