示例#1
0
 public virtual async Task <ActionResult <TParentResource> > DeleteAll(ChildAlterResource childResource)
 {
     if (await IsUnauthorized(Operations.Alter))
     {
         return(Unauthorized());
     }
     return(await Application.DeleteAll(childResource.ParentId));
 }
        public ActionResult <TParentResource> DeleteLastChild()
        {
            var parent              = ParentResourceCreate.GetOrCreate();
            var childResource       = GetChildResource(parent).Last();
            var childDeleteResource = new ChildAlterResource()
            {
                ParentId = parent.Id
            };

            return(Client.Delete(childResource.Id, childDeleteResource).Result);
        }
示例#3
0
 public Task <ActionResult <TParentResource> > DeleteAll(ChildAlterResource childResource)
 {
     return(SendMethod <TParentResource>(HttpMethod.Delete, childResource));
 }
示例#4
0
 public Task <ActionResult <TParentResource> > Delete(string id, ChildAlterResource childResource)
 {
     return(SendMethod <TParentResource>(id, HttpMethod.Delete, childResource));
 }