forked from doctrine-extensions/DoctrineExtensions
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request doctrine-extensions#1791 from JCID/patch-1
[Loggable] Allow for Embedded documents to also have child documents
- Loading branch information
Showing
4 changed files
with
90 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
<?php | ||
|
||
namespace Loggable\Fixture\Entity; | ||
|
||
use Doctrine\ORM\Mapping as ORM; | ||
use Gedmo\Mapping\Annotation as Gedmo; | ||
|
||
/** | ||
* Class GeoLocation | ||
* @package Loggable\Fixture | ||
* @author Fabian Sabau <[email protected]> | ||
* | ||
* @ORM\Embeddable() | ||
*/ | ||
class GeoLocation | ||
{ | ||
/** | ||
* @var string $latitude | ||
* @ORM\Column(type="string") | ||
* @Gedmo\Versioned() | ||
*/ | ||
protected $location; | ||
|
||
/** | ||
* Geo constructor. | ||
* @param string $location | ||
*/ | ||
public function __construct($location) | ||
{ | ||
$this->location = $location; | ||
} | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getLocation() | ||
{ | ||
return $this->location; | ||
} | ||
|
||
/** | ||
* @param string $location | ||
*/ | ||
public function setLocation($location) | ||
{ | ||
$this->location = $location; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters