@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.)
hq.recaptime.dev/wiki/Phorge
phorge
phabricator
1<?php
2
3final class PhamePostEditEngineLock
4 extends PhabricatorEditEngineLock {
5
6 public function willPromptUserForLockOverrideWithDialog(
7 AphrontDialogView $dialog) {
8
9 return $dialog
10 ->setTitle(pht('Edit Locked Post'))
11 ->appendParagraph(
12 pht('Comments are disabled for this post. Edit it anyway?'))
13 ->addSubmitButton(pht('Edit Post'));
14 }
15
16 public function willBlockUserInteractionWithDialog(
17 AphrontDialogView $dialog) {
18
19 return $dialog
20 ->setTitle(pht('Post Locked'))
21 ->appendParagraph(
22 pht('You can not interact with this post because it is locked.'));
23 }
24
25 public function getLockedObjectDisplayText() {
26 return pht('Comments have been disabled for this post.');
27 }
28
29}