mirror of
https://github.com/idanoo/autobrr
synced 2025-07-23 08:49:13 +00:00
feat: show irc network status in settings list
This commit is contained in:
parent
dcd1d458cf
commit
f103dff221
6 changed files with 221 additions and 11 deletions
|
@ -13,6 +13,7 @@ import (
|
|||
|
||||
type ircService interface {
|
||||
ListNetworks(ctx context.Context) ([]domain.IrcNetwork, error)
|
||||
GetNetworksWithHealth(ctx context.Context) ([]domain.IrcNetworkWithHealth, error)
|
||||
DeleteNetwork(ctx context.Context, id int64) error
|
||||
GetNetworkByID(id int64) (*domain.IrcNetwork, error)
|
||||
StoreNetwork(ctx context.Context, network *domain.IrcNetwork) error
|
||||
|
@ -46,7 +47,7 @@ func (h ircHandler) Routes(r chi.Router) {
|
|||
func (h ircHandler) listNetworks(w http.ResponseWriter, r *http.Request) {
|
||||
ctx := r.Context()
|
||||
|
||||
networks, err := h.service.ListNetworks(ctx)
|
||||
networks, err := h.service.GetNetworksWithHealth(ctx)
|
||||
if err != nil {
|
||||
//
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue