1
This commit is contained in:
+1
-2
@@ -612,7 +612,6 @@ abstract class Model extends Component implements ModelInterface, ArrayAccess, T
|
|||||||
*/
|
*/
|
||||||
public function save($data = NULL): static|bool
|
public function save($data = NULL): static|bool
|
||||||
{
|
{
|
||||||
var_dump($this->_attributes);
|
|
||||||
if (!is_null($data)) {
|
if (!is_null($data)) {
|
||||||
$this->_attributes = merge($this->_attributes, $data);
|
$this->_attributes = merge($this->_attributes, $data);
|
||||||
}
|
}
|
||||||
@@ -652,7 +651,7 @@ abstract class Model extends Component implements ModelInterface, ArrayAccess, T
|
|||||||
private function resolve($rule): Validator
|
private function resolve($rule): Validator
|
||||||
{
|
{
|
||||||
$validate = Validator::getInstance();
|
$validate = Validator::getInstance();
|
||||||
$validate->setParams($this->getAttributes());
|
$validate->setParams($this->_attributes);
|
||||||
$validate->setModel($this);
|
$validate->setModel($this);
|
||||||
foreach ($rule as $val) {
|
foreach ($rule as $val) {
|
||||||
$field = array_shift($val);
|
$field = array_shift($val);
|
||||||
|
|||||||
Reference in New Issue
Block a user