xiongzhu 4 лет назад
Родитель
Сommit
b08010be86
2 измененных файлов с 8 добавлено и 1 удалено
  1. 3 0
      src/main/nine-space/src/main.js
  2. 5 1
      src/main/nine-space/src/store/index.js

+ 3 - 0
src/main/nine-space/src/main.js

@@ -81,3 +81,6 @@ if (query.code) {
         document.location.replace('https://nft.9space.vip/wx/redirect?redirectUrl=' + location.href);
     }
 }
+if (query.invitor) {
+    store.commit('setInvitor', query.invitor);
+}

+ 5 - 1
src/main/nine-space/src/store/index.js

@@ -6,7 +6,8 @@ export default createStore({
         finished: false,
         userInfo: null,
         firstUrl: '',
-        couponInfo: null
+        couponInfo: null,
+        invitor: null
     },
     mutations: {
         setFinished(state, finished) {
@@ -20,6 +21,9 @@ export default createStore({
         },
         setCouponInfo(state, couponInfo) {
             state.couponInfo = couponInfo;
+        },
+        setInvitor(state, invitor) {
+            state.invitor = invitor;
         }
     },
     actions: {