mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-03 09:11:10 +00:00
Refactors the artist slice across the stack
This commit is contained in:
1 parent
c112c64c25
commit
aa097ecc98
55 files changed
+3219
-278
No files matched your search
+1
-4
@@ -1,5 +1,4 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
@@ -8,12 +7,10 @@ namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artis
|
||||
/// <summary>
|
||||
/// Represents a request to get the lightweight read models of the albums of an artist.
|
||||
/// </summary>
|
||||
/// <param name="ArtistId">The unique identifier of the artist whose albums are retrieved.</param>
|
||||
/// <param name="CurrentPage">The page of results to retrieve. Optional.</param>
|
||||
/// <param name="PerPage">The maximum number of albums to retrieve per page. Optional.</param>
|
||||
[DebuggerDisplay("ArtistId: {ArtistId}")]
|
||||
[DebuggerDisplay("CurrentPage: {CurrentPage}, PerPage: {PerPage}")]
|
||||
public record GetArtistAlbumsLiteRequest(
|
||||
Guid ArtistId,
|
||||
int? CurrentPage,
|
||||
int? PerPage
|
||||
);
|
||||
-15
@@ -1,15 +0,0 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to get the albums of an artist.
|
||||
/// </summary>
|
||||
/// <param name="ArtistId">The unique identifier of the artist whose albums are retrieved.</param>
|
||||
[DebuggerDisplay("ArtistId: {ArtistId}")]
|
||||
public record GetArtistAlbumsRequest(
|
||||
Guid ArtistId
|
||||
);
|
||||
-15
@@ -1,15 +0,0 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to get an artist by the specified Id.
|
||||
/// </summary>
|
||||
/// <param name="ArtistId">The unique identifier of the artist to retrieve.</param>
|
||||
[DebuggerDisplay("ArtistId: {ArtistId}")]
|
||||
public record GetArtistRequest(
|
||||
Guid ArtistId
|
||||
);
|
||||
+1
-4
@@ -1,5 +1,4 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
@@ -8,13 +7,11 @@ namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artis
|
||||
/// <summary>
|
||||
/// Represents a request to get the lightweight read models of the artists of a media library.
|
||||
/// </summary>
|
||||
/// <param name="LibraryId">The Id of the media library whose artists are retrieved. Required.</param>
|
||||
/// <param name="CurrentPage">The page of results to retrieve. Optional.</param>
|
||||
/// <param name="PerPage">The maximum number of artists to retrieve per page. Optional.</param>
|
||||
/// <param name="SearchTerm">The search term used to filter the artists by name. Optional.</param>
|
||||
[DebuggerDisplay("LibraryId: {LibraryId}")]
|
||||
[DebuggerDisplay("SearchTerm: {SearchTerm}")]
|
||||
public record GetArtistsLiteRequest(
|
||||
Guid LibraryId,
|
||||
int? CurrentPage,
|
||||
int? PerPage,
|
||||
string? SearchTerm
|
||||
|
||||
+1
-4
@@ -1,5 +1,4 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
@@ -8,13 +7,11 @@ namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artis
|
||||
/// <summary>
|
||||
/// Represents a request to get the artists of a media library.
|
||||
/// </summary>
|
||||
/// <param name="LibraryId">The Id of the media library whose artists are retrieved. Required.</param>
|
||||
/// <param name="CurrentPage">The page of results to retrieve. Optional.</param>
|
||||
/// <param name="PerPage">The maximum number of artists to retrieve per page. Optional.</param>
|
||||
/// <param name="SearchTerm">The search term used to filter the artists by name. Optional.</param>
|
||||
[DebuggerDisplay("LibraryId: {LibraryId}")]
|
||||
[DebuggerDisplay("SearchTerm: {SearchTerm}")]
|
||||
public record GetArtistsRequest(
|
||||
Guid LibraryId,
|
||||
int? CurrentPage,
|
||||
int? PerPage,
|
||||
string? SearchTerm
|
||||
|
||||
+40
@@ -0,0 +1,40 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary.MusicLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.AudioLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to update an album of an artist, together with the tracks of the album, within an artist update.
|
||||
/// </summary>
|
||||
/// <param name="AlbumId">The Id of the album, when the album already exists. Optional.</param>
|
||||
/// <param name="Metadata">The album metadata of the album. Required.</param>
|
||||
/// <param name="MediaFormat">The physical or digital medium of the album. Optional.</param>
|
||||
/// <param name="Barcode">The barcode of the album. Optional.</param>
|
||||
/// <param name="CatalogNumber">The catalog number of the album. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseId">The MusicBrainz identifier of the release. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseGroupId">The MusicBrainz identifier of the release group. Optional.</param>
|
||||
/// <param name="MusicBrainzReleaseArtistId">The MusicBrainz identifier of the release artist. Optional.</param>
|
||||
/// <param name="Contributors">The list of media contributors that performed on the album. Required.</param>
|
||||
/// <param name="Ratings">The list of ratings for this album. Required.</param>
|
||||
/// <param name="Tracks">The list of tracks of the album, each with the Id of the track when the track already exists. Required.</param>
|
||||
[DebuggerDisplay("Title: {Metadata.Title}")]
|
||||
public record UpdateArtistAlbumRequest(
|
||||
Guid? AlbumId,
|
||||
AlbumMetadataDto? Metadata,
|
||||
MusicMediaFormat? MediaFormat,
|
||||
string? Barcode,
|
||||
string? CatalogNumber,
|
||||
Guid? MusicBrainzReleaseId,
|
||||
Guid? MusicBrainzReleaseGroupId,
|
||||
Guid? MusicBrainzReleaseArtistId,
|
||||
List<MediaContributorReferenceDto>? Contributors,
|
||||
List<AudioRatingDto>? Ratings,
|
||||
List<UpdateArtistTrackRequest>? Tracks
|
||||
);
|
||||
+1
-2
@@ -1,6 +1,5 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
using Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Albums;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
@@ -22,5 +21,5 @@ public record UpdateArtistRequest(
|
||||
string? Website,
|
||||
Guid? MusicBrainzArtistId,
|
||||
List<MediaContributorReferenceDto>? Contributors,
|
||||
List<AddAlbumRequest>? Albums
|
||||
List<UpdateArtistAlbumRequest>? Albums
|
||||
);
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary.MusicLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.AudioLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
#endregion
|
||||
|
||||
namespace Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artists;
|
||||
|
||||
/// <summary>
|
||||
/// Represents a request to update a track of an album of an artist, within an artist update.
|
||||
/// </summary>
|
||||
/// <param name="TrackId">The Id of the track, when the track already exists. Optional.</param>
|
||||
/// <param name="Path">The file system path of the track. Required.</param>
|
||||
/// <param name="Metadata">The audio metadata of the track. Required.</param>
|
||||
/// <param name="TrackNumber">The number of the track on its disc. Required.</param>
|
||||
/// <param name="DiscNumber">The number of the disc the track belongs to. Optional.</param>
|
||||
/// <param name="Script">The script used by the language of the track. Optional.</param>
|
||||
/// <param name="Key">The musical key of the track. Optional.</param>
|
||||
/// <param name="Bpm">The tempo of the track in beats per minute. Optional.</param>
|
||||
/// <param name="Work">The title of the work the track is a recording of. Optional.</param>
|
||||
/// <param name="MusicBrainzRecordingId">The MusicBrainz identifier of the recording. Optional.</param>
|
||||
/// <param name="MusicBrainzTrackId">The MusicBrainz identifier of the track. Optional.</param>
|
||||
/// <param name="MusicBrainzWorkId">The MusicBrainz identifier of the work. Optional.</param>
|
||||
/// <param name="Moods">The list of moods of the track. Optional.</param>
|
||||
/// <param name="Isrcs">The list of ISRC (International Standard Recording Code) of the track. Optional.</param>
|
||||
/// <param name="Contributors">The list of media contributors that performed on the track. Required.</param>
|
||||
/// <param name="Ratings">The list of ratings for this track. Required.</param>
|
||||
[DebuggerDisplay("Title: {Metadata.Title}")]
|
||||
public record UpdateArtistTrackRequest(
|
||||
Guid? TrackId,
|
||||
string? Path,
|
||||
AudioMetadataDto? Metadata,
|
||||
int? TrackNumber,
|
||||
int? DiscNumber,
|
||||
string? Script,
|
||||
MusicKey? Key,
|
||||
int? Bpm,
|
||||
string? Work,
|
||||
Guid? MusicBrainzRecordingId,
|
||||
Guid? MusicBrainzTrackId,
|
||||
Guid? MusicBrainzWorkId,
|
||||
List<MoodDto>? Moods,
|
||||
List<IsrcDto>? Isrcs,
|
||||
List<MediaContributorReferenceDto>? Contributors,
|
||||
List<AudioRatingDto>? Ratings
|
||||
);
|
||||
Reference in new issue
Block a user