public List <EMAsset> GetEMAssets(EMProfile emProfile) { var assets = entertainmentAssetCollection .Include(profile => profile.EMProfile) .Find(x => x.EMProfile.Id == emProfile.Id) .ToList(); return(assets); }
public EMProfile SaveEMProfile(EMProfile profile) { if (profile.Id == 0) { profile.Id = entertainmentProfileCollection.Insert(profile); } else { profile.Updated(); _ = entertainmentProfileCollection.Update(profile); } return(profile); }