Forráskód Böngészése

Merge remote-tracking branch 'origin/2025鹅状元数学' into 2025鹅状元数学

tanxue 21 órája
szülő
commit
b9f6dd7128

+ 12 - 0
api/chanpinneirong.js

@@ -83,3 +83,15 @@ export function yingyuPinduInfo(data = {}) {
     timeout: 20000
   })
 }
+
+export function yingyuDanciInfo(data = {}) {
+  return request({
+    'url': '/app/danci/chanpin/banben/info',
+    headers: {
+      isToken: true
+    },
+    method: 'post',
+    data,
+    timeout: 20000
+  })
+}

+ 25 - 0
api/chaojidanci.js

@@ -59,4 +59,29 @@ export function getWordZhangwo(data = {}) {
     data,
     timeout: 20000
   })
+}
+
+
+export function getDanciChanpinBanbenList(data = {}) {
+  return request({
+    'url': '/app/danci/chanpin/banben/list',
+    headers: {
+      isToken: true
+    },
+    method: 'post',
+    data,
+    timeout: 20000
+  })
+}
+
+export function getDanciChanpinBanbenSave(data = {}) {
+  return request({
+    'url': '/app/danci/chanpin/banben/save',
+    headers: {
+      isToken: true
+    },
+    method: 'post',
+    data,
+    timeout: 20000
+  })
 }

+ 23 - 0
api/shop.js

@@ -84,6 +84,29 @@ export function getAppCp3Info(data = {}) {
 	})
 }
 
+export function getAppCp4Buy(data = {}) {
+	return request({
+		url: "/app/shop/danci/buy",
+		headers: {
+			isToken: true
+		},
+		method: 'post',
+		data,
+		timeout: 20000
+	})
+}
+
+export function getAppCp4Info(data = {}) {
+	return request({
+		url: "/app/shop/danci/info",
+		headers: {
+			isToken: true
+		},
+		method: 'post',
+		data,
+		timeout: 20000
+	})
+}
 
 export function orderPayAli(data = {}) {
 	return request({

+ 1 - 1
config.js

@@ -2,7 +2,7 @@
 // 应用全局配置
 export default   {
   //baseUrl: 'https://goosechampion.com/api',
-   baseUrl: 'https://kf3.mtavip.com/api',
+   baseUrl: 'https://kf1.mtavip.com/api',
   // baseUrl: 'https://goosechampion.com/api/v104',
   // 应用信息
   appInfo: {

+ 14 - 0
pages.json

@@ -169,6 +169,20 @@
 			}
 		},
 		{
+			"path" : "pages/chanpinShop/cp4/intro",
+			"style" :
+			{
+				"navigationStyle": "custom"
+			}
+		},
+		{
+			"path" : "pages/chanpinShop/cp4/dingdan",
+			"style" :
+			{
+				"navigationStyle": "custom"
+			}
+		},
+		{
 			"path" : "pages/chanpinMy/duihuanma",
 			"style" :
 			{

+ 3 - 1
pages/chanpinShop/components/yingyuList.vue

@@ -2,6 +2,7 @@
 	<view class="shop-card-list" v-if="list.length">
     <template  v-for="{chanpin,value:item} in list">
       <cardVue v-if="chanpin == 'ziranpindu'" :item="item" :key="item.chanpinId"></cardVue>
+      <cardVue2 v-if="chanpin == 'chaojidanci'" :item="item" :key="item.chanpinId"></cardVue2>
     </template>
 
 	</view>
@@ -12,7 +13,8 @@
 </template>
 
 <script setup>
-  import cardVue from '../cp3/card.vue';
+import cardVue from '../cp3/card.vue';
+import cardVue2 from '../cp4/card.vue';
 
 	const props = defineProps({
 		list: {

+ 4 - 1
pages/chanpinXuanze/cp3/card.vue

@@ -24,6 +24,7 @@
 
 <script setup>
 import * as pinduHttp from "@/api/chanpinZiRanPinDu.js"
+import * as chaojidanciHttp from "@/api/chaojidanci.js"
 import ezyActiveVue from "@/components/ezyActive/ezyActive.vue";
 import cacheManager from "@/utils/cacheManager.js";
 const porps = defineProps({
@@ -33,11 +34,13 @@ const porps = defineProps({
 })
 // 选择产品等级
 function handleSelect(item) {
+	console.log('item',item);
+
   porps.item.levelList.forEach(citem => {citem.active = false; if (item.dengjiId == citem.dengjiId) {citem.active = true}})
   const opt = {
     dengjiId: item.dengjiId,
   }
-  pinduHttp.getChanpin3DengjiSave(opt).then(res => {
+  pinduHttp.getDanciChanpinBanbenSave(opt).then(res => {
     if (!res.data) {
       return;
     }

+ 35 - 6
pages/chanpinXuanze/cp4/banben.vue

@@ -5,7 +5,12 @@
       <view class="nav-bar-title">选择版本-L6</view>
     </view>
 
-    <view class="ezy-page-body">
+    <view>
+      <view @click="data.isShangce = true">上册</view>
+      <view @click="data.isShangce = false">下册</view>
+    </view>
+
+    <view v-if="data.isShangce" class="ezy-page-body">
       <template v-if="data.banbenList.length">
 		  <view class="xbb-list-box">
 			 <ezyActiveVue class="ezy-list-item-active xbb-item-box" v-for="item in data.banbenList" :key="item.id"
@@ -25,24 +30,48 @@
         </view>
       </template>
     </view>
+
+    <view v-else class="ezy-page-body">
+      <template v-if="data.banbenList2.length">
+        <view class="xbb-list-box">
+          <ezyActiveVue class="ezy-list-item-active xbb-item-box" v-for="item in data.banbenList" :key="item.id"
+                        @aclick="handleSelect(item)">
+            <text class="book-text">{{item.name}}</text>
+            <icon class="arrow-icon"></icon>
+          </ezyActiveVue>
+        </view>
+        <view class="ezy-no-more">没有更多</view>
+      </template>
+      <template v-else>
+        <view class="shiti-frame-box">
+          <view class="ezy-no-sj">
+            <icon></icon>
+            <text>暂无数据</text>
+          </view>
+        </view>
+      </template>
+    </view>
   </view>
 </template>
 
 <script setup>
 import {reactive} from "vue";
 import {onLoad} from "@dcloudio/uni-app"
-import * as shuxueHttp from "@/api/chanpinShuxue.js"
+import * as danciHttp from "@/api/chaojidanci.js"
 import cacheManager from "@/utils/cacheManager.js";
 import ezyActiveVue from "@/components/ezyActive/ezyActive.vue";
 
 const data = reactive({
   dengjiId: null,
-  banbenList: []
+  banbenList: [],
+  banbenList2: [],
+  isShangce: true,
 })
 
 function getBanbenList() {
-  shuxueHttp.getShuxueChanpinBanbenList({dengjiId: data.dengjiId}).then(res => {
-    data.banbenList = res.data;
+  danciHttp.getDanciChanpinBanbenList({dengjiId: data.dengjiId}).then(res => {
+    data.banbenList = res.data.banbenList1;
+    data.banbenList2 = res.data.banbenList2;
   })
 }
 
@@ -56,7 +85,7 @@ function handleSelect(item) {
   const opt = {
     banbenId: item.id,
   }
-  shuxueHttp.getShuxueChanpinBanbenSave(opt).then(res => {
+  danciHttp.getDanciChanpinBanbenSave(opt).then(res => {
     if (!res.data) { return;}
     cacheManager.get('contentInfo') && cacheManager.remove('contentInfo');
     // 跳转

+ 13 - 0
pages/chanpinneirong/index.vue

@@ -5,6 +5,7 @@
 		</view>
 		<chanpin1 v-if="chanpinId==1" ref="chanpin1Ref"></chanpin1>
 		<chanpin2 v-if="chanpinId==2" ref="chanpin2Ref"></chanpin2>
+		<chanpin2 v-if="chanpinId==3" ref="chanpin3Ref"></chanpin2>
 		<chanpin4 v-if="chanpinId==4" ref="chanpin4Ref"></chanpin4>
 
 		<tipMiddleDialog ref="tipDialogRef" :closeFlag='false' :title="tipTitle" @confirm-btn="BanbenConfirmBtn"
@@ -31,6 +32,7 @@
 	} from '../../utils/common';
 	import chanpin1 from './chanpin1'
 	import chanpin2 from './chanpin2'
+	import chanpin3 from './chanpin3'
 	import chanpin4 from './chanpin4'
 	import {
 		banbenImpinfo
@@ -70,6 +72,7 @@
 			CustomTabBar,
 			chanpin1,
 			chanpin2,
+			chanpin3,
 			chanpin4,
 			tipMiddleDialog
 		},
@@ -130,6 +133,10 @@
 						this.$nextTick(() => {
 							this.$refs.chanpin2Ref.initData()
 						})
+					case 3:
+						this.$nextTick(() => {
+							this.$refs.chanpin3Ref.initData()
+						})
 					case 4:
 						this.$nextTick(() => {
 							this.$refs.chanpin4Ref.initData()
@@ -153,6 +160,12 @@
 						this.$nextTick(() => {
 							this.$refs.chanpin2Ref.initData(dengjiId2)
 						})
+						break;	
+							case 3:
+						const banbenId3 = data.banbenId
+						this.$nextTick(() => {
+							this.$refs.chanpin3Ref.initData(banbenId3)
+						})
 						break;
 					case 4:
 						const dengjiId4 = data.dengjiId