首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Glass Mapper Sitecore 8.1搜索内容(ContentSearchManager)

Glass Mapper Sitecore 8.1搜索内容(ContentSearchManager)
EN

Stack Overflow用户
提问于 2016-09-15 21:28:53
回答 1查看 205关注 0票数 0

我第一次在我的Sitecore 8.1项目中使用Glass Mapper。我正在尝试使用谷歌眼镜的搜索功能。我检查了谷歌眼镜( SitecoreAttributeConfigurationLoader("glass.sitecore7");"). )的教程,但它抛出了一个错误("var attributes = new http://glass.lu/Mapper/Sc/Tutorials/Tutorial25

任何人都有使用Sitecore 8.1的例子。

谢谢

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2016-09-15 22:14:07

搜索示例被设置为使用fluent configuration,并且在应用程序启动时,该示例也会尝试使用pre-load all the models

这是示例中的以下几行:

代码语言:javascript
复制
var attributes = new SitecoreAttributeConfigurationLoader("glass.sitecore7");
...
return new IConfigurationLoader[]{attributes, loader};

您看到的错误是因为您没有将示例更新到您的特定项目。

您需要更新库的名称以匹配包含您的类的项目,例如

代码语言:javascript
复制
var attributes = new SitecoreAttributeConfigurationLoader("MyProject.Models");
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/39512327

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档