当前位置: 首页>>代码示例>>C#>>正文


C# AreaRegistrationContext.MapLanguageRoute方法代码示例

本文整理汇总了C#中System.Web.Mvc.AreaRegistrationContext.MapLanguageRoute方法的典型用法代码示例。如果您正苦于以下问题:C# AreaRegistrationContext.MapLanguageRoute方法的具体用法?C# AreaRegistrationContext.MapLanguageRoute怎么用?C# AreaRegistrationContext.MapLanguageRoute使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在System.Web.Mvc.AreaRegistrationContext的用法示例。


在下文中一共展示了AreaRegistrationContext.MapLanguageRoute方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: RegisterArea

        public override void RegisterArea(AreaRegistrationContext context)
        {
            #region AdminBattlesController
            context.MapLanguageRoute("admin/battles", MVC.Admin.AdminBattles.GetBattles());
            context.MapLanguageRoute("admin/battles/create", MVC.Admin.AdminBattles.CreateBattle());
            #endregion

            #region AdminTeamsControoler
            context.MapLanguageRoute("admin/teams/pro", MVC.Admin.AdminTeams.GetProTeams());
            context.MapLanguageRoute("admin/teams/pro/create", MVC.Admin.AdminTeams.CreateProTeam());
            #endregion AdminTeamsController
        }
开发者ID:meze,项目名称:betteamsbattle,代码行数:12,代码来源:AdminAreaRegistration.cs

示例2: RegisterArea

        public override void RegisterArea(AreaRegistrationContext context)
        {
            #region HomeController
            context.MapLanguageRoute("", MVC.NotAdmin.Home.Index());
            #endregion

            #region BattlesController
            context.MapLanguageRoute("battles/all", MVC.NotAdmin.Battles.AllBattles());
            context.MapLanguageRoute("battles/{battleId}", MVC.NotAdmin.Battles.GetBattle());
            #endregion

            #region BetsController
            context.MapLanguageRoute("battles/{battleId}/mybets", MVC.NotAdmin.Bets.GetMyBattleBets());
            context.MapLanguageRoute("users/{userId}/bets", MVC.NotAdmin.Bets.GetUserBets());
            context.MapLanguageRoute("teasm/{teamId}/bets", MVC.NotAdmin.Bets.GetTeamBets());
            context.MapLanguageRoute("battles/{battleId}/mybets/new", MVC.NotAdmin.Bets.MakeBet());
            context.MapLanguageRoute("battles/{battleId}/mybets/{battleBetId}/succeeded", MVC.NotAdmin.Bets.BetSucceeded());
            context.MapLanguageRoute("battles/{battleId}/mybets/{battleBetId}/failed", MVC.NotAdmin.Bets.BetFailed());
            context.MapLanguageRoute("battles/{battleId}/mybets/{battleBetId}/canceledbybookmaker", MVC.NotAdmin.Bets.BetCanceledByBookmaker());
            #endregion

            #region AccountsController
            context.MapLanguageRoute("account/signin", MVC.NotAdmin.Accounts.SignIn());
            context.MapLanguageRoute("account/authenticate", MVC.NotAdmin.Accounts.Authenticate());
            context.MapLanguageRoute("account/signup", MVC.NotAdmin.Accounts.SignUp());
            context.MapLanguageRoute("account/signout", MVC.NotAdmin.Accounts.SignOut());
            #endregion

            #region TeamsController
            context.MapLanguageRoute("teams/{teamId}", MVC.NotAdmin.Teams.GetTeam());
            context.MapLanguageRoute("users/{userId}", MVC.NotAdmin.Teams.GetPersonalTeam());
            context.MapLanguageRoute("teams/top", MVC.NotAdmin.Teams.TopTeams());
            context.MapLanguageRoute("battles/{battleId}/topteams", MVC.NotAdmin.Teams.BattleTopTeams());
            #endregion

            #region UsersController
            
            #endregion
        }
开发者ID:meze,项目名称:betteamsbattle,代码行数:39,代码来源:NotAdminAreaRegistration.cs


注:本文中的System.Web.Mvc.AreaRegistrationContext.MapLanguageRoute方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。