feat: 自动化执行逻辑开发

This commit is contained in:
DEV_DSW
2026-03-11 17:01:48 +08:00
parent d07c65c581
commit b32fb2e9e8
10 changed files with 525 additions and 95 deletions

View File

@@ -18,11 +18,19 @@ export class executeScriptService extends EventEmitter {
return await new Promise((resolve) => {
try {
const roomType = options?.roomType ?? '';
const startTime = options?.startTime ?? '';
const endTime = options?.endTime ?? '';
const operation = options?.operation ?? '';
const child = spawn('node', [scriptPath], {
env: {
...process.env,
...options,
}
ROOM_TYPE: String(roomType),
START_DATE: String(startTime),
END_DATE: String(endTime),
OPERATION: String(operation)
},
});
let stdoutTail = '';