setIcon('piercing') ->make([ 'rewrite' => [ 'slug' => 'piercings', 'with_front' => false, ], 'taxonomies' => [ 'city', 'piercing_placement', 'piercing_style', ], ]) ->setAll([ 'show_directory', 'hide_single', 'redirect_to_author', 'favouritable', 'karma', 'show_feed' ]) ->setIntegration('facebook') ->setIntegration('instagram'); //$directory = $piercing->getConfig('directory'); } function aei_piercing_fields():void { if (!class_exists('JVBase\registrar\Registrar')) { return; } $piercing = Registrar::getInstance('piercing'); // $breadcrumbs = $piercing->config('breadcrumbs'); // $breadcrumbs->setCrumb('section'); $fields = $piercing->fields(); $fields->modifyField('post_thumbnail', 'label', 'Main Image'); $fields->modifyField('post_content', 'label', 'Notes (optional)'); $fields->addField('gallery', [ 'type' => 'upload', 'label' => 'Additional Images', ]); $fields->addField('piercing_placement', [ 'type' => 'selector', 'subtype' => 'taxonomy', 'taxonomy' => 'piercing_placement', 'label' => 'Placement', ]); $fields->addField('piercing_style', [ 'type' => 'selector', 'subtype' => 'taxonomy', 'taxonomy' => 'piercing_style', 'label' => 'Piercing Style', ]); } function aei_piercing_schema():array { return [ 'type' => 'JVBase\managers\SEO\render\Thing\CreativeWork\VisualArtwork', 'name' => '{{post_title}} | by {{post_author.name}} {{post_author.city}} Piercer', ]; } function aei_piercing_meta():array { return[ 'name' => '{{post_title}} | by {{post_author.name}} {{post_author.city}} Piercer', 'description' => '{{style}} {{colour}} {{theme}} piercing in {{post_author.city}}.', ]; } function aei_piercing_archive(array $defaults):array { return array_merge($defaults, [ 'name' => 'Edmonton\'s Best Piercings', 'description' => 'Piercings in Edmonton, Alberta.' ]); } function aei_piercing_reference_schema(array $defaults):array { return $defaults; }