func (o LayerManager) GetLayerBySession(sessionId int, db *mgo.Database, code string) map[string]interface{} { dictionaryManager := dictionary.GetInstance() result := dictionaryManager.GetDictionaryBySession(db, code) if result == nil { programDictionaryManager := dictionary.GetProgramDictionaryInstance() result = programDictionaryManager.GetProgramDictionaryBySession(sessionId, db, code) } return result }
func (c Component) Dicttest() revel.Result { dictionaryManager := dictionary.GetInstance() result := dictionaryManager.GetDictionary("D_DICTTEST") c.Response.ContentType = "application/json; charset=utf-8" return c.RenderJson(result) }