提交 e905a5f5 authored 作者: matian's avatar matian

updates

上级 6d83ad83
......@@ -28,7 +28,11 @@ export function getReportDetail(id) {
// 验证是否有未完成的答题记录
export function checkRecord(id, type) {
return httpRequest.post(`/api/xtraining/api/v1/answer/${id}/check-record/${type}`, {}, {
return httpRequest.post(
`/api/xtraining/api/v1/answer/${id}/check-record/${type}`,
{},
{
headers: { 'Content-Type': 'application/json' }
})
}
)
}
<template>
<div>
<ToolCard class="main_content">
<Step :activeStep="activeStep" class="pt50-pl60"/>
<Step :activeStep="activeStep" class="pt50-pl60" />
<div>
<MailStepOne v-if="activeStep === 0" class="pt-50"/>
<MailStepTwo v-if="activeStep === 1" class="pt-50"/>
<MailStepOne v-if="activeStep === 0" class="pt-50" />
<MailStepTwo v-if="activeStep === 1" class="pt-50" />
<div class="main_content_btn">
<div class="step_prev step_btn" @click="handlePrev" v-if="activeStep > 0">上一步</div>
<div class="step_next step_btn" @click="handleNext" v-if="activeStep >= 1 || activeStep < 3">下一步</div>
<div class="step_next step_btn" @click="handleNext" v-if="activeStep >= 0 && activeStep < 3">下一步</div>
<div class="step_finished step_btn" @click="handlePreview" v-if="activeStep === 3">点击生成预览</div>
</div>
</div>
......@@ -20,6 +20,7 @@ import ToolCard from '@/components/base/ToolCard.vue'
import MailStepOne from '../components/mail/MailStepOne.vue'
import Step from '@/components/base/Step.vue'
import MailStepTwo from '../components/mail/MailStepTwo.vue'
import { cacheReport } from '../api'
export default {
components: {
ToolCard,
......@@ -39,6 +40,10 @@ export default {
},
// 下一步
handleNext() {
const reports = { type: 1, commit_report: [{ 1: 1 }] }
cacheReport(this.$store.state.case.id, { reports: JSON.stringify(reports) }).then(res => {
console.log(res, 'res111')
})
this.activeStep++
},
// 点击生成预览
......@@ -55,7 +60,7 @@ export default {
.main_content_btn {
display: flex;
justify-content: center;
padding-bottom:70px;
padding-bottom: 70px;
.step_btn {
width: 119px;
height: 32px;
......@@ -82,10 +87,10 @@ export default {
}
}
}
.pt50-pl60{
.pt50-pl60 {
padding: 50px 0 0 60px;
}
.pt-50{
.pt-50 {
padding-top: 50px;
}
</style>
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论