示例#1
0
func getStatusesWebSocket(req *model.WebSocketRequest) (map[string]interface{}, *model.AppError) {
	statusMap := app.GetAllStatuses()
	return model.StatusMapToInterfaceMap(statusMap), nil
}
示例#2
0
func getStatusesHttp(c *Context, w http.ResponseWriter, r *http.Request) {
	statusMap := model.StatusMapToInterfaceMap(app.GetAllStatuses())
	w.Write([]byte(model.StringInterfaceToJson(statusMap)))
}