Hi Yuri,
is just a Idea about new ehancement in V9, i think "Collaborators + AssignedUsers"..
Of course, i have not see the V9, so i can be false
Maybe make out-of box "Select Filter" like :
OnlyAsCollaborators
For me it's not complicate to make a custom select.. like (sample can help other) :
Maybe if you think is relevant.
Thanks ... i was waiting with the V9
is just a Idea about new ehancement in V9, i think "Collaborators + AssignedUsers"..
Of course, i have not see the V9, so i can be false
Maybe make out-of box "Select Filter" like :
OnlyAsCollaborators
For me it's not complicate to make a custom select.. like (sample can help other) :
PHP Code:
namespace Espo\Custom\Classes\Select\Meeting\BoolFilters;
use Espo\Core\Select\Bool\Filter;
use Espo\ORM\Query\SelectBuilder;
use Espo\ORM\Query\Part\Where\OrGroupBuilder;
use Espo\ORM\Query\Part\Condition as Cond;
use Espo\Entities\User;
class AsAttendee implements Filter
{
public function __construct(
private User $user
){}
public function apply(SelectBuilder $queryBuilder, OrGroupBuilder $orGroupBuilder): void
{
$queryBuilder
->leftJoin('users', 'asAttendee');
$orGroupBuilder
->add(
Cond::and(
Cond::equal(
Cond::column('asAttendeeMiddle.userId'),
$this->user->getId()
)
)
);
}
}
Thanks ... i was waiting with the V9
Comment