@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.)
hq.recaptime.dev/wiki/Phorge
phorge
phabricator
1<?php
2
3final class PhabricatorSystemActionLog extends PhabricatorSystemDAO {
4
5 protected $actorHash;
6 protected $actorIdentity;
7 protected $action;
8 protected $score;
9 protected $epoch;
10
11 protected function getConfiguration() {
12 return array(
13 self::CONFIG_TIMESTAMPS => false,
14 self::CONFIG_COLUMN_SCHEMA => array(
15 'actorHash' => 'bytes12',
16 'actorIdentity' => 'text255',
17 'action' => 'text32',
18 'score' => 'double',
19 ),
20 self::CONFIG_KEY_SCHEMA => array(
21 'key_epoch' => array(
22 'columns' => array('epoch'),
23 ),
24 'key_action' => array(
25 'columns' => array('actorHash', 'action', 'epoch'),
26 ),
27 ),
28 ) + parent::getConfiguration();
29 }
30
31 public function setActorIdentity($identity) {
32 $this->setActorHash(PhabricatorHash::digestForIndex($identity));
33 return parent::setActorIdentity($identity);
34 }
35
36}