|
@@ -171,6 +171,28 @@ export default {
|
|
|
mounted() {
|
|
|
// iview bug: https://github.com/iview/iview/issues/4061
|
|
|
// document.body.style = "";
|
|
|
+
|
|
|
+ if (typeof nodeRequire != "undefined") {
|
|
|
+ try {
|
|
|
+ var fs = window.nodeRequire("fs");
|
|
|
+
|
|
|
+ window.nodeRequire("node-cmd").get("multiCamera.exe", () => {
|
|
|
+ let CameraInfo = fs.readFileSync("CameraInfo.txt", "utf-8");
|
|
|
+ if (CameraInfo && CameraInfo.trim()) {
|
|
|
+ CameraInfo = CameraInfo.trim();
|
|
|
+ CameraInfo = CameraInfo.replace(/\r\n/g, "");
|
|
|
+ CameraInfo = CameraInfo.replace(/\n/g, "");
|
|
|
+ console.log(CameraInfo);
|
|
|
+ this.$http.post(
|
|
|
+ "/api/ecs_core/log/studentClient/debug/S-001001",
|
|
|
+ CameraInfo
|
|
|
+ );
|
|
|
+ }
|
|
|
+ });
|
|
|
+ } catch (error) {
|
|
|
+ console.log(error);
|
|
|
+ }
|
|
|
+ }
|
|
|
},
|
|
|
beforeRouteUpdate(from, to, next) {
|
|
|
if (process.env.NODE_ENV === "development") {
|