diff --git a/backend/routes/offer.js b/backend/routes/offer.js index 30d72067..79e508ec 100644 --- a/backend/routes/offer.js +++ b/backend/routes/offer.js @@ -50,7 +50,7 @@ async function addOffer(description, startLocation, endLocation, startDate, endD const addOfferAd = ` INSERT INTO ad (description, startLocation, endLocation, startDate, endDate, animals, smoker, notes, numSeats, userId) VALUES (?,?,?,?,?,?,?,?,?,?)`; - const addOffer = 'INSERT INTO offer (vehicleId, adId, pricePerPerson, pricePerFreight) VALUES (?, ?, ?, ?)'; + const addOffer = 'INSERT INTO offer (vehicleId, adId, pricePerPerson, pricePerFreight) VALUES (?, last_insert_id(), ?, ?)'; try { const conn = await pool.getConnection(); diff --git a/frontend/mycargonaut/src/app/main/ad/ad.component.html b/frontend/mycargonaut/src/app/main/ad/ad.component.html index f321264d..46bee557 100644 --- a/frontend/mycargonaut/src/app/main/ad/ad.component.html +++ b/frontend/mycargonaut/src/app/main/ad/ad.component.html @@ -24,17 +24,6 @@
Wollen Sie diese Fahrt übernehmen?
- Angebotener Gesamtpreis: + Angebotener Gesamtpreis: {{this.typeSpecificContent.price}}