using TrackCenter.Application.Dtos.TrackContents;
using TrackCenter.Application.Services.ProvideServices;
using TrackCenter.Domain.Aggregates.TrackContentAggregate;
using TrackCenter.Domain.Dtos.TrackContents;
namespace TrackCenter.Application.Services.ProvideServices;
///
/// 轨迹内容服务
///
[ApiExplorerSettings(GroupName = "提供接口")]
[Route("/ProviderService")]
public class TrackContentService : ApplicationServiceBase
{
private readonly ITrackContentRepository _trackContentRepository;
public TrackContentService(ITrackContentRepository trackContentRepository)
{
_trackContentRepository = trackContentRepository;
}
///
/// 根据应用获取轨迹内容列表
///
///
///
[HttpPost("Track/GetTrackContents")]
public async Task> GetTrackContentsAsync(string AppKey)
{
var res = await _trackContentRepository.GetTrackContentByAppKeyAsync(AppKey);
var result = ObjectMapper.Map, List>(res);
return result;
}
}