Browse Source

提交

dev_xrcc
chenkainan 4 months ago
parent
commit
63b0992886
  1. 2
      components/header.vue
  2. 7
      manifest.json
  3. 5
      package-lock.json
  4. 1
      package.json
  5. 7
      pages.json
  6. 654
      pages/index/iSoul.vue
  7. 24
      pages/index/index.vue
  8. 268
      pages/index/readingBody.vue
  9. 113
      pages/index/sensoryStore.vue
  10. 258
      pages/login/login.vue
  11. 100
      subPackages/haveFeeling/detailXiang.vue

2
components/header.vue

@ -2,7 +2,7 @@
<view class="header" :style="{'height': height+'px','padding-top':statusBarHeight+'px'}"> <view class="header" :style="{'height': height+'px','padding-top':statusBarHeight+'px'}">
<image src="https://static.ticket.sz-trip.com/epicSoul/readingBody/search.png" mode="heightFix"></image> <image src="https://static.ticket.sz-trip.com/epicSoul/readingBody/search.png" mode="heightFix"></image>
<image src="https://static.ticket.sz-trip.com/uploads/20250625/9bb05097e07570a934235983e1681a9f.png" mode="heightFix"></image> <image src="https://static.ticket.sz-trip.com/uploads/20250625/9bb05097e07570a934235983e1681a9f.png" mode="heightFix"></image>
<view></view> <view style="width: 50rpx;"></view>
</view> </view>
</template> </template>

7
manifest.json

@ -50,9 +50,12 @@
"quickapp" : {}, "quickapp" : {},
/* */ /* */
"mp-weixin" : { "mp-weixin" : {
"appid" : "", "appid" : "wx8954209bb3ad489e",
"setting" : { "setting" : {
"urlCheck" : false "urlCheck" : false,
"es6" : true,
"postcss" : true,
"minified" : true
}, },
"usingComponents" : true "usingComponents" : true
}, },

5
package-lock.json

@ -4,6 +4,11 @@
"lockfileVersion": 1, "lockfileVersion": 1,
"requires": true, "requires": true,
"dependencies": { "dependencies": {
"moment": {
"version": "2.30.1",
"resolved": "https://registry.npmmirror.com/moment/-/moment-2.30.1.tgz",
"integrity": "sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how=="
},
"ydui-district": { "ydui-district": {
"version": "1.1.0", "version": "1.1.0",
"resolved": "https://registry.npmmirror.com/ydui-district/-/ydui-district-1.1.0.tgz", "resolved": "https://registry.npmmirror.com/ydui-district/-/ydui-district-1.1.0.tgz",

1
package.json

@ -4,6 +4,7 @@
"description": "", "description": "",
"main": "main.js", "main": "main.js",
"dependencies": { "dependencies": {
"moment": "^2.30.1",
"ydui-district": "^1.1.0" "ydui-district": "^1.1.0"
}, },
"devDependencies": {}, "devDependencies": {},

7
pages.json

@ -40,6 +40,13 @@
"navigationStyle": "custom" "navigationStyle": "custom"
// "navigationBarTitleText": "iSoul" // "navigationBarTitleText": "iSoul"
} }
},
{
"path" : "pages/login/login",
"style" : {
"navigationBarTitleText" : "登录",
"navigationStyle": "custom"
}
} }
], ],
"subPackages": [{ "subPackages": [{

654
pages/index/iSoul.vue

@ -1,25 +1,661 @@
<template> <template>
<view></view> <view class="bg">
<view class="title">我的</view>
<view class="topBox" @click="gotoProfile">
<view class="avatar-box flex-center">
<image :src="showImg(userInfo.avatar)" mode="aspectFill" class="headImg" v-if="userInfo.avatar"></image>
<image src="https://changshu.js-dyyj.com/uploads/20250326/516242619f0772bee371a60684618c01.png" mode="aspectFill"
class="headImg" v-else></image>
</view>
<view class="username" v-if="userInfo.nickname">{{userInfo.nickname}}</view>
<view class="username" v-else>请登录/注册 ></view>
<view class="personalCenter flex-center" v-if="userInfo.nickname">
个人中心
</view>
</view>
<view class="orderBox">
<navigator :url="'/subPackages/order/trades'" class="moreBox flex-between">
我的订单
<span class="flex-between">查看更多 <img
src="https://static.ticket.sz-trip.com/cgc/images/user/rightIcon.png" alt=""></span>
</navigator>
<view class="flex-around" style="margin-top: 20rpx;">
<view class="orderItem" v-for="(item,index) in orderList" :key="index" @click="goTrades(item)">
<img :src="item.src" alt="">
<view>{{item.title}}</view>
</view>
</view>
<!-- 待付款轮播 -->
<!-- <swiper class="my-swipe" :autoplay="3000" indicator-color="white" v-if="dfkList && dfkList.length>0" circular>
<swiper-item v-for="(item,index) in dfkList" :key="item.id">
<div class="dfkBox" @click="goToOrderDetail(item)">
<image :src="showImg(item.order_child[0].specifications_image)" mode="aspectFill"></image>
<div class="contentBox">
<div style="width:300rpx;">
<div style="font-size: 27rpx;margin-bottom: 10rpx;">等待付款 </div>
<div style="display: flex;color: #8A8A8A;font-size: 27rpx;">剩余时间<uni-countdown class="countdown" @timeup="timeup(index)" :show-day="false" :hour="differTimeList[index].slice(0,2)" :minute="differTimeList[index].slice(3,5)" :second="differTimeList[index].slice(6,8)"/></div>
</div>
<div class="orderBtn" @click.stop="setOrderId(item.order_id)">去支付</div>
</div>
</div>
</swiper-item>
</swiper> -->
</view>
<view class="cygj">
<view class="cyItem" style="font-weight: bold;font-size: 31rpx;color: #333333;">
常用工具
</view>
<view class="cyItem flex-between" v-for="(item,index) in cyList" :key="index"
@click="gotoUrl(item,index)" v-if="item.isShow">
<view class="flex-center">
<img :src="item.src" class="headIcon">
{{item.title}}
</view>
<img src="https://static.ticket.sz-trip.com/yandu/images/user/rightIcon-gray.png" class="rightIcon">
</view>
<!-- <button id="contact" class="cyItem flex-between" open-type="contact" bindcontact="handleContact" session-from="sessionFrom">
<view class="flex-center">
<img src="https://static.ticket.sz-trip.com/dongtai/images/user/zxkf.png" class="headIcon">
在线客服
</view>
<img src="https://static.ticket.sz-trip.com/dongtai/images/user/rightIcon-gray.png" class="rightIcon">
</button> -->
</view>
<!-- 旅游咨询弹框 -->
<uni-popup ref="popup" type="center">
<view class="consult-popup">
即将拨打客服电话
<view class="consult-subtitle">服务时间周一至周五<br>9:00-12:0013:00-18:00</view>
<view class="consult-btns">
<view @click="$refs.popup.close()">取消</view>
<view @click="clickPhone('0515-69186109')">确定</view>
<!-- <view>
<button class="confirm" open-type="contact">确定</button>
</view> -->
</view>
</view>
</uni-popup>
<CustomTabBar :currentTab="4" />
</view>
</template> </template>
<script> <script>
import moment from "moment";
import CustomTabBar from '@/components/CustomTabBar.vue'; import CustomTabBar from '@/components/CustomTabBar.vue';
export default { export default {
components: {CustomTabBar}, components: {CustomTabBar},
data() { data() {
return {} return {
}, dfkList: [],
onLoad() { differTimeList: [],
nowDateTime: '', //
userInfo: {},
orderList: [{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/dfk.png',
title: '待付款',
status: 'WAIT_PAYMENT'
},
{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/dfh.png',
title: '待使用/发货',
status: 'PAYMENT_SUCCESSFULLY'
},
{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/dsh.png',
title: '待收货',
status: 'POST'
},
// {
// src: 'https://changshu.js-dyyj.com/uploads/20250326/3f13d3a10dd0f88e764e3ddf1157c108.png',
// title: '',
// status: 'WAIT_COMMENT'
// },
{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/tk.png',
title: '退款/售后',
status: 'WAIT_REFUND,REFUND_SUCCESS,REFUND_REFUSAL,REFUND_ERROR,REFUND_PART'
},
],
cyList: [
{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/gwc.png',
title: '购物车',
path: '/subPackages/user/gwc',
isShow: true
},
{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/kfdh.png',
title: '客服电话',
path: '',
isShow: true
},
{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/shdz.png',
title: '收货地址',
path: '/subPackages/user/travelerList',
isShow: true
},
{
src: 'https://static.ticket.sz-trip.com/cgc/images/user/ysgl.png',
title: '隐私管理',
path: '/subPackages/user/privacy',
isShow: true
},
// {
// src: 'https://changshu.js-dyyj.com/uploads/20250326/3e977f62b6cbfeec5a17d945b96b8c8c.png',
// title: '',
// path: '/subPackages/service/service',
// isShow: true
// },
],
}
}, },
onReady() { onShow() {
this.userInfo = (uni.getStorageSync('userInfo') && JSON.parse(uni.getStorageSync('userInfo'))) || this.$store.state.user.userInfo || {}
console.log(this.userInfo)
// this.dfkList = []
// this.nowDateTime = parseInt(new Date().getTime() / 1000)
// this.Post({}, "/api/user/userInfo").then((res) => {
// if (res.data) {
// this.userInfo = res.data;
// // this.getDfk()
// //
// this.Post({},'/api/merchants/is_merchant').then(res => {
// this.cyList[6].isShow = res.data
// })
// }
// });
}, },
methods:{ methods: {
//
gotoProfile() {
// token
if(this.userInfo.token) {
uni.navigateTo({
url: '/subPackages/user/profile'
})
}else {
uni.navigateTo({
url: '/pages/login/login'
})
}
},
timeup(index) {
// return this.dfkList.splice(index,1)
},
setOrderId(id) {
let that = this;
that.orderId = id;
that.Post({
order_id: id,
type: "miniprogram",
platform: 'miniprogram'
},
'/api/pay/unify'
).then(res => {
if (res.data) {
uni.requestPayment({
nonceStr: res.data.nonceStr,
package: res.data.package,
paySign: res.data.paySign,
signType: res.data.signType,
timeStamp: res.data.timeStamp
});
}
});
},
//
getDfk() {
this.differTimeList = []
let params = {
offset: this.dfkList.length,
limit: 10,
status: 'WAIT_PAYMENT',
}
this.Post(params, '/api/order/orderList').then(res => {
this.isLoading = false
if (res) {
this.dfkList = [...this.dfkList, ...res.data]
this.dfkList.forEach(item => {
// ,-differTimeList
let del;
if (moment(item.close_time).diff(moment()) > 0) {
del = moment.utc(moment(item.close_time).diff(moment())).format('HH:mm:ss')
} else {
del = '00:00:00'
}
this.differTimeList.push(del)
})
console.log(this.differTimeList);
console.log('this.differTimeList:' + this.differTimeList[0].slice(0, 2))
}
})
},
goToOrderDetail(item) {
uni.navigateTo({
url: '/subPackages/order/detail?id=' + item.order_id
});
},
getChild(list) {
let arr = []
for (let i = 0; i < list.length; i++) {
if (list[i].product_model == "ticket") {
console.log(list[i]);
arr.push(list[i])
break
}
}
console.log(arr);
if (arr.length > 0) {
return arr[0]
} else {
return list[0]
}
}, },
goCoupon() {
uni.navigateTo({
url: "/subPackages/user/coupon",
});
},
goKeFu() {
uni.navigateTo({
url: "/subPackages/publicservices/ServiceOnline",
});
},
// open(){
// this.$refs.popup.open('center')
// },
gotoUrl(item, index) {
if (item.title == "客服电话") {
this.$refs.popup.open()
return;
}
uni.navigateTo({
url: item.path
})
},
qidai() {
uni.showToast({
title: '功能建设中...',
icon: 'none'
})
},
goTrades(item) {
if (item) {
uni.navigateTo({
url: "/subPackages/order/trades?type=" + item.title,
});
} else {
uni.navigateTo({
url: "/subPackages/order/trades",
});
}
},
//
isGz(item) {
this.$refs.pop.openPop(
'https://yjks.oss-cn-shanghai.aliyuncs.com/uploads/20230517/db9eb60e0abfea8be1075b406fefe551.jpg');
// this.Post({}, '/api/wechat/getSubcribeInfo').then(res => {
// if (res.data) {
// uni.navigateTo({
// url:'/subPackages/webPage/webPage?url='+'https://mp.weixin.qq.com/mp/profile_ext?action=home&__biz=MzU2NjQwNTYxNg==#wechat_redirect'
// })
// } else {
// console.log(this.$refs.pop);
// }
// });
},
}
} }
</script> </script>
<style lang="scss" scoped> <style scoped lang="scss">
view{
box-sizing: border-box;
}
::v-deep .uni-countdown {
font-size: 20px !important;
::v-deep .uni-countdown__splitor {
font-size: 20px !important;
}
}
.bg {
min-height: 100vh;
overflow-x: hidden;
background: url('https://static.ticket.sz-trip.com/cgc/images/user/bg.png') no-repeat;
background-size: 100% auto;
background-color: #F7F7F7;
padding-bottom: 100rpx;
}
.title {
font-weight: bold;
font-size: 36rpx;
color: #333333;
position: absolute;
top: 110rpx;
left: 50%;
transform: translate(-50%, 0);
}
.topBox {
width: 750rpx;
height: 373rpx;
padding: 100rpx 0 0 26rpx;
box-sizing: border-box;
display: flex;
margin-top: 90rpx;
.avatar-box {
width: 120rpx;
height: 120rpx;
background: #FFFFFF;
border-radius: 50%;
overflow: hidden;
}
.headImg {
width: 120rpx;
height: 120rpx;
border-radius: 50%;
}
.username {
margin: 40rpx 0 0 28rpx;
font-weight: 500;
font-size: 40rpx;
color: #000000;
}
.personalCenter {
width: 165rpx;
height: 59rpx;
background: rgba(24, 135, 145, 1);
border-radius: 29rpx 0rpx 0rpx 29rpx;
margin: 40rpx 0 0 auto;
font-weight: bold;
font-size: 28rpx;
color: #FFFFFF;
}
}
.orderBox {
width: 697rpx;
background: #FFFFFF;
box-shadow: 0rpx 0rpx 23rpx 0rpx rgba(80, 80, 80, 0.12);
border-radius: 20rpx;
margin: -48rpx auto 0;
padding-bottom: 30.6rpx;
.moreBox {
height: 84rpx;
margin: auto;
font-size: 31rpx;
font-family: PingFang SC;
font-weight: bold;
color: #000000;
padding-left: 26rpx;
span {
padding-right: 18rpx;
font-size: 27rpx;
font-family: PingFang SC;
font-weight: 500;
box-sizing: border-box;
img {
width: 12rpx;
height: 21rpx;
margin-left: 12rpx;
}
}
}
.orderItem {
font-size: 27rpx;
font-family: PingFang SC;
font-weight: 500;
color: #000000;
width: 25%;
text-align: center;
img {
width: 80rpx;
height: 80rpx;
}
}
}
.lxwm {
width: 696rpx;
height: 447rpx;
background: #FFFFFF;
box-shadow: 0px 4rpx 12rpx 0px rgba(150, 149, 149, 0.3);
border-radius: 20rpx;
margin: auto;
padding: 27rpx 19rpx 0 19rpx;
font-size: 31rpx;
font-family: PingFang SC;
font-weight: bold;
color: #000000;
.midBox {
padding: 26rpx 43rpx 21rpx 44rpx;
box-sizing: border-box;
img {
width: 265rpx;
height: 252rpx;
border-radius: 15rpx;
}
}
.botBox {
padding: 0 30rpx 0 51rpx;
font-size: 27rpx;
font-family: PingFang SC;
font-weight: bold;
color: #000000;
}
}
.cygj {
width: 697rpx;
background: #FFFFFF;
border-radius: 20rpx;
margin: 30rpx auto 0;
padding: 0 27rpx;
font-size: 28rpx;
font-family: PingFang SC;
font-weight: 500;
color: #000000;
box-sizing: border-box;
.cyItem {
height: 106rpx;
display: flex;
align-items: center;
border-bottom: 1rpx solid #D8D8D8;
.headIcon {
width: 42rpx;
height: 42rpx;
margin-right: 15rpx;
}
.rightIcon {
width: 20rpx;
height: 20rpx;
}
}
.cyItem:last-child {
border: none;
}
}
.my-swipe {
// width: 100%;
margin: 0 30rpx;
margin-top: 37.3rpx;
}
swiper {
height: 111rpx !important;
}
.dfkBox {
width: 100%;
height: 111rpx;
background: #F7F7F7;
margin: 0 auto 30.64rpx;
// padding: 0.25rem;
display: flex;
}
.dfkBox image {
width: 137rpx;
height: 111rpx;
border-radius: 13rpx;
flex-shrink: 0;
// margin-right: 16.7rpx;
}
.dfkBox .contentBox {
padding-left: 5rpx;
padding-right: 5rpx;
height: 111rpx;
width: 100%;
display: flex;
justify-content: space-around;
align-items: center;
}
// .van-count-down{
// font-size: 0.39rem;
// font-family: PingFang SC;
// font-weight: 400;
// color: #FB6E4D;
// }
.orderBtn {
width: 152rpx;
height: 56rpx;
background: linear-gradient(270deg, #FC5109, #FDC43A);
;
border-radius: 28rpx;
text-align: center;
line-height: 56rpx;
font-size: 27rpx;
font-family: PingFang SC;
font-weight: 400;
color: #FFFFFF;
// margin-left: 50rpx;
// margin-right: 20rpx;
}
#contact {
-webkit-tap-highlight-color: transparent;
background-color: rgba(0, 0, 0, 0);
border-radius: 0;
box-sizing: border-box;
color: transparent;
cursor: pointer;
overflow: hidden;
padding: 0 27rpx;
position: relative;
text-align: center;
text-decoration: none;
border: transparent 0px solid;
display: flex;
align-items: center;
font-size: 28rpx;
font-family: PingFang SC;
font-weight: 500;
color: #000000;
}
button::after {
border: none;
background-color: rgba(0, 0, 0, 0);
}
.more {
width: 100vw;
height: 100vh;
background-color: rgba(0, 0, 0, .5);
position: fixed;
top: 0;
left: 0;
display: flex;
flex-direction: column;
justify-content: space-around;
align-items: center;
image {
width: 646rpx;
height: 959rpx;
}
img {
width: 80rpx;
height: 80rpx;
}
}
.consult-popup {
width: 487rpx;
height: 367rpx;
background: #F0F0F0;
border-radius: 20rpx;
padding: 65rpx 0 23rpx;
font-weight: bold;
font-size: 32rpx;
color: #000000;
text-align: center;
.consult-subtitle {
font-weight: 500;
font-size: 27rpx;
color: #333333;
margin-top: 43rpx;
}
.consult-btns {
display: flex;
margin-top: 75rpx;
view {
width: 50%;
font-weight: bold;
font-size: 32rpx;
color: #00AEA0;
line-height: 54rpx;
}
view:first-child {
border-right: 1rpx solid #D8D8D8;
color: #000000;
}
}
}
.confirm{
height: 58rpx;
line-height: 58rpx;
background: none;
font-weight: bold;
font-size: 32rpx;
color: #00AEA0;
}
</style> </style>

24
pages/index/index.vue

@ -1,7 +1,13 @@
<template> <template>
<view class="bg"> <view class="bg">
<headerVue></headerVue> <headerVue></headerVue>
<view class="content">
<swiper class="top-banner" :indicator-dots="false" :autoplay="false" v-if="topBanner && topBanner.length > 0">
<swiper-item v-for="(item, index) in topBanner" :key="index" @click.stop="gotoUrlNew(item)">
<image class="top-banner" :src="showImg(item.head_img)" mode="aspectFill" lazy-load="true"></image>
</swiper-item>
</swiper>
</view>
<CustomTabBar :currentTab="0" /> <CustomTabBar :currentTab="0" />
</view> </view>
</template> </template>
@ -13,14 +19,14 @@
components: {CustomTabBar,headerVue}, components: {CustomTabBar,headerVue},
data() { data() {
return { return {
topBanner: []
} }
}, },
onLoad() { onLoad() {
}, },
onReady() { onReady() {
this.getList()
}, },
onReachBottom() { onReachBottom() {
@ -114,7 +120,17 @@
.bg { .bg {
min-height: 100vh; min-height: 100vh;
background: #FFFFFF; background: #FFFFFF;
display: flex;
flex-direction: column;
}
.content{
flex: 1;
height: 200rpx;
width: 100%;
}
.top-banner {
width: 100%;
height: 100%;
} }
</style> </style>

268
pages/index/readingBody.vue

@ -1,105 +1,227 @@
<template> <template>
<view class="bg"> <view class="bg">
<navigator url="/subPackages/readingBody/index" class="content"> <headerVue />
<swiper class="top-banner" :indicator-dots="false" :autoplay="false" v-if="topBanner && topBanner.length > 0">
<swiper-item v-for="(item, index) in topBanner" :key="index" > <view class="top-box">
<image class="top-banner" :src="showImg(item.head_img)" mode="aspectFill" lazy-load="true"></image> <swiper class="carousel-swiper" :indicator-dots="false" :autoplay="true" :interval="5000" :duration="500"
@change="onSwiperChange">
<swiper-item v-for="(item, index) in swiperList" :key="index">
<image :src="item.img" mode=""></image>
</swiper-item> </swiper-item>
</swiper> </swiper>
</navigator> <view class="exhibit-issue">issue/0{{ currentIndex + 1 }}</view>
<!-- 底部指示点 -->
<view class="custom-indicators">
<view v-for="(_, index) in swiperList" :key="index"
:class="['indicator-dot', {'active': index === currentIndex}]"></view>
</view>
</view>
<scroll-view scroll-x="true" show-scrollbar="false">
<view class="category-scroll">
<image v-for="(item,index) in categories" :key="index" :src="item"></image>
</view>
</scroll-view>
<view class="title-box">
全部阅读
<image src="https://static.ticket.sz-trip.com/epicSoul/readingBody/titleSpan.png" mode=""></image>
</view>
<view class="reading-title flex-between">
<view v-for="(item,index) in readingType" :key="index" @click="changeType(index)">{{item}}</view>
<span :style="{left: readingIndex == 0 ? '32rpx' : (readingIndex == 1 ? '245rpx' : '448rpx')}"></span>
</view>
<view class="reading-box">
<image v-for="(item,index) in readingList" :key="index" :src="item"></image>
</view>
<CustomTabBar :currentTab="1" /> <CustomTabBar :currentTab="1" />
</view> </view>
</template> </template>
<script> <script>
import headerVue from "@/components/header.vue" import headerVue from "@/components/header.vue";
import CustomTabBar from '@/components/CustomTabBar.vue'; import CustomTabBar from '@/components/CustomTabBar.vue';
export default { export default {
components: {CustomTabBar,headerVue}, components: {
headerVue,
CustomTabBar
},
data() { data() {
return { return {
topBanner: [] swiperList: [{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/img.png'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/img.png'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/img.png'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/img.png'
}
],
currentIndex: 0,
categories: [
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img1.png',
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img1.png',
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img1.png'
],
readingList: [
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img2.png',
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img2.png',
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img2.png',
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img2.png',
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img2.png',
'https://static.ticket.sz-trip.com/epicSoul/readingBody/img2.png'
],
readingType: ['2025', '2026', '更多'],
readingIndex: 0
} }
}, },
onLoad() {
},
onReady() {
this.getList()
},
methods: { methods: {
getList() { onSwiperChange(e) {
// this.currentIndex = e.detail.current;
this.Post({
type_id: 3,
position: 1,
}, '/api/adv/getAdv').then(res => {
if(res.data) {
this.topBanner = res.data;
}
});
},
// 234
gotoUrlNew(item) {
console.log(item);
let that = this;
let url = '';
switch (item.jump_type) {
case 0:
break;
case 2:
uni.navigateTo({
url: item.tdata
});
break;
case 3:
uni.navigateTo({
url: '/subPackages/webPage/webPage?url=' + item.tdata
});
break;
case 4:
uni.navigateToMiniProgram({
appId: item.tdata.appid, // appid
path: item.tdata.page, //
envVersion: 'release',
success: res => {
//
console.log('打开成功', res);
},
fail: err => {
console.log(err);
}
});
break;
default:
break;
}
}, },
changeType(index) {
this.readingIndex = index
console.log(index,this.readingIndex)
}
}
}
</script>
<style lang="scss" scoped>
.bg {
padding-bottom: 200rpx;
}
.top-box {
margin: 60rpx 40rpx 0;
height: 830rpx;
box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.1);
border-radius: 20rpx;
padding-top: 10rpx;
background-color: #fff;
}
.carousel-swiper {
width: 582.13rpx;
height: 706.24rpx;
margin: -40rpx auto 0;
image {
width: 100%;
height: 100%;
} }
} }
</script>
<style lang="scss" scoped> .exhibit-issue {
font-family: serif;
font-size: 28rpx;
color: #999;
font-style: italic;
padding: 40rpx 30rpx 0 0;
text-align: right;
}
.bg { .custom-indicators {
min-height: 100vh;
background: #FFFFFF;
display: flex; display: flex;
flex-direction: column; justify-content: center;
gap: 8rpx;
margin-top: 40rpx;
.indicator-dot {
width: 8rpx;
height: 8rpx;
border-radius: 4rpx;
background-color: rgba(150, 150, 150, 0.5);
transition: all 0.3s;
}
.indicator-dot.active {
width: 20rpx;
background-color: rgb(133, 133, 133);
}
} }
.content{
flex: 1; .category-scroll {
height: 200rpx; padding: 40rpx 0 0 40rpx;
width: 100%; display: flex;
image {
width: 520rpx;
height: 260rpx;
flex-shrink: 0;
margin-right: 20rpx;
}
} }
.top-banner {
width: 100%; .title-box {
height: 100%; font-size: 36rpx;
font-weight: 500;
margin-top: 40rpx;
padding-left: 60rpx;
image {
width: 185.85rpx;
height: 20.98rpx;
margin-left: 21rpx;
}
} }
.reading-title {
margin: 60rpx auto 0;
width: 585rpx;
height: 30rpx;
border-radius: 15rpx;
background-color: rgba(46, 220, 78, .8);
font-weight: bold;
font-size: 28rpx;
color: #000000;
padding: 0 55rpx;
position: relative;
view {
position: absolute;
z-index: 20;
bottom: 15rpx;
}
&>view:nth-child(2) {
left: 268rpx;
}
&>view:nth-child(3) {
right: 55rpx;
}
span {
width: 111rpx;
height: 100%;
background-color: rgb(9, 154, 60);
border-radius: 15rpx;
position: absolute;
left: 32rpx;
}
}
.reading-box {
margin: 0 40rpx 0;
border-radius: 20rpx;
box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.1);
padding: 35rpx 20rpx 5rpx;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
position: relative;
top: -15rpx;
background-color: #fff;
image {
width: 188rpx;
height: 335rpx;
margin-bottom: 30rpx;
}
}
</style> </style>

113
pages/index/sensoryStore.vue

@ -2,17 +2,42 @@
<view class="bg"> <view class="bg">
<headerVue></headerVue> <headerVue></headerVue>
<view class="banner-content"> <view class="banner-content">
<swiper class="top-banner" :circular="true" :interval="6000" :duration="800" <swiper class="top-banner" :circular="true" :interval="6000" :duration="800"
:indicator-dots="false" :autoplay="true" v-if="topBanner && topBanner.length > 0"> :indicator-dots="false" :autoplay="true" @change="swiperChange" >
<swiper-item v-for="(item, index) in topBanner" :key="index" @click.stop="gotoUrlNew(item)"> <swiper-item v-for="(item, index) in topBanner" :key="index" @click.stop="gotoUrlNew(item)">
<image class="top-banner" :src="showImg(item.head_img)" mode="aspectFill" lazy-load="true"></image> <image class="top-banner" :src="showImg(item.head_img)" mode="aspectFill"></image>
</swiper-item> </swiper-item>
</swiper> </swiper>
<view class="dot-container">
<view :class="['dot-line',index==swiperIndex?'active':'']" v-for="(item, index) in topBanner" :key="index"></view>
</view>
</view> </view>
<image style="margin-top: 63rpx;" class="head-img" src="https://static.ticket.sz-trip.com/uploads/20250625/e3112c280ef9761af741907a737ef221.png"></image>
<view class="product-content"> <view class="product-content">
<image class="head-img" src="https://static.ticket.sz-trip.com/uploads/20250625/e3112c280ef9761af741907a737ef221.png"></image>
<view class="product">
<view class="item" v-for="(item,i) in list" :key="item.goods.id">
<image class="item-img" :src="showImg(item.goods.image)"></image>
<view class="content">
<view class="title text-overflow">{{item.goods.title}}</view>
<view class="bottom">
<view class="price">{{item.goods.money/100}}</view>
<image src="https://static.ticket.sz-trip.com/epicSoul/readingBody/gwc.png" class="buy-cart"></image>
</view>
</view>
</view>
</view>
<image style="margin: 53rpx 0 35rpx;" class="head-img" src="https://static.ticket.sz-trip.com/uploads/20250625/e3112c280ef9761af741907a737ef221.png"></image>
<view class="img-container">
<image v-for="i in 3" :key="i" src="https://cgc.js-dyyj.com/uploads/20250619/839df8a6ffaa539b213551577b6fc388.png?timestamp=1750841365993"
@click="gotoPath('/subPackages/haveFeeling/detailXiang')"></image>
</view>
</view> </view>
<CustomTabBar :currentTab="2" /> <CustomTabBar :currentTab="2" />
</view> </view>
@ -25,13 +50,16 @@
components: {CustomTabBar,headerVue}, components: {CustomTabBar,headerVue},
data() { data() {
return { return {
topBanner: [] topBanner: [],
list: [],
swiperIndex: 0,
} }
}, },
onLoad() { onLoad() {
}, },
onReady() { onReady() {
this.getProduct()
this.getList() this.getList()
}, },
@ -39,6 +67,10 @@
}, },
methods: { methods: {
swiperChange(e) {
this.swiperIndex = e.detail.current
},
viewDetail(item) { viewDetail(item) {
if (item.url) { if (item.url) {
uni.navigateTo({ uni.navigateTo({
@ -51,6 +83,16 @@
}) })
}, },
getProduct () {
this.Post({
tag_id: 45,
offset: 0,
limit: 3,
},'/api/tag/getGoodsByTagId').then(res => {
this.list = res.data;
})
},
getList() { getList() {
// //
this.Post({ this.Post({
@ -110,14 +152,34 @@
.bg { .bg {
min-height: 100vh; min-height: 100vh;
background: #FFFFFF; background: #FFFFFF;
padding-bottom: 200rpx;
} }
.banner-content{ .banner-content{
width: 100%; width: 100%;
height: 496.4rpx; height: 496.4rpx;
position: relative;
.top-banner { .top-banner {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.dot-container{
position: absolute;
bottom: 43rpx;
display: flex;
align-items: center;
justify-content: center;
width: 100%;
left: 0;
.dot-line{
width: 52rpx;
height: 4rpx;
margin: 0 8rpx;
background: RGBA(189, 170, 173, 0.8);
&.active{
background: RGBA(255, 255, 255, 0.8);
}
}
}
} }
.head-img{ .head-img{
@ -127,7 +189,48 @@
display: block; display: block;
} }
.product-content{ .product-content{
padding: 0 26rpx; padding: 63rpx 26rpx 0;
.product{
padding: 36rpx 0 0;
display: flex;
flex-wrap: nowrap;
justify-content: space-between;
.item{
width: 214.69rpx;
}
.item-img{
width: 214.69rpx;
height: 286.33rpx;
}
.content{
height: 80rpx;
padding: 0rpx 4rpx;
font-weight: 400;
font-size: 24rpx;
color: #000000;
}
.bottom{
display: flex;
padding-top: 13rpx;
justify-content: space-between;
align-items: center;
}
.buy-cart{
width: 28rpx;
height: 24rpx;
}
}
}
.img-container{
width: 100%;
image{
display: block;
width: 100%;
height: 314rpx;
border-radius: 40rpx;
margin-bottom: 20rpx;
}
} }
</style> </style>

258
pages/login/login.vue

@ -0,0 +1,258 @@
<template>
<view class="content" style="overflow-x: auto;">
<view class="search-header" :style="{'height': height+'px','padding-top':statusBarHeight+'px'}">
<view class="title">epic soul</view>
<view class="subtitle">大运河非物质文化遗产</view>
</view>
<view :style="{'height':height+'px','flex-shrink':0}"></view>
<div style="padding-top: 88rpx;">
<div class="login-tip">epic soul 申请获得</div>
<div class="login-tip2">以下权限</div>
<div class="login-tip-box">
<text>获得你的公开信息昵称头像地区及性别</text>
</div>
<div class="btn-box">
<button bindtap="cancel" type="default" @click="redirectIndex">取消</button>
<button type="primary" @click="getUserInfo">同意</button>
</div>
<div class="flex-center article-box">
<radio-group @change="toggleAgreement">
<radio value="1" :checked="isAgreed" style="transform:scale(0.7)"></radio>
</radio-group>
<div>同意<text @click="gotoInfo">用户服务协议隐私政策</text></div>
</div>
<uni-popup ref="popup" type="bottom" background-color="#fff">
<button type="default" open-type="getPhoneNumber" @getphonenumber="handlePhoneNumber" style="width: 100%;height: 12vh;line-height: 12vh;">点击授权手机号</button>
</uni-popup>
</div>
</view>
</template>
<script>
export default {
name: "login",
data() {
return {
//
height: 0,
statusBarHeight: 0,
isAgreed: false,
};
},
onLoad(options) {
this.initRectInfo()
//
if (options.needAuth === '1') {
setTimeout(() => {
this.$refs.popup.open('bottom');
}, 400);
}
},
methods: {
initRectInfo () {
const sysInfo = uni.getSystemInfoSync()
this.statusBarHeight = sysInfo.statusBarHeight
//
this.height = sysInfo.statusBarHeight + 40
},
//
handlePhoneNumber(e) {
if (e.detail.errMsg === "getPhoneNumber:ok") { //
this.$refs.popup.close();
this.Post({
code: e.detail.code,
encryptedData: e.detail.encryptedData,
iv: e.detail.iv,
token: uni.getStorageSync('token1')
}, '/api/mini_program/bindPhoneNumber')
.then(res => {
this.$store.commit('changeUserInfo', res.data.userinfo);
this.navigateBasedOnPath();
})
.catch(error => {
console.error('绑定手机号失败:', error);
uni.showToast({
title: '绑定手机号失败,请稍后重试',
icon: 'none'
});
});
} else {
console.error('获取手机号失败:', e.detail.errMsg);
uni.showToast({
title: '获取手机号失败,请稍后重试',
icon: 'none'
});
}
},
//
gotoInfo() {
uni.navigateTo({
url: '/subPackages/user/privacy'
});
},
//
toggleAgreement() {
this.isAgreed = !this.isAgreed;
},
//
redirectIndex() {
uni.switchTab({
url: '/pages/index/index',
});
},
//
getUserInfo() {
if (!this.isAgreed) {
uni.showToast({
title: '请先勾选同意《用户服务协议》、《隐私政策》',
icon: 'none'
});
return;
}
uni.login({
provider: 'weixin',
success: (loginRes) => {
uni.getUserInfo({
withCredentials: true,
success: (res) => {
this.Post({
code: loginRes.code,
userInfo: res.userInfo,
encryptedData: res.encryptedData,
iv: res.iv,
wechat_qrcode: uni.getStorageSync('wechat_qrcode') || ''
}, '/api/mini_program/login')
.then(resTwo => {
this.$store.commit('changeUserInfo', resTwo.data.userinfo);
if (resTwo.data.userinfo.mobile) {
this.navigateBasedOnPath();
} else {
uni.setStorageSync('token1', resTwo.data.userinfo.token);
this.$refs.popup.open('bottom');
}
})
.catch(error => {
console.error('登录失败:', error);
uni.showToast({
title: '登录失败,请稍后重试',
icon: 'none'
});
});
},
fail: (err) => {
console.error('获取用户信息失败:', err);
uni.showToast({
title: '获取用户信息失败,请稍后重试',
icon: 'none'
});
}
});
},
fail: (err) => {
console.error('微信登录失败:', err);
uni.showToast({
title: '微信登录失败,请稍后重试',
icon: 'none'
});
}
});
},
//
navigateBasedOnPath() {
if (this.$store.state.user.toPath.includes('user/user')) {
uni.switchTab({
url: this.$store.state.user.toPath
});
} else {
uni.navigateBack({});
}
}
},
};
</script>
<style scoped lang="scss">
.search-header{
width: 100%;
position: fixed;
top: 0;
left: 0;
right: 0;
background: white;
text-align: center;
z-index:99;
.title{
font-size: 30rpx
}
.subtitle{
font-size: 22rpx;
}
}
.content {
min-height: 100vh;
}
.login-tip {
font-size: 28rpx;
margin: 0 60rpx;
margin-top: 40rpx;
}
.login-tip2 {
font-size: 44rpx;
margin: 0rpx 60rpx;
margin-top: 20rpx;
font-weight: 400;
}
.login-tip-box {
display: flex;
align-items: flex-start;
margin: 0 60rpx;
font-size: 28rpx;
margin-top: 40rpx;
line-height: 40rpx;
}
.login-tip-box .icon-gou1 {
line-height: 80rpx;
margin-top: -20rpx;
margin-right: 30rpx;
color: #666;
}
.btn-box {
display: flex;
position: absolute;
bottom: 100rpx;
left: 0;
right: 0;
}
.btn-box button {
width: 400rpx;
}
.article-box {
position: absolute;
left: 0;
right: 0;
justify-content: center;
font-size: 24rpx;
color: #1aad19;
bottom: 40rpx;
}
.article-box .iconfont {
margin-right: 10rpx;
font-size: 26rpx;
}
.article-box text {
border-bottom: 1px solid;
}
</style>

100
subPackages/haveFeeling/detailXiang.vue

@ -1,6 +1,25 @@
<template> <template>
<view class="bg"> <view class="bg">
<headerVue /> <headerVue />
<image src="https://static.ticket.sz-trip.com/epicSoul/readingBody/xiangImg.png" mode="widthFix" class="topImg"></image>
<view class="box">
<view v-for="(item,index) in list" :key="index" class="item">
<image :src="showImg(item.img)" mode="aspectFill" class="headimg"></image>
<view class="content">
<view class="title text-overflow">{{item.title}}</view>
<view class="flex-between">
<view class="price">{{(item.price / 100).toFixed(2)}}</view>
<image src="https://static.ticket.sz-trip.com/epicSoul/readingBody/gwc.png" mode="" class="gwc"></image>
</view>
</view>
</view>
</view>
<view style="margin: 80rpx 50rpx;">
富文本 富文本
两千年的柏树自西汉年便扎根江南太湖畔的光福每年柏子熟时遵循古老的仪式于古柏枝干系上红绳燃清香向自然致以敬意这是江南百姓世代流传的生存智慧将草木荣枯视为对生命共同体的敬畏也感恩时间的馈赠
</view>
</view> </view>
</template> </template>
@ -12,7 +31,44 @@
}, },
data() { data() {
return { return {
list: [
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/productImg.png',
title: '湖石初醒湖石初醒湖石初醒湖石初醒湖石初醒',
price: '13800'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/productImg.png',
title: '湖石初醒',
price: '13800'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/productImg.png',
title: '湖石初醒',
price: '13800'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/productImg.png',
title: '湖石初醒',
price: '13800'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/productImg.png',
title: '湖石初醒',
price: '13800'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/productImg.png',
title: '湖石初醒',
price: '13800'
},
{
img: 'https://static.ticket.sz-trip.com/epicSoul/readingBody/productImg.png',
title: '湖石初醒',
price: '13800'
}
]
} }
} }
} }
@ -22,4 +78,48 @@
.bg { .bg {
padding-bottom: 200rpx; padding-bottom: 200rpx;
} }
.topImg {
width: 100%;
}
.box {
margin: 95rpx 45rpx 0;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
.item {
margin-bottom: 45rpx;
.headimg {
width: 204rpx;
height: 204rpx;
}
.content {
width: 204rpx;
margin-top: 5rpx;
.flex-between {
margin-top: 10rpx;
}
.title {
font-weight: 400;
font-size: 30rpx;
color: #000000;
}
.price {
font-size: 18rpx;
}
.gwc {
width: 28.18rpx;
height: 24.58rpx;
}
}
}
}
</style> </style>
Loading…
Cancel
Save