Przeglądaj źródła

Merge branch '2025鹅状元数学' of https://gogs.mtavip.com/wangguoyu/uniProject into 2025鹅状元数学

tanxue 4 tygodni temu
rodzic
commit
79c53630af

+ 14 - 1
api/chaojidanci.js

@@ -84,4 +84,17 @@ export function getDanciChanpinBanbenSave(data = {}) {
     data,
     timeout: 20000
   })
-}
+}
+
+export function getDanciChanpinWordInfo(data = {}) {
+  return request({
+    'url': '/app/danci/chanpin/danci/info',
+    headers: {
+      isToken: true
+    },
+    method: 'post',
+    data,
+    timeout: 20000
+  })
+}
+

+ 7 - 0
pages.json

@@ -197,6 +197,13 @@
 			}
 		},
 		{
+			"path" : "pages/chaojidanci/newEnglish/components/xiangjie",
+			"style" :
+			{
+				"navigationStyle": "custom"
+			}
+		},
+		{
 			"path" : "pages/chaojidanci/newEnglish/index",
 			"style" :
 			{

+ 9 - 36
pages/chaojidanci/newEnglish/components/xiangjie.vue

@@ -37,9 +37,8 @@
 		onMounted
 	} from 'vue';
 	import {
-		getWordInfo,
-		getWordInfoYk
-	} from "@/api/word.js"
+		getDanciChanpinWordInfo
+	} from "@/api/chaojidanci.js"
 	import {
 		onLoad
 	} from '@dcloudio/uni-app';
@@ -57,16 +56,10 @@
 		name: ''
 	})
 	const data = ref(null)
-	const userCode = getUserIdentity();
 
 	onLoad((options) => {
-		if (userCode !== 'Visitor') {
-			getInfo(options)
-			data.value = options
-		} else {
-			getCommonInfo(options)
-			data.value = options
-		}
+		getInfo(options)
+		data.value = options
 	})
 	const highlightWord = (text) => {
 		if (!text || !pageInfo.value.name) {
@@ -80,36 +73,16 @@
 		});
 	}
 	const handleBack = () => {
-
-
-		if (userCode !== 'Visitor') {
-			uni.redirectTo({
-				url: `/pages/chaojidanci/newEnglish/index?jieId=${data.value.jieId}&wordId=${data.value.wordId}`
-			});
-		} else {
-			
-			console.log('data123',data);
-			uni.redirectTo({
-				url: `/pages/chaojidanci/newEnglish/index?jieId=${data.value.jieId}&wordId=${data.value.wordId}&levelId=${data.value.levelId}&typeId=${data.value.typeId}&subjectId=${data.value.subjectId}&tipFlag=${data.value.tipFlag}&youkeZhangId=${data.value.youkeZhangId}`
-			});
-		}
+		uni.redirectTo({
+				url: `/pages/chaojidanci/newEnglish/index?danyuanId=${data.value.danyuanId}&wordId=${data.value.wordId}`
+		});
 	}
 	const getInfo = (data) => {
 		let req = {
-			jieId: data.jieId,
-			wordId: data.wordId
-		}
-		getWordInfo(req).then(res => {
-			console.log('res', res);
-			pageInfo.value = res.data
-		})
-	}
-	const getCommonInfo = (data) => {
-		let req = {
-			jieId: data.jieId,
+			danyuanId: data.danyuanId,
 			wordId: data.wordId
 		}
-		getWordInfoYk(req).then(res => {
+		getDanciChanpinWordInfo(req).then(res => {
 			console.log('res', res);
 			pageInfo.value = res.data
 		})