add project title to result array and change "update" to "fetched"
later it might become handy to distinguish the update direction (from Twingle to CiviCRM or to Twingle from CiciCRM )
This commit is contained in:
parent
ef2cb029f6
commit
cbca983d8b
1 changed files with 3 additions and 1 deletions
|
@ -84,6 +84,7 @@ class TwingleProject {
|
||||||
$this->id = $result['id'];
|
$this->id = $result['id'];
|
||||||
$this->timestamp = $result['last_update'];
|
$this->timestamp = $result['last_update'];
|
||||||
return [
|
return [
|
||||||
|
'title' => $this->values['title'],
|
||||||
'id' => $this->id,
|
'id' => $this->id,
|
||||||
'project_id' => $this->values['id'],
|
'project_id' => $this->values['id'],
|
||||||
'state' => 'created',
|
'state' => 'created',
|
||||||
|
@ -91,6 +92,7 @@ class TwingleProject {
|
||||||
}
|
}
|
||||||
// Give information back if project already exists
|
// Give information back if project already exists
|
||||||
return [
|
return [
|
||||||
|
'title' => $this->values['title'],
|
||||||
'id' => is_array($this->id) ? implode(', ', $this->id) : $this->id,
|
'id' => is_array($this->id) ? implode(', ', $this->id) : $this->id,
|
||||||
'project_id' => $this->values['id'],
|
'project_id' => $this->values['id'],
|
||||||
'state' => 'exists',
|
'state' => 'exists',
|
||||||
|
@ -112,7 +114,7 @@ class TwingleProject {
|
||||||
'title' => $this->values['title'],
|
'title' => $this->values['title'],
|
||||||
'id' => $this->id,
|
'id' => $this->id,
|
||||||
'project_id' => $this->values['id'],
|
'project_id' => $this->values['id'],
|
||||||
'state' => 'updated',
|
'state' => 'fetched',
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue