阅读背景:

Rails更大 - 根据模型属性进行模型验证

来源:互联网 

I've got a Trip model, which among other attributes has a start_odometer and end_odometer value. In my model, i'd like to validate that the end odometer is larger than the starting odometer. The end odometer can also be blank because the trip may not have finished yet.I've got a Trip model, which among other attrib




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: