aggiornamenti su PCB
This commit is contained in:
@@ -131,11 +131,11 @@ async function completaSettaggioProduct_AndProductInfo(arrcampi_productInfo, arr
|
||||
}
|
||||
|
||||
if (!rec.hasOwnProperty('img') && product.code) {
|
||||
productInfo.imagefile = 'upload/products/' + product.code + '.jpg';
|
||||
productInfo.imagefile = product.code + '.jpg';
|
||||
} else {
|
||||
if (rec.hasOwnProperty('img')) {
|
||||
if (rec['img']) {
|
||||
productInfo.imagefile = 'upload/products/' + rec['img'];
|
||||
productInfo.imagefile = rec['img'];
|
||||
} else {
|
||||
productInfo.imagefile = '';
|
||||
}
|
||||
@@ -823,7 +823,8 @@ router.post('/import', authenticate, async (req, res) => {
|
||||
link: product.link,
|
||||
idCatProds: [],
|
||||
idSubCatProds: [],
|
||||
img: 'upload/products/' + product.code + '.jpg',
|
||||
// img: 'upload/products/' + product.code + '.jpg',
|
||||
imagefile: product.code + '.jpg',
|
||||
weight: product.weight,
|
||||
unit: tools.getIdUnitsByText(product.unit),
|
||||
productTypes: shared_consts.PRODUCTTYPE.PRODUCT,
|
||||
|
||||
Reference in New Issue
Block a user