liujiaxin vor 1 Woche
Ursprung
Commit
524d8e7b9c
73 geänderte Dateien mit 1891 neuen und 3768 gelöschten Zeilen
  1. 27 10
      pages.json
  2. 393 2482
      pages/home/index.vue
  3. 0 0
      pages/home/shopping.vue
  4. 245 113
      pages/live/index.vue
  5. 343 360
      pages/shopping/index.vue
  6. 612 230
      pages/user/index.vue
  7. 271 0
      pages/user/indexLittle.vue
  8. 0 573
      pages/user/indexold.vue
  9. BIN
      static/address.png
  10. BIN
      static/advice.png
  11. BIN
      static/after_sales.png
  12. BIN
      static/avatar.png
  13. BIN
      static/bg_myclass.png
  14. BIN
      static/bg_video.png
  15. BIN
      static/class_lock.png
  16. BIN
      static/class_play.png
  17. BIN
      static/class_video.png
  18. BIN
      static/collect.png
  19. BIN
      static/collected.png
  20. BIN
      static/completed.png
  21. BIN
      static/course_number.png
  22. BIN
      static/course_number_bg.png
  23. BIN
      static/customer1.png
  24. BIN
      static/footprint.png
  25. BIN
      static/icon_arrow_down.png
  26. BIN
      static/icon_direction_right.png
  27. BIN
      static/icon_direction_right2.png
  28. BIN
      static/icon_myclass.png
  29. BIN
      static/icon_video.png
  30. BIN
      static/integral.png
  31. BIN
      static/layer_share_icon16@3x.png
  32. BIN
      static/menu1.png
  33. BIN
      static/menu2.png
  34. BIN
      static/menu3.png
  35. BIN
      static/menu4.png
  36. BIN
      static/mycoupon.png
  37. BIN
      static/orangetabbar/home.png
  38. BIN
      static/orangetabbar/home_pre.png
  39. BIN
      static/orangetabbar/live.png
  40. BIN
      static/orangetabbar/live_pre.png
  41. BIN
      static/orangetabbar/mine.png
  42. BIN
      static/orangetabbar/mine_pre.png
  43. BIN
      static/orangetabbar/new.png
  44. BIN
      static/orangetabbar/new_pre.png
  45. BIN
      static/orangetabbar/shop.png
  46. BIN
      static/orangetabbar/shop_pre.png
  47. BIN
      static/payment.png
  48. BIN
      static/purple_home_top_bg.png
  49. BIN
      static/qualification.png
  50. BIN
      static/right_arrow_white.png
  51. BIN
      static/sale_file.png
  52. BIN
      static/send_goods.png
  53. BIN
      static/service_file.png
  54. BIN
      static/set.png
  55. BIN
      static/shop_home.png
  56. BIN
      static/shop_meau1.png
  57. BIN
      static/shop_meau10.png
  58. BIN
      static/shop_meau2.png
  59. BIN
      static/shop_meau3.png
  60. BIN
      static/shop_meau4.png
  61. BIN
      static/shop_meau5.png
  62. BIN
      static/shop_meau6.png
  63. BIN
      static/shop_meau7.png
  64. BIN
      static/shop_meau8.png
  65. BIN
      static/shop_meau9.png
  66. BIN
      static/shop_message.png
  67. BIN
      static/shop_service.png
  68. BIN
      static/shop_shopping_car.png
  69. BIN
      static/shop_weixin.png
  70. BIN
      static/shopping_car.png
  71. BIN
      static/sort_icon.png
  72. BIN
      static/sou_goods.png
  73. BIN
      static/video_icon20@2x.png

+ 27 - 10
pages.json

@@ -291,6 +291,17 @@
 				"enablePullDownRefresh": false
 			}
 
+		},{
+			"path": "pages/home/shopping",
+			"style": {
+				"navigationBarTitleText": "",
+				"enablePullDownRefresh": false,
+				"navigationStyle": "custom",
+				"app-plus": {
+					"titleNView": false
+				}
+			}
+
 		}, {
 			"path": "pages/home/h5",
 			"style": {
@@ -1317,23 +1328,29 @@
 			// 	"text": "健康百科"
 			// },
 			// {
-			// 	"pagePath": "pages/shopping/index",
-			// 	"iconPath": "/static/orangetabbar/shop_mall.png",
-			// 	"selectedIconPath": "/static/orangetabbar/shop_mall_sel.png",
+			// 	"pagePath": "pages/home/shopping",
+			// 	"iconPath": "/static/orangetabbar/shop.png",
+			// 	"selectedIconPath": "/static/orangetabbar/shop_pre.png",
 			// 	"text": "健康产品"
 			// },
+			{
+				"pagePath": "pages/shopping/index",
+				"iconPath": "/static/orangetabbar/shop.png",
+				"selectedIconPath": "/static/orangetabbar/shop_pre.png",
+				"text": "健康产品"
+			},
+			{
+				"pagePath": "pages/live/index",
+				"iconPath": "/static/orangetabbar/live.png",
+				"selectedIconPath": "/static/orangetabbar/live_pre.png",
+				"text": "直播"
+			},
 			// {
-			// 	"pagePath": "pages/live/index",
+			// 	"pagePath": "pages/learn/index",
 			// 	"iconPath": "/static/orangetabbar/new.png",
 			// 	"selectedIconPath": "/static/orangetabbar/new_pre.png",
 			// 	"text": "学习"
 			// },
-			{
-				"pagePath": "pages/learn/index",
-				"iconPath": "/static/orangetabbar/new.png",
-				"selectedIconPath": "/static/orangetabbar/new_pre.png",
-				"text": "学习"
-			},
 			// {
 			// 	"pagePath": "pages/message/index",
 			// 	"iconPath": "/static/orangetabbar/new.png",

+ 393 - 2482
pages/home/index.vue

@@ -1,134 +1,100 @@
 <template>
-	<view class="content">
-		<!-- 背景图片 -->
-		<!-- <image class="bg" src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/hp_top_bg.png" mode=""></image> -->
-		<view>
-			<view class="top-inner">
-				<view class="fixed-top-box" :style="{ background: bgColor }">
-					<!-- 这里是状态栏 -->
-					<view class="status_bar" :style="{height: statusBarHeight}"></view>
-					<view class="header-content">
-						<view class="top-title">
-							<view class="name">云联融智</view>
-						</view>
-						<view class="header-search-box">
-							<view class="search-bar" @click="toSearch">
-								<image class="search-icon" src=" /static/search_gray.png" mode="aspectFit"></image>
-								<text class="placeholder">请输入关键字搜索</text>
-							</view>
-							<view class="message-box" @click="navTo('/pages/message/index')">
-								<image class="message-icon" src=" /static/message.png" mode="aspectFit"></image>
-								<view class="red-dot"></view>
-							</view>
-						</view>
-					</view>
-				</view>
-			</view>
-			<!-- 头部间距 -->
-			<view :style="{paddingBottom: headerHeight + 'px'}">
-				<!-- <view class="status_bar" :style="{height: statusBarHeight}"></view> -->
-			</view>
-			<!-- 轮播图 -->
-			<view class="banner-box">
-				<view class="inner">
-					<swiper class="swiper" :indicator-dots="true" :circular="true" :autoplay="true" :interval="3000"
-						:duration="1000" indicator-color="rgba(255, 255, 255, 0.6)" indicator-active-color="#ffffff">
-						<swiper-item class="swiper-item" v-for="(item,index) in advList" :key="index"
-							@click="handleAdvClick(item)">
-							<image :src="item.imageUrl" mode="aspectFill"></image>
-						</swiper-item>
-					</swiper>
+	<view class="home-container">
+		<!-- 顶部背景装饰 -->
+		<view class="top-bg-decoration"></view>
+
+		<!-- 自定义导航栏 -->
+		<view class="nav-bar-fixed" :style="{ paddingTop: statusBarHeight + 'px' }">
+			<view class="nav-content">
+				<view class="product-name">产品名称</view>
+				<view class="search-input-box" @click="toSearch">
+					<image class="search-icon" src="/static/search_gray.png" mode="aspectFit"></image>
+					<text class="placeholder">搜索课程</text>
 				</view>
 			</view>
+		</view>
 
-			<!-- 菜单 -->
-			<view class="menu-content">
-				<view class="menu-box">
-					<view @click="yangshengClick(item)" class="menu-item" :key="index" v-for="(item,index) in yangshengs">
-						<view class="icon-wrap">
-							<image class="icon" :src="item.icon"></image>
+		<!-- 内容区域 -->
+		<scroll-view class="main-content-scroll" scroll-y :style="{ paddingTop: (statusBarHeight + 44) + 'px' }">
+			<!-- Banner 轮播图 -->
+			<view class="banner-section">
+				<swiper class="banner-swiper" :indicator-dots="true" circular autoplay interval="3000" duration="500" 
+					indicator-color="rgba(255,255,255,0.6)" indicator-active-color="#fff">
+					<swiper-item v-for="(item, index) in advList" :key="index" @click="handleAdvClick(item)">
+						<view class="banner-card">
+							<image v-if="item.imageUrl" class="banner-image" :src="item.imageUrl" mode="aspectFill"></image>
 						</view>
-						<view class="title">{{item.title}} </view>
+					</swiper-item>
+				</swiper>
+			</view>
+
+			<!-- 导航网格 -->
+			<view class="nav-grid">
+				<view class="nav-item" v-for="(item, index) in navMenus" :key="index" @click="menuClick(item)">
+					<view class="nav-icon-wrap">
+						<image class="nav-icon" :src="item.icon" mode="aspectFit"></image>
 					</view>
+					<text class="nav-title">{{ item.title }}</text>
 				</view>
 			</view>
 
-			<!-- 最新发布 -->
-			<view class="section-box latest-release">
+			<!-- 热门好课 -->
+			<view class="section-container">
 				<view class="section-header">
-					<view class="left">
-						<view class="vertical-bar"></view>
-						<text class="title">最新发布</text>
-					</view>
-					<view class="more" @click="goClassList(1)">
-						<text>查看全部</text>
-						<image src=" /static/right_arrow_right.png" mode="aspectFit"></image>
+					<text class="section-title">热门好课</text>
+					<view class="more-link" @click="goClassList(1)">
+						<text>更多</text>
+						<image class="arrow-icon" src="/static/right_arrow_right.png" mode="aspectFit"></image>
 					</view>
 				</view>
-				<scroll-view class="horizontal-scroll" scroll-x="true">
-					<view class="scroll-content">
-						<view class="item" v-for="(item, index) in latestList" :key="index" @click="goClass(item.courseId, 1)">
-							<image class="cover" :src="item.imgUrl || ' /static/course_img.png'" mode="aspectFill"></image>
-							<view class="name ellipsis">{{item.courseName}}</view>
-						</view>
-					</view>
-				</scroll-view>
-			</view>
 
-			<!-- 精品录播 -->
-			<view class="section-box featured-courses">
-				<view class="section-header">
-					<view class="left">
-						<view class="vertical-bar"></view>
-						<text class="title">精品录播</text>
+				<!-- 特色大课 -->
+				<view class="featured-course-card" v-if="featuredCourse" @click="goClass(featuredCourse.courseId, 1)">
+					<view class="cover-wrap">
+						<image class="course-cover" :src="featuredCourse.imgUrl || '/static/bg_video.png'" mode="aspectFill"></image>
+						<view class="tag-yangsheng">养生</view>
+						<view class="lesson-badge">
+							<view class="left">
+							<image class="left-icon" src="/static/course_number_bg.png" mode="aspectFit"></image>
+							<image class="play-icon-small" src="/static/course_number.png" mode="aspectFit"></image>
+							<text>第1讲</text>
+							</view>
+							<text>共{{ featuredCourse.lessonCount }}节课</text>
+							<image class="arrow-right-small" src="/static/right_arrow_white.png" mode="aspectFit"></image>
+						</view>
 					</view>
-					<view class="more" @click="goClassList(2)">
-						<text>查看全部</text>
-						<image src=" /static/right_arrow_right.png" mode="aspectFit"></image>
+					<view class="course-info">
+						<view class="course-title">{{ featuredCourse.courseName }}</view>
+						<view class="course-footer">
+							<view class="author-info">
+								<image class="author-avatar" :src="featuredCourse.authorAvatar || '/static/avatar.png'" mode="aspectFill"></image>
+								<text class="author-name">{{ featuredCourse.authorName }}</text>
+							</view>
+							<view class="playback-count">{{ featuredCourse.playCount }}次播放</view>
+						</view>
 					</view>
 				</view>
-				<view class="grid-list">
-					<view class="item" v-for="(item, index) in featuredList" :key="index" @click="goClass(item.courseId, 1)">
-						<view class="cover-box">
-							<image class="cover" :src="item.imgUrl || ' /static/course_img.png'" mode="aspectFill"></image>
-							<view class="overlay bottom-info">
-								<text class="left-text">{{item.playCount}}次播放</text>
-								<text class="right-text">共{{item.lessonCount}}讲</text>
+
+				<!-- 课程列表 -->
+				<view class="course-list">
+					<view class="course-item" v-for="(item, index) in otherCourses" :key="index" @click="goClass(item.courseId, 1)">
+						<image class="item-thumb" :src="item.imgUrl || '/static/course_img.png'" mode="aspectFill"></image>
+						<view class="item-content">
+							<view class="item-title ellipsis-2">{{ item.courseName }}</view>
+							<view class="item-footer">
+								<text class="item-playback">{{ item.playCount }}次播放</text>
+								<view class="study-btn">去学习</view>
 							</view>
 						</view>
-						<view class="name ellipsis">{{item.courseName}}</view>
 					</view>
 				</view>
 			</view>
+			
+			<!-- 底部间距 -->
+			<view class="bottom-safe-area"></view>
+		</scroll-view>
 
-				<!--养生干货-->
-				<!-- <view class="articles" >
-			    	<view class="title-box">
-			    		<view class="title">养生干货</view>
-			    		<view class="more" @click="navTo('/pages_index/index/articleList')">
-			    			<view class="text">更多</view>
-			    			<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/arrow_gray.png"></image>
-			    		</view>
-			    	</view>
-			    	<view class="article-box" v-if="articles.length>0">
-			    		<view class="item" :key="index" @click="navTo('/pages_index/index/articleDetails?articleId='+item.articleId)" v-for="(item,index) in articles">
-			    			<view class="left">
-			    				<view class="title">
-			    					{{item.title}}
-			    				</view>
-			    				<view class="views">
-			    					浏览量 {{item.views}}
-			    				</view>
-			    			</view>
-			    			<view class="right">
-			    				<image :src="item.imageUrl"></image>
-			    			</view>
-			    		</view>
-			    	</view>
-			    </view> -->
-
-			</view>
-
+		<!-- 原有的弹窗组件保留 -->
 		<view class="popup-box" v-if="activityShow">
 			<view class="info-mask" @tap="closeActivity()"></view>
 			<view class="info-form">
@@ -141,2502 +107,447 @@
 </template>
 
 <script>
-	import {
-		courseList,
-		courseListB
-	} from '@/api/class.js'
+	import { courseList } from '@/api/class.js'
 	import zModal from '@/components/z-modal/z-modal.vue'
-	import {
-		getStoreActivity
-	} from '@/api/activity.js'
-	import {
-		getDepartmentList
-	} from '@/api/doctorOrder.js'
-	import {
-		getMenu,
-			getCanvas,
-			getIndexData,
-			getTuiDoctor,
-			getTuiArticle,
-			getTuiDoctorOrder,
-			getCartCount,
-			getConfigByKey
-	} from '@/api/index'
-	import {
-		getDoctorArticleList
-	} from '@/api/doctorArticle.js'
-	import {
-		getArticleList
-	} from '@/api/article.js'
-	import {
-		getStoreConfig
-	} from '@/api/common'
-	// import tabBg from "https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/tab_bg.png"
-	import freeAudio from '@/components/chengpeng-audio/free-audio.vue'
-	import Menu from '@/components/Menu.vue'
-	import HotProduct from './components/HotProduct.vue'
-	import NewProduct from './components/NewProduct.vue'
-	import TuiProduct from '@/components/tuiProduct.vue'
-	import {
-		getUserInfo,
-		bindPromoter
-	} from '@/api/user'
+	import { getStoreActivity } from '@/api/activity.js'
+	import { getIndexData, bindPromoter } from '@/api/index'
+	import { getUserInfo } from '@/api/user'
+
 	export default {
 		components: {
-			zModal,
-			freeAudio,
-			Menu,
-			HotProduct,
-			NewProduct,
-			TuiProduct
+			zModal
 		},
 		data() {
 			return {
-				isLike: false,
-				classList: [],
-				btnGroup: [{
-					text: '取消',
-					color: '#FFFFFF',
-					bgColor: '#999999',
-					width: '150rpx',
-					height: '80rpx',
-					shape: 'fillet',
-					eventName: 'cancle'
-				}, {
-					text: '确定',
-					color: '#FFFFFF',
-					bgColor: '#5B37FD ',
-					width: '150rpx',
-					height: '80rpx',
-					shape: 'fillet',
-					eventName: 'sure'
-				}],
-				tuiModalControl: false,
-				activity: null,
-				activityShow: false,
-				newProductList: [],
-				hotProductList: [],
-				tuiProductList: [],
-				menus: [],
-				canvas: [],
-				allDoctorTitle: "全部医生",
-				topLen: 0,
-				deptId: 0,
-				depts: [],
-				docTab: 1,
-				top: 0,
-				cartCount: 0,
-				doctorOrderList: [],
-				orderType: 0,
-				cateId: null,
-				articleList: [],
-				advList: [],
-				doctorList: [],
-				articleCateList: [],
-				doctocArticles: [], //养生讲堂
-				articles: [], //养生干货
-				// 状态栏的高度
-				statusBarHeight: uni.getStorageSync('menuInfo') ? uni.getStorageSync('menuInfo').statusBarHeight : 20,
-				headerHeight: 88, // 默认高度,后续动态计算
-				tabBg: "https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/tab_bg.png", // tab切换背景
-				// 问诊案例类型
-				orderTypes: [{
-					name: '全部',
-					id: 0,
-				}, {
-					name: '图文',
-					id: 1,
-				}, {
-					name: '语音',
-					id: 2,
-				}],
-				// 限时消息是否显示
-				messageShow: true,
-				yangshengs: [{
-						id: "1",
-						title: "精选课程",
-						page: "/pages_course/teacherClassroom?type=1",
-						icon: "/static/menu1.png",
-					},
-					{
-						id: "2",
-						title: "分享社区",
-						page: "/pages_index/index/articleList",
-						icon: "/static/menu2.png",
-					},
-					{
-						id: "3",
-						title: "付费课程",
-						page: "/pages_course/teacherClassroom?type=2",
-						icon: "/static/menu3.png",
-					},
-					{
-						id: "4",
-						title: "全部课程",
-						page: "/pages_course/teacherClassroom",
-						icon: "/static/menu4.png",
-					}
+				statusBarHeight: uni.getSystemInfoSync().statusBarHeight,
+				advList: [
+					{ imageUrl: '', advUrl: '', showType: 1 },
+					{ imageUrl: '', advUrl: '', showType: 1 }
 				],
-				latestList: [
-					{ courseId: 1, courseName: '中医降脂养肝课', imgUrl: ' /static/famous_doctor_img.png' },
-					{ courseId: 2, courseName: '五脏养生操', imgUrl: ' /static/famous_doctor_img2.png' },
-					{ courseId: 3, courseName: '杜丁秋冬肠胃养生课', imgUrl: ' /static/course_img.png' }
+				navMenus: [
+					{ title: '药品商城', icon: '/static/menu1.png',  linkUrl: '/pages/shopping/index', linkType: 1 },
+					{ title: '热门好课', icon: '/static/menu2.png',linkUrl: '/pages_course/teacherClassroom?type=1', linkType: 1 },
+					{ title: '我的课程', icon: '/static/menu3.png',  linkUrl: '/pages_course/teacherClassroom?type=2', linkType: 1 },
+					{ title: '专业客服', icon: '/static/menu4.png',  linkUrl: '/pages/message/index', linkType: 1 }
 				],
-				featuredList: [
-					{ courseId: 4, courseName: '中医降脂养肝课', imgUrl: ' /static/famous_doctor_img.png', playCount: '8.1万', lessonCount: 15 },
-					{ courseId: 5, courseName: '五脏养生操', imgUrl: ' /static/famous_doctor_img2.png', playCount: '8.1万', lessonCount: 15 },
-					{ courseId: 6, courseName: '杜丁秋冬肠胃养生课', imgUrl: ' /static/course_img.png', playCount: '8.1万', lessonCount: 15 },
-					{ courseId: 7, courseName: '冬季养生', imgUrl: ' /static/famous_doctor_img.png', playCount: '8.1万', lessonCount: 15 }
+				featuredCourse: {
+					courseId: 4,
+					courseName: '你和合理膳食还有多少距离?',
+					imgUrl: '/static/bg_video.png',
+					lessonCount: 30,
+					authorName: '健康大讲堂',
+					authorAvatar: '/static/avatar.png',
+					playCount: '8.1万'
+				},
+				otherCourses: [
+					{ courseId: 5, courseName: '脑梗塞是帕金森病的发病因素吗?', imgUrl: '/static/famous_doctor_img.png', playCount: '25862' },
+					{ courseId: 6, courseName: '合理的运动与健康', imgUrl: '/static/famous_doctor_img2.png', playCount: '25862' },
+					{ courseId: 7, courseName: '合理的运动与健康', imgUrl: '/static/course_img.png', playCount: '25862' },
+					{ courseId: 8, courseName: '合理的运动与健康', imgUrl: '/static/famous_doctor_img.png', playCount: '25862' }
 				],
-				userinfoa: [],
-				isuser: false,
-				menvKey: [],
-				classListb:{}
-			}
-			// this.getStoreActivity();
-		},
-		onLoad(option) {
-			if (option.userCode != null) {
-				uni.setStorageSync('userCode', option.userCode);
-				if (this.utils.checkLoginState()) {
-					this.getUserInfo();
-				}
-			}
-			if (option.hasOwnProperty('q') && option.q) {
-				// 通过下面这步解码,可以拿到url的值
-				const url = decodeURIComponent(option.q)
-				this.url = url;
-				// // 对url中携带的参数提取处理
-				const obj = this.utils.urlToObj(url)
-				uni.setStorageSync('userCode', obj.userCode);
-				if (this.utils.checkLoginState()) {
-					this.getUserInfo();
-				}
-			}
-			// this.getStoreActivity()
-		},
-		// 暂停所有音频(一般用于页面切换时停止正在播放的音频)
-		onUnload() { //普通页面在 onUnload 生命周期中执行
-			uni.$emit('stop')
-		},
-		onHide() { //tabBar页面在onHide生命周期中执行
-			uni.$emit('stop')
-		},
-		onPageScroll(e) {
-			//console.log(e)
-			this.top = e.scrollTop;
-		},
-		mounted() {
-			this.getCourseList()
-			//this.getDepartmentList();
-			this.calculateHeaderHeight();
-		},
-		onShareAppMessage(res) {
-			return {
-				title: '盛世生活工具A-您的专属健康解决方案',
-				path: `/pages/common/launch`,
-				imageUrl: this.$store.state.imgpath+'/app/image/logo.png'//分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
-			}
-		},
-		onReachBottom() {
-			// console.log("onReachBottom")
-			this.$refs.tuiProduct.getTuiProducts();
-		},
-		//分享到朋友圈
-		onShareTimeline(res) {
-			return {
-				title: '盛世生活工具A-您的专属健康解决方案',
-				query: '', //页面参数
-				imageUrl: this.$store.state.imgpath+'/app/image/logo.png'//分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
+				activityShow: false,
+				activity: null,
+				tuiModalControl: false,
+				btnGroup: [
+					{ text: '取消', color: '#FFFFFF', bgColor: '#999999', width: '150rpx', height: '80rpx', shape: 'fillet', eventName: 'cancle' },
+					{ text: '确定', color: '#FFFFFF', bgColor: '#5B37FD', width: '150rpx', height: '80rpx', shape: 'fillet', eventName: 'sure' }
+				]
 			}
 		},
-		computed: {
-			// 计算属性的 getter
-			bgColor: function() {
-				var top = this.top / 30;
-				return 'rgba(255,255,255, ' + top + ')';
-			},
-			imgPath() {
-			  return this.$store.state.imgpath
-			},
-			isDrug() {
-				return this.$store.state.isDrug
-			},
-		},
-		onShow() {
-			this.getMenu();
-			this.getIndexData()
-			//this.getTuiDoctorOrder();
-			// console.log(uni.getStorageSync('isLocation'))
-			// if(uni.getStorageSync('isLocation')==""){
-			// 	this.getLocation();
-			// }
-			if (uni.getStorageSync('AppToken')) {
-				this.getUserInfo()
-			} else {
-				this.isuser = true
-			}
-			if (this.utils.checkLoginState()) {
-				this.getCartCount();
-			}
-			this.getStoreConfig();
-			//this.getTuiDoctor()
-			this.getCanvas();
-			this.getDoctorArticleList();
-			this.getArticleList();
-			this.getshowmanv()
+		onLoad() {
+			this.getIndexData();
+			this.getCourseList();
 		},
 		methods: {
-			likeClick(item){
-				this.isLike = !this.isLike
-			},
-			calculateHeaderHeight() {
-				const query = uni.createSelectorQuery().in(this);
-				query.select('.fixed-top-box').boundingClientRect(data => {
-					if (data) {
-						this.headerHeight = data.height;
-					}
-				}).exec();
-			},
 			getCourseList() {
 				courseList().then(res => {
 					if (res.code == 200 && res.data && res.data.length > 0) {
-						console.log('公域',res.data)
-						this.classList = res.data.slice(0, 3)
-					} else {
-						// 模拟数据
-						this.classList = [
-							{
-								courseId: 1,
-								courseName: '第一期超nice的健康博主大盘点,带你领略健康生活',
-								imgUrl: ' /static/course_img.png'
-							},
-							{
-								courseId: 2,
-								courseName: '家庭医生健康顾问服务,全家人的健康保障',
-								imgUrl: ' /static/course_img.png'
-							}
-						]
-					}
-				}).catch(() => {
-					// 接口报错也显示模拟数据
-					this.classList = [
-						{
-							courseId: 1,
-							courseName: '第一期超nice的健康博主大盘点,带你领略健康生活',
-							imgUrl: ' /static/course_img.png'
-						}
-					]
-				})
-			},
-			goClass(id,type) {
-				// console.log(id)
-				uni.navigateTo({
-					url:'/pages_course/learn?courseId='+id+'&type='+type
-				})
-			},
-			goClassList(type) {
-				uni.navigateTo({
-					url: '/pages_course/teacherClassroom?type='+type
-				})
-			},
-			getshowmanv() {
-				const data = {
-					key: "store.appShow"
-				}
-				getConfigByKey(data).then(res => {
-					if (res.code == 200) {
-						this.menvKey = JSON.parse(res.data)
-						// console.log('排序', this.menvKey[0])
-					}
-				})
-			},
-			getUserInfo() {
-				getUserInfo().then(
-					res => {
-						if (res.code == 200) {
-							if (res.user != null) {
-								this.userinfoa = res.user
-								// if(res.user.isPromoter==null||res.user.isPromoter==0){
-								// 	this.tuiModalControl=true
-								// }
-							}
-						} else {
-							uni.showToast({
-								icon: 'none',
-								title: "请求失败",
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			cancleTui(e) {
-				this.tuiModalControl = false
-			},
-			submitTui(e) {
-				// console.log(e)
-				if (e.inputText == null || e.inputText == "") {
-					uni.showToast({
-						icon: 'none',
-						title: "请输入邀请码",
-					});
-					return;
-				}
-				var data = {
-					userCode: e.inputText
-				};
-				bindPromoter(data).then(
-					res => {
-						if (res.code == 200) {
-							uni.showToast({
-								icon: 'none',
-								title: res.msg,
-							});
-							this.tuiModalControl = false
-						} else {
-							uni.showToast({
-								icon: 'none',
-								title: res.msg,
-							});
-						}
-					},
-					rej => {}
-				);
-
-			},
-			bindload: function(detail) {},
-			binderror: function(detail) {},
-			closeActivity() {
-				this.activityShow = false;
-				// uni.setStorageSync(this.activity.activityId,null);
-			},
-			getStoreActivity() {
-				let data = {}
-				getStoreActivity(data).then(res => {
-					this.activity = res.activity;
-					if (this.activity != null) {
-						// if(uni.getStorageSync(this.activity.activityId)!=null)
-						// {
-						// 	uni.setStorageSync(this.activity.activityId,1);
-						// 	this.activityShow=true;
-						// }
-						// else{
-						// 	this.activityShow=false;
-						// }
-						this.activityShow = true;
-					} else {
-						this.activityShow = false;
+						// 实际数据更新
 					}
-				})
-			},
-			showActivity() {
-				this.activityShow = false;
-				uni.navigateTo({
-					url: '/pages_shopping/shopping/activityDetails?activityId=' + this.activity.activityId
-				})
+				});
 			},
-			menuClick(item) {
-				if (item.linkType == 1) {
-					if (item.linkUrl == "/pages/shopping/index") {
-						uni.switchTab({
-							url: item.linkUrl
-						})
-					} else if (item.linkUrl == "/pages/healthy/index") {
-						uni.switchTab({
-							url: item.linkUrl
-						})
-					} else {
-
-						uni.navigateTo({
-							url: item.linkUrl
-						})
+			getIndexData() {
+				getIndexData().then(res => {
+					if (res.code == 200 && res.data.advList && res.data.advList.length > 0) {
+						this.advList = res.data.advList;
 					}
-
-				} else if (item.linkType == 0) {
-					uni.showToast({
-						icon: 'none',
-						title: "开发中...",
-					});
-				}
-			},
-			goDev() {
-				uni.showToast({
-					icon: 'none',
-					title: "开发中...",
 				});
 			},
 			handleAdvClick(item) {
-				console.log(item);
-				if (item.showType == 1) {
-					uni.setStorageSync('url', item.advUrl);
-					uni.navigateTo({
-						url: "h5"
-					})
-				} else if (item.showType == 2) {
-					uni.navigateTo({
-						url: item.advUrl
-					})
-				} else if (item.showType == 3) {
-					uni.setStorageSync('content', item.content);
-					uni.navigateTo({
-						url: "content"
-					})
+				if (item.advUrl) {
+					uni.navigateTo({ url: item.advUrl });
 				}
 			},
-			deptChange(item) {
-				this.deptId = item.departmentId;
-				this.getTuiDoctor();
-			},
-			getMenu() {
-				this.menus = [];
-				getMenu().then(res => {
-					if (res.code == 200) {
-						// for (var i = 0; i < res.data.length; i++) {
-						// 	const item=res.data[i];
-						// if(item.menuName.indexOf('健康百科')>=0 || item.menuName.indexOf('健康自测')>=0 
-						// || item.menuName.indexOf('健康档案')>=0 ||item.menuName.indexOf('用药咨询')>=0){
-						// 	this.menus.push(item);
-						// }
-						// }
-						// console.log('图标', res.data)
-						// const menuNames = ['健康百科', '健康自测', '健康档案', '药品商城', '领券中心', '会员'];
-						this.menus = res.data
-						// this.menus = res.data.filter(item => menuNames.some(menuName => item.menuName.includes(menuName)) );
-					} else {
-
-					}
-				});
-			},
-			getCanvas() {
-				getCanvas().then(res => {
-					if (res.code == 200 && res.data && res.data.json) {
-						// console.log(res.data)
-						this.canvas = JSON.parse(res.data.json)
-					}
-				});
-			},
-			getDepartmentList() {
-				this.depts = [];
-				getDepartmentList().then(res => {
-					if (res.code == 200) {
-						var allDept = {
-							departmentId: 0,
-							departmentName: "全部"
-						}
-						this.depts.push(allDept);
-						this.depts = this.depts.concat(res.data);
-					} else {
-						uni.showToast({
-							icon: 'none',
-							title: "请求失败",
-						});
-					}
-				});
-			},
-			getTuiDoctor() {
-				let data = {
-					departmentId: this.deptId,
-					doctorType: this.docTab
-				};
-				getTuiDoctor(data).then(
-					res => {
-						if (res.code == 200) {
-							this.doctorList = res.data;
-						} else {
-							uni.showToast({
-								icon: 'none',
-								title: "请求失败",
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			docTabChange(val) {
-				if (val == 1) {
-					this.allDoctorTitle = "全部医师"
-				}
-				if (val == 2) {
-					this.allDoctorTitle = "全部药师"
-				}
-				if (val == 3) {
-					this.allDoctorTitle = "全部营养师"
+			menuClick(item) {
+				if (item.linkType == 1) {
+					uni.navigateTo({ url: item.linkUrl });
 				}
-				this.docTab = val;
-				this.getTuiDoctor();
-			},
-			showImg(urls) {
-				var imgArr = urls.split(',');
-				//预览图片
-				uni.previewImage({
-					urls: imgArr,
-					current: imgArr[0]
-				});
-			},
-			getStoreConfig() {
-				getStoreConfig().then(
-					res => {
-						if (res.code == 200) {
-							uni.setStorageSync('config', JSON.stringify(res.data));
-						}
-					},
-					rej => {}
-				);
-
-			},
-			goAuthUrl(url) {
-				this.utils.isLogin().then(res => {
-					if (res) {
-						uni.navigateTo({
-							url: url
-						})
-					}
-				})
-			},
-			// 跳转页面
-			navTo(url) {
-				uni.navigateTo({
-					url: url
-				})
-			},
-			getLocation() {
-				var that = this;
-				uni.authorize({
-					scope: 'scope.userLocation',
-					success() {
-						uni.getLocation({
-							type: 'gcj02', //腾讯地图使用gcj02获取位置坐标
-							success: function(res) {
-								uni.setStorageSync('isLocation', 1);
-								uni.setStorageSync('lng', res.longitude);
-								uni.setStorageSync('lat', res.latitude);
-							},
-						})
-					},
-					fail(err) {
-						console.log(err)
-					}
-				})
-			},
-			getIndexData() {
-				let data = {
-				};
-				getIndexData(data).then(
-					res => {
-						if (res.code == 200) {
-							this.advList = res.data.advList;
-							this.articleCateList = res.data.articleCateList;
-							if (this.articleCateList != null && this.articleCateList.length > 0) {
-								this.cateId = this.articleCateList[0].cateId;
-								this.getTuiArticle()
-							}
-							this.tuiProductList = res.data.tuiProductList
-							this.newProductList = res.data.newProductList
-							this.hotProductList = res.data.hotProductList
-						} else {
-							uni.showToast({
-								icon: 'none',
-								title: "请求失败",
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			getCartCount() {
-				this.utils.isLogin().then(res => {
-					if (res) {
-						getCartCount().then(
-							cartRes => {
-								if (cartRes.code == 200) {
-									this.cartCount = cartRes.data;
-								}
-							},
-							rej => {}
-						);
-					}
-				})
-			},
-			getTuiArticle() {
-				let data = {
-					cateId: this.cateId
-				};
-				getTuiArticle(data).then(
-					res => {
-						if (res.code == 200) {
-							this.articleList = res.data;
-						} else {
-							uni.showToast({
-								icon: 'none',
-								title: "请求失败",
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			getTuiDoctorOrder() {
-				let data = {
-					orderType: this.orderType
-				};
-				getTuiDoctorOrder(data).then(
-					res => {
-						if (res.code == 200) {
-							this.doctorOrderList = res.data;
-						} else {
-							uni.showToast({
-								icon: 'none',
-								title: "请求失败",
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			showArticle(item) {
-				uni.navigateTo({
-					url: '../healthy/detail?articleId=' + item.articleId
-				})
-			},
-			showProduct(item) {
-				uni.navigateTo({
-					url: '../shopping/productDetails?productId=' + item.productId
-				})
 			},
-			// 顶部搜索
-			toSearch() {
+			goClass(id, type) {
 				uni.navigateTo({
-					url: './productSearch'
-				})
-			},
-			// 健康知识选中
-			articleCateChange(item) {
-				this.cateId = item.cateId;
-				this.getTuiArticle();
-			},
-			// 问诊案例选中
-			orderTypeChange(item) {
-				this.orderType = item.id;
-				console.log(this.orderType)
-				this.getTuiDoctorOrder();
-			},
-			// 关闭限时消息
-			closeMsg() {
-				this.messageShow = false
+					url: '/pages_course/learn?courseId=' + id + '&type=' + type
+				});
 			},
-			// 查看全部
-			viewAll(url) {
+			goClassList(type) {
 				uni.navigateTo({
-					url: '/pages/home/' + url,
+					url: '/pages_course/teacherClassroom?type=' + type
 				});
 			},
-			shopDoctor(item) {
-				console.log(item);
-				uni.navigateTo({
-					url: "/pages_doctor/doctorDetail?doctorId=" + item.doctorId
-				})
+			toSearch() {
+				uni.navigateTo({ url: './productSearch' });
 			},
-			switchTo(url) {
-				uni.switchTab({
-					url: url
-				})
-				return
+			closeActivity() { this.activityShow = false; },
+			showActivity() {
+				this.activityShow = false;
+				uni.navigateTo({ url: '/pages_shopping/shopping/activityDetails?activityId=' + this.activity.activityId });
 			},
-			yangshengClick(item) {
-				if (item.page == "") {
-					uni.showToast({
-						icon: "none",
-						title: '暂无更多'
-					})
+			cancleTui() { this.tuiModalControl = false; },
+			submitTui(e) {
+				if (!e.inputText) {
+					uni.showToast({ icon: 'none', title: "请输入邀请码" });
 					return;
 				}
-				uni.navigateTo({
-					url: item.page
-				})
-			},
-			// 在线问诊
-			openIm() {
-				uni.navigateTo({
-					url: '/pages_doctor/doctorOrderIM?orderId=10'
-				})
-			},
-			getDoctorArticleList() {
-				//联网加载数据
-				var that = this;
-				var data = {
-					pageNum: 1,
-					pageSize: 10
-				};
-				getDoctorArticleList(data).then(res => {
-					if (res.code == 200 && res.data && res.data.list && res.data.list.length > 0) {
-						this.doctocArticles = res.data.list;
-					} else {
-						// 模拟数据
-						this.doctocArticles = [
-							{
-								articleId: 1,
-								title: '中医降脂养肝课',
-								imageUrl: ' /static/famous_doctor_img.png',
-								views: 3724,
-								doctorName: '崔医生',
-								avatar: ' /static/avatar.png'
-							},
-							{
-								articleId: 2,
-								title: '春季养生与防病',
-								imageUrl: ' /static/famous_doctor_img2.png',
-								views: 2850,
-								doctorName: '崔医生',
-								avatar: ' /static/avatar.png'
-							}
-						]
-					}
-				}).catch(() => {
-					// 接口报错也显示模拟数据
-					this.doctocArticles = [
-						{
-							articleId: 1,
-							title: '中医降脂养肝课',
-							imageUrl: ' /static/famous_doctor_img.png',
-							views: 3724,
-							doctorName: '崔医生',
-							avatar: ' /static/avatar.png'
-						}
-					]
-				});
-			},
-			getArticleList() {
-				//联网加载数据
-				var that = this;
-				var data = {
-					isTui: 1,
-					pageNum: 1,
-					pageSize: 10,
-				};
-				getArticleList(data).then(res => {
+				bindPromoter({ userCode: e.inputText }).then(res => {
 					if (res.code == 200) {
-						this.articles = res.data.list;
-					} else {
-						uni.showToast({
-							icon: 'none',
-							title: "请求失败",
-						});
+						uni.showToast({ icon: 'none', title: res.msg });
+						this.tuiModalControl = false;
 					}
 				});
-			},
+			}
 		}
 	}
 </script>
 
 <style lang="scss">
-	.fixed-top-box {
+	.home-container {
+		min-height: 100vh;
+		background-color: #FFFFFF;
+		position: relative;
+	}
+
+	.top-bg-decoration {
+		position: absolute;
+		top: 0;
+		left: 0;
 		width: 100%;
+		height: 450rpx;
+		background: linear-gradient(180deg, #F0F2FF 0%, rgba(255, 255, 255, 0) 100%);
+		z-index: 0;
+	}
+
+	/* 导航栏 */
+	.nav-bar-fixed {
 		position: fixed;
 		top: 0;
 		left: 0;
-		z-index: 1000;
-		transition: all 0.5s;
-		background-color: #fff;
-
-		.status_bar {
-			width: 100%;
-		}
+		width: 100%;
+		z-index: 100;
+		background-color: transparent;
 
-		.header-content {
-			padding: 10rpx 30rpx 20rpx;
+		.nav-content {
+			height: 44px;
+			display: flex;
+			align-items: center;
+			padding: 0 30rpx;
+
+			.product-name {
+				font-size: 42rpx;
+				font-weight: bold;
+				color: #1A1A1A;
+				margin-right: 24rpx;
+				flex-shrink: 0;
+			}
 
-			.top-title {
-				height: 88upx;
+			.search-input-box {
+				width: 302rpx;
+				height: 68rpx;
+				background: #FFFFFF;
+				border-radius: 34rpx;
 				display: flex;
 				align-items: center;
-				justify-content: flex-start;
+				padding: 0 28rpx;
+				margin-right: 24rpx;
+				box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
 
-				.name {
-					font-size: 44rpx;
-					font-family: PingFang SC;
-					font-weight: bold;
-					color: #1A1A1A;
+				.search-icon {
+					width: 30rpx;
+					height: 30rpx;
+					margin-right: 14rpx;
 				}
-			}
 
-			.header-search-box {
-				display: flex;
-				align-items: center;
-				justify-content: space-between;
-				margin-top: 10rpx;
+				.placeholder {
+					font-size: 28rpx;
+					color: #BBBBBB;
+				}
+			}
 
-				.search-bar {
-					flex: 1;
-					height: 72rpx;
-					background: #F5F6F8;
-					border-radius: 36rpx;
-					display: flex;
-					align-items: center;
-					padding: 0 30rpx;
-					margin-right: 20rpx;
+		
+		}
+	}
 
-					.search-icon {
-						width: 32rpx;
-						height: 32rpx;
-						margin-right: 16rpx;
-					}
+	.main-content-scroll {
+		height: 100vh;
+		position: relative;
+		z-index: 1;
+	}
 
-					.placeholder {
-						font-size: 28rpx;
-						color: #999;
-					}
-				}
+	/* Banner */
+	.banner-section {
+		padding: 20rpx 30rpx;
 
-				.message-box {
-					position: relative;
-					width: 56rpx;
-					height: 56rpx;
-					display: flex;
-					align-items: center;
-					justify-content: center;
+		.banner-swiper {
+			height: 233rpx;
+			border-radius: 28rpx;
+			overflow: hidden;
+		}
 
-					.message-icon {
-						width: 48rpx;
-						height: 48rpx;
-					}
+		.banner-card {
+			width: 100%;
+			height: 100%;
+			background: linear-gradient(135deg, #FF4D4D 0%, #FF8533 100%);
+			position: relative;
+		}
 
-					.red-dot {
-						position: absolute;
-						top: 4rpx;
-						right: 4rpx;
-						width: 16rpx;
-						height: 16rpx;
-						background: #FF4D4F;
-						border-radius: 50%;
-						border: 2rpx solid #fff;
-					}
-				}
-			}
+		.banner-image {
+			position: absolute;
+			width: 100%;
+			height: 100%;
+			z-index: 1;
 		}
 	}
 
-	.content {
-		width: 100%;
-		position: relative;
-		background-color: #fff;
-		min-height: 100vh;
-
-		.banner-box {
-			padding: 0 30upx;
-			margin-top: 20rpx;
+	/* 导航网格 */
+	.nav-grid {
+		display: flex;
+		justify-content: space-between;
+		padding: 40rpx 50rpx;
 
-			.inner {
-				width: 100%;
-				height: 300upx;
-				border-radius: 20upx;
-				overflow: hidden;
+		.nav-item {
+			display: flex;
+			flex-direction: column;
+			align-items: center;
 
-				.swiper,
-				.swiper-item,
-				.swiper-item image {
-					width: 100%;
+			.nav-icon-wrap {
+				width: 104rpx;
+				height: 104rpx;
+				display: flex;
+				align-items: center;
+				justify-content: center;
+				margin-bottom: 20rpx;
+				.nav-icon {
+					width:100%;
 					height: 100%;
 				}
 			}
-		}
 
-		.menu-content {
-			background-color: transparent;
-			padding: 40upx 30upx 20upx;
+			.nav-title {
+				font-size: 28rpx;
+				color: #333333;
+				font-weight: 500;
+			}
 		}
+	}
+
+	/* 章节容器 */
+	.section-container {
+		padding: 20rpx 30rpx;
 
-		.menu-box {
+		.section-header {
 			display: flex;
-			align-items: center;
 			justify-content: space-between;
+			align-items: center;
+			margin-bottom: 30rpx;
 
-			.menu-item {
+			.section-title {
+				font-size: 38rpx;
+				font-weight: bold;
+				color: #1A1A1A;
+			}
+
+			.more-link {
 				display: flex;
-				flex-direction: column;
 				align-items: center;
-				width: 25%;
+				font-size: 28rpx;
+				color: #BBBBBB;
+
+				.arrow-icon {
+					width: 28rpx;
+					height: 28rpx;
+					margin-left: 4rpx;
+				}
+			}
+		}
+	}
 
-				.icon-wrap {
-					width: 100upx;
-					height: 100upx;
-					border-radius: 50%;
+	/* 特色大课卡片 */
+	.featured-course-card {
+		background: #FFFFFF;
+		border-radius: 28rpx;
+		overflow: hidden;
+		box-shadow: 0 6rpx 30rpx rgba(0, 0, 0, 0.06);
+		margin-bottom: 40rpx;
+
+		.cover-wrap {
+			position: relative;
+			width: 100%;
+			height: 420rpx;
+
+			.course-cover {
+				width: 100%;
+				height: 100%;
+			}
+
+			.tag-yangsheng {
+				position: absolute;
+				top: 0;
+				left: 0;
+				padding: 10rpx 28rpx;
+				background: #5B37FD;
+				color: #FFFFFF;
+				font-size: 26rpx;
+				border-bottom-right-radius: 24rpx;
+			}
+
+			.lesson-badge {
+				padding-right: 16rpx;
+				position: absolute;
+				bottom: 24rpx;
+				right: 24rpx;
+			background: rgba(0,0,0,0.5);
+				backdrop-filter: blur(6px);
+				border-radius: 24rpx;
+				display: flex;
+				height: 48rpx;
+				align-items: center;
+				color: #FFFFFF;
+				font-size: 26rpx;
+				.left{
 					display: flex;
 					align-items: center;
-					justify-content: center;
-					margin-bottom: 16upx;
-
-					.icon {
-						width: 88upx;
-						height: 88upx;
-					}
+					padding-left: 16rpx;
+					width: 144rpx;
+					height: 48rpx;
+					position: relative;
+					.left-icon{
+					position: absolute;
+					left: 0;
+					top: 0;
+					width: 144rpx;
+					height: 48rpx;
+					z-index: -1;
+				}
+				.play-icon-small {
+					width: 30rpx;
+					height: 30rpx;
+					margin-right: 4rpx;
 				}
-
-				.title {
-					font-size: 26upx;
-					color: #333;
-					font-family: PingFang SC;
-					font-weight: 500;
+				}
+				
+				.arrow-right-small {
+					width: 20rpx;
+					height: 20rpx;
 				}
 			}
 		}
 
-		.section-box {
-			padding: 20rpx 30rpx;
+		.course-info {
+			padding: 30rpx;
+				background: #68686A;
+				color: #fff;
+			.course-title {
+				font-size: 36rpx;
+				font-weight: bold;
+				margin-bottom: 28rpx;
+			}
 
-			.section-header {
+			.course-footer {
 				display: flex;
 				justify-content: space-between;
 				align-items: center;
-				margin-bottom: 24rpx;
 
-				.left {
+				.author-info {
 					display: flex;
 					align-items: center;
 
-					.vertical-bar {
-						width: 8rpx;
-						height: 32rpx;
-						background: #5C4BFF;
-						border-radius: 4rpx;
+					.author-avatar {
+						width: 52rpx;
+						height: 52rpx;
+						border-radius: 50%;
 						margin-right: 16rpx;
 					}
 
-					.title {
-						font-size: 36rpx;
-						font-weight: bold;
-						color: #1A1A1A;
+					.author-name {
+						font-size: 28rpx;
 					}
 				}
 
-				.more {
-					display: flex;
-					align-items: center;
-
-					text {
-						font-size: 24rpx;
-						color: #999;
-						margin-right: 8rpx;
-					}
-
-					image {
-						width: 48rpx;
-						height: 48rpx;
-					}
+				.playback-count {
+					font-size: 28rpx;
 				}
 			}
+		}
+	}
 
-			.horizontal-scroll {
-				width: 100%;
-				white-space: nowrap;
-
-				.scroll-content {
-					display: flex;
-
-					.item {
-						width: 220rpx;
-						margin-right: 20rpx;
-						flex-shrink: 0;
-
-						.cover {
-							width: 220rpx;
-							height: 160rpx;
-							border-radius: 12rpx;
-							background: #f0f0f0;
-						}
-
-						.name {
-							margin-top: 12rpx;
-							font-size: 26rpx;
-							color: #333;
-							text-align: center;
-						}
-					}
-				}
-			}
-
-			.grid-list {
-				display: flex;
-				flex-wrap: wrap;
-				justify-content: space-between;
-
-				.item {
-					width: 334rpx;
-					margin-bottom: 30rpx;
-
-					.cover-box {
-						position: relative;
-						width: 100%;
-						height: 190rpx;
-						border-radius: 16rpx;
-						overflow: hidden;
-
-						.cover {
-							width: 100%;
-							height: 100%;
-							background: #f0f0f0;
-						}
-
-						.overlay {
-							position: absolute;
-							bottom: 0;
-							left: 0;
-							width: 100%;
-							height: 60rpx;
-							background: linear-gradient(to top, rgba(0,0,0,0.5), transparent);
-							display: flex;
-							align-items: center;
-							justify-content: space-between;
-							padding: 0 16rpx;
-							color: #fff;
-							font-size: 22rpx;
-						}
-					}
-
-					.name {
-						margin-top: 16rpx;
-						font-size: 28rpx;
-						color: #333;
-						font-weight: 500;
-					}
-				}
-			}
-		}
-
-		.index-cont {
-			box-sizing: border-box;
-			padding: 0 20upx 120rpx;
-
-			.pub-item {
-				background: #FFFFFF;
-				border-radius: 16upx;
-				margin-bottom: 20upx;
-
-				.tabs {
-					width: 100%;
-					display: flex;
-					align-items: center;
-					justify-content: flex-start;
-					height: 110rpx;
-					background-color: #F0F3F4;
-
-					.tab {
-						height: 110rpx;
-						display: flex;
-						align-items: center;
-						justify-content: center;
-						position: relative;
-						flex: 1;
-
-						.img {
-							z-index: 1;
-							position: absolute;
-							top: 0rpx;
-							left: 0rpx;
-							width: 100%;
-							height: 100%;
-						}
-
-						.inner {
-							z-index: 2;
-
-							.title {
-								font-size: 32upx;
-								font-family: PingFang SC;
-								font-weight: bold;
-								color: #666666;
-							}
-
-							.active {
-								color: #5B37FD ;
-							}
-						}
-
-					}
-
-
-				}
-
-				.pub-title-box {
-					box-sizing: border-box;
-					padding: 36upx 30upx;
-					display: flex;
-					align-items: center;
-					justify-content: space-between;
-
-					.left {
-						font-size: 32upx;
-						line-height: 1;
-						font-family: PingFang SC;
-						font-weight: bold;
-						color: #111111;
-					}
-
-					.right {
-						display: flex;
-						align-items: center;
-						justify-content: center;
-
-						.text {
-							font-size: 24rpx;
-							line-height: 1;
-							font-family: PingFang SC;
-							font-weight: 500;
-							color: #999999;
-							margin-right: 10upx;
-						}
-
-						image {
-							width: 14upx;
-							height: 24upx;
-						}
-					}
-
-				}
-
-				.doc-tab-box {
-					padding: 14rpx 30rpx 0rpx 30rpx;
-					position: relative;
-
-					.tab-inner {
-						padding: 14upx 0 30upx;
-						display: flex;
-						overflow-x: auto;
-					}
-
-					.item {
-						font-size: 28upx;
-						white-space: nowrap;
-						line-height: 1;
-						font-family: PingFang SC;
-						font-weight: 500;
-						color: #666666;
-						margin-right: 40upx;
-						position: relative;
-
-						&:last-child {
-							margin-right: 0;
-						}
-
-						&.active {
-							font-weight: bold;
-							color: #333333;
-						}
-
-						&.cases {
-							margin-right: 60upx;
-						}
-
-						.text {
-							position: relative;
-							z-index: 1;
-						}
-
-						.tab-bg {
-							width: 72upx;
-							height: 28upx;
-							position: absolute;
-							top: 17upx;
-							left: 50%;
-							transform: translateX(-36upx);
-							z-index: -1;
-						}
-					}
-
-					.right-mask {
-						width: 56upx;
-						height: 34upx;
-						position: absolute;
-						top: 25upx;
-						right: 0upx;
-						z-index: 1;
-					}
-				}
-
-				.doc-list {
-					padding: 20upx;
-
-					.item {
-						box-sizing: border-box;
-						background: #FFFFFF;
-						// border-radius: 16upx;
-						display: flex;
-						border-bottom: 1px solid #F0F0F0;
-						margin-bottom: 30rpx;
-
-						.head-box {
-							width: 120upx;
-							height: 120upx;
-							background: #EDF1F4;
-							border-radius: 50%;
-							overflow: hidden;
-							margin-right: 30upx;
-
-							image {
-								width: 100%;
-								height: 100%;
-							}
-						}
-
-						.info {
-							width: calc(100% - 150upx);
-
-							.top {
-								display: flex;
-								align-items: center;
-								font-family: PingFang SC;
-								line-height: 1;
-
-								.name {
-									font-size: 34upx;
-									font-weight: bold;
-									color: #111111;
-								}
-
-								.line {
-									width: 1px;
-									height: 26upx;
-									background: #DDDDDD;
-									margin: 0 20upx;
-								}
-
-								.other {
-									font-size: 28upx;
-									font-weight: 500;
-									color: #333333;
-								}
-							}
-
-							.unit-box {
-								display: flex;
-								margin-top: 24upx;
-
-								.level {
-									padding: 0 10upx;
-									height: 30upx;
-									line-height: 30upx;
-									font-size: 22upx;
-									font-family: PingFang SC;
-									font-weight: 500;
-									color: #FFFFFF;
-									background: #5B37FD ;
-									border-radius: 10upx 4upx 10upx 4upx;
-									margin-right: 12upx;
-								}
-
-								.name {
-									font-size: 28upx;
-									font-family: PingFang SC;
-									font-weight: 500;
-									color: #333333;
-									line-height: 30upx;
-								}
-							}
-
-							.expertise {
-								font-size: 26upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #666666;
-								line-height: 42upx;
-								margin: 22upx 0 26upx;
-							}
-
-							.rate-box {
-								display: flex;
-								align-items: center;
-
-								.star {
-									display: flex;
-									align-items: center;
-
-									image {
-										width: 22upx;
-										height: 22upx;
-										margin-right: 10upx;
-									}
-
-									text {
-										font-size: 26upx;
-										font-family: PingFang SC;
-										font-weight: bold;
-										color: #CEA764;
-										line-height: 1;
-									}
-								}
-
-								.line {
-									width: 1px;
-									height: 20upx;
-									background: #DDDDDD;
-									margin: 0 20upx;
-								}
-
-								.num-box {
-									display: flex;
-									align-items: center;
-									font-family: PingFang SC;
-
-									.label {
-										font-size: 24upx;
-										font-weight: 500;
-										color: #999999;
-										line-height: 1;
-										margin-right: 7px;
-									}
-
-									.num {
-										font-size: 26upx;
-										font-weight: bold;
-										color: #CEA764;
-										line-height: 1;
-									}
-								}
-							}
-
-							.price-box {
-								display: flex;
-								align-items: center;
-								margin-top: 38upx;
-
-								.btn-item {
-									display: flex;
-									align-items: center;
-									justify-content: center;
-									width: 164upx;
-									height: 56upx;
-									line-height: 56upx;
-									border: 1px solid rgba(43, 199, 185, 0.5);
-									border-radius: 28upx;
-									font-family: PingFang SC;
-									margin-right: 30upx;
-
-									&:last-child {
-										margin-right: 0;
-									}
-
-									.label {
-										font-size: 26upx;
-										font-weight: 500;
-										color: #5B37FD ;
-										margin-right: 5upx;
-									}
-
-									.num {
-										font-size: 28upx;
-										font-weight: bold;
-										color: #5B37FD ;
-									}
-								}
-							}
-						}
-					}
-
-					.item:last-child {
-						border-bottom: none;
-						margin-bottom: 0rpx;
-					}
-
-					.bottom-title {
-						height: 50rpx;
-						display: flex;
-						align-items: center;
-						justify-content: center;
-						font-size: 26rpx;
-						font-family: PingFang SC;
-						font-weight: bold;
-						color: #5B37FD ;
-
-						image {
-							margin-left: 8rpx;
-							width: 14rpx;
-							height: 24rpx;
-						}
-					}
-				}
-
-				// 医师团队
-				.doc-cont {
-					box-sizing: border-box;
-					padding: 0 30upx;
-
-					.inner {
-						padding: 4upx 0 40upx;
-						display: flex;
-						overflow-x: auto;
-					}
-
-					.item {
-						display: flex;
-						align-items: center;
-						flex-direction: column;
-						margin-right: 40upx;
-
-						&:last-child {
-							margin-right: 0;
-						}
-
-						.head-box {
-							width: 120upx;
-							height: 120upx;
-							background: #F2F5F9;
-							border-radius: 50%;
-							margin-bottom: 20upx;
-							overflow: hidden;
-
-							image {
-								width: 100%;
-								height: 100%;
-							}
-						}
-
-						.name {
-							max-width: 120upx;
-							font-size: 28upx;
-							line-height: 1;
-							font-family: PingFang SC;
-							font-weight: 500;
-							color: #111111;
-							margin-bottom: 16upx;
-							text-align: center;
-						}
-
-						.position {
-							max-width: 120upx;
-							font-size: 24upx;
-							line-height: 1;
-							font-family: PingFang SC;
-							font-weight: 500;
-							color: #999999;
-							text-align: center;
-						}
-					}
-				}
-
-				.inner {
-					padding: 0 30upx;
-				}
-
-				// 健康知识
-				.pub-tab-box {
-					position: relative;
-
-					.tab-inner {
-						padding: 14upx 0 30upx;
-						display: flex;
-						overflow-x: auto;
-					}
-
-					.item {
-						font-size: 28upx;
-						white-space: nowrap;
-						line-height: 1;
-						font-family: PingFang SC;
-						font-weight: 500;
-						color: #666666;
-						margin-right: 40upx;
-						position: relative;
-
-						&:last-child {
-							margin-right: 0;
-						}
-
-						&.active {
-							font-weight: bold;
-							color: #333333;
-						}
-
-						&.cases {
-							margin-right: 60upx;
-						}
-
-						.text {
-							position: relative;
-							z-index: 1;
-						}
-
-						.tab-bg {
-							width: 72upx;
-							height: 28upx;
-							position: absolute;
-							top: 17upx;
-							left: 50%;
-							transform: translateX(-36upx);
-							z-index: -1;
-						}
-					}
-
-					.right-mask {
-						width: 56upx;
-						height: 34upx;
-						position: absolute;
-						top: 14upx;
-						right: -30upx;
-						z-index: 1;
-					}
-				}
-
-				.know-list {
-					padding-right: 10upx;
-
-					.item {
-						padding: 30upx 0;
-						display: flex;
-						align-items: center;
-						justify-content: space-between;
-						border-bottom: 1px solid #F0F0F0;
-
-						&:last-child {
-							border-bottom: none;
-						}
-
-						.left {
-							flex: 1;
-							padding-right: 40upx;
-							height: 190upx;
-							display: flex;
-							flex-direction: column;
-							justify-content: space-between;
-
-							.title {
-								font-size: 32upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #111111;
-								line-height: 48upx;
-							}
-
-							.info-box {
-								width: 100%;
-								display: flex;
-								align-items: center;
-								justify-content: space-between;
-
-								.readers {
-									display: flex;
-									align-items: center;
-
-									.head-box {
-										margin-right: 27upx;
-										display: flex;
-										align-items: center;
-
-										.head {
-											width: 48upx;
-											height: 48upx;
-											border-radius: 50%;
-											overflow: hidden;
-											box-shadow: 0 0 0 1px #fff;
-											margin-right: -10upx;
-
-											image {
-												width: 100%;
-												height: 100%;
-											}
-										}
-									}
-
-									.readings {
-										display: flex;
-										align-items: center;
-
-										.eye {
-											width: 26upx;
-											height: 20upx;
-											margin-right: 9upx;
-										}
-
-										.num {
-											font-size: 24upx;
-											font-family: PingFang SC;
-											font-weight: 500;
-											color: #999999;
-											line-height: 1;
-										}
-									}
-								}
-
-								.time {
-									font-size: 24upx;
-									line-height: 1;
-									font-family: PingFang SC;
-									font-weight: 500;
-									color: #999999;
-								}
-							}
-						}
-
-						.right {
-							width: 250upx;
-							height: 190upx;
-							border-radius: 8upx;
-							overflow: hidden;
-
-							image {
-								width: 100%;
-								height: 100%;
-							}
-						}
-					}
-				}
-
-				// 问诊案例
-				.cases-list {
-					padding-bottom: 10upx;
-
-					.item {
-						padding: 30upx 0;
-						border-bottom: 1px solid #F0F0F0;
-
-						&:last-child {
-							border-bottom: none;
-						}
-
-						.dec-text {
-							font-size: 32upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #111111;
-							line-height: 48upx;
-						}
-
-						.images-box {
-							margin-top: 10upx;
-							display: flex;
-							flex-wrap: wrap;
-
-							.img-item {
-								width: 155upx;
-								height: 155upx;
-								background: #F5F5F5;
-								border-radius: 8upx;
-								margin: 0 10upx 10upx 0;
-								overflow: hidden;
-
-								image {
-									width: 100%;
-									height: 100%;
-								}
-
-								&:nth-child(4n) {
-									margin-right: 0;
-								}
-							}
-						}
-
-						.doc-info {
-							display: flex;
-							align-items: center;
-							margin: 30upx 0 20upx;
-
-							.head {
-								width: 60upx;
-								height: 60upx;
-								background: #F2F5F9;
-								border-radius: 50%;
-								margin-right: 20upx;
-								overflow: hidden;
-
-								image {
-									width: 100%;
-									height: 100%;
-								}
-							}
-
-							.name {
-								font-size: 28upx;
-								line-height: 1;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #111111;
-							}
-
-							.line {
-								width: 1px;
-								height: 22upx;
-								background: #DDDDDD;
-								margin: 0 16upx;
-							}
-
-							.posit,
-							.address {
-								font-size: 26upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #999999;
-							}
-						}
-
-						.answer-box {
-							width: 100%;
-							background: #F5F7F7;
-							border-radius: 10upx;
-							display: flex;
-							flex-direction: column;
-							justify-content: center;
-
-							.text-inner {
-								// height: 84upx;
-								font-size: 28upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #666666;
-								line-height: 42upx;
-								padding: 15upx;
-							}
-						}
-
-						.read-box {
-							margin-top: 30upx;
-							display: flex;
-							align-items: center;
-							justify-content: flex-end;
-
-							image {
-								width: 24upx;
-								height: 19upx;
-								margin-right: 10upx;
-							}
-
-							.text {
-								font-size: 24upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #999999;
-							}
-						}
-					}
-				}
-			}
-
-			// 精选药品
-			.feat-title {
-				margin-top: 30upx;
-				padding: 10upx 0 33upx;
-				display: flex;
-				align-items: center;
-				justify-content: center;
-
-				image {
-					width: 37upx;
-					height: 37upx;
-					margin: 0upx 20upx;
-				}
-
-				text {
-					font-size: 36upx;
-					line-height: 1;
-					font-family: PingFang SC;
-					font-weight: bold;
-					color: #111111;
-				}
+	/* 课程列表 */
+	.course-list {
+		.course-item {
+			display: flex;
+			padding: 30rpx 0;
+			&:last-child {
+				border-bottom: none;
 			}
 
-			.drug-list {
-				display: flex;
-				flex-wrap: wrap;
-
-				.item {
-					margin-right: 20rpx;
-					margin-bottom: 20rpx;
-					width: 345rpx;
-					background: #FFFFFF;
-					box-shadow: 0px 0px 10rpx 4rpx rgba(199, 199, 199, 0.22);
-					border-radius: 20rpx;
-					overflow: hidden;
-
-					&:nth-child(2n) {
-						margin-right: 0;
-					}
-
-					.img-box {
-						width: 100%;
-						height: 334upx;
-
-						image {
-							width: 100%;
-							height: 100%;
-						}
-					}
-
-					.info-box {
-						box-sizing: border-box;
-						height: 182upx;
-						padding: 20upx;
-
-						.title {
-							height: 80upx;
-							font-size: 26upx;
-							font-family: PingFang SC;
-							font-weight: 500;
-							color: #111111;
-							line-height: 40upx;
-						}
-
-						.price-box {
-							display: flex;
-							align-items: center;
-							margin-top: 20upx;
-
-							.now {
-								color: #FF6633;
-								display: flex;
-								align-items: flex-end;
-								margin-right: 20upx;
-								font-family: PingFang SC;
-
-								.unit {
-									font-size: 24upx;
-									line-height: 1.4;
-									margin-right: 4upx;
-								}
-
-								.num {
-									font-size: 36upx;
-									font-weight: bold;
-									line-height: 1;
-								}
-							}
-
-							.old {
-								font-size: 26upx;
-								font-family: PingFang SC;
-								text-decoration: line-through;
-								color: #BBBBBB;
-								line-height: 1;
-							}
-						}
-					}
-				}
+			.item-thumb {
+				width: 260rpx;
+				height: 160rpx;
+				border-radius: 20rpx;
+				margin-right: 30rpx;
 			}
-		}
-
-		// 健康生活大讲堂
-		.open-class {
-			padding: 20rpx;
-			margin: 20rpx 15rpx 0rpx;
-			// background-color: #f0f4f7;
 
-			.title-box {
+			.item-content {
+				flex: 1;
 				display: flex;
+				flex-direction: column;
 				justify-content: space-between;
-				align-items: center;
 
-				.title {
+				.item-title {
 					font-size: 32rpx;
+					color: #1A1A1A;
 					font-weight: bold;
+					line-height: 1.4;
 				}
 
-				.more {
-					font-size: 24rpx;
-					padding-left: 30rpx;
-					color: #999999;
+				.item-footer {
 					display: flex;
+					justify-content: space-between;
 					align-items: center;
 
-					image {
-						width: 24rpx;
-						height: 24rpx;
-					}
-				}
-			}
-
-
-			.class-item {
-				font-size: 24rpx;
-				margin-top: 24rpx;
-				background-color: #fff;
-				border-radius: 16rpx;
-				padding: 0 16rpx;
-				margin-right: 14rpx;
-				width: 250rpx;
-				height: 280rpx;
-				font-size: 26rpx;
-				font-weight: 500;
-
-				.img-box {
-					height: 220rpx;
-					border-radius: 16rpx;
-					overflow: hidden;
-					margin-bottom: 12rpx;
-					image {
-						width: 100%;
-						height: 100%;
-					}
-				}
-
-
-				&:last-child {
-					margin-right: 0rpx;
-				}
-			}
-		}
-
-		.modules {
-			.module {
-				.depts {
-					z-index: 101;
-					margin: 20rpx 15rpx 0rpx;
-					padding: 20rpx;
-					//box-shadow: 0px 0px 5px 2px rgba(0, 0, 0, 0.05);
-					//background-color: #fff;
-					border-radius: 15rpx;
-
-					.title {
-						font-size: 32upx;
-						font-family: PingFang SC;
-						font-weight: bold;
-						color: #2A2B2E;
-					}
-
-					.dept-box {
-						margin-top: 15rpx;
-						display: flex;
-						align-items: center;
-						justify-content: flex-start;
-						flex-wrap: wrap;
-
-						.dept {
-							padding: 15rpx 5rpx;
-							width: 25%;
-							display: flex;
-							flex-direction: column;
-							align-items: center;
-							justify-content: center;
-							padding: 14rpx 0;
-
-							.icon {
-								width: 58rpx;
-								height: 58rpx;
-							}
-
-							.title {
-								margin-top: 10rpx;
-								font-size: 24upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #111111;
-							}
-						}
-					}
-
-				}
-
-				.doctor-articles {
-					z-index: 101;
-					margin: 20rpx 15rpx 0rpx;
-					padding: 20rpx;
-					box-shadow: 0px 0px 5px 2px rgba(0, 0, 0, 0.05);
-					background-color: #fff;
-					border-radius: 15rpx;
-
-					.title-box {
-						display: flex;
-						flex-direction: row;
-						align-items: center;
-						justify-content: space-between;
-
-						.title {
-							font-size: 32upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #111111;
-						}
-
-						.more {
-							display: flex;
-							align-items: center;
-							justify-content: flex-end;
-
-							.text {
-								font-size: 24rpx;
-								font-family: PingFang SC;
-								color: #9B9B9B;
-							}
-
-							image {
-								margin-left: 10rpx;
-								width: 15rpx;
-								height: 20rpx;
-							}
-
-						}
-					}
-
-					.article-box {
-						padding: 20rpx 0rpx;
-						overflow-x: auto;
-						box-sizing: border-box;
-						display: flex;
-						align-items: center;
-						justify-content: flex-start;
-
-						.article {
-							width: 300rpx;
-							margin-right: 20rpx;
-							background: #f9f8fe;
-							display: flex;
-							flex-direction: column;
-							align-items: flex-start;
-							justify-content: flex-start;
-
-							&:last-child {
-								margin-right: 0rpx;
-							}
-
-							.image-box {
-								width: 300rpx;
-								height: 400rpx;
-								position: relative;
-								border-radius: 20rpx;
-
-								image {
-									border-radius: 20rpx;
-									width: 300rpx;
-									height: 400rpx;
-								}
-
-								.views {
-									position: absolute;
-									top: 0rpx;
-									left: 0rpx;
-									padding: 5rpx 10rpx;
-									background: rgba(0, 0, 0, 0.25);
-									border-radius: 12rpx 0px 12rpx 0px;
-									opacity: 1;
-									font-size: 20rpx;
-									font-family: PingFang SC-Bold, PingFang SC;
-									font-weight: bold;
-									color: #FFFFFF;
-								}
-
-								.doctor {
-									margin: 10rpx;
-									display: flex;
-									align-items: center;
-									justify-content: flex-start;
-									position: absolute;
-									bottom: 0rpx;
-									left: 0rpx;
-
-									image {
-										border-radius: 50%;
-										width: 64rpx;
-										height: 64rpx;
-									}
-
-									.right {
-										width: 200rpx;
-										margin-left: 10rpx;
-										display: flex;
-										flex-direction: column;
-										align-items: flex-start;
-										justify-content: space-between;
-
-										.doc-name {
-											width: 200rpx;
-											font-size: 30rpx;
-											font-weight: bold;
-											font-family: PingFang SC;
-											color: #fff;
-										}
-
-										.doc-position {
-											width: 100%;
-											font-size: 28rpx;
-											font-family: PingFang SC;
-											color: #fff;
-											font-weight: bold;
-											opacity: 0.8;
-										}
-									}
-								}
-							}
-
-							.article-title-box {
-								width: 100%;
-								margin-top: 10rpx;
-								display: flex;
-								align-items: center;
-								justify-content: flex-start;
-
-								.article-title {
-									font-size: 30rpx;
-									font-weight: bold;
-									font-family: PingFang SC;
-									color: #2A2B2E;
-								}
-
-							}
-
-						}
-
-					}
-				}
-
-				.doctors {
-					z-index: 101;
-					margin: 20rpx 15rpx;
-					padding: 20rpx;
-					box-shadow: 0px 0px 5px 2px rgba(0, 0, 0, 0.05);
-					background-color: #fff;
-					border-radius: 15rpx;
-
-					.title-box {
-						display: flex;
-						flex-direction: row;
-						align-items: center;
-						justify-content: space-between;
-
-						.title {
-							font-size: 32upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #111111;
-						}
-
-						.more {
-							display: flex;
-							align-items: center;
-							justify-content: flex-end;
-
-							.text {
-								font-size: 24rpx;
-								font-family: PingFang SC;
-								color: #9B9B9B;
-							}
-
-							image {
-								margin-left: 10rpx;
-								width: 15rpx;
-								height: 20rpx;
-							}
-
-						}
-					}
-
-				}
-
-				.articles {
-					z-index: 101;
-					margin: 20rpx 15rpx;
-					padding: 20rpx;
-					box-shadow: 0px 0px 5px 2px rgba(0, 0, 0, 0.05);
-					background-color: #fff;
-					border-radius: 15rpx;
-
-					.title-box {
-						display: flex;
-						flex-direction: row;
-						align-items: center;
-						justify-content: space-between;
-
-						.title {
-							font-size: 32upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #111111;
-						}
-
-						.more {
-							display: flex;
-							align-items: center;
-							justify-content: flex-end;
-
-							.text {
-								font-size: 24rpx;
-								font-family: PingFang SC;
-								color: #9B9B9B;
-							}
-
-							image {
-								margin-left: 10rpx;
-								width: 15rpx;
-								height: 20rpx;
-							}
-
-						}
-					}
-
-					.article-box {
-						margin-top: 15rpx;
-						padding: 20rpx 0rpx 0rpx;
-						display: flex;
-						flex-direction: column;
-						align-items: flex-start;
-						justify-content: flex-start;
-
-						.item {
-							width: 100%;
-							margin-bottom: 20rpx;
-							display: flex;
-							align-items: flex-start;
-							justify-content: flex-start;
-
-							&:last-child {
-								margin-bottom: 0rpx;
-							}
-
-							.left {
-								flex: 1;
-								height: 160rpx;
-								margin-right: 15rpx;
-								display: flex;
-								flex-direction: column;
-								align-items: flex-start;
-								justify-content: space-between;
-
-								.title {
-									font-size: 28upx;
-									font-family: PingFang SC;
-									font-weight: bold;
-									color: #111111;
-								}
-
-								.views {
-									font-size: 24upx;
-									font-family: PingFang SC;
-									color: #9a9a9c;
-								}
-							}
-
-							.right {
-								image {
-									border-radius: 10rpx;
-									width: 220rpx;
-									height: 160rpx;
-									border: 1px solid #eeeeee;
-								}
-							}
-						}
-					}
-				}
-
-				.packages {
-					z-index: 101;
-					margin: 20rpx 15rpx;
-					padding: 20rpx;
-					box-shadow: 0px 0px 5px 2px rgba(0, 0, 0, 0.05);
-					background-color: #fff;
-					border-radius: 15rpx;
-
-					.title-box {
-						display: flex;
-						flex-direction: row;
-						align-items: center;
-						justify-content: space-between;
-
-						.title {
-							font-size: 32upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #111111;
-						}
-
-						.more {
-							display: flex;
-							align-items: center;
-							justify-content: flex-end;
-
-							.text {
-								font-size: 24rpx;
-								font-family: PingFang SC;
-								color: #9B9B9B;
-							}
-
-							image {
-								margin-left: 10rpx;
-								width: 15rpx;
-								height: 20rpx;
-							}
-
-						}
+					.item-playback {
+						font-size: 26rpx;
+						color: #CCCCCC;
 					}
 
-					.package-box {
-						padding: 20rpx 0rpx 0rpx;
-						display: flex;
-						align-items: flex-start;
-						justify-content: flex-start;
-						flex-wrap: wrap;
-
-						.item {
-							width: calc(50% - 20rpx);
-							border-radius: 15rpx;
-							margin: 10rpx;
-							display: flex;
-							flex-direction: column;
-							align-items: flex-start;
-							justify-content: flex-start;
-
-							&:last-child {}
-
-							.top {
-								width: 100%;
-								height: 300rpx;
-
-								image {
-									border-radius: 15rpx 15rpx 0rpx 0rpx;
-									width: 100%;
-									height: 300rpx;
-								}
-
-							}
-
-							.bottom {
-								width: 100%;
-								margin-top: 15rpx;
-
-								.title {
-									font-weight: bold;
-									font-size: 28upx;
-									font-family: PingFang SC;
-									color: #111111;
-								}
-
-								.price-box {
-									margin-top: 10rpx;
-									display: flex;
-									align-items: center;
-									justify-content: space-between;
-									width: 100%;
-
-									.price {
-										padding: 5rpx 10rpx;
-										background-color: #5B37FD ;
-										border-radius: 30rpx;
-										font-size: 20upx;
-										font-family: PingFang SC;
-										color: #ffffff;
-									}
-
-									.count {
-										font-size: 24upx;
-										font-family: PingFang SC;
-										color: #333333;
-									}
-
-								}
-							}
-						}
+					.study-btn {
+						padding: 12rpx 40rpx;
+						background: #5B37FD;
+						color: #FFFFFF;
+						font-size: 28rpx;
+						border-radius: 36rpx;
+						font-weight: 500;
 					}
-
-
 				}
 			}
-
-		}
-	}
-
-	.official-account {
-		box-sizing: border-box;
-		width: 100%;
-		height: 100upx;
-		position: fixed;
-		bottom: 30upx;
-		z-index: 99;
-		padding: 0 20upx 180rpx 20upx;
-	}
-
-	// 消息
-	.message-box {
-		box-sizing: border-box;
-		width: 100%;
-		height: 84upx;
-		background: #F3FFFD;
-		border: 1px solid #C7E9E5;
-		box-shadow: 0px 4upx 12upx 0px rgba(90, 203, 138, 0.16);
-		border-radius: 16upx;
-		position: fixed;
-		left: 50%;
-		transform: translateX(-50%);
-		bottom: 30upx;
-		z-index: 99;
-		display: flex;
-		align-items: center;
-		justify-content: space-between;
-		padding: 0 20upx 0 30upx;
-
-		.left {
-			flex: 1;
-			display: flex;
-			align-items: center;
-
-			image {
-				width: 24upx;
-				height: 24upx;
-				margin-right: 18upx;
-			}
-
-			.text {
-				width: 90%;
-				font-size: 28upx;
-				font-family: PingFang SC;
-				font-weight: 500;
-				color: #5B37FD ;
-			}
-		}
-
-		.btn {
-			width: 100upx;
-			height: 48upx;
-			line-height: 48upx;
-			text-align: center;
-			font-size: 24upx;
-			font-family: PingFang SC;
-			font-weight: 500;
-			color: #FFFFFF;
-			border: 1px solid #D2E6FF;
-			background: linear-gradient(135deg, #5B37FD 0%, #5B37FD  100%);
-			border-radius: 24upx;
-			margin-left: 30upx;
 		}
-
 	}
 
-	.contact-btn {
-		display: inline-block;
-		position: absolute;
-		top: 0;
-		left: 0;
-		width: 100%;
-		height: 100%;
-		opacity: 0;
+	.ellipsis-2 {
+		display: -webkit-box;
+		-webkit-box-orient: vertical;
+		-webkit-line-clamp: 2;
+		overflow: hidden;
 	}
 
-	.popup-box {
-		position: fixed;
-		top: 0;
-		right: 0;
-		left: 0;
-		bottom: 0;
-		z-index: 999;
-		display: flex;
-		justify-content: center;
-		align-items: center;
-
-		.info-mask {
-			position: fixed;
-			top: 0;
-			right: 0;
-			bottom: 0;
-			left: 0;
-			background-color: rgba($color: #000000, $alpha: 0.5);
-			z-index: 999;
-		}
-
-		.info-form {
-			z-index: 1000;
-			width: 450rpx;
-			display: flex;
-			flex-direction: column;
-			justify-content: center;
-			align-items: center;
-			position: relative;
-
-			image {
-				width: 100%;
-			}
-		}
+	.bottom-safe-area {
+		height: 160rpx;
 	}
-</style>
+</style>

+ 0 - 0
pages/home/indexOld.vue → pages/home/shopping.vue


+ 245 - 113
pages/live/index.vue

@@ -1,30 +1,64 @@
 <template>
-	<view class="page-container">
-		<view class="status_bar" :style="{ height: statusBarHeight }"></view>
-		<!-- 顶部标题栏 -->
-		<view class="nav-header">
-			<view class="back-btn" @click="goBack">
-				<image class="back-icon" src="/static/right_arrow.png" mode="aspectFit"></image>
+	<view class="live-container">
+		<!-- 状态栏占位 -->
+		<view class="status_bar" :style="{ height: statusBarHeight + 'px' }"></view>
+		
+		<!-- 顶部导航栏 -->
+		<view class="nav-bar">
+			<text class="nav-title">讲堂</text>
+			<view class="search-box" @click="toSearch">
+				<image class="search-icon" src="/static/search_gray.png" mode="aspectFit"></image>
+				<text class="placeholder">搜索课程</text>
 			</view>
-			<text class="page-title">精选课程</text>
-			<view class="placeholder"></view>
+			<!-- 右侧留出微信胶囊位 -->
+			<view class="capsule-placeholder"></view>
 		</view>
 
-		<!-- 课程列表 -->
-		<view class="course-grid">
-			<view class="course-item" v-for="(item, index) in courseList" :key="index" @click="goDetail(item)">
-				<view class="course-cover-box">
-					<image class="course-cover" :src="item.image" mode="aspectFill"></image>
-				</view>
-				<view class="course-info">
-					<view class="course-name">{{ item.title }}</view>
-					<view class="course-footer">
-						<text class="play-count">{{ item.playCount }}次播放</text>
-						<image class="share-icon" src="/static/layer_share_icon16@3x.png" mode="aspectFit"></image>
+		<!-- 分类切换栏 -->
+		<view class="category-wrapper">
+			<scroll-view class="category-scroll" scroll-x :show-scrollbar="false">
+				<view class="category-list">
+					<view 
+						v-for="(item, index) in categories" 
+						:key="index" 
+						class="category-item"
+						:class="{ active: currentCateIndex === index }"
+						@click="changeCate(index)"
+					>
+						<text class="cate-name">{{ item }}</text>
+						<view class="active-line" v-if="currentCateIndex === index"></view>
 					</view>
 				</view>
+			</scroll-view>
+			<view class="expand-btn">
+				<image class="arrow-icon" src="/static/icon_arrow_down.png" mode="aspectFit"></image>
 			</view>
 		</view>
+
+		<!-- 课程列表 -->
+		<scroll-view class="course-scroll" scroll-y @scrolltolower="loadMore">
+			<view class="course-list">
+				<view 
+					class="course-item" 
+					v-for="(item, index) in courseList" 
+					:key="index"
+					@click="goDetail(item)"
+				>
+					<image class="course-thumb" :src="item.image || '/static/course_img.png'" mode="aspectFill"></image>
+					<view class="course-content">
+						<view class="course-title-wrap">
+							<text class="course-title ellipsis-2">{{ item.title }}</text>
+						</view>
+						<view class="course-footer">
+							<text class="play-count">{{ item.playCount }}次播放</text>
+							<view class="study-btn">去学习</view>
+						</view>
+					</view>
+				</view>
+			</view>
+			<!-- 底部占位,防止被系统tabbar遮挡 -->
+			<view class="bottom-placeholder"></view>
+		</scroll-view>
 	</view>
 </template>
 
@@ -32,163 +66,261 @@
 export default {
 	data() {
 		return {
-			statusBarHeight: uni.getStorageSync('menuInfo') ? uni.getStorageSync('menuInfo').statusBarHeight : 20,
+			statusBarHeight: uni.getSystemInfoSync().statusBarHeight,
+			currentCateIndex: 0,
+			categories: ['热门好课', '养生', '健康饮食', '乐器', '慢性病', '心理健康', '运动健身', '家庭教育'],
 			courseList: [
 				{
 					id: 1,
+					title: "脑梗塞是帕金森病的发病因素吗?",
 					image: "/static/famous_doctor_img.png",
-					title: "健身操",
-					playCount: "16.5万"
+					playCount: "25862"
 				},
 				{
 					id: 2,
+					title: "合理的运动与健康",
 					image: "/static/famous_doctor_img2.png",
-					title: "比赛",
-					playCount: "16.5万"
+					playCount: "25862"
 				},
 				{
 					id: 3,
+					title: "合理的运动与健康",
 					image: "/static/course_img.png",
-					title: "八段锦",
-					playCount: "16.5万"
+					playCount: "25862"
 				},
 				{
 					id: 4,
+					title: "合理的运动与健康",
 					image: "/static/famous_doctor_img.png",
-					title: "广场舞",
-					playCount: "16.5万"
+					playCount: "25862"
 				},
 				{
 					id: 5,
-					image: "/static/course_img.png",
-					title: "八段锦",
-					playCount: "16.5万"
+					title: "合理的运动与健康",
+					image: "/static/famous_doctor_img2.png",
+					playCount: "25862"
 				},
 				{
 					id: 6,
-					image: "/static/famous_doctor_img2.png",
-					title: "广场舞",
-					playCount: "16.5万"
+					title: "合理的运动与健康",
+					image: "/static/course_img.png",
+					playCount: "25862"
 				}
 			]
 		};
 	},
 	methods: {
-		goBack() {
-			uni.navigateBack();
+		changeCate(index) {
+			this.currentCateIndex = index;
+			// 这里通常会重新请求对应分类的课程数据
+		},
+		toSearch() {
+			uni.navigateTo({
+				url: '/pages/home/productSearch'
+			});
 		},
 		goDetail(item) {
 			uni.navigateTo({
 				url: `/pages_course/learn?courseId=${item.id}&type=1`
 			});
+		},
+		loadMore() {
+			console.log('加载更多...');
 		}
 	}
 };
 </script>
 
 <style lang="scss" scoped>
-.page-container {
+.live-container {
+	width: 100%;
+	height: 100vh;
+	display: flex;
+	flex-direction: column;
+	background-color: #ffffff;
+}
+
+.status_bar {
 	width: 100%;
-	min-height: 100vh;
-	background-color: #F8F9FB;
-	padding-bottom: 120upx;
+	background-color: #ffffff;
+}
+
+.nav-bar {
+	height: 44px;
+	display: flex;
+	align-items: center;
+	padding: 0 30rpx;
+	background-color: #ffffff;
 
-	.status_bar {
-		width: 100%;
-		background-color: #ffffff;
+	.nav-title {
+		font-size: 44rpx;
+		font-weight: bold;
+		color: #1A1A1A;
+		margin-right: 30rpx;
 	}
 
-	.nav-header {
-		height: 88rpx;
-		background-color: #ffffff;
+	.search-box {
+		flex: 1;
+		height: 72rpx;
+		background: #F5F6F8;
+		border-radius: 36rpx;
 		display: flex;
 		align-items: center;
-		justify-content: space-between;
-		padding: 0 30rpx;
-		position: sticky;
-		top: 0;
-		z-index: 100;
-
-		.back-btn {
-			width: 60rpx;
-			height: 60rpx;
-			display: flex;
+		padding: 0 24rpx;
+		margin-right: 20rpx;
+
+		.search-icon {
+			width: 32rpx;
+			height: 32rpx;
+			margin-right: 12rpx;
+		}
+
+		.placeholder {
+			font-size: 28rpx;
+			color: #999999;
+		}
+	}
+
+	.capsule-placeholder {
+		width: 180rpx; // 模拟微信胶囊宽度
+	}
+}
+
+.category-wrapper {
+	display: flex;
+	align-items: center;
+	padding: 20rpx 0 10rpx;
+	background-color: #ffffff;
+
+	.category-scroll {
+		flex: 1;
+		white-space: nowrap;
+		padding-left: 30rpx;
+
+		.category-list {
+			display: inline-flex;
 			align-items: center;
-			justify-content: flex-start;
 
-			.back-icon {
-				width: 36rpx;
-				height: 36rpx;
-				transform: rotate(180deg);
+			.category-item {
+				margin-right: 50rpx;
+				position: relative;
+				display: flex;
+				flex-direction: column;
+				align-items: center;
+				padding-bottom: 15rpx;
+
+				.cate-name {
+					font-size: 32rpx;
+					color: #666666;
+					transition: all 0.3s;
+				}
+
+				.active-line {
+					position: absolute;
+					bottom: 0;
+					left: 50%;
+					transform: translateX(-50%);
+					width: 60rpx;
+					height: 6rpx;
+					background: #5B37FD;
+					border-radius: 3rpx;
+				}
+
+				&.active {
+					.cate-name {
+						color: #1A1A1A;
+						font-weight: bold;
+					}
+				}
 			}
 		}
+	}
 
-		.page-title {
-			font-size: 36rpx;
-			font-weight: bold;
-			color: #1A1A1A;
-		}
+	.expand-btn {
+		width: 80rpx;
+		height: 60rpx;
+		display: flex;
+		align-items: center;
+		justify-content: center;
+		background: linear-gradient(to right, rgba(255,255,255,0), #fff 20%);
 
-		.placeholder {
-			width: 60rpx;
+		.arrow-icon {
+			width: 32rpx;
+			height: 32rpx;
+			opacity: 0.4;
 		}
 	}
+}
+
+.course-scroll {
+	flex: 1;
+	overflow: hidden;
+}
 
-	.course-grid {
-		padding: 30rpx;
+.course-list {
+	padding: 20rpx 30rpx;
+
+	.course-item {
 		display: flex;
-		flex-wrap: wrap;
-		justify-content: space-between;
-
-		.course-item {
-			width: 334rpx;
-			background-color: #ffffff;
-			border-radius: 20rpx;
-			margin-bottom: 30rpx;
-			overflow: hidden;
-			box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.02);
-
-			.course-cover-box {
-				width: 100%;
-				height: 250rpx;
-
-				.course-cover {
-					width: 100%;
-					height: 100%;
-					background-color: #f5f5f5;
-				}
-			}
+		padding: 24rpx 0;
+
+		&:last-child {
+			border-bottom: none;
+		}
+
+		.course-thumb {
+			width: 240rpx;
+			height: 150rpx;
+			border-radius: 12rpx;
+			margin-right: 24rpx;
+			flex-shrink: 0;
+		}
 
-			.course-info {
-				padding: 20rpx;
+		.course-content {
+			flex: 1;
+			display: flex;
+			flex-direction: column;
+			justify-content: space-between;
 
-				.course-name {
-					font-size: 30rpx;
-					font-weight: bold;
+			.course-title-wrap {
+				.course-title {
+					font-size: 32rpx;
 					color: #1A1A1A;
-					margin-bottom: 20rpx;
-					overflow: hidden;
-					text-overflow: ellipsis;
-					white-space: nowrap;
+					font-weight: 500;
+					line-height: 1.4;
 				}
+			}
 
-				.course-footer {
-					display: flex;
-					align-items: center;
-					justify-content: space-between;
+			.course-footer {
+				display: flex;
+				justify-content: space-between;
+				align-items: center;
 
-					.play-count {
-						font-size: 24rpx;
-						color: #999999;
-					}
+				.play-count {
+					font-size: 24rpx;
+					color: #CCCCCC;
+				}
 
-					.share-icon {
-						width: 32rpx;
-						height: 32rpx;
-					}
+				.study-btn {
+					padding: 10rpx 36rpx;
+					background: #5B37FD;
+					color: #FFFFFF;
+					font-size: 26rpx;
+					border-radius: 32rpx;
 				}
 			}
 		}
 	}
 }
-</style>
+
+.bottom-placeholder {
+	height: 40rpx;
+}
+
+.ellipsis-2 {
+	display: -webkit-box;
+	-webkit-box-orient: vertical;
+	-webkit-line-clamp: 2;
+	overflow: hidden;
+}
+</style>

+ 343 - 360
pages/shopping/index.vue

@@ -1,62 +1,76 @@
 <template>
-	<view class="content" :style="$store.state.theme.currentMoban">
-		<view class="top-content">
+	<view class="content">
+		<image class="bg-image" src="/static/purple_home_top_bg.png" ></image>
+		<!-- 顶部导航栏 -->
+		<view class="header-box">
 			<view class="status_bar" :style="{height: statusBarHeight}"></view>
-			<!-- 这里是状态栏 -->
-			<view class="top-title">健康产品</view>
-			<!-- 搜索框 -->
-			<view class="search-cont">
-				<view class="inner">
-					<image class="icon-search" src="../../static/images/search.png" mode=""></image>
-					<input type="text"  confirm-type="搜索" @click="toSearch" placeholder="输入商品名称"
-						placeholder-style="font-size:28rpx;color:#BBBBBB;font-family: PingFang SC;" />
+			<view class="header-content">
+				<view class="title">商城</view>
+				<view class="search-bar" @click="toSearch">
+					<image class="search-icon" src="/static/search_gray.png" mode="aspectFit"></image>
+					<text class="placeholder">搜索商品</text>
+				</view>
+				<view class="cart-box">
+					<image class="cart-icon" src="/static/shop_shopping_car.png" mode="aspectFit"></image>
+					<view class="badge">8</view>
 				</view>
 			</view>
 		</view>
-		<view :style="{height: divHeight}" class="medic-box">
-			<view class="cate-list">
-				<view v-for="(item,index) in cates" :key="index" class="ellipsis" :class="cateSelect == item.cateId?'item active':'item'"
-					@click="choseCate(item)">{{item.cateName }}</view>
-			</view>
-			<view class="medic">
+
+		<scroll-view scroll-y="true" class="main-scroll" :refresher-enabled="isEnabled" :refresher-triggered="triggered"
+			@refresherrefresh="pullDownRefresh" @scrolltolower="reachBottom">
+			<view class="page-container">
 				<!-- 轮播图 -->
-				<!-- <view class="banner-box">
+				<view class="banner-box">
 					<swiper class="swiper" :indicator-dots="true" :circular="true" :autoplay="true" :interval="3000"
 						:duration="1000" indicator-color="rgba(255, 255, 255, 0.6)" indicator-active-color="#ffffff">
 						<swiper-item class="swiper-item" v-for="(item,index) in advs" :key="index"
 							@click="handleAdvClick(item)">
-							<image :src="item.imageUrl" mode=""></image>
+							<image :src="item.imageUrl || '/static/famous_doctor_img.png'" mode="aspectFill"></image>
+						</swiper-item>
+						<swiper-item v-if="advs.length === 0" class="swiper-item">
+							<image src="/static/famous_doctor_img.png" mode="aspectFill"></image>
 						</swiper-item>
 					</swiper>
-				</view> -->
+				</view>
+
+				<!-- 分类导航 -->
+				<view class="category-grid">
+					<view class="category-item" v-for="(item, index) in categoryList" :key="index">
+						<image :src="item.icon" mode="aspectFit" class="cate-icon"></image>
+						<text class="cate-name">{{item.name}}</text>
+					</view>
+					<!-- 分类指示器 -->
+					<view class="indicator-box">
+						<view class="indicator-bar"></view>
+					</view>
+				</view>
+
 				<!-- 商品列表 -->
-				<view class="medic-list">
-					<!-- <view class="item" v-for="(item,index) in subCates" :key="index">
-							<view class="title">{{item.cateName}}</view> -->
-					<scroll-view scroll-y="true" class="hb" :refresher-enabled="isEnabled" :refresher-triggered="triggered"
-						refresher-background="rgba(0,0,0,0)" @refresherrefresh="pullDownRefresh"
-						@refresherrestore="triggered = false" :upper-threshold="100" :lower-threshold="100"
-						@refresherabort="triggered = false" @scrolltolower="reachBottom">
-					<view class="inner-list">
-						<view class="definite" v-for="(subItem,index) in subCates" @click="showProductList(subItem)">
-							<view class="img-box">
-								<image :src="subItem.image" mode="aspectFit"></image>
+				<view class="product-section">
+					<view class="product-list">
+						<view class="product-item" v-for="(item, index) in subCates" :key="index" @click="showProductDetails(item)">
+							<image :src="item.image" mode="aspectFill" class="product-img"></image>
+							<view class="product-info">
+								<view class="product-title ellipsis-2">{{item.productName}}</view>
+								<view class="price-row">
+									<text class="price-symbol">¥</text>
+									<text class="price-integer">{{getInteger(item.price)}}</text>
+									<text class="price-decimal">.{{getDecimal(item.price)}}</text>
+									<text class="original-price">¥{{item.otPrice || item.price}}</text>
+								</view>
 							</view>
-							<view class="name ellipsis">{{subItem.productName}}</view>
 						</view>
 					</view>
 					<u-loadmore :status="status" />
-					</scroll-view>
-					<view v-if="subCates.length==0" class="center mt20 column">
-						<image src="../../static/images/no_data.png" 
-						style="width: 200rpx;height: 150rpx;"></image>
-						<text class="fs24">暂无商品</text>
-						</view>
-					<!-- 	</view> -->
+					
+					<view v-if="subCates.length === 0 && status !== 'loading'" class="empty-box">
+						<image src="/static/images/no_data.png" mode="aspectFit" class="empty-img"></image>
+						<text class="empty-text">暂无商品</text>
+					</view>
 				</view>
 			</view>
-		</view>
-		<!-- <tabbar :actindex="2"></tabbar> -->
+		</scroll-view>
 	</view>
 </template>
 
@@ -71,393 +85,362 @@
 	export default {
 		data() {
 			return {
-				divHeight: '0px',
-				allCates: [],
-				cates: [],
-				subCates: [],
-				// 状态栏的高度
-				statusBarHeight: uni.getStorageSync('menuInfo').statusBarHeight,
-				// 选中商品分类
-				cateSelect: 0,
-				// 轮播图
+				statusBarHeight: (uni.getStorageSync('menuInfo') && uni.getStorageSync('menuInfo').statusBarHeight) || '20px',
 				advs: [],
-				theme:"beiliyou",
-				defaultOrder:'desc',
+				subCates: [],
 				page: {
-					num: 1, // 当前页码,默认0,回调之前会加1,即callback(page)会从1开始
-					size: 10 // 每页数据的数量,默认10
+					num: 1,
+					size: 10
 				},
-				titname:'',
 				isEnabled: true,
 				triggered: false,
-				status:'loadmore'
+				status: 'loadmore',
+				categoryList: [
+					{ name: '家庭常备', icon: '/static/shop_meau1.png' },
+					{ name: '儿童用药', icon: '/static/shop_meau2.png' },
+					{ name: '女性用药', icon: '/static/shop_meau3.png' },
+					{ name: '感冒发烧', icon: '/static/shop_meau4.png' },
+					{ name: '专业药房', icon: '/static/shop_meau5.png' },
+					{ name: '营养膳食', icon: '/static/shop_meau6.png' },
+					{ name: '健康理疗', icon: '/static/shop_meau7.png' },
+					{ name: '日用百货', icon: '/static/shop_meau8.png' },
+					{ name: '保健养生', icon: '/static/shop_meau9.png' },
+					{ name: '品牌好礼', icon: '/static/shop_meau10.png' }
+				]
 			};
 		},
-		onLoad() {
-			uni.showShareMenu({
-				withShareTicket: true,
-				//小程序的原生菜单中显示分享按钮,才能够让发送给朋友与分享到朋友圈两个按钮可以点击
-				menus: ["shareAppMessage", "shareTimeline"] //不设置默认发送给朋友
-			})
-			this.getProductCate();
-			setTimeout(()=>{
-				this.cateSelect=this.allCates[0].cateId
-				this.getproduct()
-			},200)
-		},
-		computed:{
-			isDrug() {
-				return this.$store.state.isDrug
-			},
-		},
 		onShow() {
-			var that = this;
-			setTimeout(function() {
-				let info = uni.createSelectorQuery().select(".top-content");
-				info.boundingClientRect(function(data) { //data - 各种参数
-					console.log(data.height) // 获取元素宽度
-					// console.log(uni.upx2px(10)) 
-					that.divHeight = "calc(100% - " + data.height + "px)"
-				}).exec()
-			}, 500);
 			this.getAdv();
+			this.getproduct('refresh');
 		},
 		methods: {
-			// divHeight(){
-			//    return 'height:calc(100% - ${this.top}px);'
-			// },
-			pullDownRefresh(){
-				// 下拉
-				this.triggered = true; //下拉了状态为true
+			getInteger(price) {
+				if (!price) return '0';
+				return Math.floor(price);
+			},
+			getDecimal(price) {
+				if (!price) return '00';
+				let decimal = (price % 1).toFixed(2).split('.')[1];
+				return decimal || '00';
+			},
+			pullDownRefresh() {
+				this.triggered = true;
+				this.page.num = 1;
+				this.getproduct('refresh');
 				setTimeout(() => {
 					this.triggered = false;
-					uni.stopPullDownRefresh()
-					this.page.num= 1;
-					this.getproduct('refresh') //触底  不穿执行else
-					// 请求接口里面需要判断是不是最后一页   是最后一页 status赋值为‘loadmore’没有更多了
-					// 请求接口
-				}, 1000)
+				}, 1000);
 			},
-			reachBottom(){
-				//上拉
-				// status这个是加载状态
+			reachBottom() {
 				if (this.status === 'loadmore') {
-					this.status = 'loading'
-					uni.showNavigationBarLoading()
-					setTimeout(() => {
-						this.page.num++
-						this.getproduct() //触底  不穿执行else
-						uni.hideNavigationBarLoading()
-					}, 1000);
-				}
-			},
-			toSearch() {
-				uni.navigateTo({
-					url: '../home/productSearch'
-				})
-			},
-			handleAdvClick(item) {
-				console.log(item);
-				if (item.showType == 1) {
-					uni.setStorageSync('url', item.advUrl);
-					uni.navigateTo({
-						url: "../home/h5"
-					})
-				} else if (item.showType == 2) {
-					uni.navigateTo({
-						url: item.advUrl
-					})
-				} else if (item.showType == 3) {
-					uni.setStorageSync('content', item.content);
-					uni.navigateTo({
-						url: "../home/content"
-					})
+					this.page.num++;
+					this.getproduct();
 				}
-
 			},
 			getAdv() {
-				let data = {
-					advType: 2
-				};
-				getAdv(data).then(
-					res => {
-						if (res.code == 200) {
-							this.advs = res.data;
-						}
-					},
-					rej => {}
-				);
+				getAdv({ advType: 2 }).then(res => {
+					if (res.code == 200) {
+						this.advs = res.data;
+					}
+				});
 			},
-			getProductCate() {
+			getproduct(type) {
+				this.status = 'loading';
 				let data = {
-					isDrug:this.isDrug
-				};
-				getProductCate(data).then(
-					res => {
-						if (res.code == 200) {
-							this.allCates = res.data;
-							this.cates = this.allCates.filter(function(item) {
-								return item.pid == 0
-							});
-							console.log(this.allCates,111)
-							console.log(this.cates)
-							if (this.cates != null && this.cates.length > 0) {
-								this.cateSelect = this.cates[0].cateId;
-								this.getSubCate()
-							}
-						} else {
-							uni.showToast({
-								icon: 'none',
-								title: "请求失败",
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 商品分类选择
-			choseCate(item) {
-				this.page.num=1
-				this.subCates=[]
-				this.cateSelect = item.cateId;
-				console.log(item)
-				this.titname=item.cateName
-				// this.getSubCate()
-				this.getproduct()
-			},
-			getproduct(type){
-				var data = {
-					cateId:this.cateSelect,
-					defaultOrder:this.defaultOrder,
 					page: this.page.num,
 					pageSize: this.page.size,
-					productName:  "",
-					storeId: "",
-					isDrug:this.isDrug
+					isDrug: this.$store.state.isDrug
 				};
-				getProducts(data).then(res=>{
-					if(res.code==200){
-						console.log(res)
-						if (type == 'refresh') {
-							this.subCates=res.data.list
-						} else {
-							// 加载更多 当前页和下一页合并
-							this.subCates = [...this.subCates, ...res.data.list]
-						}
-						if (this.page.num >= res.data.pages) {
-							//是否有下一页
-							this.status = 'nomore'
+				getProducts(data).then(res => {
+					if (res.code == 200) {
+						if (type === 'refresh') {
+							this.subCates = res.data.list;
 						} else {
-							this.status = 'loadmore'
+							this.subCates = [...this.subCates, ...res.data.list];
 						}
+						this.status = this.page.num >= res.data.pages ? 'nomore' : 'loadmore';
 					}
-				})
+				});
 			},
-			getSubCate() {
-				var that = this;
-				// this.subCates = this.allCates.filter(function(item) {
-					// let subList = that.allCates.filter(child => {
-					// 	//返回每一项的子级数组
-					// 	return child.pid === item.cateId
-					// });
-					// subList.length > 0 ? item.children = subList : [];
-				// 	return item.pid == that.cateSelect
-				// });
-				// this.getProductCate()
-				console.log(this.subCates);
+			toSearch() {
+				uni.navigateTo({
+					url: '../home/productSearch'
+				});
 			},
-			// 查看商品详情
-			showProductList(item) {
+			showProductDetails(item) {
 				uni.navigateTo({
-					// url: './productList?cateId=' + item.cateId + "&pid=" + 0
 					url: '/pages/shopping/productDetails?productId=' + item.productId
-				})
+				});
 			},
-			goSearch(e) {
-				if (e.detail.value != null && e.detail.value != "") {
-					this.utils.addHisSearch(e.detail.value);
+			handleAdvClick(item) {
+				if (item.showType == 1) {
+					uni.setStorageSync('url', item.advUrl);
+					uni.navigateTo({ url: "../home/h5" });
+				} else if (item.showType == 2) {
+					uni.navigateTo({ url: item.advUrl });
+				} else if (item.showType == 3) {
+					uni.setStorageSync('content', item.content);
+					uni.navigateTo({ url: "../home/content" });
 				}
-				uni.navigateTo({
-					url: '../home/productList?searchValue=' + e.detail.value
-				})
 			}
 		}
 	}
 </script>
 
-<style lang="scss">
-	page {
-		height: 100%;
-		background-color: #fff;
-	}
-
+<style lang="scss" scoped>
 	.content {
-		height: 100%;
 		display: flex;
 		flex-direction: column;
-
-		.top-content {
+		height: 100vh;
+		background-color: #F8F9FB;
+		position: relative;
+		z-index: 2;
+		.bg-image {
+			position: absolute;
+			top: 0;
+			left: 0;
 			width: 100%;
-			z-index: 10;
+			height: 680rpx;
+			z-index: -1;
+		}
+		
+	}
+
+	.header-box {
+		padding-bottom: 20rpx;
+
+		.header-content {
+			display: flex;
+			align-items: center;
+			padding: 0 30rpx;
+			height: 88rpx;
 
-			.top-title {
-				height: 88upx;
-				line-height: 88upx;
-				font-size: 42upx;
-				font-family: Source Han Sans CN;
+			.title {
+				font-size: 44rpx;
 				font-weight: bold;
-				color: #222222;
-				padding-left: 41upx;
-				background-color: #FFFFFF;
+				color: #333;
+				margin-right: 20rpx;
 			}
 
-			.search-cont {
-				padding: 16upx 30upx;
-				background-color: #FFFFFF;
+			.search-bar {
+				width: 302rpx;
+				height: 72rpx;
+				background: #FFFFFF;
+				border-radius: 36rpx;
+				display: flex;
+				align-items: center;
+				padding: 0 30rpx;
+				margin: 0 20rpx;
+				box-sizing: border-box;
 
-				.inner {
-					box-sizing: border-box;
-					width: 100%;
-					height: 72upx;
-					background: #F7F7F7;
-					border-radius: 36upx;
+				.search-icon {
+					width: 32rpx;
+					height: 32rpx;
+					margin-right: 16rpx;
+				}
+
+				.placeholder {
+					font-size: 28rpx;
+					color: #999;
+				}
+			}
+
+			.cart-box {
+				position: relative;
+				padding: 10rpx;
+
+				.cart-icon {
+					width: 48rpx;
+					height: 48rpx;
+				}
+
+				.badge {
+					position: absolute;
+					top: 0;
+					right: 0;
+					background: #FF4D4F;
+					color: #fff;
+					font-size: 20rpx;
+					min-width: 28rpx;
+					height: 28rpx;
+					border-radius: 14rpx;
 					display: flex;
 					align-items: center;
-					padding: 0 30upx;
+					justify-content: center;
+					padding: 0 6rpx;
+					border: 2rpx solid #fff;
+				}
+			}
+		}
+	}
 
-					.icon-search {
-						width: 28upx;
-						height: 28upx;
-						margin-right: 20upx;
-					}
+	.main-scroll {
+		flex: 1;
+		overflow: hidden;
+	}
 
-					input {
-						height: 60upx;
-						line-height: 60upx;
-						flex: 1;
-					}
-				}
+	.page-container {
+		padding: 0 30rpx 30rpx;
+	}
+
+	.banner-box {
+		width: 100%;
+		height: 320rpx;
+		border-radius: 24rpx;
+		overflow: hidden;
+		margin-bottom: 40rpx;
+
+		.swiper {
+			width: 100%;
+			height: 100%;
+
+			image {
+				width: 100%;
+				height: 100%;
 			}
 		}
+	}
+
+	.category-grid {
+		display: flex;
+		flex-wrap: wrap;
+		background: #FFFFFF;
+		border-radius: 24rpx;
+		padding: 30rpx 10rpx 20rpx;
+		margin-bottom: 30rpx;
 
-		.medic-box {
+		.category-item {
+			width: 20%;
 			display: flex;
+			flex-direction: column;
+			align-items: center;
+			margin-bottom: 30rpx;
 
-			.cate-list {
-				box-sizing: border-box;
-				width: 200upx;
-				background: #F2F5F9;
-				display: flex;
-				flex-direction: column;
-				padding: 20upx 0;
-				overflow-y: scroll;
-
-				.item {
-					height: 100upx;
-					line-height: 100upx;
-					padding-left: 30upx;
-					font-size: 28upx;
-					font-family: PingFang SC;
-					font-weight: 500;
-					color: #333333;
-					position: relative;
-
-					&.active {
-						color: #5B37FD;
-
-						&::after {
-							content: "";
-							width: 8upx;
-							height: 50upx;
-							background: #5B37FD;
-							position: absolute;
-							top: 25upx;
-							left: 0;
-						}
-					}
+			.cate-icon {
+				width: 88rpx;
+				height: 88rpx;
+				margin-bottom: 12rpx;
+			}
+
+			.cate-name {
+				font-size: 24rpx;
+				color: #333;
+			}
+		}
+
+		.indicator-box {
+			width: 100%;
+			display: flex;
+			justify-content: center;
+			margin-top: -10rpx;
+
+			.indicator-bar {
+				width: 50rpx;
+				height: 8rpx;
+				background: #F2F2F2;
+				border-radius: 4rpx;
+				position: relative;
+				
+				&::after {
+					content: "";
+					position: absolute;
+					left: 0;
+					top: 0;
+					width: 25rpx;
+					height: 100%;
+					background: #5B37FD;
+					border-radius: 4rpx;
 				}
 			}
+		}
+	}
 
-			.medic {
-				box-sizing: border-box;
-				width: calc(100% - 200upx);
-				height: 100%;
-				padding: 0 30upx;
+	.product-section {
+		.product-list {
+			display: flex;
+			flex-wrap: wrap;
+			justify-content: space-between;
 
-				.banner-box {
-					margin-top: 30rpx;
+			.product-item {
+				width: 335rpx;
+				background: #FFFFFF;
+				border-radius: 20rpx;
+				overflow: hidden;
+				margin-bottom: 20rpx;
+
+				.product-img {
 					width: 100%;
-					height: 160upx;
-					border-radius: 10upx;
-					overflow: hidden;
-
-					.swiper,
-					.swiper-item,
-					.swiper-item image {
-						width: 100%;
-						height: 100%;
-					}
+					height: 335rpx;
 				}
 
-				.medic-list {
-					box-sizing: border-box;
-					padding: 30upx 0;
-					overflow-y: auto;
-					// height: calc(100% - 100upx);
-					height: 100%;
-					position: relative;
-					// .item{
-					// 	.title{
-					// 		font-size: 28upx;
-					// 		font-family: PingFang SC;
-					// 		font-weight: bold;
-					// 		color: #333333;
-					// 		padding-top: 20upx;
-					// 		margin-bottom: 30upx;
-					// 	}
-
-					// }
-					.inner-list {
+				.product-info {
+					padding: 20rpx;
+
+					.product-title {
+						font-size: 28rpx;
+						color: #333;
+						line-height: 40rpx;
+						height: 80rpx;
+						margin-bottom: 16rpx;
+						font-weight: 500;
+					}
+
+					.price-row {
 						display: flex;
-						flex-wrap: wrap;
-
-						.definite {
-							width: calc(50% - 30upx);
-							margin-right: 30upx;
-							margin-bottom: 30upx;
-
-							.img-box {
-								width: 100%;
-								height: 220upx;
-								background: #F5F5F5;
-								border-radius: 8upx;
-								overflow: hidden;
-								display: flex;
-								align-items: center;
-
-								image {
-									max-width: 100%;
-								}
-							}
-
-							.name {
-								width: 100%;
-								margin-top: 20upx;
-								font-size: 24upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #666666;
-								text-align: center;
-							}
-
-							&:nth-child(2n) {
-								margin-right: 0;
-							}
+						align-items: baseline;
+
+						.price-symbol {
+							font-size: 24rpx;
+							color: #FF4D4F;
+							font-weight: bold;
+						}
+
+						.price-integer {
+							font-size: 36rpx;
+							color: #FF4D4F;
+							font-weight: bold;
+						}
+
+						.price-decimal {
+							font-size: 24rpx;
+							color: #FF4D4F;
+							font-weight: bold;
+						}
+
+						.original-price {
+							font-size: 24rpx;
+							color: #999;
+							text-decoration: line-through;
+							margin-left: 10rpx;
 						}
 					}
 				}
 			}
 		}
+	}
+
+	.ellipsis-2 {
+		display: -webkit-box;
+		-webkit-box-orient: vertical;
+		-webkit-line-clamp: 2;
+		overflow: hidden;
+	}
+
+	.empty-box {
+		padding: 100rpx 0;
+		display: flex;
+		flex-direction: column;
+		align-items: center;
+
+		.empty-img {
+			width: 200rpx;
+			height: 150rpx;
+			margin-bottom: 20rpx;
+		}
 
+		.empty-text {
+			font-size: 24rpx;
+			color: #999;
+		}
 	}
-</style>
+</style>

+ 612 - 230
pages/user/index.vue

@@ -1,271 +1,653 @@
 <template>
-	<view class="page-container">
-		<!-- 顶部背景 -->
-		<view class="top-bg">
-			<view class="status_bar" :style="{ height: statusBarHeight }"></view>
-			<view class="top-title">个人中心</view>
-		</view>
-
-		<!-- 用户卡片 -->
-		<view class="user-card">
-			<view class="user-info" @click="navgetTo('/pages_user/user/personInfo')">
-				<image class="avatar" :src="user.avatarUrl ? user.avatarUrl : '/static/avatar.png'" mode="aspectFill"></image>
-				<view class="info-content">
-					<view class="name-row">
-						<text class="nickname">{{ user.nickname || '立即登录' }}</text>
-						<image class="arrow-right" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+	<view>
+		<view class="top-cont">
+			<view class="top-inner">			
+				<!-- 这里是状态栏 -->
+				<view class="status_bar" :style="{height: statusBarHeight}"></view>
+				<view class="user-info">
+					<view class="left">
+						<view class="head-img">
+							<image :src="user.avatar==null?'/static/detault_head.jpg':user.avatar" mode="aspectFill"></image>
+						</view>
+						<view class="name-phone"  v-if="UserInfo">
+							<view class="name">{{user.nickname}}
+								<text class="fs24 ml12 base-color mb20 " v-if="user.isShow==1"
+								>会员</text>
+								<text class="fs24 ml12 mb20 " style="color: #666;" v-else
+								>非会员</text>
+							</view>
+							<view class="phone">{{utils.parsePhone(user.phone)}}</view>
+						</view>
+						<view class="fs40 bold name-phone center " @click='getOrderCount()' 
+						v-else>立即登录</view>
+					</view>
+					<view class="right">
+						<uni-badge size="small" :text="msgNum" absolute="rightTop" type="error">
+							<view class="set" @click="navgetTo('/pages_user/user/personInfo')">
+								<image src="/static/set.png" mode=""></image>
+							</view>
+						</uni-badge>
+						<!-- <uni-badge size="small" :text="msgNum" absolute="rightTop" type="error">
+							<view class="msg-box" @click="navgetTo('/pages_user/user/message')">
+								<image src="/static/icon-msg.png" mode=""></image>
+							</view>
+							
+						</uni-badge> -->
 					</view>
-					<view class="welcome-text">Hi,欢迎来到小程序</view>
-				</view>
-			</view>
-		</view>
-
-		<!-- 菜单列表 -->
-		<view class="menu-list">
-			<view class="menu-item" @click="navgetTo('/pages_user/user/storeOrder')">
-				<view class="left">
-					<image class="icon" src="/static/manageTabIcon/training.png" mode="aspectFit"></image>
-					<text class="label">我的课程</text>
 				</view>
-				<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
-			</view>
-			<view class="menu-item" @click="navgetTo('/pages_user/user/message')">
-				<view class="left">
-					<image class="icon" src="/static/manageTabIcon/liveclasses.png" mode="aspectFit"></image>
-					<text class="label">我的消息</text>
+				<!-- 我的订单 -->
+				<view class="my-order" v-if="user.isShow==1">
+					<view class="inner">
+						<view class="title-box">
+							<text class="title">我的订单</text>
+							<view class="all-order" @click="showOrder('')">
+								<text class="text">全部订单</text>
+								<image src="/static/right_arrow.png" mode=""></image>
+							</view>
+						</view>
+						<view class="status-box">
+							<uni-badge size="small" :text=count0 absolute="rightTop" type="error">
+								<view class="item" @click="showOrder('0')">
+									<image src="/static/payment.png" mode=""></image>
+									<text class="text">待付款</text>
+								</view>
+							</uni-badge>
+							<uni-badge size="small" :text=count1 absolute="rightTop" type="error">
+							<view class="item" @click="showOrder('1')">
+								<image src="/static/send_goods.png" mode=""></image>
+								<text class="text">待发货</text>
+							</view>
+							</uni-badge>
+							<uni-badge size="small" :text=count2 absolute="rightTop" type="error">
+							<view class="item" @click="showOrder('2')">
+								<image src="/static/sou_goods.png" mode=""></image>
+								<text class="text">待收货</text>
+							</view>
+							</uni-badge>
+							<view class="item" @click="showOrder('3')">
+								<image src="/static/completed.png" mode=""></image>
+								<text class="text">已完成</text>
+							</view>
+							<uni-badge size="small" :text=afterSalesCount absolute="rightTop" type="error">
+							<view class="item" @click="navgetTo('/pages_user/user/refundOrderList')">
+								<image src="/static/after_sales.png" mode=""></image>
+								<text class="text">售后/退款</text>
+							</view>
+							</uni-badge>
+						</view>
+					</view>
 				</view>
-				<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
-			</view>
-		</view>
 
-		<view class="menu-list mt24">
-			<view class="menu-item" @click="makePhoneCall">
-				<view class="left">
-					<image class="icon" src="/static/service_center.png" mode="aspectFit"></image>
-					<text class="label">客服中心</text>
-				</view>
-				<view class="right">
-					<text class="phone-num">400-023-8558</text>
-					<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+				<view class="content">
+					<!-- 常用工具 -->
+					<view class="used-tools">
+						<view class="title">我的服务</view>
+						
+						<view class="my-modules">
+							<view class="module-item" @click="navgetTo('/pages/learn/index')">
+								<image class="bg" src="/static/bg_myclass.png" mode="aspectFill"></image>
+								<image class="icon" src="/static/icon_myclass.png" mode=""></image>
+								<view class="module-info">
+									<text class="m-title">我的课程</text>
+									<view class="m-desc">开始学习<image class="desc-icon" src="/static/icon_direction_right2.png" mode=""></image></view>
+								</view>
+							</view>
+							<view class="module-item" @click="navgetTo('')">
+								<image class="bg" src="/static/bg_video.png" mode="aspectFill"></image>
+								<image class="icon" src="/static/icon_video.png" mode=""></image>
+								<view class="module-info">
+									<text class="m-title">我的收藏</text>
+									<view class="m-desc color">立即查看<image class="desc-icon" src="/static/icon_direction_right.png" mode=""></image></view>
+								</view>
+							</view>
+						</view>
+						
+						<view class="tools-list">
+							<view class="item no-marin-bottom" @click="navgetTo('/pages_user/user/storeProductRelation')">
+								<image src="/static/footprint.png" mode=""></image>
+								<text class="text">我的足迹</text>
+							</view>
+							<view class="item" @click="navgetTo('/pages_user/user/address')" v-if="user.isShow==1">
+								<image src="/static/address.png" mode=""></image>
+								<text class="text">收货地址</text>
+							</view>
+							<view class="item no-marin-bottom" @click="navgetTo('/pages_user/user/integral')">
+								<image src="/static/integral.png" mode=""></image>
+								<text class="text">积分管理</text>
+							</view>
+							<view class="item no-marin-bottom"  @click="navgetTo('/pages_shopping/shopping/myCoupon')">
+								<image src="/static/mycoupon.png" mode=""></image>
+								<text class="text">优惠券</text>
+							</view>
+							
+							<view class="item no-marin-bottom"  @click="navgetTo('/pages/home/cert')">
+								<image src="/static/qualification.png" mode=""></image>
+								<text class="text">资质证书</text>
+							</view>
+								
+							<view class="item no-marin-bottom">
+								<image src="/static/customer1.png" mode=""></image>
+								<text class="text">专属客服</text>
+								<button class="contact-btn" open-type="contact"></button>
+							</view>
+							<view class="item no-marin-bottom" @click="openH5('userRegister')">
+								<image src="/static/service_file.png" mode=""></image>
+								<text class="text">用户协议</text>
+							</view>
+							<view class="item no-marin-bottom align-top"  @click="openH5('userPrivacy')">
+								<image src="/static/advice.png" mode=""></image>
+								<text class="text">隐私保护</text>
+							</view>
+							<!-- <view v-if="user.isPromoter==0" class="item no-marin-bottom"  @click="navgetTo('/pages_user/user/userTuiAdd')">
+								<image src="/static/my_promotion.png" mode=""></image>
+								<text class="text">申请健康大使</text>
+							</view> -->
+							<!-- <view v-if="user.isPromoter==1" class="item no-marin-bottom"  @click="navgetTo('/pages_user/user/userTui')">
+								<image src="/static/my_promotion.png" mode=""></image>
+								<text class="text">我的推广</text>
+							</view> -->
+							
+							<view class="item no-marin-bottom" @click="toManager()">
+								<image src="/static/sale_file.png" mode=""></image>
+								<text class="text">制单管理</text>
+							</view>
+							<!-- <view class="item no-marin-bottom" @click="toManagerCourse()">
+							 	<image src="/static/sale_file.png" mode=""></image>
+							 	<text class="text">销售管理</text>
+							 </view> -->
+						</view>
+					</view>
 				</view>
-			</view>
-			<view class="menu-item" @click="navgetTo('/pages_user/user/personInfo')">
-				<view class="left">
-					<image class="icon" src="/static/set_icon.png" mode="aspectFit"></image>
-					<text class="label">设置</text>
+				<!-- <view class="banner">
+					<image src="https://hos-1309931967.cos.ap-chongqing.myqcloud.com/fs/20221125/71ddd95044bb46d5b27e19a5f61cf5ab.png"></image>
+					<view class="tel_btn" @click="callService()"></view>
+				</view> -->
+				<view style="padding-bottom: 20rpx;" v-if="UserInfo">
+					<view @tap="loginOUt" class="log-out x-c" >退出登录</view>
 				</view>
-				<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+				<!-- <view class="like-product">
+					<likeProduct  ref="product" />
+				</view> -->
+				
+				<!-- 退出登录按钮 -->
+				
 			</view>
-		</view>
-
-		<!-- 退出登录 -->
-		<view class="logout-btn" v-if="UserInfo" @tap="loginOUt">
-			退出登录
+			
 		</view>
 	</view>
 </template>
 
 <script>
-import {
-	getUserInfo
-} from '@/api/user'
-export default {
-	data() {
-		return {
-			user: {
-				nickname: "",
-				avatarUrl: "/static/avatar.png"
-			},
-			statusBarHeight: uni.getStorageSync('menuInfo') ? uni.getStorageSync('menuInfo').statusBarHeight : 20,
-			UserInfo: uni.getStorageSync('AppToken')
-		};
-	},
-	onShow() {
-		this.UserInfo = uni.getStorageSync('AppToken')
-		if (this.UserInfo) {
-			this.getUserInfo()
-		}
-	},
-	methods: {
-		getUserInfo() {
-			getUserInfo().then(
-				res => {
-					if (res.code == 200 && res.user != null) {
-						this.user = res.user;
+	import {getOrderCount} from '@/api/storeOrder'
+	import {getUserInfo} from '@/api/user'
+	import likeProduct from '@/components/likeProduct.vue'
+	export default {
+		components: {
+			likeProduct
+		},
+		data() {
+			return {
+				count0:0,
+				count1:0,
+				count2:0,
+				afterSalesCount:0,
+				user:{
+					isPromoter:0,
+					isWeixinAuth:0,
+					phone:"",
+					nickname:"用户昵称",
+					avatarUrl:"/static/detault_head.png"
+				},
+				// 状态栏的高度
+				statusBarHeight: uni.getStorageSync('menuInfo').statusBarHeight,
+				// 消息数量
+				msgNum: 0,
+				UserInfo:uni.getStorageSync('AppToken')
+			};
+		},
+		watch: {
+		    UserInfo() {
+		        return uni.getStorageSync('AppToken')
+		    }
+		},
+		onLoad() {
+			console.log("onload")
+		},
+		onShow() {
+			console.log("onshow")
+			this.UserInfo = uni.getStorageSync('AppToken') // 强制更新登录状态
+			if(this.UserInfo){
+				this.getUserInfo()
+			}else{
+				// this.isuser=true
+			}
+			// this.getUserInfo();
+			// this.getOrderCount();
+		},
+		onReachBottom() {
+			console.log("onReachBottom")
+			this.$refs.product.getGoodsProducts();
+		},
+		methods: {
+			callService(){
+				let orderKey='5d81cf01-6f8d-4e1a-ae7a-dbc26c965b01';
+				uni.navigateTo({
+					url: '/pages_company/order/confirmOrder?orderKey='+orderKey
+				})
+				return;
+				
+				 uni.makePhoneCall({
+					phoneNumber:"4000717770",
+					success:function(){
+						console.log('拨打电话成功');
+					},
+					fail() {
+						console.log('打电话失败了');
 					}
+				})
+			},
+			 
+			getOrderCount(){
+				getOrderCount().then(
+					res => {
+						if(res.code==200){
+							this.count0=res.count0;
+							this.count1=res.count1; 
+							this.count2=res.count2; 
+							this.afterSalesCount=res.afterSalesCount; 
+						} 
+					},
+					rej => {}
+				);
+			},
+			toManager(){
+				if(this.utils.checkCompanyUserLoginState()){
+					uni.navigateTo({
+						url: '/pages_company/index'
+					})
 				}
-			);
-		},
-		navgetTo(url) {
-			this.utils.isLogin().then(res => {
-				if (res) {
+				else{
 					uni.navigateTo({
-						url: url
+						url: '/pages_company/auth/login'
 					})
 				}
-			})
-		},
-		makePhoneCall() {
-			uni.makePhoneCall({
-				phoneNumber: '400-023-8558'
-			});
-		},
-		loginOUt() {
-			this.utils.loginOut();
-			this.UserInfo = "";
-			this.user = {
-				nickname: "",
-				avatarUrl: "/static/avatar.png"
-			};
+				
+			},
+			toManagerCourse(){
+				if(uni.getStorageSync('ManageToken')){
+					uni.navigateTo({
+						url: '/pages_manage/index'
+					})
+				}
+				else{
+					uni.navigateTo({
+						url: '/pages_manage/login'
+					})
+				}
+				
+			},
+			openH5(url){
+				var requestPath = uni.getStorageSync('requestPath');
+				uni.setStorageSync('url',requestPath+url);
+				uni.navigateTo({
+					url: '../home/h5?data='+url
+				})
+			},
+			getUserInfo(){
+				getUserInfo().then(
+					res => {
+						if(res.code==200){
+							if(res.user!=null){
+								this.user=res.user;
+							}
+							else{
+								this.utils.loginOut();
+							}
+							
+						}else{
+							uni.showToast({
+								icon:'none',
+								title: "请求失败",
+							});
+						}
+					},
+					rej => {}
+				);
+			},
+			// 跳转页面
+			navgetTo(url) {
+				this.utils.isLogin().then(res => {
+					if(res){
+						uni.navigateTo({
+							url: url
+						})
+					}
+				})
+			},
+			// 查看订单
+			showOrder(status) {
+				uni.navigateTo({
+					url: '/pages_user/user/storeOrder?status=' + status
+				})
+			},
+			loginOUt(){
+				this.utils.loginOut();
+				this.getUserInfo();
+			}
 		}
 	}
-}
 </script>
 
 <style lang="scss" scoped>
-.page-container {
-	width: 100%;
-	min-height: 100vh;
-	background-color: #F8F9FB;
-	padding-bottom: 120rpx;
-}
-
-.top-bg {
-	width: 100%;
-	height: 380rpx;
-	background: linear-gradient(180deg, #5C4BFF 0%, #7E71FF 100%);
-	display: flex;
-	flex-direction: column;
-
-	.status_bar {
+	.top-cont{
 		width: 100%;
-	}
-
-	.top-title {
-		height: 88rpx;
-		display: flex;
-		align-items: center;
-		justify-content: center;
-		font-size: 36rpx;
-		font-weight: bold;
-		color: #FFFFFF;
-	}
-}
-
-.user-card {
-	margin: -160rpx 30rpx 0;
-	background: #FFFFFF;
-	border-radius: 24rpx;
-	padding: 40rpx;
-	box-shadow: 0 4rpx 20rpx rgba(92, 75, 255, 0.1);
-
-	.user-info {
-		display: flex;
-		align-items: center;
-
-		.avatar {
-			width: 120rpx;
-			height: 120rpx;
-			border-radius: 50%;
-			margin-right: 30rpx;
-			background-color: #f5f5f5;
-		}
-
-		.info-content {
-			flex: 1;
-
-			.name-row {
+		height: 494upx;
+		position: relative;
+		// background-image: url(/static/personl_top_bg.png);
+		background-repeat: repeat-x;
+		background-size: 40upx 100%;
+		.top-inner{
+			width: 100%;
+			height: 100%;
+			position: absolute;
+			top: 0;
+			left: 0;
+			z-index: 2;
+			.user-info{
+				padding: 88upx 30upx 0 30upx;
 				display: flex;
 				align-items: center;
-				margin-bottom: 12rpx;
-
-				.nickname {
-					font-size: 40rpx;
-					font-weight: bold;
-					color: #1A1A1A;
-					margin-right: 12rpx;
+				justify-content: space-between;
+				.left{
+					position: relative;
+					display: flex;
+					.head-img{
+						width: 120upx;
+						height: 120upx;
+						border-radius: 50%;
+						overflow: hidden;
+						margin-right: 30upx;
+						border: 4upx solid #FFFFFF;
+						box-shadow: 0px 5px 15px 2px rgba(0,0,0,0.1);
+						image{
+							width: 100%;
+							height: 100%;
+						}
+					}
+					.name-phone{
+						padding-top: 15upx;
+						.name{
+							font-size: 40upx;
+							font-family: PingFang SC;
+							font-weight: bold;
+							color: #111111;
+							line-height: 1;
+						}
+						.phone{
+							font-size: 28upx;
+							font-family: PingFang SC;
+							font-weight: 500;
+							color: #666666;
+							line-height: 1;
+							margin-top: 30upx;
+						}
+					}
 				}
-
-				.arrow-right {
-					width: 24rpx;
-					height: 24rpx;
+				.right{
+					display: flex;
+					align-items: center;
+					justify-content: center;
+					.msg-box{
+						margin-left: 10upx;
+						width: 44upx;
+						height: 44upx;
+						image{
+							width: 100%;
+							height: 100%;
+						}
+					}
+					.set{
+						
+						width: 44upx;
+						height: 44upx;
+						image{
+							width: 100%;
+							height: 100%;
+						}
+					}
 				}
+				
 			}
-
-			.welcome-text {
-				font-size: 26rpx;
-				color: #999999;
+			.my-order{
+				padding: 50upx 20upx 0;
+				.inner{
+					box-sizing: border-box;
+					height: 245upx;
+					// height: 105upx;
+					background: #FFFFFF;
+					border-radius: 16upx;
+					padding: 40upx 30upx;
+					display: flex;
+					flex-direction: column;
+					justify-content: space-between;
+					.title-box{
+						display: flex;
+						align-items: center;
+						justify-content: space-between;
+						.title{
+							font-size: 34upx;
+							font-family: PingFang SC;
+							font-weight: bold;
+							color: #222222;
+							line-height: 1;
+						}
+						.all-order{
+							display: flex;
+							align-items: center;
+							.text{
+								font-size: 26upx;
+								font-family: PingFang SC;
+								font-weight: 500;
+								color: #999999;
+								line-height: 1;
+								margin-right: 8upx;
+							}
+							image{
+								width: 14upx;
+								height: 24upx;
+							}
+						}
+					}
+					.status-box{
+						display: flex;
+						align-items: center;
+						justify-content: space-between;
+						padding: 0 10upx;
+						.item{
+							display: flex;
+							flex-direction: column;
+							align-items: center;
+							justify-content: center;
+							image{
+								width: 40upx;
+								height: 40upx;
+								margin-bottom: 18upx;
+							}
+							.text{
+								font-size: 26upx;
+								font-family: PingFang SC;
+								font-weight: 500;
+								color: #111111;
+								line-height: 1;
+							}
+						}
+					}
+				}
 			}
+			
 		}
 	}
-}
-
-.menu-list {
-	margin: 30rpx 30rpx 0;
-	background: #FFFFFF;
-	border-radius: 24rpx;
-	padding: 0 30rpx;
-
-	.menu-item {
+	.content{
+		margin-top: 20upx;
+		padding: 0 20upx;
 		display: flex;
 		align-items: center;
-		justify-content: space-between;
-		height: 110rpx;
-		border-bottom: 1rpx solid #F5F6F8;
-
-		&:last-child {
-			border-bottom: none;
-		}
-
-		.left {
-			display: flex;
-			align-items: center;
-
-			.icon {
-				width: 44rpx;
-				height: 44rpx;
-				margin-right: 20rpx;
+		justify-content: center;
+		.used-tools{
+			box-sizing: border-box;
+			background: #FFFFFF;
+			border-radius: 16upx;
+			padding: 40upx 30upx;
+			width: 100%;
+			.title{
+				font-size: 34upx;
+				font-family: PingFang SC;
+				font-weight: bold;
+				color: #222222;
+				line-height: 1;
 			}
-
-			.label {
-				font-size: 30rpx;
-				color: #1A1A1A;
-				font-weight: 500;
+			.my-modules {
+				display: flex;
+				justify-content: space-between;
+				margin-top: 40upx;
+				.module-item {
+					position: relative;
+					width: 310upx;
+					height: 140upx;
+					border-radius: 16upx;
+					overflow: hidden;
+					display: flex;
+					align-items: center;
+					justify-content: space-around;
+					z-index: 2;
+					.icon{
+						// position: absolute;
+						// top: 20upx;
+						// left: 20upx;
+						width: 64upx;
+						height: 64upx;
+					}
+					.bg {
+						position: absolute;
+						top: 0;
+						left: 0;
+						width: 100%;
+						height: 100%;
+						z-index: -1;
+					}
+					.module-info {
+						position: relative;
+						z-index: 1;
+						padding: 25upx 20upx;
+						display: flex;
+						flex-direction: column;
+						.m-title {
+							font-size: 30upx;
+							font-weight: bold;
+							color: #222222;
+						}
+						.m-desc {
+							display: flex;
+							align-items: center;
+							font-size: 22upx;
+							color: #6154DC;
+							margin-top: 10upx;
+							&.color{
+								color: #F5723A;
+							}
+							.desc-icon{
+								width: 24upx;
+								height: 24upx;
+								margin-left:4upx;
+							}
+						}
+					}
+				}
 			}
-		}
-
-		.right {
-			display: flex;
-			align-items: center;
-
-			.phone-num {
-				font-size: 28rpx;
-				color: #666666;
-				margin-right: 12rpx;
+			.tools-list{
+				margin-top: 50upx;
+				display: flex;
+				flex-wrap: wrap;
+				width: 100%;
+				.item{
+					box-sizing: border-box;
+					width: 25%;
+					display: flex;
+					flex-direction: column;
+					align-items: center;
+					justify-content: center;
+					margin-bottom: 50upx;
+					position: relative;
+					image{
+						width: 44upx;
+						height: 44upx;
+					}
+					.text{
+						font-size: 24upx;
+						font-family: PingFang SC;
+						font-weight: 500;
+						color: #111111;
+						line-height: 1;
+						margin-top: 20upx;
+					}
+					.contact-btn{
+						display: inline-block;
+						position: absolute;
+						top: 0;
+						left: 0;
+						width: 100%;
+						height: 100%;
+						opacity: 0;
+					}
+				}
 			}
 		}
-
-		.arrow {
-			width: 24rpx;
-			height: 24rpx;
+	}
+	.log-out{
+		height: 80upx;
+		line-height: 80upx;
+		text-align: center;
+		font-size: 26upx;
+		font-family: PingFang SC;
+		font-weight: 500;
+		color: #666666;
+		background: #FFFFFF;
+		border-radius: 16upx;
+		margin-top: 20upx;
+	}
+	.sub-btn{
+		position: absolute;
+		width: 100%;
+		height: 100%;
+		opacity: 0;
+	}
+	.like-product{
+		padding: 0 20rpx;
+	}
+	.banner{
+		padding: 20rpx 20rpx 0rpx 20rpx;
+		height: 200rpx;
+		position: relative;
+		display: flex;
+		align-items: center;
+		justify-content: center;
+		image{
+			width:100%;
+			height: 100%;
+		}
+		.tel_btn{
+			width: 100%;
+			height: 100%;
+			top:0upx;
+			position: absolute;
+			opacity:0.0;
 		}
 	}
-}
-
-.mt24 {
-	margin-top: 24rpx;
-}
-
-.logout-btn {
-	margin: 40rpx 30rpx;
-	height: 100rpx;
-	background: #FFFFFF;
-	border-radius: 24rpx;
-	display: flex;
-	align-items: center;
-	justify-content: center;
-	font-size: 32rpx;
-	font-weight: bold;
-	color: #5C4BFF;
-}
+	
+	.log-out{
+		height: 100rpx;line-height: 100rpx;
+		margin: 10px;
+		border-radius: 20rpx;
+	}
+	
 </style>

+ 271 - 0
pages/user/indexLittle.vue

@@ -0,0 +1,271 @@
+<template>
+	<view class="page-container">
+		<!-- 顶部背景 -->
+		<view class="top-bg">
+			<view class="status_bar" :style="{ height: statusBarHeight }"></view>
+			<view class="top-title">个人中心</view>
+		</view>
+
+		<!-- 用户卡片 -->
+		<view class="user-card">
+			<view class="user-info" @click="navgetTo('/pages_user/user/personInfo')">
+				<image class="avatar" :src="user.avatarUrl ? user.avatarUrl : '/static/avatar.png'" mode="aspectFill"></image>
+				<view class="info-content">
+					<view class="name-row">
+						<text class="nickname">{{ user.nickname || '立即登录' }}</text>
+						<image class="arrow-right" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+					</view>
+					<view class="welcome-text">Hi,欢迎来到小程序</view>
+				</view>
+			</view>
+		</view>
+
+		<!-- 菜单列表 -->
+		<view class="menu-list">
+			<view class="menu-item" @click="navgetTo('/pages_user/user/storeOrder')">
+				<view class="left">
+					<image class="icon" src="/static/manageTabIcon/training.png" mode="aspectFit"></image>
+					<text class="label">我的课程</text>
+				</view>
+				<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+			</view>
+			<view class="menu-item" @click="navgetTo('/pages_user/user/message')">
+				<view class="left">
+					<image class="icon" src="/static/manageTabIcon/liveclasses.png" mode="aspectFit"></image>
+					<text class="label">我的消息</text>
+				</view>
+				<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+			</view>
+		</view>
+
+		<view class="menu-list mt24">
+			<view class="menu-item" @click="makePhoneCall">
+				<view class="left">
+					<image class="icon" src="/static/service_center.png" mode="aspectFit"></image>
+					<text class="label">客服中心</text>
+				</view>
+				<view class="right">
+					<text class="phone-num">400-023-8558</text>
+					<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+				</view>
+			</view>
+			<view class="menu-item" @click="navgetTo('/pages_user/user/personInfo')">
+				<view class="left">
+					<image class="icon" src="/static/set_icon.png" mode="aspectFit"></image>
+					<text class="label">设置</text>
+				</view>
+				<image class="arrow" src="/static/right_arrow_right.png" mode="aspectFit"></image>
+			</view>
+		</view>
+
+		<!-- 退出登录 -->
+		<view class="logout-btn" v-if="UserInfo" @tap="loginOUt">
+			退出登录
+		</view>
+	</view>
+</template>
+
+<script>
+import {
+	getUserInfo
+} from '@/api/user'
+export default {
+	data() {
+		return {
+			user: {
+				nickname: "",
+				avatarUrl: "/static/avatar.png"
+			},
+			statusBarHeight: uni.getStorageSync('menuInfo') ? uni.getStorageSync('menuInfo').statusBarHeight : 20,
+			UserInfo: uni.getStorageSync('AppToken')
+		};
+	},
+	onShow() {
+		this.UserInfo = uni.getStorageSync('AppToken')
+		if (this.UserInfo) {
+			this.getUserInfo()
+		}
+	},
+	methods: {
+		getUserInfo() {
+			getUserInfo().then(
+				res => {
+					if (res.code == 200 && res.user != null) {
+						this.user = res.user;
+					}
+				}
+			);
+		},
+		navgetTo(url) {
+			this.utils.isLogin().then(res => {
+				if (res) {
+					uni.navigateTo({
+						url: url
+					})
+				}
+			})
+		},
+		makePhoneCall() {
+			uni.makePhoneCall({
+				phoneNumber: '400-023-8558'
+			});
+		},
+		loginOUt() {
+			this.utils.loginOut();
+			this.UserInfo = "";
+			this.user = {
+				nickname: "",
+				avatarUrl: "/static/avatar.png"
+			};
+		}
+	}
+}
+</script>
+
+<style lang="scss" scoped>
+.page-container {
+	width: 100%;
+	min-height: 100vh;
+	background-color: #F8F9FB;
+	padding-bottom: 120rpx;
+}
+
+.top-bg {
+	width: 100%;
+	height: 380rpx;
+	background: linear-gradient(180deg, #5C4BFF 0%, #7E71FF 100%);
+	display: flex;
+	flex-direction: column;
+
+	.status_bar {
+		width: 100%;
+	}
+
+	.top-title {
+		height: 88rpx;
+		display: flex;
+		align-items: center;
+		justify-content: center;
+		font-size: 36rpx;
+		font-weight: bold;
+		color: #FFFFFF;
+	}
+}
+
+.user-card {
+	margin: -160rpx 30rpx 0;
+	background: #FFFFFF;
+	border-radius: 24rpx;
+	padding: 40rpx;
+	box-shadow: 0 4rpx 20rpx rgba(92, 75, 255, 0.1);
+
+	.user-info {
+		display: flex;
+		align-items: center;
+
+		.avatar {
+			width: 120rpx;
+			height: 120rpx;
+			border-radius: 50%;
+			margin-right: 30rpx;
+			background-color: #f5f5f5;
+		}
+
+		.info-content {
+			flex: 1;
+
+			.name-row {
+				display: flex;
+				align-items: center;
+				margin-bottom: 12rpx;
+
+				.nickname {
+					font-size: 40rpx;
+					font-weight: bold;
+					color: #1A1A1A;
+					margin-right: 12rpx;
+				}
+
+				.arrow-right {
+					width: 24rpx;
+					height: 24rpx;
+				}
+			}
+
+			.welcome-text {
+				font-size: 26rpx;
+				color: #999999;
+			}
+		}
+	}
+}
+
+.menu-list {
+	margin: 30rpx 30rpx 0;
+	background: #FFFFFF;
+	border-radius: 24rpx;
+	padding: 0 30rpx;
+
+	.menu-item {
+		display: flex;
+		align-items: center;
+		justify-content: space-between;
+		height: 110rpx;
+		border-bottom: 1rpx solid #F5F6F8;
+
+		&:last-child {
+			border-bottom: none;
+		}
+
+		.left {
+			display: flex;
+			align-items: center;
+
+			.icon {
+				width: 44rpx;
+				height: 44rpx;
+				margin-right: 20rpx;
+			}
+
+			.label {
+				font-size: 30rpx;
+				color: #1A1A1A;
+				font-weight: 500;
+			}
+		}
+
+		.right {
+			display: flex;
+			align-items: center;
+
+			.phone-num {
+				font-size: 28rpx;
+				color: #666666;
+				margin-right: 12rpx;
+			}
+		}
+
+		.arrow {
+			width: 24rpx;
+			height: 24rpx;
+		}
+	}
+}
+
+.mt24 {
+	margin-top: 24rpx;
+}
+
+.logout-btn {
+	margin: 40rpx 30rpx;
+	height: 100rpx;
+	background: #FFFFFF;
+	border-radius: 24rpx;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	font-size: 32rpx;
+	font-weight: bold;
+	color: #5C4BFF;
+}
+</style>

+ 0 - 573
pages/user/indexold.vue

@@ -1,573 +0,0 @@
-<template>
-	<view>
-		<view class="top-cont">
-			<view class="top-inner">			
-				<!-- 这里是状态栏 -->
-				<view class="status_bar" :style="{height: statusBarHeight}"></view>
-				<view class="user-info">
-					<view class="left">
-						<view class="head-img">
-							<image :src="user.avatar==null?'https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/detault_head.jpg':user.avatar" mode="aspectFill"></image>
-						</view>
-						<view class="name-phone"  v-if="UserInfo">
-							<view class="name">{{user.nickname}}
-								<text class="fs24 ml12 base-color mb20 " v-if="user.isShow==1"
-								>会员</text>
-								<text class="fs24 ml12 mb20 " style="color: #666;" v-else
-								>非会员</text>
-							</view>
-							<view class="phone">{{utils.parsePhone(user.phone)}}</view>
-						</view>
-						<view class="fs40 bold name-phone center " @click='getOrderCount()' 
-						v-else>立即登录</view>
-					</view>
-					<view class="right">
-						<uni-badge size="small" :text="msgNum" absolute="rightTop" type="error">
-							<view class="set" @click="navgetTo('/pages_user/user/personInfo')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/icon-set.png" mode=""></image>
-							</view>
-						</uni-badge>
-						<!-- <uni-badge size="small" :text="msgNum" absolute="rightTop" type="error">
-							<view class="msg-box" @click="navgetTo('/pages_user/user/message')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/icon-msg.png" mode=""></image>
-							</view>
-							
-						</uni-badge> -->
-					</view>
-				</view>
-				<!-- 我的订单 -->
-				<view class="my-order" v-if="user.isShow==1">
-					<view class="inner">
-						<view class="title-box">
-							<text class="title">我的订单</text>
-							<view class="all-order" @click="showOrder('')">
-								<text class="text">全部订单</text>
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/arrow4.png" mode=""></image>
-							</view>
-						</view>
-						<view class="status-box">
-							<uni-badge size="small" :text=count0 absolute="rightTop" type="error">
-								<view class="item" @click="showOrder('0')">
-									<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/payment.png" mode=""></image>
-									<text class="text">待付款</text>
-								</view>
-							</uni-badge>
-							<uni-badge size="small" :text=count1 absolute="rightTop" type="error">
-							<view class="item" @click="showOrder('1')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/send_goods.png" mode=""></image>
-								<text class="text">待发货</text>
-							</view>
-							</uni-badge>
-							<uni-badge size="small" :text=count2 absolute="rightTop" type="error">
-							<view class="item" @click="showOrder('2')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/sou_goods.png" mode=""></image>
-								<text class="text">待收货</text>
-							</view>
-							</uni-badge>
-							<view class="item" @click="showOrder('3')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/completed.png" mode=""></image>
-								<text class="text">已完成</text>
-							</view>
-							<uni-badge size="small" :text=afterSalesCount absolute="rightTop" type="error">
-							<view class="item" @click="navgetTo('/pages_user/user/refundOrderList')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/after_sales.png" mode=""></image>
-								<text class="text">售后/退款</text>
-							</view>
-							</uni-badge>
-						</view>
-					</view>
-				</view>
-
-				<view class="content">
-					<!-- 常用工具 -->
-					<view class="used-tools">
-						<view class="title">常用工具</view>
-						<view class="tools-list">
-							<view class="item" @click="navgetTo('/pages_user/user/address')" v-if="user.isShow==1">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/address.png" mode=""></image>
-								<text class="text">收货地址</text>
-							</view>
-							<!-- <view class="item no-marin-bottom" @click="navgetTo('/pages_user/user/integral')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/integral.png" mode=""></image>
-								<text class="text">积分管理</text>
-							</view> -->
-							<view class="item no-marin-bottom"  @click="navgetTo('/pages_shopping/shopping/myCoupon')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/mycoupon.png" mode=""></image>
-								<text class="text">优惠券</text>
-							</view>
-							<view class="item no-marin-bottom" @click="navgetTo('/pages_user/user/storeProductRelation')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/footprint.png" mode=""></image>
-								<text class="text">我的足迹</text>
-							</view>
-							<view class="item no-marin-bottom" @click="openH5('userRegister')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/service_file.png" mode=""></image>
-								<text class="text">用户协议</text>
-							</view>
-							<view class="item no-marin-bottom align-top"  @click="openH5('userPrivacy')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/advice.png" mode=""></image>
-								<text class="text">隐私保护</text>
-							</view>
-							<view class="item no-marin-bottom">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/customer1.png" mode=""></image>
-								<text class="text">专属客服</text>
-								<button class="contact-btn" open-type="contact"></button>
-							</view>
-							<!-- <view v-if="user.isPromoter==0" class="item no-marin-bottom"  @click="navgetTo('/pages_user/user/userTuiAdd')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/my_promotion.png" mode=""></image>
-								<text class="text">申请健康大使</text>
-							</view> -->
-							<!-- <view v-if="user.isPromoter==1" class="item no-marin-bottom"  @click="navgetTo('/pages_user/user/userTui')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/my_promotion.png" mode=""></image>
-								<text class="text">我的推广</text>
-							</view> -->
-							<!-- <view class="item no-marin-bottom"  @click="navgetTo('/pages/home/cert')">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/qualification.png" mode=""></image>
-								<text class="text">资质证书</text>
-							</view> -->
-	
-							<view class="item no-marin-bottom" @click="toManager()">
-								<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/sale_file.png" mode=""></image>
-								<text class="text">制单管理</text>
-							</view>
-							 <view class="item no-marin-bottom" @click="toManagerCourse()">
-							 	<image src="https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/sale_file.png" mode=""></image>
-							 	<text class="text">销售管理</text>
-							 </view>
-						</view>
-					</view>
-				</view>
-				<!-- <view class="banner">
-					<image src="https://hos-1309931967.cos.ap-chongqing.myqcloud.com/fs/20221125/71ddd95044bb46d5b27e19a5f61cf5ab.png"></image>
-					<view class="tel_btn" @click="callService()"></view>
-				</view> -->
-				<view style="padding-bottom: 20rpx;" v-if="UserInfo">
-					<view @tap="loginOUt" class="log-out x-c" >退出登录</view>
-				</view>
-				<view class="like-product">
-					<likeProduct  ref="product" />
-				</view>
-				
-				<!-- 退出登录按钮 -->
-				
-			</view>
-			
-		</view>
-	</view>
-</template>
-
-<script>
-	import {getOrderCount} from '@/api/storeOrder'
-	import {getUserInfo} from '@/api/user'
-	import likeProduct from '@/components/likeProduct.vue'
-	export default {
-		components: {
-			likeProduct
-		},
-		data() {
-			return {
-				count0:0,
-				count1:0,
-				count2:0,
-				afterSalesCount:0,
-				user:{
-					isPromoter:0,
-					isWeixinAuth:0,
-					phone:"",
-					nickname:"用户昵称",
-					avatarUrl:"https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/detault_head.png"
-				},
-				// 状态栏的高度
-				statusBarHeight: uni.getStorageSync('menuInfo').statusBarHeight,
-				// 消息数量
-				msgNum: 0,
-				UserInfo:uni.getStorageSync('AppToken')
-			};
-		},
-		watch: {
-		    UserInfo() {
-		        return uni.getStorageSync('AppToken')
-		    }
-		},
-		onLoad() {
-			console.log("onload")
-		},
-		onShow() {
-			console.log("onshow")
-			this.UserInfo = uni.getStorageSync('AppToken') // 强制更新登录状态
-			if(this.UserInfo){
-				this.getUserInfo()
-			}else{
-				// this.isuser=true
-			}
-			// this.getUserInfo();
-			// this.getOrderCount();
-		},
-		onReachBottom() {
-			console.log("onReachBottom")
-			this.$refs.product.getGoodsProducts();
-		},
-		methods: {
-			callService(){
-				let orderKey='5d81cf01-6f8d-4e1a-ae7a-dbc26c965b01';
-				uni.navigateTo({
-					url: '/pages_company/order/confirmOrder?orderKey='+orderKey
-				})
-				return;
-				
-				 uni.makePhoneCall({
-					phoneNumber:"4000717770",
-					success:function(){
-						console.log('拨打电话成功');
-					},
-					fail() {
-						console.log('打电话失败了');
-					}
-				})
-			},
-			 
-			getOrderCount(){
-				getOrderCount().then(
-					res => {
-						if(res.code==200){
-							this.count0=res.count0;
-							this.count1=res.count1; 
-							this.count2=res.count2; 
-							this.afterSalesCount=res.afterSalesCount; 
-						} 
-					},
-					rej => {}
-				);
-			},
-			toManager(){
-				if(this.utils.checkCompanyUserLoginState()){
-					uni.navigateTo({
-						url: '/pages_company/index'
-					})
-				}
-				else{
-					uni.navigateTo({
-						url: '/pages_company/auth/login'
-					})
-				}
-				
-			},
-			toManagerCourse(){
-				if(uni.getStorageSync('ManageToken')){
-					uni.navigateTo({
-						url: '/pages_manage/index'
-					})
-				}
-				else{
-					uni.navigateTo({
-						url: '/pages_manage/login'
-					})
-				}
-				
-			},
-			openH5(url){
-				var requestPath = uni.getStorageSync('requestPath');
-				uni.setStorageSync('url',requestPath+url);
-				uni.navigateTo({
-					url: '../home/h5?data='+url
-				})
-			},
-			getUserInfo(){
-				getUserInfo().then(
-					res => {
-						if(res.code==200){
-							if(res.user!=null){
-								this.user=res.user;
-							}
-							else{
-								this.utils.loginOut();
-							}
-							
-						}else{
-							uni.showToast({
-								icon:'none',
-								title: "请求失败",
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 跳转页面
-			navgetTo(url) {
-				this.utils.isLogin().then(res => {
-					if(res){
-						uni.navigateTo({
-							url: url
-						})
-					}
-				})
-			},
-			// 查看订单
-			showOrder(status) {
-				uni.navigateTo({
-					url: '/pages_user/user/storeOrder?status=' + status
-				})
-			},
-			loginOUt(){
-				this.utils.loginOut();
-				this.getUserInfo();
-			}
-		}
-	}
-</script>
-
-<style lang="scss" scoped>
-	.top-cont{
-		width: 100%;
-		height: 494upx;
-		position: relative;
-		background-image: url(https://zlwh.obs.cn-southwest-2.myhuaweicloud.com/orangeShop/personl_top_bg.png);
-		background-repeat: repeat-x;
-		background-size: 40upx 100%;
-		.top-inner{
-			width: 100%;
-			height: 100%;
-			position: absolute;
-			top: 0;
-			left: 0;
-			z-index: 2;
-			.user-info{
-				padding: 88upx 30upx 0 30upx;
-				display: flex;
-				align-items: center;
-				justify-content: space-between;
-				.left{
-					position: relative;
-					display: flex;
-					.head-img{
-						width: 120upx;
-						height: 120upx;
-						border-radius: 50%;
-						overflow: hidden;
-						margin-right: 30upx;
-						border: 4upx solid #FFFFFF;
-						box-shadow: 0px 5px 15px 2px rgba(0,0,0,0.1);
-						image{
-							width: 100%;
-							height: 100%;
-						}
-					}
-					.name-phone{
-						padding-top: 15upx;
-						.name{
-							font-size: 40upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #111111;
-							line-height: 1;
-						}
-						.phone{
-							font-size: 28upx;
-							font-family: PingFang SC;
-							font-weight: 500;
-							color: #666666;
-							line-height: 1;
-							margin-top: 30upx;
-						}
-					}
-				}
-				.right{
-					display: flex;
-					align-items: center;
-					justify-content: center;
-					.msg-box{
-						margin-left: 10upx;
-						width: 44upx;
-						height: 44upx;
-						image{
-							width: 100%;
-							height: 100%;
-						}
-					}
-					.set{
-						
-						width: 44upx;
-						height: 44upx;
-						image{
-							width: 100%;
-							height: 100%;
-						}
-					}
-				}
-				
-			}
-			.my-order{
-				padding: 50upx 20upx 0;
-				.inner{
-					box-sizing: border-box;
-					height: 245upx;
-					// height: 105upx;
-					background: #FFFFFF;
-					border-radius: 16upx;
-					padding: 40upx 30upx;
-					display: flex;
-					flex-direction: column;
-					justify-content: space-between;
-					.title-box{
-						display: flex;
-						align-items: center;
-						justify-content: space-between;
-						.title{
-							font-size: 34upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #222222;
-							line-height: 1;
-						}
-						.all-order{
-							display: flex;
-							align-items: center;
-							.text{
-								font-size: 26upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #999999;
-								line-height: 1;
-								margin-right: 8upx;
-							}
-							image{
-								width: 14upx;
-								height: 24upx;
-							}
-						}
-					}
-					.status-box{
-						display: flex;
-						align-items: center;
-						justify-content: space-between;
-						padding: 0 10upx;
-						.item{
-							display: flex;
-							flex-direction: column;
-							align-items: center;
-							justify-content: center;
-							image{
-								width: 40upx;
-								height: 40upx;
-								margin-bottom: 18upx;
-							}
-							.text{
-								font-size: 26upx;
-								font-family: PingFang SC;
-								font-weight: 500;
-								color: #111111;
-								line-height: 1;
-							}
-						}
-					}
-				}
-			}
-			
-		}
-	}
-	.content{
-		margin-top: 20upx;
-		padding: 0 20upx;
-		display: flex;
-		align-items: center;
-		justify-content: center;
-		.used-tools{
-			box-sizing: border-box;
-			background: #FFFFFF;
-			border-radius: 16upx;
-			padding: 40upx 30upx;
-			
-			.title{
-				font-size: 34upx;
-				font-family: PingFang SC;
-				font-weight: bold;
-				color: #222222;
-				line-height: 1;
-			}
-			.tools-list{
-				margin-top: 50upx;
-				display: flex;
-				flex-wrap: wrap;
-				width: 100%;
-				.item{
-					box-sizing: border-box;
-					width: 25%;
-					display: flex;
-					flex-direction: column;
-					align-items: center;
-					justify-content: center;
-					margin-bottom: 50upx;
-					position: relative;
-					image{
-						width: 44upx;
-						height: 44upx;
-					}
-					.text{
-						font-size: 24upx;
-						font-family: PingFang SC;
-						font-weight: 500;
-						color: #111111;
-						line-height: 1;
-						margin-top: 20upx;
-					}
-					.contact-btn{
-						display: inline-block;
-						position: absolute;
-						top: 0;
-						left: 0;
-						width: 100%;
-						height: 100%;
-						opacity: 0;
-					}
-				}
-			}
-		}
-	}
-	.log-out{
-		height: 80upx;
-		line-height: 80upx;
-		text-align: center;
-		font-size: 26upx;
-		font-family: PingFang SC;
-		font-weight: 500;
-		color: #666666;
-		background: #FFFFFF;
-		border-radius: 16upx;
-		margin-top: 20upx;
-	}
-	.sub-btn{
-		position: absolute;
-		width: 100%;
-		height: 100%;
-		opacity: 0;
-	}
-	.like-product{
-		padding: 0 20rpx;
-	}
-	.banner{
-		padding: 20rpx 20rpx 0rpx 20rpx;
-		height: 200rpx;
-		position: relative;
-		display: flex;
-		align-items: center;
-		justify-content: center;
-		image{
-			width:100%;
-			height: 100%;
-		}
-		.tel_btn{
-			width: 100%;
-			height: 100%;
-			top:0upx;
-			position: absolute;
-			opacity:0.0;
-		}
-	}
-	
-	.log-out{
-		height: 100rpx;line-height: 100rpx;
-		margin: 10px;
-		border-radius: 20rpx;
-	}
-	
-</style>

BIN
static/address.png


BIN
static/advice.png


BIN
static/after_sales.png


BIN
static/avatar.png


BIN
static/bg_myclass.png


BIN
static/bg_video.png


BIN
static/class_lock.png


BIN
static/class_play.png


BIN
static/class_video.png


BIN
static/collect.png


BIN
static/collected.png


BIN
static/completed.png


BIN
static/course_number.png


BIN
static/course_number_bg.png


BIN
static/customer1.png


BIN
static/footprint.png


BIN
static/icon_arrow_down.png


BIN
static/icon_direction_right.png


BIN
static/icon_direction_right2.png


BIN
static/icon_myclass.png


BIN
static/icon_video.png


BIN
static/integral.png


BIN
static/layer_share_icon16@3x.png


BIN
static/menu1.png


BIN
static/menu2.png


BIN
static/menu3.png


BIN
static/menu4.png


BIN
static/mycoupon.png


BIN
static/orangetabbar/home.png


BIN
static/orangetabbar/home_pre.png


BIN
static/orangetabbar/live.png


BIN
static/orangetabbar/live_pre.png


BIN
static/orangetabbar/mine.png


BIN
static/orangetabbar/mine_pre.png


BIN
static/orangetabbar/new.png


BIN
static/orangetabbar/new_pre.png


BIN
static/orangetabbar/shop.png


BIN
static/orangetabbar/shop_pre.png


BIN
static/payment.png


BIN
static/purple_home_top_bg.png


BIN
static/qualification.png


BIN
static/right_arrow_white.png


BIN
static/sale_file.png


BIN
static/send_goods.png


BIN
static/service_file.png


BIN
static/set.png


BIN
static/shop_home.png


BIN
static/shop_meau1.png


BIN
static/shop_meau10.png


BIN
static/shop_meau2.png


BIN
static/shop_meau3.png


BIN
static/shop_meau4.png


BIN
static/shop_meau5.png


BIN
static/shop_meau6.png


BIN
static/shop_meau7.png


BIN
static/shop_meau8.png


BIN
static/shop_meau9.png


BIN
static/shop_message.png


BIN
static/shop_service.png


BIN
static/shop_shopping_car.png


BIN
static/shop_weixin.png


BIN
static/shopping_car.png


BIN
static/sort_icon.png


BIN
static/sou_goods.png


BIN
static/video_icon20@2x.png