方法'RouteCollection.get_AppendTrailingSlash“在ASP.NET MVC 5单用剃须刀网址助手时未找到 [英] Method 'RouteCollection.get_AppendTrailingSlash' not found when using Razor Url helpers in ASP.NET MVC 5 Mono

查看:123
本文介绍了方法'RouteCollection.get_AppendTrailingSlash“在ASP.NET MVC 5单用剃须刀网址助手时未找到的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在的 ASP.NET MVC 5 应用: //mono-project.com相对=nofollow>单(Ubuntu的14.4,MonoDevelop的5.9,单声道JIT编译器版本4.0.1)。

我看到一些剃刀组件不被识别,例如:

  @ Url.Action

当我添加此

\r
\r

<标题=通知HREF =@ Url.Action( _Listing,家)>家庭及LT; / A>

\r

\r
\r

我得到这个错误:


  

system.missingMethodException而


  
  

方法'RouteCollection.get_AppendTrailingSlash找不到。


System.Web.Mvc 从包中引用。还有什么是必需的?

更新:我想这些解决方案迄今:

现在看来似乎是一个已知问题但我坚信应当有一些黑客这个工作。我试着用的aspx发动机还,但没有收获。


解决方案

最新的消息是AFAIK米格尔拒绝了我的最小拉力要求,去年,但你可以在那拉要求,即一对夫妇别人已经得到的底部看到建立在github上,其中包括本等等。

我看不到任何人的接受了单声道主线拉请求。期待我能看到的方式是,如果你知道/可以说服别人对Xamarin团队来推动这一点。

或者,与得到现已开源的.Net code单声道运行帮助。

https://github.com/gentoo/dotnet 看起来很有趣:它已经退出这一点,其他一些MVC5变化。

I am creating an ASP.NET MVC 5 application in Mono (Ubuntu 14.4, Monodevelop 5.9, Mono JIT compiler version 4.0.1).

I see that some of the razor components are not recognized, eg:

@Url.Action

When I add this

<a title="Notifications" href="@Url.Action("_Listing","Home")"> Home </a>

I get this error:

System.MissingMethodException

Method 'RouteCollection.get_AppendTrailingSlash' not found.

System.Web.Mvc is referenced from the packages. Is there anything else which is required?

Update: I tried these solutions so far:

It seems like it is a known issue but I strongly believe there shall be some hack for this to work. I tried using aspx engine also but no gain.

解决方案

The latest news afaik is that Miguel rejected my minimal pull request last year but you can see at the bottom of that Pull Request that a couple of others have got builds on github which include this and more.

I can't see anyone's got a pull request accepted for mono mainline. The way forward I can see is if you know/can persuade someone on the Xamarin team to push this.

Or, helping with getting the now-open-sourced .Net code running on mono.

But https://github.com/gentoo/dotnet looks interesting: It has pulled this and some other MVC5 changes.

这篇关于方法'RouteCollection.get_AppendTrailingSlash“在ASP.NET MVC 5单用剃须刀网址助手时未找到的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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