Differential D18000 Diff 43300 src/applications/phriction/conduit/PhrictionCreateConduitAPIMethod.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/phriction/conduit/PhrictionCreateConduitAPIMethod.php
Show First 20 Lines • Show All 44 Lines • ▼ Show 20 Lines | $doc = PhrictionDocument::initializeNewDocument( | ||||
$request->getUser(), | $request->getUser(), | ||||
$slug); | $slug); | ||||
$xactions = array(); | $xactions = array(); | ||||
$xactions[] = id(new PhrictionTransaction()) | $xactions[] = id(new PhrictionTransaction()) | ||||
->setTransactionType(PhrictionDocumentTitleTransaction::TRANSACTIONTYPE) | ->setTransactionType(PhrictionDocumentTitleTransaction::TRANSACTIONTYPE) | ||||
->setNewValue($request->getValue('title')); | ->setNewValue($request->getValue('title')); | ||||
$xactions[] = id(new PhrictionTransaction()) | $xactions[] = id(new PhrictionTransaction()) | ||||
->setTransactionType(PhrictionTransaction::TYPE_CONTENT) | ->setTransactionType(PhrictionDocumentContentTransaction::TRANSACTIONTYPE) | ||||
->setNewValue($request->getValue('content')); | ->setNewValue($request->getValue('content')); | ||||
$editor = id(new PhrictionTransactionEditor()) | $editor = id(new PhrictionTransactionEditor()) | ||||
->setActor($request->getUser()) | ->setActor($request->getUser()) | ||||
->setContentSource($request->newContentSource()) | ->setContentSource($request->newContentSource()) | ||||
->setContinueOnNoEffect(true) | ->setContinueOnNoEffect(true) | ||||
->setDescription($request->getValue('description')); | ->setDescription($request->getValue('description')); | ||||
Show All 10 Lines |