适配
This commit is contained in:
parent
42576b9285
commit
c3a07768ee
@ -1,12 +1,12 @@
|
||||
<template>
|
||||
<div class="main casemain" :class="{on: step == pageIndex }" :id="'pagemain'+pageIndex" v-show="step == pageIndex" :style="{height:step == pageIndex?'auto':'0px'}" >
|
||||
<div class="main casemain" :class="{on: step == pageIndex }" :id="'pagemain'+pageIndex" v-show="step == pageIndex" :style="{height:step == pageIndex?'100%':'0px'}" >
|
||||
<img src="../assets/bg.png" alt="" class="bg" />
|
||||
<div class="dealbox" style="position: relative;z-index:1;background:transparent;">
|
||||
<div class="prev" @click="switchPage(pageIndex - 1)">上一步</div>
|
||||
</div>
|
||||
<div class="content" >
|
||||
<div class="pagebox" >
|
||||
<div class="page" v-if="step == pageIndex">
|
||||
<div class="page" v-if="step == pageIndex" >
|
||||
<!-- <div class="card" v-html="pageItem.content"></div> -->
|
||||
<div
|
||||
class="card"
|
||||
@ -301,7 +301,7 @@ const handleClick = (e) => {
|
||||
|
||||
};
|
||||
onMounted(async () => {
|
||||
|
||||
|
||||
});
|
||||
const onChange=(newIndex)=>{
|
||||
position.value = newIndex || 0
|
||||
@ -314,12 +314,14 @@ const onChange=(newIndex)=>{
|
||||
display: block;
|
||||
position: relative;
|
||||
z-index:1;
|
||||
height:auto;
|
||||
height:100%;
|
||||
min-height: 100vh;
|
||||
}
|
||||
.casemain{
|
||||
|
||||
position: relative;
|
||||
z-index:-1000;
|
||||
min-height:0;
|
||||
height:0px;
|
||||
display: none;
|
||||
opacity: 0;
|
||||
|
||||
@ -18,7 +18,8 @@
|
||||
<div class="button" @click="handleStart" >马上开始</div>
|
||||
</div>
|
||||
</div>
|
||||
<caseDetail v-for="(item, index) in pageList" :pageIndex="index" :step="step" @switchPage="switchPage" :pageItem="item" :pageNum="pageList.length" @getAllAnswer="getAllAnswer" :start_time="start_time" :case_id="case_id"></caseDetail>
|
||||
|
||||
<caseDetail v-for="(item, index) in pageList" :pageIndex="index" :step="step" @switchPage="switchPage" :pageItem="item" :pageNum="pageList.length" @getAllAnswer="getAllAnswer" :start_time="start_time" :case_id="case_id" :key="item.case_item_id">{{ item.case_item_id }}</caseDetail>
|
||||
<comment v-show="!showIntro && step==pageList.length" ref="commentRef" :countTime="countTime" @initPage="initPage" :start_time="entry_time" :allAnswer="allAnswer" :is_welfare="is_welfare"></comment>
|
||||
<totop></totop>
|
||||
<back :project_id="caseObj.project_id"></back>
|
||||
@ -120,13 +121,18 @@ const getAllAnswer=(data)=>{
|
||||
const switchPage = (index) => {
|
||||
if(index<0){
|
||||
showIntro.value=true;
|
||||
step.value=-1;
|
||||
document.documentElement.scrollTop = 0;
|
||||
document.body.scrollTop = 0;
|
||||
setTimeout(()=>{
|
||||
step.value=-1;
|
||||
},0)
|
||||
}else{
|
||||
step.value=index;
|
||||
|
||||
document.documentElement.scrollTop = 0;
|
||||
document.body.scrollTop = 0;
|
||||
setTimeout(()=>{
|
||||
step.value=index;
|
||||
},0)
|
||||
}
|
||||
if(index==pageList.value.length){
|
||||
//alert(caseObj.project_id);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user