Documentation ¶
Index ¶
- Variables
- type AdrestiaModel
- func (am *AdrestiaModel) GetAllBalancer(includeComplete bool, sinceTimestamp int) (balancers []hestia.Balancer, err error)
- func (am *AdrestiaModel) GetAllBalancerOrder(includeComplete bool, sinceTimestamp int) (orders []hestia.BalancerOrder, err error)
- func (am *AdrestiaModel) GetAllSimpleTx(includeComplete bool, sinceTimestamp int, txType string, balancerId string) (simpleTxs []hestia.SimpleTx, err error)
- func (am *AdrestiaModel) GetBalancer(id string) (balancer hestia.Balancer, err error)
- func (am *AdrestiaModel) GetBalancerOrder(id string) (order hestia.BalancerOrder, err error)
- func (am *AdrestiaModel) GetBalancers(includeComplete bool) (balancers []hestia.Balancer, err error)
- func (am *AdrestiaModel) GetSimpleTx(id string, txType string) (simpleTx hestia.SimpleTx, err error)
- func (am *AdrestiaModel) UpdateBalancer(balancer hestia.Balancer) error
- func (am *AdrestiaModel) UpdateBalancerOrder(order hestia.BalancerOrder) error
- func (am *AdrestiaModel) UpdateSimpleTx(simpleTx hestia.SimpleTx, txType string) error
- type ApiBitcouFilter
- type BalancesModel
- type BitcouConfModel
- type BitcouCountry
- type BitcouCountryV2
- type BitcouFilter
- type BitcouFilterWrapper
- type BitcouModel
- func (bm *BitcouModel) AddCountry(country BitcouCountry) error
- func (bm *BitcouModel) AddCountryV2(country BitcouCountryV2) error
- func (bm *BitcouModel) AddProviderImage(imageInfo ladon.ProviderImageApp) error
- func (bm *BitcouModel) AddTestCountry(country BitcouCountry) error
- func (bm *BitcouModel) AddTestCountryV2(country BitcouCountryV2) error
- func (bm *BitcouModel) GetCountries(dev bool) (countries []string, err error)
- func (bm *BitcouModel) GetCountriesV2(dev bool) (countries []string, err error)
- func (bm *BitcouModel) GetCountry(id string) (country BitcouCountry, err error)
- func (bm *BitcouModel) GetCountryV2(id string) (country BitcouCountryV2, err error)
- func (bm *BitcouModel) GetFilters(db string) (filterResponse BitcouFilterWrapper, err error)
- func (bm *BitcouModel) GetProviderImage(providerId string) (imageInfo ladon.ProviderImageApp, err error)
- func (bm *BitcouModel) GetTestCountry(id string) (country BitcouCountry, err error)
- func (bm *BitcouModel) GetTestCountryV2(id string) (country BitcouCountryV2, err error)
- type CardsModel
- type CoinsModel
- type DepositsModel
- type ExchangesModel
- type GlobalConfigModel
- type OrdersModel
- type ShiftModel
- type ShiftModelV2
- func (m *ShiftModelV2) Get(id string) (shift hestia.ShiftV2, err error)
- func (m *ShiftModelV2) GetAll(filter int32, timeFilter string) (shifts []hestia.ShiftV2, err error)
- func (m *ShiftModelV2) GetOpenShifts(timestamp int64) (shifts []hestia.ShiftV2, err error)
- func (m *ShiftModelV2) Update(shift hestia.ShiftV2) error
- type ShiftStatsResponse
- type UsersModel
- func (m *UsersModel) AddCard(uid string, cardCode string) error
- func (m *UsersModel) AddDeposit(uid string, depositID string) error
- func (m *UsersModel) AddOrder(uid string, orderID string) error
- func (m *UsersModel) AddShift(uid string, shiftID string) error
- func (m *UsersModel) AddShiftV2(uid string, shiftID string) error
- func (m *UsersModel) AddVoucher(uid string, voucherID string) error
- func (m *UsersModel) AddVoucherV2(uid string, voucherId string) error
- func (m *UsersModel) Get(uid string) (user hestia.User, err error)
- func (m *UsersModel) GetAll() (users []hestia.User, err error)
- func (m *UsersModel) Update(user hestia.User) error
- type VoucherStatsResponse
- type VouchersModel
- type VouchersModelV2
- func (m *VouchersModelV2) Get(id string) (voucher hestia.VoucherV2, err error)
- func (m *VouchersModelV2) GetAll(filter int, timefilter string) (vouchers []hestia.VoucherV2, err error)
- func (m *VouchersModelV2) GetWithComposedQuery(filters herodotus.VoucherV2Filters) (vouchers []hestia.VoucherV2, err error)
- func (m *VouchersModelV2) Update(voucher hestia.VoucherV2) error
Constants ¶
This section is empty.
Variables ¶
View Source
var TestBalances = []hestia.CoinBalances{
{Ticker: "BTC", Balance: 0, Status: "SUCCESS"},
{Ticker: "COLX", Balance: 0, Status: "SUCCESS"},
{Ticker: "DASH", Balance: 0, Status: "SUCCESS"},
{Ticker: "DGB", Balance: 0, Status: "SUCCESS"},
{Ticker: "ETH", Balance: 0, Status: "SUCCESS"},
{Ticker: "GRS", Balance: 0, Status: "SUCCESS"},
{Ticker: "LTC", Balance: 0, Status: "SUCCESS"},
{Ticker: "ONION", Balance: 0, Status: "SUCCESS"},
{Ticker: "POLIS", Balance: 0, Status: "SUCCESS"},
{Ticker: "TELOS", Balance: 0, Status: "SUCCESS"},
{Ticker: "TUSD", Balance: 0, Status: "SUCCESS"},
{Ticker: "USDC", Balance: 0, Status: "SUCCESS"},
{Ticker: "USDT", Balance: 0, Status: "SUCCESS"},
{Ticker: "XSG", Balance: 0, Status: "SUCCESS"},
{Ticker: "XZC", Balance: 0, Status: "SUCCESS"},
}
View Source
var TestCard = hestia.Card{
Address: "TEST-ADDRRESS",
CardCode: "TEST-CARDCODE",
CardNumber: "123456778",
City: "TEST-CITY",
Email: "TEST@TEST.COM",
FirstName: "TEST",
LastName: "CARD",
UID: "XYZ12345678910",
}
View Source
var TestCoinData = []hestia.Coin{hestia.Coin{Ticker: "AYA", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 10, Available: false}, Orders: hestia.Properties{FeePercentage: 10, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "BAT", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 0, Available: false}, Orders: hestia.Properties{FeePercentage: 0, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "BITG", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "BTC", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "COLX", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "DASH", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "DGB", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "DIVI", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "ETH", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "FYD", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 10, Available: false}, Orders: hestia.Properties{FeePercentage: 10, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "GRS", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "LINK", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 0, Available: false}, Orders: hestia.Properties{FeePercentage: 10, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "LMY", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 10, Available: false}, Orders: hestia.Properties{FeePercentage: 10, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "LTC", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "MANA", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 10, Available: false}, Orders: hestia.Properties{FeePercentage: 10, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "MW", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 10, Available: false}, Orders: hestia.Properties{FeePercentage: 10, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "ONION", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "POLIS", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "RPD", Shift: hestia.Properties{FeePercentage: 10, Available: false}, Deposits: hestia.Properties{FeePercentage: 10, Available: false}, Vouchers: hestia.Properties{FeePercentage: 10, Available: false}, Orders: hestia.Properties{FeePercentage: 10, Available: false}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "TELOS", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "TUSD", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "USDC", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "USDT", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "XSG", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}, hestia.Coin{Ticker: "XZC", Shift: hestia.Properties{FeePercentage: 10, Available: true}, Deposits: hestia.Properties{FeePercentage: 10, Available: true}, Vouchers: hestia.Properties{FeePercentage: 10, Available: true}, Orders: hestia.Properties{FeePercentage: 10, Available: true}, Balances: hestia.BalanceLimits{HotWallet: 0, Exchanges: 0}, Adrestia: hestia.AdrestiaInfo{Available: false, CoinUsage: 0}}}
View Source
var TestConfigData = hestia.Config{ Shift: hestia.Available{Service: true, Processor: true}, Deposits: hestia.Available{Service: true, Processor: true}, Orders: hestia.Available{Service: true, Processor: true}, Vouchers: hestia.Available{Service: true, Processor: true}, }
View Source
var TestDeposit = hestia.Deposit{ ID: "TEST-DEPOSIT", UID: "XYZ12345678910", Payment: hestia.Payment{ Address: "FAKE-ADDR", Amount: 123123, Coin: "POLIS", Txid: "FAKE-TXID", Confirmations: 123, }, FeePayment: TestFeePayment, AmountInPeso: "100", CardCode: "TEST-CARDCODE", Status: "COMPLETED", Timestamp: "000000000000", }
View Source
var TestFeePayment = hestia.Payment{
Address: "TEST-ADDR",
Amount: 0,
Coin: "polis",
Txid: "TEST-TXID",
Confirmations: 0,
}
View Source
var TestOrder = hestia.Order{ ID: "TEST-ORDER", UID: "XYZ12345678910", Status: "COMPLETED", PaymentInfo: hestia.Payment{ Address: "FAKE-ADDRRESS", Amount: 100, Coin: "POLIS", Txid: "FAKE-TXID", Confirmations: 0, }, FeePayment: TestFeePayment, AddressInfo: hestia.AddressInformation{ City: "FAKE-CITY", Country: "FAKE-COUNTRY", PostalCode: "00000", Email: "TEST@TEST.COM", Street: "FAKE-STREET", }, Delivery: hestia.DeliveryOption{ Type: "DHL", Service: "EXPRESS", DeliveryAddress: hestia.AddressInformation{ City: "FAKE-CITY", Country: "FAKE-COUNTRY", PostalCode: "00000", Email: "TEST@TEST.COM", Street: "FAKE-STREET", }, }, PersonalizationData: hestia.PersonalizationInformation{ PersonalData: hestia.PersonalInformation{ BirthDate: "20190211", CivilState: "MARRIED", FirstName: "TEST-USER", LastName: "TEST-USER", Sex: "MALE", HomeNumber: "00-00-00-00", Nationality: "MEXICAN", PassportID: "1234567890", }, AddressData: hestia.AddressInformation{ City: "FAKE-CITY", Country: "FAKE-COUNTRY", PostalCode: "00000", Email: "TEST@TEST.COM", Street: "FAKE-STREET", }, }, }
View Source
var TestShift = hestia.Shift{ ID: "TEST-SHIFT", Status: hestia.GetShiftStatusString(hestia.ShiftStatusComplete), Timestamp: time.Unix(10000000, 0).Unix(), UID: "XYZ12345678910", Payment: hestia.Payment{ Address: "FAKE-ADDR", Amount: 0123123, Coin: "POLIS", Txid: "FAKE-TXID", Confirmations: 0, }, FeePayment: TestFeePayment, ToCoin: "Fake_coIN", RefundAddr: "FAKE_ADDR", ToAmount: 1000, ProofTimestamp: time.Unix(10000000, 0).Unix(), PaymentProof: "fakeTxid", ToAddress: "FakeAddress", }
View Source
var TestUser = hestia.User{ ID: "XYZ12345678910", Email: "TEST@TEST.COM", KYCData: hestia.KYCInformation{}, Role: "admin", Shifts: []string{}, Vouchers: []string{}, Deposits: []string{}, Cards: []string{}, Orders: []string{}, }
View Source
var TestVoucher = hestia.Voucher{ ID: "TEST-VOUCHER", UID: "XYZ12345678910", VoucherID: 123123, VariantID: "FAKE-VARIANT", Name: "TEST-VOUCHER", FeePayment: TestFeePayment, PaymentData: hestia.Payment{ Address: "FAKE-ADDR", Amount: 123123, Coin: "POLIS", Txid: "FAKE-TXID", Confirmations: 123, }, BitcouPaymentData: hestia.Payment{ Address: "FAKE-ADDR", Amount: 123123, Coin: "POLIS", Txid: "FAKE-TXID", Confirmations: 123, }, BitcouFeePaymentData: hestia.Payment{ Address: "TEST_ADDR", Amount: 123, Coin: "POLIS", Txid: "Fakse_TXID", Confirmations: 0, }, RefundAddr: "FAKE_ADDR", BitcouID: "FAKE-ID", RedeemCode: "FAKE-REDEEM", Status: hestia.GetVoucherStatusString(hestia.VoucherStatusComplete), Timestamp: time.Unix(0, 0).Unix(), RedeemTimestamp: time.Unix(0, 0).Unix(), }
Functions ¶
This section is empty.
Types ¶
type AdrestiaModel ¶
type AdrestiaModel struct { Firestore *firestore.DocumentRef Collections map[string]string }
func NewAdrestiaModel ¶
func NewAdrestiaModel(doc firestore.DocumentRef) AdrestiaModel
func (*AdrestiaModel) GetAllBalancer ¶
func (*AdrestiaModel) GetAllBalancerOrder ¶
func (am *AdrestiaModel) GetAllBalancerOrder(includeComplete bool, sinceTimestamp int) (orders []hestia.BalancerOrder, err error)
func (*AdrestiaModel) GetAllSimpleTx ¶
func (*AdrestiaModel) GetBalancer ¶
func (am *AdrestiaModel) GetBalancer(id string) (balancer hestia.Balancer, err error)
func (*AdrestiaModel) GetBalancerOrder ¶
func (am *AdrestiaModel) GetBalancerOrder(id string) (order hestia.BalancerOrder, err error)
func (*AdrestiaModel) GetBalancers ¶
func (am *AdrestiaModel) GetBalancers(includeComplete bool) (balancers []hestia.Balancer, err error)
func (*AdrestiaModel) GetSimpleTx ¶
func (*AdrestiaModel) UpdateBalancer ¶
func (am *AdrestiaModel) UpdateBalancer(balancer hestia.Balancer) error
func (*AdrestiaModel) UpdateBalancerOrder ¶
func (am *AdrestiaModel) UpdateBalancerOrder(order hestia.BalancerOrder) error
func (*AdrestiaModel) UpdateSimpleTx ¶
func (am *AdrestiaModel) UpdateSimpleTx(simpleTx hestia.SimpleTx, txType string) error
type ApiBitcouFilter ¶
type BalancesModel ¶
type BalancesModel struct { Firestore *firestore.DocumentRef Collection string }
func (*BalancesModel) AddBalance ¶
func (m *BalancesModel) AddBalance(balance hestia.CoinBalances) error
func (*BalancesModel) GetBalances ¶
func (m *BalancesModel) GetBalances() ([]hestia.CoinBalances, error)
func (*BalancesModel) UpdateBalances ¶
func (m *BalancesModel) UpdateBalances(Balances []hestia.CoinBalances) error
type BitcouConfModel ¶
type BitcouConfModel struct {
Firestore *firestore.CollectionRef
}
func (*BitcouConfModel) UpdateFilters ¶
func (bcm *BitcouConfModel) UpdateFilters(filter BitcouFilter) error
type BitcouCountry ¶
type BitcouCountry struct { ID string `firestore:"id" json:"id"` Vouchers []bitcou.LightVoucher `firestore:"vouchers" json:"vouchers"` }
type BitcouCountryV2 ¶
type BitcouCountryV2 struct { ID string `firestore:"id" json:"id"` Vouchers []bitcou.LightVoucherV2 `firestore:"vouchers" json:"vouchers"` }
type BitcouFilter ¶
type BitcouFilterWrapper ¶
type BitcouModel ¶
type BitcouModel struct { Firestore *firestore.CollectionRef FirestoreTest *firestore.CollectionRef FirestoreV2 *firestore.CollectionRef FirestoreTestV2 *firestore.CollectionRef ProductImages *firestore.CollectionRef }
func (*BitcouModel) AddCountry ¶
func (bm *BitcouModel) AddCountry(country BitcouCountry) error
func (*BitcouModel) AddCountryV2 ¶
func (bm *BitcouModel) AddCountryV2(country BitcouCountryV2) error
func (*BitcouModel) AddProviderImage ¶
func (bm *BitcouModel) AddProviderImage(imageInfo ladon.ProviderImageApp) error
func (*BitcouModel) AddTestCountry ¶
func (bm *BitcouModel) AddTestCountry(country BitcouCountry) error
func (*BitcouModel) AddTestCountryV2 ¶
func (bm *BitcouModel) AddTestCountryV2(country BitcouCountryV2) error
func (*BitcouModel) GetCountries ¶
func (bm *BitcouModel) GetCountries(dev bool) (countries []string, err error)
Replaces both implementations of GetCountry
func (*BitcouModel) GetCountriesV2 ¶
func (bm *BitcouModel) GetCountriesV2(dev bool) (countries []string, err error)
Replaces both implementations of GetCountry
func (*BitcouModel) GetCountry ¶
func (bm *BitcouModel) GetCountry(id string) (country BitcouCountry, err error)
func (*BitcouModel) GetCountryV2 ¶
func (bm *BitcouModel) GetCountryV2(id string) (country BitcouCountryV2, err error)
func (*BitcouModel) GetFilters ¶
func (bm *BitcouModel) GetFilters(db string) (filterResponse BitcouFilterWrapper, err error)
func (*BitcouModel) GetProviderImage ¶
func (bm *BitcouModel) GetProviderImage(providerId string) (imageInfo ladon.ProviderImageApp, err error)
func (*BitcouModel) GetTestCountry ¶
func (bm *BitcouModel) GetTestCountry(id string) (country BitcouCountry, err error)
func (*BitcouModel) GetTestCountryV2 ¶
func (bm *BitcouModel) GetTestCountryV2(id string) (country BitcouCountryV2, err error)
type CardsModel ¶
type CardsModel struct { Firestore *firestore.DocumentRef Collection string }
type CoinsModel ¶
type CoinsModel struct { Firestore *firestore.DocumentRef Collection string }
func (*CoinsModel) GetCoinsData ¶
func (m *CoinsModel) GetCoinsData() ([]hestia.Coin, error)
func (*CoinsModel) UpdateCoinsData ¶
func (m *CoinsModel) UpdateCoinsData(Coins []hestia.Coin) error
type DepositsModel ¶
type DepositsModel struct { Firestore *firestore.DocumentRef Collection string }
func (*DepositsModel) Get ¶
func (m *DepositsModel) Get(id string) (deposit hestia.Deposit, err error)
type ExchangesModel ¶
type ExchangesModel struct { Firestore *firestore.DocumentRef Collection string }
func (*ExchangesModel) Get ¶
func (m *ExchangesModel) Get(id string) (exchange hestia.ExchangeInfo, err error)
func (*ExchangesModel) GetAll ¶
func (m *ExchangesModel) GetAll() (exchanges []hestia.ExchangeInfo, err error)
func (*ExchangesModel) Update ¶
func (m *ExchangesModel) Update(exchange hestia.ExchangeInfo) error
type GlobalConfigModel ¶
type GlobalConfigModel struct { Firestore *firestore.DocumentRef Collection string }
func (*GlobalConfigModel) GetConfigData ¶
func (m *GlobalConfigModel) GetConfigData() (hestia.Config, error)
func (*GlobalConfigModel) UpdateConfigData ¶
func (m *GlobalConfigModel) UpdateConfigData(config hestia.Config) error
type OrdersModel ¶
type OrdersModel struct { Firestore *firestore.DocumentRef Collection string }
type ShiftModel ¶
type ShiftModel struct { Firestore *firestore.DocumentRef Collection string }
type ShiftModelV2 ¶
type ShiftModelV2 struct { Firestore *firestore.DocumentRef Collection string }
func (*ShiftModelV2) GetOpenShifts ¶
func (m *ShiftModelV2) GetOpenShifts(timestamp int64) (shifts []hestia.ShiftV2, err error)
type ShiftStatsResponse ¶
type UsersModel ¶
type UsersModel struct { Firestore *firestore.DocumentRef Collection string }
func (*UsersModel) AddCard ¶
func (m *UsersModel) AddCard(uid string, cardCode string) error
AddCard will add a card code into the user cards array.
func (*UsersModel) AddDeposit ¶
func (m *UsersModel) AddDeposit(uid string, depositID string) error
AddDeposit will add a deposit id into the user deposits array.
func (*UsersModel) AddOrder ¶
func (m *UsersModel) AddOrder(uid string, orderID string) error
AddOrder will add a order id into the user orders array.
func (*UsersModel) AddShift ¶
func (m *UsersModel) AddShift(uid string, shiftID string) error
AddShift will add a shift id into the user shifts array.
func (*UsersModel) AddShiftV2 ¶
func (m *UsersModel) AddShiftV2(uid string, shiftID string) error
AddShift will add a shift id into the user shifts array.
func (*UsersModel) AddVoucher ¶
func (m *UsersModel) AddVoucher(uid string, voucherID string) error
AddVoucher will add a voucher id into the user vouchers array.
func (*UsersModel) AddVoucherV2 ¶
func (m *UsersModel) AddVoucherV2(uid string, voucherId string) error
AddVoucher will add a voucher id into the user vouchers array.
type VoucherStatsResponse ¶
type VoucherStatsResponse struct { Pending int `json:"pending"` Confirmed int `json:"confirmed"` Confirming int `json:"confirming"` AwaitingProvider int `json:"awaiting_provider"` Error int `json:"error"` Complete int `json:"complete"` RefundTotal int `json:"refund_total"` RefundFee int `json:"refund_fee"` Refunded int `json:"refunded"` RefundedPartially int `json:"refunded_partially"` Total int `json:"total"` }
type VouchersModel ¶
type VouchersModel struct { Firestore *firestore.DocumentRef Collection string }
func (*VouchersModel) Get ¶
func (m *VouchersModel) Get(id string) (voucher hestia.Voucher, err error)
type VouchersModelV2 ¶
type VouchersModelV2 struct { Firestore *firestore.DocumentRef Collection string }
func (*VouchersModelV2) Get ¶
func (m *VouchersModelV2) Get(id string) (voucher hestia.VoucherV2, err error)
func (*VouchersModelV2) GetWithComposedQuery ¶
func (m *VouchersModelV2) GetWithComposedQuery(filters herodotus.VoucherV2Filters) (vouchers []hestia.VoucherV2, err error)
Click to show internal directories.
Click to hide internal directories.