Files
tiku-backend.net/Tiku.Infrastructure/Growth/ReferralService.cs
xiong c497a3ca8d
Some checks failed
ci / release-gate (push) Has been cancelled
清理代码
2026-08-03 12:31:39 +08:00

32 lines
797 B
C#

using Tiku.Application.Growth;
using Tiku.Application.Security;
using Tiku.Infrastructure.Persistence;
namespace Tiku.Infrastructure.Growth;
public sealed partial class ReferralService(
TikuDbContext dbContext,
IReferralQrcodeGenerator qrcodeGenerator,
ICurrentAccessContext currentAccessContext) : IReferralService
{
private static readonly HashSet<string> AllowedEventTypes = new(StringComparer.OrdinalIgnoreCase)
{
"enter",
"register",
"purchase",
"share",
"scan",
"manual_bind"
};
private static readonly HashSet<string> AllowedSources = new(StringComparer.OrdinalIgnoreCase)
{
"share",
"qrcode",
"timeline",
"miniapp",
"h5",
"manual",
"unknown"
};
}