9 changed files with 144 additions and 36 deletions
-
4CHANGELOG.md
-
8app/widgets/Post/locales.ini
-
23app/widgets/Publish/Publish.php
-
53app/widgets/Publish/_publish_toggles.tpl
-
17app/widgets/Publish/publish.css
-
28app/widgets/Publish/publish.tpl
-
6app/widgets/PublishHelp/PublishHelp.php
-
21database/migrations/20240204122606_add_comments_disabled_to_drafs_table.php
-
12src/Moxl/Stanza/PubsubAtom.php
@ -0,0 +1,53 @@ |
|||||
|
<li> |
||||
|
<span class="primary privacy" |
||||
|
title="{$c->__('post.public_title')}"> |
||||
|
<form> |
||||
|
<div> |
||||
|
<div class="checkbox"> |
||||
|
<input |
||||
|
id="public" |
||||
|
name="public" |
||||
|
onchange="Publish_ajaxTogglePrivacy({$draft->id}, this.checked)" |
||||
|
{if="$draft && $draft->open"} |
||||
|
checked |
||||
|
{/if} |
||||
|
type="checkbox"> |
||||
|
<label for="public"> |
||||
|
<i class="material-symbols"></i> |
||||
|
</label> |
||||
|
</div> |
||||
|
</div> |
||||
|
</form> |
||||
|
</span> |
||||
|
<div> |
||||
|
<p>{$c->__('post.public_title')}</p> |
||||
|
<p>{$c->__('post.public_text')}</p> |
||||
|
</div> |
||||
|
</li> |
||||
|
|
||||
|
<li> |
||||
|
<span class="primary comments_disabled" |
||||
|
title="{$c->__('post.comments_disabled_title')}"> |
||||
|
<form> |
||||
|
<div> |
||||
|
<div class="checkbox"> |
||||
|
<input |
||||
|
id="comments_disabled" |
||||
|
name="comments_disabled" |
||||
|
onchange="Publish_ajaxToggleCommentsDisabled({$draft->id}, this.checked)" |
||||
|
{if="$draft && $draft->comments_disabled"} |
||||
|
checked |
||||
|
{/if} |
||||
|
type="checkbox"> |
||||
|
<label for="comments_disabled"> |
||||
|
<i class="material-symbols"></i> |
||||
|
</label> |
||||
|
</div> |
||||
|
</div> |
||||
|
</form> |
||||
|
</span> |
||||
|
<div> |
||||
|
<p>{$c->__('post.comments_disabled_title')}</p> |
||||
|
<p>{$c->__('post.comments_disabled_text')}</p> |
||||
|
</div> |
||||
|
</li> |
||||
@ -0,0 +1,21 @@ |
|||||
|
<?php |
||||
|
|
||||
|
use Movim\Migration; |
||||
|
use Illuminate\Database\Schema\Blueprint; |
||||
|
|
||||
|
class AddCommentsDisabledToDrafsTable extends Migration |
||||
|
{ |
||||
|
public function up() |
||||
|
{ |
||||
|
$this->schema->table('drafts', function (Blueprint $table) { |
||||
|
$table->boolean('comments_disabled')->default(false); |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
public function down() |
||||
|
{ |
||||
|
$this->schema->table('drafts', function (Blueprint $table) { |
||||
|
$table->dropColumn('comments_disabled'); |
||||
|
}); |
||||
|
} |
||||
|
} |
||||
Write
Preview
Loading…
Cancel
Save
Reference in new issue