wangguoyu 2 semanas atrás
pai
commit
139dfee391
43 arquivos alterados com 136 adições e 2728 exclusões
  1. 52 127
      pages.json
  2. 0 118
      pages/baoming/index.vue
  3. 0 211
      pages/course/common/catalogue.vue
  4. 0 39
      pages/course/index.vue
  5. 0 238
      pages/course/kechengInfo.vue
  6. 0 708
      pages/cuoti/cuoti.vue
  7. 0 30
      pages/cuoti/index.vue
  8. 0 66
      pages/demo/index.vue
  9. 21 11
      pages/index/index.vue
  10. 0 40
      pages/lianxi/index.vue
  11. 0 74
      pages/my/components/birthdayDialog.vue
  12. 0 81
      pages/my/components/genderDialog.vue
  13. 0 103
      pages/my/components/passwordDialog.vue
  14. 0 78
      pages/my/components/realNameDialog.vue
  15. 0 78
      pages/my/components/telDialog.vue
  16. 0 29
      pages/my/credit.vue
  17. 0 41
      pages/my/mesList.vue
  18. 0 38
      pages/my/mesPage.vue
  19. 0 237
      pages/my/setting.vue
  20. 0 34
      pages/my/zhengshu.vue
  21. BIN
      static/images/index/index-banner.png
  22. BIN
      static/images/index/index-gg-img.png
  23. BIN
      static/images/index/index-kc-default.jpg
  24. BIN
      static/images/index/index-kc-img.png
  25. BIN
      static/images/index/index-ks-default.png
  26. BIN
      static/images/index/index-ks-img.png
  27. BIN
      static/images/index/index-lx-img.png
  28. BIN
      static/images/index/indexks-ks-img.png
  29. BIN
      static/images/my/my-baoming-icon-sj.png
  30. BIN
      static/images/my/my-certificate-icon-sj.png
  31. BIN
      static/images/my/my-ceshi-icon-sj.png
  32. BIN
      static/images/my/my-credits-icon-sj.png
  33. BIN
      static/images/my/my-explain-icon-sj.png
  34. BIN
      static/images/my/my-learnMap-icon-sj.png
  35. BIN
      static/images/my/my-news-icon-sj.png
  36. BIN
      static/images/my/my-office-icon-sj.png
  37. BIN
      static/images/my/my-setting-icon-sj.png
  38. BIN
      static/images/my/my-wrong-icon-sj.png
  39. 0 0
      subpkgExam/pages/exam/exam.vue
  40. 0 0
      subpkgExam/pages/exam/examTools.js
  41. 63 96
      subpkgScore/pages/score/kaoshiChengjiInfo.vue
  42. 0 178
      utils/request copy 1.js
  43. 0 73
      utils/request copy.js

+ 52 - 127
pages.json

@@ -1,6 +1,5 @@
 {
-	"pages": [ //pages数组中第一项表示应用启动页,参考:https://uniapp.dcloud.io/collocation/pages
-		{
+	"pages": [{
 			"path": "pages/login",
 			"style": {
 				"navigationBarTitleText": ""
@@ -13,166 +12,92 @@
 			}
 		},
 		{
-			"path" : "pages/exam/index",
+			"path": "pages/exam/index",
 			"style": {
 				"navigationStyle": "custom"
 			}
 		},
 		{
-			"path" : "pages/my/index",
-			"style" :
-			{
-				"navigationBarTitleText" : "我的"
-			}
-		},
-		{
-			"path" : "pages/my/mesList",
-			"style" :
-			{
-				"navigationBarTitleText" : "消息"
-			}
-		},
-		{
-			"path" : "pages/my/zhengshu",
-			"style" :
-			{
-				"navigationBarTitleText" : "证书"
-			}
-		},
-		{
-			"path" : "pages/my/setting",
-			"style" :
-			{
-				"navigationBarTitleText" : "设置"
-			}
-		},
-		{
-			"path" : "pages/demo/index",
-			"style" :
-			{
-				"navigationBarTitleText" : "demo"
-			}
-		},
-		{
-			"path" : "pages/course/index",
-			"style" :
-			{
-				"navigationBarTitleText" : "课程"
-			}
-		},
-			{
-			"path" : "pages/course/kechengInfo",
-			"style" :
-			{
-				"navigationBarTitleText" : "课程详情"
-			}
-		},
-		{
-			"path" : "pages/score/index",
-			"style" :
-			{
-				"navigationStyle" : "custom"
-			}
-		},
-		{
-			"path" : "pages/score/kaoshiChengjiInfo",
-			"style" :
-			{
-					"navigationStyle" : "custom"
-			}
-		},
-		{
-			"path" : "pages/exam/exam",
+			"path": "pages/score/index",
 			"style": {
 				"navigationStyle": "custom"
 			}
 		},
 		{
-			"path" : "pages/lianxi/index",
-			"style" : 
-			{
-				"navigationBarTitleText" : "练习"
-			}
-		},
-		{
-			"path" : "pages/lianxi/lianxi",
-			"style" : 
-			{
-				"navigationBarTitleText" : ""
-			}
-		},
-		{
-			"path" : "pages/baoming/index",
-			"style" : 
-			{
-				"navigationBarTitleText" : "报名"
-			}
-		},
-		{
-			"path" : "pages/cuoti/index",
-			"style" : 
-			{
-				"navigationBarTitleText" : "错题"
-			}
-		},
-		{
-			"path" : "pages/cuoti/cuoti",
-			"style" : 
-			{
-				"navigationBarTitleText" : "错题答案"
-			}
-		},
-		{
-			"path" : "pages/my/mesPage",
-			"style" : 
-			{
-				"navigationBarTitleText" : "消息详情"
+			"path": "pages/my/index",
+			"style": {
+				"navigationBarTitleText": "我的"
 			}
+		}
+	],
+	"subPackages": [{
+			"root": "subpkgExam",
+			"name": "exam",
+			"pages": [{
+				"path": "pages/exam/exam",
+				"style": {
+					"navigationStyle": "custom"
+				}
+			}]
 		},
 		{
-			"path" : "pages/my/credit",
-			"style" : 
-			{
-				"navigationBarTitleText" : "学分"
-			}
+			"root": "subpkgScore",
+			"name": "score",
+			"pages": [{
+				"path": "pages/score/kaoshiChengjiInfo",
+				"style": {
+					"navigationStyle": "custom"
+				}
+			}]
 		}
 	],
 	"tabBar": {
-			"color": "#565656",
-			"selectedColor": "#0856E6",
-			"borderStyle": "black",
-			"backgroundColor": "#ffffff",
-			"fontSize": "13px",
-			"iconWidth": "28px",
-			"spacing": "0px",
-			"list": [{
+		"color": "#565656",
+		"selectedColor": "#0856E6",
+		"borderStyle": "black",
+		"backgroundColor": "#ffffff",
+		"fontSize": "13px",
+		"iconWidth": "28px",
+		"spacing": "0px",
+		"list": [{
 				"pagePath": "pages/index/index",
 				"iconPath": "static/images/tabbar/unselect/index-sj.png",
 				"selectedIconPath": "static/images/tabbar/select/index-sj.png",
 				"text": "首页"
-			}, {
+			},
+			{
 				"pagePath": "pages/exam/index",
 				"iconPath": "static/images/tabbar/unselect/exam-sj.png",
 				"selectedIconPath": "static/images/tabbar/select/exam-sj.png",
 				"text": "考试"
-			}, 
+			},
 			{
 				"pagePath": "pages/score/index",
 				"iconPath": "static/images/tabbar/unselect/score-sj.png",
 				"selectedIconPath": "static/images/tabbar/select/score-sj.png",
 				"text": "成绩"
-			}, {
+			},
+			{
 				"pagePath": "pages/my/index",
 				"iconPath": "static/images/tabbar/unselect/my-sj.png",
 				"selectedIconPath": "static/images/tabbar/select/my-sj.png",
 				"text": "我的"
-			}]
-		},
+			}
+		]
+	},
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
 		"navigationBarTitleText": "麦塔软件",
-		"navigationBarBackgroundColor": "#fff"
+		"navigationBarBackgroundColor": "#fff",
+		"lazyCodeLoading": "requiredComponents"
+	},
+	"easycom": {
+		"autoscan": true,
+		"custom": {
+			"^uni-(.*)": "@dcloudio/uni-ui/lib/uni-$1/uni-$1.vue",
+			// 只保留确实在主包使用的组件规则
+			"^common-(.*)": "@/components/common-$1.vue"
+		}
 	},
-
 	"uniIdRouter": {}
-}
+}

+ 0 - 118
pages/baoming/index.vue

@@ -1,118 +0,0 @@
-<template>
-	<custom-scroll-list :refreshFn="getBaomingList" :tabList="tabData" :defaultTab="0" ref="scrollRef"
-		placeholder="请输入报名考试名称">
-		<template #default="{list}">
-			<scroll-list-card-baoming v-for="(item,index) in list" :key="item.lxId" :data="item"
-				@btnClick="handleClick"></scroll-list-card-baoming>
-		</template>
-	</custom-scroll-list>
-	<!-- 考试须知 -->
-	<kaoshixuzhi ref="ksxzRef" @confirm="handleConfirm"></kaoshixuzhi>
-</template>
-
-<script setup>
-	import scrollListCardBaoming from "@/components/score-list-card-baoming/score-list-card-baoming.vue"
-	import kaoshixuzhi from "@/components/kaoshixuzhi/kaoshixuzhi.vue"
-	import {
-		getBaomingList,
-	} from "@/api/baoming.js";
-	import {
-		ref
-	} from "vue";
-
-
-	const tabData = [{
-			label: "审核中",
-			value: 0,
-		},
-		{
-			label: "已通过",
-			value: 1,
-		}, {
-			label: "未通过",
-			value: 2,
-		}, {
-			label: "未报名",
-			value: 3,
-		}, {
-			label: "已结束",
-			value: 4,
-		}
-	]
-
-
-	function goKaoshiPage(data) {
-		uni.navigateTo({
-			url: `/pages/exam/exam?ksId=${data.ksId}&zhuapai=${data.zhuapai}`
-		})
-	}
-	
-	function handleConfirm() {
-		goKaoshiPage(activeKs.value)
-	}
-
-	function showKaoshiXuzhi() {
-		const option = {
-			ksId: activeKs.value.ksId
-		}
-		getClientKaoshiInfo(option).then(res => {
-			examNoticeInfo.value = res.data;
-			// 校验抓拍
-			doCheckZhuapai()
-		})
-
-	}
-
-	function doCheckZhuapai() {
-		if (examNoticeInfo.value.zhuapai) {
-			// 存在抓拍
-		} else {
-			// 不存在抓拍
-			ksxzRef.value.showDialog(examNoticeInfo.value)
-		}
-	}
-
-	function handleClick(data) {
-		activeKs.value = data;
-		if (data.status == 0) {
-			// 未开始
-			showKaoshiXuzhi()
-		}
-		if (data.status == 1) {
-			// 可以考试
-			showKaoshiXuzhi()
-		}
-		if (data.status == 2) {
-			// 再次考试
-			showKaoshiXuzhi()
-		}
-		if (data.status == 3) {
-			// 考试中
-			showKaoshiXuzhi()
-		}
-		if (data.status == 4) {
-			// 已结束
-			uni.showToast({
-				title: '考试已结束',
-				icon: 'none'
-			})
-		}
-		if (data.status == 5) {
-			// 未报名
-			kaoShiApply({
-				ksId: data.ksId
-			}).then(res => {
-				uni.showToast({
-					title: '报名成功',
-					icon: 'none'
-				})
-				scrollRef.value.onRefresh()
-			})
-		}
-
-	}
-</script>
-
-<style lang="scss">
-
-</style>

+ 0 - 211
pages/course/common/catalogue.vue

@@ -1,211 +0,0 @@
-<template>
-	<view>
-		<uni-collapse class="chapter-collapse" accordion>
-			<uni-collapse-item v-for="(zhangItem, zhangIndex) in props.options.zhangList" :key="zhangIndex"
-				:title="zhangItem.name" :open="isCurrentZhang(zhangIndex)">
-				<uni-collapse class="chapter-collapse" accordion>
-					<uni-collapse-item v-for="(jieItem, jieIndex) in zhangItem.jieList" :key="'jie-'+jieIndex"
-						:title="jieItem.name" :open="isCurrentJie(zhangIndex,jieIndex)">
-						<view class="section-header">{{ jieItem.name }}</view>
-						<view v-for="(video, vidIndex) in jieItem.kejianList" :key="'vid-'+video.kjId"
-							class="video-item" @click="handleVideoClick(zhangIndex, jieIndex, vidIndex,video)">
-							<view class="video-info">
-								<text class="video-name"
-									:class="{ active: isCurrentVideo(zhangIndex, jieIndex, vidIndex) }">
-									{{ video.name }}
-								</text>
-								<view class="progress-container">
-									<progress :percent="calcProgress(video)" stroke-width="4"
-										:activeColor="video.curProcess >= 100 ? '#4cd964' : '#007aff'" />
-								</view>
-							</view>
-						</view>
-					</uni-collapse-item>
-				</uni-collapse>
-			</uni-collapse-item>
-		</uni-collapse>
-	</view>
-</template>
-
-<script setup>
-	import {
-		getKechengList,
-		kejianInfo
-	} from "@/api/course.js";
-	import {
-		onLoad,
-		onReady
-	} from "@dcloudio/uni-app"
-
-	import {
-		ref,
-		reactive,
-		defineProps,
-		defineEmits,
-		onMounted,
-		watchEffect,
-		defineExpose
-	} from 'vue';
-	const props = defineProps({
-		options: {
-			type: Object,
-			default: () => {}
-		},
-		currentVideo: {
-			type: Object,
-			default: () => {}
-		},
-
-	})
-	let currentPos = ref({
-		zhangIndex: -1,
-		jieIndex: -1,
-		vidIndex: -1
-	});
-	const Emits = defineEmits(['kejianInfo', 'playNext']);
-	// 初始化时定位第一个未完成视频
-	onMounted(() => {
-		loadProgressFromCache();
-		findFirstUnfinished();
-	});
-	// 加载缓存进度
-	const loadProgressFromCache = () => {
-		props.options.zhangList.forEach(zhang => {
-			zhang.jieList.forEach(jie => {
-				jie.kejianList.forEach(video => {
-					const cached = uni.getStorageSync(`video_${video.kjId}`);
-					if (cached) {
-						video.curProcess = (cached / uni.getStorageSync(
-							`duration_${video.kjId}`)) * 100 || 0;
-						video.maxProcess = Math.max(video.maxProcess, video.curProcess);
-					}
-				});
-			});
-		});
-	};
-	// 查找第一个未完成视频
-	const findFirstUnfinished = () => {
-		for (let z = 0; z < props.options.zhangList.length; z++) {
-			const zhang = props.options.zhangList[z];
-			for (let j = 0; j < zhang.jieList.length; j++) {
-				const jie = zhang.jieList[j];
-				for (let v = 0; v < jie.kejianList.length; v++) {
-					const video = jie.kejianList[v];
-					if (video.curProcess < 100) {
-						updateCurrentPosition(z, j, v, video);
-						return;
-					}
-				}
-			}
-		}
-	};
-	// 判断是否当前章
-	const isCurrentZhang = (zhangIndex) => {
-		return currentPos.value.zhangIndex === zhangIndex;
-	};
-
-	// 判断是否当前节(需要同时匹配章和节)
-	const isCurrentJie = (zhangIndex, jieIndex) => {
-		return currentPos.value.zhangIndex === zhangIndex &&
-			currentPos.value.jieIndex === jieIndex;
-	};
-
-	// 判断是否当前视频
-	const isCurrentVideo = (z, j, v) => {
-		return currentPos.value.zhangIndex === z &&
-			currentPos.value.jieIndex === j &&
-			currentPos.value.vidIndex === v;
-	};
-
-	// 计算进度
-	const calcProgress = (video) => {
-		return Math.min(video.curProcess, 100);
-	};
-
-	// 点击视频处理
-	const handleVideoClick = (z, j, v, video) => {
-		console.log('video', video);
-		// currentPos.value = {
-		// 	zhangIndex: z,
-		// 	jieIndex: j,
-		// 	vidIndex: v
-		// };
-		updateCurrentPosition(z, j, v, video);
-		kejianInfo({
-			kjId: video.kjId
-		}).then(res => {
-			console.log('res', res);
-			Emits('kejianInfo', {
-				...res.data,
-				kjId: video.kjId
-			})
-		})
-		// 这里添加实际播放逻辑
-	};
-	// 更新播放位置
-	const updateCurrentPosition = (z, j, v, video) => {
-		currentPos.value = {
-			zhangIndex: z,
-			jieIndex: j,
-			vidIndex: v
-		};
-		video.curProcess = uni.getStorageSync(`video_${video.kjId}`) /
-			uni.getStorageSync(`duration_${video.kjId}`) * 100 || 0;
-	};
-	// 播放下一个视频
-	let playNextVideo = () => {
-		let {
-			zhangIndex,
-			jieIndex,
-			vidIndex
-		} = currentPos.value;
-		const chapters = props.options.zhangList;
-
-		// 1. 同节的下一个视频
-		const currentSection = chapters[zhangIndex].jieList[jieIndex];
-		if (vidIndex < currentSection.kejianList.length - 1) {
-			vidIndex++;
-			return playVideoAt(zhangIndex, jieIndex, vidIndex);
-		}
-
-		// 2. 同章的下一节
-		const currentChapter = chapters[zhangIndex];
-		if (jieIndex < currentChapter.jieList.length - 1) {
-			for (let j = jieIndex + 1; j < currentChapter.jieList.length; j++) {
-				if (currentChapter.jieList[j].kejianList.length > 0) {
-					return playVideoAt(zhangIndex, j, 0);
-				}
-			}
-		}
-
-		// 3. 后续章节
-		for (let z = zhangIndex + 1; z < chapters.length; z++) {
-			for (let j = 0; j < chapters[z].jieList.length; j++) {
-				if (chapters[z].jieList[j].kejianList.length > 0) {
-					return playVideoAt(z, j, 0);
-				}
-			}
-		}
-
-		uni.showToast({
-			title: '已播放所有课程',
-			icon: 'none'
-		});
-	};
-	// 辅助方法
-	const playVideoAt = (z, j, v) => {
-		const video = props.options.zhangList[z].jieList[j].kejianList[v];
-		updateCurrentPosition(z, j, v, video);
-		Emits('kejianInfo', {
-			...video,
-			kjId: video.kjId
-		});
-	};
-	defineExpose({
-	  playNextVideo
-	});
-</script>
-
-<style lang="scss">
-
-</style>

+ 0 - 39
pages/course/index.vue

@@ -1,39 +0,0 @@
-<template>
-	<custom-scroll-list :refreshFn="getKechengList" :tabList="tabData" :defaultTab="1">
-		<template #default="{list}">
-			<scroll-list-card-kecheng @click="kechengClick(item)" v-for="(item,index) in list" :key="item.ksId"
-				:data="item"></scroll-list-card-kecheng>
-		</template>
-	</custom-scroll-list>
-</template>
-
-<script setup>
-	import {
-		getKechengList
-	} from "@/api/course.js";
-	import {
-		onLoad,
-		onReady,
-
-	} from "@dcloudio/uni-app"
-	import {
-		reactive,
-		ref
-	} from "vue";
-	const tabData = [{
-		label: "可以学习",
-		value: 1,
-	}, {
-		label: "已结束",
-		value: 4
-	}]
-	const kechengClick = (data) => {
-		uni.navigateTo({
-			url: '/pages/course/kechengInfo?kcId=' + data.kcId + '&name=' + data.name
-		});
-	}
-</script>
-
-<style lang="scss">
-
-</style>

+ 0 - 238
pages/course/kechengInfo.vue

@@ -1,238 +0,0 @@
-<template>
-	<view class="course-container">
-		<!-- 视频播放器 -->
-		<video v-if="currentVideo.url" :src="currentVideo.url" :id="videoId" controls @ended="handleVideoEnd"
-			@timeupdate="handleTimeUpdate" @loadedmetadata="handleVideoLoaded">
-		</video>
-
-		<!-- 课程信息 -->
-		<view class="course-header">
-			<text class="course-title">测试课程1</text>
-			<view class="course-meta">
-				<text>讲师:张老师</text>
-				<text>时长:3分42秒</text>
-				<text>1人学习</text>
-			</view>
-		</view>
-		<!-- 选项卡 -->
-		<view class="course-tabs">
-			<text :class="['tab-item', activeTab === '目录' ? 'active' : '']" @click="activeTab = '目录'">目录</text>
-			<text :class="['tab-item', activeTab === '介绍' ? 'active' : '']" @click="activeTab = '介绍'">介绍</text>
-			<text :class="['tab-item', activeTab === '评论' ? 'active' : '']" @click="activeTab = '评论'">评论</text>
-			<text :class="['tab-item', activeTab === '考试' ? 'active' : '']" @click="activeTab = '考试'">考试</text>
-		</view>
-		<!-- 目录内容 -->
-		<view v-if="activeTab == '目录'" class="course-content">
-			<catalogue ref="catalogueRef" @kejianInfo='getKejianInfo' :options="kejianUserVo"
-				:current-video="currentVideo"></catalogue>
-		</view>
-		<view v-if="activeTab == '介绍'" class="course-content">
-			<view v-if="!kechengData.intro" class="s-kehceng-default">
-				<view>
-					<img :src="jieshaoImg">
-					<text>还没有介绍</text>
-				</view>
-			</view>
-			<view v-else v-html="kechengData.intro" class="kecheng-tab-jieshao"></view>
-		</view>
-			<view v-if="activeTab == '评论'" class="course-content">
-			<view v-if="!kechengData.intro" class="s-kehceng-default">
-				<view>
-					<text>还没有介绍</text>
-				</view>
-			</view>
-			<view v-else v-html="kechengData.intro" class="kecheng-tab-jieshao"></view>
-		</view>
-
-	</view>
-</template>
-
-<script setup>
-	import {
-		ref,
-		onMounted
-	} from 'vue';
-	import {
-		onLoad,
-		onReady,
-
-	} from "@dcloudio/uni-app"
-	import {
-		kechengStart
-	} from "@/api/course.js";
-	import catalogue from './common/catalogue.vue';
-	// 选项卡状态
-	const activeTab = ref('');
-	let kcId = ref('');
-	let kejianUserVo = ref(null);
-	let kechengData = ref(null);
-	// 当前播放信息
-	const currentVideo = ref({
-		url: '',
-		kjId: ''
-	});
-	const currentChapter = ref(0);
-	const currentSection = ref(0);
-	const catalogueRef = ref(null);
-	const videoId = ref('courseVideo');
-	let videoContext = null;
-	onLoad((options) => {
-		console.log('options', options);
-		kcId.value = options.kcId
-
-	});
-	onMounted(() => {
-		getKechengData()
-	});
-
-	function getKechengData() {
-		kechengStart({
-			kcId: kcId.value
-		}).then(res => {
-			console.log('res', res);
-			activeTab.value = '目录'
-			kejianUserVo.value = res.data.kejianUserVo
-			kechengData.value = res.data
-		})
-	}
-
-	function getKejianInfo(data) {
-		console.log('data', data.url);
-
-		currentVideo.value = {
-			url: data.url,
-			kjId: data.kjId
-		};
-		setTimeout(() => {
-			if (!videoContext) {
-				videoContext = uni.createVideoContext(videoId.value, this);
-			}
-			const cachedTime = uni.getStorageSync(`video_${data.kjId}`) || 0;
-			videoContext.seek(cachedTime);
-		}, 300);
-	}
-
-
-	const handleTimeUpdate = (e) => {
-		const currentTime = e.detail.currentTime;
-		uni.setStorageSync(`video_${currentVideo.value.kjId}`, currentTime);
-	};
-
-	const handleVideoEnd = () => {
-		catalogueRef.value.playNextVideo();
-	};
-	const handleVideoLoaded = (e) => {
-		uni.setStorageSync(`duration_${currentVideo.value.kjId}`, e.detail.duration);
-	};
-</script>
-
-<style scoped>
-	.course-container {
-		display: flex;
-		flex-direction: column;
-		height: 100vh;
-	}
-
-	.course-header {
-		padding: 20rpx;
-		background: #f5f5f5;
-	}
-
-	.course-title {
-		font-size: 36rpx;
-		font-weight: bold;
-	}
-
-	.course-meta {
-		margin-top: 10rpx;
-		font-size: 24rpx;
-		color: #666;
-	}
-
-	.course-tabs {
-		display: flex;
-		justify-content: space-around;
-		padding: 20rpx;
-		background: #fff;
-		border-bottom: 1rpx solid #ddd;
-	}
-
-	.tab-item {
-		font-size: 28rpx;
-		color: #666;
-	}
-
-	.tab-item.active {
-		color: #09BB07;
-		font-weight: bold;
-	}
-
-	.course-content {
-		flex: 1;
-		overflow-y: auto;
-		padding: 20rpx;
-	}
-
-	.chapter-list {
-		background: #fff;
-	}
-
-	.chapter-item {
-		margin-bottom: 20rpx;
-	}
-
-	.chapter-title {
-		padding: 20rpx;
-		background: #f5f5f5;
-		display: flex;
-		justify-content: space-between;
-		border-bottom: 1rpx solid #ddd;
-	}
-
-	.section-list {
-		background: #fff;
-	}
-
-	.section-item {
-		padding: 20rpx;
-		display: flex;
-		justify-content: space-between;
-		border-bottom: 1rpx solid #eee;
-	}
-
-	.section-info {
-		flex: 1;
-	}
-
-	.section-title {
-		display: block;
-		font-size: 28rpx;
-		color: #333;
-	}
-
-	.play-status {
-		width: 180rpx;
-		text-align: right;
-	}
-
-	.playing {
-		color: #09BB07;
-		font-size: 24rpx;
-	}
-
-	.progress {
-		color: #666;
-		font-size: 24rpx;
-	}
-
-	.unplayed {
-		color: #999;
-		font-size: 24rpx;
-	}
-
-	video {
-		width: 100%;
-		height: 300rpx;
-		background: #000;
-	}
-</style>

+ 0 - 708
pages/cuoti/cuoti.vue

@@ -1,708 +0,0 @@
-<template>
-	<view class="phone-score-page">
-		<!-- 段落 -->
-		<view class="score-shiti-content">
-			<!-- 试题区域 -->
-			<view v-if="activeSt">
-				<template v-if="activeSt.stTypeId == 1">
-					<!-- 单选 -->
-					<danxuan :question="activeSt" :key="activeSt.stId"></danxuan>
-				</template>
-				<template v-if="activeSt.stTypeId == 2">
-					<!-- 多选 -->
-					<duoxuan :question="activeSt" :key="activeSt.stId"></duoxuan>
-				</template>
-				<template v-if="activeSt.stTypeId == 3">
-					<!-- 判断 -->
-					<panduan :question="activeSt" :key="activeSt.stId"></panduan>
-				</template>
-				<template v-if="activeSt.stTypeId == 4">
-					<!-- 填空 -->
-					<tiankong :question="activeSt" :key="activeSt.stId"></tiankong>
-				</template>
-				<template v-if="activeSt.stTypeId == 5">
-					<!-- 简答 -->
-					<jianda :question="activeSt" :key="activeSt.stId"></jianda>
-				</template>
-				<template v-if="activeSt.stTypeId == 6">
-					<!-- 阅读 -->
-					<yuedu :question="activeSt" :key="activeSt.stId" @yudu-change="onYueduChange"></yuedu>
-				</template>
-			</view>
-			<!-- 底部 -->
-			<view class="kaoshi-bottom-box">
-				<view class="shiti-num-box" @click="showAnswerCard">
-					<icon class="shiti-num-icon"></icon>答题卡
-					<text
-						class="active-num">{{activeSt ? activeSt.onlyNum: 0}}</text>/<text>{{data.StListForSearch.length}}</text>
-				</view>
-			</view>
-
-			<!-- 解析 -->
-			<view v-if="activeSt" class="score-answer-box">
-				<view class="phone-question-answer-box" v-if="activeSt.stTypeId == 6">
-					<template v-if="yuduItemAnswer.stTypeId == 5">
-						<!-- 阅读题中简答题 -->
-						<view class="phone-line-title">答案解析</view>
-						<view class="btdf-row">本题得分:<text>{{yuduItemAnswer.score}}</text>分</view>
-						<view class="zqda-row">正确答案:
-							<view>{{yuduItemAnswer.result}}</view>
-						</view>
-						<view class="ndda-row">您的答案:
-							<view>{{yuduItemAnswer.reply}}</view>
-						</view>
-						<view class="dajx-row">答案解析:
-							<rich-text :nodes="yuduItemAnswer.answer"></rich-text>
-						</view>
-					</template>
-					<template v-else-if="yuduItemAnswer.stTypeId == 4">
-						<view class="phone-line-title">答案解析</view>
-						<view class="btdf-row">本题得分:<text>{{yuduItemAnswer.score}}</text>分</view>
-						<view class="zqda-row">正确答案:
-							<view v-for="(item,index) in yuduItemAnswer.result">{{`填空${index+1}`}} : {{item}}</view>
-						</view>
-						<view class="ndda-row">您的答案:
-							<view v-for="(item,index) in yuduItemAnswer.reply"> {{`填空${index+1}`}}: {{item}}</view>
-						</view>
-						<view class="dajx-row">答案解析:
-							<rich-text :nodes="yuduItemAnswer.answer"></rich-text>
-						</view>
-					</template>
-					<template v-else>
-						<view class="phone-line-title">答案解析</view>
-						<view class="btdf-row">本题得分:<text>{{yuduItemAnswer.score}}</text>分</view>
-						<view class="zqda-row">正确答案:<text>{{yuduItemAnswer.result}}</text></view>
-						<view class="ndda-row">您的答案:<text>{{yuduItemAnswer.reply}}</text></view>
-						<view class="dajx-row">答案解析:
-							<rich-text :nodes="yuduItemAnswer.answer"></rich-text>
-						</view>
-					</template>
-				</view>
-				<view class="phone-question-answer-box" v-else-if="activeSt.stTypeId == 5">
-					<view class="phone-line-title">答案解析</view>
-					<view class="btdf-row">本题得分:<text>{{data.score}}</text>分</view>
-					<view class="zqda-row">正确答案:
-						<view>{{data.result}}</view>
-					</view>
-					<view class="ndda-row">您的答案:
-						<view>{{data.reply}}</view>
-					</view>
-					<view class="dajx-row">答案解析:
-						<rich-text :nodes="data.answer"></rich-text>
-					</view>
-				</view>
-				<view class="phone-question-answer-box" v-else-if="activeSt.stTypeId == 4">
-					<view class="phone-line-title">答案解析</view>
-					<view class="btdf-row">本题得分:<text>{{answerRes.score}}</text>分</view>
-					<view class="zqda-row">正确答案:
-						<view v-for="(item,index) in answerRes.result">{{`填空${index+1}`}} : {{item}}</view>
-					</view>
-					<view class="ndda-row">您的答案:
-						<view v-for="(item,index) in answerRes.reply"> {{`填空${index+1}`}}: {{item}}</view>
-					</view>
-					<view class="dajx-row">答案解析:
-						<rich-text :nodes="answerRes.answer"></rich-text>
-					</view>
-				</view>
-				<view class="phone-question-answer-box" v-else>
-					<view class="phone-line-title">答案解析</view>
-					<view class="btdf-row">本题得分:<text>{{answerRes.score}}</text>分</view>
-					<view class="zqda-row">正确答案:<text>{{answerRes.result}}</text></view>
-					<view class="ndda-row">您的答案:<text>{{answerRes.reply}}</text></view>
-					<view class="dajx-row">答案解析:
-						<rich-text :nodes="answerRes.answer"></rich-text>
-					</view>
-				</view>
-			</view>
-		</view>
-		<!-- 上下按钮 -->
-		<view v-if="activeSt" class="score-bottom-box">
-			<view @click="handleOpenCard" class="score-num-box">
-				<icon class="score-num-icon"></icon>
-				<text
-					class="active-num">{{activeSt && activeSt.onlyNum||0}}</text>/<text>{{data.StListForSearch.length}}</text>
-			</view>
-			<view>
-				<button type="default" size="mini" hover-class="none" class="phone-green-btn score-answer-btn"
-					@click="handlePrev" v-if="!isFistStId">上一题</button>
-				<button type="default" size="mini" hover-class="none" class="phone-green-btn score-answer-btn"
-					@click="handleNext" v-if="!isLastStId">下一题</button>
-				<!-- 		<button type="default" size="mini" hover-class="none" class="phone-green-btn score-answer-btn"
-					@click="handleBack" v-if="isLastStId">完成</button> -->
-			</view>
-		</view>
-		<!-- 答题卡 -->
-		<uni-popup ref="popupRef" background-color="#fff" :animation="false" :is-mask-click="false" :mask-click="false">
-			<view class="answer-card-popup">
-				<view class="icon-title-navBar-box">
-					<view @click="handlePopupBack" class="nav-bar-icon"> </view>
-					<text class="nav-bar-title">答题卡</text>
-				</view>
-				<view class="card-content-box">
-					<view class="answer-card-content" v-for="(paragraph,paragraphIndex) in questionData"
-						:key="paragraphIndex">
-						<view class="paragraph-title">
-							{{paragraph.name}}
-						</view>
-						<view class="paragraph-qa" v-for="(qa,qaIndex) in paragraph.qas" :key="qaIndex"
-							:class="getQaClass(qa)" @click="answerCardItemClick(qa)">{{qa.onlyNum}}
-						</view>
-					</view>
-				</view>
-			</view>
-		</uni-popup>
-
-	</view>
-</template>
-
-<script setup>
-	import danxuan from "@/components/questions/danxuan.vue";
-	import duoxuan from "@/components/questions/duoxuan.vue";
-	import tiankong from "@/components/questions/tiankong.vue";
-	import panduan from "@/components/questions/panduan.vue";
-	import jianda from "@/components/questions/jianda.vue";
-	import yuedu from "@/components/questions/yuedu.vue";
-	import {
-		useQuestionTools
-	} from "@/components/questions/useQuestionTools.js";
-
-	import {
-		onLoad
-	} from "@dcloudio/uni-app";
-	import {
-		ref,
-		reactive,
-		computed
-	} from "vue"
-	import * as ctApi from "@/api/cuoti.js"
-	const {
-		checkDanxuanReply,
-		checkDuoxuanReply,
-		checkPanduanReply,
-		checkTiankongReply,
-		getLetterByIndex,
-		checkJiandaReply,
-		checkYueduReply
-	} = useQuestionTools();
-
-
-	const hisId = ref(null)
-	const popupRef = ref(null)
-	const yuduItemAnswer = ref(null); // 阅读小题显示答案
-	const yuduIndexQa = ref(null); // 阅读小题答案
-
-	const data = reactive({
-		ksId: null,
-		ksName: '',
-		stTotal: 0,
-		zyLevelName: '',
-		userScore: '',
-		ksScore: 0,
-		StListForSearch: [],
-		duanluo: []
-	})
-
-	const questionData = ref([]);
-	const progress = reactive({
-		dlIndex: 0,
-		dtIndex: 0
-	})
-
-	const dlName = computed(() => {
-		if (data.StListForSearch && activeSt.value) {
-			return data.StListForSearch[activeSt.value.onlyNum].paragraphName
-		} else {
-			return ''
-		}
-	})
-
-	const activeSt = computed(() => {
-		if (questionData.value.length) {
-			return questionData.value.length && questionData.value[progress.dlIndex].qas[progress.dtIndex];
-		} else {
-			return null
-		}
-	})
-
-	const answerRes = computed(() => {
-		const qa = activeSt.value;
-		let score = qa.score;
-		let reply = '';
-		let result = '';
-		let answer = qa.answer;
-		if (qa.stTypeId == 1) {
-			// 单选题
-			if (qa.reply && qa.reply.trim() !== '') {
-				reply = getLetterByIndex(qa.reply)
-			} else {
-				reply = '未答'
-			}
-
-			if (qa.result) {
-				result = getLetterByIndex(qa.result)
-			} else {
-				result = '无答案'
-			}
-		}
-		if (qa.stTypeId == 2) {
-			// 多选题
-
-			if (qa.reply && qa.reply.length) {
-				reply = qa.reply.map(item => {
-					if (item.trim()) {
-						return getLetterByIndex(item.trim())
-					}
-				}).join(',')
-			} else {
-				reply = '未答'
-			}
-			if (qa.result) {
-				result = qa.result.map(item => {
-					if (item.trim()) {
-						return getLetterByIndex(item.trim())
-					}
-				}).join(',')
-			} else {
-				result = '无答案'
-			}
-		}
-		if (qa.stTypeId == 3) {
-			// 判断题
-			if (qa.reply === '') {
-				reply = '未答'
-			} else if (qa.reply == 0) {
-				reply = '错误'
-			} else if (qa.reply == 1) {
-				reply = '正确'
-			}
-			if (qa.result == 0) {
-				result = '错误'
-			} else if (qa.result == 1) {
-				result = '正确'
-			}
-		}
-		if (qa.stTypeId == 4) {
-			let reply = qa.reply || [];
-			let result = qa.result || [];
-			// 填空题
-			return {
-				score,
-				reply,
-				result,
-				answer
-			}
-		} else if (qa.stTypeId == 5) {
-			let reply = qa.reply;
-			let result = qa.result;
-			// 简答题
-			return {
-				score,
-				reply,
-				result,
-				answer
-			}
-		} else {
-			return {
-				score,
-				reply,
-				result,
-				answer
-			}
-		}
-	})
-
-	function showAnswerCard() {
-		popupRef.value.open('top')
-	}
-
-	function onYueduChange(data) {
-		yuduIndexQa.value = data;
-		checkYueduJiexi()
-	}
-
-	// 校验阅读解析
-	function checkYueduJiexi() {
-		console.log('格式化阅读题', yuduIndexQa.value)
-		let qa = yuduIndexQa.value;
-		let score = qa.userScore;
-		let reply = '';
-		let result = '';
-		let answer = qa.answer;
-		if (qa.stTypeId == 1) {
-			// 单选题
-			if (qa.reply && qa.reply.trim() !== '') {
-				reply = getLetterByIndex(qa.reply)
-			} else {
-				reply = '未答'
-			}
-
-			if (qa.result) {
-				result = getLetterByIndex(qa.result)
-			} else {
-				result = '无答案'
-			}
-			yuduItemAnswer.value = {
-				score,
-				reply,
-				result,
-				answer
-			}
-		}
-		if (qa.stTypeId == 2) {
-			// 多选题
-
-			if (qa.reply && qa.reply.length) {
-				reply = qa.reply.map(item => {
-					if (item.trim()) {
-						return getLetterByIndex(item.trim())
-					}
-				}).join(',')
-			} else {
-				reply = '未答'
-			}
-			if (qa.result) {
-				result = qa.result.map(item => {
-					if (item.trim()) {
-						return getLetterByIndex(item.trim())
-					}
-				}).join(',')
-			} else {
-				result = '无答案'
-			}
-			yuduItemAnswer.value = {
-				score,
-				reply,
-				result,
-				answer
-			}
-		}
-		if (qa.stTypeId == 3) {
-			// 判断题
-			if (qa.reply === '') {
-				reply = '未答'
-			} else if (qa.reply == 0) {
-				reply = '错误'
-			} else if (qa.reply == 1) {
-				reply = '正确'
-			}
-			if (qa.result == 0) {
-				result = '错误'
-			} else if (qa.result == 1) {
-				result = '正确'
-			}
-			yuduItemAnswer.value = {
-				score,
-				reply,
-				result,
-				answer
-			}
-		}
-		if (qa.stTypeId == 4) {
-			let reply = qa.reply || [];
-			let result = qa.result || [];
-			// 填空题
-			yuduItemAnswer.value = {
-				score,
-				reply,
-				result,
-				answer
-			}
-		}
-		if (qa.stTypeId == 5) {
-			// 简单题
-			let reply = qa.reply ? '未答' : qa.reply;
-			let result = qa.result;
-			yuduItemAnswer.value = {
-				score,
-				reply,
-				result,
-				answer
-			}
-		}
-
-	}
-
-	const isFistStId = computed(() => {
-		if (data.StListForSearch.length) {
-			return data.StListForSearch[0].stId == activeSt.value.stId
-		} else {
-			return false
-		}
-	});
-	const isLastStId = computed(() => {
-		if (data.StListForSearch.length) {
-			return data.StListForSearch[data.StListForSearch.length - 1].stId == activeSt.value.stId
-		} else {
-			return false
-		}
-	});
-
-
-	onLoad((options) => {
-		hisId.value = options.hisId;
-		initPage()
-	})
-
-
-	function getQaClass(qa) {
-		if (qa.marked && qa.marked === true) {
-			return 'paragraph-qa-block-mark';
-		} else {
-			if (qa.stTypeId == 1) {
-				if (checkDanxuanReply(qa)) {
-					return 'paragraph-qa-block-done';
-				} else {
-					return 'paragraph-qa-block-init';
-				}
-			} else if (qa.stTypeId == 2) {
-				if (checkDuoxuanReply(qa)) {
-					return 'paragraph-qa-block-done';
-				} else {
-					return 'paragraph-qa-block-init';
-				}
-			} else if (qa.stTypeId == 3) {
-				if (checkPanduanReply(qa)) {
-					return 'paragraph-qa-block-done';
-				} else {
-					return 'paragraph-qa-block-init';
-				}
-			} else if (qa.stTypeId == 4) {
-				if (checkTiankongReply(qa)) {
-					return 'paragraph-qa-block-done';
-				} else {
-					return 'paragraph-qa-block-init';
-				}
-			} else if (qa.stTypeId == 5) {
-				if (checkJiandaReply(qa)) {
-					return 'paragraph-qa-block-done';
-				} else {
-					return 'paragraph-qa-block-init';
-				}
-			} else if (qa.stTypeId == 6) {
-				if (checkYueduReply(qa)) {
-					return 'paragraph-qa-block-done';
-				} else {
-					return 'paragraph-qa-block-init';
-				}
-			}
-		}
-	}
-
-	function skipQuestion(dlIndex, dtIndex) {
-		progress.dlIndex = dlIndex;
-		progress.dtIndex = dtIndex;
-		handlePopupBack()
-	}
-
-	function answerCardItemClick(qa) {
-		const actQa = data.StListForSearch.find(item => item.stId == qa.stId);
-		skipQuestion(actQa.dlIndex, actQa.dtIndex)
-	}
-
-
-	function handleBack() {
-		uni.redirectTo({
-			url: "/pages/admin/Chengji/list"
-		})
-	}
-
-
-	function formatDuanluoList() {
-		let uIndex = 0; // 试题num
-		let iDuanluo = 0; // 段落num
-		let result = [];
-		for (const duanluo of data.duanluo) {
-			let paragraph = {
-				qas: [],
-			};
-			paragraph.name = duanluo.name;
-
-			let iQa = 0; // 当前试题序号
-			let order = 0; // 当前题型中第几题
-			for (const iDanxuan of duanluo.danxuan) {
-				iDanxuan.type = 'danxuan';
-				iDanxuan.marked = false;
-				iDanxuan.onlyNum = uIndex + 1;
-				iDanxuan.order = order;
-				iDanxuan.iQa = iQa;
-				paragraph.qas.push(iDanxuan);
-				uIndex++;
-				order++;
-				iQa++;
-
-				data.StListForSearch.push({
-					stId: iDanxuan.stId,
-					paragraphName: paragraph.name,
-					dlIndex: iDuanluo,
-					dtIndex: iDanxuan.iQa,
-					num: iDanxuan.onlyNum
-				})
-			}
-			order = 0;
-			for (const iDuoxuan of duanluo.duoxuan) {
-				iDuoxuan.type = 'duoxuan';
-				iDuoxuan.marked = false;
-				iDuoxuan.onlyNum = uIndex + 1;
-				iDuoxuan.order = order;
-				paragraph.qas.push(iDuoxuan);
-				iDuoxuan.iQa = iQa;
-				uIndex++;
-				order++;
-				iQa++;
-
-				data.StListForSearch.push({
-					stId: iDuoxuan.stId,
-					paragraphName: paragraph.name,
-					dlIndex: iDuanluo,
-					dtIndex: iDuoxuan.iQa,
-					num: iDuoxuan.onlyNum
-				})
-			}
-			order = 0;
-			for (const iPanduan of duanluo.panduan) {
-				iPanduan.type = 'panduan';
-				iPanduan.marked = false;
-				iPanduan.onlyNum = uIndex + 1;
-				iPanduan.order = order;
-				paragraph.qas.push(iPanduan);
-				iPanduan.iQa = iQa;
-				uIndex++;
-				order++;
-				iQa++;
-
-				data.StListForSearch.push({
-					stId: iPanduan.stId,
-					paragraphName: paragraph.name,
-					dlIndex: iDuanluo,
-					dtIndex: iPanduan.iQa,
-					num: iPanduan.onlyNum
-				})
-			}
-			order = 0;
-			for (const iTiankong of duanluo.tiankong) {
-				iTiankong.type = 'tiankong';
-				iTiankong.marked = false;
-				iTiankong.onlyNum = uIndex + 1;
-				iTiankong.order = order;
-				paragraph.qas.push(iTiankong);
-				iTiankong.iQa = iQa;
-				uIndex++;
-				order++;
-				iQa++;
-
-				data.StListForSearch.push({
-					stId: iTiankong.stId,
-					paragraphName: paragraph.name,
-					dlIndex: iDuanluo,
-					dtIndex: iTiankong.iQa,
-					num: iTiankong.onlyNum
-				})
-			}
-			order = 0;
-			for (const iJianda of duanluo.jianda) {
-				iJianda.type = 'jianda';
-				iJianda.onlyNum = uIndex + 1;
-				iJianda.order = order;
-				iJianda.iQa = iQa;
-				paragraph.qas.push(iJianda);
-				iJianda.reply = '';
-				uIndex++;
-				order++;
-				iQa++;
-
-				data.StListForSearch.push({
-					stId: iJianda.stId,
-					paragraphName: paragraph.name,
-					dlIndex: iDuanluo,
-					dtIndex: iJianda.iQa,
-					num: iJianda.onlyNum
-				})
-			}
-			order = 0;
-			for (const iYuedu of duanluo.yuedu) {
-				iYuedu.type = 'yuedu';
-				iYuedu.onlyNum = uIndex + 1;
-				iYuedu.order = order;
-				iYuedu.iQa = iQa;
-
-				if (iYuedu.duoxuan && iYuedu.duoxuan.length) {
-					iYuedu.duoxuan.map((qIt) => {
-						qIt.reply = qIt.reply || [];
-						return qIt
-					})
-				}
-
-				if (iYuedu.tiankong && iYuedu.tiankong.length) {
-					iYuedu.tiankong.map((qIt) => {
-						qIt.reply = new Array(qIt.count).fill('');
-						return qIt;
-					});
-				}
-
-				paragraph.qas.push(iYuedu);
-				iYuedu.reply = [];
-				uIndex++;
-				order++;
-				iQa++;
-
-				data.StListForSearch.push({
-					stId: iYuedu.stId,
-					paragraphName: paragraph.name,
-					dlIndex: iDuanluo,
-					dtIndex: iYuedu.iQa,
-					num: iYuedu.onlyNum
-				})
-			}
-			iDuanluo++;
-			questionData.value.push(paragraph)
-
-		}
-	}
-
-	function handlePrev() {
-		const qa = data.StListForSearch.find(item => item.stId == activeSt.value.stId);
-		const index = qa.num - 1;
-		if (index > 0) {
-			const result = data.StListForSearch[index - 1];
-			progress.dlIndex = result.dlIndex;
-			progress.dtIndex = result.dtIndex
-		}
-
-	}
-
-	function handleNext() {
-		const qa = data.StListForSearch.find(item => item.stId == activeSt.value.stId);
-		const index = qa.num - 1;
-		if (index < data.StListForSearch.length) {
-			const result = data.StListForSearch[index + 1];
-			progress.dlIndex = result.dlIndex;
-			progress.dtIndex = result.dtIndex
-		}
-	}
-
-
-
-	function initPage() {
-		uni.setNavigationBarTitle({
-			title: '错题'
-		});
-		ctApi.getCuotiInfo({
-			hisId: hisId.value
-		}).then(res => {
-			data.duanluo = [res.data];
-			formatDuanluoList();
-		})
-	}
-
-	function handlePopupBack() {
-		popupRef.value.close()
-	}
-
-	function handleOpenCard() {
-		popupRef.value.open('top')
-	}
-</script>
-
-<style>
-
-</style>

+ 0 - 30
pages/cuoti/index.vue

@@ -1,30 +0,0 @@
-<template>
-	<custom-scroll-list-date-vue :refreshFn="getCuotiList" :defaultTab="1" ref="scrollRef" placeholder="请输入考试名称">
-		<template #default="{list}">
-			<scroll-list-card-cuoti v-for="(item,index) in list" :key="item.lxId" :data="item"
-				@btnClick="handleClick"></scroll-list-card-cuoti>
-		</template>
-	</custom-scroll-list-date-vue>
-</template>
-
-<script setup>
-	import scrollListCardCuoti from "@/components/score-list-card-cuoti/score-list-card-cuoti.vue";
-	import customScrollListDateVue from "@/components/custom-scroll-list/custom-scroll-list-date.vue";
-	import {
-		getCuotiList,
-	} from "@/api/cuoti.js";
-	import {
-		ref
-	} from "vue";
-
-	function handleClick(data) {
-		uni.navigateTo({
-			url: `/pages/cuoti/cuoti?hisId=${data.hisId}`
-		})	
-	}
-
-</script>
-
-<style lang="scss">
-
-</style>

+ 0 - 66
pages/demo/index.vue

@@ -1,66 +0,0 @@
-<template>
-	<view class="lli-demo-page">
-		<uni-search-bar class="uni-mt-10" radius="100" placeholder="请输入考试名称" bgColor="#F3F3F4" clearButton="auto" cancelButton="none" @confirm="search"/>
-		<view class="lli-status-box">
-		    <text class="status-item click">可以考试</text><text class="status-item">已结束</text>
-		</view>
-		<scroll-view class="demo-scroll-view" scroll-y="true">
-			<view class="content-view">
-				
-				<view class="lli-tc demo-title">------------咱们要用的默认按钮↓-------------</view>
-				<button class="lli-btn">页面次要操作 Normal</button>
-				<button class="lli-btn" loading="true" >页面主操作 Loading</button>
-				<button class="lli-btn" disabled="true" >页面次要操作 Disabled</button>
-				<view class="lli-tc demo-title">---------咱们要用的按钮plain(线性)↓----------</view>
-				<button class="lli-btn" plain="true">页面次要操作 Normal</button>
-				<button class="lli-btn" loading="true" plain="true">页面主操作 Loading</button>
-				<button class="lli-btn" disabled="true" plain="true">页面次要操作 Disabled</button>
-				<view class="lli-tc demo-title">------------其他组件定义color="#0550e5"-------------</view>	
-					<checkbox-group>
-						<label>
-							<checkbox value="cb" checked="true" color="#0550e5"/>选中
-						</label>
-						<label>
-							<checkbox value="cb" />未选中
-						</label>
-					</checkbox-group>
-					<view class="lli-tc demo-title">------------扩展组件-------------</view>
-						
-					<uni-section title="自定义样式" subTitle="使用 styles 属性 ,可以自定义输入框样式" type="line" padding>
-								<uni-easyinput v-model="value" placeholder="请输入内容"@input="input"></uni-easyinput>
-							</uni-section>
-			</view>
-		</scroll-view>
-	</view>
-</template>
-
-<script>
-	export default {
-		data() {
-			return {
-				value:'',
-			}
-		},
-		methods: {
-			search:function(){},
-		}
-	}
-</script>
-<style lang="scss">
-	.lli-demo-page{
-		display: flex;flex-direction: column;
-		height: 100vh;padding-bottom: 60rpx;box-sizing: border-box;
-		.demo-scroll-view{
-			overflow-y: auto;flex: 1;
-		}
-		.content-view{padding: 24px;box-sizing: border-box;}
-		.demo-title{margin: 24px 0 10px;}
-	}
-	/* 小程序UI开发规范 */
-	/*  1.第一版没有UI,用手机单机版的UI开发,尽可能保持一致
-		2.页面中样式第一版都先写到底部style中
-		2.扩展组件:已重置样式,可以直接用
-		3.内置组件:如果是有颜色的,需要添加color="#0550e5"(后期会改成动态的,第一版先这么加),btn也可以用demo写好的
-		4.自己写的样式尽量只用view,text标签,使用类选择器不要使用标签选择器 */
-</style>
-

+ 21 - 11
pages/index/index.vue

@@ -80,29 +80,31 @@
 		getNoticeCount,
 		getExamList
 	} from '@/api/index.js';
-	import { 
+	import {
 		onLoad
 	} from "@dcloudio/uni-app"
+	import cacheManager from '@/utils/cacheManager.js'
 	const banners = ref('');
-	const defaultbanners = ref('/static/images/index/index-banner.png');
-	const defultKsImg = ref('/static/images/index/index-ks-default.png');
-	const defultKcImg = ref('/static/images/index/index-kc-default.png');
+	const defaultbanners = ref('');
+	const defultKsImg = ref('');
+	const defultKcImg = ref('');
+
 	const statusCodeKc = ref(['未开始', '可以学习', '已学完', '学习中', '已结束']);
 	const statusCodeKs = ref(['未开始', '可以考试', '再次考试', '考试中', '已结束', '未报名', '报名审核中', '审核未通过', '等待人工评分']);
 	let menuList = ref([{
-			url: '/static/images/index/index-kc-img.png',
+			url: '',
 			text: '我的课程',
 		},
 		{
-			url: '/static/images/index/index-ks-img.png',
+			url: '',
 			text: '我的考试',
 		},
 		{
-			url: '/static/images/index/index-lx-img.png',
+			url: '',
 			text: '每日一练',
 		},
 		{
-			url: '/static/images/index/index-gg-img.png',
+			url: '',
 			text: '公告',
 			badge: 0,
 		},
@@ -115,13 +117,21 @@
 	const activeKs = ref(null);
 
 	onLoad(() => {
+		uni.showLoading({
+			title: '加载中'
+		});
+		defaultbanners.value = cacheManager.get('projectImg').index_banner
+		defultKsImg.value = cacheManager.get('projectImg').index_ks_default
+		defultKcImg.value = cacheManager.get('projectImg').index_kc_default
+		menuList.value[0].url = cacheManager.get('projectImg').index_kc_img
+		menuList.value[1].url = cacheManager.get('projectImg').index_ks_img
+		menuList.value[2].url = cacheManager.get('projectImg').index_lx_img
+		menuList.value[3].url = cacheManager.get('projectImg').index_gg_img
 		getNoticeCountData();
 		getCourseListData();
 		getExamListData();
+		uni.hideLoading();
 	});
-
-
-
 	function getNoticeCountData() {
 		let req = {
 			'page': 1,

+ 0 - 40
pages/lianxi/index.vue

@@ -1,40 +0,0 @@
-<template>
-	<custom-scroll-list :refreshFn="getLianxiList" :tabList="tabData" :defaultTab="1" ref="scrollRef"
-		placeholder="请输入练习名称">
-		<template #default="{list}">
-			<scroll-list-card-lianxi v-for="(item,index) in list" :key="item.lxId" :data="item"
-				@btnClick="handleClick"></scroll-list-card-lianxi>
-		</template>
-	</custom-scroll-list>
-</template>
-
-<script setup>
-	import scrollListCardLianxi from "@/components/score-lianxi-card-lianxi/score-lianxi-card-lianxi.vue"
-	import {
-		getLianxiList,
-	} from "@/api/lianxi.js";
-	import {
-		ref
-	} from "vue";
-
-
-	const tabData = [{
-			label: "开始练习",
-			value: 1,
-		},
-		{
-			label: "已结束",
-			value: 2,
-		}
-	]
-
-	function handleClick(data) {
-		uni.redirectTo({
-			url: `/pages/lianxi/lianxi?lxId=${data.lxId}`
-		})
-	}
-</script>
-
-<style lang="scss">
-
-</style>

+ 0 - 74
pages/my/components/birthdayDialog.vue

@@ -1,74 +0,0 @@
-<template>
-	<uni-popup ref="birthdayPopup" :animation="false" :is-mask-click="false"
-	 mask-background-color="rgba(0, 0, 0, 0.4)">
-	 <view class="phone-common-dialog birthday-dialog">
-		<view class="common-body-box">
-			<uni-calendar
-				ref="calendar"
-				:insert="true"
-				@change="dataConfirm"
-				 />
-			<view class="common-btn-box">
-				<view class="not-confirm-btn" @click="handleClose">{{notBtn}}</view>
-				<view class="confirm-btn" @click="confirmBtn">{{okBtn}}</view>
-			</view>
-		</view>
-	 </view>
-	</uni-popup>
-</template>
-
-<script setup>
-	import {ref,reactive} from "vue"
-	import {toast} from "@/utils/common";
-	const props = defineProps({
-	  notBtn: {
-	    type: String,
-	  	require: true,
-	    default: '取消'
-	  },
-	  okBtn: {
-	    type: String,
-	  	require: true,
-	    default: '确认'
-	  },
-	});
-	const time= ref('');
-	const birthdayPopup = ref(null); // 索引
-	const $emit = defineEmits(['confirm-btn'])
-	
-	function passClear(){
-		time.value = '';
-	}
-	
-	function dataConfirm(data){
-		time.value = data.fulldate;
-	}
-	
-	// 打开弹窗
-	function handleShow() {
-		birthdayPopup.value.open();
-	}
-	// 取消
-	function handleClose() {
-		passClear();
-		birthdayPopup.value.close();
-	}
-	// 确认
-	function confirmBtn(){
-		if(time.value){
-			$emit('confirm-btn',time.value);
-			passClear();
-			birthdayPopup.value.close();
-		}else{
-			toast('请选择日期')
-		}
-		
-	}
-	defineExpose({
-			handleShow,
-			handleClose
-		})
-</script>
-
-<style>
-</style>

+ 0 - 81
pages/my/components/genderDialog.vue

@@ -1,81 +0,0 @@
-<template>
-	<uni-popup ref="genderPopup" :animation="false" :is-mask-click="false"
-	 mask-background-color="rgba(0, 0, 0, 0.4)">
-	 <view class="phone-common-dialog">
-		<view class="common-body-box">
-			<view class="common-title">修改性别</view>
-			<view class="common-input-box">
-				<view class="common-input-row">
-					<text class="common-input-label"><text class="common-label-require">*</text>性别:</text>
-					<uni-data-select
-						class="common-select"
-					    v-model="data.gender"
-					    :localdata="data.range"
-					    @change="change"
-					></uni-data-select>
-				</view>
-			</view>
-			<view class="common-btn-box">
-				<view class="not-confirm-btn" @click="handleClose">{{notBtn}}</view>
-				<view class="confirm-btn" @click="confirmBtn">{{okBtn}}</view>
-			</view>
-		</view>
-	 </view>
-	</uni-popup>
-</template>
-
-<script setup>
-	import {ref,reactive} from "vue"
-	const props = defineProps({
-	  notBtn: {
-	    type: String,
-	  	require: true,
-	    default: '取消'
-	  },
-	  okBtn: {
-	    type: String,
-	  	require: true,
-	    default: '确认'
-	  },
-	});
-	const data = reactive({
-		gender: '',
-		range:[
-		    { value: 0, text: "未知" },
-		    { value: 1, text: "男" },
-		    { value: 2, text: "女" },
-		]
-	})
-	const genderPopup = ref(null); // 索引
-	const $emit = defineEmits(['confirm-btn'])
-	
-	function change(data){
-		console.log('changedata',data);
-	}
-	
-	function passClear(){
-		data.gender = '';
-	}
-	// 打开弹窗
-	function handleShow() {
-		genderPopup.value.open();
-	}
-	// 取消
-	function handleClose() {
-		passClear();
-		genderPopup.value.close();
-	}
-	// 确认
-	function confirmBtn(){
-		$emit('confirm-btn',data.gender);
-		passClear();
-		genderPopup.value.close();
-	}
-	defineExpose({
-			handleShow,
-			handleClose
-		})
-</script>
-
-<style>
-</style>

+ 0 - 103
pages/my/components/passwordDialog.vue

@@ -1,103 +0,0 @@
-<template>
-	<uni-popup ref="passwordPopup" :animation="false" :is-mask-click="false"
-	 mask-background-color="rgba(0, 0, 0, 0.4)">
-	 <view class="phone-common-dialog">
-		<view class="common-body-box">
-			<view class="common-title">修改密码</view>
-			<view class="common-input-box">
-				<view class="common-input-row">
-					<text class="common-input-label"><text class="common-label-require">*</text>原密码:</text>
-					<input class="common-input" v-model="data.oldPassWord"  placeholder="请输入原密码" />
-				</view>
-				<view class="common-input-row">
-					<text class="common-input-label"><text class="common-label-require">*</text>新密码:</text>
-					<input class="common-input" v-model="data.newPassWord"  placeholder="请输入新密码" />
-				</view>
-				<view class="common-input-row">
-					<text class="common-input-label"><text class="common-label-require">*</text>确认密码:</text>
-					<input class="common-input" v-model="data.okPassWord"  placeholder="请确认密码" />
-				</view>
-			</view>
-			<view class="common-btn-box">
-				<view class="not-confirm-btn" @click="handleClose">{{notBtn}}</view>
-				<view class="confirm-btn" @click="confirmBtn">{{okBtn}}</view>
-			</view>
-		</view>
-	 </view>
-	</uni-popup>
-</template>
-
-<script setup>
-	import {ref,reactive} from "vue"
-	const props = defineProps({
-	  notBtn: {
-	    type: String,
-	  	require: true,
-	    default: '取消'
-	  },
-	  okBtn: {
-	    type: String,
-	  	require: true,
-	    default: '确认'
-	  },
-	});
-	const data = reactive({
-		okPassWord: '',
-		oldPassWord: '',
-		newPassWord: '',
-	})
-	const passwordPopup = ref(null); // 索引
-	const $emit = defineEmits(['confirm-btn'])
-	
-	function passClear(){
-		data.okPassWord = '';
-		data.oldPassWord = '';
-		data.newPassWord = '';
-	}
-	// 打开弹窗
-	function handleShow() {
-		passwordPopup.value.open();
-	}
-	// 取消
-	function handleClose() {
-		passClear();
-		passwordPopup.value.close();
-	}
-	// 确认
-	function confirmBtn(){
-		let arr = [];
-		if (!data.oldPassWord) {
-			arr.push('原密码');
-		}
-		if (!data.newPassWord) {
-			arr.push('新密码');
-		}
-		if (!data.newPassWord) {
-			arr.push('确认密码');
-		}
-		if (!data.oldPassWord || !data.newPassWord) {
-			uni.showToast({
-				icon: 'none',
-				title: `请输入${arr.join('、')}信息!`
-			})
-			return;
-		}
-		if (data.newPassWord != data.okPassWord) {
-			uni.showToast({
-				icon: 'none',
-				title: '新密码和确认密码不同'
-			})
-			return;
-		}
-		$emit('confirm-btn',data);
-		passClear();
-		passwordPopup.value.close();
-	}
-	defineExpose({
-			handleShow,
-			handleClose
-		})
-</script>
-
-<style>
-</style>

+ 0 - 78
pages/my/components/realNameDialog.vue

@@ -1,78 +0,0 @@
-<template>
-	<uni-popup ref="realNamePopup" :animation="false" :is-mask-click="false"
-	 mask-background-color="rgba(0, 0, 0, 0.4)">
-	 <view class="phone-common-dialog">
-		<view class="common-body-box">
-			<view class="common-title">修改姓名</view>
-			<view class="common-input-box">
-				<view class="common-input-row">
-					<text class="common-input-label"><text class="common-label-require">*</text>真实姓名:</text>
-					<input class="common-input" v-model="data.realName"  placeholder="请输入真实姓名" />
-				</view>
-			</view>
-			<view class="common-btn-box">
-				<view class="not-confirm-btn" @click="handleClose">{{notBtn}}</view>
-				<view class="confirm-btn" @click="confirmBtn">{{okBtn}}</view>
-			</view>
-		</view>
-	 </view>
-	</uni-popup>
-</template>
-
-<script setup>
-	import {ref,reactive} from "vue"
-	const props = defineProps({
-	  notBtn: {
-	    type: String,
-	  	require: true,
-	    default: '取消'
-	  },
-	  okBtn: {
-	    type: String,
-	  	require: true,
-	    default: '确认'
-	  },
-	});
-	const data = reactive({
-		realName: '',
-	})
-	const realNamePopup = ref(null); // 索引
-	const $emit = defineEmits(['confirm-btn'])
-	
-	function passClear(){
-		data.realName = '';
-	}
-	// 打开弹窗
-	function handleShow() {
-		realNamePopup.value.open();
-	}
-	// 取消
-	function handleClose() {
-		passClear();
-		realNamePopup.value.close();
-	}
-	// 确认
-	function confirmBtn(){
-		let arr = [];
-		if (!data.realName) {
-			arr.push('真实姓名');
-		}
-		if (!data.realName) {
-			uni.showToast({
-				icon: 'none',
-				title: `请输入${arr.join('、')}信息!`
-			})
-			return;
-		}
-		$emit('confirm-btn',data.realName);
-		passClear();
-		realNamePopup.value.close();
-	}
-	defineExpose({
-			handleShow,
-			handleClose
-		})
-</script>
-
-<style>
-</style>

+ 0 - 78
pages/my/components/telDialog.vue

@@ -1,78 +0,0 @@
-<template>
-	<uni-popup ref="telPopup" :animation="false" :is-mask-click="false"
-	 mask-background-color="rgba(0, 0, 0, 0.4)">
-	 <view class="phone-common-dialog">
-		<view class="common-body-box">
-			<view class="common-title">修改电话</view>
-			<view class="common-input-box">
-				<view class="common-input-row">
-					<text class="common-input-label"><text class="common-label-require">*</text>新号码:</text>
-					<input class="common-input" v-model="data.tel"  placeholder="请输入新号码" />
-				</view>
-			</view>
-			<view class="common-btn-box">
-				<view class="not-confirm-btn" @click="handleClose">{{notBtn}}</view>
-				<view class="confirm-btn" @click="confirmBtn">{{okBtn}}</view>
-			</view>
-		</view>
-	 </view>
-	</uni-popup>
-</template>
-
-<script setup>
-	import {ref,reactive} from "vue"
-	const props = defineProps({
-	  notBtn: {
-	    type: String,
-	  	require: true,
-	    default: '取消'
-	  },
-	  okBtn: {
-	    type: String,
-	  	require: true,
-	    default: '确认'
-	  },
-	});
-	const data = reactive({
-		tel: '',
-	})
-	const telPopup = ref(null); // 索引
-	const $emit = defineEmits(['confirm-btn'])
-	
-	function passClear(){
-		data.tel = '';
-	}
-	// 打开弹窗
-	function handleShow() {
-		telPopup.value.open();
-	}
-	// 取消
-	function handleClose() {
-		passClear();
-		telPopup.value.close();
-	}
-	// 确认
-	function confirmBtn(){
-		let arr = [];
-		if (!data.tel) {
-			arr.push('新号码');
-		}
-		if (!data.tel) {
-			uni.showToast({
-				icon: 'none',
-				title: `请输入${arr.join('、')}!`
-			})
-			return;
-		}
-		$emit('confirm-btn',data.tel);
-		passClear();
-		telPopup.value.close();
-	}
-	defineExpose({
-			handleShow,
-			handleClose
-		})
-</script>
-
-<style>
-</style>

+ 0 - 29
pages/my/credit.vue

@@ -1,29 +0,0 @@
-<template>
-	<!-- <view class="sum-score-box">总学分:{{totalCredits}}分</view>
-	<custom-scroll-list :hasSearcBar="false" :refreshFn="getCreditList" :hasTab="false">
-		<template #default="{list}">
-			<scroll-list-card-mes  v-for="(item,index) in list" :key="item.noticeId"
-				:data="item"></scroll-list-card-mes>
-		</template>
-	</custom-scroll-list> -->
-</template>
-
-<script setup>
-	import {getCreditList,getCreditTotal} from '@/api/my.js'
-	import {onLoad,onReady,} from "@dcloudio/uni-app"
-	import {reactive,ref} from "vue";
-	let totalCredits = ref('');
-	onLoad(() => {
-		getCreditInit()
-	})
-	
-	function getCreditInit() {
-		getTotalData();
-	}
-	
-	function getTotalData(){
-		getCreditTotal({}).then(res => {
-			totalCredits.value= res.data;
-		})
-	}
-</script>

+ 0 - 41
pages/my/mesList.vue

@@ -1,41 +0,0 @@
-<template>
-	<!-- <custom-scroll-list :hasSearcBar="false" :refreshFn="getNoticeList" :hasTab="false">
-		<template #default="{list}">
-			<scroll-list-card-mes  v-for="(item,index) in list" :key="item.noticeId"
-				:data="item"></scroll-list-card-mes>
-		</template>
-	</custom-scroll-list> -->
-</template>
-
-<script setup>
-	import {getNoticeList} from '@/api/my.js'
-	import {onLoad,onReady,} from "@dcloudio/uni-app"
-	import {reactive,ref} from "vue";
-	let pageFrom = ref('');
-	onLoad((options) => {
-		pageFrom.value = options.from;
-		console.log('pageFrom.value', pageFrom.value);
-		
-	
-	});
-	function onBackPress() { 
-		switch (pageFrom.value) {
-			case 'my':
-			    uni.redirectTo({
-			       url: '/pages/my/index' 
-			     });
-			    break;
-			case 'index':
-			    uni.redirectTo({
-			       url: '/pages/index/index' 
-			     });
-			    break;	
-			case 'indexPeixun':
-			    uni.redirectTo({
-			       url: '/pages/index/index' 
-			     });
-			    break;
-		}
-	   
-	  }
-</script>

+ 0 - 38
pages/my/mesPage.vue

@@ -1,38 +0,0 @@
-<template>
-	<view class="phone-mes-page">
-		 <view class="mes-box">
-		     <view class="mes-name">{{mesPageData.name}}</view>
-		     <text class="mes-time">{{mesPageData.createTime}}</text>
-		     <view  class="fwb-box" v-html="mesPageData.content"></view>
-		 </view>
-	</view>
-</template>
-
-<script setup>
-import {reactive,ref} from "vue";
-import {onLoad,onShow} from '@dcloudio/uni-app';
-import {getNoticeInfo} from '@/api/my.js'
-let mesPageData = reactive({
-	name: '',
-	createTime: '',
-	content: '',
-});
-	
-let pageId = ref('');
-onLoad((options) => {
-	pageId.value = options.noticeId;
-	getMesInit()
-});
-
-function getMesInit(){
-	getNoticeInfo({noticeId:pageId.value}).then(res => {
-		mesPageData.name= res.data.name;
-		mesPageData.createTime = res.data.createTime;
-		mesPageData.content = res.data.content;
-	})
-}
-</script>
-
-<style>
-
-</style>

+ 0 - 237
pages/my/setting.vue

@@ -1,237 +0,0 @@
-<template>
-	<view class="mobile-setting-page">
-		<view class="setting-list-box">
-			<view class="list-row no-jt-row img-list-row">
-				<text>头像</text>
-				<img class="head-img" :src="settingData.icon" v-if="settingData.icon">
-				<icon class="phone-default-userImg setting-default-userImg" v-else></icon>
-			</view>
-			<view class="list-row no-jt-row">
-				<text>用户名</text>
-				<text class="row-content">{{settingData.userName}}</text>
-			</view>
-			<!-- <view class="list-row" @click="goToPage('realName')">
-				<text>真实姓名</text>
-				<text class="row-content">{{settingData.realName}}</text>
-			</view>
-			<view class="list-row" @click="goToPage('gender')">
-				<text>性别</text>
-				<text class="row-content" v-if="settingData.gender===0"></text>
-				<text class="row-content" v-if="settingData.gender===1">男</text>
-				<text class="row-content" v-if="settingData.gender===2">女</text>
-			</view>
-			
-			<view class="list-row" @click="goToPage('shengri')">
-				<text>生日</text>
-				<text class="row-content">{{settingData.birthday}}</text>
-			</view>
-			
-			<view class="list-row" @click="goToPage('tel')">
-				<text>电话</text>
-				<text class="row-content">{{settingData.tel}}</text>
-			</view>
-			<view class="list-row" @click="goToPage('xgmm')">
-				<text>修改密码</text>
-				<text class="row-content">{{settingData.xgmm}}</text>
-			</view> -->
-			<view class="list-row no-jt-row" @click="goToPage('qlhc')">
-				<text>清理缓存</text>
-				<text class="row-content"></text>
-			</view>
-		</view>
-		<view @click="quitClick" class="exit-login-btn">退出登录</view>
-		<real-name-dialog ref="realNameDialogRef" @confirm-btn="realNameBtn"></real-name-dialog>
-		<tel-dialog ref="telDialogRef" @confirm-btn="telBtn"></tel-dialog>
-		<password-dialog ref="passwordDialogRef" @confirm-btn="passwordBtn"></password-dialog>
-		<birthday-dialog ref="birthdayDialogRef" @confirm-btn="birthdayBtn"></birthday-dialog>
-		<gender-dialog ref="genderDialogRef" @confirm-btn="genderBtn"></gender-dialog>
-	</view>
-</template>
-
-<script setup>
-import {reactive,ref} from "vue";
-import {logout} from '@/api/login.js'
-import {toast} from "@/utils/common";
-import {onLoad} from '@dcloudio/uni-app';
-import {getUserInfo,getUserUpRealName,getUserUpTel,getUserUpPassword,getUserUpBirthday,getUserUpGender} from '@/api/my.js'
-import {useUserCache} from "@/utils/userCache.js"
-import cacheManager from '@/utils/cacheManager.js';
-import realNameDialog from './components/realNameDialog.vue';
-import telDialog from './components/telDialog.vue';
-import passwordDialog from './components/passwordDialog.vue';
-import birthdayDialog from './components/birthdayDialog.vue';
-import genderDialog from './components/genderDialog.vue';
-
-let settingData = reactive({
-		icon: '',
-		userName: '',
-		realName: '',
-		gender:'',
-		birthday: '',
-		tel:'',
-	});
-	
-	onLoad(() => {
-		getSettingInit()
-	})
-	
-	function getSettingInit(){
-		getUserInfo({}).then(res => {
-			settingData.icon = res.data.icon;
-			settingData.userName = res.data.userName;
-			settingData.realName = res.data.realName;
-			settingData.gender = res.data.gender;
-			settingData.birthday = res.data.birthday;
-			settingData.tel = res.data.tel;
-		})
-	}
-	
-	/***** 跳转 *****/
-	function goToPage(data){
-		switch (data) {
-			case 'realName':
-			    realNameDialogRef.value.handleShow();
-			break;
-			case 'gender':
-			    genderDialogRef.value.handleShow();
-			break;
-			case 'shengri':
-			    birthdayDialogRef.value.handleShow();
-			break;
-			case 'tel':
-			    telDialogRef.value.handleShow();
-			break;
-			case 'xgmm':
-			    passwordDialogRef.value.handleShow();
-			break;
-			case 'qlhc':
-			    clearLocation()
-			break;
-		}
-	}
-	
-	
-	function clearLocation(){
-		// 清理考试缓存
-		useUserCache().removeCache('kaoshiCache');
-	}
-	
-	function quitClick(){
-		uni.showModal({
-				title: '提示',
-				content: '你确定要执行这个操作吗?',
-				success: (res) => {
-				  if (res.confirm) {
-					// 确定
-					quit()
-				  } else if (res.cancel) {
-					// 取消
-				  }
-				}
-			  });
-		
-		 }
-		 
-	function quit (){
-			logout().then(res=>{
-				toast('退出登录成功')
-				uni.navigateTo({
-					url: '/pages/login'
-				});
-				cacheManager.clearAll();
-				
-			}).catch(err => {
-			toast('退出登录失败,请稍后重试')
-		})
-		
-	}
-	/***** 真实姓名 *****/
-	const realNameDialogRef = ref(null);
-	function realNameBtn(data){
-		console.log(data,'data');
-		settingData.realName = data;
-		const opt = {
-			realName: settingData.realName,
-		}
-		getUserUpRealName(opt).then(res => {
-			if (res.data) {
-				uni.showToast({
-					title: '更新成功'
-				})
-				realNameDialogRef.value.handleClose();
-			}
-		})
-	}
-	
-	/***** 电话 *****/
-	const telDialogRef = ref(null);
-	function telBtn(data){
-		console.log(data,'data');
-		settingData.tel = data;
-		const opt = {
-			tel: settingData.tel,
-		}
-		getUserUpTel(opt).then(res => {
-			if (res.data) {
-				uni.showToast({
-					title: '更新成功'
-				})
-				telDialogRef.value.handleClose();
-			}
-		})
-	}
-	
-	/***** 修改日期 *****/
-	const birthdayDialogRef = ref(null);
-	function birthdayBtn(data){
-		settingData.birthday = data;
-		const opt = {
-			brithday: settingData.birthday,
-		}
-		getUserUpBirthday(opt).then(res => {
-			if (res.data) {
-				uni.showToast({
-					title: '更新成功'
-				})
-				birthdayDialogRef.value.handleClose();
-			}
-		})
-	}
-	
-	/***** 修改性别 *****/
-	const genderDialogRef = ref(null);
-	function genderBtn(data){
-		settingData.gender = data;
-		const opt = {
-			gender: data,
-		}
-		getUserUpGender(opt).then(res => {
-			if (res.data) {
-				uni.showToast({
-					title: '更新成功'
-				})
-				birthdayDialogRef.value.handleClose();
-			}
-		})
-	}
-	
-	/***** 修改密码 *****/
-	const passwordDialogRef = ref(null);
-	function passwordBtn(data){
-		const opt = {
-			passwordOld: data.oldPassWord,
-			passwordNew: data.newPassWord, 
-		}
-		getUserUpdatePassword(opt).then(res => {
-			if (res.data) {
-				uni.showToast({
-					title: '更新成功'
-				})
-				passwordDialogRef.value.handleClose();
-			}
-		})
-	}
-</script>
-
-<style>
-</style>

+ 0 - 34
pages/my/zhengshu.vue

@@ -1,34 +0,0 @@
-<template>
-	<custom-scroll-list :hasSearcBar="false" :refreshFn="getZhengshuList" :hasTab="false" >
-		<template #default="{list}">
-			<scroll-list-card-zhengshu  v-for="(item,index) in list" :key="item.ksId"
-				:data="item"></scroll-list-card-zhengshu>
-		</template>
-	</custom-scroll-list>
-</template>
-
-<script setup>
-	import {
-		getZhengshuList
-	} from "@/api/zhengshu.js";
-	import {
-		onLoad,
-		onReady,
-
-	} from "@dcloudio/uni-app"
-	import {
-		reactive,
-		ref
-	} from "vue";
-	function onBackPress(options) { 
-
-	    uni.redirectTo({
-	      url: '/pages/my/index' 
-	    });
-	    return true; 
-	  }
-</script>
-
-<style lang="scss">
-
-</style>

BIN
static/images/index/index-banner.png


BIN
static/images/index/index-gg-img.png


BIN
static/images/index/index-kc-default.jpg


BIN
static/images/index/index-kc-img.png


BIN
static/images/index/index-ks-default.png


BIN
static/images/index/index-ks-img.png


BIN
static/images/index/index-lx-img.png


BIN
static/images/index/indexks-ks-img.png


BIN
static/images/my/my-baoming-icon-sj.png


BIN
static/images/my/my-certificate-icon-sj.png


BIN
static/images/my/my-ceshi-icon-sj.png


BIN
static/images/my/my-credits-icon-sj.png


BIN
static/images/my/my-explain-icon-sj.png


BIN
static/images/my/my-learnMap-icon-sj.png


BIN
static/images/my/my-news-icon-sj.png


BIN
static/images/my/my-office-icon-sj.png


BIN
static/images/my/my-setting-icon-sj.png


BIN
static/images/my/my-wrong-icon-sj.png


+ 0 - 0
pages/exam/exam.vue → subpkgExam/pages/exam/exam.vue


+ 0 - 0
pages/exam/examTools.js → subpkgExam/pages/exam/examTools.js


+ 63 - 96
pages/lianxi/lianxi.vue → subpkgScore/pages/score/kaoshiChengjiInfo.vue

@@ -1,18 +1,12 @@
 <template>
-	<view class="phone-kaoshi-page">
-		<!-- 导航区域 -->
-		<view class="icon-title-navBar-box">
-			<view @click="handleBack" class="nav-bar-icon"></view>
-			<text class="nav-bar-title">{{data.lxName}}</text>
-		</view>
+	<view class="mobile-shiti-page mobile-score-page">
+		<customNavbarVue :title="data.name" :show-back-btn="true" @back="handleBack"></customNavbarVue>
 		<!-- 第一行 -->
-		<view class="kaoshi-page-title">
+		<view class="shiti-page-title kaoshi-page-title">
 			<view v-if="activeSt" class="title-types">{{dlName}}</view>
-			<view>100分钟</view>
 		</view>
 
-
-		<view class="kaoshi-shiti-content">
+		<view class="shiti-content-box">
 			<!-- 内容区域 -->
 			<!-- 试题区域 -->
 			<view v-if="activeSt">
@@ -39,32 +33,27 @@
 				<template v-if="activeSt.stTypeId == 6">
 					<!-- 阅读 -->
 					<yuedu :question="activeSt" :key="activeSt.stId" @yudu-change="onYueduChange"></yuedu>
+					
 				</template>
 			</view>
 
 		</view>
-
-		<view class="kaoshi-bottom-box">
-			<button class="phone-green-btn bj-btn" hover-class="none" type="default" size="mini"
-				@click="handleBiaoji">{{activeSt && activeSt.marked ? '取标':'标记'}}</button>
-			<view @click="showAnswerCard" class="shiti-num-box">
+		<view class="shiti-bottom-box">
+			<view class="shiti-num-box kecheng-bottom-box">
+				<icon class="answer-score-icon"></icon>
+				<text class="orange-big-color">{{data.userScore}}</text> / {{data.ksScore}}分
+			</view>
+			<view class="shiti-num-box"  @click="showAnswerCard" >
 				<icon class="shiti-num-icon"></icon>
-				<text
-					class="active-num">{{activeSt ? activeSt.onlyNum: 0}}</text>/<text>{{data.StListForSearch.length}}</text>
+				<text class="blue-big-color">{{activeSt ? activeSt.onlyNum: 0}}</text>/ {{data.StListForSearch.length}}
 			</view>
-			<button class="phone-white-btn jx-btn" hover-class="none" type="default" size="mini"
-				@click="handleCheckJiexi">解析</button>
 		</view>
 		<template v-if="activeSt">
-			<button type="default" size="mini" hover-class="none" class="phone-green-btn ks-btn-prev"
+			<button type="default" size="mini" hover-class="none" class="phone-green-btn st-btn-prev"
 				@click="handlePrev" v-if="!isFistStId">上一题</button>
-			<button type="default" size="mini" hover-class="none" class="phone-green-btn ks-btn-next"
+			<button type="default" size="mini" hover-class="none" class="phone-green-btn st-btn-next"
 				@click="handleNext" v-if="!isLastStId">下一题</button>
-			<button type="default" size="mini" hover-class="none" class="phone-green-btn ks-btn-next"
-				@click="handleBack" v-if="isLastStId">交卷</button>
 		</template>
-
-		<!-- 答题卡 -->
 		<uni-popup ref="popupRef" background-color="#fff" :animation="false" :is-mask-click="false" :mask-click="false">
 			<view class="answer-card-popup">
 				<view class="icon-title-navBar-box">
@@ -84,13 +73,6 @@
 				</view>
 			</view>
 		</uni-popup>
-		<!--
-		// 倒计时
-		<view v-if="!!data.endSecond">
-			<text>考试倒计时:</text>
-			<uni-countdown :show-day="false" :second="1000" @timeup="onTimeUp" :start="startCountDown"></uni-countdown>
-		</view>
-		-->
 		<!-- 答案解析 -->
 		<scoreAndAnswerVue ref="scoreAnswerRef"></scoreAndAnswerVue>
 		<scoreAndAnswerAdminTiankong ref="scoreAnswerTkRef"></scoreAndAnswerAdminTiankong>
@@ -111,16 +93,17 @@
 	import {
 		onLoad
 	} from "@dcloudio/uni-app";
-	import * as lxApi from "@/api/lianxi.js"
-	import danxuan from "@/components/questions/danxuan.vue";
-	import duoxuan from "@/components/questions/duoxuan.vue";
-	import tiankong from "@/components/questions/tiankong.vue";
-	import panduan from "@/components/questions/panduan.vue";
-	import jianda from "@/components/questions/jianda.vue";
-	import yuedu from "@/components/questions/yuedu.vue";
+	import * as cjApi from "@/api/chengji.js"
+	import danxuan from "@/components/questionsChengji/danxuan.vue";
+	import duoxuan from "@/components/questionsChengji/duoxuan.vue";
+	import tiankong from "@/components/questionsChengji/tiankong.vue";
+	import panduan from "@/components/questionsChengji/panduan.vue";
+	import jianda from "@/components/questionsChengji/jianda.vue";
+	import yuedu from "@/components/questionsChengji/yuedu.vue";
 	import scoreAndAnswerVue from "@/components/scoreAndAnswer/scoreAndAnswerAdmin.vue";
 	import scoreAndAnswerAdminTiankong from "@/components/scoreAndAnswer/scoreAndAnswerAdminTiankong.vue";
 	import scoreAndAnswerAdminJianda from "@/components/scoreAndAnswer/scoreAndAnswerJianda.vue";
+	import customNavbarVue from "@/components/custom-navbar/custom-navbar.vue";
 	import {
 		useQuestionTools
 	} from "@/components/questions/useQuestionTools.js";
@@ -149,8 +132,10 @@
 	const scoreAnswerJdRef = ref(null);
 
 	const data = reactive({
-		lxId: null,
-		lxName: '',
+		hisId: null,
+		name: '',
+		ksScore: '',
+		scoreData: '',
 		stTotal: 0,
 		stScore: 0,
 		biaoji: null,
@@ -211,10 +196,29 @@
 	});
 
 	onLoad((option) => {
-		data.lxId = option.lxId;
+		data.hisId = option.hisId;
+		data.name = option.name;
+		data.userScore = option.userScore;
+		data.ksScore = option.ksScore;
+
 		initKaoshi();
 	})
 
+	function onTimeUp() {
+		console.log('end')
+	}
+	function answerCardItemClick(qa) {
+		const actQa = data.StListForSearch.find(item => item.stId == qa.stId);
+		skipQuestion(actQa.dlIndex, actQa.dtIndex)
+	
+	}
+	function skipQuestion(dlIndex, dtIndex) {
+		progress.dlIndex = dlIndex;
+		progress.dtIndex = dtIndex;
+		handlePopupBack()
+		// 切换试题时清空阅读提解析
+		yuduIndexQa.value = null;
+	}
 	function getQaClass(qa) {
 		if (qa.marked && qa.marked === true) {
 			return 'paragraph-qa-block-mark';
@@ -258,31 +262,6 @@
 			}
 		}
 	}
-
-	function skipQuestion(dlIndex, dtIndex) {
-		progress.dlIndex = dlIndex;
-		progress.dtIndex = dtIndex;
-		handlePopupBack()
-		// 切换试题时清空阅读提解析
-		yuduIndexQa.value = null;
-	}
-
-	function answerCardItemClick(qa) {
-		const actQa = data.StListForSearch.find(item => item.stId == qa.stId);
-		skipQuestion(actQa.dlIndex, actQa.dtIndex)
-
-	}
-
-	function handleBack() {
-		uni.redirectTo({
-			url: "/pages/admin/Lianxi/list"
-		})
-	}
-
-	function onTimeUp() {
-		console.log('end')
-	}
-
 	function showAnswerCard() {
 		popupRef.value.open('top')
 	}
@@ -308,6 +287,7 @@
 		const index = qa.num - 1;
 		if (index < data.StListForSearch.length) {
 			const result = data.StListForSearch[index + 1];
+			console.log('resultresult',result);
 			progress.dlIndex = result.dlIndex;
 			progress.dtIndex = result.dtIndex
 		}
@@ -472,12 +452,9 @@
 			questionData.value.push(paragraph)
 
 			console.log(questionData.value)
+			console.log(paragraph)
 		}
 	}
-
-	function handleBiaoji() {
-		activeSt.value.marked = !activeSt.value.marked;
-	}
 	// 切换阅读小题时更新当前试题解析
 	function onYueduChange(qa) {
 		yuduIndexQa.value = qa;
@@ -485,12 +462,13 @@
 
 	// 校验阅读解析
 	function checkYueduJiexi() {
+		debugger
 		let qa = yuduIndexQa.value;
 		let score = qa.userScore;
 		let reply = '';
 		let result = '';
 		let answer = qa.answer;
-		if (qa.stTypeId == 1) {
+		if (qa.stTypeId == 0) {
 			// 单选题
 			if (qa.reply && qa.reply.trim() !== '') {
 				reply = getLetterByIndex(qa.reply)
@@ -689,38 +667,27 @@
 
 	}
 
+	function handleBack() {
+
+		// uni.redirectTo({
+		// 	url: "/pages/score/index"
+		// })
+	uni.navigateBack()
+	}
+
 	function initKaoshi() {
-		lxApi.getLianxiInfo({
-			lxId: data.lxId
+		cjApi.lookChengjiView({
+			hisId: data.hisId
 		}).then(res => {
 			const {
-				lxId,
-				lxName,
-				stTotal,
-				stScore,
-				biaoji,
-				endSecond,
-				pageSize,
-				toggleScreenFlag,
-				toggleScreenSecond,
-				zhuapai,
+				hisId,
 				duanluoList
 			} = res.data;
-			data.lxId = lxId;
-			data.lxName = lxName;
-			data.stTotal = stTotal;
-			data.stScore = stScore;
-			data.biaoji = biaoji;
-			data.endSecond = endSecond;
-			data.pageSize = pageSize;
-			data.toggleScreenFlag = toggleScreenFlag;
-			data.toggleScreenSecond = toggleScreenSecond;
-			data.zhuapai = zhuapai;
+			data.hisId = hisId;
 			data.duanluo = duanluoList;
 			formatDuanluoList(data.duanluo);
-			startCountDown.value = true;
 			uni.setNavigationBarTitle({
-				title: data.lxName
+				title: data.name
 			});
 		})
 	}

+ 0 - 178
utils/request copy 1.js

@@ -1,178 +0,0 @@
-import axios     from 'axios';
-import { Md5 }   from 'ts-md5/dist/md5';
-import config from '@/config'
-let noTimeoutLimitArr = [
-
-];
-
-// create an axios instance
-const service = axios.create({
-                                 baseURL:         config.baseUrl, // url = base url + request url
-                                 withCredentials: false, // send cookies when cross-domain requests
-                                 timeout:         20000, // request timeout
-                             });
-
-export let needLoadingRequestCount = 0;
-export function showFullScreenLoading(config) {
-    if (needLoadingRequestCount === 0) {
-        store.state.isLoading = true
-    }
-    needLoadingRequestCount++;
-}
-
-export function tryHideFullScreenLoading() {
-    if (needLoadingRequestCount <= 0) {
-        return;
-    }
-
-    needLoadingRequestCount--;
-    if (needLoadingRequestCount === 0) {
-        store.state.isLoading = false
-    }
-}
-// request interceptor
-service.interceptors.request.use(
-    config => {
-        // do something before request is sent
-        // console.log(config);
-
-        function setTimeoutunlimit(config) {
-            // if (_.indexOf(noTimeoutLimitArr, config.url) > -1) {
-            //     config.timeout = 9999999999;
-            // }
-        }
-
-        function mixSignAndToken(config) {
-		//	debugger
-            // console.log(config.data, process.env.VUE_APP_BASE_API, process.env.VUE_APP_SECRET_KEY);
-            const checkurl = function (url) {
-                if (url === '/common/active') {
-                    return false;
-                }
-                // 用户端白名单
-                if (url.indexOf('/common') > -1) {
-                    return true;
-                }
-                // 管理端白名单
-                if (url === '/admin/user/auth') {
-                    return true;
-                }
-                // 短信服务白名单
-                if (url === 'sms/sendCode') {
-                    return true;
-                }
-                return false;
-            };
-			
-            if (checkurl(config.url)) {
-                if(config.url.indexOf('/open' >-1)){
-                }else {
-                    config.headers['X-AUTH-SIGN'] = Md5.hashStr(JSON.stringify(config.data) + '123');
-                }
-            } else {
-                if (store.state.auth) {
-                    config.headers['X-AUTH-SIGN'] = Md5.hashStr(JSON.stringify(config.data) + store.state.auth.secret);
-                    config.headers['X-AUTH-TOKEN'] = store.state.auth.token;
-                } else {
-                    // 非登录操作,但没有auth,跳转登录
-                    router.push('/' + store.state.tenantCode + '/login');
-                }
-            }
-
-        }
-        // if (!JSON.stringify(config.data.customLoadingSwitch)) {
-        //     //  如不需要在data中 LoadingSwitch:false
-        //     console.log('有loading');
-        //     showFullScreenLoading(config);
-        // }
-        mixSignAndToken(config);
-        setTimeoutunlimit(config);
-
-        /*if (store.getters.token) {
-            // let each request carry token
-            // ['X-Token'] is a custom headers key
-            // please modify it according to the actual situation
-            config.headers['X-Token'] = getToken();
-        }*/
-        return config;
-    },
-    error => {
-        // do something with request error
-        // console.log(error); // for debug
-        return Promise.reject(error);
-    },
-);
-
-
-
-// response interceptor
-service.interceptors.response.use(
-    /**
-     * If you want to get http information such as headers or status
-     * Please return  response => response
-     */
-
-    /**
-     * Determine the request status by custom code
-     * Here is just an example
-     * You can also judge the status by HTTP Status Code
-     */
-    response => {
-        const res = response.data;
-
-        // if the custom code is not 20000, it is judged as an error.
-        if (res.code !== 0) {
-    
-            // 401:登录超时
-            if (res.code === 401) {
-                setTimeout(function () {
-                    if (window.loading) {
-                        window.loading.close();
-                    }
-                    // console.log(router);
-                    /*if (router.app.$route.path.indexOf('/c/') === 0) {
-                        router.push('/c/' + store.state.tenantCode + '/login');
-                    } else {
-                        router.push('/a/' + store.state.tenantCode + '/login');
-                    }*/
-                    store.state.showBottomNav = true;
-                    router.push('/login');
-                }, 2000);
-            }
-            if (res.code === 405) {
-                setTimeout(function () {
-                    if (window.loading) {
-                        window.loading.close();
-                    }
-                    store.state.showBottomNav = true;
-                    router.push('/login');
-                }, 2000);
-            }
-
-            if (res.code === 502) {
-            //    Toast.fail('bad gateway');
-            }
-            if (res.code === 500 || res.code === 1001|| res.code ===1002) {
-                tryHideFullScreenLoading();
-                return Promise.reject('error' + res.code + '-' + (res.message === undefined ? 'nomessage': res.message));
-            }
-            tryHideFullScreenLoading();
-            return Promise.reject(res.message || 'error');
-        } else {
-            tryHideFullScreenLoading();
-            return res;
-        }
-    },
-    error => {
-
-        if (error == 'Error: Network Error') {
-        //    Toast.fail('网络断开,请检查网络');
-        } else {
-         //   Toast.fail('其他错误,请联系管理员');
-        }
-        tryHideFullScreenLoading();
-        return Promise.reject(error);
-    },
-);
-
-export default service;

+ 0 - 73
utils/request copy.js

@@ -1,73 +0,0 @@
-import store from '@/store'
-import config from '@/config'
-import { getToken } from '@/utils/auth'
-import errorCode from '@/utils/errorCode'
-import { toast, showConfirm, tansParams } from '@/utils/common'
-
-let timeout = 10000
-const baseUrl = config.baseUrl
-
-const request = config => {
-  // 是否需要设置 token
-  const isToken = (config.headers || {}).isToken === false
-  config.header = config.header || {}
-  if (getToken() && !isToken) {
-    config.header['Authorization'] = 'Bearer ' + getToken()
-  }
-  // get请求映射params参数
-  if (config.params) {
-    let url = config.url + '?' + tansParams(config.params)
-    url = url.slice(0, -1)
-    config.url = url
-  }
-  return new Promise((resolve, reject) => {
-    uni.request({
-        method: config.method || 'get',
-        timeout: config.timeout ||  timeout,
-        url: config.baseUrl || baseUrl + config.url,
-        data: config.data,
-        header: config.header,
-        dataType: 'json'
-      }).then(response => {
-        let [error, res] = response
-        if (error) {
-          toast('后端接口连接异常')
-          reject('后端接口连接异常')
-          return
-        }
-        const code = res.data.code || 200
-        const msg = errorCode[code] || res.data.msg || errorCode['default']
-        if (code === 401) {
-          showConfirm('登录状态已过期,您可以继续留在该页面,或者重新登录?').then(res => {
-            if (res.confirm) {
-              store.dispatch('LogOut').then(res => {
-                uni.reLaunch({ url: '/pages/login' })
-              })
-            }
-          })
-          reject('无效的会话,或者会话已过期,请重新登录。')
-        } else if (code === 500) {
-          toast(msg)
-          reject('500')
-        } else if (code !== 200) {
-          toast(msg)
-          reject(code)
-        }
-        resolve(res.data)
-      })
-      .catch(error => {
-        let { message } = error
-        if (message === 'Network Error') {
-          message = '后端接口连接异常'
-        } else if (message.includes('timeout')) {
-          message = '系统接口请求超时'
-        } else if (message.includes('Request failed with status code')) {
-          message = '系统接口' + message.substr(message.length - 3) + '异常'
-        }
-        toast(message)
-        reject(error)
-      })
-  })
-}
-
-export default request