随笔 - 785  文章 - 16 评论 - 39 阅读 - 166万
< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

12 2020 档案
.NetCore3.1 使用JWT认证授权时获取当前请求的用户名
摘要:在netcore5.0里,这样不行了 应该编入用户名,最后用HttpContext.User.Identity获取(从claim获取) // 最近使用JWT来给WebApi进行授权认证,在项目中使用 HttpContext.User.Identity.Name 获取当前登录的用户名一直获取不到,以往 阅读全文
posted @ 2020-12-29 18:24 qqhfeng16 阅读(2518) 评论(0) 推荐(1) 编辑
linq批量更新插入删除查询Z.EntityFramework.Extensions.EFCore申请扩充
摘要:https://entityframework-plus.net/ 阅读全文
posted @ 2020-12-29 15:48 qqhfeng16 阅读(279) 评论(0) 推荐(0) 编辑
Z.EntityFramework.Extensions.EFCore(实体框架的神奇扩充批量更新批量保存批量删除)特别高效
摘要:// @nuget: Microsoft.EntityFrameworkCore.SqlServer // @nuget: Z.EntityFramework.Extensions.EFCore // Website: https://entityframework-extensions.net/ 阅读全文
posted @ 2020-12-29 15:31 qqhfeng16 阅读(998) 评论(0) 推荐(0) 编辑
asp.net core 5,0 项目中Add-Migration 执行报错 (可能不小心删掉了,安装后真的可以用了!!!)
摘要:错误提示: Add-Migration : The term 'Add-Migration' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelli 阅读全文
posted @ 2020-12-25 18:52 qqhfeng16 阅读(278) 评论(0) 推荐(0) 编辑
EF Core索引
摘要: 阅读全文
posted @ 2020-12-23 08:41 qqhfeng16 阅读(107) 评论(0) 推荐(0) 编辑
NET Core中的DataAnnotations
摘要: 阅读全文
posted @ 2020-12-23 08:35 qqhfeng16 阅读(319) 评论(0) 推荐(0) 编辑
Migration数据迁移命令
摘要: 阅读全文
posted @ 2020-12-23 08:34 qqhfeng16 阅读(170) 评论(0) 推荐(0) 编辑
Asp.Net Core报错System.Text.Json.JsonException: A possible object cycle was detected which is not supp(配置导航属性的时候出现的错误)
摘要:Asp.Net Core报错:System.Text.Json.JsonException: A possible object cycle was detected which is not supported. This can either be due to a cycle or if th 阅读全文
posted @ 2020-12-23 08:09 qqhfeng16 阅读(214) 评论(0) 推荐(0) 编辑
vs2019 netcore 5.0 连接mysql数据库踩下的坑。不要再测试其他 Pomelo.EntityFreameworkCore.Mysql,那些网上的都是针对3.x 根本就不行
摘要:1、netcore 5.0 太新了,vs2019里面没有nuget里面没有最新的 包。 2、不要用mysql官方的,那个不行。用pomelo这个,这是微软文档指定的,兼容性肯定好。 最新的包还是测试版。找到这个地方,启动 nuget命令行,手动安装包。 解决办法: 3.第三步 找到 github的网 阅读全文
posted @ 2020-12-22 11:50 qqhfeng16 阅读(563) 评论(0) 推荐(0) 编辑
Ubuntu部署Asp.net core网站无法访问
摘要: 阅读全文
posted @ 2020-12-19 22:10 qqhfeng16 阅读(127) 评论(0) 推荐(0) 编辑
关于发布dotnet 无法显示页面的问题(可以正常运行,但是页面不显示) 单独运行(windows 和 ubuntu 一样处理)
摘要:不论是debug、release、release\publish 这三种文件夹 错误的方式:(貌似运行成功了,但是就是不显示页面) D:\vscodeapp\netcore50\alyun\myapi\bin\Release\net5.0\publish>dotnet myapi.dll 方式1:( 阅读全文
posted @ 2020-12-19 21:57 qqhfeng16 阅读(264) 评论(0) 推荐(0) 编辑
.Net Core 5.0 TagHelper的使用 关键的关键是 引入命名空间就行,不能是具体的类名
摘要:.Net Core 5.0 TagHelper的使用 关键的关键是 引入命名空间就行,不能是具体的类名 阅读全文
posted @ 2020-12-14 16:51 qqhfeng16 阅读(134) 评论(0) 推荐(0) 编辑
SqlCommandBuilder 为SqlDataAdapter 提供 update、insert、delete 命令(自己利用select命令自动从数据库元数据推断)
摘要://SqlCommandBuilder 为 SqlDataAdapter 提供 update、insert、delete 命令(自己利用select命令自动从数据库元数据推断) //select命令必须包含主键(SqlCommandBuilder 自己去推断其他的三个命令) //推断完成后,不需要对 阅读全文
posted @ 2020-12-06 12:09 qqhfeng16 阅读(216) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示