Put identifier in path (#48831)

This commit is contained in:
Alexander Weaver
2022-05-06 16:06:30 -05:00
committed by GitHub
parent 809aa38103
commit 99eaa0fc20
7 changed files with 70 additions and 70 deletions
@@ -86,6 +86,8 @@ func (srv *ProvisioningSrv) RoutePostContactPoint(c *models.ReqContext, cp apimo
}
func (srv *ProvisioningSrv) RoutePutContactPoint(c *models.ReqContext, cp apimodels.EmbeddedContactPoint) response.Response {
id := web.Params(c.Req)[":ID"]
cp.UID = id
err := srv.contactPointService.UpdateContactPoint(c.Req.Context(), c.OrgId, cp, alerting_models.ProvenanceAPI)
if err != nil {
return ErrResp(http.StatusInternalServerError, err, "")