wiring up map updates
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Michele Scandura 2021-09-16 16:34:44 +01:00
parent e18cbb157c
commit 155cb4ea9a
13 changed files with 99 additions and 58 deletions

View file

@ -0,0 +1,21 @@
using System;
using System.Collections.Generic;
using MediatR;
using Sledgemapper.Shared.Entities;
namespace Sledgemapper.Api.Commands
{
public class GetCampaignMapsCommand : IRequest<List<Session>>
{
public double Timestamp { get; private set; }
public string CampaignName { get; private set; }
public string UserId { get; private set; }
public GetCampaignMapsCommand(string campaingName, string userId)
{
Timestamp = DateTimeOffset.Now.ToUnixTimeMilliseconds();
CampaignName = campaingName;
UserId = userId;
}
}
}

View file

@ -10,6 +10,7 @@ namespace Sledgemapper.Api.Commands
public double Timestamp { get; private set; }
public string CampaignName { get; private set; }
public string UserId { get; private set; }
public GetCampaignPlayersCommand(string campaingName, string userId)
{
Timestamp = DateTimeOffset.Now.ToUnixTimeMilliseconds();
@ -17,18 +18,4 @@ namespace Sledgemapper.Api.Commands
UserId = userId;
}
}
public class GetCampaignMapsCommand : IRequest<List<Session>>
{
public double Timestamp { get; private set; }
public string CampaignName { get; private set; }
public string UserId { get; private set; }
public GetCampaignMapsCommand(string campaingName, string userId)
{
Timestamp = DateTimeOffset.Now.ToUnixTimeMilliseconds();
CampaignName = campaingName;
UserId = userId;
}
}
}

View file

@ -6,7 +6,7 @@ namespace Sledgemapper.Api.Commands
{
public Overlay Overlay { get; private set; }
public NewOverlayCommand(string sessionName, Overlay overlay, string userId) : base(sessionName, userId)
public NewOverlayCommand(string campaignId, string mapId, Overlay overlay, string userId) : base(campaignId, mapId, userId)
{
Overlay = overlay;
}