Ruby China
  • 社区
  • 招聘
  • Wiki
  • 酷站
  • Gems
  • 注册
  • 登录
Tony
@mystery
会员
第 9242 位会员 / 2013-09-22

易课教育
成都
2 篇帖子 / 157 条回帖
6 关注者
18 正在关注
0 收藏
不要做相同的事情,期待不同的结果。
GitHub Public Repos
  • rmp-api 0

    A wrapper for the Rate My Professor (RMP) GraphQL database

  • AI-Scientist 0

    The AI Scientist: Towards Fully Automated Open-Ended Scientific Discovery 🧑‍🔬

  • Robyn 0

    Robyn is a Super Fast Async Python Web Framework with a Rust runtime.

  • qaDemo 0

  • gptstore-prompts 0

    Here are the Top 100 prompts on GPTStore, which we can use to learn and improve prompt engineering.

  • ChatGPT-Next-Web 0

    A well-designed cross-platform ChatGPT UI (Web / PWA / Linux / Win / MacOS). 一键拥有你自己的跨平台 ChatGPT 应用。

  • vue-admin-better 0

    🚀🚀🚀vue admin,vue3 admin,vue3.0 admin,vue后台管理,vue-admin,vue3.0-admin,admin,vue-admin,vue-element-a...

  • video-retalking 0

    [SIGGRAPH Asia 2022] VideoReTalking: Audio-based Lip Synchronization for Talking Head Video Editi...

  • chatgpt-nextjs 0

    像官方 ChatGPT 一样使用,再加入更强大的功能(Use as the official ChatGPT, with even more powerful features.)

  • easy-ui 0

More on GitHub
  • 概况
  • 话题
  • 回帖
  • 收藏
  • 正在关注
  • 关注者
  • 求 ruby 进程中线程资源使用查看工具介绍 at 2014年06月28日

    #2 楼 @lihaidong sorry

  • rails3 是否可以稳定实现增量编译 Assets Pipeline at 2014年06月27日

    #3 楼 @saiga 您这可是超常规的架构应用,有想法,有胆量,相比 turbo-sprockets-rails3 我选择后者,呵呵

  • rails3 是否可以稳定实现增量编译 Assets Pipeline at 2014年06月27日

    #1 楼 @ericguo 感觉还没到升级的时机,应该再等等。哈哈

  • rails3 是否可以稳定实现增量编译 Assets Pipeline at 2014年06月27日

    #2 楼 @billy 发布时 assets 没改变的情况是会跳过编译的

  • bundle install 直接报错 at 2014年06月25日

    #6 楼 @zhangyanan 要么放弃 JRuby 要么放弃 Windows

  • bundle install 直接报错 at 2014年06月25日

    #4 楼 @zhangyanan 我想问的是,你为什么不用 Linux?

  • [北京] 触控科技有限公司招聘 Ruby 服务器开发人员 1 名 at 2014年06月25日

    #1 楼 @chechaoyang 你在这家公司?

  • [经验之谈] 转行做程序员的 8 个月 at 2014年06月16日

    我对减肥 挺有兴趣的 哈哈

  • 大家看看我这水平还有希望么? at 2014年06月10日

    这么多技术书要看,你还有时间怀疑自己能力?赶快看书去!哈哈

  • 批量数据该怎么处理才能减少耗时 (如何用 EventMachine 发送多 http 请求) at 2014年06月10日

    #12 楼 @yutian 先写个 rake 查找一下 filename 然后记录下来,这样就不用每次 File.exists?(filename) 时间 (IO) 上会节约好多,以后再处理 job 逻辑上也好优化。

  • 批量数据该怎么处理才能减少耗时 (如何用 EventMachine 发送多 http 请求) at 2014年06月10日

    #10 楼 @yutian 那你应该给是否生成了 pdf 加个一个字段来记录,再写个脚本再更新一下现有记录,这样一劳永逸呀亲!

  • [深圳] 大疆创新科技有限公司 (DJI) 招聘 Ruby 开发工程师 6 名 at 2014年06月06日

    #24 楼 @stonegong 是真的么,这个还让玩哪?

  • [深圳] 大疆创新科技有限公司 (DJI) 招聘 Ruby 开发工程师 6 名 at 2014年06月05日

    招聘宣传动画蛮好玩的, 是牛人你就来

  • 请教一个重构方案 at 2014年06月01日

    #25 楼 @flowerwrong 麻烦楼主代码贴出来看一下 inject([]) do |arr, klass| arr 此时不应该是 nil 呀!

  • 请教一个重构方案 at 2014年05月31日
    UN_GRADUATION_TYPE = "本科生"
    GRADUATION_TYPE = "研究生"
    
    def get_graduation_type_relation_records class_name, fun
      return [] unless class_name = class_name.safe_constantize
       # .clone 可以拷到 Engienclass  而 dup 不可以,避免加其它单例方法失败。
      class_name.where("check_status < ?", 1).clone.inject([]) do |arr, klass|
        arr << klass if GRADUATION_TYPE == klass.send(fun).try(:stu_type)
      end
    end
    
    @courseUsers = get_graduation_type_relation_records 'CourseUser', 'course'
    @serviceUsers = get_graduation_type_relation_records 'ServiceUser', 'service'
    @patentUsers get_graduation_type_relation_records 'PatentUser', 'patent'
    
  • has_many 和 belongs_to 中的 :foreign_key at 2014年05月29日

    self.primary_key 默认主键 默认 ID

    :primary_key

    Specify the method that returns the primary key of associated object used for the association. By default this is id.

    但是 Paper.find(2).author 不能够返回 paper 的 author

    belongs_to :author

    class Paper < ActiveRecord::Base
      self.primary_key = 'pid'
      belongs_to :author, foreign_key: 'a_id'
    end
    

    在什么场合会用到

    不知道这个例子 适合不?

    class Category < ActiveRecord::Base
      belongs_to :parent, :foreign_key => :parent_id
      has_many :children, :foreign_key => :parent_id
    end
    
  • [北京] 大鱼自助游招聘 前端 /Ruby 工程师啦,推荐成功有奖 at 2014年05月26日

    #1 楼 @zj0713001 你家大鱼太霸气了 台北往返机票!!! 😏

  • 驾考,科目二挂了,心情好糟糕~~~~ at 2014年05月26日

    没事,你比我好多了,我还没报名呢

  • 怎么实现多站搜索 at 2014年05月22日

    Solr 就可以帮你实现呀! Apache Lucene http://lucene.apache.org/

  • Yegge: 谷歌开发流程,敏捷真的靠谱吗? at 2014年05月22日

    #2 楼 @chenge 我觉得这事还得因人而异。

  • 诸位正在用啥手机啊 at 2014年05月22日

    5s

  • 看我如何解决 ActionView::MissingTemplate 的问题 at 2014年05月21日
    1. 你都没说你想要什么样的结果?
    2. 你只说你发现了,还没来的及处理,你这事看来还得追踪报导呀!
  • 可不可以将循环写在<script></script>之间 at 2014年05月21日

    #8 楼 @xiongxin8802 好吧

  • 可不可以将循环写在<script></script>之间 at 2014年05月21日

    #6 楼 @xiongxin8802 不用吧,你可以写 html 呀!

    <% articles.each do |article| %>
    <span class="articles" article_id="<%=article.id" style="dispaly:hidden;"> <%= article.body %></span>
    <% end %>
    
    $('.articles').each();
    在这取出来...
    
  • 可不可以将循环写在<script></script>之间 at 2014年05月21日

    你为什么要这么写呢,你最好换一种实现的方式,这不科学呀亲!

  • [成都] 超有爱教育科技招聘 Ruby 大牛啦 at 2014年05月21日

    @danoyang 最后一张图片没有显示出来!

  • [成都] 超有爱教育科技招聘 Ruby 大牛啦 at 2014年05月21日

    顶一下!我也有用这个。

  • 页面视图用什么调试 at 2014年05月21日

    Gemfile gem 'debugger'

    Views <% debugger %>

  • 扒一扒 ThoughtWorks 面试的那点事 at 2014年05月20日

    很多 Ruby 代码,写完后一看,这不是 Java 嘛!是谁把你们掰弯了?哈哈

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