< Summary

Information
Class: Services.ApiServices.FidApi.Models.FidPriceCurrentRow
Assembly: Services
File(s): /home/runner/work/Studio2Prod/Studio2Prod/AppRepository/ApiServices/FidApi/Models/FidPriceStock.cs
Line coverage
100%
Covered lines: 13
Uncovered lines: 0
Coverable lines: 13
Total lines: 82
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_CabinetKey()100%11100%
get_Article()100%11100%
get_WarehouseName()100%11100%
get_Stock()100%11100%
get_StockSupplier()100%11100%
get_Price()100%11100%
get_OldPrice()100%11100%
get_MinPrice()100%11100%
get_PurchasePrice()100%11100%
get_PriceWarehouse()100%11100%
get_PriceSupplier()100%11100%
get_RunId()100%11100%
get_UpdatedAt()100%11100%

File(s)

/home/runner/work/Studio2Prod/Studio2Prod/AppRepository/ApiServices/FidApi/Models/FidPriceStock.cs

#LineLine coverage
 1using Newtonsoft.Json;
 2
 3namespace Services.ApiServices.FidApi.Models;
 4
 5/// <summary>Единый снимок цены, остатков и истории из фид-сервиса.</summary>
 6public sealed class FidPriceStock
 7{
 8    [JsonProperty("current")]
 9    public List<FidPriceCurrentRow> Current { get; init; } = [];
 10
 11    [JsonProperty("history")]
 12    public List<FidPriceHistoryRow> History { get; init; } = [];
 13}
 14
 15public sealed class FidPriceCurrentRow
 16{
 17    [JsonProperty("cabinetKey")]
 318    public string CabinetKey { get; init; } = string.Empty;
 19
 20    [JsonProperty("article")]
 321    public string Article { get; init; } = string.Empty;
 22
 23    [JsonProperty("warehouseName")]
 224    public string? WarehouseName { get; init; }
 25
 26    [JsonProperty("stock")]
 227    public int? Stock { get; init; }
 28
 29    [JsonProperty("stockSupplier")]
 230    public string? StockSupplier { get; init; }
 31
 32    [JsonProperty("price")]
 233    public decimal? Price { get; init; }
 34
 35    [JsonProperty("oldPrice")]
 236    public decimal? OldPrice { get; init; }
 37
 38    [JsonProperty("minPrice")]
 239    public decimal? MinPrice { get; init; }
 40
 41    [JsonProperty("purchasePrice")]
 242    public decimal? PurchasePrice { get; init; }
 43
 44    [JsonProperty("priceWarehouse")]
 245    public string? PriceWarehouse { get; init; }
 46
 47    [JsonProperty("priceSupplier")]
 248    public string? PriceSupplier { get; init; }
 49
 50    [JsonProperty("runId")]
 251    public long? RunId { get; init; }
 52
 53    [JsonProperty("updatedAt")]
 254    public DateTime UpdatedAt { get; init; }
 55}
 56
 57public sealed class FidPriceHistoryRow
 58{
 59    [JsonProperty("runId")]
 60    public long RunId { get; init; }
 61
 62    [JsonProperty("assembledAt")]
 63    public DateTime AssembledAt { get; init; }
 64
 65    [JsonProperty("assembledBy")]
 66    public string? AssembledBy { get; init; }
 67
 68    [JsonProperty("cabinetKey")]
 69    public string CabinetKey { get; init; } = string.Empty;
 70
 71    [JsonProperty("article")]
 72    public string Article { get; init; } = string.Empty;
 73
 74    [JsonProperty("price")]
 75    public decimal? Price { get; init; }
 76
 77    [JsonProperty("oldPrice")]
 78    public decimal? OldPrice { get; init; }
 79
 80    [JsonProperty("totalStock")]
 81    public long? TotalStock { get; init; }
 82}