* zin: add more commands for query.

This commit is contained in:
sunhao
2024-02-28 09:17:17 +08:00
parent ab11c64529
commit 44fc56f686
4 changed files with 43 additions and 32 deletions
+2 -1
View File
@@ -390,7 +390,8 @@ class context extends \zin\utils\dataset
list($method, $args) = $command;
foreach($queryNodes as $queryNode)
{
$result = call_user_func("\zin\command::{$method}", $queryNode, $args, $this->rootNode);
$queryNode->rootNode = $this->rootNode;
$result = call_user_func("\zin\command::{$method}", $queryNode, ...$args);
if($result instanceof node) $queryNodes = array($result);
else if(is_array($result)) $queryNodes = $result;
}