Interpretation of a POS system using ActiveRecord and Ruby