Skip to content

Commit 86f96b7

Browse files
committed
Sync with Kendo UI Professional
1 parent 0eb8918 commit 86f96b7

File tree

33 files changed

+271
-110
lines changed

33 files changed

+271
-110
lines changed

docs-aspnet/html-helpers/helper-basics/using-client-templates.md

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ The available template types are:
1616

1717
* [Inline Client Templates](#inline-client-templates)
1818
* [External Client Templates](#external-client-templates)
19+
* [Partial Client Templates](#partial-client-templates)
1920
* [Content Security Policy Templates](#content-security-policy-csp-templates)
2021

2122

@@ -216,6 +217,76 @@ For example, you can define an external client template for a [Grid column]({% s
216217
217218
218219
Also, you can integrate Telerik UI for {{ site.framework }} components in the external client templates by using the [HTML Helpers](#adding-html-helpers-inside-external-client-templates) {% if site.core %}or [Tag Helpers](adding-tag-helpers-inside-external-client-templates){% endif %}.
220+
## Partial Client Templates
221+
222+
As of the R1 SP1 2023 release, the majority of the Telerik UI for {{ site.framework }} components expose the ability to include arbitrary client template content within the boundaries of a Partial View by using the respective component's new `TemplateView` method.
223+
224+
The example below illustrates how to incorporate the Grid Toolbar's template content within a Partial View.
225+
226+
```HtmlHelper
227+
@(Html.Kendo().Grid<Kendo.Mvc.Examples.Models.ProductViewModel>()
228+
.Name("grid")
229+
.Columns(columns => {
230+
columns.Bound(p => p.ProductID).Visible(true).Width(100);
231+
columns.Bound(p => p.ProductName);
232+
columns.Bound(p => p.UnitPrice).Width(150);
233+
columns.Bound(p => p.QuantityPerUnit);
234+
})
235+
.ToolBar(toolbar => {
236+
toolbar.ClientTemplateView(Html.Partial("_ToolbarTemplatePartial"));
237+
})
238+
.DataSource(dataSource => dataSource
239+
.Ajax()
240+
.ServerOperation(false)
241+
.Model(model => model.Id(p => p.ProductID))
242+
.Read("ToolbarTemplate_Read", "Grid")
243+
)
244+
)
245+
```
246+
{% if site.core %}
247+
```TagHelper
248+
<kendo-grid name="grid" height="500">
249+
<columns>
250+
<column field="ProductID" visible="true" width="100">
251+
<exportable pdf="true" />
252+
</column>
253+
<column field="ProductName">
254+
</column>
255+
<column field="UnitPrice" width="150">
256+
</column>
257+
<column field="QuantityPerUnit">
258+
</column>
259+
</columns>
260+
<toolbar client-template-view="@Html.Partial("_ToolbarTemplatePartial")">
261+
</toolbar>
262+
<datasource page="0" type="DataSourceTagHelperType.Ajax" page-size="20" server-operation="false">
263+
<schema data="Data" total="Total" errors="Errors">
264+
<model id="ProductID"></model>
265+
</schema>
266+
<transport>
267+
<read url="@Url.Action("ToolbarTemplate_Read","Grid")" />
268+
</transport>
269+
</datasource>
270+
</kendo-grid>
271+
```
272+
{% endif %}
273+
```_Partial.cshtml
274+
<div class="toolbar">
275+
<label class="category-label" for="category">Show products by category:</label>
276+
@(Html.Kendo().DropDownList()
277+
.Name("categories")
278+
.OptionLabel("All")
279+
.DataTextField("CategoryName")
280+
.DataValueField("CategoryID")
281+
.HtmlAttributes(new { style = "width: 150px;" })
282+
.DataSource(ds =>
283+
{
284+
ds.Read("ToolbarTemplate_Categories", "Grid");
285+
})
286+
.ToClientTemplate()
287+
)
288+
</div>
289+
```
219290

220291
### Adding HTML Helpers inside External Client Templates
221292

docs-aspnet/installation/migrating.md

Lines changed: 40 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -13,52 +13,64 @@ The MVC technology 3, 4 and 5 has been a wonderful technology for many years. It
1313

1414
ASP.NET Core is the active offering of Microsoft and provides cross-platform ground for building and running .NET apps on Linux, macOS, and Windows. This is the technology that will get updates going forward. So naturally, many people will want to choose developing Core MVC web applications.
1515

16-
Telerik UI has well supported and developed Products for each of these technologies. This article aims to help you with the process of migrating from MVC to Core MVC if this happens to be your decision.
16+
Telerik UI has well supported and developed products for each of these technologies through its [Telerik UI for ASP.NET MVC](https://demos.telerik.com/aspnet-mvc/) and [Telerik UI for ASP.NET Core](https://demos.telerik.com/aspnet-core/) libraries.
17+
18+
This article aims at helping you with the process of migrating from ASP.NET MVC to ASP.NET Core.
1719

1820
## Compatibility
1921

20-
The good news is that there is almost 1:1 parity between the two UI toolsets. The transition should be smooth, easy and fully feature covered.
22+
The good news is that there is almost 1:1 parity between the two UI toolsets. The transition is smooth, easy, and fully feature-covered. For any minor variations, check the [section about exceptions](#exceptions) to find out where the products differ from one another.
2123

22-
For reference, you can compare the Code base of these two live samples and you will notice that the syntax is identical:
24+
For reference, compare the code base of the following live samples to make sure the syntax is identical:
2325

24-
- [Grid in Telerik UI for MVC](https://demos.telerik.com/aspnet-mvc/grid/local-data-binding).
25-
- [Grid in Telerik UI for Core MVC](https://demos.telerik.com/aspnet-core/grid/local-data-binding)
26+
- [Telerik UI for ASP.NET MVC Data Grid](https://demos.telerik.com/aspnet-mvc/grid/local-data-binding).
27+
- [Telerik UI for ASP.NET Core Data Grid](https://demos.telerik.com/aspnet-core/grid/local-data-binding)
2628

2729
## Exceptions
2830

2931
There are couple of differences worth mentioning to ease your migration process.
3032

31-
1. MVC Grid server rendered templates should transfer to client rendered templates in Core MVC Grid. Therefore, you will now use `.HeaderTemplate()` instead of `.ClientHeaderTemplate()`.
33+
1. The MVC Grid server-rendered templates must transfer to client-rendered templates in Core Grid. Therefore, you will now use `.HeaderTemplate()` instead of `.ClientHeaderTemplate()`.
34+
35+
2. Check out the [Migrate to ASP.NET Core MVC from ASP.NET Framework MVC](https://www.telerik.com/blogs/migrate-aspnet-core-mvc-aspnet-framework-mvc) blog post by Joe Guadagno to explore the common code-behind steps while migrating an app to ASP.NET Core MVC.
36+
37+
Some key takeaways from this blog are:
3238

33-
2. We have a Blog post covering common code-behind steps:
39+
- **Separate the Models**–Putting your domain or data transfer objects into a separate project.
40+
- **Separate the Data Layer**–Getting data access methods out of the user interface (web app).
41+
- **Create a New Project**–Analyzing the structure differences of a project in the new technology: folders, files, and so on.
42+
- **Gotchas**–Possible things that may stump you during the migration process.
3443

35-
[Migrate to ASP.NET Core MVC from ASP.NET Framework MVC](https://www.telerik.com/blogs/migrate-aspnet-core-mvc-aspnet-framework-mvc)
44+
3. The rest are syntax sugar differences caused by the frameworks themselves. These are present only for some of the components. For instance, here is a Validation action definition of the Upload component in MVC:
3645

37-
3. The rest are syntax sugar differences caused by the frameworks themselves. For instance, here is a Validation action definition of the Upload component in MVC:
38-
```C#
39-
public ActionResult Validation_Save(IEnumerable<HttpPostedFileBase> files)
40-
{
41-
}
42-
```
43-
And this is the equivalent implementation in Core MVC:
44-
```C#
45-
public async Task<ActionResult> Validation_Save(IEnumerable<IFormFile> files)
46-
{
47-
}
48-
```
46+
```C#
47+
public ActionResult Validation_Save(IEnumerable<HttpPostedFileBase> files)
48+
{
49+
}
50+
```
4951

50-
4. The same is true for the **Startup.cs** file:
52+
The following is the equivalent implementation in Core MVC:
5153

52-
[JSON serialization in Core](https://docs.telerik.com/aspnet-core/installation/json-serialization)
54+
```C#
55+
public async Task<ActionResult> Validation_Save(IEnumerable<IFormFile> files)
56+
{
57+
}
58+
```
5359

54-
5. You can check this nice MSDN article for general points when migrating:
60+
4. The same is true for the `Startup.cs` file. Check out the [JSON serialization in Core](https://docs.telerik.com/aspnet-core/installation/json-serialization) article to see how to configure it.
5561

56-
[Migrate from ASP.NET MVC to ASP.NET Core MVC](https://learn.microsoft.com/en-us/aspnet/core/migration/mvc?view=aspnetcore-7.0)
62+
5. You can check the [Migrate from ASP.NET MVC to ASP.NET Core MVC](https://learn.microsoft.com/en-us/aspnet/core/migration/mvc?view=aspnetcore-7.0) MSDN article for general points when migrating.
5763

64+
Some key takeaways from this article are:
65+
66+
- Install the .NET Upgrade Assistant.
67+
- Open Visual Studio and choose the **Upgrade** action in the **Solution Explorer** context menu.
68+
- Check the **Summary of Changes** before pressing **Finish**.
5869

5970
## Migrating from Another Technology
6071

61-
If you are coming from another Telerik UI toolset, we have resources addressing this situation as well:
62-
- [From Web Forms to Core](https://www.telerik.com/blogs/review-of-telerik-toolsets-for-aspnet-web-forms-core)
63-
- [From Web Forms to Blazor](https://www.telerik.com/blogs/review-of-telerik-toolsets-for-asp.net-web-forms-and-blazor-part-1)
64-
- [From MVC to Blazor](https://www.telerik.com/blogs/migrating-mvc-to-blazor)
72+
If you are coming from another Telerik UI toolset, refer to the following resources addressing this scenario:
73+
74+
- [From Web Forms to Core](https://www.telerik.com/blogs/review-of-telerik-toolsets-for-aspnet-web-forms-core)–A blog post and whitepaper, which aim to assist developers in familiarizing quickly with the overall idea of ASP.NET Web Forms and ASP.NET Core. They also outline a couple of fundamental steps for customers who’ve decided to create a new application based on ASP.NET Core, or modernize their existing Web Forms app by switching to a Core app.
75+
- [From Web Forms to Blazor](https://www.telerik.com/blogs/review-of-telerik-toolsets-for-asp.net-web-forms-and-blazor-part-1)–A blog post series divided into three parts. These serve as a guide for developers to learn what Telerik has to offer for both technologies and how to migrate from ASP.NET AJAX to the newest .NET technology - Blazor.
76+
- [From MVC to Blazor](https://www.telerik.com/blogs/migrating-mvc-to-blazor)–A blog post outlining how to migrate from ASP.NET MVC to Blazor and what pitfalls to look out for while doing so.

docs/api/javascript/ui/pdfviewer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ Specifies the localization messages of the toolbar.
458458

459459
### messages.toolbar.pager.last `String` *(default: "Go to the last page")*
460460

461-
### messages.toolbar.pager.of `String` *(default: " of {0} ")*
461+
### messages.toolbar.pager.of `String` *(default: "of")*
462462

463463
### messages.toolbar.pager.page `String` *(default: "page")*
464464

docs/controls/charts/get-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ The Chart [`tooltip`](/api/javascript/dataviz/ui/chart/configuration/tooltip#too
296296

297297
## Next Steps
298298

299-
* [Referencing Existing Widget Instances]({% slug widget_methodsand_events_kendoui_installation %})
299+
* [Referencing Existing Component Instances]({% slug widget_methodsand_events_kendoui_installation %})
300300
* [Demo Page for the Chart](https://demos.telerik.com/kendo-ui/chart/index)
301301

302302
## See Also

docs/controls/data-management/listview/get-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ The ListView allows you to display a scrollbar inside the widget so end-users do
282282

283283
## Next Steps
284284

285-
* [Referencing Existing Widget Instances]({% slug widget_methodsand_events_kendoui_installation %})
285+
* [Referencing Existing Component Instances]({% slug widget_methodsand_events_kendoui_installation %})
286286
* [Demo Page for the ListView](https://demos.telerik.com/kendo-ui/listview/index)
287287

288288
## See Also

docs/controls/editors/datepicker/get-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ You can customize the format of the displayed date by setting the [`format`](/ap
108108

109109
## Next Steps
110110

111-
* [Referencing Existing Widget Instances]({% slug widget_methodsand_events_kendoui_installation %})
111+
* [Referencing Existing Component Instances]({% slug widget_methodsand_events_kendoui_installation %})
112112
* [Demo Page for the DatePicker](https://demos.telerik.com/kendo-ui/datepicker/index)
113113

114114
## See Also

docs/controls/editors/dropdownlist/get-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ Among other functionalities, the DropDownList supports filtering. The filtering
115115

116116
## Next Steps
117117

118-
* [Referencing Existing Widget Instances]({% slug widget_methodsand_events_kendoui_installation %})
118+
* [Referencing Existing Component Instances]({% slug widget_methodsand_events_kendoui_installation %})
119119
* [Demo Page for the DropDownList](https://demos.telerik.com/kendo-ui/dropdownlist/index)
120120

121121
## See Also

docs/controls/editors/numerictextbox/get-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ You can now refer to the NumericTextBox instance and build on top of its existin
7676
7777
## Next Steps
7878

79-
* [Referencing Existing Widget Instances]({% slug widget_methodsand_events_kendoui_installation %})
79+
* [Referencing Existing Component Instances]({% slug widget_methodsand_events_kendoui_installation %})
8080
* [Demo Page for the NumericTextBox](https://demos.telerik.com/kendo-ui/numerictextbox/index)
8181

8282
## See Also

docs/controls/editors/signature/get-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ $(document).ready(function () {
7373

7474
## Next Steps
7575

76-
* [Referencing Existing Widget Instances]({% slug widget_methodsand_events_kendoui_installation %})
76+
* [Referencing Existing Component Instances]({% slug widget_methodsand_events_kendoui_installation %})
7777
* [Demo Page for the Signature](https://demos.telerik.com/kendo-ui/signature/index)
7878

7979
## See Also

docs/controls/editors/textbox/get-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ The TextBox enables you to configure the label by using the [`label`](https://do
8686

8787
## Next Steps
8888

89-
* [Referencing Existing Widget Instances]({% slug widget_methodsand_events_kendoui_installation %})
89+
* [Referencing Existing Component Instances]({% slug widget_methodsand_events_kendoui_installation %})
9090
* [Demo Page for the TextBox](https://demos.telerik.com/kendo-ui/textbox/index)
9191

9292
## See Also

0 commit comments

Comments
 (0)