where( 'post_type', fluentcrmTemplateCPTSlug() )->whereIn('post_status', $types); } public function scopeCampaignTemplate($query) { return $query->where( 'post_type', fluentcrmCampaignTemplateCPTSlug() )->where('post_status', 'publish'); } public function campaign() { return $this->hasOne(__NAMESPACE__.'\\'.'Campaign', 'template_id', 'ID'); } public function render($content = null) { $content = $content ?: $this->post_content; return Parser::parse($content, []); } }