* Fix closeModal js.

This commit is contained in:
Yagami
2019-03-21 13:43:38 +08:00
parent 1523c62182
commit 6aa434a9ca
2 changed files with 1 additions and 21 deletions
+1 -1
View File
@@ -125,7 +125,7 @@ class task extends control
}
/* If link from no head then reload*/
if(isonlybody()) $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'closeModal' => true));
if(isonlybody()) $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'parent'));
if($todoID > 0)
{
-20
View File
@@ -3,26 +3,6 @@ $(function()
{
removeDitto();
if($('#batchCreateForm table thead tr th.c-name').width() < 200) $('#batchCreateForm table thead tr th.c-name').width(200);
$('#batchCreateForm').ajaxForm(
{
finish:function(response)
{
if(response.locate)
{
if(response.locate == 'parent')
{
parent.$.cookie('selfClose', 1);
setTimeout(function(){parent.$.closeModal(null, 'this')}, 1200);
}
else
{
setTimeout(function(){window.location.href = response.locate;}, 1200);
}
}
return false;
}
});
});
/* Get select of stories.*/