index.vue 1.89 KB
<!--
 * @Description: 
 * @Author: huyue
 * @Date: 2022-05-06 11:28:02
 * @LastEditors: huyue
 * @LastEditTime: 2022-07-21 16:21:02
-->
<template>
  <div class="scrm-wechat-main">
    <wx-system v-if="corpAuthModel === 0"></wx-system>
    <wx-user v-if="corpAuthModel === 3"></wx-user>
    <div
      class="wechat-qrcode-panel"
      v-if="corpAuthModel === null"
      :style="{
        height: bHeight + 'px'
      }"
    >
      <div class="config-box-qrcode">
        <div class="config-use-desc">请联系平台运营配置企微接入模式</div>
        <div class="config-use-qrcode">
          <img src="https://img01.glsx.com.cn/weapp/resource/saas/scrm/lianghh.png" alt="" />
        </div>
        <div class="config-use-desc">联系电话:18824231191</div>
      </div>
    </div>
  </div>
</template>

<script>
import wxSystem from './components/wxSystem'
import wxUser from './components/wxUser'
export default {
  name: 'enterpriseWechat',
  components: {
    wxSystem,
    wxUser
  },
  data() {
    return {
      corpAuthModel: '',
      bHeight: 500
    }
  },
  mounted() {
    let clientHeight = document.documentElement.clientHeight
    this.bHeight = clientHeight - 80
    this.$apis.ww.getStatus({}).then(res => {
      this.corpAuthModel = res.corpAuthModel
      if (this.corpAuthModel === null) {
        this.$alert('请联系平台运营配置企微接入模式', '提示', {
          confirmButtonText: '确定',
          type: 'info',
          customClass: 'gl-message-box'
        })
      }
    })
  }
}
</script>

<style lang="scss" scoped>
.wechat-qrcode-panel {
  width: 100%;
  background: #fff;
  height: calc(100% - 100px);
  display: flex;
  justify-content: center;
  align-items: center;
  .config-box-qrcode {
    width: 300px;
    text-align: center;
    .config-use-qrcode {
      width: 200px;
      height: 200px;
      text-align: center;
      margin: 0 auto;
    }
  }
}
</style>