- aggiunto note 'note_ordine_gas'

- corretto bug
This commit is contained in:
Surya Paolo
2024-03-26 15:36:49 +01:00
parent bf1e9b83ba
commit 39687265c8
10 changed files with 83 additions and 14 deletions

View File

@@ -30,6 +30,9 @@ const CartSchema = new Schema({
note: {
type: String,
},
note_ordine_gas: {
type: String,
},
modify_at: {
type: Date,
},
@@ -121,6 +124,7 @@ module.exports.updateCartByCartId = async function (cartId, newCart) {
const totalPrice = newCart.totalPrice;
const totalPriceCalc = newCart.totalPriceCalc;
const note = newCart.note;
const note_ordine_gas = newCart.note_ordine_gas;
const modify_at = new Date();
@@ -131,6 +135,7 @@ module.exports.updateCartByCartId = async function (cartId, newCart) {
totalPriceCalc,
totalQty,
note,
note_ordine_gas,
modify_at: new Date(),
},
}, { new: false }).lean().then((ris) => {