Open-source event management and ticket selling platform — perfect for concerts, conferences, and everything in between 🎟️ If you find this project helpful, please consider giving us a star ⭐️
PHP attendize-alternativedoor-managementevent-check-inevent-managementevent-registrationevent-ticketingeventbrite-alternativeeventslaravelopen-sourcephpreactself-hostedsell-ticketssell-tickets-onlineticket-sellingticketing-systemtickettailor-alternativetito-alternative
<?php
namespace HiEvents\Models;
use HiEvents\DomainObjects\Generated\QuestionDomainObjectAbstract;
use Illuminate\Database\Eloquent\Relations\BelongsToMany;
use Illuminate\Database\Eloquent\SoftDeletes;
class Question extends BaseModel
{
use SoftDeletes;
protected function getCastMap(): array
{
return [
QuestionDomainObjectAbstract::OPTIONS => 'array',
];
}
public function products(): BelongsToMany
{
return $this
->belongsToMany(Product::class, 'product_questions')
->whereNull('product_questions.deleted_at');
}
}