简体   繁体   English

Orchard和Visual Studio 2012命令行错误

[英]Orchard and Visual Studio 2012 command line error

I'm trying to create a new theme in orchard command line but i get an error. 我正在尝试在Orchard命令行中创建一个新主题,但出现错误。 Thank you in advance. 先感谢您。

orchard> codegen theme CWSTheme 果园> codegen主题CWSTheme

Error executing command "codegen theme CWSTheme" 执行命令“ codegen theme CWSTheme”时出错

None of the constructors found with 'Orchard.Environment.AutofacUtil.DynamicProx
y2.ConstructorFinderWrapper' on type 'Orchard.Security.Authorizer' can be invoke
d with the available services and parameters:
Cannot resolve parameter 'Orchard.Security.IAuthorizationService authorizationSe
rvice' of constructor 'Void .ctor(Orchard.Security.IAuthorizationService, Orchar
d.UI.Notify.INotifier, Orchard.IWorkContextAccessor)'.

Exception Details: Autofac.Core.DependencyResolutionException: None of the const
ructors found with 'Orchard.Environment.AutofacUtil.DynamicProxy2.ConstructorFin
derWrapper' on type 'Orchard.Security.Authorizer' can be invoked with the availa
ble services and parameters:
Cannot resolve parameter 'Orchard.Security.IAuthorizationService authorizationSe
rvice' of constructor 'Void .ctor(Orchard.Security.IAuthorizationService, Orchar
d.UI.Notify.INotifier, Orchard.IWorkContextAccessor)'.

Try: 尝试:

  • Exit the Orchard Command Line 退出果园命令行
  • If you can stop site running on your webserver 如果您可以停止网站在网络服务器上运行
  • In App_Data delete the contents of the dependencies folder (these will get regenerated) 在App_Data中,删除依赖项文件夹的内容(这些将重新生成)
  • Try the command line again and hopefully all is fixed 再次尝试命令行,希望所有问题都已解决
  • If you need to restart the site 如果您需要重新启动网站

I find this often clears up a lot of errors and is the Orchard equivalent of turning it off and on again. 我发现这通常会清除很多错误,而Orchard等效于将其关闭然后再打开。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM