|
@@ -21,7 +21,7 @@
|
|
|
</view>
|
|
|
</z-paging>
|
|
|
<u-toast ref="uToast" />
|
|
|
- <judge-auth ref="judgeAuth" @adoptAuth="adoptAuth"/>
|
|
|
+ <judge-auth ref="judgeAuth" @adoptAuth="adoptAuth" />
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
@@ -71,18 +71,29 @@
|
|
|
},
|
|
|
adoptAuth(item) {
|
|
|
this.$u.api.skillTraining.signUpClassApi({
|
|
|
- packageId: item.id
|
|
|
- }).then(res => {
|
|
|
- if (res.code === 200) {
|
|
|
- this.jumpPage('/pages/skillsTraining/submitSuccess/submitSuccess');
|
|
|
- } else {
|
|
|
- this.$refs.uToast.show({
|
|
|
- title: res.msg,
|
|
|
- type: 'error'
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
- }
|
|
|
+ packageId: item.id
|
|
|
+ }).then(res => {
|
|
|
+ if (res.code === 200) {
|
|
|
+ this.jumpPage('/pages/skillsTraining/submitSuccess/submitSuccess');
|
|
|
+ } else {
|
|
|
+ this.$refs.uToast.show({
|
|
|
+ title: res.msg,
|
|
|
+ type: 'error'
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+ /**
|
|
|
+ * 跳转到指定页面
|
|
|
+ * @param { String } url
|
|
|
+ * @param {Object} parmas
|
|
|
+ */
|
|
|
+ jumpPage(url, params) {
|
|
|
+ this.$u.route({
|
|
|
+ url,
|
|
|
+ params
|
|
|
+ })
|
|
|
+ },
|
|
|
}
|
|
|
}
|
|
|
</script>
|