MCPcopy
hub / github.com/koderover/zadig / UpdateOperationLogStatus

Function UpdateOperationLogStatus

pkg/middleware/gin/audit_log.go:35–45  ·  view source on GitHub ↗

更新操作日志状态

(c *gin.Context)

Source from the content-addressed store, hash-verified

33
34// 更新操作日志状态
35func UpdateOperationLogStatus(c *gin.Context) {
36 c.Next()
37 if c.GetString("operationLogID") == "" {
38 return
39 }
40 log := ginzap.WithContext(c).Sugar()
41 err := systemservice.UpdateOperation(c.GetString("operationLogID"), c.Writer.Status(), log)
42 if err != nil {
43 log.Errorf("UpdateOperation err:%v", err)
44 }
45}

Callers 1

OperationLogStatusFunction · 0.85

Calls 5

WithContextFunction · 0.92
NextMethod · 0.80
GetStringMethod · 0.80
StatusMethod · 0.65
ErrorfMethod · 0.45

Tested by

no test coverage detected