src/Leevel/Database/Condition.php
public function time(string $type = 'date'): self
    {
        if ($this->checkFlowControl()) {
            return $this;
        }

        if (!in_array($type, ['date', 'month', 'day', 'year'], true)) {
            throw new InvalidArgumentException(
                sprintf('Time type `%s` is invalid.', $type)
            );
        }

        $this->setInTimeCondition($type);

        return $this;
    }
public function time(string $type = 'date'): self
    {
        if ($this->checkFlowControl()) {
            return $this;
        }

        if (!in_array($type, ['date', 'month', 'day', 'year'], true)) {
            throw new InvalidArgumentException(
                sprintf('Time type `%s` is invalid.', $type)
            );
        }

        $this->setInTimeCondition($type);

        return $this;
    }
时间控制语句开始.

@param string $type

@return $this