Revert "改名"

This reverts commit fdf58326
This commit is contained in:
2022-01-19 14:57:14 +08:00
parent d5b58a1fc7
commit d42fc588b4
6 changed files with 11 additions and 14 deletions
+1 -1
View File
@@ -135,7 +135,7 @@ class ActiveQuery extends Component implements ISqlBuilder
$name = explode(',', $name);
}
foreach ($name as $val) {
array_push($this->with, $val);
$this->with[] = $val;
}
return $this;
}
+1 -1
View File
@@ -18,7 +18,7 @@ abstract class Condition extends Component
protected string $opera = '=';
/** @var array|mixed */
protected $value;
protected mixed $value;
const INT_TYPE = ['bit', 'bool', 'tinyint', 'smallint', 'mediumint', 'int', 'bigint', 'float', 'double', 'decimal', 'timestamp'];
+2 -2
View File
@@ -17,9 +17,9 @@ class HasCount extends HasBase
* @param $name
* @param $arguments
* @return ActiveQuery
* @throws Exception
* @throws ActiveQuery|static
*/
public function __call($name, $arguments): mixed
public function __call($name, $arguments)
{
if (method_exists($this, $name)) {
return call_user_func([$this, $name], ...$arguments);
+2 -2
View File
@@ -23,9 +23,9 @@ class HasMany extends HasBase
/**
* @param $name
* @param $arguments
* @return ActiveQuery
* @return ActiveQuery|static
*/
public function __call($name, $arguments): mixed
public function __call($name, $arguments)
{
if (method_exists($this, $name)) {
return call_user_func([$this, $name], ...$arguments);
+3 -3
View File
@@ -9,8 +9,8 @@ declare(strict_types=1);
namespace Database;
use Exception;
use Database\Traits\HasBase;
use Exception;
/**
* Class HasOne
@@ -23,9 +23,9 @@ class HasOne extends HasBase
/**
* @param $name
* @param $arguments
* @return ActiveQuery
* @return ActiveQuery|static
*/
public function __call($name, $arguments): mixed
public function __call($name, $arguments)
{
if (method_exists($this, $name)) {
return call_user_func([$this, $name], ...$arguments);
+2 -5
View File
@@ -39,9 +39,6 @@ class PDO implements StopHeartbeatCheck
public int $read_timeout;
private EventProvider $eventProvider;
public array $attributes = [];
@@ -67,8 +64,8 @@ class PDO implements StopHeartbeatCheck
public function init(): void
{
$this->heartbeat_check();
$this->eventProvider = Kiri::getDi()->get(EventProvider::class);
$this->eventProvider->on(OnWorkerExit::class, [$this, 'onWorkerExit']);
$eventProvider = Kiri::getDi()->get(EventProvider::class);
$eventProvider->on(OnWorkerExit::class, [$this, 'onWorkerExit']);
}