kyfxbl 发表于 2013-1-15 02:13:22

啊啊啊,ruby语法真调皮啊。作为中青年程序员,ruby初学者,哥倍感压力啊。

def self.upcreate_table :orders do |t|    t.string :name    t.text :address    t.string :email    t.string :pay_type, :limit => 10      t.timestampsendend

诶。。。看这意思好像":name"、":address"是参数吧?怎么要多个:呢,我看别的地方又没有:。略感纠结。

PS:NS真是个好小伙,刚才有菜鸟问题请教他,他不但耐心回答,还写了实例代码。真是好心人啊。
页: [1]
查看完整版本: 啊啊啊,ruby语法真调皮啊。作为中青年程序员,ruby初学者,哥倍感压力啊。