MCPcopy Create free account
hub / github.com/APIParkLab/APIPark / UpdateSubscribeStatus

Method UpdateSubscribeStatus

service/subscribe/iml.go:129–138  ·  view source on GitHub ↗
(ctx context.Context, application string, service string, status int)

Source from the content-addressed store, hash-verified

127}
128
129func (i *imlSubscribeService) UpdateSubscribeStatus(ctx context.Context, application string, service string, status int) error {
130 info, err := i.store.First(ctx, map[string]interface{}{"service": service, "application": application})
131 if err != nil {
132 return err
133 }
134 info.ApplyStatus = status
135 info.ApproveAt = time.Now()
136 //info.Approver = utils.UserId(ctx)
137 return i.store.Save(ctx, info)
138}
139
140func (i *imlSubscribeService) MySubscribeServices(ctx context.Context, application string, serviceIDs []string) ([]*Subscribe, error) {
141 w := make(map[string]interface{})

Callers

nothing calls this directly

Calls 1

SaveMethod · 0.65

Tested by

no test coverage detected