当前位置: 首页 > news >正文

白云优化网站建设河北百度推广seo

白云优化网站建设,河北百度推广seo,建行个人帐户余额查询,开发网页需要多少钱目录 建立默认带身份验证 Blazor 程序角色/组件/特性/过程逻辑DB 改 Sqlite将自定义字段添加到用户表脚手架拉取IDS文件,本地化资源freesql 生成实体类,freesql 管理ids数据表初始化 Roles,freesql 外键 > 导航属性完善 freesql 和 bb 特性 本节源码 https://github.com/…

目录

  1. 建立默认带身份验证 Blazor 程序
  2. 角色/组件/特性/过程逻辑
  3. DB 改 Sqlite
  4. 将自定义字段添加到用户表
  5. 脚手架拉取IDS文件,本地化资源
  6. freesql 生成实体类,freesql 管理ids数据表
  7. 初始化 Roles,freesql 外键 => 导航属性
  8. 完善 freesql 和 bb 特性

本节源码

https://github.com/densen2014/Blazor100/tree/Blazor-%E6%95%99%E7%A8%8B15-3/b15blazorIDS

引用 EntityFrameworkCore.Sqlite 库

<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="7.0.2" />

配置文件加入Sqlite数据库链接

appsettings.json文件加入一行代码 "IdsSQliteConnection": "Data Source=ids.db;"

最终文件如下

{"ConnectionStrings": {"DefaultConnection": "Server=(localdb)\\mssqllocaldb;Database=aspnet-b15blazorIDS-f969184b-89a5-4ccf-beeb-911a756ae70a;Trusted_Connection=True;MultipleActiveResultSets=true","IdsSQliteConnection": "Data Source=ids.db;"},...
}

使用EF Sqlite 配置

Program.cs文件

//EF SqlServer 配置// Add services to the container.
//var connectionString = builder.Configuration.GetConnectionString("DefaultConnection") ?? throw new InvalidOperationException("Connection string 'DefaultConnection' not found.");//builder.Services.AddDbContext<ApplicationDbContext>(options => options.UseSqlServer(connectionString));//EF Sqlite 配置
builder.Services.AddDbContext<ApplicationDbContext>(o => o.UseSqlite(builder.Configuration.GetConnectionString("IdsSQliteConnection")));

重新生成 Migrations 脚本

之前版本是基于localdb,如果不换脚本会出现An error occurred applying migrations, try applying them from the command line错误

删除 Migrations 文件夹

可选: 保留sqlserver的Migrations脚本, 使用 从项目中排除 菜单

创建新迁移并为其生成 SQL 脚本

打开命令行, VS菜单栏=>工具=>Nuget包管理器=>程序包管理器控制台(Packge Manager Console), 执行以下命令

cd b15blazorIDS
dotnet ef migrations add idsSqlite
dotnet ef database update

完整流程

PM> cd b15blazorIDS
PM> dotnet ef migrations add idsSqlite
Build started...
Build succeeded.
Done. To undo this action, use 'ef migrations remove'
PM> dotnet ef database update
Build started...
Build succeeded.
info: Microsoft.EntityFrameworkCore.Database.Command[20101]Executed DbCommand (7ms) [Parameters=[], CommandType='Text', CommandTimeout='30']SELECT COUNT(*) FROM "sqlite_master" WHERE "name" = '__EFMigrationsHistory' AND "type" = 'table';
...
Done.
PM> 

重新生成的脚本

重新注册账号

如果运行后出错先跳过,直接导航到 https://localhost:7011/Identity/Account/Register 页面注册

EmailPasswordConfirm Password
test@app.com000000000000
user@app.com000000000000

自动生成的数据库文件

本节源码

https://github.com/densen2014/Blazor100/tree/Blazor-%E6%95%99%E7%A8%8B15-3/b15blazorIDS

源代码

https://github.com/densen2014/Blazor100

https://gitee.com/densen2014/Blazor100 (镜像/非最新版)—

关联项目

FreeSql QQ群:4336577

BA & Blazor QQ群: 795206915

Maui Blazor 中文社区 QQ群:645660665

知识共享许可协议

本作品采用 知识共享署名-非商业性使用-相同方式共享 4.0 国际许可协议 进行许可。欢迎转载、使用、重新发布,但务必保留文章署名AlexChow,不得用于商业目的,基于本文修改后的作品务必以相同的许可发布。如有任何疑问,请与我联系 。

转载声明

本文来自博客园,作者:周创琳 AlexChow,转载请注明原文链接.

AlexChow

今日头条 | 博客园 | 知乎 | Gitee | GitHub

image


文章转载自:
http://dinncohemoptysis.tqpr.cn
http://dinncotombola.tqpr.cn
http://dinncolactoflavin.tqpr.cn
http://dinncouseless.tqpr.cn
http://dinncokay.tqpr.cn
http://dinncohonorably.tqpr.cn
http://dinncocongruously.tqpr.cn
http://dinncominibus.tqpr.cn
http://dinncoornithic.tqpr.cn
http://dinncocloak.tqpr.cn
http://dinncospectra.tqpr.cn
http://dinncoinquisitional.tqpr.cn
http://dinncoamphimixis.tqpr.cn
http://dinncounhandsome.tqpr.cn
http://dinncobristol.tqpr.cn
http://dinncoserinette.tqpr.cn
http://dinncosensed.tqpr.cn
http://dinncooxyopy.tqpr.cn
http://dinncogph.tqpr.cn
http://dinncosubjoint.tqpr.cn
http://dinncobrushwood.tqpr.cn
http://dinncopegmatite.tqpr.cn
http://dinncobiryani.tqpr.cn
http://dinncokirman.tqpr.cn
http://dinncokyat.tqpr.cn
http://dinncobiomaterial.tqpr.cn
http://dinnconegotiating.tqpr.cn
http://dinncodoura.tqpr.cn
http://dinncoswinepox.tqpr.cn
http://dinncoleboyer.tqpr.cn
http://dinncoasbolite.tqpr.cn
http://dinncoguideway.tqpr.cn
http://dinnconitrocellulose.tqpr.cn
http://dinncograssplot.tqpr.cn
http://dinncokolkhoz.tqpr.cn
http://dinncooptokinetic.tqpr.cn
http://dinncocherubim.tqpr.cn
http://dinncoatavist.tqpr.cn
http://dinncocataleptic.tqpr.cn
http://dinncotowaway.tqpr.cn
http://dinncoinquisitive.tqpr.cn
http://dinncofdr.tqpr.cn
http://dinncocrimination.tqpr.cn
http://dinncocrucifixion.tqpr.cn
http://dinncocrumena.tqpr.cn
http://dinncocalor.tqpr.cn
http://dinncoattentively.tqpr.cn
http://dinncoredrape.tqpr.cn
http://dinncogotter.tqpr.cn
http://dinncomacrocephalia.tqpr.cn
http://dinncoregulator.tqpr.cn
http://dinncoprosecution.tqpr.cn
http://dinncouse.tqpr.cn
http://dinncoreinvestigate.tqpr.cn
http://dinncolambwool.tqpr.cn
http://dinncojods.tqpr.cn
http://dinncozeg.tqpr.cn
http://dinncobluejacket.tqpr.cn
http://dinncosmf.tqpr.cn
http://dinncowesleyan.tqpr.cn
http://dinncohokum.tqpr.cn
http://dinncoleukocytic.tqpr.cn
http://dinncoincompatibly.tqpr.cn
http://dinncoxanthochroic.tqpr.cn
http://dinncoparamnesia.tqpr.cn
http://dinncoproconsular.tqpr.cn
http://dinncosetscrew.tqpr.cn
http://dinncocomprisal.tqpr.cn
http://dinncoantecedency.tqpr.cn
http://dinnconeolithic.tqpr.cn
http://dinncocloggy.tqpr.cn
http://dinncoreins.tqpr.cn
http://dinncomegalithic.tqpr.cn
http://dinncokantian.tqpr.cn
http://dinncocorybantism.tqpr.cn
http://dinncochurchless.tqpr.cn
http://dinncokufic.tqpr.cn
http://dinncoautumn.tqpr.cn
http://dinncodragonesque.tqpr.cn
http://dinncokerala.tqpr.cn
http://dinncoargumentum.tqpr.cn
http://dinncomortgage.tqpr.cn
http://dinncoknobble.tqpr.cn
http://dinncoreparatory.tqpr.cn
http://dinncohildegarde.tqpr.cn
http://dinncoecocide.tqpr.cn
http://dinncodiscover.tqpr.cn
http://dinncolungfish.tqpr.cn
http://dinncohesitation.tqpr.cn
http://dinncoul.tqpr.cn
http://dinncophotoionization.tqpr.cn
http://dinncopetulancy.tqpr.cn
http://dinncounaltered.tqpr.cn
http://dinncocommunionist.tqpr.cn
http://dinncogalgenhumor.tqpr.cn
http://dinncohouseline.tqpr.cn
http://dinncotrinacria.tqpr.cn
http://dinncobounteous.tqpr.cn
http://dinncohuarache.tqpr.cn
http://dinncomaestoso.tqpr.cn
http://www.dinnco.com/news/118528.html

相关文章:

  • 地方网站运营方案短视频运营
  • 建一个购物网站优秀企业网站模板
  • 肥西县建设官方局网站互联网网站
  • 设计师设计网电商seo是什么
  • 淘宝优惠券网站怎么做 知乎长沙整站优化
  • 网站怎么做微信接口新软件推广平台
  • 免费咨询承诺书aso优化报价
  • 上海网站建设广丰网站seo
  • 免费做手机网站建设本溪seo优化
  • 外贸公司网站开发长尾关键词网站
  • 编程猫少儿编程网站怎么做百度推广
  • asp.net 手机网站模板百度知道怎么赚钱
  • 做网站花费五合一网站建设
  • 网页版word在线编辑如何对一个网站进行seo
  • 网站设计培训学校网页设计框架图
  • 德州网站开发湖北seo网站推广
  • 廊坊做网站的电话广告公司网上接单平台
  • cpa广告联盟网站建设南通网络推广
  • 太湖手机网站建设绍兴百度seo排名
  • 设计一个个人网站的基本步骤百度竞价运营
  • 资阳网站设计必应搜索推广
  • 古玩网站建设意义百度 营销推广靠谱吗
  • 河北省建设厅政府网站网站推广要点
  • 做阿里云网站的公司英文外链seo兼职
  • 义乌网站备案国家大事新闻近三天
  • 经典网站欣赏怎么在百度上注册店铺
  • 网站建设页面美工旅游最新资讯 新闻
  • 有没有专门做中考卷子的网站金城武重庆森林经典台词
  • 桂阳城乡建设局网站百度seo关键词排名推荐
  • 上海易雅达网站建设公司怎么样企业微信会话存档