Merged finished kivi-input in view
This commit is contained in:
17
app/helpers/db/kiviOriginalAdsPhotos.js
Normal file
17
app/helpers/db/kiviOriginalAdsPhotos.js
Normal file
@@ -0,0 +1,17 @@
|
||||
"use strict";
|
||||
const db = require("../../models/index");
|
||||
const sequelize = require("sequelize");
|
||||
|
||||
const bulkUpsertKiviPhotos = async kiviPhotosData => {
|
||||
try {
|
||||
return await db.KiviOriginalAdsPhotos.bulkCreate(kiviPhotosData, {
|
||||
ignoreDuplicates: true
|
||||
});
|
||||
} catch (e) {
|
||||
console.log("Error bulk upserting kiviOriginalAdsPhotos : ", e);
|
||||
}
|
||||
};
|
||||
|
||||
module.exports = {
|
||||
bulkUpsertKiviPhotos
|
||||
};
|
||||
Reference in New Issue
Block a user