panlei
2019-11-20 3e447a37138bdf6d1c8f95f821f91c1701f35861
insertdata/insertDataToEs.go
@@ -97,6 +97,7 @@
type Target struct {
   TargetId       string  `json:"targetId"`
   TargetScore    float64 `json:"targetScore"`
   TargetType     string  `json:"targetType"`
   Feature        string  `json:"feature"`
   PicSmUrl       string  `json:"picSmUrl"`
   TargetLocation Points  `json:"targetLocation"`
@@ -187,6 +188,7 @@
                  var target = new(Target)
                  target.TargetId = face.Id
                  target.TargetScore = face.Score
                  target.TargetType = face.Type
                  target.Feature = base64.StdEncoding.EncodeToString(face.Feature)
                  target.PicSmUrl = resp["fileUrl"].(string)
                  target.TargetLocation = Points{TopLeft: Point{face.Location.X, face.Location.Y}, BottomRight: Point{face.Location.X + face.Location.Width, face.Location.Y + face.Location.Height}}