mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-05 13:14:05 +00:00
Enhance Syncable and SyncMaster Interfaces to Support Customizable Attribute Synchronization
This commit is contained in:
parent
8f9c7efa45
commit
846776892a
5 changed files with 35 additions and 13 deletions
|
|
@ -603,6 +603,11 @@ class CentralUser extends Model implements SyncMaster
|
|||
return ResourceUser::class;
|
||||
}
|
||||
|
||||
public function getTenantModelFillable(): array
|
||||
{
|
||||
return (new ResourceUser)->getFillable();
|
||||
}
|
||||
|
||||
public function getGlobalIdentifierKey()
|
||||
{
|
||||
return $this->getAttribute($this->getGlobalIdentifierKeyName());
|
||||
|
|
@ -651,6 +656,11 @@ class ResourceUser extends Model implements Syncable
|
|||
return CentralUser::class;
|
||||
}
|
||||
|
||||
public function getCentralModelFillable(): array
|
||||
{
|
||||
return (new CentralUser)->getFillable();
|
||||
}
|
||||
|
||||
public function getSyncedAttributeNames(): array
|
||||
{
|
||||
return [
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue