MCPcopy
hub / github.com/XiaoMi/naftis / ListTaskTmpls

Function ListTaskTmpls

src/api/handler/tasktmpl.go:38–47  ·  view source on GitHub ↗

ListTaskTmpls returns specified task template.

(c *gin.Context)

Source from the content-addressed store, hash-verified

36
37// ListTaskTmpls returns specified task template.
38func ListTaskTmpls(c *gin.Context) {
39 ids := make([]uint, 0, 1)
40 if idStr := c.Param("id"); idStr != "" {
41 ids = append(ids, cast.ToUint(idStr))
42 }
43 c.JSON(200, gin.H{
44 "code": 0,
45 "data": service.TaskTmpl.Get("", "", "", ids, 0, 0, 0, 0),
46 })
47}
48
49// ListTaskTmplVars returns variable map of specific task template.
50func ListTaskTmplVars(c *gin.Context) {

Callers

nothing calls this directly

Calls 1

GetMethod · 0.45

Tested by

no test coverage detected