code formatting and smaller errors
This commit is contained in:
parent
a81eb0c438
commit
937a35e1b8
6 changed files with 15 additions and 19 deletions
|
@ -137,7 +137,7 @@ class CampaignType {
|
|||
);
|
||||
|
||||
if ($this->results['is_error'] == 0) {
|
||||
\Civi::log()->info("Twingle Extension has deleted campaign type.\n
|
||||
\Civi::log()->info("TwingleCampaign Extension has deleted campaign type.\n
|
||||
label: $this->label\n
|
||||
name: $this->name"
|
||||
);
|
||||
|
@ -148,12 +148,12 @@ class CampaignType {
|
|||
}
|
||||
else {
|
||||
if ($this->label) {
|
||||
\Civi::log()->error("Twingle Extension could not delete campaign type
|
||||
\Civi::log()->error("TwingleCampaign Extension could not delete campaign type
|
||||
\"$this->label\": $this->results['error_message']"
|
||||
);
|
||||
}
|
||||
else {
|
||||
\Civi::log()->error("Twingle Extension could not delete campaign type:
|
||||
\Civi::log()->error("TwingleCampaign Extension could not delete campaign type:
|
||||
$this->results['error_message']");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -235,13 +235,13 @@ class CustomField {
|
|||
else {
|
||||
if ($this->label && $this->custom_group_id) {
|
||||
\Civi::log()
|
||||
->error("Twingle Extension could not delete custom field
|
||||
->error("TwingleCampaign Extension could not delete custom field
|
||||
\"$this->label\" for group \"$this->custom_group_id\":
|
||||
$this->result['error_message']");
|
||||
}
|
||||
else {
|
||||
\Civi::log()
|
||||
->error("Twingle Extension could not delete custom field:
|
||||
->error("TwingleCampaign Extension could not delete custom field:
|
||||
$this->result['error_message']");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -49,7 +49,7 @@ class CustomGroup {
|
|||
$this->id = $this->results['id'];
|
||||
|
||||
if ($this->results['is_error'] == 0) {
|
||||
\Civi::log()->info("Twingle Extension has created a new custom group.
|
||||
\Civi::log()->info("TwingleCampaign Extension has created a new custom group.
|
||||
title: $this->title
|
||||
name: $this->name
|
||||
extends: $this->extends
|
||||
|
@ -59,12 +59,12 @@ class CustomGroup {
|
|||
}
|
||||
else {
|
||||
if ($this->title) {
|
||||
\Civi::log()->error("Twingle Extension could not create new custom group
|
||||
\Civi::log()->error("TwingleCampaign Extension could not create new custom group
|
||||
for \"$this->title\": $this->results['error_message']"
|
||||
);
|
||||
}
|
||||
else {
|
||||
\Civi::log()->error("Twingle Extension could not create new
|
||||
\Civi::log()->error("TwingleCampaign Extension could not create new
|
||||
custom group: $this->results['error_message']");
|
||||
}
|
||||
}
|
||||
|
@ -134,7 +134,7 @@ class CustomGroup {
|
|||
);
|
||||
|
||||
if ($this->results['is_error'] == 0) {
|
||||
\Civi::log()->info("Twingle Extension has deleted custom group.
|
||||
\Civi::log()->info("TwingleCampaign Extension has deleted custom group.
|
||||
title: $this->title
|
||||
name: $this->name
|
||||
extends: $this->extends
|
||||
|
@ -147,12 +147,12 @@ class CustomGroup {
|
|||
}
|
||||
else {
|
||||
if ($this->title) {
|
||||
\Civi::log()->error("Twingle Extension could not delete custom group
|
||||
\Civi::log()->error("TwingleCampaign Extension could not delete custom group
|
||||
\"$this->title\": $this->results['error_message']"
|
||||
);
|
||||
}
|
||||
else {
|
||||
\Civi::log()->error("Twingle Extension could not delete custom group:
|
||||
\Civi::log()->error("TwingleCampaign Extension could not delete custom group:
|
||||
$this->results['error_message']");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ class TwingleEvent extends Campaign {
|
|||
|
||||
$this->className = (new \ReflectionClass($this))->getShortName();
|
||||
$this->prefix = 'twingle_event_';
|
||||
|
||||
$this->values['campaign_type_id'] = 'twingle_event';
|
||||
// Add value for campaign type
|
||||
$event['campaign_type_id'] = 'twingle_event';
|
||||
|
||||
|
@ -53,7 +53,7 @@ class TwingleEvent extends Campaign {
|
|||
* If TRUE, don't do any changes
|
||||
*
|
||||
* @return array|null
|
||||
* Returns a response array that contains title, id, event_id, project_
|
||||
* Returns a response array that contains title, id, event_id, project_id
|
||||
* and status or NULL if $values is not an array
|
||||
*
|
||||
* @throws CiviCRM_API3_Exception
|
||||
|
|
|
@ -33,11 +33,7 @@ class TwingleProject extends Campaign {
|
|||
|
||||
$this->className = (new \ReflectionClass($this))->getShortName();
|
||||
$this->prefix = 'twingle_project_';
|
||||
|
||||
// Add value for campaign type
|
||||
$this->values['campaign_type_id'] = 'twingle_project';
|
||||
|
||||
// Get custom field name for project_id
|
||||
$this->id_custom_field = Cache::getInstance()
|
||||
->getCustomFieldMapping()['twingle_project_id'];
|
||||
|
||||
|
|
|
@ -323,7 +323,7 @@
|
|||
"data_type": "String",
|
||||
"html_type": "Text",
|
||||
"text_length": 128,
|
||||
"is_active": 0,
|
||||
"is_active": 1,
|
||||
"is_view": 1,
|
||||
"weight": 6
|
||||
},
|
||||
|
@ -336,7 +336,7 @@
|
|||
"data_type": "String",
|
||||
"html_type": "Text",
|
||||
"text_length": 10,
|
||||
"is_active": 0,
|
||||
"is_active": 1,
|
||||
"is_view": 1,
|
||||
"weight": 6
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue