Exemplo n.º 1
0
        //Task<IEnumerable<IDocument>> IFolderManager.GetSharedDocument(string userId)
        //{
        //    throw new NotImplementedException();
        //}

        public async Task <IEnumerable <ResourceClaim> > SharedDocument(string id, string type, string[] users)
        {
            var resourceList = new List <ResourceClaim>();

            foreach (var user in users)
            {
                var addedResource = await _resourceManager.AddResourceClaimAsync(id, type, user, "View");

                if (addedResource != null)
                {
                    resourceList.Add(addedResource);
                }
            }

            return(resourceList);
        }