supaddress.js 1.2 KB

1234567891011121314151617181920212223
  1. const { Integer, Text, Relationship } = require('@keystonejs/fields');
  2. const { AutoIncrement } = require('@keystonejs/fields-auto-increment');
  3. module.exports = {
  4. fields: {
  5. supaddress_id: { type: AutoIncrement, isRequired: true, label: 'supaddress' },
  6. addrtype: { type: Integer, isRequired: true, label: 'addrtype' },
  7. name: { type: Text, label: 'Imie' },
  8. surname: { type: Text, label: 'Nazwisko' },
  9. companyname: { type: Text, label: 'Nazwa Firmy' },
  10. street: { type: Text, label: 'Ulica' },
  11. housenumber: { type: Text, label: 'Nr. Domu' },
  12. localnumber: { type: Text, label: 'localnumber' },
  13. city: { type: Text, label: 'Miasto' },
  14. zipcode: { type: Text, label: 'Kod Pocztowy' },
  15. country: { type: Text, label: 'Kraj' },
  16. nip: { type: Text, label: 'NIP' },
  17. email: { type: Text, label: 'Adres e-mail' },
  18. phone_mb: { type: Text, label: 'Numer telefonu' },
  19. comment: { type: Text, label: 'Komentarz' },
  20. suppliers_id: { type: Relationship, ref: 'suppliers', many: true, isRequired: true, label: 'suppliers' },
  21. }, label: 'Supaddre'//, plural: 'Supaddress'
  22. };