Page MenuHomePhorge

D25705.1734665035.diff
No OneTemporary

D25705.1734665035.diff

diff --git a/src/applications/phriction/controller/PhrictionEditController.php b/src/applications/phriction/controller/PhrictionEditController.php
--- a/src/applications/phriction/controller/PhrictionEditController.php
+++ b/src/applications/phriction/controller/PhrictionEditController.php
@@ -134,9 +134,31 @@
$xactions[] = id(new PhrictionTransaction())
->setTransactionType(PhrictionDocumentTitleTransaction::TRANSACTIONTYPE)
->setNewValue($title);
- $xactions[] = id(new PhrictionTransaction())
+ $content_xaction = id(new PhrictionTransaction())
->setTransactionType($edit_type)
->setNewValue($content_text);
+
+ $content_metadata = $request->getStr('content_metadata');
+ if ($content_metadata) {
+ $content_metadata = phutil_json_decode($content_metadata);
+ $attached_file_phids = idx(
+ $content_metadata,
+ 'attachedFilePHIDs',
+ array());
+
+ if ($attached_file_phids) {
+ $metadata_object = array(
+ 'remarkup.control' => array(
+ 'attachedFilePHIDs' => $attached_file_phids,
+ ),
+ );
+
+ $content_xaction->setMetadata($metadata_object);
+ }
+ }
+
+ $xactions[] = $content_xaction;
+
$xactions[] = id(new PhrictionTransaction())
->setTransactionType(PhabricatorTransactions::TYPE_VIEW_POLICY)
->setNewValue($v_view)

File Metadata

Mime Type
text/plain
Expires
Fri, Dec 20, 03:23 (21 h, 29 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1016464
Default Alt Text
D25705.1734665035.diff (1 KB)

Event Timeline