From 9d06ca3082e29484266c2a9bee62c7a8c92ee07c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E8=88=AA?= Date: Fri, 12 Sep 2025 16:59:05 +0800 Subject: [PATCH 1/2] =?UTF-8?q?fix=EF=BC=9A=20=E6=A0=B7=E5=BC=8F=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/course/index.vue | 66 +++++++++++++++++++++++++++----------- 1 file changed, 48 insertions(+), 18 deletions(-) diff --git a/src/pages/course/index.vue b/src/pages/course/index.vue index 1ad37b11..5e0ad9f4 100644 --- a/src/pages/course/index.vue +++ b/src/pages/course/index.vue @@ -113,6 +113,9 @@ + + + @@ -236,24 +239,22 @@ import { onShow } from "@dcloudio/uni-app" } const courseListBase = ref([]) const courseList = computed(()=>{ - if(activeTag.value.length > 0 && !!activeTag.value[0]){ - return courseListBase.value - // .filter(t=>{ - // let _tags = (t.tagCataList||[]).map(k=>k.tagId) - // let _pass = false - // activeTag.value.forEach(k => { - // if(_tags.includes(k)){ - // _pass = true - // } - // }) - // return _pass - // }) - }else{ - return courseListBase.value - } - // return activeTag.value.length > 0 - // ?courseListBase.value.filter(t=>(t.tagCataList||[]).map(k=>k.tagId).indexOf(activeTag.value)>=0) - // :courseListBase.value + return courseListBase.value + // if(activeTag.value.length > 0 && !!activeTag.value[0]){ + // return courseListBase.value + // .filter(t=>{ + // let _tags = (t.tagCataList||[]).map(k=>k.tagId) + // let _pass = false + // activeTag.value.forEach(k => { + // if(_tags.includes(k)){ + // _pass = true + // } + // }) + // return _pass + // }) + // }else{ + // return courseListBase.value + // } }) // 整理树形 const courseListTree = computed(()=>{ @@ -310,6 +311,7 @@ import { onShow } from "@dcloudio/uni-app" pageObj.value.page = 1 } pageObj.value.total = 0 + loading.value = true switch (activeTab.value){ case '全部': queryCrsInfoByCatalogApi({ @@ -319,6 +321,8 @@ import { onShow } from "@dcloudio/uni-app" }).then(res=>{ courseListBase.value = courseListBase.value.concat(res.body || []) pageObj.value.total = res.total + }).finally(()=>{ + loading.value = false }) break; case '热门': @@ -335,12 +339,16 @@ import { onShow } from "@dcloudio/uni-app" }).then(res=>{ courseListBase.value = courseListBase.value.concat(res.body || []) pageObj.value.total = res.total + }).finally(()=>{ + loading.value = false }) break; } } + const loading = ref(false) const changeTab = (item) => { if(!item) return + courseListBase.value = [] activeTab.value = item.name activeTag.value = [] pageObj.value.page = 1 @@ -348,32 +356,43 @@ import { onShow } from "@dcloudio/uni-app" // activeTag.value = '' activeCourseType.value = '' activePrdlineType.value = '' + loading.value = true switch (item.name){ case '全部': queryCrsInfoByCatalogApi(pageObj.value).then(res=>{ courseListBase.value = res.body || [] pageObj.value.total = res.total + }).finally(()=>{ + loading.value = false }) break; case '热门': queryCrsInfoByPopularApi(pageObj.value).then(res=>{ courseListBase.value = res.body || [] + }).finally(()=>{ + loading.value = false }) break; case '最新': queryCrsInfoByLastnewApi(pageObj.value).then(res=>{ courseListBase.value = res.body || [] + }).finally(()=>{ + loading.value = false }) break; case '推荐': queryCrsInfoByRecmdApi(pageObj.value).then(res=>{ courseListBase.value = res.body || [] + }).finally(()=>{ + loading.value = false }) break; case '生产线': queryCrsInfoByPrdLineApi(pageObj.value).then(res=>{ courseListBase.value = res.body || [] pageObj.value.total = res.total + }).finally(()=>{ + loading.value = false }) break; } @@ -719,6 +738,17 @@ import { onShow } from "@dcloudio/uni-app" } } } + .loading-box{ + width: 100%; + height: 100rpx; + position: relative; + .loading-val{ + position: absolute; + left:50%; + top:50%; + transform: translate(-50%, -50%); + } + } } } \ No newline at end of file From c8216c5cb6296696f3d9f892f863e8705efca4ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=94=B0=E5=B2=A9?= Date: Mon, 15 Sep 2025 08:35:09 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=94=99=E9=A2=98?= =?UTF-8?q?=E6=9C=ACbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 4 +- README.en.md | 3 + src/components/examination/es-analysis.vue | 2 +- src/composables/useZpaging.js | 3 +- src/pages.json | 1 + src/pages/examination/index.vue | 3 +- src/pages/learningTasks/index.vue | 3 - src/pages/login/ysxy.vue | 27 ++- src/pages/practice/index.vue | 8 +- .../components/correct.vue | 96 +++++------ .../components/favorites-course.vue | 125 +++++++------- src/pages/wrongQuestionRecord/correct.vue | 49 ++++-- src/pages/wrongQuestionRecord/index.vue | 154 ++++++++---------- src/pagesA.json | 3 +- 14 files changed, 253 insertions(+), 228 deletions(-) diff --git a/.env.development b/.env.development index b5885673..17ba804a 100644 --- a/.env.development +++ b/.env.development @@ -6,7 +6,7 @@ ENV = 'development' # VITE_APP_BASE_API_Url = 'http://25.18.122.78:9786' # DEV -VITE_APP_BASE_API_Url = 'https://aitstest.jlbank.com.cn:7002' +VITE_APP_BASE_API_Url = 'https://aitstest.jlbank.com.cn:7001' # app入口 #VITE_APP_BASE_API_Url = 'https://aitstest.jlbank.com.cn:7002' @@ -24,7 +24,7 @@ VITE_APP_BASE_H5_API_Url = 'https://aitstest.jlbank.com.cn:7001' # dev -VITE_APP_BASE_H5_API_Url = 'http://25.18.122.65:7001' +#VITE_APP_BASE_H5_API_Url = 'http://25.18.122.65:7001' # sit #VITE_APP_BASE_H5_API_Url = 'http://25.18.122.91:9786' diff --git a/README.en.md b/README.en.md index 53639d47..cb85303e 100644 --- a/README.en.md +++ b/README.en.md @@ -4,3 +4,6 @@ npm 淘宝源下载 :npm config set registry https://registry.npmmirror.com npm config set registry http://25.12.10.69:8081/repository/aliyun-npm/ + +npm install --registry=https://registry.npmmirror.com + diff --git a/src/components/examination/es-analysis.vue b/src/components/examination/es-analysis.vue index 84e5bea3..375e7be7 100644 --- a/src/components/examination/es-analysis.vue +++ b/src/components/examination/es-analysis.vue @@ -51,7 +51,7 @@ }); const keywords = computed(() => { if (!props.value.relKeyword) return []; - return props.value.relKeyword.split(',').map((key) => key.trim()); + return props.value.relKeyword.split(/[,、]/).map((key) => key.trim()); }); const highlightedText = computed(() => { diff --git a/src/composables/useZpaging.js b/src/composables/useZpaging.js index 75e54dae..faf92378 100644 --- a/src/composables/useZpaging.js +++ b/src/composables/useZpaging.js @@ -6,13 +6,13 @@ import { } from 'vue'; export default function useZpaging({ - pagingRef, // 必传:z-paging组件的ref fetchFunction, // 必传:接口请求函数 searchKey = '' // 可选:搜索参数名,默认'searchText' }) { const total = ref(-1); const data_list = ref([]); const searchText = ref(''); + const pagingRef = ref(null); const queryList = async (pageNo, pageSize) => { try { const requestParams = { @@ -52,6 +52,7 @@ export default function useZpaging({ } }; return { + pagingRef, queryList, reload, search, diff --git a/src/pages.json b/src/pages.json index 0f86c625..793326fb 100644 --- a/src/pages.json +++ b/src/pages.json @@ -195,6 +195,7 @@ "path": "pages/wrongQuestionRecord/correct", "style": { "navigationBarTitleText": "错题本做题页", + "disableSwipeBack": true, "app-plus": { "titleNView": false } diff --git a/src/pages/examination/index.vue b/src/pages/examination/index.vue index 8bdba1fe..fd4dde92 100644 --- a/src/pages/examination/index.vue +++ b/src/pages/examination/index.vue @@ -156,7 +156,7 @@ import Subject from '@/components/examination/subject.vue'; import TouchBtn from '@/components/examination/touchBtn.vue'; import { ref, reactive, computed, onMounted, nextTick } from 'vue'; - import { onLoad } from '@dcloudio/uni-app'; + import { onLoad, onBackPress } from '@dcloudio/uni-app'; import common from '@/common/common'; import { getPageCache, setupKeyboardHeightListener } from '@/common/common'; import { commonUploadVoiceFile } from '@/api/common.js'; @@ -663,6 +663,7 @@ } }); }; + onBackPress((res) => res.from === 'backbutton'); diff --git a/src/pages/wrongQuestionRecord/components/favorites-course.vue b/src/pages/wrongQuestionRecord/components/favorites-course.vue index 2ebc228e..f5b1a62c 100644 --- a/src/pages/wrongQuestionRecord/components/favorites-course.vue +++ b/src/pages/wrongQuestionRecord/components/favorites-course.vue @@ -1,77 +1,92 @@ diff --git a/src/pages/wrongQuestionRecord/correct.vue b/src/pages/wrongQuestionRecord/correct.vue index eb1f4efc..fbfea93b 100644 --- a/src/pages/wrongQuestionRecord/correct.vue +++ b/src/pages/wrongQuestionRecord/correct.vue @@ -80,7 +80,7 @@