const { Integer, Text, Relationship } = require('@keystonejs/fields'); const { AutoIncrement } = require('@keystonejs/fields-auto-increment'); module.exports = { fields: { supaddress_id: { type: AutoIncrement, isRequired: true, label: 'supaddress' }, addrtype: { type: Integer, isRequired: true, label: 'addrtype' }, name: { type: Text, label: 'Imie' }, surname: { type: Text, label: 'Nazwisko' }, companyname: { type: Text, label: 'Nazwa Firmy' }, street: { type: Text, label: 'Ulica' }, housenumber: { type: Text, label: 'Nr. Domu' }, localnumber: { type: Text, label: 'localnumber' }, city: { type: Text, label: 'Miasto' }, zipcode: { type: Text, label: 'Kod Pocztowy' }, country: { type: Text, label: 'Kraj' }, nip: { type: Text, label: 'NIP' }, email: { type: Text, label: 'Adres e-mail' }, phone_mb: { type: Text, label: 'Numer telefonu' }, comment: { type: Text, label: 'Komentarz' }, suppliers_id: { type: Relationship, ref: 'suppliers', many: true, isRequired: true, label: 'suppliers' }, }, label: 'Supaddre'//, plural: 'Supaddress' };