diff --git a/modules/entry/back/methods/entry/getBuys.js b/modules/entry/back/methods/entry/getBuys.js index 3a4d5cc47..bd9c5db7a 100644 --- a/modules/entry/back/methods/entry/getBuys.js +++ b/modules/entry/back/methods/entry/getBuys.js @@ -50,6 +50,7 @@ module.exports = Self => { 'stickers', 'packing', 'grouping', + 'packing', 'groupingMode', 'quantity', 'packagingFk', @@ -79,7 +80,9 @@ module.exports = Self => { fields: [ 'id', 'typeFk', + 'stems', 'name', + 'category', 'subName', 'size', 'minPrice', @@ -95,14 +98,31 @@ module.exports = Self => { 'value9', 'tag10', 'value10', - 'groupingMode' + 'groupingMode', + 'inkFk', + 'originFk', + 'producerFk' ], - include: { - relation: 'itemType', - scope: { - fields: ['code', 'description'] + include: [ + { + relation: 'itemType', + scope: { + fields: ['code', 'description'] + } + }, + { + relation: 'origin', + scope: { + fields: ['code'] + } + }, + { + relation: 'producer', + scope: { + fields: ['name'] + } } - } + ] } }] };