Orchard 重命名迁移中的内容类型 [英] Orchard Rename Content Type in Migration

查看:49
本文介绍了Orchard 重命名迁移中的内容类型的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望在我的 Orchard 模块之一中重命名现有的自定义内容类型.是否可以在迁移中执行此操作?

I'm hoping to rename an existing custom content type in one of my Orchard modules. Is it possible to do this in a migration?

推荐答案

可以,但不能使用 ContentDefinitionManager.最简单的方法是使用 SchemaBuilder.ExecuteSqlSettings_ContentTypeDefinitionRecord 表执行 SQL 更新查询.

Yes, but not by using ContentDefinitionManager. The simplest way would be to execute an SQL update query against Settings_ContentTypeDefinitionRecord table using SchemaBuilder.ExecuteSql.

这篇关于Orchard 重命名迁移中的内容类型的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆