7837-testToMaster_2432 #2834

Merged
alexm merged 161 commits from 7837-testToMaster_2432 into master 2024-08-06 05:52:05 +00:00
3 changed files with 28 additions and 9 deletions
Showing only changes of commit 3e0e43da2f - Show all commits

View File

@ -86,8 +86,8 @@ proc: BEGIN
WHERE calc_id = vCalcFk;
UPDATE tmp.itemInventory it
JOIN tItemInventoryCalc iic ON iic.itemFk = it.id
JOIN tItemVisibleCalc ivc ON ivc.item_id = it.id
LEFT JOIN tItemInventoryCalc iic ON iic.itemFk = it.id
LEFT JOIN tItemVisibleCalc ivc ON ivc.item_id = it.id
SET it.inventory = iic.quantity,
it.visible = ivc.visible,
it.avalaible = iic.quantity,

View File

@ -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']
}
}
}
]
}
}]
};

View File

@ -53,7 +53,6 @@ module.exports = Self => {
const deletedExpedition = await models.Expedition.destroyById(expeditionId);
deletedExpeditions.push(deletedExpedition);
} catch (e) {
console.log('e: ', e);
notDeletedExpeditions.push(expeditionId);
}
}