1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-30 01:10:58 +01:00

Add rulePHID to HeraldEffect

Summary: Ref T4195. Herald rules gained PHIDs only recently, propagate them to HeraldEffect to make some of the hook stuff eaiser.

Test Plan: iiam

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T4195

Differential Revision: https://secure.phabricator.com/D7781
This commit is contained in:
epriestley 2013-12-17 15:23:45 -08:00
parent f28d3089d7
commit baa756a027
2 changed files with 17 additions and 6 deletions

View file

@ -2,14 +2,15 @@
final class HeraldEffect {
protected $objectPHID;
protected $action;
protected $target;
private $objectPHID;
private $action;
private $target;
protected $ruleID;
protected $effector;
private $ruleID;
private $rulePHID;
private $effector;
protected $reason;
private $reason;
public function setObjectPHID($object_phid) {
$this->objectPHID = $object_phid;
@ -47,6 +48,15 @@ final class HeraldEffect {
return $this->ruleID;
}
public function setRulePHID($rule_phid) {
$this->rulePHID = $rule_phid;
return $this;
}
public function getRulePHID() {
return $this->rulePHID;
}
public function setEffector($effector) {
$this->effector = $effector;
return $this;

View file

@ -359,6 +359,7 @@ final class HeraldEngine {
$effect->setTarget($action->getTarget());
$effect->setRuleID($rule->getID());
$effect->setRulePHID($rule->getPHID());
$name = $rule->getName();
$id = $rule->getID();