码迷,mamicode.com
首页 >  
搜索关键字:routes    ( 707个结果
6.2 Controllers -- Representing Multipe Models
1. 一个controller的modle可以代表几个记录也可以带便单个。这里,路由的model hook返回一个歌曲数组: app/routes/songs.js export default Ember.Route.extend({ model() { return this.store.fin
分类:其他好文   时间:2016-01-28 13:45:42    阅读次数:163
5.7 Components — Sending Actions From Components to Your Application
一、概述 1. 当一个组件在模板中被使用时,它具有发送action到这个模板的controller和routes的能力。这些允许组件通知application当重大事件发生的时候,比如点击组件一个特殊的元素。 2. 像{{action}}Handlebars辅助器,来自组件的actions首先会去到
分类:移动开发   时间:2016-01-28 00:41:39    阅读次数:265
4.2 Routing -- Defining Your Routes
一、概述1.当应用程序启动时,路由器负责显示模板,加载数据,另外还设置应用程序的状态。这是通过匹配当前URL到你定义的routes来实现的。2. Ember app router中的Map方法可以被调用来定义URL映射。当调用Map时,你应该传递一个function,它将会被调用,this会被设置为...
分类:其他好文   时间:2016-01-25 13:16:27    阅读次数:260
4.3 Routing -- Generated Objects
就像在routing guide中介绍的那样,不管什么时候你在路由器中定义一个新路径,Ember.js就会尝试需找一个对应的route,controller,template,它们的命名都是根据命名约定的。如果没找到任何这些对象的实现,会为你生成合适的对象。一、Generated Routes将定你...
分类:其他好文   时间:2016-01-25 13:11:11    阅读次数:174
C# MVC 页面静态化导致的问题
在设置页面静态化的路由,代码如//静态路由 routes.MapRoute( name: "html", url: "{controller}/{action}.html", defaults:...
分类:Windows程序   时间:2016-01-19 00:24:32    阅读次数:213
ASP.NET Web API中实现版本的几种方式
在ASP.NET Web API中,当我们的API发生改变,就涉及到版本问题了。如何实现API的版本呢?1、通过路由设置版本最简单的一种方式是通过路由设置,不同的路由,不同的版本,不同的controller。config.Routes.MapHttpRoute( name: "Food", ...
分类:Windows程序   时间:2016-01-18 13:43:02    阅读次数:300
MVC4.0 如何设置默认静态首页index.shtml
1.不启用二级域名情况下(www.xxx.com)下设置默认静态首页index.shtml 通过配置IIS的默认文档,设置默认首页地址 然后在MVC的路由中写入忽略默认路由代码 routes.IgnoreRoute("{resource}.axd/{*pathInfo}"); r...
分类:Web程序   时间:2016-01-18 12:17:30    阅读次数:161
LowercaseRoutesMVC ASP.NET MVC routes to lowercase URLs
About this ProjectTired of your MVC application generating mixed-case URLs likehttp://mysite.com/Home/Aboutorhttp://mysite.com/Admin/Customers/List? W...
分类:Web程序   时间:2016-01-13 00:31:00    阅读次数:234
mvc默认路由说明
一、命名参数规范+匿名对象routes.MapRoute(name: "Default",url: "{controller}/{action}/{id}", defaults: new { controller = "Home", action = "Index", id = UrlParamet...
分类:Web程序   时间:2016-01-12 13:24:49    阅读次数:133
Rails笔记-rails-tutorial-hello_app
rails4.2.21/rails_4.2.2_newhello_app2/修改gemfile3/bundleinstall4/railsserver-b$IP-p$PORT(cloud9)5/添加hello,action6/修改路由(config/routes.rb)root‘application#hello‘Git版本控制1/gitinit(当前目录创建仓库)2/gitadd-A(当前目录下的文件添加到仓库)3/gitcommi..
分类:移动开发   时间:2016-01-05 18:59:44    阅读次数:164
707条   上一页 1 ... 53 54 55 56 57 ... 71 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!