const mongoose = require("mongoose");
const Tax = require("../models/admin/taxModel");

module.exports = async () => {
  const exists = await Tax.findOne({ isDefault: true });
  if (exists) return;

  await Tax.create({
    name: "GST 18%",
    type: "GST",
    rates: { cgst: 9, sgst: 9, igst: 18 },
    applicableFor: "BOTH",
    isDefault: true,
    isActive: true,
  });

  console.log("✅ Default GST created");
};
