[SEBA-202] Adding remote_id
Change-Id: I9346ded6376e66aa571f835f970d6bba7a91353d
diff --git a/handlers.go b/handlers.go
index 791073e..ef2e5af 100644
--- a/handlers.go
+++ b/handlers.go
@@ -14,13 +14,13 @@
package main
import (
- "strconv"
"encoding/json"
"net/http"
+ "strconv"
+
"github.com/gorilla/mux"
)
-
func (c *Config) getSubscriberHandler(w http.ResponseWriter, r *http.Request) {
vars := mux.Vars(r)
sadisRequestID := vars["id"]
@@ -45,12 +45,12 @@
if sub.OnuSerialNumber == sadisRequestID {
log.Infof("Found subscriber with ID %s", sub.OnuSerialNumber)
sadisSubscriber := sadisSubscriber{
- ID: sub.OnuSerialNumber,
- CTag: sub.CTag,
- STag: sub.STag,
+ ID: sub.OnuSerialNumber,
+ CTag: sub.CTag,
+ STag: sub.STag,
NasPortID: sub.NasPortID,
CircuitID: sub.CircuitID,
- RemoteID: sub.CircuitID, // TODO get a proper value here
+ RemoteID: sub.RemoteID,
}
json, e := json.Marshal(&sadisSubscriber)
@@ -81,8 +81,8 @@
if devID == sadisRequestID {
log.Infof("Found OLT device with ID %s", devID)
sadisDevice := sadisDevice{
- ID: devID,
- Uplink: toInt(device.Uplink),
+ ID: devID,
+ Uplink: toInt(device.Uplink),
HardwareID: "de:ad:be:ef:ba:11", // TODO do we really need to configure this?
}