Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F14060698
D8303.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D8303.diff
View Options
Index: src/applications/differential/editor/DifferentialTransactionEditor.php
===================================================================
--- src/applications/differential/editor/DifferentialTransactionEditor.php
+++ src/applications/differential/editor/DifferentialTransactionEditor.php
@@ -107,6 +107,57 @@
return parent::requireCapabilities($object, $xaction);
}
+ protected function shouldSendMail(
+ PhabricatorLiskDAO $object,
+ array $xactions) {
+ return true;
+ }
+
+ protected function getMailTo(PhabricatorLiskDAO $object) {
+ $phids = array();
+ $phids[] = $object->getAuthorPHID();
+ foreach ($object->getReviewerStatus() as $reviewer) {
+ $phids[] = $reviewer->getReviewerPHID();
+ }
+ return $phids;
+ }
+
+ protected function getMailSubjectPrefix() {
+ return PhabricatorEnv::getEnvConfig('metamta.differential.subject-prefix');
+ }
+
+ protected function buildReplyHandler(PhabricatorLiskDAO $object) {
+ return id(new DifferentialReplyHandler())
+ ->setMailReceiver($object);
+ }
+
+ protected function buildMailTemplate(PhabricatorLiskDAO $object) {
+ $id = $object->getID();
+ $title = $object->getTitle();
+
+ $original_title = $object->getOriginalTitle();
+
+ $subject = "D{$id}: {$title}";
+ $thread_topic = "D{$id}: {$original_title}";
+
+ return id(new PhabricatorMetaMTAMail())
+ ->setSubject($subject)
+ ->addHeader('Thread-Topic', $thread_topic);
+ }
+
+ protected function buildMailBody(
+ PhabricatorLiskDAO $object,
+ array $xactions) {
+
+ $body = parent::buildMailBody($object, $xactions);
+
+ $body->addTextSection(
+ pht('REVISION DETAIL'),
+ PhabricatorEnv::getProductionURI('/D'.$object->getID()));
+
+ return $body;
+ }
+
protected function supportsSearch() {
return true;
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Nov 19, 3:03 AM (14 h, 29 m ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6715381
Default Alt Text
D8303.diff (1 KB)
Attached To
Mode
D8303: Send basic email from new ApplicationTransaction editor
Attached
Detach File
Event Timeline
Log In to Comment