南昌市物联网技防平台-前端
shuishen
2021-03-19 b69ca83a6f4eacc6afa0ac5b23514e6a520b79ea
src/page/index/logo.vue
@@ -365,21 +365,31 @@
          url: "/api/blade-jfpts/alarm/alarm/selecttx?id=" + that.deviceId,
          method: "post",
        }).then(function (response) {
          var userId = JSON.parse(window.localStorage.getItem('物联网安保云服务平台-userInfo')).content.user_id;
          if (response.data.data.length > 0 && response.data.data[0].waringType == "一键求助" && response.data.data[0].alarmId != userId) {
          var userId = JSON.parse(
            window.localStorage.getItem("物联网安保云服务平台-userInfo")
          ).content.user_id;
          if (response.data.data.length > 0) {
            that.deviceId = response.data.data[0].id;
            that.form = response.data.data[0];
            that.peopleList = [
              { label: that.form.oneContacts, value: that.form.onePhone },
              { label: that.form.twoContacts, value: that.form.twoPhone },
              { label: that.form.threeContacts, value: that.form.threePhone },
            ];
            that.peopleName = that.form.oneContacts;
            that.peoplePhone = that.form.onePhone;
            that.dialogTableVisible = true;
            that.videoConversationReal = true;
            that.$refs.realAudio.src = "./realVideo/audio.mp3";
            that.$refs.realAudio.play();
            console.log(userId, response.data.data[0].alarmId);
            if (
              response.data.data[0].waringType == "紧急求救" &&
              response.data.data[0].alarmId == userId
            ) {
              response.data.data[0].waringType == "一键求助";
              that.form = response.data.data[0];
              that.peopleList = [
                { label: that.form.oneContacts, value: that.form.onePhone },
                { label: that.form.twoContacts, value: that.form.twoPhone },
                { label: that.form.threeContacts, value: that.form.threePhone },
              ];
              that.peopleName = that.form.oneContacts;
              that.peoplePhone = that.form.onePhone;
              that.dialogTableVisible = true;
              that.videoConversationReal = true;
              that.$refs.realAudio.src = "./realVideo/audio.mp3";
              that.$refs.realAudio.play();
            }
          }
        });
      }, 5000);
@@ -387,6 +397,8 @@
    closeDialog() {
      //关闭窗口回调,关闭警报
      this.$refs.realAudio.pause();
     this.videoConversationReal = false;
      this.oldVideoSatart = false;
    },
    updateJtyep(row, jtype, t) {
      var that = this;