From 8477da26437cd927b47fbac8874e2a7e02b580ca Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Sun, 14 Feb 2016 15:49:59 -0500 Subject: Rename File controller to TaskFile --- app/Template/board/tooltip_files.php | 4 +- app/Template/file/new.php | 33 -------------- app/Template/file/open.php | 6 --- app/Template/file/remove.php | 15 ------- app/Template/file/screenshot.php | 19 -------- app/Template/file/show.php | 84 ----------------------------------- app/Template/task/menu.php | 4 +- app/Template/task/show.php | 2 +- app/Template/task_file/new.php | 33 ++++++++++++++ app/Template/task_file/open.php | 6 +++ app/Template/task_file/remove.php | 15 +++++++ app/Template/task_file/screenshot.php | 19 ++++++++ app/Template/task_file/show.php | 84 +++++++++++++++++++++++++++++++++++ 13 files changed, 162 insertions(+), 162 deletions(-) delete mode 100644 app/Template/file/new.php delete mode 100644 app/Template/file/open.php delete mode 100644 app/Template/file/remove.php delete mode 100644 app/Template/file/screenshot.php delete mode 100644 app/Template/file/show.php create mode 100644 app/Template/task_file/new.php create mode 100644 app/Template/task_file/open.php create mode 100644 app/Template/task_file/remove.php create mode 100644 app/Template/task_file/screenshot.php create mode 100644 app/Template/task_file/show.php (limited to 'app/Template') diff --git a/app/Template/board/tooltip_files.php b/app/Template/board/tooltip_files.php index 407309b3..4fa14b57 100644 --- a/app/Template/board/tooltip_files.php +++ b/app/Template/board/tooltip_files.php @@ -8,9 +8,9 @@ - url->link(t('download'), 'file', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> + url->link(t('download'), 'TaskFile', 'download', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id'])) ?> -   url->link(t('open file'), 'file', 'open', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id']), false, 'popover') ?> +   url->link(t('open file'), 'TaskFile', 'open', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id']), false, 'popover') ?> diff --git a/app/Template/file/new.php b/app/Template/file/new.php deleted file mode 100644 index e84ef839..00000000 --- a/app/Template/file/new.php +++ /dev/null @@ -1,33 +0,0 @@ - - - - - -
-
- -
-
- - - -
- - - url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?> -
diff --git a/app/Template/file/open.php b/app/Template/file/open.php deleted file mode 100644 index 3df012b6..00000000 --- a/app/Template/file/open.php +++ /dev/null @@ -1,6 +0,0 @@ - \ No newline at end of file diff --git a/app/Template/file/remove.php b/app/Template/file/remove.php deleted file mode 100644 index 24844835..00000000 --- a/app/Template/file/remove.php +++ /dev/null @@ -1,15 +0,0 @@ - - -
-

- e($file['name'])) ?> -

- -
- url->link(t('Yes'), 'file', 'remove', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id']), true, 'btn btn-red') ?> - - url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?> -
-
\ No newline at end of file diff --git a/app/Template/file/screenshot.php b/app/Template/file/screenshot.php deleted file mode 100644 index 58b93ac3..00000000 --- a/app/Template/file/screenshot.php +++ /dev/null @@ -1,19 +0,0 @@ - - -
-

-
- -
- - form->csrf() ?> -
- - - url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?> -
-
- -

\ No newline at end of file diff --git a/app/Template/file/show.php b/app/Template/file/show.php deleted file mode 100644 index ed006299..00000000 --- a/app/Template/file/show.php +++ /dev/null @@ -1,84 +0,0 @@ - -
- - - -
- -
- <?= $this->e($file['name']) ?> -
-
- -
-
- dt->datetime($file['date'])).'
'.t('Size: %s', $this->text->bytes($file['size'])) ?>'> - -
- -
-
-
- -
- - - - - - - - - - - - - - - - - - -
- - - - e($file['user_name'] ?: $file['username']) ?> - - dt->date($file['date']) ?> - - text->bytes($file['size']) ?> -
- -
- \ No newline at end of file diff --git a/app/Template/task/menu.php b/app/Template/task/menu.php index e997a6ad..cddd930a 100644 --- a/app/Template/task/menu.php +++ b/app/Template/task/menu.php @@ -38,11 +38,11 @@
  • - url->link(t('Attach a document'), 'file', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?> + url->link(t('Attach a document'), 'TaskFile', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?>
  • - url->link(t('Add a screenshot'), 'file', 'screenshot', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?> + url->link(t('Add a screenshot'), 'TaskFile', 'screenshot', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?>
  • diff --git a/app/Template/task/show.php b/app/Template/task/show.php index 43906a81..a32232ae 100644 --- a/app/Template/task/show.php +++ b/app/Template/task/show.php @@ -25,7 +25,7 @@ render('task/time_tracking_summary', array('task' => $task)) ?> -render('file/show', array( +render('task_file/show', array( 'task' => $task, 'files' => $files, 'images' => $images diff --git a/app/Template/task_file/new.php b/app/Template/task_file/new.php new file mode 100644 index 00000000..f03ce8dc --- /dev/null +++ b/app/Template/task_file/new.php @@ -0,0 +1,33 @@ + + + + + +
    +
    + +
    +
    + + + +
    + + + url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?> +
    diff --git a/app/Template/task_file/open.php b/app/Template/task_file/open.php new file mode 100644 index 00000000..e3721b59 --- /dev/null +++ b/app/Template/task_file/open.php @@ -0,0 +1,6 @@ + \ No newline at end of file diff --git a/app/Template/task_file/remove.php b/app/Template/task_file/remove.php new file mode 100644 index 00000000..5e6c83f2 --- /dev/null +++ b/app/Template/task_file/remove.php @@ -0,0 +1,15 @@ + + +
    +

    + e($file['name'])) ?> +

    + +
    + url->link(t('Yes'), 'TaskFile', 'remove', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'file_id' => $file['id']), true, 'btn btn-red') ?> + + url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?> +
    +
    \ No newline at end of file diff --git a/app/Template/task_file/screenshot.php b/app/Template/task_file/screenshot.php new file mode 100644 index 00000000..72214362 --- /dev/null +++ b/app/Template/task_file/screenshot.php @@ -0,0 +1,19 @@ + + +
    +

    +
    + +
    + + form->csrf() ?> +
    + + + url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'close-popover') ?> +
    +
    + +

    \ No newline at end of file diff --git a/app/Template/task_file/show.php b/app/Template/task_file/show.php new file mode 100644 index 00000000..98f26c33 --- /dev/null +++ b/app/Template/task_file/show.php @@ -0,0 +1,84 @@ + +
    + + + +
    + +
    + <?= $this->e($file['name']) ?> +
    +
    + +
    +
    + dt->datetime($file['date'])).'
    '.t('Size: %s', $this->text->bytes($file['size'])) ?>'> + +
    + +
    +
    +
    + +
    + + + + + + + + + + + + + + + + + + +
    + + + + e($file['user_name'] ?: $file['username']) ?> + + dt->date($file['date']) ?> + + text->bytes($file['size']) ?> +
    + +
    + \ No newline at end of file -- cgit v1.2.3