Skip to content
Snippets Groups Projects
Commit 28e4941d authored by Ludovic Ganée's avatar Ludovic Ganée
Browse files

ajout du databaseDeleteAll dans mink

parent 955f37ed
No related branches found
No related tags found
No related merge requests found
Pipeline #56911 failed
......@@ -94,4 +94,17 @@ trait MinkCaseDatabaseTrait
}
return $count;
}
/**
* delete all $modelName where $conditions
* @param string $modelName
* @param array $conditions
* @return int delete count
* @throw RecordNotFoundException
*/
protected function databaseDeleteAll(string $modelName, array $conditions = []): int
{
$model = $this->databaseGetModel($modelName);
return $model->deleteAll($conditions);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment