瀏覽代碼

调整 头像

于添 6 月之前
父節點
當前提交
21cc220da6

+ 0 - 2
src/App.vue

@@ -2,7 +2,6 @@
 	<a-config-provider :locale="locale" >
 		<router-view v-if="$route.meta.fullpage" />
 		<div v-else>
-			<a-layout  >
 				<Header/>
 				<div style="width: 100vw; overflow-y: scroll;height: 100%">
 					<div style="width: 71%; margin-left: 10%;">
@@ -13,7 +12,6 @@
 				</div>
 
 <!--				<Footer/>-->
-			</a-layout>
 
 		</div>
 	</a-config-provider>

+ 9 - 4
src/router/portal.js

@@ -76,22 +76,27 @@ const portal = [
 	},
 	{
 		name: 'questionnaireManagement',
-		path: '/portal/questionnaireManagement',
+		path: '/questionnaireManagement',
 		component: () => import('@/views/exm/questionnaireManagement/index.vue'),
 	},
 	{
 		name: 'examinationManagement',
-		path: '/portal/examinationManagement',
+		path: '/examinationManagement',
 		component: () => import('@/views/exm/examinationManagement/index.vue'),
 	},
 	{
 		name: 'exampaper',
-		path: '/portal/exampaper',
+		path: '/exampaper',
 		component: () => import('@/views/exm/exampaper/index.vue'),
 	},
+	{
+		name: 'question',
+		path: '/question',
+		component: () => import('@/views/exm/question/index.vue'),
+	},
 	{
 		name: 'answerManagement',
-		path: '/portal/answerManagement',
+		path: '/answerManagement',
 		component: () => import('@/views/answerManagement/index.vue'),
 	},
 	{

+ 4 - 0
src/router/whiteList.js

@@ -154,6 +154,10 @@ const constRouters = [
 		path: '/examinationManagement',
 		component: () => import('@/views/exm/examinationManagement/index.vue')
 	},
+	{
+		path: '/question',
+		component: () => import('@/views/exm/question/index.vue')
+	},
 	{
 		path: '/exampaper',
 		component: () => import('@/views/exm/exampaper/index.vue')

+ 2 - 2
src/style/index.less

@@ -15,7 +15,7 @@
 .body, html {
 	width: 100%;
 	height: 100%;
-	background-color: #f6f8f9;
+	//background-color: #f6f8f9;
 }
 
 a, button, input, textarea {
@@ -34,7 +34,7 @@ a, button, input, textarea {
 
 /* 大布局样式 */
 .admin-ui {
-	overflow: hidden;
+	//overflow: hidden;
 	height: 100%;
 	display: flex;
 	flex-flow: column;

+ 1 - 1
src/views/courseAdd/components/courseInfo.vue

@@ -275,7 +275,7 @@
 			formState.collegeId = res.data.collegeId
 			// formState.collegeTwoId = res.data.collegeTwoId
 			// majorIdName.value = res.data.collegeAllId?.split(',')
-			getCollegeMajor(formState.collegeTwoId)
+			// getCollegeMajor(formState.collegeTwoId)
 			formState.courseType = res.data.courseType
 			formState.courseDesc = res.data.courseDesc
 			toRaw(quillEditorRef.value).setHTML(formState.courseDesc)

+ 73 - 49
src/views/courseAdd/components/courseProduction/index.vue

@@ -32,12 +32,13 @@
 			<!-- 课时列表 -->
 			<div v-for="(lesson, lessonIndex) in chapter.classHours" :key="lessonIndex" class="lesson">
 				<!-- 视频封面 -->
-				<img  src="@/assets/images/fileImg/gif.png" alt="Video Cover" class="video-cover" style="width: 140px; height: 90px"/>
+				<img src="@/assets/images/fileImg/gif.png" alt="Video Cover" class="video-cover"
+					 style="width: 140px; height: 90px"/>
 				<!-- 课时信息 -->
 				<div style="display: flex; flex-direction: column; justify-content: space-between; height: 100%  ">
 					<div>{{ lesson.name }}</div>
 					<div>
-<!--						<span>视频大小:{{ lesson.size }}MB</span>-->
+						<!--						<span>视频大小:{{ lesson.size }}MB</span>-->
 						<span>发布时间:{{ lesson.createTime }}</span>
 						<span>发布人:{{ lesson.createUserName }}</span>
 					</div>
@@ -52,15 +53,18 @@
 		</div>
 		<!-- 添加章节模态框 -->
 		<a-modal v-model:visible="modalVisible" :title="dialogTitle" @ok="handleOk" @cancel="handleCancel">
-			<a-form :model="formState">
-				<a-form-item label="章节名称">
+			<a-form :model="formState" ref="formRef" :rules="rules" :label-col="{ span: 7 }"
+					:wrapper-col="{ span: 12 }">
+				<a-form-item label="章节名称" name="chapterName">
 					<a-input v-model:value="formState.chapterName" placeholder="请输入章节名称"/>
 				</a-form-item>
-				<a-form-item label="章节名称">
-					<a-select v-model:value="formState.knowledgeIds"  placeholder="请选择状态" style="width: 120px; margin-right: 12px">
+				<a-form-item label="知识点" name="knowledgeIds">
+					<a-select   mode="multiple" v-model:value="formState.knowledgeIds" placeholder="请选择知识点"
+							  style="width: 220px; ">
 						<a-select-option v-for="(item, index) in knowledgeOptions" :key="index" :value="item.value">{{
 								item.label
-							}}</a-select-option>
+							}}
+						</a-select-option>
 					</a-select>
 				</a-form-item>
 			</a-form>
@@ -75,13 +79,14 @@ import {ref, reactive, onMounted} from 'vue'
 import addDialog from './addDialog.vue'
 import courseProductionApi from '@/api/courseCenter/courseProduction.js'
 import {useRoute, useRouter} from 'vue-router'
-import { del ,  edit as editApi } from '@/api/hour/index'
+import {del, edit as editApi} from '@/api/hour/index'
 import tool from "@/utils/tool";
 
 
 const router = useRouter()
 const route = useRoute()
 const popoverVisible = ref({})
+const formRef = ref(null)
 const modeTag = ref('add')
 const dialogTitle = ref('添加章节')
 const knowledgeOptions = tool.dictList('knowledge')
@@ -103,9 +108,9 @@ const handleEdit = (item) => {
 	addDialogRef.value.edit(item)
 }
 const handleDel = (item) => {
-	console.log('删除',item)
+	console.log('删除', item)
 
-	del([{id : item.id}]).then(()=>{
+	del([{id: item.id}]).then(() => {
 		getList()
 	})
 }
@@ -117,9 +122,13 @@ const addDialogRef = ref(null)
 // 表单状态
 const formState = reactive({
 	id: '',
-	chapterName: '',
-	knowledgeIds : []
+	chapterName: undefined,
+	knowledgeIds: []
 })
+const rules = {
+	chapterName: [{required: true, message: '请输入章节名称', trigger: 'blur'}],
+	knowledgeIds: [{required: true, message: '请选择知识点', trigger: 'blur'}],
+}
 const pagination = reactive({
 	pageSize: 10,
 	pageNum: 1,
@@ -131,48 +140,58 @@ const showModal = () => {
 	dialogTitle.value = '添加章节'
 	modeTag.value = 'add'
 	modalVisible.value = true
+
+
 	formState.chapterName = ''
 	formState.knowledgeIds = []
 }
 
 // 确认按钮点击事件
 const handleOk = () => {
-	let courseInfoId = props.courseInfoId
-	if (formState.chapterName && modeTag.value == 'add') {
-
-		courseProductionApi
-			.add({
-				courseId: courseInfoId,
-				name: formState.chapterName
-			})
-			.then((res) => {
-				console.log(res, '章节添加')
-				getList()
-			})
-			.catch((err) => {
-				console.log(err)
-			})
-		formState.chapterName = '' // 清空表单
-		modalVisible.value = false // 关闭模态框
-	}
-	if (formState.chapterName && modeTag.value == 'edit') {
-
-		courseProductionApi
-			.edit({
-				id: formState.id,
-				courseId: courseInfoId,
-				name: formState.chapterName
-			})
-			.then((res) => {
-				console.log(res, '章节添加')
-				getList()
-			})
-			.catch((err) => {
-				console.log(err)
-			})
-		formState.chapterName = '' // 清空表单
-		modalVisible.value = false // 关闭模态框
-	}
+	formRef.value.validate().then(() => {
+
+
+		let courseInfoId = props.courseInfoId
+		if (formState.chapterName && modeTag.value == 'add') {
+
+			courseProductionApi
+				.add({
+					courseId: courseInfoId,
+					name: formState.chapterName,
+					knowledgeIds : formState.knowledgeIds
+				})
+				.then((res) => {
+					console.log(res, '章节添加')
+					getList()
+				})
+				.catch((err) => {
+					console.log(err)
+				})
+			formState.chapterName = '' // 清空表单
+			modalVisible.value = false // 关闭模态框
+		}
+		if (formState.chapterName && modeTag.value == 'edit') {
+
+			courseProductionApi
+				.edit({
+					id: formState.id,
+					courseId: courseInfoId,
+					name: formState.chapterName,
+					knowledgeIds : formState.knowledgeIds
+				})
+				.then((res) => {
+					console.log(res, '章节添加')
+					getList()
+				})
+				.catch((err) => {
+					console.log(err)
+				})
+			formState.chapterName = '' // 清空表单
+			modalVisible.value = false // 关闭模态框
+		}
+	})
+
+
 }
 
 // 取消按钮点击事件
@@ -187,8 +206,13 @@ const editChapter = (chapterIndex) => {
 	modalVisible.value = true
 	dialogTitle.value = '修改章节'
 	modeTag.value = 'edit'
+
+	formRef.value.resetFields()
+
+
 	formState.id = item.id
 	formState.chapterName = item.name
+	formState.knowledgeIds = item.knowledeges
 
 }
 
@@ -247,7 +271,7 @@ const onAddChapter = () => {
 }
 onMounted(() => {
 	console.log('有没有id呢', props.courseInfoId)
-	console.log('有没有字典',knowledgeOptions)
+	console.log('有没有字典', knowledgeOptions)
 	getList()
 
 

+ 2 - 0
src/views/myResources/coverUpload/index.vue

@@ -92,6 +92,7 @@
 
 		if (!isFileTypeAllowed) {
 			message.error(`不支持的文件格式: ${fileExtension},请上传以下格式: ${allowedExtensions.join(', ')}`)
+			coverFileList.value = []
 			return false
 		}
 
@@ -99,6 +100,7 @@
 		const isLt500K = file.size / 1024 < 500
 		if (!isLt500K) {
 			message.error('文件大小不能超过500KB!')
+			coverFileList.value = []
 			return false
 		}
 

+ 31 - 31
src/views/myResources/personalResources/index.vue

@@ -1,5 +1,5 @@
 <template>
-	<div style="overflow-y: auto; display: flex;height: 100vh">
+	<div>
 		<!-- 主要内容区域 -->
 				<div style="width: 100%;  display: flex">
 					<div class="sidebar-menu" style="width: 15%">
@@ -50,12 +50,12 @@
 	const openKeys = ref(['resources'])
 
 	const menuItems = ref([
-		{
-			key: 'home',
-			icon: HomeOutlined,
-			label: '我的主页',
-			title: '我的主页'
-		},
+		// {
+		// 	key: 'home',
+		// 	icon: HomeOutlined,
+		// 	label: '我的主页',
+		// 	title: '我的主页'
+		// },
 		{
 			key: 'resources',
 			icon: FolderOutlined,
@@ -74,30 +74,30 @@
 			label: '我的课程专辑',
 			title: '我的课程专辑'
 		},
-		{
-			key: 'questionBank',
-			icon: QuestionCircleOutlined,
-			label: '我的题库',
-			title: '我的题库'
-		},
-		{
-			key: 'classroom',
-			icon: BankOutlined,
-			label: '我的教室',
-			title: '我的教室'
-		},
-		{
-			key: 'courses',
-			label: '我的课程',
-			icon: SolutionOutlined,
-			title: '我的课程'
-		},
-		{
-			key: 'tasks',
-			label: '我的任务',
-			icon: ScheduleOutlined,
-			title: '我的任务'
-		}
+		// {
+		// 	key: 'questionBank',
+		// 	icon: QuestionCircleOutlined,
+		// 	label: '我的题库',
+		// 	title: '我的题库'
+		// },
+		// {
+		// 	key: 'classroom',
+		// 	icon: BankOutlined,
+		// 	label: '我的教室',
+		// 	title: '我的教室'
+		// },
+		// {
+		// 	key: 'courses',
+		// 	label: '我的课程',
+		// 	icon: SolutionOutlined,
+		// 	title: '我的课程'
+		// },
+		// {
+		// 	key: 'tasks',
+		// 	label: '我的任务',
+		// 	icon: ScheduleOutlined,
+		// 	title: '我的任务'
+		// }
 	])
 
 	const handleClick = (e) => {

+ 2 - 0
src/views/portal/components/Header.vue

@@ -46,10 +46,12 @@
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="portal/courseManagement">课程管理</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="answerManagement">问答管理</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="classManagement">班级管理</a-menu-item>
+					
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="examinationManagement">考试管理</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="questionnaireManagement">问卷管理</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="exampaper">试题管理</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="student/record/">考试记录</a-menu-item>
+					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="question">题目列表</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="statistics">统计分析</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="usercenter">个人中心</a-menu-item>
 					<a-menu-item style="margin-left: 1px; margin-right: 1px" key="forum">论坛</a-menu-item>

+ 1 - 1
src/views/resourceCenter/index.vue

@@ -1,5 +1,5 @@
 <template>
-	<div style="height: 100vh">
+	<div>
 		<ComplexChoices/>
 		<div style="height: 20px"></div>
 		<a-row :gutter="16">

+ 61 - 14
src/views/resourceDetails/components/TallList.vue

@@ -20,6 +20,8 @@
 							"
 						></div>
 						<span style="display: block; font-size: 10px">未登录</span>
+
+
 					</div>
 
 					<div style="width: 100%; height: 100%; display: flex; position: relative">
@@ -47,21 +49,33 @@
 			</div>
 			<div>
 				<div style="display: flex">
-					<div style="display: flex; flex-direction: column; margin-left: 10px; margin-right: 10px">
-						<div
-							style="
-								width: 30px;
-								height: 30px;
-								background: #1e90ff;
-								border-radius: 50%;
-								margin-top: 15px;
-								margin-right: 15px;
-							"
-						></div>
-						<span style="display: block; font-size: 10px">未登录</span>
-					</div>
+					<div class="account-center-avatarHolder" style="margin-top: 5px">
+						<div class="avatar">
+							<a-spin size="small" :spinning="false">
+								<img :src="userInfo.avatar" />
+							</a-spin>
+							<!--						<a @click="uploadLogo">-->
+							<!--							<div :class="userInfo.avatar ? 'mask' : 'mask-notImg'"><upload-outlined /></div>-->
+							<!--						</a>-->
+						</div>
+						<div >{{ userInfo.name }}</div>
 
-					<div style="width: 100%; height: 100%; display: flex; position: relative">
+					</div>
+<!--					<div style="display: flex; flex-direction: column; margin-left: 10px; margin-right: 10px">-->
+<!--						<div-->
+<!--							style="-->
+<!--								width: 30px;-->
+<!--								height: 30px;-->
+<!--								background: #1e90ff;-->
+<!--								border-radius: 50%;-->
+<!--								margin-top: 15px;-->
+<!--								margin-right: 15px;-->
+<!--							"-->
+<!--						></div>-->
+<!--						<span style="display: block; font-size: 10px">未登录</span>-->
+<!--					</div>-->
+
+					<div style="width: 100%; height: 100%; display: flex; position: relative;  margin-left: 10px">
 						<a-textarea placeholder="" :rows="4" v-model:value="talk" style="margin-top: 5px" />
 					</div>
 				</div>
@@ -102,6 +116,7 @@
 	import { ref } from 'vue'
 	import TabSwitcher from './TabSwitcher.vue'
 	import TallItem from './TallItem.vue'
+	import { globalStore } from '@/store'
 	import EqualItem from './EqualItem.vue'
 	import {
 		addViewCount,
@@ -116,6 +131,7 @@
 	} from '@/api/portal'
 	import { useRoute } from 'vue-router'
 	import EventBus from '@/utils/EventBus'
+	import {message} from "ant-design-vue";
 	const currentPage = reactive({
 		funcType: 2,
 		current: 1,
@@ -137,6 +153,11 @@
 	const equalList = ref([])
 	const talkList = ref([])
 
+	const global_store = globalStore()
+
+	const userInfo = computed(() => {
+		return global_store.userInfo
+	})
 	// callBackTalk: [
 	// 			{
 	// 				id: 2,
@@ -195,8 +216,14 @@
 		} else {
 			getHotPageComment()
 		}
+
 	}
 	const handerPublish = () => {
+
+		if(talk.value.length == 0){
+			message.error('发表评论不能为空')
+			return
+		}
 		addComment({ resourceId: id, commentName: talk.value })
 			.then((res) => {
 				getPageComment()
@@ -281,6 +308,7 @@
 </script>
 
 <style scoped>
+
 	.tab-switcher {
 		display: flex;
 		border-radius: 20px;
@@ -474,4 +502,23 @@
 		background-color: #1e90ff;
 		margin-right: 5px;
 	}
+
+	.account-center-avatarHolder {
+		text-align: center;
+		margin-bottom: 14px;
+
+		& > .avatar {
+			margin: 0 auto;
+			width: 35px;
+			height: 35px;
+			margin-bottom: 1px;
+			border-radius: 50%;
+			overflow: hidden;
+
+			img {
+				height: 100%;
+				width: 100%;
+			}
+		}
+	}
 </style>

+ 1 - 4
src/views/statisticalAnalysis/analysisLearningBehaviors/index.vue

@@ -1,5 +1,5 @@
 <template>
-	<div class="learning-behavior-analysis" style="height: 100vh; overflow-y: auto">
+	<div class="learning-behavior-analysis">
 		<!-- 页面头部 -->
 		<div class="header">
 			<h1>📊 学习行为分析</h1>
@@ -170,9 +170,6 @@
 				</div>
 			</div>
 		</div>
-		<div style="height: 100px">
-
-		</div>
 	</div>
 </template>
 

+ 1 - 4
src/views/statisticalAnalysis/analysisTeachingActivities/index.vue

@@ -1,5 +1,5 @@
 <template>
-	<div class="teaching-activity-analysis" style="height: 100vh; overflow-y: auto">
+	<div class="teaching-activity-analysis">
 		<!-- 页面头部 -->
 		<div class="header">
 			<h1>📚 教学活动分析</h1>
@@ -108,9 +108,6 @@
 			<h3>📚 文档观看详细统计</h3>
 			<a-table :columns="documentColumns" :data-source="documentData" :pagination="{ pageSize: 10 }" row-key="id" />
 		</div>
-		<div style="height: 100px">
-
-		</div>
 	</div>
 </template>
 

+ 1 - 4
src/views/statisticalAnalysis/overviewLearningProgress/index.vue

@@ -1,5 +1,5 @@
 <template>
-	<div class="p-6 flex justify-center min-h-screen" style="overflow-y: auto;  height: 100vh;">
+	<div class="p-6 flex justify-center min-h-screen">
 		<div class="w-full mx-auto">
 			<!-- 顶部筛选区 -->
 			<div class="bg-white rounded-lg shadow-sm p-6 mb-6 h-25 flex items-center">
@@ -118,9 +118,6 @@
 					</template>
 				</a-table>
 			</div>
-			<div style="height: 100px">
-
-			</div>
 		</div>
 	</div>
 </template>

+ 1 - 4
src/views/statisticalAnalysis/videoAnalysis/index.vue

@@ -1,5 +1,5 @@
 <template>
-	<div class="video-analysis-container" style="height: 100vh; overflow-y: auto">
+	<div class="video-analysis-container">
 		<!-- 页面头部 -->
 		<div class="header">
 			<h1>📊 视频分析</h1>
@@ -148,9 +148,6 @@
 				</template>
 			</a-table>
 		</div>
-		<div style="height: 100px">
-
-		</div>
 	</div>
 </template>
 

+ 3 - 0
src/views/sys/user/userCenter.vue

@@ -14,6 +14,7 @@
 					</div>
 					<div class="username">{{ userInfo.name }}</div>
 					<div class="bio">{{ userInfo.nickname }}</div>
+
 				</div>
 				<div class="account-center-detail">
 <!--					<p><i class="title"></i>{{ userInfo.positionName }}</p>-->
@@ -67,6 +68,7 @@
 	import { useRoute } from 'vue-router'
 	import tool from '@/utils/tool'
 	import { globalStore } from '@/store'
+
 	import userCenterApi from '@/api/sys/userCenterApi'
 	import accountBasic from './userTab/accountBasic.vue'
 	import CropUpload from '@/components/CropUpload/index.vue'
@@ -110,6 +112,7 @@
 	]
 	const noTitleKey = ref('accountBasic')
 	const onTabChange = (key) => {
+		console.log('key是什么呢', key)
 		noTitleKey.value = key
 	}
 	const Route = useRoute()

+ 4 - 4
src/views/userfileconvert/components/ListView.vue

@@ -64,25 +64,25 @@ const columns = [
 	{
 		title: '资源名称',
 		dataIndex: 'fileName',
-		sorter: true,
+		// sorter: true,
 		width: '15%'
 	},
 	{
 		title: '文件后缀',
 		dataIndex: 'extendName',
-		sorter: true,
+		// sorter: true,
 		width: '15%'
 	},
 	{
 		title: '发布时间',
 		dataIndex: 'createTime',
-		sorter: true,
+		// sorter: true,
 		width: '12%'
 	},
 	{
 		title: '操作',
 		dataIndex: 'action',
-		sorter: true,
+		// sorter: true,
 		width: '2%'
 	}
 ]

File diff suppressed because it is too large
+ 0 - 0
stats.html


+ 1 - 0
vite.config.js

@@ -44,6 +44,7 @@ export default defineConfig(({ command, mode }) => {
 				'/api': {
 					target: 'http://192.168.1.245:9003',
 					// target: 'http://192.168.31.15:9003',
+					// target: 'http://192.168.31.15:9003',
 					ws: false,
 					changeOrigin: true
 					// rewrite: (path) => path.replace(/^\/api/, '')

Some files were not shown because too many files changed in this diff