瀏覽代碼

修改分享

lex 1 年之前
父節點
當前提交
d05870d900

+ 2 - 2
src/student/live-class/live-detail.tsx

@@ -117,9 +117,9 @@ export default defineComponent({
   async mounted() {
     await this._init()
     if (/(localhost|192)/g.test(location.origin)) {
-      this.shareUrl = `https://dev.colexiu.com/teacher/#/shareLive?recomUserId=${state.user.data?.userId}&groupId=${this.groupId}&userType=${state.platformType}`
+      this.shareUrl = `https://dev.colexiu.com/teacher/#/shareLive?recomUserId=${state.user.data?.userId}&groupId=${this.groupId}&userType=${state.platformType}&p=tenant`
     } else {
-      this.shareUrl = `${location.origin}/teacher/#/shareLive?recomUserId=${state.user.data?.userId}&groupId=${this.groupId}&userType=${state.platformType}`
+      this.shareUrl = `${location.origin}/teacher/#/shareLive?recomUserId=${state.user.data?.userId}&groupId=${this.groupId}&userType=${state.platformType}&p=tenant`
     }
   },
   methods: {

+ 2 - 2
src/student/video-class/video-detail.tsx

@@ -42,9 +42,9 @@ export default defineComponent({
   async mounted() {
     await this._init()
     if (/(localhost|192)/g.test(location.origin)) {
-      this.shareUrl = `https://dev.colexiu.com/teacher#/shareVideo?recomUserId=${state.user.data?.userId}&groupId=${this.params.groupId}&userType=${state.platformType}`
+      this.shareUrl = `https://dev.colexiu.com/teacher#/shareVideo?recomUserId=${state.user.data?.userId}&groupId=${this.params.groupId}&userType=${state.platformType}&p=tenant`
     } else {
-      this.shareUrl = `${location.origin}/teacher#/shareVideo?recomUserId=${state.user.data?.userId}&groupId=${this.params.groupId}&userType=${state.platformType}`
+      this.shareUrl = `${location.origin}/teacher#/shareVideo?recomUserId=${state.user.data?.userId}&groupId=${this.params.groupId}&userType=${state.platformType}&p=tenant`
     }
   },
   methods: {

+ 1 - 4
src/teacher/live-class/live-detail.tsx

@@ -131,10 +131,7 @@ export default defineComponent({
         this.myself = !res.data.myself
       }
 
-      this.shareUrl = `${location.origin}/teacher/#/shareLive?recomUserId=${state.user.data?.userId}&groupId=${this.groupId}`
-      if (state.user.data?.tenantId > 0) {
-        this.shareUrl = this.shareUrl + '&p=tenant'
-      }
+      this.shareUrl = `${location.origin}/teacher/#/shareLive?recomUserId=${state.user.data?.userId}&groupId=${this.groupId}&p=tenant`
       // console.log(this.live)
     } catch {
       //

+ 1 - 4
src/teacher/video-class/video-detail.tsx

@@ -73,10 +73,7 @@ export default defineComponent({
       this.detailList = result.detailList || []
 
       // shareVideo?recomUserId=56&groupId=124
-      this.shareUrl = `${location.origin}/teacher/#/shareVideo?recomUserId=${state.user.data?.userId}&groupId=${this.params.videoLessonGroupId}`
-      if (state.user.data?.tenantId > 0) {
-        this.shareUrl = this.shareUrl + '&p=tenant'
-      }
+      this.shareUrl = `${location.origin}/teacher/#/shareVideo?recomUserId=${state.user.data?.userId}&groupId=${this.params.videoLessonGroupId}&p=tenant`
       !this.myself && this.getList()
     } catch (e) {
       console.log(e)