summaryrefslogtreecommitdiffstats
path: root/apps/tasks/templates
diff options
context:
space:
mode:
Diffstat (limited to 'apps/tasks/templates')
-rw-r--r--apps/tasks/templates/part.taskform.php10
-rw-r--r--apps/tasks/templates/tasks.php3
2 files changed, 5 insertions, 8 deletions
diff --git a/apps/tasks/templates/part.taskform.php b/apps/tasks/templates/part.taskform.php
index 139693c0e96..da984d830bd 100644
--- a/apps/tasks/templates/part.taskform.php
+++ b/apps/tasks/templates/part.taskform.php
@@ -5,14 +5,8 @@
<input type="text" id="location" name="location" placeholder="<?php echo $l->t('Location of the task');?>" value="<?php echo isset($_['details']->LOCATION) ? $_['details']->LOCATION[0]->value : '' ?>">
<br>
<label for="categories"><?php echo $l->t('Categories'); ?></label>
- <select name="categories[]" multiple="multiple">
- <?php
-var_dump($_['categories']);
- foreach($_['category_options'] as $category){
- echo '<option value="' . $category . '"' . (in_array($category, $_['categories']) ? ' selected="selected"' : '') . '>' . $category . '</option>';
- }
- ?>
- </select>
+ <input id="categories" name="categories" type="text" placeholder="<?php echo $l->t('Separate categories with commas'); ?>" value="<?php echo isset($_['categories']) ? htmlspecialchars($_['categories']) : '' ?>">
+ <a class="action edit" onclick="$(this).tipsy('hide');OCCategories.edit();" title="<?php echo $l->t('Edit categories'); ?>"><img alt="<?php echo $l->t('Edit categories'); ?>" src="<?php echo image_path('core','actions/rename.svg')?>" class="svg action" style="width: 16px; height: 16px;"></a>
<br>
<label for="due"><?php echo $l->t('Due'); ?></label>
<input type="text" id="due" name="due" placeholder="<?php echo $l->t('Due date') ?>" value="<?php echo isset($_['details']->DUE) ? $l->l('datetime', $_['details']->DUE[0]->getDateTime()) : '' ?>">
diff --git a/apps/tasks/templates/tasks.php b/apps/tasks/templates/tasks.php
index 8d34a40683b..8df2a100b69 100644
--- a/apps/tasks/templates/tasks.php
+++ b/apps/tasks/templates/tasks.php
@@ -20,3 +20,6 @@
<img title="Edit" src="<?php echo image_path('core', 'actions/rename.svg') ?>" class="svg">
</span>
</p>
+<script type='text/javascript'>
+var categories = <?php echo json_encode($_['categories']); ?>;
+</script>