Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH Use class name instead of self #537

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/DataObjects/WorkflowDefinition.php
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ public function incomingTitle()
} elseif (isset($req['Title']) && !empty($req['Title'])) {
$incomingTitle = $req['Title'];
} else {
$incomingTitle = self::$default_workflow_title_base;
$incomingTitle = WorkflowDefinition::$default_workflow_title_base;
}
return $incomingTitle;
}
Expand Down
10 changes: 5 additions & 5 deletions src/DataObjects/WorkflowTransition.php
Original file line number Diff line number Diff line change
Expand Up @@ -282,19 +282,19 @@ public function extendedRequiredFieldsNotSame($data = null)
$check = array('ActionID','NextActionID');
foreach ($check as $fieldName) {
if (!isset($data[$fieldName])) {
return self::$extendedMethodReturn;
return WorkflowTransition::$extendedMethodReturn;
}
}
// Have we found some identical values?
if ($data[$check[0]] == $data[$check[1]]) {
// Used to display to the user, so the first of the array is fine
self::$extendedMethodReturn['fieldName'] = $check[0];
self::$extendedMethodReturn['fieldValid'] = false;
self::$extendedMethodReturn['fieldMsg'] = _t(
WorkflowTransition::$extendedMethodReturn['fieldName'] = $check[0];
WorkflowTransition::$extendedMethodReturn['fieldValid'] = false;
WorkflowTransition::$extendedMethodReturn['fieldMsg'] = _t(
'WorkflowTransition.TRANSITIONLOOP',
'A transition cannot lead back to its parent action.'
);
}
return self::$extendedMethodReturn;
return WorkflowTransition::$extendedMethodReturn;
}
}
4 changes: 2 additions & 2 deletions src/Forms/AWRequiredFields.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,11 @@ protected function getData()

public function setCaller($caller)
{
self::$caller = $caller;
AWRequiredFields::$caller = $caller;
}

public function getCaller()
{
return self::$caller;
return AWRequiredFields::$caller;
}
}
2 changes: 1 addition & 1 deletion src/Jobs/WorkflowReminderJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class WorkflowReminderJob extends AbstractQueuedJob
public function __construct($repeatInterval = 0)
{
if (!$this->repeatInterval) {
$this->repeatInterval = $repeatInterval ? $repeatInterval : self::DEFAULT_REPEAT;
$this->repeatInterval = $repeatInterval ? $repeatInterval : WorkflowReminderJob::DEFAULT_REPEAT;
$this->totalSteps = 2;
$this->currentStep = 1;
}
Expand Down
Loading