* code for task#1657.
This commit is contained in:
+15
-7
@@ -417,16 +417,24 @@ class doc extends control
|
||||
}
|
||||
else
|
||||
{
|
||||
$response['result'] = 'success';
|
||||
$response['message'] = '';
|
||||
|
||||
$this->doc->delete(TABLE_DOC, $docID);
|
||||
if(dao::isError())
|
||||
|
||||
/* if ajax request, send result. */
|
||||
if($this->server->ajax)
|
||||
{
|
||||
$response['result'] = 'fail';
|
||||
$response['message'] = dao::getError();
|
||||
if(dao::isError())
|
||||
{
|
||||
$response['result'] = 'fail';
|
||||
$response['message'] = dao::getError();
|
||||
}
|
||||
else
|
||||
{
|
||||
$response['result'] = 'success';
|
||||
$response['message'] = '';
|
||||
}
|
||||
$this->send($response);
|
||||
}
|
||||
$this->send($response);
|
||||
die(js::locate($this->session->docList, 'parent'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user