diff --git a/pages.json b/pages.json
index adfe632..859575c 100644
--- a/pages.json
+++ b/pages.json
@@ -13,6 +13,13 @@
"navigationBarTitleText": "我的"
}
},
+ {
+ "path": "pages/map/map",
+ "style": {
+ "navigationStyle": "custom",
+ "navigationBarTitleText": "智游常熟"
+ }
+ },
{
"path": "pages/login/login",
"style": {
@@ -101,6 +108,12 @@
"navigationBarTitleText": "全部订单"
}
},
+ {
+ "path": "order/orderPay",
+ "style": {
+ "navigationBarTitleText": "支付"
+ }
+ },
{
"path": "eventCalendar/eventCalendar",
"style": {
@@ -113,12 +126,19 @@
"style": {
"navigationBarTitleText": "活动详情"
}
+ },
+ {
+ "path": "webPage/webPage",
+ "style": {
+ "navigationBarTitleText": "",
+ "enablePullDownRefresh": false
+ }
}
]
}],
"tabBar": {
"color": "#999999",
- "selectedColor": "#333333",
+ "selectedColor": "#00AEA0",
"borderStyle": "black",
"backgroundColor": "#ffffff",
"fontSize": "24rpx",
@@ -130,6 +150,12 @@
"selectedIconPath": "/static/images/selectHome.png",
"text": "首页"
},
+ {
+ "pagePath": "pages/map/map",
+ "iconPath": "/static/images/map.png",
+ "selectedIconPath": "/static/images/selectMap.png",
+ "text": "地图"
+ },
{
"pagePath": "pages/user/user",
"iconPath": "/static/images/mine.png",
diff --git a/pages/index/index.vue b/pages/index/index.vue
index 0176ef0..67a16bb 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -29,12 +29,12 @@
-
+
{{item.title}}
查看更多产品 >
-
+
{{pItem.title}}
@@ -51,7 +51,7 @@
-
+
{{calendarItem.name}}
@@ -87,7 +87,7 @@
-
+
@@ -178,13 +178,21 @@
title: '景点',
id: '619',
spanColor: '#529AE7',
- list: []
+ list: [],
+ url: {
+ jump_type:3,
+ tdata: 'https://m.cloud.sz-trip.com/AttractionsTickets'
+ }
},
{
title: '特产',
id: '620',
spanColor: '#EE710C',
- list: []
+ list: [],
+ url: {
+ jump_type:3,
+ tdata: 'https://m.cloud.sz-trip.com/CulturalCreation'
+ }
}
],
calendarItem: {},
@@ -269,6 +277,82 @@
}, 500);
},
methods: {
+ // banner跳转
+ // 2是各种详情页,3是列表专题页面,4是小程序
+ 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:
+ let isJDSZ = this.goJDSZMiniProgram(item.tdata)
+ if (isJDSZ) return
+ 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;
+ }
+ },
+ // 判断是否跳转君到苏州专题页
+ goJDSZMiniProgram (tpage) {
+ if (tpage.indexOf('m.cloud.sz-trip.com') > -1) {
+ // 如果已登录但没有手机号,直接去授权页面
+ let userInfo = null
+ try {
+ userInfo = JSON.parse(uni.getStorageSync('userInfo'))
+
+ } catch(e) {}
+ if (userInfo && userInfo.token && !userInfo.mobile) {
+ uni.showToast({
+ title: '未授权手机号',
+ icon: 'none'
+ })
+ // 去登录页面授权
+ setTimeout(()=>{
+ uni.navigateTo({
+ url: '/pages/login/login?needAuth=1'
+ })
+ },200)
+
+
+ return true
+ }
+
+ // 获取授权code
+ this.checkIsLoginJdsz().then(res => {
+ if(res) {
+ uni.navigateTo({
+ url: '/subPackages/webPage/webPage?url=' + encodeURIComponent(`${tpage}?token=` + res + '&isKunshan=1')
+ });
+ }
+ })
+ return true
+ }
+ return false
+ },
// 瀑布流
getColumnItems(columnIndex) {
const columnItems = [];
@@ -282,9 +366,8 @@
getBanner() {
// 获取顶部banner
this.Post({
- apiType: 'jdsz',
- type_id: 5,
- position: 0,
+ type_id: 3,
+ position: 6,
}, '/api/adv/getAdv').then(res => {
if(res) {
this.topBanner = res.data
@@ -293,8 +376,7 @@
// 小banner
this.Post({
- apiType: 'jdsz',
- type_id: 5,
+ type_id: 3,
position: 1,
}, '/api/adv/getAdv').then(res => {
if(res) {
diff --git a/pages/map/map.vue b/pages/map/map.vue
new file mode 100644
index 0000000..02409e3
--- /dev/null
+++ b/pages/map/map.vue
@@ -0,0 +1,8 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/static/images/home.png b/static/images/home.png
index 9d13426..82ac36a 100644
Binary files a/static/images/home.png and b/static/images/home.png differ
diff --git a/static/images/map.png b/static/images/map.png
new file mode 100644
index 0000000..93e5a4d
Binary files /dev/null and b/static/images/map.png differ
diff --git a/static/images/mine.png b/static/images/mine.png
index 67970d8..54d64d1 100644
Binary files a/static/images/mine.png and b/static/images/mine.png differ
diff --git a/static/images/selectHome.png b/static/images/selectHome.png
index 2359413..35c660f 100644
Binary files a/static/images/selectHome.png and b/static/images/selectHome.png differ
diff --git a/static/images/selectMap.png b/static/images/selectMap.png
new file mode 100644
index 0000000..9fb1eba
Binary files /dev/null and b/static/images/selectMap.png differ
diff --git a/static/images/selectMine.png b/static/images/selectMine.png
index 16e1d34..84a5f77 100644
Binary files a/static/images/selectMine.png and b/static/images/selectMine.png differ
diff --git a/static/js/CommonFunction.js b/static/js/CommonFunction.js
index f82fcb7..1fd8d92 100644
--- a/static/js/CommonFunction.js
+++ b/static/js/CommonFunction.js
@@ -233,7 +233,128 @@ Vue.prototype.getHeadImg = type => {
});
}
+// 判断君到苏州token是否生效
+Vue.prototype.checkIsLoginJdsz = () => {
+ Vue.prototype.Post({
+ apiType: 'jdsz',
+ }, '/api/uservice/user/getMyInfo').then(res => {
+ if(res.code == 1 || res.code == 200) {
+ return res.data.token
+ }else if(res.code == 401) {
+ // 重新登陆
+ Vue.prototype.Post({}, '/api/user/getAuthCode').then(res => {
+ if (res.code == 1 || res.code == 200) {
+ Vue.prototype.Post({
+ apiType: 'jdsz',
+ }, '/api/uservice/user/loginBykunshan').then(res => {
+ if(res.data.code == 401) {
+ this.$store.commit('changeLoginPath')
+ return;
+ }
+ uni.setStorageSync('jdszToken', res.data.data.token)
+ })
+ }
+ }).catch(res => {
+ if (res.data.code == 201) {
+ uni.showToast({
+ title: '未授权手机号',
+ icon: 'none'
+ })
+ // 去登录页面授权
+ setTimeout(()=>{
+ uni.navigateTo({
+ url: '/pages/login/login?needAuth=1'
+ })
+ },400)
+ }
+ })
+ }
+ })
+}
+
// 跳转君到苏州详情
-Vue.prototype.gotoDetailByType = item => {
+Vue.prototype.gotoDetailByTypeToJdsz = item => {
+ let httpUrl = 'https://m.cloud.sz-trip.com/'
+ let url = ''
+
+ // 酒景套餐
+ if (item.is_package) {
+ url = httpUrl + 'MailMerchandiseDetail?id=' + item.id
+ }
+
+ switch (item.type) {
+ case 'ticket': // 是产品的 票务
+ url = httpUrl + 'ScenicDetail?id=' + item.scene_id || item.id
+ break;
+ case 'hotel': // 是产品的 酒店
+ url = httpUrl + 'HotelDetail?id=' + item.scene_id || item.id
+ break;
+ case 'post': // 是产品的 邮寄
+ url = httpUrl + 'MailMerchandiseDetail?id=' + item.id
+ break;
+ case 'line': // 是产品的 线路
+ url = httpUrl + 'LineDetail?id=' + item.id
+ break;
+ case 'coupon': // 是产品的 卡券
+ url = httpUrl + 'CardDetail?id=' + item.id
+ break;
+ case 'show': // 是产品的 演出
+ url = httpUrl + 'PerformDetail?id=' + item.id
+ break;
+ case 'food': // 是产品的 食品
+ url = httpUrl + 'FoodDetail?id=' + item.id
+ break;
+ case 'activity': // 是产品的 活动 todo 这里要弄成是活动的id去跳转的,特别是从 江苏夜游过去的
+ url = httpUrl + 'AppointmentDetail?id=' + item.act_calendar_id || item.id
+ break;
+ case 'calendar': // ai入口活动日历
+ url = httpUrl + 'AppointmentDetail?id=' + item.id
+ break;
+ case 'movie': // 是产品的 电影
+ url = httpUrl + 'MovieDetail?id=' + item.third_id || item.id
+ break;
+ case 'scenic': // 是场景的 景点
+ url = httpUrl + 'ScenicDetail?id=' + item.scene_id || item.id
+ break;
+ case 'room': // 是场景的 酒店
+ url = httpUrl + 'HotelDetail?id=' + item.scene_id || item.id
+ break;
+ case 'restaurant': // 是场景 美食
+ url = httpUrl + 'RestaurantDetail?id=' + item.id
+ break;
+ case 'tenscenic': // 是场景 十景
+ url = httpUrl + 'TenScenicDetail?id=' + item.id
+ break;
+ case 'venue': // 是场景的 场馆
+ url = httpUrl + 'PavilionDetail?id=' + item.scene_id || item.id
+ break;
+ case 'cinema': // 是场景的 影院
+ url = httpUrl + 'CinemaDetail?id=' + item.third_id || item.id
+ break;
+ case 'relic': // 文物
+ url = httpUrl + 'ProtectionUnitsInfo?id=' + item.id
+ break;
+ case 'units': // 文化单位
+ url = httpUrl + 'CulturalUnitInfo?id=' + item.id
+ break;
+ case 'red_map': // 红色地图
+ url = httpUrl + 'RedTouristInfo?id=' + item.id
+ break;
+ case 'travels': // 红色地图
+ url = httpUrl + 'TravelNotesIntroductionInfo?id=' + item.id
+ break;
+ }
+
+ uni.navigateTo({
+ url: '/subPackages/webPage/webPage?url=' + encodeURIComponent(url)
+ });
+ return;
+ Vue.prototype.checkIsLoginJdsz().then(res => {
+ if(res) {
+ uni.navigateTo({
+ url: '/subPackages/webPage/webPage?url=' + encodeURIComponent(url + '&token=' + res)
+ });
+ }
+ })
}
\ No newline at end of file
diff --git a/static/js/request.js b/static/js/request.js
index a68fafa..7628d93 100644
--- a/static/js/request.js
+++ b/static/js/request.js
@@ -15,8 +15,7 @@ const getToken = () => {
return userInfo.token;
}
}
- // return store.state.user.userInfo.token;
- return "ce870b90-d976-42b7-b4d8-d2957316886b"
+ return store.state.user.userInfo.token;
};
// 定义错误处理函数
diff --git a/subPackages/order/detail.vue b/subPackages/order/detail.vue
new file mode 100644
index 0000000..933f5a1
--- /dev/null
+++ b/subPackages/order/detail.vue
@@ -0,0 +1,1578 @@
+
+
+
+
+ 订单状态
+
+
+ {{info.status_text}}
+
+
+ 订单将在{{info.close_time.slice(-8)}}自动取消
+
+
+ 系统将在1-7个工作日内原路退回您的原支付账户
+
+
+ 您的退款金额已退还到您的原支付账户
+
+
+
+
+ 还剩{{remainNum}}张未核销
+
+
+
+
+ {{item.specifications_name}}
+
+
+ 核销码:{{item.third_order_id||item.child_id}}
+
+
+
+ 已核销
+
+
+ 已失效
+
+
+
+
+
+
+
+
+
+
+
+
+ 左右滑动核销其他二维码
+
+
+
+
+
+
+
+
+
+
+
+ {{info.order_child[0].goods_title}}
+
+
+
+ 出行时间:{{info.order_child[0].use_date}}
+
+
+ 开放时间:{{info.order_child[0].scenic_data.open_description}}
+
+
+
+
+
+
+ {{item.specifications_name}}
+
+ ¥{{item.money / 100}}
+ x{{item.num}}
+
+
+
+
+
+
+
+ 商品总额:¥{{info.money / 100}}
+
+
+ 优惠券:-¥{{info.discounts / 100}}
+
+
+ 实付金额:¥{{info.pay_money / 100}}
+
+
+
+
+
+
+ 出行人
+
+ {{item.specifications_name}}
+
+ 姓名:{{item.contact_name}}
+
+
+ 身份证:{{item.id_number}}
+
+
+
+
+
+
+
+
+ 收货地址
+ {{info.order_child[0].consignee.name}} {{info.order_child[0].consignee.tel}}
+ {{info.order_child[0].consignee.address}}
+
+
+
+
+ 商家名称
+
+
+
+ {{item.goods_title}}
+
+ {{item.specifications_name}}
+ x{{item.num}}
+
+
+
+
+
+
+
+ 商品总额:¥{{info.money / 100}}
+
+
+ 优惠券:-¥{{info.discounts / 100}}
+
+
+ 实付金额:¥{{info.pay_money / 100}}
+
+
+
+
+
+
+ 自提信息
+
+
+
+ {{info.order_child[0].contact.name}}
+ {{info.order_child[0].contact.tel}}
+
+
+
+
+
+ {{info.order_child[0].extract.extract_name}}
+ {{info.order_child[0].extract.detail_addr}}
+
+
+
+
+
+
+ 电话
+
+
+
+ 导航
+
+
+
+
+
+
+
+
+
+ 购买信息
+
+
+
+ {{foodInfo.title}}
+
+
+ {{item}}
+
+ x{{info.order_child[0].num}}
+
+
+
+
+ {{info.order_child[0].contact_name}}
+ {{info.order_child[0].phone}}
+
+
+
+
+
+ 商品总额:¥{{info.money / 100}}
+
+
+ 优惠券:-¥{{info.discounts / 100}}
+
+
+ 实付金额:¥{{info.pay_money / 100}}
+
+
+
+
+
+ 商家信息
+ 店铺名称
+
+
+
+
+
+ 营业时间
+ {{info.order_child[0].goods_data.open_description}}
+
+
+
+
+
+
+
+
+
+
+ {{info.order_child[0].goods_data.address}}
+
+
+ 距您约{{info.order_child[0].goods_data.distance > 1000 ? (info.order_child[0].goods_data.distance / 1000).toFixed(2) + 'km' : info.order_child[0].goods_data.distance + 'm'}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 入住信息
+ {{info.order_child[0].goods_title}}
+
+
+
+ {{(info.order_child[0].start_date).slice(5)}}
+ {{ShowDateDay(new Date(info.order_child[0].start_date).getDay())}}入住
+
+ 共{{calDate(info.order_child[0].start_date, info.order_child[0].end_date)}}晚
+
+ {{info.order_child[0].end_date.slice(5)}}
+ {{ShowDateDay(new Date(info.order_child[0].end_date).getDay())}}离店
+
+
+
+
+
+ {{info.order_child[0].scenic_data.address}}
+
+
+ 地图
+
+
+
+
+ 电话
+
+
+
+
+ {{info.order_child[0].specifications_name}}
+
+ ¥{{info.order_child[0].money / 100}}
+ x{{info.order_child[0].num}}
+
+
+
+
+
+
+ 商品总额:¥{{info.money / 100}}
+
+
+ 优惠券:-¥{{info.discounts / 100}}
+
+
+ 实付金额:¥{{info.pay_money / 100}}
+
+
+
+
+
+ 预订信息
+ 房间数:{{info.order_child[0].num}}间
+ 入住姓名:{{info.reserve_name}}
+ 联系电话:{{info.reserve_phone}}
+
+
+
+
+
+
+ 订单信息
+
+ 订单账号:{{info.order_id}}
+
+
+ 复制
+
+
+
+ 下单时间:{{info.create_time}}
+
+
+ 支付时间:{{info.pay_time}}
+
+
+
+
+
+
+ 联系客服
+
+
+
+
+
+
+
+
+
+ 物流信息
+ x
+
+
+
+ ·
+ ·
+
+ {{item.AcceptStation}}
+ {{item.AcceptTime}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/subPackages/order/orderCoupon.vue b/subPackages/order/orderCoupon.vue
new file mode 100644
index 0000000..9b08ece
--- /dev/null
+++ b/subPackages/order/orderCoupon.vue
@@ -0,0 +1,424 @@
+
+
+
+
+
+
+
+
+
+ {{item.discounts/100}}元
+
+
+ {{getPecenet(item.percent)}}折
+
+
+ 满{{item.min_limit/100}}元可用
+
+
+
+
+ {{item.title}}
+
+
+ {{item.open_time.slice(0,10)}}-{{item.end_time.slice(0,10)}}可用
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 使用规则:{{item.content}}
+ 使用规则:{{item.content}}
+
+
+
+
+
+
+
+
+
+ 暂无优惠券
+
+
+
+
+ 优惠:
+ ¥
+ {{reducePrice}}
+
+
+ 优惠:
+ {{reducePrice}}
+
+
+
+ 确定
+
+
+
+
+
+
+
+
diff --git a/subPackages/order/orderPay.vue b/subPackages/order/orderPay.vue
new file mode 100644
index 0000000..829e4d9
--- /dev/null
+++ b/subPackages/order/orderPay.vue
@@ -0,0 +1,400 @@
+
+
+ 支付剩余时间
+
+
+
+
+ 应付金额
+ ¥{{detail.paid_money / 100}}
+
+
+ 支付方式:
+
+
+
+
+
+
+
+ 微信支付
+
+
+
+
+
+
+
+
+
+
+
+
+ 数字人民币子钱包支付
+
+
+
+
+
+
+
+
+
+ {{item.bank_name}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 微信支付
+
+
+
+
+
+
+
+
+
+
+
+
+ 数字人民币子钱包支付
+
+
+
+
+
+
+
+
+
+ {{item.bank_name}}
+
+
+
+
+
+
+
+
+
+
+ 立即付款
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/subPackages/peripheralActivity/peripheralActivity.vue b/subPackages/peripheralActivity/peripheralActivity.vue
index 25da716..647c503 100644
--- a/subPackages/peripheralActivity/peripheralActivity.vue
+++ b/subPackages/peripheralActivity/peripheralActivity.vue
@@ -3,7 +3,7 @@
-
+
{{item.name}}
diff --git a/subPackages/webPage/webPage.vue b/subPackages/webPage/webPage.vue
new file mode 100644
index 0000000..208fb2f
--- /dev/null
+++ b/subPackages/webPage/webPage.vue
@@ -0,0 +1,27 @@
+
+
+
+
+
+
+
+
\ No newline at end of file