mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-17 05:54:26 +01:00
* Histograms: Add Lightning data and API endpoints Ported over from the mobile-working-branch. Adds histogram data for Lightning and exposes the wallet/lightning histogram data via the API. It also add a dashboard graph for the Lightning balance. Caveat: The Lightning histogram is calculated by using the current channel balance and going backwards through as much invoices and transactions as we have. The "start" of the LN graph data might not be accurate though. That's because we don't track (and not even have) the LN onchain data. It is calculated by using the current channel balance and going backwards through as much invoices and transactions as we have. So the historic graph data for LN is basically a best effort of trying to reconstruct it with what we have: The LN channel transactions. * More timeframes * Refactoring: Remove redundant WalletHistogram types * Remove store property from dashboard tile view models * JS error fixes
22 lines
727 B
C#
22 lines
727 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using BTCPayServer.Client.Models;
|
|
using BTCPayServer.Services.Rates;
|
|
using StoreData = BTCPayServer.Data.StoreData;
|
|
|
|
namespace BTCPayServer.Components.StoreWalletBalance;
|
|
|
|
public class StoreWalletBalanceViewModel
|
|
{
|
|
public string StoreId { get; set; }
|
|
public decimal? Balance { get; set; }
|
|
public string CryptoCode { get; set; }
|
|
public string DefaultCurrency { get; set; }
|
|
public CurrencyData CurrencyData { get; set; }
|
|
public WalletId WalletId { get; set; }
|
|
public HistogramType Type { get; set; }
|
|
public IList<DateTimeOffset> Labels { get; set; }
|
|
public IList<decimal> Series { get; set; }
|
|
public bool MissingWalletConfig { get; set; }
|
|
}
|