From 9cad6a832c786989be620573b09badccfe7e3b51 Mon Sep 17 00:00:00 2001 From: QYF-GitLab1 <1940665526@qq.com> Date: 星期一, 25 八月 2025 15:11:37 +0800 Subject: [PATCH] 首页头部,样式调整 --- src/views/classManage/jobManage.vue | 141 ++++++++++++++++++++++++----------------------- 1 files changed, 72 insertions(+), 69 deletions(-) diff --git a/src/views/classManage/jobManage.vue b/src/views/classManage/jobManage.vue index c2d8d25..495e873 100644 --- a/src/views/classManage/jobManage.vue +++ b/src/views/classManage/jobManage.vue @@ -317,7 +317,7 @@ </el-table-column> <el-table-column label="鍒嗘暟" width="120"> <template #default="scope"> - <span style="color: #ff6c00">{{ scope.row.score }}</span> + <span style="color: #019e58">{{ scope.row.score }}</span> </template> </el-table-column> <el-table-column label="璁剧疆" width="260"> @@ -389,7 +389,7 @@ align-center v-model="visibleView" destroy-on-close - width="900" + width="1200" > <template #header> <div class="viewTitle">宸查�夐鐩�</div> @@ -445,7 +445,7 @@ align-center v-model="visibleLook" destroy-on-close - width="900" + width="1200" > <template #header> <div class="viewTitle">棰勮浣滀笟</div> @@ -550,8 +550,8 @@ { value: config.taskType.homeWork, field: 'Type', - subFilters: [] - } + subFilters: [], + }, ]) // task const taskData = reactive({ @@ -563,7 +563,7 @@ state: '', groupId: '', beginDate: '', - endDate: '' + endDate: '', }) // question Key const questionKey = [ @@ -577,7 +577,7 @@ 'Embedded_QuestionBank_QuestionType', 'Embedded_QuestionBank_Score', 'Embedded_QuestionBank_Stem', - 'Embedded_QuestionBank_StemStyle' + 'Embedded_QuestionBank_StemStyle', ] // dialognew const visible = ref(false) @@ -589,14 +589,14 @@ homeworkName: '', homeworkStartingDate: '', homeworkSubmissionDate: '', - explain: '' + explain: '', }) let pages = reactive({ currentPage: 1, page: 1, pageSize: 15, count: 0, - loading: false + loading: false, }) // dialogedit const visibleEdit = ref(false) @@ -638,11 +638,11 @@ const pubValue = ref(null) onMounted(() => { - const userCache: any = localStorage.getItem('jesk-userInfo') + const userCache: any = localStorage.getItem(config.userInfoKey) if (userCache) { userInfo.value = JSON.parse(userCache) } - defaultCmsPath.value = classInfo.bookRefCode ? 'jsek_digitalTextbooks' : 'defaultGoodsStore3' + defaultCmsPath.value = classInfo.bookRefCode ? '*' : 'defaultGoodsStore3' getTaskList() }) @@ -672,7 +672,7 @@ if (!taskItem.homeworkName) { ElMessage({ type: 'warning', - message: '璇峰~鍐欎綔涓氬悕绉� ' + message: '璇峰~鍐欎綔涓氬悕绉� ', }) newLoading.value = false return false @@ -680,7 +680,7 @@ if (!taskItem.homeworkStartingDate) { ElMessage({ type: 'warning', - message: '璇峰~鍐欎綔涓氬紑濮嬫椂闂� ' + message: '璇峰~鍐欎綔涓氬紑濮嬫椂闂� ', }) newLoading.value = false return false @@ -688,7 +688,7 @@ if (!taskItem.homeworkSubmissionDate) { ElMessage({ type: 'warning', - message: '璇峰~鍐欎綔涓氱粨鏉熸椂闂�' + message: '璇峰~鍐欎綔涓氱粨鏉熸椂闂�', }) newLoading.value = false return false @@ -705,7 +705,7 @@ beginDate: taskItem.homeworkStartingDate, endDate: taskItem.homeworkSubmissionDate, duration: 0, - config: JSON.stringify({ scoreData: [] }) + config: JSON.stringify({ scoreData: [] }), } MG.edu .newTask(data) @@ -739,7 +739,7 @@ beginDate: moment(taskItem.homeworkStartingDate).format('YYYY-MM-DDTHH:mm:ss'), endDate: moment(taskItem.homeworkSubmissionDate).format('YYYY-MM-DDTHH:mm:ss'), duration: 0, - config: JSON.stringify({ scoreData: scoreData.value }) + config: JSON.stringify({ scoreData: scoreData.value }), } MG.edu .updateTask(data) @@ -766,11 +766,11 @@ size: pages.pageSize, sort: { type: 'Desc', - field: 'CreateDate' + field: 'CreateDate', }, filterList, searchList, - groupId: classInfo?.id + groupId: classInfo?.id, } MG.edu .getTaskList(data) @@ -786,7 +786,7 @@ return { ...item, beginDate: moment(item.beginDate).format('YYYY-MM-DD'), - endDate: moment(item.endDate).format('YYYY-MM-DD') + endDate: moment(item.endDate).format('YYYY-MM-DD'), } }) if (taskData.id) { @@ -821,8 +821,8 @@ { compareType: 'Contains', keywords: searchKey.value, - field: 'Name' - } + field: 'Name', + }, ] pages.page = 1 pages.currentPage = 1 @@ -832,7 +832,7 @@ // 鍒犻櫎璧勬簮 const removeTaskItem = (item: any) => { const data = { - ids: [item.id] + ids: [item.id], } MG.edu .delTask(data) @@ -840,7 +840,7 @@ if (res) { ElMessage({ message: '鍒犻櫎鎴愬姛', - type: 'success' + type: 'success', }) getTaskList() } @@ -848,7 +848,7 @@ .catch((e: any) => { ElMessage({ message: '鍒犻櫎澶辫触', - type: 'error' + type: 'error', }) }) } @@ -860,9 +860,9 @@ requests: checkData.value?.map((item: any) => { return { path: String(taskData.rootCmsItemId), - cmsItemId: item.id + cmsItemId: item.id, } - }) + }), } MG.edu .addTaskCmsItemList(data) @@ -870,7 +870,7 @@ if (res) { ElMessage({ message: '宸插姞鍏�', - type: 'success' + type: 'success', }) selectCache.value = [] checkData.value = [] @@ -883,7 +883,7 @@ .catch((e: any) => { ElMessage({ message: '鍔犲叆澶辫触', - type: 'error' + type: 'error', }) }) } @@ -898,7 +898,7 @@ taskId: taskData?.id, // taskData?.id path: String(taskData?.rootCmsItemId), //taskData?.rootCmsItemId type: '*', - keys: questionKey + keys: questionKey, } MG.edu .getTaskCmsItem(data) @@ -914,18 +914,22 @@ if (questionKey != null) { for (let fieldKey of questionKey) { if (item.datas[fieldKey]) { - const values = JSON.parse(item.datas[fieldKey]) - if (values.length > 0) { - // 鐢ㄥ瓧娈靛悕澶勭悊杩斿洖鐨勫瓧娈靛�� - if (values[0].Value) { - item[fieldKey] = values[0].Value - } else if (values[0].Data) { - item[fieldKey] = values[0].Data.Value - } else if (!values[0].Value && values[0].FileList?.length > 0) { - item[fieldKey] = values[0].FileList - } else { - item[fieldKey] = '-' + try { + const values = JSON.parse(item.datas[fieldKey]) + if (values.length > 0) { + // 鐢ㄥ瓧娈靛悕澶勭悊杩斿洖鐨勫瓧娈靛�� + if (values[0].Value) { + item[fieldKey] = values[0].Value + } else if (values[0].Data) { + item[fieldKey] = values[0].Data.Value + } else if (!values[0].Value && values[0].FileList?.length > 0) { + item[fieldKey] = values[0].FileList + } else { + item[fieldKey] = '-' + } } + } catch (error) { + console.log(error, item.datas[fieldKey], item) } } } @@ -949,7 +953,7 @@ .catch((e: any) => { ElMessage({ message: '鍒楄〃鑾峰彇澶辫触', - type: 'error' + type: 'error', }) console.log(e) }) @@ -960,16 +964,16 @@ ElMessageBox.confirm('鏄惁纭鍒犻櫎?', '鎻愮ず', { confirmButtonText: '鏄�', cancelButtonText: '鍚�', - type: 'warning' + type: 'warning', }).then(() => { const data = { taskId: taskData.id, requests: [ { cmsItemId: item.id, - path: String(taskData.rootCmsItemId) - } - ] + path: String(taskData.rootCmsItemId), + }, + ], } MG.edu .removeTaskCmsItemList(data) @@ -977,7 +981,7 @@ if (res) { ElMessage({ type: 'success', - message: '宸插垹闄�' + message: '宸插垹闄�', }) selectedIndex.value = 0 getTaskCmsList() @@ -986,7 +990,7 @@ .catch((err: any) => { ElMessage({ type: 'error', - message: '鍒犻櫎澶辫触锛岃绋嶅悗鍐嶈瘯' + message: '鍒犻櫎澶辫触锛岃绋嶅悗鍐嶈瘯', }) }) }) @@ -1191,7 +1195,7 @@ content, type: 'Normal', cmsTypeRefCode: '', - newDataListRequest: [] + newDataListRequest: [], } MG.ugc .newTopicMessage(data) @@ -1199,7 +1203,7 @@ if (res) { ElMessage({ type: 'success', - message: '宸插彂甯�' + message: '宸插彂甯�', }) } }) @@ -1235,8 +1239,8 @@ router.push({ path: '/jobDetail', query: { - classInfo: JSON.stringify(obj) - } + classInfo: JSON.stringify(obj), + }, }) } @@ -1261,8 +1265,7 @@ path: defaultCmsPath.value, queryType: '*', productId: String(classInfo?.bookId), - storeInfo: defaultCmsPath.value, - cmsPath: classInfo?.rootCmsItemId + cmsPath: classInfo?.rootCmsItemId, } MG.store .getProductDetail(query) @@ -1276,8 +1279,7 @@ path: defaultCmsPath.value, queryType: '*', productId: String(classInfo?.bookId), - storeInfo: defaultCmsPath.value, - cmsPath: obj.productLinkPath + cmsPath: obj.productLinkPath, } MG.store .getProductDetail(query) @@ -1311,7 +1313,6 @@ path: defaultCmsPath.value, queryType: '*', productId: String(classInfo?.bookId), - storeInfo: defaultCmsPath.value, cmsPath: item.productLinkPath, itemFields: { Embedded_QuestionBank_AnalysisCon: [], @@ -1323,8 +1324,8 @@ Embedded_QuestionBank_QuestionType: [], Embedded_QuestionBank_Score: [], Embedded_QuestionBank_Stem: [], - Embedded_QuestionBank_StemStyle: [] - } + Embedded_QuestionBank_StemStyle: [], + }, }) if (item.type == 'questionBankFolder' && item.childrenFolderCount == 0) { return data.datas.cmsDatas @@ -1347,7 +1348,6 @@ path: defaultCmsPath.value, queryType: '*', productId: String(classInfo?.bookId), - storeInfo: defaultCmsPath.value, cmsPath, itemFields: { Embedded_QuestionBank_AnalysisCon: [], @@ -1359,8 +1359,8 @@ Embedded_QuestionBank_QuestionType: [], Embedded_QuestionBank_Score: [], Embedded_QuestionBank_Stem: [], - Embedded_QuestionBank_StemStyle: [] - } + Embedded_QuestionBank_StemStyle: [], + }, } MG.store .getProductDetail(query) @@ -1384,8 +1384,7 @@ path: defaultCmsPath.value, queryType: '*', productId: String(classInfo?.bookId), - storeInfo: defaultCmsPath.value, - cmsPath: item.productLinkPath + cmsPath: item.productLinkPath, } MG.store .getProductDetail(query) @@ -1489,7 +1488,7 @@ { name: '璁鸿堪棰�', totalScore: 0, value: 'discuss', data: [] }, { name: '濉┖棰�', totalScore: 0, value: 'completion', data: [] }, { name: '杩炵嚎棰�', totalScore: 0, value: 'matching', data: [] }, - { name: '鍒嗙被棰�', totalScore: 0, value: 'classification', data: [] } + { name: '鍒嗙被棰�', totalScore: 0, value: 'classification', data: [] }, ] try { let list = [] @@ -1517,7 +1516,7 @@ questionType: item.Embedded_QuestionBank_QuestionType, questionAnalysisCon: item.Embedded_QuestionBank_AnalysisCon, questionAnswer: item.Embedded_QuestionBank_Answer, - customAnswer: null + customAnswer: null, } } catch (error) { console.log(item) @@ -1594,13 +1593,13 @@ color: #333; line-height: 30px; text-align: left; - border-left: 6px solid #ff6c00; + border-left: 6px solid #019e58; padding-left: 10px; } } margin-top: 20px; ::v-deep .el-tabs__nav-wrap::after { - background-color: #ff6d00; + background-color: #019e58; height: 1px; } @@ -1611,7 +1610,7 @@ } ::v-deep .is-active { - background-color: #ff6d00; + background-color: #019e58; color: #fff; border-radius: 3px 3px 0 0; } @@ -1748,6 +1747,7 @@ background: #e0f2ff; overflow: auto; padding: 10px 18px; + box-sizing: border-box; .searchBox { position: sticky; top: -10px; @@ -1877,7 +1877,7 @@ .leftBg { background-color: rgba(255, 173, 65, 0.1); border-radius: 5px 5px 5px 5px; - color: #ff6c00 !important; + color: #019e58 !important; } .pageBox { padding: 10px 0; @@ -1889,6 +1889,9 @@ justify-content: center; align-items: center; padding: 20px 0; + span { + min-width: 80px; + } } } } -- Gitblit v1.9.1