ListTaskTmpls returns specified task template.
(c *gin.Context)
| 36 | |
| 37 | // ListTaskTmpls returns specified task template. |
| 38 | func 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. |
| 50 | func ListTaskTmplVars(c *gin.Context) { |