Initial Commit

This commit is contained in:
khaccount committed 2026-05-18 14:46:25 +02:00
1 parent 4f495177e4
commit b6d2142214
166 files changed
+13952 -178

No files matched your search

@@ -0,0 +1,29 @@
<?php
namespace Evomedien\Vitec\Domain\Model;
use TYPO3\CMS\Extbase\Domain\Model\Category as ExtbaseCategory;
class Category extends ExtbaseCategory
{
/**
* @var string
*/
protected $class = '';
/**
* @return string
*/
public function getClass(): string
{
return $this->class;
}
/**
* @param string $class
*/
public function setClass(string $class): void
{
$this->class = $class;
}
}
@@ -0,0 +1,55 @@
<?php
namespace Evomedien\Vitec\Domain\Model;
use TYPO3\CMS\Extbase\DomainObject\AbstractEntity;
class Download extends AbstractEntity
{
/**
* @var string
*/
protected $title = '';
/**
* @var string
*/
protected $slug = '';
/* ----------------------------------------------------*/
/**
* @return string
*/
public function getTitle(): string
{
return $this->title;
}
/**
* @param string $title
*/
public function setTitle(string $title): void
{
$this->title = $title;
}
/**
* @return string
*/
public function getSlug(): string
{
return $this->slug;
}
/**
* @param string $slug
*/
public function setSlug(string $slug): void
{
$this->slug = $slug;
}
/* ----------------------------------------------------*/
}
@@ -0,0 +1,80 @@
<?php
declare(strict_types=1);
namespace Evomedien\Vitec\Domain\Model\Dto;
/**
* DTO for Product List Content Element in JSON output
*/
class ProductListContentElement implements \JsonSerializable
{
protected array $products = [];
protected array $settings = [];
public function setProducts(array $products): void
{
$this->products = $products;
}
public function setSettings(array $settings): void
{
$this->settings = $settings;
}
public function jsonSerialize(): array
{
$productsData = [];
foreach ($this->products as $product) {
$productsData[] = [
'uid' => $product->getUid(),
'title' => $product->getTitle(),
'subtitle' => $product->getSubtitle(),
'teaser' => $product->getTeaser(),
'description' => $product->getDescription(),
'slug' => $product->getSlug(),
'categories' => $this->serializeCategories($product->getCategories()),
'image' => $this->serializeImage($product->getProductimage()),
];
}
return [
'products' => $productsData,
'settings' => $this->settings,
];
}
protected function serializeCategories($categories): array
{
$categoriesData = [];
if ($categories) {
foreach ($categories as $category) {
$categoriesData[] = [
'uid' => $category->getUid(),
'title' => $category->getTitle(),
];
}
}
return $categoriesData;
}
protected function serializeImage($images): ?array
{
if (!$images || $images->count() === 0) {
return null;
}
$imageObject = $images->current();
return [
'uid' => $imageObject->getUid(),
'url' => $imageObject->getOriginalResource()->getPublicUrl(),
'title' => $imageObject->getTitle(),
'alternative' => $imageObject->getAlternative(),
'description' => $imageObject->getDescription(),
];
}
}
@@ -0,0 +1,163 @@
<?php
namespace Evomedien\Vitec\Domain\Model;
use TYPO3\CMS\Extbase\Domain\Model\Category;
use TYPO3\CMS\Extbase\DomainObject\AbstractEntity;
use TYPO3\CMS\Extbase\Persistence\ObjectStorage;
class Market extends AbstractEntity
{
/**
* @var string
*/
protected $title = '';
/**
* @var string
*/
protected $subtitle = '';
/**
* @var string
*/
protected $teaser = '';
/**
* @var string
*/
protected $description = '';
/**
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade("remove")
*/
protected $image = null;
/**
* @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\TYPO3\CMS\Extbase\Domain\Model\Category>
* @TYPO3\CMS\Extbase\Annotation\ORM\Lazy
*/
protected $categories;
public function __construct()
{
$this->categories = new ObjectStorage();
}
/* ---------------------------------------------- */
/* Getter und Setter */
/* ---------------------------------------------- */
/**
* @return string
*/
public function getTitle(): string
{
return $this->title;
}
/**
* @param string $title
*/
public function setTitle(string $title): void
{
$this->title = $title;
}
/**
* @return string
*/
public function getSubtitle(): string
{
return $this->subtitle;
}
/**
* @param string $subtitle
*/
public function setSubtitle(string $subtitle): void
{
$this->subtitle = $subtitle;
}
/**
* @return string
*/
public function getTeaser(): string
{
return $this->teaser;
}
/**
* @param string $teaser
*/
public function setTeaser(string $teaser): void
{
$this->teaser = $teaser;
}
/**
* @return string
*/
public function getDescription(): string
{
return $this->description;
}
/**
* @param string $description
*/
public function setDescription(string $description): void
{
$this->description = $description;
}
/**
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference|null
*/
public function getImage()
{
return $this->image;
}
/**
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $image
*/
public function setImage(\TYPO3\CMS\Extbase\Domain\Model\FileReference $image): void
{
$this->image = $image;
}
/**
* @param Category $category
*/
public function addCategory(Category $category): void
{
$this->categories->attach($category);
}
/**
* @param Category $categoryToRemove
*/
public function removeCategory(Category $categoryToRemove): void
{
$this->categories->detach($categoryToRemove);
}
/**
* @return ObjectStorage<Category>
*/
public function getCategories(): ObjectStorage
{
return $this->categories;
}
/**
* @param ObjectStorage<Category> $categories
*/
public function setCategories(ObjectStorage $categories): void
{
$this->categories = $categories;
}
}
@@ -0,0 +1,922 @@
<?php
declare(strict_types=1);
namespace Evomedien\Vitec\Domain\Model;
use TYPO3\CMS\Extbase\Persistence\ObjectStorage;
use TYPO3\CMS\Extbase\Domain\Model\Category;
use TYPO3\CMS\Extbase\Domain\Model\FileReference;
/**
* This file is part of the "VITEC" Extension for TYPO3 CMS.
*
* For the full copyright and license information, please read the
* LICENSE.txt file that was distributed with this source code.
*
* (c) 2025
*/
/**
* Product
*/
class Product extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
{
/**
* title
*
* @var string
* @TYPO3\CMS\Extbase\Annotation\Validate("NotEmpty")
*/
protected $title;
/**
* slug
*
* @var string
*/
protected $slug;
/**
* urltitle
*
* @var string
*/
protected $urltitle = '';
/**
* seotitle
*
* @var string
*/
protected $seotitle = '';
/**
* seometa
*
* @var string
*/
protected $seometa = '';
/**
* keywords
*
* @var string
*/
protected $keywords = '';
/**
* structureddata
*
* @var string
*/
protected $structureddata = '';
/**
* teaser
*
* @var string
*/
protected $teaser = '';
/**
* subtitle
*
* @var string
*/
protected $subtitle = '';
/**
* video
*
* @var string
*/
protected $video = '';
/**
* hideonapp
*
* @var bool
*/
protected $hideonapp = false;
/**
* hideonwebsite
*
* @var bool
*/
protected $hideonwebsite = false;
/**
* hideondatasheets
*
* @var bool
*/
protected $hideondatasheets = false;
/**
* hideonproducts
*
* @var bool
*/
protected $hideonproducts = false;
/**
* applications
*
* @var string
*/
protected $applications = '';
/**
* description
*
* @var string
*/
protected $description = '';
/**
* highlights
*
* @var string
*/
protected $highlights = '';
/**
* shortcut
*
* @var bool
*/
protected $shortcut = false;
/**
* shortcutpid
*
* @var string
*/
protected $shortcutpid = '';
/**
* legacy
*
* @var bool
*/
protected $legacy = false;
/**
* supportproduct
*
* @var bool
*/
protected $supportproduct = false;
/**
* subproduct
*
* @var bool
*/
protected $subproduct = false;
/**
* @var ObjectStorage<Category>
*/
protected $categories;
/**
* Product images
*
* @var ObjectStorage<FileReference>
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade("remove")
*/
protected $productimage;
/**
* Downloads
*
* @var ObjectStorage<\Evomedien\Vitec\Domain\Model\Download>
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade("remove")
*/
protected $downloads;
/**
* Open Graph Image
*
* @var FileReference
*/
protected $ogimage;
/**
* Content element link - Key Features
*
* @var string
*/
protected $contentelement;
/**
* Content element link - CTA Features
*
* @var string
*/
protected $contentelementcta;
/**
* @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\Evomedien\Vitec\Domain\Model\Product>
* @TYPO3\CMS\Extbase\Annotation\ORM\Lazy
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade("remove")
*/
protected $relatedprodukt;
/* --------------------------------------------------------------------- */
/**
* Returns the title
*
* @return string
*/
public function getTitle()
{
return $this->title;
}
/**
* Sets the title
*
* @param string $title
* @return void
*/
public function setTitle(string $title)
{
$this->title = $title;
}
/**
* Returns the video
*
* @return string
*/
public function getVideo()
{
return $this->video;
}
/**
* Sets the video
*
* @param string $video
* @return void
*/
public function setVideo(string $video)
{
$this->video = $video;
}
/**
* Returns the slug
*
* @return string
*/
public function getSlug()
{
return $this->slug;
}
/**
* Sets the slug
*
* @param string $slug
* @return void
*/
public function setSlug(string $slug)
{
$this->slug = $slug;
}
/**
* Returns the urltitle
*
* @return string
*/
public function getUrltitle()
{
return $this->urltitle;
}
/**
* Sets the urltitle
*
* @param string $urltitle
* @return void
*/
public function setUrltitle(string $urltitle)
{
$this->urltitle = $urltitle;
}
/**
* Returns the seotitle
*
* @return string
*/
public function getSeotitle()
{
return $this->seotitle;
}
/**
* Sets the seotitle
*
* @param string $seotitle
* @return void
*/
public function setSeotitle(string $seotitle)
{
$this->seotitle = $seotitle;
}
/**
* Returns the seometa
*
* @return string $seometa
*/
public function getSeometa()
{
return $this->seometa;
}
/**
* Sets the seometa
*
* @param string $seometa
* @return void
*/
public function setSeometa($seometa)
{
$this->seometa = $seometa;
}
/**
* Returns the keywords
*
* @return string $keywords
*/
public function getKeywords()
{
return $this->keywords;
}
/**
* Sets the keywords
*
* @param string $keywords
* @return void
*/
public function setKeywords($keywords)
{
$this->keywords = $keywords;
}
/**
* Returns the teaser
*
* @return string $kteasereywords
*/
public function getTeaser()
{
return $this->teaser;
}
/**
* Sets the teaser
*
* @param string $teaser
* @return void
*/
public function setTeaser($teaser)
{
$this->teaser = $teaser;
}
/**
* Returns the subtitle
*
* @return string $subtitle
*/
public function getSubtitle()
{
return $this->subtitle;
}
/**
* Sets the subtitle
*
* @param string $subtitle
* @return void
*/
public function setSubtitle($subtitle)
{
$this->subtitle = $subtitle;
}
/**
* Returns the hideonapp
*
* @return bool $hideonapp
*/
public function getHideonapp()
{
return $this->hideonapp;
}
/**
* Sets the hideonapp
*
* @param bool $hideonapp
* @return void
*/
public function setHideonapp($hideonapp)
{
$this->hideonapp = $hideonapp;
}
/**
* Returns the description
*
* @return bool $description
*/
public function getDescription()
{
return $this->description;
}
/**
* Sets the description
*
* @param bool $description
* @return void
*/
public function setDescriptionp($description)
{
$this->description = $description;
}
/**
* Returns the hideonwebsite
*
* @return bool $hideonwebsite
*/
public function getHideonwebsite()
{
return $this->hideonwebsite;
}
/**
* Sets the hideonwebsite
*
* @param bool $hideonwebsite
* @return void
*/
public function setHideonwebsite($hideonwebsite)
{
$this->hideonwebsite = $hideonwebsite;
}
/**
* Returns the hideondatasheets
*
* @return bool $hideondatasheets
*/
public function getHideondatasheets()
{
return $this->hideondatasheets;
}
/**
* Sets the hideondatasheets
*
* @param bool $hideondatasheets
* @return void
*/
public function setHideondatasheets($hideondatasheets)
{
$this->hideondatasheets = $hideondatasheets;
}
/**
* Returns the hideonproducts
*
* @return bool $hideonproducts
*/
public function getHideonproducts()
{
return $this->hideonproducts;
}
/**
* Sets the hideonproducts
*
* @param bool $hideonproducts
* @return void
*/
public function setHideonproducts($hideonproducts)
{
$this->hideonproducts = $hideonproducts;
}
/**
* Returns the structureddata
*
* @return string $structureddata
*/
public function getStructureddata()
{
return $this->structureddata;
}
/**
* Sets the structureddata
*
* @param string $structureddata
* @return void
*/
public function setStructureddata($structureddata)
{
$this->structureddata = $structureddata;
}
/**
* Returns the applications
*
* @return string $applications
*/
public function getApplications()
{
return $this->applications;
}
/**
* Sets the applications
*
* @param string $applications
* @return void
*/
public function setApplications($applications)
{
$this->applications = $applications;
}
/**
* Returns the highlights
*
* @return string $highlights
*/
public function getHighlights()
{
return $this->highlights;
}
/**
* Sets the highlights
*
* @param string $highlights
* @return void
*/
public function setHighlights($highlights)
{
$this->highlights = $highlights;
}
/**
* Returns the shortcutpid
*
* @return string
*/
public function getShortcutpid()
{
return $this->shortcutpid;
}
/**
* Sets the shortcutpid
*
* @param string $shortcutpid
* @return void
*/
public function setShortcutpid ($shortcutpid)
{
$this->shortcutpid = $shortcutpid;
}
/**
* Returns the shortcut
*
* @return bool $shortcut
*/
public function getShortcut()
{
return $this->shortcut;
}
/**
* Sets the shortcut
*
* @param bool $shortcut
* @return void
*/
public function setShortcut($shortcut)
{
$this->shortcut = $shortcut;
}
/**
* Returns the legacy
*
* @return bool $legacy
*/
public function getLegacy()
{
return $this->legacy;
}
/**
* Sets the legacy
*
* @param bool $legacy
* @return void
*/
public function setLegacy($legacy)
{
$this->legacy = $legacy;
}
/**
* Returns the supportproduct
*
* @return bool $supportproduct
*/
public function getSupportproduct()
{
return $this->supportproduct;
}
/**
* Sets the supportproduct
*
* @param bool $supportproduct
* @return void
*/
public function setSupportproduct($supportproduct)
{
$this->supportproduct = $supportproduct;
}
/**
* Returns the subproduct
*
* @return bool $subproduct
*/
public function getSubproduct()
{
return $this->subproduct;
}
/**
* Sets the subproduct
*
* @param bool $subproduct
* @return void
*/
public function setSubproduct($subproduct)
{
$this->subproduct = $subproduct;
}
/**
* Initializes the ObjectStorage for categories
*/
public function __construct()
{
$this->categories = new ObjectStorage();
$this->productimage = new ObjectStorage();
$this->downloads = new ObjectStorage();
}
/**
* Adds a category
*
* @param Category $category
* @return void
*/
public function addCategory(Category $category)
{
$this->categories->attach($category);
}
/**
* Removes a category
*
* @param Category $categoryToRemove
* @return void
*/
public function removeCategory(Category $categoryToRemove)
{
$this->categories->detach($categoryToRemove);
}
/**
* Returns the categories
*
* @return ObjectStorage<Category>
*/
public function getCategories()
{
return $this->categories;
}
/**
* Sets the categories
*
* @param ObjectStorage<Category> $categories
* @return void
*/
public function setCategories(ObjectStorage $categories)
{
$this->categories = $categories;
}
/**
* Adds a product image
*
* @param FileReference $productimage
* @return void
*/
public function addProductimage(FileReference $productimage)
{
$this->productimage->attach($productimage);
}
/**
* Removes a product image
*
* @param FileReference $productimageToRemove
* @return void
*/
public function removeProductimage(FileReference $productimageToRemove)
{
$this->productimage->detach($productimageToRemove);
}
/**
* Returns the product images
*
* @return ObjectStorage<FileReference>
*/
public function getProductimage()
{
return $this->productimage;
}
/**
* Sets the product images
*
* @param ObjectStorage<FileReference> $productimage
* @return void
*/
public function setProductimage(ObjectStorage $productimage)
{
$this->productimage = $productimage;
}
/**
* Adds a download
*
* @param \Evomedien\Vitec\Domain\Model\Download $download
* @return void
*/
public function addDownload(\Evomedien\Vitec\Domain\Model\Download $download): void
{
$this->downloads->attach($download);
}
/**
* Removes a download
*
* @param \Evomedien\Vitec\Domain\Model\Download $downloadToRemove
* @return void
*/
public function removeDownload(\Evomedien\Vitec\Domain\Model\Download $downloadToRemove): void
{
$this->downloads->detach($downloadToRemove);
}
/**
* Returns the downloads
*
* @return ObjectStorage<\Evomedien\Vitec\Domain\Model\Download>
*/
public function getDownloads(): ObjectStorage
{
return $this->downloads;
}
/**
* Sets the downloads
*
* @param ObjectStorage<\Evomedien\Vitec\Domain\Model\Download> $downloads
* @return void
*/
public function setDownloads(ObjectStorage $downloads): void
{
$this->downloads = $downloads;
}
/**
* Returns the Open Graph Image
*
* @return FileReference|null
*/
public function getOgimage(): ?FileReference
{
return $this->ogimage;
}
/**
* Sets the Open Graph Image
*
* @param FileReference $ogimage
* @return void
*/
public function setOgimage(FileReference $ogimage): void
{
$this->ogimage = $ogimage;
}
/**
* Returns the content element link
*
* @return string
*/
public function getContentelement(): string
{
return $this->contentelement;
}
/**
* Sets the content element link
*
* @param string $contentelement
* @return void
*/
public function setContentelement(string $contentelement): void
{
$this->contentelement = $contentelement;
}
/**
* Returns the content element cta link
*
* @return string
*/
public function getContentelementcta(): string
{
return $this->contentelementcta;
}
/**
* Sets the content element link cta
*
* @param string $contentelementcta
* @return void
*/
public function setContentelementcta(string $contentelementcta): void
{
$this->contentelementcta = $contentelementcta;
}
/**
* @return \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\Vendor\Extension\Domain\Model\Product>
*/
public function getRelatedprodukt(): \TYPO3\CMS\Extbase\Persistence\ObjectStorage
{
return $this->relatedprodukt;
}
/**
* @param \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\Vendor\Extension\Domain\Model\Product> $relatedprodukt
*/
public function setRelatedprodukt(\TYPO3\CMS\Extbase\Persistence\ObjectStorage $relatedprodukt): void
{
$this->relatedprodukt = $relatedprodukt;
}
/* --------------------------------------------------------------------- */
}
@@ -0,0 +1,163 @@
<?php
namespace Evomedien\Vitec\Domain\Model;
use TYPO3\CMS\Extbase\Domain\Model\Category;
use TYPO3\CMS\Extbase\DomainObject\AbstractEntity;
use TYPO3\CMS\Extbase\Persistence\ObjectStorage;
class Solution extends AbstractEntity
{
/**
* @var string
*/
protected $title = '';
/**
* @var string
*/
protected $subtitle = '';
/**
* @var string
*/
protected $teaser = '';
/**
* @var string
*/
protected $description = '';
/**
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade("remove")
*/
protected $image = null;
/**
* @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\TYPO3\CMS\Extbase\Domain\Model\Category>
* @TYPO3\CMS\Extbase\Annotation\ORM\Lazy
*/
protected $categories;
public function __construct()
{
$this->categories = new ObjectStorage();
}
/* ---------------------------------------------- */
/* Getter und Setter */
/* ---------------------------------------------- */
/**
* @return string
*/
public function getTitle(): string
{
return $this->title;
}
/**
* @param string $title
*/
public function setTitle(string $title): void
{
$this->title = $title;
}
/**
* @return string
*/
public function getSubtitle(): string
{
return $this->subtitle;
}
/**
* @param string $subtitle
*/
public function setSubtitle(string $subtitle): void
{
$this->subtitle = $subtitle;
}
/**
* @return string
*/
public function getTeaser(): string
{
return $this->teaser;
}
/**
* @param string $teaser
*/
public function setTeaser(string $teaser): void
{
$this->teaser = $teaser;
}
/**
* @return string
*/
public function getDescription(): string
{
return $this->description;
}
/**
* @param string $description
*/
public function setDescription(string $description): void
{
$this->description = $description;
}
/**
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference|null
*/
public function getImage()
{
return $this->image;
}
/**
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $image
*/
public function setImage(\TYPO3\CMS\Extbase\Domain\Model\FileReference $image): void
{
$this->image = $image;
}
/**
* @param Category $category
*/
public function addCategory(Category $category): void
{
$this->categories->attach($category);
}
/**
* @param Category $categoryToRemove
*/
public function removeCategory(Category $categoryToRemove): void
{
$this->categories->detach($categoryToRemove);
}
/**
* @return ObjectStorage<Category>
*/
public function getCategories(): ObjectStorage
{
return $this->categories;
}
/**
* @param ObjectStorage<Category> $categories
*/
public function setCategories(ObjectStorage $categories): void
{
$this->categories = $categories;
}
}
@@ -0,0 +1,335 @@
<?php
namespace Evomedien\Vitec\Domain\Model;
use TYPO3\CMS\Extbase\Domain\Model\Category;
use TYPO3\CMS\Extbase\DomainObject\AbstractEntity;
use TYPO3\CMS\Extbase\Persistence\ObjectStorage;
class Usecase extends AbstractEntity
{
/**
* @var string
*/
protected $title = '';
/**
* @var string
*/
protected $slug = '';
/**
* subtitle
*
* @var string
*/
protected $subtitle = '';
/**
* teaser
*
* @var string
*/
protected $teaser = '';
/**
* hideonapp
*
* @var bool
*/
protected $hideonapp = false;
/**
* hideonwebsite
*
* @var bool
*/
protected $hideonwebsite = false;
/**
* description
*
* @var string
*/
protected $description = '';
/**
* @var string
*/
protected $singlepid = '';
/**
* caseimage
*
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade
*/
protected $caseimage = '';
/**
* logoimage
*
* @var \TYPO3\CMS\Extbase\Domain\Model\FileReference
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade
*/
protected $logoimage = null;
/**
* @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\TYPO3\CMS\Extbase\Domain\Model\Category>
* @TYPO3\CMS\Extbase\Annotation\ORM\Cascade("remove")
*/
protected $categories;
/* ---------------------------------------------- */
/* Getter und Setter */
/* ---------------------------------------------- */
/**
* @return string
*/
public function getTitle(): string
{
return $this->title;
}
/**
* @param string $title
*/
public function setTitle(string $title): void
{
$this->title = $title;
}
/**
* @return string
*/
public function getSlug(): string
{
return $this->slug;
}
/**
* @param string $slug
*/
public function setSlug(string $slug): void
{
$this->slug = $slug;
}
/**
* @return string
*/
public function getSinglepid(): string
{
return $this->singlepid;
}
/**
* @param string $singlepid
*/
public function setSinglepid(string $singlepid): void
{
$this->singlepid = $singlepid;
}
/**
* Returns the teaser
*
* @return string $kteasereywords
*/
public function getTeaser()
{
return $this->teaser;
}
/**
* Sets the teaser
*
* @param string $teaser
* @return void
*/
public function setTeaser($teaser)
{
$this->teaser = $teaser;
}
/**
* Returns the subtitle
*
* @return string $subtitle
*/
public function getSubtitle()
{
return $this->subtitle;
}
/**
* Sets the subtitle
*
* @param string $subtitle
* @return void
*/
public function setSubtitle($subtitle)
{
$this->subtitle = $subtitle;
}
/**
* Returns the hideonapp
*
* @return bool $hideonapp
*/
public function getHideonapp()
{
return $this->hideonapp;
}
/**
* Sets the hideonapp
*
* @param bool $hideonapp
* @return void
*/
public function setHideonapp($hideonapp)
{
$this->hideonapp = $hideonapp;
}
/**
* Returns the hideonwebsite
*
* @return bool $hideonwebsite
*/
public function getHideonwebsite()
{
return $this->hideonwebsite;
}
/**
* Sets the hideonwebsite
*
* @param bool $hideonwebsite
* @return void
*/
public function setHideonwebsite($hideonwebsite)
{
$this->hideonwebsite = $hideonwebsite;
}
/**
* Returns the description
*
* @return string $description
*/
public function getDescription()
{
return $this->description;
}
/**
* Sets the description
*
* @param string $description
* @return void
*/
public function setDescription($description)
{
$this->description = $description;
}
/**
* Returns the caseimage
*
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference $caseimage
*/
public function getCaseimage()
{
return $this->caseimage;
}
/**
* Sets the caseimage
*
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $caseimage
* @return void
*/
public function setCaseimage(\TYPO3\CMS\Extbase\Domain\Model\FileReference $caseimage)
{
$this->caseimage = $caseimage;
}
/**
* Returns the logoimage
*
* @return \TYPO3\CMS\Extbase\Domain\Model\FileReference $logoimage
*/
public function getLogoimage()
{
return $this->logoimage;
}
/**
* Sets the logoimage
*
* @param \TYPO3\CMS\Extbase\Domain\Model\FileReference $logoimage
* @return void
*/
public function setLogoimage(\TYPO3\CMS\Extbase\Domain\Model\FileReference $logoimage)
{
$this->logoimage = $logoimage;
}
/**
* Initializes the ObjectStorage for categories
*/
public function __construct()
{
$this->categories = new ObjectStorage();
$this->productimage = new ObjectStorage();
$this->downloads = new ObjectStorage();
}
/**
* Adds a category
*
* @param Category $category
* @return void
*/
public function addCategory(Category $category)
{
$this->categories->attach($category);
}
/**
* Removes a category
*
* @param Category $categoryToRemove
* @return void
*/
public function removeCategory(Category $categoryToRemove)
{
$this->categories->detach($categoryToRemove);
}
/**
* Returns the categories
*
* @return ObjectStorage<Category>
*/
public function getCategories()
{
return $this->categories;
}
/**
* Sets the categories
*
* @param ObjectStorage<Category> $categories
* @return void
*/
public function setCategories(ObjectStorage $categories)
{
$this->categories = $categories;
}
}
@@ -0,0 +1,28 @@
<?php
declare(strict_types=1);
namespace Evomedien\Vitec\Domain\Repository;
/**
* This file is part of the "VITEC" Extension for TYPO3 CMS.
*
* For the full copyright and license information, please read the
* LICENSE.txt file that was distributed with this source code.
*
* (c) 2025
*/
/**
* The repository for Downloads
*/
class DownloadRepository extends \TYPO3\CMS\Extbase\Persistence\Repository
{
public function findByUids(array $uids)
{
$query = $this->createQuery();
return $query->matching(
$query->in('uid', $uids) // Use 'uid' instead of 'uids'
)->execute();
}
}
@@ -0,0 +1,11 @@
<?php
declare(strict_types=1);
namespace Evomedien\Vitec\Domain\Repository;
use TYPO3\CMS\Extbase\Persistence\Repository;
class MarketRepository extends Repository
{
}
@@ -0,0 +1,66 @@
<?php
namespace Evomedien\Vitec\Domain\Repository;
use TYPO3\CMS\Extbase\Persistence\QueryResultInterface;
use TYPO3\CMS\Extbase\Persistence\Repository;
class ProductRepository extends Repository
{
/**
* Find products with visibility filters and optional category filtering
*
* @param array $categoryUids Optional category UIDs to filter by
* @param bool $respectVisibility Whether to apply visibility filters
* @return QueryResultInterface
*/
public function findFilteredProducts(array $categoryUids = [], bool $respectVisibility = true): QueryResultInterface
{
$query = $this->createQuery();
$constraints = [];
// Add visibility constraints if requested
if ($respectVisibility) {
$constraints[] = $query->equals('legacy', 0);
$constraints[] = $query->equals('supportproduct', 0);
$constraints[] = $query->equals('hideonwebsite', 0);
$constraints[] = $query->equals('hideonproducts', 0);
$constraints[] = $query->equals('subproduct', 0);
}
// Add category filtering if categories are provided
$categoryUids = array_filter(array_map('intval', $categoryUids));
if (!empty($categoryUids)) {
// For TYPO3 13.4, use contains() for MM relations to sys_category
$categoryConstraints = [];
foreach ($categoryUids as $categoryUid) {
$categoryConstraints[] = $query->contains('categories', $categoryUid);
}
$constraints[] = $query->logicalOr(...$categoryConstraints);
}
// Apply constraints if any exist
if (!empty($constraints)) {
$query->matching($query->logicalAnd(...$constraints));
}
return $query->execute();
}
/**
* Find all visible products (convenience method)
*/
public function findAllVisible(): QueryResultInterface
{
return $this->findFilteredProducts([], true);
}
/**
* Find products by categories only (no visibility filtering)
*/
public function findByCategoriesOnly(array $categoryUids): QueryResultInterface
{
return $this->findFilteredProducts($categoryUids, false);
}
}
@@ -0,0 +1,11 @@
<?php
declare(strict_types=1);
namespace Evomedien\Vitec\Domain\Repository;
use TYPO3\CMS\Extbase\Persistence\Repository;
class SolutionRepository extends Repository
{
}
@@ -0,0 +1,28 @@
<?php
namespace Evomedien\Vitec\Domain\Repository;
use TYPO3\CMS\Extbase\Persistence\QueryResultInterface;
/**
* This file is part of the "VITEC" Extension for TYPO3 CMS.
*
* For the full copyright and license information, please read the
* LICENSE.txt file that was distributed with this source code.
*
* (c) 2025
*/
/**
* The repository for Usecase
*/
class UsecaseRepository extends \TYPO3\CMS\Extbase\Persistence\Repository
{
public function findAllWithCategories(): QueryResultInterface
{
$query = $this->createQuery();
$query->getQuerySettings()->setRespectStoragePage(false); // Fetch from all storage pages
return $query->execute();
}
}