const mongoose = require('mongoose');

const orderTransactionSchema = new mongoose.Schema({
    order: {
        type: mongoose.Schema.Types.ObjectId,
        ref: 'Order',
        required: true,
      },
      transaction: {
        type: mongoose.Schema.Types.ObjectId,
        ref: 'Transaction',
        required: true,
      },
}, {
    timestamps: true,
    collection: 'orderTransactions'
})

module.exports = mongoose.model("OrderTransaction", orderTransactionSchema);
