public IActionResult OnGet() { Parents = ApiExtension.GetAsync <IEnumerable <SelectListItem> >( GlobalParameter.ApiBaseAddress, "/api/Document/GetForSelectList", HttpContext.Session.GetString("Token")).Result; return(Page()); }
public IActionResult OnGet() { ArticleGroupsModel = ApiExtension.GetAsync <IEnumerable <Model.Entity.Blog.ArticleGroup> >( GlobalParameter.ApiBaseAddress, "/api/ArticleGroup/GetAll", HttpContext.Session.GetString("Token")).Result; return(Page()); }
public IActionResult OnGet() { MasterModel = ApiExtension.GetAsync <IEnumerable <Model.Entity.BaseInfo.MasterDetail> >( GlobalParameter.ApiBaseAddress, "api/MasterDetail/GetAllMaster", HttpContext.Session.GetString("Token")).Result; return(Page()); }
//public IEnumerable<Document> DocumentsModel { get; set; } public IActionResult OnGet(Guid documentId = default) { DocumentModel = ApiExtension.GetAsync <Document>(GlobalParameter.ApiBaseAddress, "/api/Document/GetByIdWithImageChildrens", headers: new Dictionary <string, string> { { "Id", documentId == default ? GlobalParameter.GetStartDocumentId.ToString() : documentId.ToString() } }).Result;
public IActionResult OnGet(Guid articleGroupId) { ArticleGroupId = articleGroupId; ArticlesModel = ApiExtension.GetAsync <IEnumerable <Article> >(GlobalParameter.ApiBaseAddress, "/api/article/GetAllWithGroupAndImage", headers: new Dictionary <string, string> { { "ArticleGroupId", articleGroupId.ToString() } }).Result; return(Page()); }
public IActionResult OnGet() { ArticleGroups = ApiExtension.GetAsync <IEnumerable <SelectListItem> >( GlobalParameter.ApiBaseAddress, "/api/ArticleGroup/GetForSelectList", HttpContext.Session.GetString("Token"), new Dictionary <string, string> { { "ArticleGroupId", Guid.Empty.ToString() } }).Result; return(Page()); }
public IActionResult OnGet(Guid articleId) { ArticleModel = ApiExtension.GetAsync <Article>(GlobalParameter.ApiBaseAddress, "/api/article/GetWithGroupAndImage", headers: new Dictionary <string, string> { { "Id", articleId.ToString() } }).Result; if (ArticleModel == null) { return(Redirect("/vBlog/ArticleGroup")); } return(Page()); }
public IActionResult OnGet(Guid articleId) { Article = ApiExtension.PostAsync <Model.Entity.Blog.Article, Guid>( GlobalParameter.ApiBaseAddress, "/api/Article/GetById", articleId, HttpContext.Session.GetString("Token")).Result; ArticleImagesModel = ApiExtension.GetAsync <IEnumerable <Model.Entity.Blog.ArticleImage> >( GlobalParameter.ApiBaseAddress, "/api/ArticleImage/GetByArticleId", HttpContext.Session.GetString("Token"), new Dictionary <string, string> { { "ArticleId", articleId.ToString() } }).Result; return(Page()); }
public IActionResult OnGet(Guid documentId) { Document = ApiExtension.PostAsync <Model.Entity.Blog.Document, Guid>( GlobalParameter.ApiBaseAddress, "/api/Document/GetById", documentId, HttpContext.Session.GetString("Token")).Result; DocumentImagesModel = ApiExtension.GetAsync <IEnumerable <Model.Entity.Blog.DocumentImage> >( GlobalParameter.ApiBaseAddress, "/api/DocumentImage/GetByDocumentId", HttpContext.Session.GetString("Token"), new Dictionary <string, string> { { "DocumentId", documentId.ToString() } }).Result; return(Page()); }
public IActionResult OnGet(Guid id) { Parents = ApiExtension.GetAsync <IEnumerable <SelectListItem> >( GlobalParameter.ApiBaseAddress, "/api/ArticleGroup/GetForSelectList", HttpContext.Session.GetString("Token"), new Dictionary <string, string> { { "ArticleGroupId", id.ToString() } }).Result; ArticleGroupModel = ApiExtension.PostAsync <Model.Entity.Blog.ArticleGroup, Guid>( GlobalParameter.ApiBaseAddress, "/api/ArticleGroup/GetById", id, HttpContext.Session.GetString("Token")).Result; return(Page()); }
public IActionResult OnGet() { ArticleGroupsModel = ApiExtension.GetAsync <IEnumerable <ArticleGroup> >(GlobalParameter.ApiBaseAddress, "/api/ArticleGroup/GetAllWithArticleAndChilds").Result; return(Page()); }