* testcase: refactor the method to batch confirm story change of cases.

This commit is contained in:
liugang
2023-08-14 15:09:14 +08:00
parent 35057ad37c
commit 638086ba6b
+5 -4
View File
@@ -1685,10 +1685,11 @@ class testcase extends control
*/
public function batchConfirmStoryChange($productID = 0)
{
if(!$this->post->caseIDList) return print(js::locate($this->session->caseList));
$caseIDList = array_unique($this->post->caseIDList);
foreach($caseIDList as $caseID) $this->confirmStoryChange($caseID,false);
if($this->post->caseIDList)
{
$caseIDList = $this->testcase->filterIdList($this->post->caseIDList);
foreach($caseIDList as $caseID) $this->confirmStoryChange($caseID,false);
}
echo js::locate($this->session->caseList);
}