crabatool 1.0.847 → 1.0.849
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/tool/evsockettool.js +8 -2
package/package.json
CHANGED
package/tool/evsockettool.js
CHANGED
|
@@ -295,8 +295,14 @@ function processEvFile(conn, filePath) {
|
|
|
295
295
|
// 模拟上传成功
|
|
296
296
|
log('模拟上传文件到七牛服务器:', filePath, '->', audioUrl);
|
|
297
297
|
|
|
298
|
-
//
|
|
299
|
-
|
|
298
|
+
// 确定文件类型
|
|
299
|
+
var fileType = fileExt.toLowerCase() === '.mp4' ? 'video' : 'audio';
|
|
300
|
+
|
|
301
|
+
// 发送文件URL给前端,包含文件类型
|
|
302
|
+
sendEvMessage(conn, 'completed', '录制完成', {
|
|
303
|
+
audioUrl: audioUrl,
|
|
304
|
+
fileType: fileType
|
|
305
|
+
});
|
|
300
306
|
|
|
301
307
|
// 保持监控状态,等待下一次录制
|
|
302
308
|
}
|