diff --git a/resources/sql/patches/20130214.chatlogchannelid.sql b/resources/sql/patches/20130214.chatlogchannelid.sql new file mode 100644 index 0000000000..bc522e205c --- /dev/null +++ b/resources/sql/patches/20130214.chatlogchannelid.sql @@ -0,0 +1,2 @@ +ALTER TABLE `{$NAMESPACE}_chatlog`.`chatlog_event` + ADD `channelID` INT UNSIGNED NOT NULL; diff --git a/src/applications/chatlog/conduit/ConduitAPI_chatlog_record_Method.php b/src/applications/chatlog/conduit/ConduitAPI_chatlog_record_Method.php index 3bdd5c9181..1531e26c6d 100644 --- a/src/applications/chatlog/conduit/ConduitAPI_chatlog_record_Method.php +++ b/src/applications/chatlog/conduit/ConduitAPI_chatlog_record_Method.php @@ -42,6 +42,7 @@ final class ConduitAPI_chatlog_record_Method foreach ($logs as $log) { $obj = clone $template; $obj->setChannel(idx($log, 'channel')); + $obj->setChannelID(0); $obj->setType(idx($log, 'type')); $obj->setAuthor(idx($log, 'author')); $obj->setEpoch(idx($log, 'epoch')); diff --git a/src/applications/chatlog/storage/PhabricatorChatLogEvent.php b/src/applications/chatlog/storage/PhabricatorChatLogEvent.php index 0c29886922..ebdb600ea6 100644 --- a/src/applications/chatlog/storage/PhabricatorChatLogEvent.php +++ b/src/applications/chatlog/storage/PhabricatorChatLogEvent.php @@ -5,6 +5,7 @@ final class PhabricatorChatLogEvent implements PhabricatorPolicyInterface { protected $channel; + protected $channelID; protected $epoch; protected $author; protected $type; diff --git a/src/infrastructure/storage/patch/PhabricatorBuiltinPatchList.php b/src/infrastructure/storage/patch/PhabricatorBuiltinPatchList.php index c8e5ee4e77..99d6f17dda 100644 --- a/src/infrastructure/storage/patch/PhabricatorBuiltinPatchList.php +++ b/src/infrastructure/storage/patch/PhabricatorBuiltinPatchList.php @@ -1113,6 +1113,10 @@ final class PhabricatorBuiltinPatchList extends PhabricatorSQLPatchList { 'type' => 'sql', 'name' => $this->getPatchPath('20130214.chatlogchannel.sql'), ), + '20130214.chatlogchannelid.sql' => array( + 'type' => 'sql', + 'name' => $this->getPatchPath('20130214.chatlogchannelid.sql'), + ), ); }