tasks/templates/main.php

148 lines
8.7 KiB
PHP
Raw Normal View History

2015-06-11 07:34:38 +00:00
<div ng-app="Tasks" ng-cloak ng-controller="AppController" ng-click="closeAll($event)" id="app" class="handler">
<div id="app-navigation" ng-controller="ListController">
<ul id="collections">
2015-07-19 12:05:29 +00:00
<li id="collection_{{ collection.id }}"
class="collection"
collectionID="{{collection.id}}"
ng-repeat="collection in collections"
ng-class="{'animate-up': hideCollection(collection.id), active: collection.id==route.listID}"
dnd-list="draggedTasks"
dnd-drop="dropCollection(event, item, index)"
dnd-dragover="dragoverCollection(event, item, index)">
<a href="#/lists/{{ collection.id }}">
2015-07-19 12:05:29 +00:00
<span class="icon collection-{{ collection.id }}">
<text ng-show="collection.id=='today'"><?php p($_['DOM']); ?></text>
</span>
<span class="title">{{ collection.displayname }}</span>
</a>
<div class="app-navigation-entry-utils">
<ul>
<li class="app-navigation-entry-utils-counter">{{ getCollectionString(collection.id) | counterFormatter }}</li>
</ul>
</div>
</li>
2015-07-19 12:05:29 +00:00
<li class="list with-menu handler"
2016-02-25 21:27:45 +00:00
id="list_{{ calendar._properties.uri }}"
listID="{{calendar._properties.uri}}"
ng-repeat="calendar in calendars"
ng-class="{active: calendar._properties.uri==route.listID, edit:route.listparameter == 'name' && route.listID == calendar._properties.uri}"
2015-07-19 12:05:29 +00:00
dnd-list="draggedTasks"
dnd-drop="dropList(event, item, index)"
dnd-dragover="dragoverList(event, item, index)">
2016-02-25 21:27:45 +00:00
<a href="#/lists/{{ calendar._properties.uri }}" style="border-right: 4px solid {{ calendar._properties.calendarcolor }};" ng-dblclick="editName(calendar._properties.uri)">
<span class="icon list-list"></span>
2016-02-25 21:27:45 +00:00
<span class="title">{{ calendar._properties.displayname }}</span>
</a>
<div class="app-navigation-entry-utils">
<ul>
2016-02-25 21:27:45 +00:00
<li class="app-navigation-entry-utils-counter">{{ getListCount(calendar._properties.uri,'all') | counterFormatter }}</li>
<li class="app-navigation-entry-utils-menu-button svg"><button></button></li>
</ul>
</div>
2015-06-14 19:22:13 +00:00
<div class="app-navigation-entry-menu">
<ul>
2016-02-25 21:27:45 +00:00
<li title="<?php p($l->t('rename')); ?>" ng-click="editName(calendar._properties.uri)" >
2015-09-01 20:59:44 +00:00
<img class="icon-rename svg" src="<?php p(image_path('core', 'actions/rename.svg'))?>"/>
<span><?php p($l->t('rename')); ?></span>
</li>
2016-02-25 21:27:45 +00:00
<li title="<?php p($l->t('delete')); ?>" ng-click="deleteList(calendar._properties.uri)" ng-show="showDelete(calendar._properties.uri)" >
2015-09-01 20:59:44 +00:00
<img class="icon-delete svg" src="<?php p(image_path('core', 'actions/delete.svg'))?>"/>
<span><?php p($l->t('delete')); ?></span>
</li>
</ul>
</div>
2015-06-14 19:22:13 +00:00
<div class="app-navigation-entry-edit">
2015-06-11 07:34:38 +00:00
<form>
2016-02-25 21:27:45 +00:00
<input ng-model="calendar._properties.displayname" class="edit" type="text" ng-keydown="checkName($event)" autofocus-on-insert>
2015-06-11 19:09:03 +00:00
<input type="submit" value="" class="action icon-checkmark svg" ng-click="submitNewName()">
2015-06-11 07:34:38 +00:00
</form>
</div>
</li>
2015-06-14 19:22:13 +00:00
<li class="newList handler" ng-class="{edit: status.addingList}">
<a class="addlist" ng-click="startAddingList()" oc-click-focus="{selector: '#newList', timeout: 0}">
<span class="icon detail-add"></span>
2015-06-14 18:57:09 +00:00
<span class="title"><?php p($l->t('Add List...')); ?></span>
</a>
2015-06-14 19:22:13 +00:00
<div class="app-navigation-entry-edit">
2015-06-14 18:57:09 +00:00
<form ng-disabled="isAddingList">
<input id="newList" ng-model="status.newListName" class="edit" type="text" autofocus-on-insert
placeholder="<?php p($l->t('New List')); ?>" ng-keydown="checkListInput($event)" >
<input type="submit" value="" class="action icon-checkmark svg" ng-click="submitNewList($event)">
</form>
</div>
2015-06-11 07:34:38 +00:00
</li>
</ul>
<div id="app-settings" ng-controller="SettingsController">
<div id="app-settings-header">
2015-06-10 21:12:36 +00:00
<button class="settings-button" data-apps-slide-toggle="#app-settings-content">
<span><?php p($l->t('Settings')); ?></span>
</button>
</div>
<div id="app-settings-content">
<ul>
2015-07-12 17:35:18 +00:00
<li>
<label for="startOfWeek"><?php p($l->t('Start of week')); ?></label>
<select id="startOfWeek" ng-change="setStartOfWeek()" ng-model="settingsmodel.getById('various').startOfWeek" ng-options="startOfWeekOption.id as startOfWeekOption.name for startOfWeekOption in startOfWeekOptions"></select>
</li>
<li class="headline">
<?php p($l->t('Visibility of Smart Collections')); ?>
</li>
<li ng-repeat="collection in collections">
<span class="icon collection-{{ collection.id }}"><text ng-show="collection.id=='today'"><?php p($_['DOM']); ?></text></span>
2015-06-11 07:34:38 +00:00
<label for="visibilityCollection-{{collection.id}}" class="title">{{ collection.displayname }}</label>
<select id="visibilityCollection-{{collection.id}}" ng-change="setVisibility(collection.id)" ng-model="collection.show" ng-options="collectionOption.id as collectionOption.name for collectionOption in collectionOptions"></select>
</li>
</ul>
</div>
2014-03-28 19:11:56 +00:00
</div>
</div>
<div id="app-content" ng-controller="TasksController" ng-class="{'details-visible':route.taskID}">
<div class="content-wrapper">
<div id="add-task" class="add-task handler" ng-show="showInput()" ng-class="{'focus':status.focusTaskInput}">
<a class="input-star">
<span class="icon input-star"></span>
</a>
<a class="input-date">
<span class="icon input-date"></span>
</a>
2015-07-19 12:05:29 +00:00
<form ng-submit="addTask(status.taskName)" name="addTaskForm">
<input id="target" ng-disabled="isAddingTask" ng-click="focusTaskInput()" class="transparent" placeholder="{{ getAddString() }}" ng-model="status.taskName"
ng-keydown="checkTaskInput($event)"/>
</form>
</div>
<div class="task-list">
<?php print_unescaped($this->inc('part.tasklist')); ?>
<?php print_unescaped($this->inc('part.collectionall')); ?>
<?php print_unescaped($this->inc('part.collectionweek')); ?>
<div id="searchresults"></div>
2015-02-25 20:14:44 +00:00
<div class="task-item template">
<div class="task-body">
<div class="percentdone"></div>
<a class="task-checkbox" name="toggleCompleted" ng-click="toggleCompleted()">
2015-02-25 20:14:44 +00:00
<span class="icon task-checkbox"></span>
</a>
<a class="icon task-separator"></a>
<a class="task-star" ng-click="toggleStarred(task.id)">
2015-02-25 20:14:44 +00:00
<span class="icon task-star faded"></span>
</a>
<a class="duedate" ng-class="{overdue: TasksModel.overdue(task.due)}">{{ task.due | dateTaskList }}</a>
<div class="title-wrapper">
<span class="title"></span>
<span class="icon task-attachment"></span>
</div>
</div>
</div>
</div>
2014-03-28 19:11:56 +00:00
</div>
2015-02-08 19:13:16 +00:00
<div id="task-details" ng-class="{'details-visible':route.taskID}">
<div class="content-wrapper">
<?php print_unescaped($this->inc('part.details')); ?>
</div>
2014-03-28 19:11:56 +00:00
</div>
</div>
2015-07-19 12:05:29 +00:00
<script type="text/ng-template" id="part.taskbody">
<?php print_unescaped($this->inc('part.taskbody')); ?>
</script>
2015-05-28 15:33:21 +00:00
</div>