mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-01 20:52:48 +08:00
改进Model类的destroy方法
This commit is contained in:
@@ -565,14 +565,13 @@ abstract class Model implements \JsonSerializable, \ArrayAccess
|
||||
$data = [];
|
||||
}
|
||||
$resultSet = $db->select($data);
|
||||
$result = false;
|
||||
if ($resultSet) {
|
||||
foreach ($resultSet as $data) {
|
||||
$result = $data->delete();
|
||||
}
|
||||
return $result;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user