zhuo
2025-03-15 cce94447499a38569fdc4a609e92858188423068
单点登录方法获取调整
已修改2个文件
17 ■■■■■ 文件已修改
src/views/login.vue 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/logindemo.vue 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/login.vue
@@ -38,7 +38,7 @@
            <router-link class="link-type" :to="'/register'">立即注册</router-link>
          </div>
        </el-form-item>
        <el-button v-if="false" type="primary" plain @click="goLogin">集团集成登录</el-button>
        <el-button v-if="true" type="primary" plain @click="goLogin">集团集成登录</el-button>
      </el-form>
    </div>
    <!--  底部  -->
@@ -96,11 +96,9 @@
  },
  methods: {
    async goLogin() {
      const {
        data: { data },
      } = await getSsoAuthUrl()
      window.location.href = data
      // this.$router.push({ path: '/thirdpartylogin' })
      await getSsoAuthUrl().then(res => {
        window.location.href = res.data
      })
    },
    getCode() {
      getCodeImg().then(res => {
src/views/logindemo.vue
@@ -13,10 +13,9 @@
  computed: {},
  methods: {
    async goLogin() {
      const {
        data: { data }
      } = await getSsoAuthUrl()
      window.location.href = data
      await getSsoAuthUrl().then(res => {
        window.location.href = res.data
      })
    }
  }
}