UIHint数据注释减慢渲染过程

发布于 2024-12-20 02:59:14 字数 299 浏览 4 评论 0原文

具有实体框架的 MVC 2 C# .NET 4.0 项目包含一个带有用户控件的视图,该控件显示 Telerik MVC 扩展 网格。网格使用一张包含多个字段的表并正确显示。

编辑网格行时,许多字段需要是下拉列表。要创建它们,我需要使用 uihint 注释表中的字段;这使用了一个编辑器模板,它是我的下拉列表。

表对象的字段有 13 个数据注释。由于这些注释,网格渲染速度非常慢。可以做什么来优化这个?

An MVC 2 C# .NET 4.0 project with Entity Framework contains a view with a user control displaying a Telerik MVC Extensions grid. The grid uses one table with many fields and displays correctly.

When editing the grid rows, many of the fields need to be drop-down lists. To create them, I need to annotate the fields in my table with uihint; this uses a editor template that is my drop down list.

There are 13 data annotations for fields for the table object. Due to these annotations, the grid renders very slowly. What can be done to optimize this?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文