Pimcore\Model\Document\Listing::getCondition PHP Method

getCondition() public method

Returns the SQL condition value.
public getCondition ( ) : string
return string
    public function getCondition()
    {
        $condition = parent::getCondition();
        if ($condition) {
            if (Document::doHideUnpublished() && !$this->getUnpublished()) {
                $condition = " (" . $condition . ") AND published = 1";
            }
        } elseif (Document::doHideUnpublished() && !$this->getUnpublished()) {
            $condition = "published = 1";
        }
        return $condition;
    }