Skip to content

Commit e75f966

Browse files
committed
1.1.9.8
1 parent 2ec8cfb commit e75f966

4 files changed

Lines changed: 83 additions & 2 deletions

File tree

-87.6 KB
Binary file not shown.
88 KB
Binary file not shown.

Blazor.WebForm.Components/Blazor.WebForm.Components.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<TargetFramework>net5.0</TargetFramework>
55
<SignAssembly>true</SignAssembly>
66
<AssemblyOriginatorKeyFile>Blazor.WebForm.Components.pfx</AssemblyOriginatorKeyFile>
7-
<Version>1.1.9.7</Version>
7+
<Version>1.1.9.8</Version>
88
<RootNamespace>asp</RootNamespace>
99
<Copyright>Jurio li</Copyright>
1010
<AssemblyName>Blazor.WebForm.Components</AssemblyName>
@@ -17,7 +17,7 @@
1717

1818
<ItemGroup>
1919
<PackageReference Include="Applied" Version="1.2.1.6" />
20-
<PackageReference Include="Blazor.WebForm.UI" Version="1.1.9.7" />
20+
<PackageReference Include="Blazor.WebForm.UI" Version="1.1.9.8" />
2121
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="5.0.9" />
2222
</ItemGroup>
2323

Blazor.WebForm.Components/FreeDataSource.razor

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,12 @@
88
@code {
99
private OnExecuteSorted _executeSorted;
1010
private OnExecuteUpdated _executeUpdated;
11+
private OnExecuteUpdatedAsync _executeUpdatedAsync;
1112
private OnExecuteSelected _executeSelected;
1213
private OnExecuteDeleted _executeDeleted;
14+
private OnExecuteDeletedAsync _executeDeletedAsync;
1315
private OnExecuteInserted _executeInserted;
16+
private OnExecuteInsertedAsync _executeInsertedAsync;
1417

1518
[Parameter]
1619
public bool AutoSort
@@ -93,6 +96,27 @@
9396
}
9497
}
9598

99+
[Parameter]
100+
public OnExecuteUpdatedAsync OnExecuteUpdatedAsync
101+
{
102+
get
103+
{
104+
return _executeUpdatedAsync;
105+
}
106+
set
107+
{
108+
if (value != null)
109+
{
110+
this.Control.ExecuteUpdatedAsync += InvokeExecuteUpdatedAsync;
111+
}
112+
else
113+
{
114+
this.Control.ExecuteUpdatedAsync -= InvokeExecuteUpdatedAsync;
115+
}
116+
_executeUpdatedAsync = value;
117+
}
118+
}
119+
96120
[Parameter]
97121
public EventHandler OnDataSourceChanged
98122
{
@@ -148,6 +172,27 @@
148172
}
149173
}
150174

175+
[Parameter]
176+
public OnExecuteInsertedAsync OnExecuteInsertedAsync
177+
{
178+
get
179+
{
180+
return _executeInsertedAsync;
181+
}
182+
set
183+
{
184+
if (value != null)
185+
{
186+
this.Control.ExecuteInsertedAsync += InvokeExecuteInsertedAsync;
187+
}
188+
else
189+
{
190+
this.Control.ExecuteInsertedAsync -= InvokeExecuteInsertedAsync;
191+
}
192+
_executeInsertedAsync = value;
193+
}
194+
}
195+
151196
[Parameter]
152197
public OnExecuteDeleted OnExecuteDeleted
153198
{
@@ -169,6 +214,27 @@
169214
}
170215
}
171216

217+
[Parameter]
218+
public OnExecuteDeletedAsync OnExecuteDeletedAsync
219+
{
220+
get
221+
{
222+
return _executeDeletedAsync;
223+
}
224+
set
225+
{
226+
if (value != null)
227+
{
228+
this.Control.ExecuteDeletedAsync += InvokeExecuteDeletedAsync;
229+
}
230+
else
231+
{
232+
this.Control.ExecuteDeletedAsync -= InvokeExecuteDeletedAsync;
233+
}
234+
_executeDeletedAsync = value;
235+
}
236+
}
237+
172238
private void InvokeExecuteSorted(object sender, ref IEnumerable enumerable, DataSourceSelectArguments arguments)
173239
{
174240
_executeSorted.Invoke(sender, ref enumerable, arguments);
@@ -179,6 +245,11 @@
179245
_executeUpdated.Invoke(sender, keys, values, oldValues);
180246
}
181247

248+
private Task InvokeExecuteUpdatedAsync(object sender, IDictionary keys, IDictionary values, IDictionary oldValues)
249+
{
250+
return _executeUpdatedAsync.Invoke(sender, keys, values, oldValues);
251+
}
252+
182253
private IEnumerable InvokeExecuteSelected(object sender)
183254
{
184255
return _executeSelected.Invoke(sender);
@@ -189,8 +260,18 @@
189260
_executeDeleted.Invoke(sender, keys, oldValues);
190261
}
191262

263+
private Task InvokeExecuteDeletedAsync(object sender, IDictionary keys, IDictionary oldValues)
264+
{
265+
return _executeDeletedAsync.Invoke(sender, keys, oldValues);
266+
}
267+
192268
private void InvokeExecuteInserted(object sender, IDictionary values)
193269
{
194270
_executeInserted.Invoke(sender, values);
195271
}
272+
273+
private Task InvokeExecuteInsertedAsync(object sender, IDictionary values)
274+
{
275+
return _executeInsertedAsync.Invoke(sender, values);
276+
}
196277
}

0 commit comments

Comments
 (0)