石墨消解 mock
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

20 lines
426 B

import express from "express";
import { delay } from "../utils/helper";
import { WsProxy } from "../utils/wss";
const router = express.Router();
router.post("/", async (req, res) => {
await delay(200);
setTimeout(() => {
WsProxy.send({
type: "cmd",
data: {
commandId: req.body.commandId,
status: "D0000",
},
});
}, 2000);
res.json({ code: "00000", msg: "执行成功" });
});
export default router;