|
@@ -32,7 +32,7 @@ import { parseTime, SignInTime } from '../util/formattingData'
|
32
|
32
|
export default {
|
33
|
33
|
data() {
|
34
|
34
|
return {
|
35
|
|
- ClassContent: null,
|
|
35
|
+ ClassContent: {},
|
36
|
36
|
isShoucang: false,
|
37
|
37
|
courseIds: '',
|
38
|
38
|
|
|
@@ -42,12 +42,12 @@ export default {
|
42
|
42
|
},
|
43
|
43
|
mounted() {
|
44
|
44
|
this.onloadClass()
|
45
|
|
- this.courseIds = this.$route.params.courseId
|
|
45
|
+ this.courseIds = this.$route.query.courseId
|
46
|
46
|
},
|
47
|
47
|
methods: {
|
48
|
48
|
parseTime,
|
49
|
49
|
onloadClass() {
|
50
|
|
- getCourseInfof(this.$route.params.courseId).then((e) => {
|
|
50
|
+ getCourseInfof(this.$route.query.courseId).then((e) => {
|
51
|
51
|
this.ClassContent = e
|
52
|
52
|
if (e.isFavored) {
|
53
|
53
|
this.isShoucang = true
|
|
@@ -58,7 +58,7 @@ export default {
|
58
|
58
|
},
|
59
|
59
|
collectionHande() {
|
60
|
60
|
addCollection({
|
61
|
|
- targetId: this.$route.params.courseId,
|
|
61
|
+ targetId: this.$route.query.courseId,
|
62
|
62
|
targetName: this.ClassContent.title,
|
63
|
63
|
targetType: 'course'
|
64
|
64
|
}).then((e) => {
|
|
@@ -69,7 +69,7 @@ export default {
|
69
|
69
|
},
|
70
|
70
|
deleteColl() {
|
71
|
71
|
deleteCollection({
|
72
|
|
- targetId: this.$route.params.courseId,
|
|
72
|
+ targetId: this.$route.query.courseId,
|
73
|
73
|
targetName: this.ClassContent.title,
|
74
|
74
|
targetType: 'course'
|
75
|
75
|
}).then((e) => {
|