09 2015 档案

摘要:require 'csv'class PartRequestsController params[:status]).order('id DESC') @status = params[:status] respond_to do |format| format.html #... 阅读全文
posted @ 2015-09-09 14:11 PointNet 阅读(1520) 评论(1) 推荐(0) 编辑
摘要:classHardWorkerincludeSidekiq::Workerrequire'CSV'defperform(file_path)csv_text=File.read(file_path)csv=CSV.parse(csv_text,:headers=>true)csv.eachdo|ro... 阅读全文
posted @ 2015-09-09 13:51 PointNet 阅读(419) 评论(0) 推荐(0) 编辑
摘要:字符串处理函数1.返回字符串的长度str.length => integer2.判断字符串中是否包含另一个串str.include? other_str => true or false"hello".include? "lo" #=> true"hello".include? "ol" #... 阅读全文
posted @ 2015-09-06 23:34 PointNet 阅读(1215) 评论(0) 推荐(0) 编辑