Skip to content

Commit

Permalink
[AB#38683] added entity map to instance.
Browse files Browse the repository at this point in the history
  • Loading branch information
filipcieslikans committed Jan 22, 2025
1 parent 848fc48 commit ff52640
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 13 deletions.
14 changes: 11 additions & 3 deletions src/eCloud/Entities/InstanceSoftware.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,16 @@
*/
class InstanceSoftware extends Entity
{
/**
* @var array
*/
protected $dates = ['createdAt', 'updatedAt'];

public static $entityMap = [
'id' => 'id',
'name' => 'name',
'instance_id' => 'instanceId',
'software_id' => 'softwareId',
'sync' => 'sync',
'task' => 'task',
'created_at' => 'createdAt',
'updated_at' => 'updatedAt',
];
}
11 changes: 1 addition & 10 deletions src/eCloud/InstanceSoftwareClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,7 @@ class InstanceSoftwareClient extends Client implements ClientEntityInterface

public function getEntityMap()
{
return [
'id' => 'id',
'name' => 'name',
'instance_id' => 'instanceId',
'software_id' => 'softwareId',
'sync' => 'sync',
'task' => 'task',
'created_at' => 'createdAt',
'updated_at' => 'updatedAt',
];
return InstanceSoftware::$entityMap;
}

public function loadEntity($data)
Expand Down

0 comments on commit ff52640

Please sign in to comment.