看板初始化提交

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
@@ -0,0 +1,8 @@
<div class="page-header">
<h2><?= t('Add a new external link') ?></h2>
</div>
<form action="<?= $this->url->href('TaskExternalLinkController', 'save', array('task_id' => $task['id'])) ?>" method="post" autocomplete="off">
<?= $this->render('task_external_link/form', array('task' => $task, 'dependencies' => $dependencies, 'values' => $values, 'errors' => $errors)) ?>
<?= $this->modal->submitButtons() ?>
</form>
+8
View File
@@ -0,0 +1,8 @@
<div class="page-header">
<h2><?= t('Edit external link') ?></h2>
</div>
<form action="<?= $this->url->href('TaskExternalLinkController', 'update', array('task_id' => $task['id'], 'link_id' => $link['id'])) ?>" method="post" autocomplete="off">
<?= $this->render('task_external_link/form', array('task' => $task, 'dependencies' => $dependencies, 'values' => $values, 'errors' => $errors)) ?>
<?= $this->modal->submitButtons() ?>
</form>
+23
View File
@@ -0,0 +1,23 @@
<div class="page-header">
<h2><?= t('Add a new external link') ?></h2>
</div>
<form action="<?= $this->url->href('TaskExternalLinkController', 'create', array('task_id' => $task['id'])) ?>" method="post" autocomplete="off">
<?= $this->form->csrf() ?>
<?= $this->form->label(t('External link'), 'text') ?>
<?= $this->form->text(
'text',
$values,
$errors,
array(
'required',
'autofocus',
'placeholder="'.t('Copy and paste your link here...').'"',
)) ?>
<?= $this->form->label(t('Link type'), 'type') ?>
<?= $this->form->select('type', $types, $values) ?>
<?= $this->modal->submitButtons() ?>
</form>
+11
View File
@@ -0,0 +1,11 @@
<?= $this->form->csrf() ?>
<?= $this->form->hidden('link_type', $values) ?>
<?= $this->form->label(t('URL'), 'url') ?>
<?= $this->form->text('url', $values, $errors, array('required')) ?>
<?= $this->form->label(t('Title'), 'title') ?>
<?= $this->form->text('title', $values, $errors, array('required')) ?>
<?= $this->form->label(t('Dependency'), 'dependency') ?>
<?= $this->form->select('dependency', $dependencies, $values, $errors) ?>
@@ -0,0 +1,15 @@
<div class="page-header">
<h2><?= t('Remove a link') ?></h2>
</div>
<div class="confirm">
<p class="alert alert-info">
<?= t('Do you really want to remove this link: "%s"?', $link['title']) ?>
</p>
<?= $this->modal->confirmButtons(
'TaskExternalLinkController',
'remove',
array('link_id' => $link['id'], 'task_id' => $task['id'])
) ?>
</div>
+10
View File
@@ -0,0 +1,10 @@
<details class="accordion-section" <?= empty($links) ? '' : 'open' ?>>
<summary class="accordion-title"><?= t('External links') ?></summary>
<div class="accordion-content">
<?= $this->render('task_external_link/table', array(
'links' => $links,
'task' => $task,
'project' => $project,
)) ?>
</div>
</details>
+47
View File
@@ -0,0 +1,47 @@
<?php if (! empty($links)): ?>
<table class="table-striped table-scrolling">
<thead>
<tr>
<th class="column-15"><?= t('Type') ?></th>
<th><?= t('Title') ?></th>
<th class="column-15"><?= t('Dependency') ?></th>
<th class="column-15"><?= t('Creator') ?></th>
<th class="column-10"><?= t('Date') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($links as $link): ?>
<tr>
<td>
<?php if ($this->user->hasProjectAccess('TaskExternalLinkController', 'edit', $task['project_id'])): ?>
<div class="dropdown">
<a href="#" class="dropdown-menu dropdown-menu-link-icon"><i class="fa fa-cog"></i><i class="fa fa-caret-down"></i></a>
<ul>
<li>
<?= $this->modal->medium('edit', t('Edit'), 'TaskExternalLinkController', 'edit', array('link_id' => $link['id'], 'task_id' => $task['id'])) ?>
</li>
<li>
<?= $this->modal->confirm('trash-o', t('Remove'), 'TaskExternalLinkController', 'confirm', array('link_id' => $link['id'], 'task_id' => $task['id'])) ?>
</li>
</ul>
</div>
<?php endif ?>
<?= $this->text->e($link['type']) ?>
</td>
<td>
<a href="<?= $this->text->e($link['url']) ?>" title="<?= $this->text->e($link['url']) ?>" target="_blank"><?= $this->text->e($link['title']) ?><span class="ui-helper-hidden-accessible"> (<?= $this->text->e($link['url']) ?>)</span></a>
</td>
<td>
<?= $this->text->e($link['dependency_label']) ?>
</td>
<td>
<?= $this->text->e($link['creator_name'] ?: $link['creator_username']) ?>
</td>
<td>
<?= $this->dt->date($link['date_creation']) ?>
</td>
</tr>
<?php endforeach ?>
</tbody>
</table>
<?php endif ?>