From e90c18770dfccded106c395c05dbc88d8fd99040 Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期一, 15 四月 2024 16:17:21 +0800 Subject: [PATCH] 答题器,详情页bug修改 --- packageBookService/pages/bookServices/examination/questionList/index.js | 9 ---- packageBookService/pages/bookServices/detail/components/tree/index.wxss | 1 packageBookService/pages/bookServices/detail/components/suggestDialog/index.js | 2 packageBookService/pages/bookServices/examination/examination.js | 35 +++++++++-------- packageBookService/pages/bookServices/examination/questionSchedule/index.js | 12 +---- packageBookService/pages/bookServices/detail/index.wxss | 43 +++++++++++++++------ packageBookService/pages/bookServices/examination/examination.wxml | 2 packageBookService/pages/bookServices/examination/questionOptions/index.wxss | 5 +- packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxml | 2 packageBookService/pages/bookServices/detail/components/testResource/testResource.wxss | 5 +- packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxss | 4 +- 11 files changed, 66 insertions(+), 54 deletions(-) diff --git a/packageBookService/pages/bookServices/detail/components/suggestDialog/index.js b/packageBookService/pages/bookServices/detail/components/suggestDialog/index.js index 19048b5..c6721e0 100644 --- a/packageBookService/pages/bookServices/detail/components/suggestDialog/index.js +++ b/packageBookService/pages/bookServices/detail/components/suggestDialog/index.js @@ -35,7 +35,7 @@ * 缁勪欢鐨勫垵濮嬫暟鎹� */ data: { - inputStyle: 'border: 2rpx solid rgba(220,220,220,1);border-radius: 12rpx; padding:16rpx;', + inputStyle: 'border: 2rpx solid rgba(220,220,220,1);border-radius: 12rpx; padding: 0 0 0 16rpx;', showIndex: null, //鎵撳紑寮圭獥鐨勫搴斾笅鏍� height: '', //灞忓箷楂樺害 inputvalue: '', diff --git a/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxml b/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxml index 49d7801..8350c32 100644 --- a/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxml +++ b/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxml @@ -14,7 +14,7 @@ <view class="close-icon" bind:tap="closePopup"> <t-icon name="close-circle" - size="24" + size="28" data-name="close-circle" bind:click="onIconTap" color="#f1f1f1" diff --git a/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxss b/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxss index 13c3c3f..3bedf03 100644 --- a/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxss +++ b/packageBookService/pages/bookServices/detail/components/suggestDialog/index.wxss @@ -142,7 +142,7 @@ .popup-content { width: 100%; - height: 720rpx; + height: 680rpx; display: flex; flex-direction: column; } @@ -206,5 +206,5 @@ /* background-color: #f1f1f1; border-radius: 20rpx; */ position: absolute; - bottom: -60rpx; + bottom: -70rpx; } \ No newline at end of file diff --git a/packageBookService/pages/bookServices/detail/components/testResource/testResource.wxss b/packageBookService/pages/bookServices/detail/components/testResource/testResource.wxss index d520034..670cc67 100644 --- a/packageBookService/pages/bookServices/detail/components/testResource/testResource.wxss +++ b/packageBookService/pages/bookServices/detail/components/testResource/testResource.wxss @@ -76,7 +76,7 @@ justify-content: center; align-items: center; width: 176rpx; - height: 82rpx; + height: 80rpx; } .test-btn:last-child { @@ -89,7 +89,8 @@ .btn-box { display: flex; - width: 50%; + justify-content: space-between; + width: 49%; } .practice-btn { diff --git a/packageBookService/pages/bookServices/detail/components/tree/index.wxss b/packageBookService/pages/bookServices/detail/components/tree/index.wxss index 64c43c0..b79a80b 100644 --- a/packageBookService/pages/bookServices/detail/components/tree/index.wxss +++ b/packageBookService/pages/bookServices/detail/components/tree/index.wxss @@ -3,6 +3,7 @@ --td-collapse-header-text-color: #ff6C00; --td-collapse-icon-color: #ff6c00; --td-collapse-header-height: min-content; + padding-bottom: 50rpx; } diff --git a/packageBookService/pages/bookServices/detail/index.wxss b/packageBookService/pages/bookServices/detail/index.wxss index 454c921..69f336c 100644 --- a/packageBookService/pages/bookServices/detail/index.wxss +++ b/packageBookService/pages/bookServices/detail/index.wxss @@ -160,7 +160,7 @@ display: flex; align-items: center; width: 100%; - height: 150rpx; + height: 120rpx; border-radius: 0 0 20rpx 20rpx; } @@ -186,12 +186,12 @@ .price { margin-left: 12rpx; - font-size: 34rpx; + font-size: 32rpx; color: #fff; } .price-text { - font-size: 34rpx; + font-size: 32rpx; } .price-old { @@ -225,6 +225,7 @@ min-height: calc(100vh - 900rpx); margin-top: 20rpx; background-color: #fff !important; + --td-tab-item-height: 140rpx; } @@ -410,12 +411,14 @@ } .t-tabs .t-tabs__item--active { - /* color: #ff6d00; - font-size: 30rpx; */ background-repeat: no-repeat; - background-size: 40% 64%; - background-position: right; - background-image: url(http://jsysf.bnuic.com/website/image/click-icon.png); + background-size: 30% 40%; + background-position: 65% 50%; + background-image: url(https://jsek.bnuic.com/home/image/click-icon.png); +} + +.t-tabs__item--evenly { + flex: 1 0 auto !important; } .loading { @@ -433,10 +436,26 @@ font-size: 28rpx !important; } -.t-tabs__item-inner { - font-size: 24rpx; -} .t-tabs__item-inner .t-icon { - margin-bottom: 6rpx; + margin-bottom: 12rpx; +} + +.t-tabs__item-inner .t-icon__image { + width: 36rpx !important; + height: 44rpx !important; +} + +.t-tabs__nav .t-tabs__item:nth-child(3) .t-tabs__item-inner .t-icon__image { + width: 44rpx !important; + height: 40rpx !important; +} + +.t-tabs__nav .t-tabs__item { + width: 160rpx !important; + padding: 0 !important; +} + +.t-tabs__scroll { + overflow-x: auto; } \ No newline at end of file diff --git a/packageBookService/pages/bookServices/examination/examination.js b/packageBookService/pages/bookServices/examination/examination.js index 070b53f..a819f70 100644 --- a/packageBookService/pages/bookServices/examination/examination.js +++ b/packageBookService/pages/bookServices/examination/examination.js @@ -75,7 +75,6 @@ }); } this.init(); - console.log("浼犲弬", options); }, /** @@ -202,15 +201,15 @@ // 姝e垯琛ㄨ揪寮忓尮閰�<source>鏍囩涓殑src灞炴�у�� var srcRegex = /<source\s+src="([^"]+)"/i; var srcTwo = /<audio\s+src="([^"]+)"/i; - + // 鎵ц姝e垯鍖归厤 var match = srcRegex.exec(htmlString); const local = srcTwo.exec(htmlString) // 濡傛灉鍖归厤鎴愬姛锛岃繑鍥炵涓�涓崟鑾风粍鐨勫唴瀹癸紙src灞炴�х殑鍊硷級 if (match && match[1]) { - return match[1].replace( '../file', app.config.requestCtx + '/file'); + return match[1].replace('../file', app.config.requestCtx + '/file'); } else if (local && local[1]) { - return local[1].replace( '../file', app.config.requestCtx + '/file') + return local[1].replace('../file', app.config.requestCtx + '/file') } else { // 濡傛灉娌℃湁鍖归厤鍒帮紝杩斿洖null return null; @@ -794,9 +793,6 @@ }, }; await app.MG.store.getProductDetail(query).then((res) => { - if (!res.datas.cmsDatas[0].datas.length) return this.setData({ - noData: true - }) this.setData({ total: res.datas.cmsDatas[0].datas.length, }); @@ -875,7 +871,7 @@ /\<img/gi, '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' ) - .replace(/\<p/gi, '<p class="stem-rich-p"'); + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); } // 閫夐」瀵屾枃鏈鐞� if ( @@ -888,7 +884,7 @@ if (item.txt) item.txt = item.txt .replace(/\<img/gi, '<img class="option-rich-img"') - .replace(/\<p/gi, '<p class="stem-rich-p"'); + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); }); } // 瑙f瀽瀵屾枃鏈鐞� @@ -987,7 +983,14 @@ }); } // 鏈夐鐩啀寮�濮嬪�掕鏃� - if (this.data.questionDataList.length) this.startCountdown(); + if (this.data.questionDataList.length) { + // console.log(this.data.questionDataList); + this.startCountdown(); + } else { + this.setData({ + noData: true + }) + } this.setData({ loading: false, }); @@ -1388,7 +1391,7 @@ /\<img/gi, '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' ) - .replace(/\<p/gi, '<p class="stem-rich-p"'); + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); } // 閫夐」瀵屾枃鏈鐞� if ( @@ -1401,7 +1404,7 @@ if (item.txt) item.txt = item.txt .replace(/\<img/gi, '<img class="option-rich-img"') - .replace(/\<p/gi, '<p class="stem-rich-p"'); + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); }); } // 瑙f瀽瀵屾枃鏈鐞� @@ -1636,7 +1639,7 @@ /\<img/gi, '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' ) - .replace(/\<p/gi, '<p class="stem-rich-p"'); + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); } // 閫夐」瀵屾枃鏈鐞� if ( @@ -1649,7 +1652,7 @@ if (item.txt) item.txt = item.txt .replace(/\<img/gi, '<img class="option-rich-img"') - .replace(/\<p/gi, '<p class="stem-rich-p"'); + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); }); } // 瑙f瀽瀵屾枃鏈鐞� @@ -1906,7 +1909,7 @@ questionObj.stem.stemTxt = questionObj.stem.stemTxt.replace( /\<img/gi, '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img"' - ); + ).replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); } // 閫夐」瀵屾枃鏈鐞� if ( @@ -1920,7 +1923,7 @@ item.txt = item.txt.replace( /\<img/gi, '<img class="option-rich-img"' - ); + ).replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); }); } // 鍚姏棰樹慨鏀� diff --git a/packageBookService/pages/bookServices/examination/examination.wxml b/packageBookService/pages/bookServices/examination/examination.wxml index 4ea7c17..ec63e12 100644 --- a/packageBookService/pages/bookServices/examination/examination.wxml +++ b/packageBookService/pages/bookServices/examination/examination.wxml @@ -81,7 +81,7 @@ subjectiveNum="{{subjectiveNum}}" subjectiveGrade="{{subjectiveGrade}}" correctNum="{{correctNum}}" - mockSumTime="{{mock.sumTime}}" + mockSumTime="{{mockData.sumTime}}" bind:setCollect="setCollect" bind:submitPaper="submitPaper" bind:restart="restart" diff --git a/packageBookService/pages/bookServices/examination/questionList/index.js b/packageBookService/pages/bookServices/examination/questionList/index.js index 0a00adc..1785411 100644 --- a/packageBookService/pages/bookServices/examination/questionList/index.js +++ b/packageBookService/pages/bookServices/examination/questionList/index.js @@ -34,14 +34,7 @@ type: Boolean, } }, - observers: { - 'questionList': function (newValue) { - console.log(newValue); - } - }, - created() { - // console.log('缁勪欢浼犲弬', this.properties); - }, + observers: {}, ready() { innerAudioContext.stop(); innerAudioContext.destroy(); diff --git a/packageBookService/pages/bookServices/examination/questionOptions/index.wxss b/packageBookService/pages/bookServices/examination/questionOptions/index.wxss index 713cfc9..45afba8 100644 --- a/packageBookService/pages/bookServices/examination/questionOptions/index.wxss +++ b/packageBookService/pages/bookServices/examination/questionOptions/index.wxss @@ -34,6 +34,7 @@ .popup-block { width: 100vw; height: 700rpx; + padding-bottom: 50rpx; background: #fff; border-top-left-radius: 16rpx; border-top-right-radius: 16rpx; @@ -60,7 +61,7 @@ } .question-title { - margin-top: 40rpx; + /* margin-top: 40rpx; */ display: flex; align-items: center; } @@ -112,7 +113,7 @@ } .question-list { - margin: 46rpx 0 64rpx 0; + margin: 8rpx 0 66rpx 0; display: flex; flex-wrap: wrap; } diff --git a/packageBookService/pages/bookServices/examination/questionSchedule/index.js b/packageBookService/pages/bookServices/examination/questionSchedule/index.js index 903a716..2c91db6 100644 --- a/packageBookService/pages/bookServices/examination/questionSchedule/index.js +++ b/packageBookService/pages/bookServices/examination/questionSchedule/index.js @@ -1,4 +1,3 @@ - // pages/bookServices/examination/questionSchedule/questionSchedule.js Component({ /** @@ -41,10 +40,8 @@ }, created( - ) { - }, - detached() { - }, + ) {}, + detached() {}, /** * 缁勪欢鐨勫垵濮嬫暟鎹� @@ -80,9 +77,6 @@ percentage: (this.data.ready / this.data.questionList.length) * 100 }) }, - 'isNight': function (newValue) { - console.log('is', newValue); - } }, /** * 缁勪欢鐨勬柟娉曞垪琛� @@ -182,4 +176,4 @@ // } } -}) +}) \ No newline at end of file -- Gitblit v1.9.1