Add Campaigns module for grouping short links.
Deploy Ladill Link / deploy (push) Successful in 1m26s
Deploy Ladill Link / deploy (push) Successful in 1m26s
Let accounts organise links by promo or launch, attach or detach links, and view combined click totals from the sidebar.
This commit is contained in:
@@ -11,6 +11,7 @@ class ShortLink extends Model
|
||||
{
|
||||
protected $fillable = [
|
||||
'user_id',
|
||||
'campaign_id',
|
||||
'source_app',
|
||||
'source_kind',
|
||||
'source_ref',
|
||||
@@ -40,6 +41,11 @@ class ShortLink extends Model
|
||||
return $this->belongsTo(User::class);
|
||||
}
|
||||
|
||||
public function campaign(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(Campaign::class);
|
||||
}
|
||||
|
||||
public function clicks(): HasMany
|
||||
{
|
||||
return $this->hasMany(LinkClick::class);
|
||||
|
||||
Reference in New Issue
Block a user