mirror of
https://github.com/claunia/marechai.git
synced 2026-07-08 17:57:08 +00:00
Lets admins merge duplicate SoftwareCompilation entries: a new
POST /software-compilations/{id}/merge endpoint re-parents releases,
covers, junction rows (with dedup/self-loop guards), and predecessor
references onto the target before deleting the sources. Wired into
both the Blazor MudBlazor admin page and the Uno admin page, each
with a search-based target/source picker, plus full localization.
70 lines
3.2 KiB
C#
70 lines
3.2 KiB
C#
// <auto-generated/>
|
|
#pragma warning disable CS0618
|
|
using Microsoft.Kiota.Abstractions.Extensions;
|
|
using Microsoft.Kiota.Abstractions.Serialization;
|
|
using System.Collections.Generic;
|
|
using System.IO;
|
|
using System;
|
|
namespace Marechai.ApiClient.Models
|
|
{
|
|
[global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.0.0")]
|
|
#pragma warning disable CS1591
|
|
public partial class MergeSoftwareCompilationsRequest : IAdditionalDataHolder, IParsable
|
|
#pragma warning restore CS1591
|
|
{
|
|
/// <summary>Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.</summary>
|
|
public IDictionary<string, object> AdditionalData { get; set; }
|
|
/// <summary>The sourceIds property</summary>
|
|
#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER
|
|
#nullable enable
|
|
public List<int?>? SourceIds { get; set; }
|
|
#nullable restore
|
|
#else
|
|
public List<int?> SourceIds { get; set; }
|
|
#endif
|
|
/// <summary>The targetId property</summary>
|
|
public int? TargetId { get; set; }
|
|
/// <summary>
|
|
/// Instantiates a new <see cref="global::Marechai.ApiClient.Models.MergeSoftwareCompilationsRequest"/> and sets the default values.
|
|
/// </summary>
|
|
public MergeSoftwareCompilationsRequest()
|
|
{
|
|
AdditionalData = new Dictionary<string, object>();
|
|
}
|
|
/// <summary>
|
|
/// Creates a new instance of the appropriate class based on discriminator value
|
|
/// </summary>
|
|
/// <returns>A <see cref="global::Marechai.ApiClient.Models.MergeSoftwareCompilationsRequest"/></returns>
|
|
/// <param name="parseNode">The parse node to use to read the discriminator value and create the object</param>
|
|
public static global::Marechai.ApiClient.Models.MergeSoftwareCompilationsRequest CreateFromDiscriminatorValue(IParseNode parseNode)
|
|
{
|
|
if(ReferenceEquals(parseNode, null)) throw new ArgumentNullException(nameof(parseNode));
|
|
return new global::Marechai.ApiClient.Models.MergeSoftwareCompilationsRequest();
|
|
}
|
|
/// <summary>
|
|
/// The deserialization information for the current model
|
|
/// </summary>
|
|
/// <returns>A IDictionary<string, Action<IParseNode>></returns>
|
|
public virtual IDictionary<string, Action<IParseNode>> GetFieldDeserializers()
|
|
{
|
|
return new Dictionary<string, Action<IParseNode>>
|
|
{
|
|
{ "sourceIds", n => { SourceIds = n.GetCollectionOfPrimitiveValues<int?>()?.AsList(); } },
|
|
{ "targetId", n => { TargetId = n.GetIntValue(); } },
|
|
};
|
|
}
|
|
/// <summary>
|
|
/// Serializes information the current object
|
|
/// </summary>
|
|
/// <param name="writer">Serialization writer to use to serialize this model</param>
|
|
public virtual void Serialize(ISerializationWriter writer)
|
|
{
|
|
if(ReferenceEquals(writer, null)) throw new ArgumentNullException(nameof(writer));
|
|
writer.WriteCollectionOfPrimitiveValues<int?>("sourceIds", SourceIds);
|
|
writer.WriteIntValue("targetId", TargetId);
|
|
writer.WriteAdditionalData(AdditionalData);
|
|
}
|
|
}
|
|
}
|
|
#pragma warning restore CS0618
|