Ruby on Rails
文章平均质量分 79
lanrion
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
Rails route constraints api 介绍
Rails 为route的路由约束提供了constraints 方法,具体的使用如下: 限制IP地址constraints(:ip => /192.168.\d+.\d+/) do resources :posts end 可以提供一个ip或者一个ip地址的范围进行限制,一旦检测到用户的ip地址符合限制范围,则会告知不存在此route。 匹配动态请求这个例子是控制ro...2013-07-21 17:15:30 · 354 阅读 · 0 评论 -
Ruby gem for Baidu API
前一个月专门写了一个Ruby版本的百度API( http://developer.baidu.com/dev), 取名 api4baidu,Github地址: https://github.com/lanrion/baidu Rubygems: https://rubygems.org/gems/api4baidu 具体用法,在这里引用一下 homepage里的README ...原创 2013-10-27 23:39:46 · 162 阅读 · 0 评论 -
微信Ruby API access_token 验证 weixin_authorize
微信API access_token 验证 weixin_authorize https://github.com/lanrion/weixin_authorize WeixinAuthorize Installation Add this line to your application's Gemfile: gem 'weixin_authorize' And then exe...2014-03-16 02:56:36 · 323 阅读 · 0 评论 -
Twitter ratchet twitter_ratchet_rails
Twitter ratchet , 类似于bootstrap,不过专注于mobile,笔者用过在实际项目中,压缩后非常小,十分适合在mobile中使用。 查看官方网站: http://goratchet.com/components/ 同时也快速包装了一个Rails 的gem: 主要依赖于 Ratchet v2.0.1 https://github.com/lanrion/twit...2014-03-13 01:08:18 · 169 阅读 · 0 评论 -
微信企业号 Ruby gem
对接企业微信应答:https://github.com/lanrion/qy_wechat (对应公众号gem:https://github.com/lanrion/weixin_rails_middleware) 安装 目前只有Master稳定版本,务必通过: gem 'qy_wechat', git: 'https://github.com/lanrion/qy_wecha...2015-01-02 11:24:58 · 489 阅读 · 0 评论 -
使用 Rails 插件快速开发weixin 服务
GEM https://github.com/lanrion/weixin_rails_middleware EXAMPLE https://github.com/lanrion/weixin_rails_middleware_example 自动验证微信请求。 无需拼接XML格式,只需要使用 WeixinMessageHelper 辅助方法,即可快速回复...2014-01-27 17:56:28 · 190 阅读 · 0 评论 -
最近完成的一个项目:essaywit
我的github账号:https://github.com/lanrion 我的微博: http://www.weibo.com/denghuaitao 今天结束了一个项目,http://www.essaywit.com 。 功能都挺简单,一个购物车,订单,支付,订单服务, 会话管理,三个角色, 导师,学生,管理员,功能简单,但几乎web应用需要的都已经有。 用户管理是用d...2014-01-04 01:07:42 · 198 阅读 · 0 评论 -
Ruby中require、load、autoload的区别
require: require(filename) -> true or false Ruby tries to load the library named string, returning true if successful. If the filename does not resolve to an absolute path, it will be searched fo...原创 2013-07-29 21:34:12 · 451 阅读 · 0 评论 -
[1] Refinery CMS: 介绍与基本使用
CMS 在百度百科的解释为 CMS是Content Management System的缩写,意为"内容管理系统",它具有许多基于模板的优秀设计,可以加快网站开发的速度和减少开发的成本。 按我的简单理解其实就是一个可视化的编辑,最直观的理解就是iteye现在这个博客发表编辑功能,先上refinerycms的截图: 很酷吧! 如果你是新手,现在肯定在想这个是怎么跑进...原创 2013-07-29 20:56:20 · 234 阅读 · 0 评论 -
可对元素为Hash型的数组排序的Ruby Gem: sort_collections
sort_collections:https://github.com/lanrion/sort_collections 这个gem的目的是,当我们通过API接收数据的时候(没有使用ActiveRecord),会出现需要对当前数组进行排序,Ruby中已经提供了sort方法,但是该方法,只是对简单的String、Integer等类型排序,如果是Hash呢?我需要针对Hash里的某个key进...原创 2013-10-27 23:47:21 · 171 阅读 · 0 评论
分享