const { Text, Decimal, Integer, Checkbox, Uuid, Relationship } = require('@keystonejs/fields'); const { AutoIncrement } = require('@keystonejs/fields-auto-increment'); module.exports = { fields: { id: { type: Uuid, isRequired: true, label: 'deliveryitems' }, catnum: { type: Text, label: 'Numer katalogowy' }, price_netto: { type: Decimal, knexOptions: { precision: 12, scale: 2 }, label: 'Cena netto' }, value_netto: { type: Decimal, knexOptions: { precision: 12, scale: 2 }, label: 'Wartosc netto' }, isize: { type: Text, isRequired: true, label: 'isize' }, mass: { type: Decimal, knexOptions: { precision: 12, scale: 2 }, label: 'Masa' }, quantity: { type: Integer, label: 'Ilosc' }, documents_id: { type: Relationship, ref: 'documents', many: false, isRequired: true, label: 'documents' }, kinds_id: { type: Relationship, ref: 'kinds', many: false, label: 'kinds' }, uom_id: { type: Relationship, ref: 'uom', many: false, label: 'uom' }, materials_id: { type: Relationship, ref: 'materials', many: false, label: 'Surowiec' }, vat_id: { type: Relationship, ref: 'vat', many: false, isRequired: true, label: 'VAT' }, shops_id: { type: Relationship, ref: 'shops', many: false, isRequired: true, label: 'Magazyn' }, fifo: { type: Checkbox, isRequired: true, label: 'fifo' }, itype: { type: Integer, isRequired: true, label: 'itype' }, }, label: 'Deliveryitem'//, plural: 'Deliveryitemss' };