For review view ad page.

This commit is contained in:
Naida Vatric
2020-03-14 15:34:18 +01:00
parent a36fba09eb
commit 981faeb610
5 changed files with 37 additions and 18 deletions

View File

@@ -12,6 +12,20 @@ const bulkUpsertKiviPhotos = async kiviPhotosData => {
}
};
module.exports = {
bulkUpsertKiviPhotos
const findPhotosForKiviAd = async id => {
try {
return db.KiviOriginalAdsPhotos.findAll({
where: {
kiviAdId: id
}
});
} catch (error) {
console.log("kiviOriginalAdsPhotos.js", error);
return null;
}
};
module.exports = {
bulkUpsertKiviPhotos,
findPhotosForKiviAd
};