Skip to content

Commit

Permalink
Merge branch 'dhairyagothi:main' into yash/fix-267
Browse files Browse the repository at this point in the history
  • Loading branch information
yashksaini-coder authored Oct 16, 2024
2 parents 1f76a03 + 967508c commit d175148
Show file tree
Hide file tree
Showing 10 changed files with 1,307 additions and 617 deletions.
3 changes: 3 additions & 0 deletions backend/controllers/coolieController.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import { io } from "../index.js";
import CoolieBooking from "../models/CoolieBooking.js";




export const createCoolieBooking = async (req, res) => {
try {
const {
Expand Down
6 changes: 5 additions & 1 deletion backend/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import cookieParser from "cookie-parser";
import { createServer } from "http";
import { Server } from "socket.io";



const app = express();
const server = createServer(app);

Expand All @@ -26,9 +28,11 @@ app.use(express.urlencoded({ extended: true }));
connectDB();

import authRoutes from "./routes/authRoutes.js";
import stationRoutes from "./routes/stationRoutes.js";

app.use("/auth", authRoutes);
app.use("/api", authRoutes);
app.use("/station", stationRoutes);

app.get("/", (req, res) => {
res.send("Working...");
Expand All @@ -45,7 +49,7 @@ const io = new Server(server, {
});

if (process.env.NODE_ENV !== 'production') {
const io = new Server(server, { /* CORS settings */ });

io.on("connection", (socket) => {
console.log("A user connected:", socket.id);
socket.on("disconnect", () => {
Expand Down
3 changes: 1 addition & 2 deletions frontend/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@
<link rel="icon" type="image/svg+xml" href="./src/assets/stationsaarthi.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Station Saarthi</title>
<link href="https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap" rel="stylesheet">
<style>
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200" /> <style>
/* Style for the Google Translate element */
#google_element {
position: absolute;
Expand Down
Loading

0 comments on commit d175148

Please sign in to comment.