text: "use strict";
  Object.defineProperty(exports, "__esModule", { value: true });
  const mongoose = require("mongoose");
  exports.OrderSchema = new mongoose.Schema({
      owner: {
          type: mongoose.Schema.Types.ObjectId,
          ref: 'User',
      },
      totalPrice: {
          type: Number,
          default: 0,
      },
      products: [
          {
              product: {
                  type: mongoose.Schema.Types.ObjectId,
                  ref: 'Product',
              },
              quantity: {
                  type: Number,
                  default: 0,
              },
          },
      ],
      created: {
          type: Date,
          default: Date.now,
      },
  });
  //# sourceMappingURL=order.schema.js.map