Commit c0eee663 by doszhang

dos

parent 7a32c277
...@@ -446,6 +446,11 @@ function submitAnswer() { ...@@ -446,6 +446,11 @@ function submitAnswer() {
function prevQuestion() { function prevQuestion() {
if (nowQuestionIndex != 1) { if (nowQuestionIndex != 1) {
if (nowQuestionIndex == 2) {
$('.index-scroll').css('height', '27.5rem');
} else {
$('.index-scroll').css('height', '30.5rem');
}
let nowIndex1 = nowQuestionIndex; let nowIndex1 = nowQuestionIndex;
console.log('nowIndex:' + nowIndex1); console.log('nowIndex:' + nowIndex1);
$('.question' + nowQuestionIndex + '-block').addClass('fadeoutright'); $('.question' + nowQuestionIndex + '-block').addClass('fadeoutright');
...@@ -474,6 +479,7 @@ function prevQuestion() { ...@@ -474,6 +479,7 @@ function prevQuestion() {
function nextQuestion(e) { function nextQuestion(e) {
if ((e == 'indexbar' && (watchedQuestion.indexOf(nowQuestionIndex + 1) != -1)) || e != 'indexbar') { if ((e == 'indexbar' && (watchedQuestion.indexOf(nowQuestionIndex + 1) != -1)) || e != 'indexbar') {
if (nowQuestionIndex != 5) { if (nowQuestionIndex != 5) {
$('.index-scroll').css('height', '30.5rem');
if (nowAnswer !== '') { if (nowAnswer !== '') {
let nowIndex = nowQuestionIndex; let nowIndex = nowQuestionIndex;
answerArr[nowQuestionIndex - 1] = nowAnswer; answerArr[nowQuestionIndex - 1] = nowAnswer;
...@@ -543,6 +549,7 @@ function initQuestion() { ...@@ -543,6 +549,7 @@ function initQuestion() {
$('.btn-nextquestion').show(); $('.btn-nextquestion').show();
$('.point').css('left', 0); $('.point').css('left', 0);
$('.poster-canvas-block').html(''); $('.poster-canvas-block').html('');
$('.index-scroll').css('height', '27.5rem');
nowQuestionIndex = 1; nowQuestionIndex = 1;
answerArr = []; answerArr = [];
nowAnswer = ''; nowAnswer = '';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment