Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
GoGoCarto
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pixel Humain
GoGoCarto
Commits
39b8a228
Unverified
Commit
39b8a228
authored
5 years ago
by
Sebastian Castro
Browse files
Options
Downloads
Patches
Plain Diff
Import add createdAt/updatedAt
parent
c2189701
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/Biopen/GeoDirectoryBundle/Document/Import.php
+36
-0
36 additions, 0 deletions
src/Biopen/GeoDirectoryBundle/Document/Import.php
with
36 additions
and
0 deletions
src/Biopen/GeoDirectoryBundle/Document/Import.php
+
36
−
0
View file @
39b8a228
...
...
@@ -10,6 +10,8 @@ use Biopen\CoreBundle\Document\AbstractFile;
use
Symfony\Component\Validator\Constraints
as
Assert
;
use
Symfony\Component\Validator\Context\ExecutionContextInterface
;
use
Gedmo\Mapping\Annotation
as
Gedmo
;
abstract
class
ImportState
{
const
Started
=
"started"
;
...
...
@@ -135,6 +137,18 @@ class Import extends AbstractFile
*/
private
$lastRefresh
=
null
;
/**
* @MongoDB\Field(type="date")
* @Gedmo\Timestampable(on="create")
*/
private
$createdAt
;
/**
* @MongoDB\Field(type="date")
* @Gedmo\Timestampable(on="update")
*/
private
$updatedAt
;
public
function
__construct
()
{
$this
->
logs
=
new
\Doctrine\Common\Collections\ArrayCollection
();;
...
...
@@ -545,4 +559,26 @@ class Import extends AbstractFile
{
return
$this
->
lastRefresh
;
}
/**
* Set createdAt
*
* @param date $createdAt
* @return $this
*/
public
function
setCreatedAt
(
$createdAt
)
{
$this
->
createdAt
=
$createdAt
;
return
$this
;
}
/**
* Get createdAt
*
* @return date $createdAt
*/
public
function
getCreatedAt
()
{
return
$this
->
createdAt
;
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment