add bill to booking if there

This commit is contained in:
Thomas Ruoff
2020-11-02 22:43:59 +01:00
parent ecc3715f27
commit d440d0e07e

View File

@@ -16,6 +16,7 @@ export const getServerSideBooking: GetServerSideProps = async (context) => {
} }
await booking.populate('booker').execPopulate() await booking.populate('booker').execPopulate()
await booking.populate('bill').execPopulate()
// TODO: hack, not sure why _id is not serilizable // TODO: hack, not sure why _id is not serilizable
const bookingJSON = JSON.parse(JSON.stringify(booking.toJSON())) const bookingJSON = JSON.parse(JSON.stringify(booking.toJSON()))