Ruby China
  • Topics
  • 招聘
  • Wiki
  • 酷站
  • Gems
  • Sign Up
  • Sign In
xofred
@xofred2
Member
NO. 5774 / 2013-02-22

[email protected]
广州
3 Topics / 5 Replies
0 Followers
0 Following
3 Favorites
GitHub Public Repos
  • deviantart-gallery-dow... 33

    fetch deviantart's images using mechanize

  • xofred 1

    xofred's notes and pratices

  • v2ray-233 1

    最好用的 V2Ray 一键安装脚本 & 管理脚本

  • Ed2kChromePlugin 0

    a useful tool for coping mount of ed2k link on the page

  • xofred.github.io 0

  • FramePack 0

    Lets make video diffusion practical!

  • gibbon 0

    Gibbon is an API wrapper for MailChimp's API

  • factory_bot_rails_issu... 0

    https://github.com/thoughtbot/factory_bot_rails/issues/387

  • jasvim 0

  • merit 0

    Reputation engine for Rails apps

More on GitHub
  • Overview
  • Topics
  • Replies
  • Favorites
  • Following
  • Followers
  • 如何使用 validates 及 uniqueness 实现两个字段唯一确定一条记录 at October 31, 2017

    1 楼正解,官方文档关于多字段唯一验证有讲

    更保险的话可以在数据库加索引,因为update_all 之类的方法会跳过验证,直接操作数据库

  • 使用 carrierwave 如何做多文件上传,表单处应该如何填写 at September 13, 2017

    之前项目的做法是,分多次上传,同一个 action 处理

    params.require(:product).permit(:photo)
    

    form 类似

    <%= form_for :product, { class: "form-group", multiple: true } do |f| %>
      <%= f.file_field :photo %>
    <% end %>
    

    这样的

  • Rails 5.1 使用 yarn 和 webpack 实战 (vue, 构建等) at May 03, 2017

    👍期待下集可以顺便讲讲和 turbolinks 的和谐相处~~

  • 请教下 Kaminari 不刷新怎么自动分页 at March 06, 2017

    好像是可以不刷新的,在 view 加上:

    <%= paginate @users, remote: true %>
    

    参考官方文档

  • [已解决] ruby 命令行调用 jar 包中文传参的乱码问题 at February 09, 2017

    #3 楼 @hiveer 的确是编码问题,发觉 java 调用 jar 包时要指定编码

关于 / RubyConf / Ruby 镜像 / RubyGems 镜像 / 活跃会员 / 组织 / API / 贡献者
由众多爱好者共同维护的 Ruby 中文社区,本站使用 Homeland 构建,并采用 Docker 部署。
服务器由 赞助 CDN 由 赞助
iOS 客户端 / Android 客户端 简体中文 / English