Commit 6b14d08e4c79016679d2da35c57142549713918c
1 parent
9dc773b1b3
Exists in
master
case studies
Showing
11 changed files
with
35 additions
and
19 deletions
Show diff stats
src/components/AuthorIntro.vue
... | ... | @@ -81,9 +81,11 @@ export default { |
81 | 81 | }, |
82 | 82 | mounted() { |
83 | 83 | var allSlideData = localStorage.getItem("spotlight_slide"+this.$route.params.caseStudyId); |
84 | - if (allSlideData) { | |
84 | + if (allSlideData) { | |
85 | 85 | this.allSlide = JSON.parse(allSlideData); |
86 | 86 | this.getCurrentSlideData(); |
87 | + }else{ | |
88 | + this.$router.push("/login"); | |
87 | 89 | } |
88 | 90 | |
89 | 91 | }, | ... | ... |
src/components/AuthorReadingBreak.vue
... | ... | @@ -105,9 +105,11 @@ export default { |
105 | 105 | var allSlideData = localStorage.getItem( |
106 | 106 | "spotlight_slide" + this.$route.params.caseStudyId |
107 | 107 | ); |
108 | - if (allSlideData) { | |
108 | + if (allSlideData) { | |
109 | 109 | this.allSlide = JSON.parse(allSlideData); |
110 | 110 | this.getCurrentSlideData(); |
111 | + }else{ | |
112 | + this.$router.push("/login"); | |
111 | 113 | } |
112 | 114 | }, |
113 | 115 | methods: { |
... | ... | @@ -149,14 +151,7 @@ export default { |
149 | 151 | this.$router.push("/profile"); |
150 | 152 | }, |
151 | 153 | |
152 | - commentExistCheck(i) { | |
153 | - console.log(this.commentList[i].comment); | |
154 | - var returnValue = false; | |
155 | - if (this.commentList[i].comment) { | |
156 | - returnValue = true; | |
157 | - } | |
158 | - return returnValue; | |
159 | - }, | |
154 | + | |
160 | 155 | }, |
161 | 156 | }; |
162 | 157 | </script> | ... | ... |
src/components/AuthorReadingNow.vue
... | ... | @@ -65,9 +65,11 @@ components: { |
65 | 65 | }, |
66 | 66 | mounted() { |
67 | 67 | var allSlideData = localStorage.getItem("spotlight_slide"+this.$route.params.caseStudyId); |
68 | - if (allSlideData) { | |
68 | + if (allSlideData) { | |
69 | 69 | this.allSlide = JSON.parse(allSlideData); |
70 | 70 | this.getCurrentSlideData(); |
71 | + }else{ | |
72 | + this.$router.push("/login"); | |
71 | 73 | } |
72 | 74 | |
73 | 75 | }, | ... | ... |
src/components/EpisodeIntro.vue
... | ... | @@ -108,9 +108,11 @@ components: { |
108 | 108 | }, |
109 | 109 | mounted() { |
110 | 110 | var allSlideData = localStorage.getItem("spotlight_slide"+this.$route.params.caseStudyId); |
111 | - if (allSlideData) { | |
111 | + if (allSlideData) { | |
112 | 112 | this.allSlide = JSON.parse(allSlideData); |
113 | 113 | this.getCurrentSlideData(); |
114 | + }else{ | |
115 | + this.$router.push("/login"); | |
114 | 116 | } |
115 | 117 | |
116 | 118 | }, | ... | ... |
src/components/NoScreenshotSingleAuthor.vue
... | ... | @@ -509,9 +509,11 @@ export default { |
509 | 509 | var allSlideData = localStorage.getItem( |
510 | 510 | "spotlight_slide" + this.$route.params.caseStudyId |
511 | 511 | ); |
512 | - if (allSlideData) { | |
512 | + if (allSlideData) { | |
513 | 513 | this.allSlide = JSON.parse(allSlideData); |
514 | 514 | this.getCurrentSlideData(); |
515 | + }else{ | |
516 | + this.$router.push("/login"); | |
515 | 517 | } |
516 | 518 | var userdata = localStorage.getItem("spotlight_usertoken"); |
517 | 519 | if (userdata) { | ... | ... |
src/components/SingleMobileScreenInsightOne.vue
... | ... | @@ -474,9 +474,11 @@ export default { |
474 | 474 | var allSlideData = localStorage.getItem( |
475 | 475 | "spotlight_slide" + this.$route.params.caseStudyId |
476 | 476 | ); |
477 | - if (allSlideData) { | |
477 | + if (allSlideData) { | |
478 | 478 | this.allSlide = JSON.parse(allSlideData); |
479 | 479 | this.getCurrentSlideData(); |
480 | + }else{ | |
481 | + this.$router.push("/login"); | |
480 | 482 | } |
481 | 483 | var userdata = localStorage.getItem("spotlight_usertoken"); |
482 | 484 | if (userdata) { | ... | ... |
src/components/SingleMobileScreenInsightTwo.vue
... | ... | @@ -540,9 +540,11 @@ export default { |
540 | 540 | "spotlight_slide" + this.$route.params.caseStudyId |
541 | 541 | ); |
542 | 542 | var userdata = localStorage.getItem("spotlight_usertoken"); |
543 | - if (allSlideData) { | |
543 | + if (allSlideData) { | |
544 | 544 | this.allSlide = JSON.parse(allSlideData); |
545 | 545 | this.getCurrentSlideData(); |
546 | + }else{ | |
547 | + this.$router.push("/login"); | |
546 | 548 | } |
547 | 549 | if (userdata) { |
548 | 550 | userdata = JSON.parse(userdata); | ... | ... |
src/components/TwoScreenWithInsight.vue
... | ... | @@ -477,9 +477,11 @@ export default { |
477 | 477 | var allSlideData = localStorage.getItem( |
478 | 478 | "spotlight_slide" + this.$route.params.caseStudyId |
479 | 479 | ); |
480 | - if (allSlideData) { | |
480 | + if (allSlideData) { | |
481 | 481 | this.allSlide = JSON.parse(allSlideData); |
482 | 482 | this.getCurrentSlideData(); |
483 | + }else{ | |
484 | + this.$router.push("/login"); | |
483 | 485 | } |
484 | 486 | var userdata = localStorage.getItem("spotlight_usertoken"); |
485 | 487 | if (userdata) { | ... | ... |
src/components/TwoScreenWithoutInsight.vue
... | ... | @@ -528,9 +528,11 @@ export default { |
528 | 528 | var allSlideData = localStorage.getItem( |
529 | 529 | "spotlight_slide" + this.$route.params.caseStudyId |
530 | 530 | ); |
531 | - if (allSlideData) { | |
531 | + if (allSlideData) { | |
532 | 532 | this.allSlide = JSON.parse(allSlideData); |
533 | 533 | this.getCurrentSlideData(); |
534 | + }else{ | |
535 | + this.$router.push("/login"); | |
534 | 536 | } |
535 | 537 | var userdata = localStorage.getItem("spotlight_usertoken"); |
536 | 538 | if (userdata) { | ... | ... |
src/components/noscreenshotSingleautho.vue
... | ... | @@ -444,6 +444,8 @@ data() { |
444 | 444 | if (allSlideData) { |
445 | 445 | this.allSlide = JSON.parse(allSlideData); |
446 | 446 | this.getCurrentSlideData(); |
447 | + }else{ | |
448 | + this.$router.push("/login"); | |
447 | 449 | } |
448 | 450 | var userdata = localStorage.getItem("spotlight_usertoken"); |
449 | 451 | if (userdata) { | ... | ... |
src/components/outro.vue
... | ... | @@ -18,14 +18,14 @@ |
18 | 18 | <img src="../assets/images/arrow-bottom.svg" /> |
19 | 19 | </div> |
20 | 20 | <ul class=""> |
21 | - <li v-for="(study, i) in caseStudies" :key="i"> | |
21 | + <!-- <li v-for="(study, i) in caseStudies" :key="i"> | |
22 | 22 | <a href=""> |
23 | 23 | <img :src="study.intro.logoURL" /> |
24 | 24 | <span |
25 | 25 | ><img src="../assets/images/p-eye.svg" /> 0 Views</span |
26 | 26 | > |
27 | 27 | </a> |
28 | - </li> | |
28 | + </li> --> | |
29 | 29 | |
30 | 30 | <!-- <li class="payments-spc-57"> |
31 | 31 | <a href=""> |
... | ... | @@ -223,6 +223,9 @@ export default { |
223 | 223 | this.getCurrentSlideData(); |
224 | 224 | this.getCaseStudies(); |
225 | 225 | this.getRating(); |
226 | + }else{ | |
227 | + | |
228 | + this.$router.push("/login"); | |
226 | 229 | } |
227 | 230 | }, |
228 | 231 | methods: { | ... | ... |