看板初始化提交

This commit is contained in:
zephyr
2026-06-01 21:23:12 -07:00
commit 27411ebedc
1827 changed files with 192340 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
<?php use Kanboard\Core\Security\Role;?>
<div class="page-header">
<h2><?= t('Add a comment') ?></h2>
</div>
<form method="post" action="<?= $this->url->href('CommentListController', 'save', array('task_id' => $task['id'])) ?>" autocomplete="off">
<?= $this->form->csrf() ?>
<?= $this->form->textEditor('comment', array('project_id' => $task['project_id']), array(), array('required' => true, 'aria-label' => t('New comment'))) ?>
<?php
$formName = 'visibility';
$visibilityOptions['app-user'] = t('Standard users');
$attribute[] = ('hidden');
?>
<?php if ($this->user->getRole() !== Role::APP_USER) {
echo $this->form->label(t('Visibility:'), $formName);
$attribute = [];
$visibilityOptions['app-user'] = t('Standard users');
$visibilityOptions['app-manager'] = t('Application managers or more');
}
?>
<?php if ($this->user->getRole() === Role::APP_ADMIN) {
$visibilityOptions['app-admin'] = t('Administrators');
}
?>
<?= $this->form->select($formName, $visibilityOptions, array(), array(), $attribute) ?>
<?= $this->modal->submitButtons() ?>
</form>
+31
View File
@@ -0,0 +1,31 @@
<div class="page-header">
<h2><?= $this->text->e($task['title']) ?></h2>
<?php if (!isset($is_public) || !$is_public): ?>
<ul>
<li>
<?= $this->url->icon('sort', t('Change sorting'), 'CommentListController', 'toggleSorting', array('task_id' => $task['id']), false, 'js-modal-replace') ?>
</li>
<?php if ($editable): ?>
<li>
<?= $this->modal->medium('paper-plane', t('Send by email'), 'CommentMailController', 'create', array('task_id' => $task['id'])) ?>
</li>
<?php endif ?>
</ul>
<?php endif ?>
</div>
<div class="comments">
<?php foreach ($comments as $comment): ?>
<?= $this->render('comment/show', array(
'comment' => $comment,
'task' => $task,
'editable' => $editable,
'is_public' => isset($is_public) && $is_public,
)) ?>
<?php endforeach ?>
<?php if ($editable): ?>
<?= $this->render('comment_list/create', array(
'task' => $task,
)) ?>
<?php endif ?>
</div>