* finish task #1419.
This commit is contained in:
@@ -26,7 +26,11 @@
|
||||
<?php echo html::a($this->createLink('todo', 'view', "todoID=$todo->id&from=my"), '#' . $todo->id . ' ' . $todo->name)?>
|
||||
<span class='ui-li-count'>
|
||||
<?php
|
||||
if(empty($todo->begin))
|
||||
if($todo->status == 'done')
|
||||
{
|
||||
echo $lang->todo->finish;
|
||||
}
|
||||
elseif(empty($todo->begin))
|
||||
{
|
||||
echo $lang->todo->lblDisableDate;
|
||||
}
|
||||
|
||||
@@ -329,9 +329,9 @@ class todo extends control
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function import2Today()
|
||||
public function import2Today($todoID = 0)
|
||||
{
|
||||
$todoIDList = $this->post->todoIDList;
|
||||
$todoIDList = $_POST ? $this->post->todoIDList : array($todoID);
|
||||
$today = date::today();
|
||||
$this->dao->update(TABLE_TODO)->set('date')->eq($today)->where('id')->in($todoIDList)->exec();
|
||||
die(js::locate($this->session->todoList));
|
||||
|
||||
@@ -32,6 +32,10 @@
|
||||
$browseLink = $this->createLink('my', 'todo');
|
||||
}
|
||||
if(common::hasPriv('todo', 'finish') and $todo->status != 'done') echo '<li>' . html::a($this->createLink('todo', 'finish', "id=$todo->id"), $lang->todo->finish, 'hiddenwin') . '</li>';
|
||||
if($todo->account == $app->user->account and common::hasPriv('todo', 'import2Today') and $todo->date != date('Ymd'))
|
||||
{
|
||||
echo '<li>' . html::a($this->createLink('todo', 'import2Today', "todoID=$todo->id"), $lang->todo->import2Today, 'hiddenwin') . '</li>';
|
||||
}
|
||||
if($todo->account == $app->user->account and common::hasPriv('todo', 'delete'))
|
||||
{
|
||||
echo '<li>' . html::a($this->createLink('todo', 'delete', "todoID=$todo->id"), $lang->delete, 'hiddenwin') . '</li>';
|
||||
|
||||
Reference in New Issue
Block a user