浏览代码

feat:注册登录弹框插件微信二维码增加source参数

yangfeng 3 月之前
父节点
当前提交
7beb76a715
共有 1 个文件被更改,包括 7 次插入2 次删除
  1. 7 2
      plugins/login-auth/src/module-model/wxQrcode.ts

+ 7 - 2
plugins/login-auth/src/module-model/wxQrcode.ts

@@ -1,5 +1,5 @@
 import { computed, ref } from 'vue'
-
+import { useCustomSpecialSource } from '@/utils/use'
 /**
  * 微信二维码相关
  */
@@ -10,7 +10,12 @@ const pageShareId = ref('')
 const pageKopShareId = ref('')
 
 const pageWechatQrcodeImgSrc = computed(() => {
-  return ImgBase + pageShareId.value
+  const source = useCustomSpecialSource()
+  if (source && source !== 'undefined' && source !== 'null') {
+    return ImgBase + pageShareId.value + '?source=' + source
+  } else {
+    return ImgBase + pageShareId.value
+  }
 })
 
 const pageKopQrcodeImgSrc = computed(() => {