src/Leevel/Database/Ddd/Select.php
protected function parseWithRelation(array $relation): array
    {
        $arr = [];

        foreach ($relation as $name => $condition) {
            if (is_numeric($name)) {
                list($name, $condition) = [
                    $condition,
                    function () {
                    },
                ];
            }

            $arr = $this->parseNestedWith($name, $arr);

            $arr[$name] = $condition;
        }

        return $arr;
    }
protected function parseWithRelation(array $relation): array
    {
        $arr = [];

        foreach ($relation as $name => $condition) {
            if (is_numeric($name)) {
                list($name, $condition) = [
                    $condition,
                    function () {
                    },
                ];
            }

            $arr = $this->parseNestedWith($name, $arr);

            $arr[$name] = $condition;
        }

        return $arr;
    }
格式化预载入关联.

@param array $relation

@return array