Changeset View
Changeset View
Standalone View
Standalone View
src/applications/phriction/storage/PhrictionContent.php
Show First 20 Lines • Show All 112 Lines • ▼ Show 20 Lines | return array( | ||||
id(new PhabricatorConduitSearchFieldSpecification()) | id(new PhabricatorConduitSearchFieldSpecification()) | ||||
->setKey('documentPHID') | ->setKey('documentPHID') | ||||
->setType('phid') | ->setType('phid') | ||||
->setDescription(pht('Document this content is for.')), | ->setDescription(pht('Document this content is for.')), | ||||
id(new PhabricatorConduitSearchFieldSpecification()) | id(new PhabricatorConduitSearchFieldSpecification()) | ||||
->setKey('version') | ->setKey('version') | ||||
->setType('int') | ->setType('int') | ||||
->setDescription(pht('Content version.')), | ->setDescription(pht('Content version.')), | ||||
id(new PhabricatorConduitSearchFieldSpecification()) | |||||
->setKey('authorPHID') | |||||
->setType('phid') | |||||
->setDescription(pht('Author of this version of the content.')), | |||||
); | ); | ||||
} | } | ||||
public function getFieldValuesForConduit() { | public function getFieldValuesForConduit() { | ||||
return array( | return array( | ||||
'documentPHID' => $this->getDocument()->getPHID(), | 'documentPHID' => $this->getDocument()->getPHID(), | ||||
'version' => (int)$this->getVersion(), | 'version' => (int)$this->getVersion(), | ||||
'authorPHID' => $this->getAuthorPHID(), | |||||
); | ); | ||||
} | } | ||||
public function getConduitSearchAttachments() { | public function getConduitSearchAttachments() { | ||||
return array(); | return array( | ||||
id(new PhrictionContentSearchEngineAttachment()) | |||||
->setAttachmentKey('content'), | |||||
); | |||||
} | } | ||||
} | } |