随笔分类 - MVC / WebApi
摘要:using Cloudcubic.Common; namespace CloudCubic.Model.DTO.Base { /// <summary> /// 2023-04-23 新增 /// </summary> /// <typeparam name="T"></typeparam> pub
阅读全文
摘要:长时间不使用mvc容易忘记:故记录一下相关的内容 1:_layout布局中的RenderSection <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8" /> <meta name="viewport" content="wi
阅读全文
摘要:1:导入NuGet包 Microsoft.AspNetCore.Authentication.JwtBearer 2:配置 jwt相关信息 3:在 startUp中 1 public void ConfigureServices(IServiceCollection services){ 2 #re
阅读全文
只有注册用户登录后才能阅读该文。
摘要:直接干货: using System; using System.Collections.Generic; using System.Linq; using System.Net.Http; using System.Threading.Tasks; namespace FEG.ESB.Common
阅读全文
摘要:查了些资料,感觉很多码友,尤其是在Core那块写上传文件的代码,个人感觉写复杂了! 所以决定自己来个究竟!这里把mvc和core一起来做个小总结 还是先看如下截图(后台代码没有进行封装,只是测试) 1: MVC (这个就当自己再复习一遍) 2: Core3.0的一些截图 1:Asp.net MVC
阅读全文
摘要:这里就直接截图了,如下(很简单的操作): 1:Get几种请求 2:Post 3:Put 4:Delete 最后,虽然简单,代码还是给放一下(这里只是抛砖引玉的作用,自己可以根据自身的业务需要来做进一步的优化和封装): using System; using System.Collections.Ge
阅读全文
摘要:1:IBaseDAL 1 using System; 2 using System.Collections.Generic; 3 using System.Linq; 4 using System.Linq.Expressions; 5 using System.Text; 6 using Syst
阅读全文
摘要:1:Home/index.cshtml下面的Html代码 2:Home/index 下面的HomeController 3: Ajax的模拟代码,先登录,后获取授权,再带上Ticket,后台过滤器校验ok杂可以请求对应的接口 4: 创建的一个测试的 WebApiController 如ValuesC
阅读全文
摘要:封装自己的通用CURD By EF
阅读全文