Implementation of a generic backend of eshop in Crystal
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
319 B

5 years ago
  1. require "json"
  2. enum Country
  3. FR,
  4. NL,
  5. DE,
  6. IT,
  7. EI,
  8. GB,
  9. end
  10. class Address
  11. JSON.mapping(
  12. name: String,
  13. address1: String,
  14. address2: {type: String, nilable: true},
  15. postcode: String,
  16. city: String,
  17. country: Country,
  18. is_default: Bool
  19. )
  20. end