public GroupController() { CollectionController collectionController = new CollectionController(); UserProfileController userProfileController = new UserProfileController(); if (_list == null) { _list = new List <Group> { new Group() { Id = Guid.NewGuid(), Name = "Família", Collection = collectionController.Get("PKM99"), Participants = userProfileController.Get() }, new Group() { Id = Guid.NewGuid(), Name = "Trabalho", Collection = collectionController.Get("FWC18"), Participants = userProfileController.Get().Where(x => x.Login.Equals("lucasbbudelon") || x.Login.Equals("lady")).ToList() }, new Group() { Id = Guid.NewGuid(), Name = "Faculdade", Collection = collectionController.Get("TLK94"), Participants = userProfileController.Get().Where(x => x.Login.Equals("lucasbbudelon") || x.Login.Equals("veri")).ToList() } }; } }
//// POST: api/Default //[HttpPost] //public void Post([FromBody]string value) //{ //} //// PUT: api/Default/5 //[HttpPut("{id}")] //public void Put(int id, [FromBody]string value) //{ //} #region PRIVATE private Album GetAlbum(string codeCollection, string userProfileLogin) { var collection = new CollectionController().Get(codeCollection); var userProfile = new UserProfileController().GetByLogin(userProfileLogin); return(new Album() { Id = Guid.NewGuid(), Collection = collection, UserProfile = userProfile, Items = GetItems(collection) }); }