Sleimanx2\Plastic\Searchable::getDocumentType PHP Method

getDocumentType() public method

Get the model elastic type.
public getDocumentType ( ) : string
return string
    public function getDocumentType()
    {
        // if the type is defined use it else return the table name
        if (isset($this->documentType) and !empty($this->documentType)) {
            return $this->documentType;
        }
        return $this->getTable();
    }