本文整理汇总了Golang中One/Service/ProjectService.ProjectService.ActionType方法的典型用法代码示例。如果您正苦于以下问题:Golang ProjectService.ActionType方法的具体用法?Golang ProjectService.ActionType怎么用?Golang ProjectService.ActionType使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类One/Service/ProjectService.ProjectService
的用法示例。
在下文中一共展示了ProjectService.ActionType方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。
示例1: HandleProjectAllGet
func HandleProjectAllGet(c *gin.Context) {
var result = make(map[string]interface{}, 16)
var userid string
//var cookieid string
var projectid string
userid = c.Params.ByName("personid")
if userid == "" {
result["code"] = 400
result["descrip"] = "userid is empty"
result["data"] = nil
c.JSON(200, result)
return
}
ser := new(Service.ProjectService)
ser.Userid = tools.ToInt64(userid)
ser.Projectid = tools.ToInt64(projectid)
ser.ActionType = Service.PROJECT_GET_ACTION
ser.ServerType = Service.PROJECT_ALL_SERVICE_TYPE
ok, _ := ser.ProcessService()
result["code"] = 0
result["descrip"] = "ok"
result["data"] = ser.Container
if ok == false {
tools.Info(result)
c.JSON(200, result)
return
}
c.JSON(200, result)
return
}
示例2: HandleProjectStaticsGet
func HandleProjectStaticsGet(c *gin.Context) {
var result = make(map[string]interface{}, 16)
var userid string
var projectid string
// var cookieid string
ser := new(Service.ProjectService)
ser.Userid = tools.ToInt64(userid)
ser.Projectid = tools.ToInt64(projectid)
ser.ActionType = Service.PROJECT_GET_ACTION
ok, _ := ser.ProcessService()
result["code"] = ok
result["result"] = ser.Container
if ok == false {
tools.Info(result)
}
}