* Add api for close bug and confirm bug.

This commit is contained in:
zhengrunyu
2022-03-30 10:01:28 +08:00
committed by hufangzhou
parent 1bc250a4b3
commit c047d2b422
6 changed files with 94 additions and 4 deletions
+9 -2
View File
@@ -1259,7 +1259,14 @@ class bug extends control
return print(js::closeModal('parent.parent'));
}
}
return print(js::locate($this->createLink('bug', 'view', "bugID=$bugID"), 'parent'));
if(defined('RUN_MODE') && RUN_MODE == 'api')
{
return $this->send(array('status' => 'success', 'data' => $bugID));
}
else
{
return print(js::locate($this->createLink('bug', 'view', "bugID=$bugID"), 'parent'));
}
}
if($this->app->tab == 'project')
@@ -1710,7 +1717,7 @@ class bug extends control
}
if(defined('RUN_MODE') && RUN_MODE == 'api')
{
return print(array('status' => 'success', 'data' => $bugID));
return $this->send(array('status' => 'success', 'data' => $bugID));
}
else
{