|
|
@ -1119,20 +1119,15 @@ namespace Jellyfin.Api.Controllers
|
|
|
|
/// <summary>
|
|
|
|
/// <summary>
|
|
|
|
/// Set channel mappings.
|
|
|
|
/// Set channel mappings.
|
|
|
|
/// </summary>
|
|
|
|
/// </summary>
|
|
|
|
/// <param name="providerId">Provider id.</param>
|
|
|
|
/// <param name="setChannelMappingDto">The set channel mapping dto.</param>
|
|
|
|
/// <param name="tunerChannelId">Tuner channel id.</param>
|
|
|
|
|
|
|
|
/// <param name="providerChannelId">Provider channel id.</param>
|
|
|
|
|
|
|
|
/// <response code="200">Created channel mapping returned.</response>
|
|
|
|
/// <response code="200">Created channel mapping returned.</response>
|
|
|
|
/// <returns>An <see cref="OkResult"/> containing the created channel mapping.</returns>
|
|
|
|
/// <returns>An <see cref="OkResult"/> containing the created channel mapping.</returns>
|
|
|
|
[HttpPost("ChannelMappings")]
|
|
|
|
[HttpPost("ChannelMappings")]
|
|
|
|
[Authorize(Policy = Policies.DefaultAuthorization)]
|
|
|
|
[Authorize(Policy = Policies.DefaultAuthorization)]
|
|
|
|
[ProducesResponseType(StatusCodes.Status200OK)]
|
|
|
|
[ProducesResponseType(StatusCodes.Status200OK)]
|
|
|
|
public async Task<ActionResult<TunerChannelMapping>> SetChannelMapping(
|
|
|
|
public async Task<ActionResult<TunerChannelMapping>> SetChannelMapping([FromBody, Required] SetChannelMappingDto setChannelMappingDto)
|
|
|
|
[FromQuery] string? providerId,
|
|
|
|
|
|
|
|
[FromQuery] string? tunerChannelId,
|
|
|
|
|
|
|
|
[FromQuery] string? providerChannelId)
|
|
|
|
|
|
|
|
{
|
|
|
|
{
|
|
|
|
return await _liveTvManager.SetChannelMapping(providerId, tunerChannelId, providerChannelId).ConfigureAwait(false);
|
|
|
|
return await _liveTvManager.SetChannelMapping(setChannelMappingDto.ProviderId, setChannelMappingDto.TunerChannelId, setChannelMappingDto.ProviderChannelId).ConfigureAwait(false);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// <summary>
|
|
|
|