last changes before removing from memory and adding to db

This commit is contained in:
Norm Rasmussen
2022-06-15 21:56:30 -04:00
parent 3d6c43419a
commit fead4cdbd6
5 changed files with 1154 additions and 1120 deletions

File diff suppressed because it is too large Load Diff

View File

@ -1,5 +1,8 @@
@page "/accounts"
@inherits ActLogic
@using SqliteWasmHelper
@using BlazorWasmExample.Data
@using Microsoft.EntityFrameworkCore
@inject ISqliteWasmDbContextFactory<ThingContext> Factory
<PageTitle>Accounts</PageTitle>
@ -45,12 +48,6 @@
</body>
@code {
// Using Cascading Parameters
[Parameter]
public string? Account;
[CascadingParameter]
public string? AccountTask;
[CascadingParameter]
public string? TaskNote;
private string? newAccount;
private List<Account> accounts = new List<Account>();

View File

@ -1,6 +1,7 @@
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Components.Web;
using TodoList.Data;
using SqliteWasmHelper;
var builder = WebApplication.CreateBuilder(args);
@ -8,6 +9,8 @@ var builder = WebApplication.CreateBuilder(args);
builder.Services.AddRazorPages();
builder.Services.AddServerSideBlazor();
builder.Services.AddSingleton<WeatherForecastService>();
builder.Services.AddSqliteWasmDbContextFactory<ThingContext>(
opts => opts.UseSqlite("Data Source=blazor_todo.sqlite3"));
var app = builder.Build();

View File

@ -4,11 +4,12 @@
<TargetFramework>net6.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
<WasmBuildNative>true</WasmBuildNative
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Radzen.Blazor" Version="3.18.15" />
<PackageReference Include="sqlite-helper" Version="1.3.0" />
<ItemGroup>
<PackageReference Include="Radzen.Blazor" Version="3.18.15" />
<PackageReference Include="sqlite-helper" Version="1.3.0" />
</ItemGroup>
</Project>

View File

@ -358,6 +358,39 @@
"Components.NameMatch": "Components.FullyQualifiedNameMatch"
}
},
{
"HashCode": -850474101,
"Kind": "Components.Component",
"Name": "__GeneratedComponent.AspNetCore_6f55647a24fc3d69b0dc4cb39334dbc68a36af0f",
"AssemblyName": "TodoList",
"CaseSensitive": true,
"TagMatchingRules": [
{
"TagName": "AspNetCore_6f55647a24fc3d69b0dc4cb39334dbc68a36af0f"
}
],
"Metadata": {
"Runtime.Name": "Components.IComponent",
"Common.TypeName": "__GeneratedComponent.AspNetCore_6f55647a24fc3d69b0dc4cb39334dbc68a36af0f"
}
},
{
"HashCode": 1349245139,
"Kind": "Components.Component",
"Name": "__GeneratedComponent.AspNetCore_6f55647a24fc3d69b0dc4cb39334dbc68a36af0f",
"AssemblyName": "TodoList",
"CaseSensitive": true,
"TagMatchingRules": [
{
"TagName": "__GeneratedComponent.AspNetCore_6f55647a24fc3d69b0dc4cb39334dbc68a36af0f"
}
],
"Metadata": {
"Runtime.Name": "Components.IComponent",
"Common.TypeName": "__GeneratedComponent.AspNetCore_6f55647a24fc3d69b0dc4cb39334dbc68a36af0f",
"Components.NameMatch": "Components.FullyQualifiedNameMatch"
}
},
{
"HashCode": 1178284997,
"Kind": "Components.Component",