* Add id for checking unique field.

This commit is contained in:
daitingting
2022-05-09 17:02:23 +08:00
committed by wangyuting2
parent a607161591
commit d577d57a33
16 changed files with 73 additions and 6 deletions
+3
View File
@@ -715,6 +715,7 @@ class testcaseModel extends model
$version = $stepChanged ? $oldCase->version + 1 : $oldCase->version;
$case = fixer::input('post')
->add('id', $caseID)
->add('version', $version)
->setIF($this->post->story != false and $this->post->story != $oldCase->story, 'storyVersion', $this->loadModel('story')->getVersion($this->post->story))
->setIF(!$this->post->linkCase, 'linkCase', '')
@@ -835,6 +836,7 @@ class testcaseModel extends model
$now = helper::now();
$status = $this->getStatus('review', $oldCase);
$case = fixer::input('post')
->add('id', $caseID)
->remove('result,comment')
->setDefault('reviewedDate', substr($now, 0, 10))
->setDefault('lastEditedBy', $this->app->user->account)
@@ -947,6 +949,7 @@ class testcaseModel extends model
foreach($caseIDList as $caseID)
{
$case = new stdclass();
$case->id = $caseID;
$case->lastEditedBy = $this->app->user->account;
$case->lastEditedDate = $now;
$case->pri = $data->pris[$caseID];