自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

beslow的专栏

虽然慢,至少在前进。

  • 博客(8)
  • 资源 (1)
  • 收藏
  • 关注

原创 rspec spec/ 测试不通过,报 undefined method `assertions' 错

Failures: 1) Authentication authorization for-non-signed-in users in the Users controller submitting to the update action Failure/Error: specify { expect(response).to redirect_to(signin_path)

2014-04-25 17:50:33 1699

原创 rails db:migrate 出错 bundle exec

rake aborted!Gem::LoadError: You have already activated rake 10.2.2, but your Gemfile requires rake 10.1.1. Prepending `bundle exec` to your command may so

2014-04-14 11:03:27 3354

原创 rails4 在页面view用link_to 给控制器controller传参数

app\v 'V') %>

2014-04-14 10:30:31 2702

转载 邮箱格式验证 js

JS正则表达式1)验证密码   function verifyPassword(str){      var reg=/^[A-Za-z0-9]+$/;      if( reg.test(str) ){          return true;      }else{          return false;      }   }2)检查邮箱

2014-04-09 10:04:30 963

原创 rails4 ajax实现验证用户存在否

假设用户表名是 users  ,用户名 字段 是  name1、需为users对应的建一个controller,同时定义方法checknameapp\controllers\users_controller.rbclass UsersController < ApplicationController def checkname if User.where(name: pa

2014-04-03 11:17:52 978

原创 rails4 onclick事件不响应

rails4 新增了turbolinks插件,可以在项目的gemfile中看到  # Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinksgem 'turbolinks'项目的manifest文件(一般是applicatio

2014-04-02 10:00:39 1132

原创 ActiveModel::ForbiddenAttributesError

升级到rails4之后,像这这样的语句会报错:ActiveModel::ForbiddenAttributesError@product = Product.new(params[:product])方法是改为@product = Product.new(product_params)同时增加私有方法product_params.class ProductsController

2014-04-01 14:10:42 854

原创 ruby on rails 4 中利用 remote:true 实现 ajax ,小记

_form.html.erb true do |f| %> postcontroller.rb def new @post = Post.new respond_to do |format| format.html format.json { re

2014-04-01 12:50:53 4898

OLE操作EXCEL之DLL实现(C++)

封装了olefunction 对excel的一些基本操作,如打开、关闭xls文件,设置某单元格内容,获取某单元格内容等。 本例dll用bcb6.0编写!

2013-09-27

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除