get campaign id and timestamp of existing projects
This commit is contained in:
parent
350bb513a0
commit
0ce48fa58b
1 changed files with 9 additions and 0 deletions
|
@ -163,6 +163,15 @@ class TwingleProject {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($result['count'] == 1) {
|
if ($result['count'] == 1) {
|
||||||
|
|
||||||
|
// get campaign id
|
||||||
|
$this->id = $result['values'][0]['id'];
|
||||||
|
|
||||||
|
// set object timestamp to project last_update
|
||||||
|
$date = $result['values'][0][$cf_last_update];
|
||||||
|
$date = DateTime::createFromFormat('Y-m-d H:i:s', $date);
|
||||||
|
$this->timestamp = $date->getTimestamp();
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue