mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-05 21:54:02 +00:00
runForMultiple can scope pending tenants
This commit is contained in:
parent
b73d047a39
commit
0a37eb487a
9 changed files with 47 additions and 11 deletions
|
|
@ -13,6 +13,7 @@ trait HasATenantsOption
|
|||
{
|
||||
return array_merge([
|
||||
['tenants', null, InputOption::VALUE_IS_ARRAY | InputOption::VALUE_OPTIONAL, '', null],
|
||||
['with-pending', null, InputOption::VALUE_NONE, 'include pending tenants in query', null],
|
||||
], parent::getOptions());
|
||||
}
|
||||
|
||||
|
|
@ -26,6 +27,11 @@ trait HasATenantsOption
|
|||
->cursor();
|
||||
}
|
||||
|
||||
protected function withPending(): bool
|
||||
{
|
||||
return $this->option('with-pending');
|
||||
}
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue