xiaoxiao0

<img class="code-img" @click="getCaptcha()" ref="captcha" src="接口地址" alt/>

import { VerifyCode } from "@/api/account";
export default {
data() {
return {
verify_code: "",
};
},
methods: {
async LoginBtn() {
let { code, msg, data } = await Login({
verify_code: this.verify_code,
});
},

// 点击更换验证码
getCaptcha(event) {
  var num = Math.ceil(Math.random() * 10);
  this.$refs.captcha.src = "https://test.npn.sg/npnsysapi/verify_code?" + num;
},

};

分类:

技术点:

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-09-22
  • 2022-01-13
  • 2021-12-05
  • 2021-08-07
  • 2021-08-09
猜你喜欢
  • 2021-11-28
  • 2021-12-06
  • 2021-07-22
  • 2021-10-29
  • 2022-12-23
  • 2021-05-28
相关资源
相似解决方案