| | |
| | | <el-main class="align-center"> |
| | | <H1 v-if="content!==null && content.trim()!==''">{{content}}</H1> |
| | | <H1 v-else>{{$t('finishMsg')}}</H1> |
| | | <el-button type="danger" :disabled="downDisable" @click="downReport" round>{{$t('down')}}</el-button> |
| | | </el-main> |
| | | </el-container> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import examPaperApi from '@/api/examPaper' |
| | | import {mapState} from "vuex"; |
| | | export default { |
| | | data () { |
| | | return { |
| | | name: this.$route.query.name, |
| | | content: this.$route.query.content |
| | | content: this.$route.query.content, |
| | | downDisable: true, |
| | | downUrl: '' |
| | | } |
| | | }, |
| | | created () { |
| | | let _this = this |
| | | examPaperApi.selectTesterReport(_this.memberToken).then(re => { |
| | | if (re.code === 0) { |
| | | _this.downDisable = false |
| | | _this.downUrl = re.msg |
| | | console.log(re) |
| | | } else { |
| | | console.log(re) |
| | | } |
| | | }) |
| | | }, |
| | | mounted () { |
| | | |
| | |
| | | beforeDestroy () { |
| | | }, |
| | | methods: { |
| | | downReport: function () { |
| | | let _this = this |
| | | examPaperApi.down(_this.downUrl) |
| | | } |
| | | }, |
| | | computed: { |
| | | ...mapState('user', { memberToken: state => state.memberToken }) |
| | | } |
| | | } |
| | | </script> |