<template>
  <div>跳转SOC平台中，请稍后</div>
</template>

<script>
export default {
  data() {
    return {};
  },
  methods: {
    //获取登录方式
    ssoLoginSZGJURL: function () {
      this.$fetch.ssoLoginSZGJURL().then(
        (resp) => {
          console.log(resp);
          if (resp.data.returnCode == "0") {
            if (resp.data.data) {
              window.location.href = resp.data.data.server +
                "/auth/realms/cmp/protocol/openid-connect/auth?response_type=code&client_id=sso-client&redirect_uri=" +
                resp.data.data.url +
                "&scope=openid";
            } else {
              this.$message.error("获取国际电信登陆地址失败：未配置");
            }
          }
        },
        (error) => {
          this.$message.error("获取国际电信登陆地址失败：" + error);
        }
      );
    }
  },

  created: function () {
    this.ssoLoginSZGJURL();
  },
};
</script>

