Example #1
0
        public async Task <IActionResult> OnDeleteTweetAsync()
        {
            //Not implemented yet on server
            HttpResponseMessage Result = await DS.DeleteAsync("Twitter/DeleteTweet/" + ID);

            return(new JsonResult(Result.StatusCode));
        }
        public async Task <IActionResult> OnPostDeleteEpisodeAsync()
        {
            HttpResponseMessage message = await DS.DeleteAsync("Episodes/" + EpisodeID);


            JsonResult result = new JsonResult(message.StatusCode.ToString());

            return(result);
        }
Example #3
0
        public async Task <IActionResult> OnPostDelSplashNewsAsync()
        {
            if (ID == 0)
            {
                return(new JsonResult(null));
            }

            HttpResponseMessage result = await DS.DeleteAsync("SplashNews/DeleteSplashNews/" + ID);

            return(new JsonResult(result.StatusCode.ToString()));
        }
Example #4
0
        public async Task TestDelete()
        {
            Res = await DS.FindByIdAsync(100);

            Assert.IsTrue(Res.Success);

            Res = await DS.DeleteAsync(100);

            Assert.IsTrue(Res.Success, "Failed to delete an existing dataset.");

            Res = await DS.DeleteAsync(100);

            Assert.IsFalse(Res.Success, "Deleting a nonexistant dataset returns a success.");
        }