feat: 完成任务系统的领域服务
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
namespace Yi.Framework.Bbs.Domain.Managers.AssignmentProviders;
|
||||
using Yi.Framework.Bbs.Domain.Shared.Enums;
|
||||
|
||||
namespace Yi.Framework.Bbs.Domain.Managers.AssignmentProviders;
|
||||
|
||||
/// <summary>
|
||||
/// 每日任务提供者
|
||||
/// </summary>
|
||||
public class DailyProvider : TimerProvider
|
||||
{
|
||||
protected override TimeSpan TimeCycle => TimeSpan.FromDays(1);
|
||||
protected override AssignmentTypeEnum AssignmentType => AssignmentTypeEnum.Daily;
|
||||
}
|
||||
@@ -9,11 +9,7 @@ public class NoviceProvider : IAssignmentProvider
|
||||
{
|
||||
public Task<List<AssignmentDefineAggregateRoot>> GetCanReceiveListAsync(AssignmentContext context)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
public Task VerifyCanAcceptAsync(AssignmentContext context)
|
||||
{
|
||||
//新手任务是要有前置依赖关系的,链表类型依赖
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,11 @@
|
||||
namespace Yi.Framework.Bbs.Domain.Managers.AssignmentProviders;
|
||||
using Yi.Framework.Bbs.Domain.Shared.Enums;
|
||||
|
||||
namespace Yi.Framework.Bbs.Domain.Managers.AssignmentProviders;
|
||||
|
||||
/// <summary>
|
||||
/// 每周任务提供者
|
||||
/// </summary>
|
||||
public class WeeklyProvider : TimerProvider
|
||||
{
|
||||
protected override TimeSpan TimeCycle => TimeSpan.FromDays(7);
|
||||
protected override AssignmentTypeEnum AssignmentType => AssignmentTypeEnum.Weekly;
|
||||
}
|
||||
Reference in New Issue
Block a user