Hi guys, quick question... In the Cases Status field the is a setting called 'Not Actual Options', can any one please tell me what it does?
Many thanks..
Gareth
Many thanks..
Gareth
namespace Espo\Modules\Crm\SelectManagers; class CaseObj extends \Espo\Core\Select\SelectManager { protected function boolFilterOpen(&$result) { return [ 'status!=' => $this->getMetadata()->get(['entityDefs', $this->entityType, 'fields', 'status', 'notActualOptions']) ?? [] ]; } protected function filterOpen(&$result) { $result['whereClause'][] = [ 'status!=' => $this->getMetadata()->get(['entityDefs', $this->entityType, 'fields', 'status', 'notActualOptions']) ?? [] ]; } protected function filterClosed(&$result) { $result['whereClause'][] = [ 'status' => 'Closed' ]; } }
"fields" { .... "status": { "type": "enum", "options": ["New", "Assigned", "Pending", "Closed", "Rejected", "Duplicate"], "default": "New", "style": { "Closed": "success", "Duplicate": "danger", "Rejected": "danger" }, "audited": true, "fieldManagerAdditionalParamList": [ { "name": "notActualOptions", "view": "views/admin/field-manager/fields/not-actual-options" } ], "notActualOptions": ["Closed", "Rejected", "Duplicate"] }, ... }
Comment