Commit 57354d33 by ym

联调

1 parent dfa2928a
...@@ -3,8 +3,10 @@ ...@@ -3,8 +3,10 @@
VUE_APP_TITLE=广联运营平台 VUE_APP_TITLE=广联运营平台
# 网络请求公用地址 # 网络请求公用地址
#VUE_APP_API=https://wx.glsx.com.cn/rop-ddh-carlife/router #VUE_APP_API=https://wx.glsx.com.cn/rop-ddh-carlife/router
VUE_APP_API=https://qcwx.glsx.com.cn/rop-ddh-carlife/router VUE_APP_API=http://192.168.2.60:7226/rop-scrm-equity/router
#VUE_APP_API=http://devwx.glsx.com.cn/rop-ddh-carlife/router #VUE_APP_API=http://192.168.2.94:7226/rop-scrm-equity/router
#VUE_APP_API=http://scrm.test.glsx.com.cn/rop-scrm-equity/router
#VUE_APP_API=http://qcwx.glsx.com.cn/rop-ddh-carlife/router
#VUE_APP_API=http://192.168.2.60:8086/rop-ddh-carlife/router #VUE_APP_API=http://192.168.2.60:8086/rop-ddh-carlife/router
VUE_APP_KEY=48e5e13229b82c1b4e6e8c96151f0637 VUE_APP_KEY=48e5e13229b82c1b4e6e8c96151f0637
......
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
"vant": "^2.10.11", "vant": "^2.10.11",
"vconsole": "^3.4.0", "vconsole": "^3.4.0",
"vue": "^2.6.12", "vue": "^2.6.12",
"vue-photo-preview": "^1.1.3",
"vue-router": "^3.2.0", "vue-router": "^3.2.0",
"vue-wechat-title": "^2.0.7", "vue-wechat-title": "^2.0.7",
"vuex": "^3.6.2", "vuex": "^3.6.2",
......
...@@ -6,15 +6,15 @@ export const equity = { ...@@ -6,15 +6,15 @@ export const equity = {
}, },
/** 获取会员权益卡 */ /** 获取会员权益卡 */
getCardInfo() { getCardInfo() {
return request({}, 'ddh.carlife.equity.h5.card.get') return request({}, 'dj.api.get.equity.info')
}, },
/** 根据卡号激活权益卡 */ /** 根据卡号激活权益卡 */
activateByCardNo(data) { activateByCardNo(data) {
return request(data, 'ddh.carlife.equity.h5.card.enable.by.cardno') return request(data, 'dj.api.get.equity.open.card.by.cardno')
}, },
/** 根据SN激活权益卡 */ /** 根据SN激活权益卡 */
activateBySn(data) { activateBySn(data) {
return request(data, 'ddh.carlife.equity.h5.card.enable.by.sn') return request(data, 'dj.api.get.equity.open.card.by.sn')
}, },
//权益订单 //权益订单
getOrderUrl(data) { getOrderUrl(data) {
...@@ -23,12 +23,21 @@ export const equity = { ...@@ -23,12 +23,21 @@ export const equity = {
getFissionInfo(data) { getFissionInfo(data) {
return request(data, 'ddh.carlife.equity.h5.get.fission.info') return request(data, 'ddh.carlife.equity.h5.get.fission.info')
}, },
/** 是否开通权益 */
openCardFission(data) { openCardFission(data) {
return request(data, 'ddh.carlife.equity.h5.open.card.by.fission.user') return request(data, 'ddh.carlife.equity.h5.open.card.by.fission.user')
}, },
getOrderCount(data) { getOrderCount(data) {
return request(data, 'ddh.carlife.equity.h5.get.hw.order.count') return request(data, 'ddh.carlife.equity.h5.get.hw.order.count')
}, },
/** 是否开通权益 */
getMerchantid(data) {
return request(data, 'dj.api.get.equity.pakage.by.merchantid')
},
/** 获取Edj地址 */
getEdjUrl(data) {
return request(data, 'dj.api.get.equity.edj.url')
},
} }
export const common = { export const common = {
...@@ -45,11 +54,11 @@ export const common = { ...@@ -45,11 +54,11 @@ export const common = {
}, },
/**获取微信config */ /**获取微信config */
getWxConfig(data) { getWxConfig(data) {
return request(data, 'ddh.carlife.common.wechat.jsconfig', 'get') return request(data, 'dj.api.scrm.common.wechat.jsconfig', 'get')
}, },
/**上传图片 */ /**上传图片 */
uploadImage(data) { uploadImage(data) {
return request(data, 'ddh.carlife.common.upload.image', 'post', ['file']) return request(data, 'dj.api.scrm.common.upload.image', 'post', ['file'])
} }
} }
...@@ -93,7 +102,91 @@ export const car = { ...@@ -93,7 +102,91 @@ export const car = {
export const cardRoll = { export const cardRoll = {
/**获取我的卡券 */ /**获取我的卡券 */
getCardList(data) { getCardList(data) {
return request(data, '') return request(data, 'dj.api.get.equity.h5.order.list.get')
},
/**订单详情 */
getCardDetail(data) {
return request(data, 'dj.api.get.equity.h5.order.detail.get')
},
/**创建售后 */
getCardRefund(data) {
return request(data, 'dj.api.get.equity.order.refund.detail.create')
},
/**获取售后详情 */
getCardRefundDetail(data) {
return request(data, 'dj.api.get.equity.h5.order.refund.detail.get')
},
/**获取权益卡详情 */
getCardMerchantid(data) {
return request(data, 'dj.api.get.equity.open.card.price.get.by.merchantid')
},
/**购买权益卡 */
getCardBuy(data) {
return request(data, 'dj.api.get.equity.open.card.to.buy')
},
/**确认收货 */
getCardConfirm(data) {
return request(data, 'dj.api.get.equity.h5.order.finish.confirm')
}, },
}
export const oilStation = {
/**获取油号 */
getOilNoList(data) {
return request(data, 'dj.api.scrm.oil.oilNoList')
},
/**获取加油站列表 */
getStationList(data) {
return request(data, 'dj.api.scrm.oil.list')
},
/**获取加油站详情 */
getStationDetail(data) {
return request(data, 'dj.api.scrm.oil.detail')
},
/**获取全部订单列表 */
getStationOrderList(data) {
return request(data, 'dj.api.scrm.oil.orderList')
},
/**分页获取订单列表 */
getStationOrderPage(data) {
return request(data, 'dj.api.scrm.oil.orderPage')
},
/**获取支付url地址 */
getStationPayUrl(data) {
return request(data, 'dj.api.scrm.oil.payUrl')
},
/**获取搜索记录 */
getStationSearchList(data) {
return request(data, 'dj.api.scrm.oil.search.list')
},
/**新增搜索记录 */
getStationSearchInsert(data) {
return request(data, 'dj.api.scrm.oil.search.insert')
},
/**删除搜索记录 */
getStationSearchDelete(data) {
return request(data, 'dj.api.scrm.oil.search.delete')
},
/**清空搜索记录 */
getStationSearchDeleteAll(data) {
return request(data, 'dj.api.scrm.oil.search.deleteAll')
},
}
export const commodity = {
/**获取商品数据 */
getCouponDetail(data) {
return request(data, 'dj.api.get.equity.coupon.detail')
},
/**获取商品数据 */
getChargeDetail(data) {
return request(data, 'dj.api.get.equity.charge.detail')
},
/**获取订单编号 */
getOrderCode(data) {
return request(data, 'dj.api.get.equity.ordercode.get')
},
/**支付订单 */
payOrder(data) {
return request(data, 'dj.api.get.equity.create.order')
}
} }
\ No newline at end of file \ No newline at end of file
...@@ -9,6 +9,11 @@ import '@a/scss/common.scss' ...@@ -9,6 +9,11 @@ import '@a/scss/common.scss'
import store from "./store" import store from "./store"
Vue.use(VueWechatTitle) Vue.use(VueWechatTitle)
Vue.use(Vant) Vue.use(Vant)
import preview from 'vue-photo-preview'
import 'vue-photo-preview/dist/skin.css'
Vue.use(preview)
import Vconsole from 'vconsole';
new Vconsole();
Vue.config.productionTip = false Vue.config.productionTip = false
Vue.prototype.isMiniprogram = window.__wxjs_environment === 'miniprogram' Vue.prototype.isMiniprogram = window.__wxjs_environment === 'miniprogram'
window.vm = new Vue({ window.vm = new Vue({
......
...@@ -3,6 +3,11 @@ import shopList from './list' ...@@ -3,6 +3,11 @@ import shopList from './list'
export default { export default {
data() { data() {
return { return {
ServiceList: {},
goodsServiceList: {},
goodsServiceKey: [],
carServiceList: [],
merchantId: sessionStorage.getItem('GL_WX_MERCHANTID'),
notice: '', notice: '',
phone_range: ['134', '135', '136', '137', '138', '139', '147', '150', '151', '152', '157', '158', '159', '182', '183', '184', '187', '188', '130', '131', '132', '145', '155', '156', '185', '186', '133', '153', '180', '181', '189', '170', '176', '177', '178'], phone_range: ['134', '135', '136', '137', '138', '139', '147', '150', '151', '152', '157', '158', '159', '182', '183', '184', '187', '188', '130', '131', '132', '145', '155', '156', '185', '186', '133', '153', '180', '181', '189', '170', '176', '177', '178'],
travelList: [{ travelList: [{
...@@ -69,7 +74,8 @@ export default { ...@@ -69,7 +74,8 @@ export default {
} }
}, },
mounted() { mounted() {
this.setNoticeInfo() this.setNoticeInfo();
this.getMerchantid();
if (this.isMiniprogram) wx.miniProgram.postMessage({}) if (this.isMiniprogram) wx.miniProgram.postMessage({})
}, },
methods: { methods: {
...@@ -90,32 +96,106 @@ export default { ...@@ -90,32 +96,106 @@ export default {
updataNotice() { updataNotice() {
this.setNoticeInfo() this.setNoticeInfo()
}, },
jumpLink(e) { CarLink(e) {
let params = { let supplier = e.supplier;
...e switch(supplier) {
case 'GL_OIL':
window.vm.$router.push({ path: '/oilStation/index'});
break;
case 'GL_ROAD_RESCUE':
window.vm.$router.push({ path: '/equity/road'});
break;
case 'GL_TIRE_PROTECTION':
window.vm.$router.push({ path: '/equity/tyre'});
break;
case 'GL_ROBBERY_PROTECTION':
window.vm.$router.push({ path: '/equity/compensate'});
break;
case 'GL_COLLISION_REPAIR':
window.vm.$router.push({ path: '/equity/collision'});
break;
case 'GL_CAR_TOTAL_LOSS':
window.vm.$router.push({ path: '/equity/loss'});
break;
case 'EDJ':
this.jumpDEJ();
break;
default:
this.showToast('即将上线,敬请期待')
} }
delete params.name },
delete params.icon jumpDEJ() {
delete params.description let {sessionId} = JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO'));
console.log(params) let para = {
if (params.route) { sessionId
let [href] = window.location.href.split('/#/')
let url = `${href}/#/equity/${params.route}`
this.openWindows(url, `equity.${params.route}`)
return
} }
equity.getCouponList({ equity.getEdjUrl(para).then(res => {
requestSource: this.getChannel(), //1.小程序,2.APP,3.公众号 let {code, data, message} = res
...params if (code == 0){
}).then(res => {
console.log(res)
let { code, data, message } = res
if (code == 0) {
this.openWindows(data) this.openWindows(data)
} else { } else {
this.showToast(message) this.showToast(message)
} }
})
},
jumpLink(e) {
if(e.appearance == 1) {
window.vm.$router.push({ path: '/commodity/business/',query:{
brandId: e.brandId,
supplier: e.supplier
}
});
}else {
window.vm.$router.push({
path: '/commodity/recharge/', query: {
brandId: e.brandId,
supplier: e.supplier
}
})
}
},
// jumpLink(e) {
// let params = {
// ...e
// }
// delete params.name
// delete params.icon
// delete params.description
// console.log(params)
// if (params.route) {
// let [href] = window.location.href.split('/#/')
// let url = `${href}/#/equity/${params.route}`
// this.openWindows(url, `equity.${params.route}`)
// return
// }
// equity.getCouponList({
// requestSource: this.getChannel(), //1.小程序,2.APP,3.公众号
// ...params
// }).then(res => {
// console.log(res)
// let { code, data, message } = res
// if (code == 0) {
// this.openWindows(data)
// } else {
// this.showToast(message)
// }
//
// })
// }
getMerchantid() {
this.carServiceList = []
let para = {
merchantId: this.merchantId
}
equity.getMerchantid(para).then(res => {
let {code, data, message} = res
if (code == 0){
this.goodsServiceKey = Object.keys(data.goodsServiceList)
this.carServiceList = data.carServiceList
this.goodsServiceList = data.goodsServiceList;
} else {
this.showToast(message)
}
}) })
}, },
jumpMore() { jumpMore() {
......
import WxConfig from '@u/WxConfig' import WxConfig from '@u/WxConfig'
import {commodity} from "@r/api";
const WX = new WxConfig(['chooseWXPay']); const WX = new WxConfig(['chooseWXPay']);
// import { commodity } from '@r/api.js'
export default { export default {
data() { data() {
return { return {
...@@ -8,11 +10,72 @@ export default { ...@@ -8,11 +10,72 @@ export default {
mounted() { mounted() {
}, },
methods: { methods: {
chooseWXPay() { async chooseWXPay() {
WX.chooseWXPay().then(res => { if(this.appearance == 2 && !/^[a-zA-Z0-9]+$/.test(this.rechargeNumber)){
this.showToast('请输入正确的充值账号')
return
}
this.orderPay();
// let message;
// if(this.appearance === 1) {
// message = `是否确认为${this.mobile}进行充值`
// }
// this.dialog({
// title: '提示',
// message: message,
// })
// .then(() => {
// WX.chooseWXPay().then(res => {
// console.log(res)
// })
// })
// .catch(() => {
// this.showToast('取消成功')
// });
},
async orderPay() {
this.showLoading();
let {sessionId} = JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO'));
let orderCode = await commodity.getOrderCode({
sessionId,
supplier: this.supplier,
brandId: this.brandId
}).then(res => {
let { code, data, message } = res
if (code == 0) {
return data;
} else {
this.showToast(message)
}
})
let para = {
orderCode,
goodsId: this.selectData?this.selectData.id:this.denomination.id,
goodsQuality: 1,
rechargeNumber: this.rechargeNumber,
payMannerId: 11,
sessionId,
}
let payData = await commodity.payOrder(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
return data;
} else {
this.showToast(message)
}
})
const { timeStamp,nonceStr, packages, signType, paySign } = payData;
WX.chooseWXPay(timeStamp,nonceStr, packages, signType, paySign).then(res => {
console.log(res) console.log(res)
if(this.appearance == 2){
window.vm.$router.replace({ name: 'cardRoll.process' })
}else {
window.vm.$router.replace({ name: 'cardRoll.success',query:{price: this.denomination.salesPrice} })
}
}) })
}, }
}, },
} }
\ No newline at end of file \ No newline at end of file
...@@ -15,7 +15,9 @@ router.beforeEach((to, from, next) => { ...@@ -15,7 +15,9 @@ router.beforeEach((to, from, next) => {
let { meta: { authBase } } = to let { meta: { authBase } } = to
if (to.name != 'common.phoneLogin') store.commit('jumpPath', to.name) if (to.name != 'common.phoneLogin') store.commit('jumpPath', to.name)
const params = getParams(window.location.href) const params = getParams(window.location.href)
console.log(params.appId)
if (params.appId) sessionStorage.setItem('GL_WX_APPID', params.appId) if (params.appId) sessionStorage.setItem('GL_WX_APPID', params.appId)
if (params.merchantId) sessionStorage.setItem('GL_WX_MERCHANTID', params.merchantId)
window.onMessageFromLoginBack = (type, userId, sessionId) => { window.onMessageFromLoginBack = (type, userId, sessionId) => {
console.log('onMessageFromLoginBack', type, userId, sessionId) console.log('onMessageFromLoginBack', type, userId, sessionId)
if (type == 0) { if (type == 0) {
......
...@@ -47,8 +47,19 @@ const pages = { ...@@ -47,8 +47,19 @@ const pages = {
title: '售后详情' title: '售后详情'
}, },
{ {
name: 'waiting',
title: '等待处理'
},
{
name: 'salesApply', name: 'salesApply',
title: '申请售后' title: '申请售后'
},
{
name: 'agreement',
title: '权益服务协议'
},
{
name: 'customer',
} }
], ],
commodity: [ commodity: [
...@@ -66,7 +77,7 @@ const pages = { ...@@ -66,7 +77,7 @@ const pages = {
}, },
{ {
name: 'business', name: 'business',
title: '' title: '详情',
}, },
], ],
device: [{ device: [{
......
...@@ -102,6 +102,7 @@ class WxConfig { ...@@ -102,6 +102,7 @@ class WxConfig {
signType, // 签名方式,默认为'SHA1',使用新版支付需传入'MD5' signType, // 签名方式,默认为'SHA1',使用新版支付需传入'MD5'
paySign, // 支付签名 paySign, // 支付签名
success(res) { success(res) {
window.vm.showToast('支付成功')
resolve(res) resolve(res)
}, },
fail() { fail() {
......
<template>
<div class="main">
<div class="box">
<div class="agreement-title">
汽车增值服务权益卡领取协议
</div>
<div class="agreement-content">
<p>本协议是您与 深圳市嘀加智慧云服务有限公司(以下简称为“我司”)、以及“商家”之间就汽车增值服务权益卡领取事项所订立的契约。请您仔细阅读本协议,您勾选“同意《汽车增值服务权益卡领取协议》”后,本协议即构成对双方有约束力的法律文件。</p>
<h3>第1条 相关定义</h3>
<p>1.1 权益卡:指签署本协议并根据权益卡开通流程所展示的收费标准支付相应费用或免费领取后获取的特殊权益(实际名称以开通流程及前端页面展示为准),权益卡包括无门槛卡、规则卡及付费卡。</p> /* eslint-disable */
<p>权益卡权益可能包括以下部分或全部类型(实际权益类型可能出现新增或减少,以商家/我司/ 第三方实际设置为准):</p>
<p>1)特定商品的优惠,即在购买特定商品过程中,通过享受优惠价格、获得折扣让利、使用品类券等方式获取的特殊权益;</p>
<p>2)特定服务,即可直接享受特别服务的特殊权益;</p>
<p>3)专属权利;</p>
<p>4)其他权益。</p>
<p>1.2 权益卡权益:指您基于其权益卡资格所享有的特殊权益,具体权益内容由商家单独提供,请予以关注或及时与商家沟通确认。</p>
<p>1.3.商家:指自行或与我司共同制定收费标准以及领卡会员权益,并独立或与我司共同协商决定是否收取费用且提供服务的经我司认证的主体。</p>
<p>1.4.我司:指本协议中“权益卡”的所有权人(在尚未正式销售给您之前)。</p>
<h3>第2条 本站服务条款的确认和接纳</h3>
<p>2.1本协议所提供的汽车增值服务权益活动的解释权和运作权归我司所有。</p>
<p>2.2您在申请开通权益卡流程中点击同意本协议之前,应当认真阅读本协议。请您务必审慎阅读、充分理解各条款内容,特别是免除或者限制责任的条款、法律适用和争议解决条款。免除或者限制责任的条款将以粗体下划线标识,领卡/购卡您应重点阅读。如您对协议有任何疑问,可向商家或我司或客服咨询。</p>
<p>2.3您点击同意本协议的,即视为您确认自己同意汽车增值服务权益相关服务的条款,且同意按本协议内容履行,如产生相关责任的,同意承担相应法律责任。</p>
<h3>第3条 活动时间</h3>
<p>3.1汽车增值服务权益的开始时间和结束时间以 我司发布的活动规则中列明的时间为准。</p>
<h3>第4条 用户权益</h3>
<p>4.1 您申请开通权益卡服务时,需根据页面提示支付相应的会员服务费用后方可完成开通。基于权益调整、市场与业务的发展,可能会调整权益卡服务开通所需会员服务费用,或向您提供与会员权益相关的增值服务,并可能收取增值服务的费用。我司就前述权益调整将在相应服务页面进行通知或公告,您可以通过 商家公众号 平台查询最新的VIP您权益内容。您确认费用及权益的调整由我司/商家/ 第三方独立完成,如果非我司调整,与我司无关。</p>
<h3>第5条 用户领权益卡注意事项</h3>
<p>5.1提交申请领取时,您同意并提交本人手机号码和邮箱等本站所需的个人资料,并保证其提供的注册资料真实、准确、完整、合法有效,您注册资料如有变动的,应及时更新其注册资料。如果您提供的注册资料不合法、不真实、不准确、不详尽,您需承担因此引起的相应责任及后果,并且我司保留终止您参与该活动的权利。</p>
<p>5.2权益服务领取后,您应谨慎合理的保存、使用其您名和密码,不得将在本站注册获得的账户借给他人使用,否则您应承担由此产生的全部责任,同时我司在该种情况下有权做出独立判断,可采取暂停或关闭您参与资格等措施。</p>
<p>5.3您同意,我司拥有通过邮件、短信电话等形式,向其发送相关活动信息等必要信息的权利。</p>
<p>5.4您同意,领取汽车增值服务权益,除为实现您自身利益外,不得利用其享有的权益非法获利,不得以任何形式售卖其所享有的权益,不得滥用其所享有的权益,如因您不当行为致我司合理怀疑的或判定的,我司有权暂停或关闭该活动的权益,此外,您需承担因此引起的相应责任及后果。</p>
<h3>第6条 协议变更</h3>
<p>6.1我们可根据国家法律法规变化及服务内容调整、保护用户权益等需要修订本协议。一旦相关内容发生重大变更,我们将通过我们的网站或客户端公告、消息通知等方式通知您。</p>
<p>6.2如您不同意本协议的修订,您应立即停止使用本服务。如您继续使用本服务的,则视为您同意本协议的修订。</p>
<h3>第7条 责任免除</h3>
<p>因下列原因导致无法正常提供服务,我司不承担任何责任:</p>
<p>1.系统停机维护或升级;</p>
<p>2.因台风、地震、洪水、雷电或恐怖袭击等不可抗力原因;</p>
<p>3.您的电脑软硬件和通信线路、供电线路出现故障的;</p>
<p>4.您操作不当或通过非授权或认可的方式使用本服务的;</p>
<p>5.因病毒、木马、恶意程序攻击、网络拥堵、系统不稳定、系统或设备故障、通讯故障、电力故障、第三方服务瑕疵或政府行为等原因。</p>
<h3>第8条 法律管辖和适用</h3>
<p>8.1如缔约方就本协议内容或其执行发生任何争议,合同各方应尽力友好协商解决;协商不成时,任何一方均可向深圳市南山区人民法院提起诉讼。</p>
<h3>第9条 其他</h3>
<p>9.1如因不可抗力或其它本站无法控制的原因使本站活动服务无法及时提供或无法按本协议进行的,我司会合理地尽力协助处理善后事宜。</p>
</div>
</div>
</div>
</template>
<script>
export default {
name: "agreement"
}
</script>
<style scoped lang="scss">
.box {
padding: 15px;
.agreement-title {
color: #666666;
line-height: 32px;
font-size: 14px;
text-align: center;
}
.agreement-content {
color: #666666;
line-height: 18px;
font-size: 12px;
>h3 {
line-height: 30px;
}
>p {
text-indent: 24px;
line-height: 18px;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<div class="main">
<div class="serve-box">
<img src="@a/images/service.png">
</div>
</div>
</template>
<script>
export default {
name: "customer"
}
</script>
<style scoped lang="scss">
.serve-box {
position: absolute;
height: 100%;
width: 100%;
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -3,60 +3,42 @@ ...@@ -3,60 +3,42 @@
<div class="box"> <div class="box">
<div class="card-detail-h"> <div class="card-detail-h">
<div class="card-img"> <div class="card-img">
<img src="@a/images/marketing/bg.png"> <img :src="detailInfo.brandLogo">
</div> </div>
<div class="card-name">星巴克大杯全国通兑券</div> <div class="card-name">{{ detailInfo.productName }}</div>
<div class="card-time">质保期至 2021-06-21 17:02:23</div> <div class="card-time">质保期至 {{ detailInfo.warrantyDate }}</div>
<div class="card-number">订单编号 APP1622357790076</div> <div class="card-number">订单编号 {{ detailInfo.orderCode }}</div>
</div> </div>
<div class="card-panel" v-if="codeStatus == 1"> <div class="card-item-panel" v-if="detailInfo.cardType >2">
<div class="card-item-panel" v-if="status == 1">
<div class="card-item"> <div class="card-item">
<div class="card-item-title">星巴克丨大杯全国通兑券</div> <div class="card-item-title">星巴克丨大杯全国通兑券</div>
<div class="card-item-style"> <div class="card-item-style" v-if="detailInfo.cardType == 5">
<div class="card-item-number"> <div class="card-item-number">
<div class="card-item-label text-hide">账号:{{account}}</div> <div class="card-item-label text-hide">账号:{{detailInfo.cardPwd}}</div>
<div class="btn-clone" @click="getClone">复制</div> <div class="btn-clone" @click="getClone">复制</div>
</div> </div>
<div class="card-item-number"> <div class="card-item-number">
<div class="card-item-label text-hide">密码:{{password}}</div> <div class="card-item-label text-hide">密码:{{detailInfo.cardPwd}}</div>
<div class="btn-clone" @click="getClone">复制</div> <div class="btn-clone" @click="getClone">复制</div>
</div> </div>
</div> </div>
</div> <div class="card-item-style" v-if="detailInfo.cardType == 3">
</div> <div class="card-item-number">
<div class="card-item-panel" v-if="status == 2"> <div class="card-item-label text-hide">URL:{{detailInfo.linkUrl}}</div>
<div class="card-item"> <div class="btn-clone" @click="getClone">复制</div>
<div class="card-item-title">星巴克丨大杯全国通兑券</div>
<div class="card-item-style">
<div class="card-item-number">
<div class="card-item-label text-hide">URL:{{url}}</div>
<div class="btn-clone" @click="getClone">复制</div>
</div>
</div> </div>
</div> </div>
</div> <div class="card-item-style" v-if="detailInfo.cardType == 4">
<div class="card-item-panel" v-if="status == 3"> <div class="card-item-number">
<div class="card-item" v-for="(item,index) in qrcode" :key="index"> <div class="card-item-label text-hide">兑换码:{{detailInfo.cardPwd}}</div>
<div class="card-item-title">星巴克丨大杯全国通兑券</div> <div class="btn-clone" @click="getClone(detailInfo.cardPwd)">复制</div>
<div class="card-item-step" v-if="qrcode.length>1">NO.{{index+1}}</div>
<div class="card-item-style">
<div class="card-item-number">
<div class="card-item-label text-hide">兑换码:{{code}}</div>
<div class="btn-clone" @click="getClone">复制</div>
</div>
</div> </div>
</div> </div>
</div>
</div> </div>
</div> <div class="card-panel" v-if="detailInfo.cardType == 0">
<div class="card-panel" v-if="codeStatus == 2">
<div class="card-qrcode-panel"> <div class="card-qrcode-panel">
<van-swipe> <img :src="detailInfo.qrcode" preview="0"/>
<van-swipe-item v-for="(image, index) in images" :key="index">
<img :src="image" />
<div class="card-qrcode-step">NO.{{index+1}}</div>
</van-swipe-item>
</van-swipe>
</div> </div>
</div> </div>
<div class="card-tips-panel"> <div class="card-tips-panel">
...@@ -69,10 +51,13 @@ ...@@ -69,10 +51,13 @@
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
import {cardRoll} from "@r/api";
export default { export default {
name: "detail", name: "detail",
data() { data() {
return { return {
detailInfo: {},
codeStatus: 1, codeStatus: 1,
status: 3, status: 3,
account: '', account: '',
...@@ -80,16 +65,31 @@ export default { ...@@ -80,16 +65,31 @@ export default {
url: 'hksdhfkjahksdjfhksjhdafksjdhfkjshadkfjhskdjfhka', url: 'hksdhfkjahksdjfhksjhdafksjdhfkjshadkfjhskdjfhka',
qrcode: [1], qrcode: [1],
code: '', code: '',
images: [ images: 'https://img01.yzcdn.cn/vant/apple-1.jpg'
'https://img01.yzcdn.cn/vant/apple-1.jpg',
'https://img01.yzcdn.cn/vant/apple-2.jpg',
],
} }
}, },
mounted() {
this.showLoading()
let {orderCode} = this.$route.query;
let {sessionId} = JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO'));
let para = {
orderCode,
sessionId
}
cardRoll.getCardDetail(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.detailInfo = data;
} else {
this.showToast(message)
}
})
},
methods: { methods: {
//复制编码 //复制编码
getClone() { getClone(value) {
this.cloneText(123123) this.cloneText(value)
} }
} }
} }
...@@ -123,22 +123,13 @@ export default { ...@@ -123,22 +123,13 @@ export default {
} }
.card-qrcode-panel { .card-qrcode-panel {
width: 160px; width: 160px;
height: 160px;
margin: 10px auto; margin: 10px auto;
padding-top: 20px; padding-top: 20px;
/deep/ img { img {
width: 160px; width: 160px;
height: 160px; height: 160px;
} }
/deep/ .van-swipe__indicators {
bottom: 34px;
}
.card-qrcode-step {
font-size: 16px;
color: #333333;
line-height: 30px;
text-align: center;
margin-top: 30px;
}
} }
.card-item { .card-item {
background: #f2f2f2; background: #f2f2f2;
...@@ -183,6 +174,7 @@ export default { ...@@ -183,6 +174,7 @@ export default {
text-shadow: 0px 2px 4px rgba(254, 96, 0, 0.24); text-shadow: 0px 2px 4px rgba(254, 96, 0, 0.24);
} }
.btn-clone { .btn-clone {
margin-left: 10px;
display: inline-block; display: inline-block;
text-align: center; text-align: center;
width: 36px; width: 36px;
......
...@@ -2,26 +2,137 @@ ...@@ -2,26 +2,137 @@
<div class="main"> <div class="main">
<div class="box"> <div class="box">
<div class="opening-border"> <div class="opening-border">
<div class="opening-border-p">合伙门店权益卡 <span>未开通</span></div>
<div class="opening-border-p">尊享100+专属权益</div>
<div class="opening-border-p price" v-if="price">¥<span>{{price}}</span>/年</div>
</div>
<div class="opening-vip-border">
<img src="@a/images/title-100.png" alt="" class="vip-title-images">
<div class="vip-shop-panel">
<img src="@a/images/vip-more.png" alt="">
</div>
<div class="vip-more">更多权益,开通即享</div>
</div>
<div class="opening-other">
<div class="opening-other-title">
其他开通方式
</div>
<div class="opening-other-border" @click="jumpOpen">
<div class="other-border-icon">
<img src="@a/images/exchange.png" alt="">
</div>
<div class="other-border-desc">
<div class="other-border-p1">兑换权益卡</div>
<div class="other-border-p2">设备码兑换</div>
</div>
</div>
</div> </div>
<div class="opening-operation"> </div>
<div class="opening-operation-price"><span>¥29.9</span>立即开通</div> <div class="opening-loading-panel" v-if="openingStatus">
<div class="opening-operation-desc">开通权益代表接受《权益服务协议》</div> <div class="opening-popup">
<div class="opening-header">
<div class="opening-jump" @click="jumpPast">
<span>跳过</span>
</div>
</div>
<div class="opening-tips">
支付成功 正在开卡中…
</div>
<div class="opening-loading">
<van-loading color="#19C34E" size="40" class="opening-loading-icon"/>
</div>
</div> </div>
</div> </div>
<div class="opening-operation">
<div class="opening-operation-price" v-if="price" @click="buyCard"><span>¥{{ price }}</span>立即开通</div>
<div class="opening-operation-price disabled" v-else>暂不支持付费购买</div>
<div class="opening-operation-desc">开通权益代表接受 <a @click="jumpAgree">《权益服务协议》</a></div>
</div>
</div> </div>
</template> </template>
<script> <script>
import {cardRoll, equity} from "@r/api";
import WxConfig from '@u/WxConfig'
const WX = new WxConfig(['chooseWXPay']);
export default { export default {
name: "opening", name: "opening",
data() { data() {
return { return {
price: '',
orderCode:'',
openingStatus: false,
merchantId: sessionStorage.getItem('GL_WX_MERCHANTID'),
} }
}, },
mounted() {
this.showLoading();
let para = {
merchantId: this.merchantId
}
cardRoll.getCardMerchantid(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.price = data.goodPrice;
this.orderCode = data.orderCode;
} else {
this.showToast(message)
}
})
},
methods: { methods: {
jumpOpen() {
window.vm.$router.push({ name: 'common.activate' });
},
async buyCard() {
let {sessionId} = JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO'));
this.showLoading();
let para = {
merchantId: this.merchantId,
orderCode: this.orderCode,
payMannerId: 9,
orderSource: 3,
sessionId,
}
let payData = await cardRoll.getCardBuy(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
return data
} else {
this.showToast(message)
}
})
const { timeStamp,nonceStr, packages, signType, paySign } = payData;
WX.chooseWXPay(timeStamp,nonceStr, packages, signType, paySign).then(res => {
console.log(res);
this.getCardInfo();
})
},
getCardInfo() {
this.openingStatus = true;
equity.getCardInfo().then(res => {
console.log(res)
this.hideLoading()
let { code, message } = res;
this.openingStatus = false;
if (code == 0) {
sessionStorage.setItem('CODE_STATUS', 1);
window.vm.$router.replace({ name: 'equity.index' });
} else {
sessionStorage.setItem('CODE_STATUS', 0)
this.showToast(message)
}
})
},
jumpPast() {
window.vm.$router.replace({ name: 'equity.index' });
this.openingStatus = false;
},
jumpAgree() {
window.vm.$router.push({ name: 'cardRoll.agreement' });
}
} }
} }
</script> </script>
...@@ -30,20 +141,204 @@ export default { ...@@ -30,20 +141,204 @@ export default {
.main { .main {
.box { .box {
padding: 20px; padding: 20px;
.opening-operation { .opening-border {
width: 337px; background-image: url('~@a/images/card.png');
height: 44px; background-size: 100% 100%;
background: #008FFF; border-radius: 16px;
border-radius: 22px; padding: 15px 20px;
color: #FFFFFF; height: 125px;
text-align: center; box-sizing: border-box;
&-price { &-p {
line-height: 22px; font-size: 16px;
margin-bottom: 10px;
color: #FFFFFF;
text-shadow: 0 2px 4px rgba(254,96,0,0.24);
display: flex;
justify-content: space-between;
&.price {
font-size: 14px;
justify-content: flex-start;
font-weight: 700;
line-height: 40px;
>span {
font-size: 26px;
color: #FFFFFF;
}
}
>span { >span {
margin-right: 10px; font-size: 14px;
color: #8B5A0F;
} }
} }
} }
.opening-vip-border {
height: 190px;
margin-top: 60px;
box-sizing: border-box;
background: #FFFFFF;
border: 1px solid #F5D890;
box-shadow: 0 2px 8px 0 rgba(255,222,166,0.30);
border-radius: 8px;
position: relative;
.vip-title-images {
position: absolute;
width: 200px;
height: 40px;
top: -30px;
left: 50%;
margin-left: -100px;
}
.vip-shop-panel {
height: 140px;
width: 312px;
margin: 14px auto 8px auto;
}
.vip-more {
font-size: 12px;
color: #CE9B1F;
letter-spacing: 0;
text-align: center;
line-height: 24px;
}
}
.opening-other {
margin: 20px auto;
&-title {
font-size: 16px;
color: #666666;
position: relative;
height: 22px;
padding-left: 15px;
margin-bottom: 10px;
&:before {
content: '';
position: absolute;
top: 0px;
left: 0px;
width: 4px;
height: 22px;
background: #FFAE23;
}
}
&-border {
opacity: 0.86;
border: 1px solid #FFA100;
border-radius: 8px;
width: 148px;
height: 60px;
display: flex;
padding: 10px;
box-sizing: border-box;
align-items: center;
justify-content: space-between;
.other-border-icon {
width: 36px;
height: 25px;
}
.other-border-p1 {
font-size: 14px;
color: #FFA100;
line-height: 20px;
}
.other-border-p2 {
font-size: 12px;
color: #6A6A6A;
line-height: 20px;
}
}
}
}
.opening-loading-panel {
position: fixed;
top: 0;
left: 0;
z-index: 2015;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.2);
.opening-popup {
width: 205px;
height: 184px;
border-radius: 8px;
opacity: 0.94;
position: fixed;
max-height: 100%;
overflow-y: auto;
background-color: #fff;
top: 50%;
left: 50%;
-webkit-transform: translate3d(-50%, -50%, 0);
transform: translate3d(-50%, -50%, 0);
.opening-header {
text-align: right;
padding: 10px;
display: flex;
justify-content: flex-end;
.opening-jump {
width: 32px;
height: 20px;
line-height: 20px;
text-align: center;
border-radius: 14px;
border: 1px solid #CDCDCD;
box-sizing: border-box;
font-size: 10px;
color: #666666;
}
}
.opening-tips {
width: 96px;
height: 44px;
font-size: 16px;
margin-left: 17px;
font-weight: 500;
color: #19C34E;
line-height: 22px;
}
.opening-loading {
text-align: center;
margin: 10px auto;;
.opening-loading-icon {
font-size: 80px;
}
}
}
}
.opening-operation {
position: fixed;
bottom: 0px;
height: 65px;
width: 100%;
padding: 6px 0px;
box-sizing: border-box;
background: #FFFFFF;
box-shadow: 0 -2px 4px 0 rgba(0,0,0,0.20);
&-price {
width: 342px;
margin: 0px auto;
height: 32px;
opacity: 0.86;
background: linear-gradient(129deg, #FF9900 0%, #FEBE00 76%, #FFBE00 100%);
border-radius: 20px;
font-size: 16px;
color: #FFFFFF;
letter-spacing: 0;
text-align: center;
line-height: 32px;
&.disabled {
background: #aaaaaa;
}
}
&-desc {
font-size: 12px;
color: #565656;
line-height: 23px;
letter-spacing: 0;
text-align: center;
>a {
text-decoration: underline;
}
}
} }
} }
</style> </style>
\ No newline at end of file \ No newline at end of file
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<div class="apply-item-1"> <div class="apply-item-1">
<div class="apply-title">申请描述</div> <div class="apply-title">申请描述</div>
<van-field <van-field
v-model="message" v-model="reason"
rows="6" rows="6"
autosize autosize
type="textarea" type="textarea"
...@@ -17,37 +17,62 @@ ...@@ -17,37 +17,62 @@
<div class="apply-item-2"> <div class="apply-item-2">
<div class="apply-title">上传图片</div> <div class="apply-title">上传图片</div>
<div class="apply-photo"> <div class="apply-photo">
<div class="apply-photo-b" @click="changeImage"> <div class="apply-photo-b" >
<img src="@a/images/upload.png"> <img :src="refundImg" @click="uploadImage" v-if="refundImg">
<img src="@a/images/upload.png" @click="uploadImage" v-else>
</div> </div>
</div> </div>
</div> </div>
<div class="apply-item-3"> <div class="apply-item-3">
<div class="apply-title">申请金额</div> <div class="apply-title">申请金额</div>
<div class="apply-price">¥23.6 <span>修改金额</span></div> <div class="apply-price">¥{{ orderPrices }}</div>
</div> </div>
<div class="apply-operation"> <div class="apply-operation">
<div class="apply-btn" @click="jumpApply">提交申请</div> <div class="apply-btn" @click="jumpApply">提交申请</div>
</div> </div>
<!-- <van-dialog v-model="priceDialog" title="修改金额" show-cancel-button @cancel="cancel" @confirm="confirm">-->
<!-- <van-field v-model="price2" type="number"/>-->
<!-- </van-dialog>-->
</div> </div>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
import {common} from "@r/api"; import {cardRoll, common} from "@r/api";
import WxConfig from '@u/WxConfig' import WxConfig from '@u/WxConfig'
const WX = new WxConfig([ 'chooseImage']) const WX = new WxConfig([ 'chooseImage'])
export default { export default {
name: "salesApply", name: "salesApply",
data() { data() {
return { return {
message: '', priceDialog: false,
applyImg: '' price2: '',
reason: '',
refundImg: '',
orderPrices: ''
} }
}, },
mounted() {
this.orderCode = this.$route.query.orderCode;
this.orderPrices = this.$route.query.orderPrices;
},
methods: { methods: {
handleEditPrice() {
this.priceDialog = true;
this.price2 = this.orderPrices;
},
confirm() {
if(this.price2 <= this.orderPrices) {
this.orderPrices = parseFloat(this.price2);
}
this.priceDialog = false;
},
cancel() {
this.showToast('取消成功');
this.priceDialog = false;
},
//上传图片 //上传图片
chooseImage () { uploadImage () {
WX.chooseImage().then(res => { WX.chooseImage().then(res => {
let [data] = res let [data] = res
let { localData } = data let { localData } = data
...@@ -68,20 +93,44 @@ export default { ...@@ -68,20 +93,44 @@ export default {
common.uploadImage({ common.uploadImage({
file: `${type}@${imgUrl}` file: `${type}@${imgUrl}`
}).then(img => { }).then(img => {
console.log(img)
if (img) { if (img) {
this.applyImg = img.data; this.refundImg = img.data;
this.showToast('上传成功') this.showToast('上传成功')
} else { } else {
this.showToast('上传失败') this.showToast('上传失败')
this.applyImg = ''; this.refundImg = '';
} }
}) })
}) })
}, },
//跳转 //跳转
jumpApply() { jumpApply() {
window.vm.$router.push({ name: 'cardRoll.salesDetail' }) if(!this.reason){
this.showToast('请输入申请描述')
return
}
if(!this.refundImg){
this.showToast('请上传图片')
return
}
this.showLoading();
let {sessionId} = JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO'));
let para = {
orderCode: this.orderCode,
reason: this.reason,
refundImg: this.refundImg,
sessionId
}
cardRoll.getCardRefund(para).then(res => {
this.hideLoading();
console.log(res)
let { code, message } = res
if (code == 0) {
window.vm.$router.push({ name: 'cardRoll.waiting' })
} else {
this.showToast(message)
}
})
} }
} }
} }
......
<template> <template>
<div class="main"> <div class="main">
<div class="box" v-if="salesStatus"> <div class="box" v-if="salesStatus">
<div class="sales-h"> <div class="sales-h" v-if="detail.refundStatus == 1">
<div class="sales-status-1 after-status">售后中</div> <div class="sales-status-1 after-status">售后中</div>
<div class="sales-status-2">等待平台处理</div> <div class="sales-status-2">等待平台处理</div>
</div> </div>
<div class="sales-h" v-if="detail.refundStatus == 3">
<div class="sales-status-1 after-status">已退款</div>
<div class="sales-status-2">钱款将原路退回至您的账户</div>
</div>
<div class="sales-h" v-if="detail.refundStatus == 2">
<div class="sales-status-1 after-status">拒绝售后</div>
<div class="sales-status-2">该商品已退换兑换或不支持售后</div>
</div>
<div class="sales-desc"> <div class="sales-desc">
<p><span>售后商品:</span>星巴克中杯全国通兑券</p> <p><span>售后商品:</span>{{ detail.productName }}</p>
<p class="sales-price"><span>申请金额:</span>¥29.5</p> <p class="sales-price"><span>申请金额:</span>{{ detail.orderPrice }}</p>
<p><span>申请时间:</span>2021-06-21 18:23:21</p> <p><span>申请时间:</span>{{ detail.createDate }}</p>
<p><span>申请描述:</span>使用不了,兑换失败,退款</p> <p><span>申请描述:</span>{{ detail.reason }}</p>
<p><span>售后编号:</span>使用不了,兑换失败,退款</p> <p><span>售后编号:</span>{{ detail.orderCode }}</p>
<p><span>订单编号:</span>使用不了,兑换失败,退款</p> <p><span>订单编号:</span>{{ detail.refundCode }}</p>
</div> </div>
<div class="sales-image"> <div class="sales-image">
<div class="sales-image-item"></div> <div class="sales-image-item">
<div class="sales-image-item"></div> <img :src="detail.img" preview="0">
<div class="sales-image-item"></div> </div>
</div> </div>
</div> </div>
<div class="box" v-else> <div class="box" v-else>
...@@ -30,12 +38,35 @@ ...@@ -30,12 +38,35 @@
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
import {cardRoll} from "@r/api";
export default { export default {
name: "salesDetail", name: "salesDetail",
data() { data() {
return { return {
salesStatus: true, salesStatus: true,
salesResult: 1,
detail: {},
} }
},
mounted() {
this.showLoading()
let {orderCode} = this.$route.query;
let {sessionId} = JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO'));
let para = {
orderCode,
sessionId
}
cardRoll.getCardRefundDetail(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.detail = data;
} else {
this.showToast(message)
}
})
},
methods: {
} }
} }
</script> </script>
...@@ -90,7 +121,7 @@ export default { ...@@ -90,7 +121,7 @@ export default {
} }
.sales-image { .sales-image {
display: flex; display: flex;
justify-content: space-around; justify-content: center;
margin-top: 20px; margin-top: 20px;
.sales-image-item { .sales-image-item {
width: 96px; width: 96px;
......
<template>
<div class="main">
<div class="box">
<div class="sales-h">
<van-icon name="clock" class="sales-icon"/>
<div class="sales-status-1">等待处理</div>
<div class="sales-status-2">已提交申请,等待处理</div>
</div>
</div>
</div>
</template>
<script type='text/ecmascript-6'>
export default {
name: "waiting",
data() {
return {
}
},
mounted() {
},
methods: {
}
}
</script>
<style scoped lang="scss">
.main {
.box {
padding: 0 15px;
.sales-h {
margin-bottom: 30px;
text-align: center;
line-height: 30px;
.sales-icon {
font-size: 50px;
color: #19c341;
margin-top: 100px;
}
.sales-status-1 {
height: 33px;
font-size: 24px;
font-weight: 500;
color: #333333;
line-height: 33px;
&.after-status {
margin-top: 35px;
}
}
.sales-status-2 {
font-size: 16px;
font-weight: 400;
color: #999999;
line-height: 22px;
margin-top: 8px;
}
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -40,8 +40,8 @@ ...@@ -40,8 +40,8 @@
<div class="process-detail-name">爱奇艺黄金会员1个月</div> <div class="process-detail-name">爱奇艺黄金会员1个月</div>
<div class="process-detail-account">充值账号:82398239489</div> <div class="process-detail-account">充值账号:82398239489</div>
<div class="process-detail-operation"> <div class="process-detail-operation">
<div class="process-recharge">继续充值</div> <div class="process-recharge" @click="getAgainPay">继续充值</div>
<div class="process-order">查看订单</div> <div class="process-order" @click="getOrder">查看订单</div>
</div> </div>
</div> </div>
</div> </div>
...@@ -56,8 +56,16 @@ export default { ...@@ -56,8 +56,16 @@ export default {
} }
}, },
mounted() { mounted() {
console.log(window.vm)
}, },
methods: {
getAgainPay() {
window.vm.$router.go(-1)
},
getOrder() {
window.vm.$router.push({ name: 'cardRoll.index',query:{appearance: 2} })
}
}
} }
</script> </script>
......
...@@ -3,21 +3,23 @@ ...@@ -3,21 +3,23 @@
<div class="box"> <div class="box">
<div class="box-h"> <div class="box-h">
<div class="recharge-title">充值账号</div> <div class="recharge-title">充值账号</div>
<van-field v-model="mobile" class="input-recharge" placeholder="请输入充值手机号" type="digit" maxlength="11"/> <van-field v-model="rechargeNumber" class="input-recharge" placeholder="请输入充值账号"/>
</div> </div>
<div class="recharge-select"> <div class="recharge-select">
<div class="recharge-select-name">充值类型</div> <div class="recharge-select-name">充值类型</div>
<div class="recharge-select-panel"> <div class="recharge-select-panel">
<div class="recharge-select-item" :class="{'checked':typeSno == index}" @click="selectType(index)" v-for="(item,index) in reType" :key="index">黄金会员</div> <div class="recharge-select-item" :class="{'checked':typeSno == index}" @click="selectType(index)" v-for="(item,index) in businessList" :key="index">
{{ item.productName }}</div>
</div> </div>
</div> </div>
<div class="recharge-select"> <div class="recharge-select">
<div class="recharge-select-name">充值面额</div> <div class="recharge-select-name">充值面额</div>
<div class="recharge-select-panel"> <div class="recharge-select-panel">
<div class="recharge-select-item2" :class="{'checked':amountSno == index}" @click="selectAmount(index)" v-for="(item,index) in reType" :key="index"> <div class="recharge-select-item2" :class="{'checked':amountSno == index}" @click="selectAmount(index)" v-for="(item,index) in denominationList" :key="index">
<div class="recharge-item-time recharge-im">1天</div> <div class="recharge-item-time recharge-im">{{ item.denomination }}</div>
<div class="recharge-item-total recharge-im">售价3.6元</div> <div class="recharge-item-total recharge-im">售价{{ item.salesPrice }}元</div>
<div class="recharge-item-total2 line-through">官方价3.9元</div> <div class="recharge-item-total2" v-if="!isOpen">权益价{{ item.lineationPrice }}元</div>
<div class="recharge-item-total2 line-through" v-else>官方价{{ item.lineationPrice }}元</div>
</div> </div>
</div> </div>
</div> </div>
...@@ -31,37 +33,85 @@ ...@@ -31,37 +33,85 @@
<van-icon name="coupon-o" class="card-roll-icon"/> <van-icon name="coupon-o" class="card-roll-icon"/>
<div>我的卡券</div> <div>我的卡券</div>
</div> </div>
<div class="card-roll"> <div class="card-roll" @click="jumpCustomer">
<van-icon name="smile-comment-o" class="card-roll-icon"/> <van-icon name="smile-comment-o" class="card-roll-icon"/>
<div>客服</div> <div>客服</div>
</div> </div>
<div class="recharge-operation" @click="chooseWXPay"><span>8.00元</span>立即充值</div> <template v-if="isOpen">
<div class="recharge-operation" @click="chooseWXPay"><span>{{denomination.salesPrice}}元</span>立即充值</div>
</template>
<template v-else>
<div class="recharge-operation" @click="jumpOpening">去开通权益</div>
</template>
</div> </div>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
import { pay} from '@/mixins' import { pay} from '@/mixins'
import {commodity} from "@r/api";
export default { export default {
mixins: [pay], mixins: [pay],
name: "recharge", name: "recharge",
data() { data() {
return { return {
isOpen: sessionStorage.getItem('CODE_STATUS'),
appearance: 2,
rechargeNumber: '',
businessStatus: 1,
denomination: {},
denominationList: [],
businessList: [],
mobile: '', mobile: '',
reType: [2,3,4,5], reType: [2,3,4,5],
typeSno: 0, typeSno: 0,
amountSno: 0, amountSno: 0,
brandId: '',
supplier: ''
} }
}, },
mounted() {
this.showLoading();
let {brandId,supplier} = this.$route.query;
this.brandId = brandId;
this.supplier = supplier;
let para = {
brandId,
supplier
}
commodity.getChargeDetail(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.businessList = data;
this.denominationList = this.businessList[0].denominationList;
this.denomination = this.denominationList[0];
} else {
this.showToast(message)
}
})
},
methods: { methods: {
jumpOpening() {
window.vm.$router.push({ name: 'cardRoll.opening' })
},
getCard() { getCard() {
window.vm.$router.push({ name: 'cardRoll.index' }) window.vm.$router.push({ name: 'cardRoll.index',query:{appearance:this.appearance} })
},
jumpCustomer() {
window.vm.$router.push({ name: 'cardRoll.customer'});
}, },
//充值类型
selectType(item) { selectType(item) {
this.typeSno = item; this.typeSno = item;
this.amountSno = 0;
this.denominationList = this.businessList[item].denominationList;
this.denomination = this.businessList[item].denominationList[0];
}, },
//选择面额
selectAmount(item) { selectAmount(item) {
this.amountSno = item; this.amountSno = item;
this.denomination = this.denominationList[item]
} }
} }
} }
...@@ -95,9 +145,8 @@ export default { ...@@ -95,9 +145,8 @@ export default {
color: #333333; color: #333333;
} }
&-panel { &-panel {
display: flex; display: grid;
flex-wrap: wrap; grid-template-columns: 33.3% 33.3% 33.3%;
justify-content: space-between;
margin-top: 10px; margin-top: 10px;
.recharge-select-item { .recharge-select-item {
width: 105px; width: 105px;
...@@ -106,7 +155,7 @@ export default { ...@@ -106,7 +155,7 @@ export default {
border: 1px solid #E9E9E9; border: 1px solid #E9E9E9;
line-height: 50px; line-height: 50px;
text-align: center; text-align: center;
margin-bottom: 10px; margin: 10px 10px 0px 0px;
color: #666666; color: #666666;
&.checked { &.checked {
background: #E6F4FF; background: #E6F4FF;
......
...@@ -5,11 +5,11 @@ ...@@ -5,11 +5,11 @@
<van-icon name="checked" class="success-icon" v-if="status"/> <van-icon name="checked" class="success-icon" v-if="status"/>
<van-icon name="warning" class="warning-icon" v-else/> <van-icon name="warning" class="warning-icon" v-else/>
</div> </div>
<div class="success-number">122</div> <div class="success-number">{{ price }}</div>
<div class="success-desc" v-if="status">订单支付成功</div> <div class="success-desc" v-if="status">订单支付成功</div>
<div class="success-desc" v-if="!status">订单支付失败</div> <div class="success-desc" v-if="!status">订单支付失败</div>
<div class="success-order" v-if="status">查看订单</div> <div class="success-order" v-if="status" @click="getOrder">查看订单</div>
<div class="success-order" v-if="!status">重新购买</div> <div class="success-order" v-if="!status" @click="getAgainPay">重新购买</div>
</div> </div>
</div> </div>
</template> </template>
...@@ -20,6 +20,18 @@ export default { ...@@ -20,6 +20,18 @@ export default {
data() { data() {
return { return {
status: true, status: true,
price: '',
}
},
mounted() {
this.price = this.$route.query.price;
},
methods: {
getAgainPay() {
window.vm.$router.go(-1)
},
getOrder() {
window.vm.$router.push({ name: 'cardRoll.index',query:{appearance: 1} })
} }
} }
} }
......
...@@ -22,134 +22,42 @@ ...@@ -22,134 +22,42 @@
<div class="bar_title"><span>用车权益</span></div> <div class="bar_title"><span>用车权益</span></div>
<div class="car_content"> <div class="car_content">
<div class="items"> <div class="items">
<template v-for="(i,index) in travelList"> <template v-for="(i,index) in carServiceList">
<div <div
class="item" class="item"
:key="index" :key="index"
@click="unReceiveDialog" @click="unReceiveDialog"
> >
<div :class="['sprite-icon',`icon-${i.icon}`]"></div> <div class="icon-goods">
<div class="item-name">{{i.name}}</div> <img :src="i.equityIcon" alt="">
<div class="item-des">{{i.description}}</div> </div>
<div class="item-name">{{i.equityName}}</div>
<div class="item-des">{{i.equityDesc}}</div>
</div> </div>
</template> </template>
<div
class="item"
@click="willComeDialog"
>
<div :class="['sprite-icon',`icon-car_charge`]"></div>
<div class="item-name">车辆充电</div>
<div class="item-des">6折起</div>
</div>
<div
class="item"
@click="willComeDialog"
>
<div :class="['sprite-icon',`icon-call_drive`]"></div>
<div class="item-name">叫代驾</div>
<div class="item-des">9折起</div>
</div>
</div> </div>
</div> </div>
</div> </div>
<div class="box equity_box"> <div class="box equity_box">
<div class="bar_title"><span>更多权益</span></div> <div class="bar_title"><span>更多权益</span></div>
<div class="scroll-items"> <div class="scroll-items">
<ul class="tab_list"> <ul class="tab_list" >
<li :class="activeTab==='drink'?'active':''" @click="activeTab='drink'">咖啡饮品</li> <li :class="goodsTab === index?'active':''" @click="goodsTab=index" v-for="(item,index) in goodsServiceKey" :key="index">{{item}}</li>
<li :class="activeTab==='catering'?'active':''" @click="activeTab='catering'">餐饮美食</li>
<li :class="activeTab==='video'?'active':''" @click="activeTab='video'">影音娱乐</li>
<li :class="activeTab==='trip'?'active':''" @click="activeTab='trip'">生活出行</li>
<li :class="activeTab==='read'?'active':''" @click="activeTab='read'">知识阅读</li>
<li :class="activeTab==='health'?'active':''" @click="activeTab='health'">医护健康</li>
</ul> </ul>
</div> </div>
<div class="tab_content" v-show="activeTab==='drink'"> <div class="tab_content">
<div class="items items_5_1"> <div class="items items_5_1">
<template v-for="(i,index) in drinkList"> <template v-for="(i,index) in goodsServiceList[goodsServiceKey[goodsTab]]">
<div <div
class="item" class="item"
:key="index" :key="index"
@click="unReceiveDialog" @click="unReceiveDialog"
> >
<div :class="['sprite-icon',`icon-${i.icon}`]"></div> <div class="icon-goods">
<div class="item-name">{{i.name}}</div> <img :src="i.equityIcon" alt="">
<div class="item-des">{{i.description}}</div> </div>
</div> <div class="item-name">{{i.brandName}}</div>
</template> <div class="item-des">{{i.equityDesc}}</div>
</div>
</div>
<div class="tab_content" v-show="activeTab==='catering'">
<div class="items items_5_1">
<template v-for="(i,index) in cateringList">
<div
class="item"
:key="index"
@click="unReceiveDialog"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='video'">
<div class="items items_5_1">
<template v-for="(i,index) in videoList">
<div
class="item"
:key="index"
@click="unReceiveDialog"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='trip'">
<div class="items items_5_1">
<template v-for="(i,index) in tripList">
<div
class="item"
:key="index"
@click="unReceiveDialog"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='read'">
<div class="items items_5_1">
<template v-for="(i,index) in readList">
<div
class="item"
:key="index"
@click="unReceiveDialog"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='health'">
<div class="items items_5_1">
<template v-for="(i,index) in healthList">
<div
class="item"
:key="index"
@click="unReceiveDialog"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div> </div>
</template> </template>
</div> </div>
...@@ -169,6 +77,7 @@ export default { ...@@ -169,6 +77,7 @@ export default {
data () { data () {
return { return {
activeTab: 'drink', activeTab: 'drink',
goodsTab: 0,
userInfo: sessionStorage.getItem('GL_EQUITY_USER_INFO')?sessionStorage.getItem('GL_EQUITY_USER_INFO'):{}, userInfo: sessionStorage.getItem('GL_EQUITY_USER_INFO')?sessionStorage.getItem('GL_EQUITY_USER_INFO'):{},
} }
......
...@@ -2,39 +2,32 @@ ...@@ -2,39 +2,32 @@
<div class="main"> <div class="main">
<div class="box"> <div class="box">
<div class="header"> <div class="header">
<div class="sprite-icon icon-equity-bg"></div>
<div class="type-1-header">
道路救援
<div class="sprite-icon icon-equity-type1"></div>
</div>
</div> </div>
<div class="body"> <div class="body">
<div class="type-1-body"> <div class="type-1-body">
<div class="title"> <div class="title-sign">
<span>碰撞维修权益说明</span> 权益说明
</div> </div>
<div class="content"> <div class="content-ul">
<p>1、<span>发生碰撞事故后,车主须返回指定经销处维修方可享受补偿,维修质量由承修经销商负责</span></p> <p>1、发生碰撞事故后,车主须返回指定经销处维修方可享受补偿,维修质量由承修经销商负责。</p>
<p>2、<span>必须投保商业车损险,且出险后车损险定损金额须达到起赔点</span></p> <p>2、必须投保商业车损险,且出险后车损险定损金额须达到起赔点。</p>
<p>3、<span>发生碰撞事故,经商业车损险承保公司核定属于保险事故,启动车损险赔付后方可申请补偿(不区分事故责任归属)</span></p> <p>3、发生碰撞事故,经商业车损险承保公司核定属于保险事故,启动车损险赔付后方可申请补偿(不区分事故责任归属)。</p>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<div <div
class="phone btn" class="phone btn"
@click="makePhoneCall('4008060999')" @click="makePhoneCall('400-6123-886')"
> >
<div class="sprite-icon icon-equity-phone"></div> <div class="icon-equity-phone"><van-icon name="phone-o" class="icon-phone"/>服务热线 400-6123-886</div>
电话咨询
</div> </div>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
export default { export default {
name: 'collision', name: 'loss',
data () { data () {
return { return {
} }
...@@ -49,13 +42,15 @@ export default { ...@@ -49,13 +42,15 @@ export default {
<style scoped lang='scss'> <style scoped lang='scss'>
.main { .main {
.box { .box {
border: 1px solid #fbdcae; position: absolute;
border-radius: 4px; min-height: 100%;
margin: 30px 26.5px 40px; width: 100%;
background: #068589;
.header { .header {
width: 100%; width: 100%;
height: 100px; height: 250px;
position: relative; background-image: url("~@a/images/equity/colltit.png");
background-size: 100% 100%;
> div { > div {
position: absolute; position: absolute;
left: 0; left: 0;
...@@ -76,15 +71,38 @@ export default { ...@@ -76,15 +71,38 @@ export default {
} }
} }
.body { .body {
padding: 24px 30px 20px;
font-size: 12px; font-size: 12px;
color: #333; color: #333;
.type-1-body {
padding: 16px;
box-sizing: border-box;
background: #FFFFFF;
box-shadow: 0 2px 4px 0 rgba(255,255,255,0.50);
border-radius: 8px;
width: 335px;
margin: 10px auto 60px auto;
position: relative;
.title-sign {
position: absolute;
left: 50%;
color: #FFFFFF;
margin-left: -85.5px;
top: -15px;
width: 171px;
height: 30px;
line-height: 30px;
text-align: center;
background-image: url("~@a/images/equity/coll.png");
background-size: 100% 100%;
}
}
> div { > div {
.title { .title {
font-size: 16px; font-size: 16px;
color: #6a6a6a; color: #6a6a6a;
font-weight: 700; font-weight: 700;
position: relative; position: relative;
text-align: center;
span { span {
position: relative; position: relative;
&::after { &::after {
...@@ -99,10 +117,18 @@ export default { ...@@ -99,10 +117,18 @@ export default {
} }
} }
} }
.content-ul {
font-size: 12px;
color: #005254;
p {
margin-top: 20px;
}
}
.content { .content {
margin: 14px 0 8px; margin: 14px 0 8px;
line-height: 24px; line-height: 18px;
color: #333; font-size: 12px;
color: #4C4C4C;
p { p {
display: grid; display: grid;
grid-template-columns: 20px 1fr; grid-template-columns: 20px 1fr;
...@@ -116,24 +142,35 @@ export default { ...@@ -116,24 +142,35 @@ export default {
} }
} }
.tips { .tips {
color: #666; color: #4C4C4C;
font-size: 12px;
} }
} }
} }
} }
.btn { .btn {
width: 85.9%; position: fixed;
height: 44px; width: 100%;
height: 50px;
bottom: 0px;
background: #FFFFFF;
display: flex; display: flex;
align-items: center;
justify-content: center; justify-content: center;
margin: 40px auto 20px; align-items: center;
font-size: 18px; .icon-equity-phone {
color: #ffffff; margin: 3px auto;
background: #ffc775; background: #008FFF;
border-radius: 10px; color: #FFFFFF;
.sprite-icon { text-align: center;
margin-right: 20px; width: 343px;
height: 44px;
line-height: 44px;
border-radius: 20px;
.icon-phone {
margin-right: 8px;
font-size: 20px;
vertical-align: middle;
}
} }
} }
} }
......
...@@ -2,55 +2,46 @@ ...@@ -2,55 +2,46 @@
<div class="main"> <div class="main">
<div class="box"> <div class="box">
<div class="header"> <div class="header">
<div class="sprite-icon icon-equity-bg"></div>
<div class="type-1-header">
道路救援
<div class="sprite-icon icon-equity-type1"></div>
</div>
</div> </div>
<div class="body"> <div class="body">
<div class="type-1-body"> <div class="type-1-body">
<div class="title"> <div class="title-sign">
<span>盗抢全损权益说明</span> 权益说明
</div> </div>
<div class="content"> <div class="content">
服务范围:在正确安装并使用深圳广联赛讯股份有限公司提供的“车载智能终端”产品情况下,签订整车全损无忧合同,赔偿标准包含:服务范围:在正确安装并使用深圳广联赛讯股份有限公司提供的“车载智能终端”产品情况下,全车被盗抢,经商业车损险公司赔偿后,赔偿车主由于车辆被盗导致的相关损失,包括 服务范围:在正确安装并使用深圳广联赛讯股份有限公司提供的“车载智能终端”产品情况下,全车被盗抢,经商业车损险公司赔偿后,赔偿车主由于车辆被盗导致的相关损失,包括
</div> </div>
<div class="content"> <div class="content-ul">
<ul> <p>— 商业车损险赔偿免赔额部分;</p>
<li>商业车损险赔偿免赔额部分;</li> <p>— 车辆购置税;</p>
<li>车辆购置税;</li> <p>— 重置车辆的登记费用;</p>
<li>重置车辆的登记费用;</li> <p>— 为减损要求使用其他代步车辆产生的费用损失;</p>
<li>为减损要求使用其他代步车辆产生的费用损失;</li> <p>— 车辆盗抢过程中产生的合理维修费用;</p>
<li>车辆盗抢过程中产生的合理维修费用;</li> <p> — 补偿被盗抢车辆的加装损失;</p>
<li>补偿被盗抢车辆的加装损失;</li> <p> — 随车行李损失;</p>
<li>随车行李损失;</li>
</ul>
</div> </div>
<div class="content"> <div class="content">
服务区域:全国(除港澳台) 服务区域:全国(除港澳台)
</div> </div>
<div class="content"> <div class="tips">
除外责任:未投保商业车损险或商业车损险承保公司拒赔或者未予理赔的; <p>除外责任:未投保商业车损险或商业车损险承保公司拒赔或者未予理赔的;</p>
<p>服务须知:在发生服务责任范围内事故后的24小时内向事故当地公安机关报案,保留现场并同时通知深圳广联赛讯股份有限公司,并全面告知车辆的相关资料</p>
</div> </div>
<div class="tips">服务须知:在发生保险事故后的24小时内向保险公司报案,保留现场并同时通知经销商,并全面告知出险车辆的相关资料</div>
</div> </div>
</div> </div>
</div> </div>
<div <div
class="phone btn" class="phone btn"
@click="makePhoneCall('4008060999')" @click="makePhoneCall('400-6123-886')"
> >
<div class="sprite-icon icon-equity-phone"></div> <div class="icon-equity-phone"><van-icon name="phone-o" class="icon-phone"/>服务热线 400-6123-886</div>
电话咨询
</div> </div>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
export default { export default {
name: 'compensate', name: 'loss',
data () { data () {
return { return {
} }
...@@ -65,13 +56,15 @@ export default { ...@@ -65,13 +56,15 @@ export default {
<style scoped lang='scss'> <style scoped lang='scss'>
.main { .main {
.box { .box {
border: 1px solid #fbdcae; position: absolute;
border-radius: 4px; min-height: 100%;
margin: 30px 26.5px 40px; width: 100%;
background: #2C09A3;
.header { .header {
width: 100%; width: 100%;
height: 100px; height: 250px;
position: relative; background-image: url("~@a/images/equity/pens.png");
background-size: 100% 100%;
> div { > div {
position: absolute; position: absolute;
left: 0; left: 0;
...@@ -92,9 +85,31 @@ export default { ...@@ -92,9 +85,31 @@ export default {
} }
} }
.body { .body {
padding: 24px 30px 20px;
font-size: 12px; font-size: 12px;
color: #333; color: #333;
.type-1-body {
padding: 16px;
box-sizing: border-box;
background: #FFFFFF;
box-shadow: 0 2px 4px 0 rgba(255,255,255,0.50);
border-radius: 8px;
width: 335px;
margin: 10px auto 70px auto;
position: relative;
.title-sign {
position: absolute;
left: 50%;
color: #FFFFFF;
margin-left: -85.5px;
top: -15px;
width: 171px;
height: 30px;
line-height: 30px;
text-align: center;
background-image: url("~@a/images/equity/penstit.png");
background-size: 100% 100%;
}
}
> div { > div {
.title { .title {
font-size: 16px; font-size: 16px;
...@@ -116,20 +131,18 @@ export default { ...@@ -116,20 +131,18 @@ export default {
} }
} }
} }
.content-ul {
width: 220px;
margin: 0 auto;
font-size: 12px;
color: #4C4C4C;
line-height: 20px;
}
.content { .content {
margin: 14px 0 8px; margin: 14px 0 8px;
line-height: 24px; line-height: 18px;
color: #333; font-size: 12px;
ul { color: #4C4C4C;
padding-left: 30px;
}
li {
list-style-type: disc;
}
p {
display: grid;
grid-template-columns: 20px 1fr;
}
.item { .item {
display: grid; display: grid;
grid-template-columns: 30px 1fr; grid-template-columns: 30px 1fr;
...@@ -139,24 +152,35 @@ export default { ...@@ -139,24 +152,35 @@ export default {
} }
} }
.tips { .tips {
color: #666; color: #4C4C4C;
font-size: 12px;
} }
} }
} }
} }
.btn { .btn {
width: 85.9%; position: fixed;
height: 44px; width: 100%;
height: 50px;
bottom: 0px;
background: #FFFFFF;
display: flex; display: flex;
align-items: center;
justify-content: center; justify-content: center;
margin: 40px auto 20px; align-items: center;
font-size: 18px; .icon-equity-phone {
color: #ffffff; margin: 3px auto;
background: #ffc775; background: #008FFF;
border-radius: 10px; color: #FFFFFF;
.sprite-icon { text-align: center;
margin-right: 20px; width: 343px;
height: 44px;
line-height: 44px;
border-radius: 20px;
.icon-phone {
margin-right: 8px;
font-size: 20px;
vertical-align: middle;
}
} }
} }
} }
......
...@@ -31,144 +31,52 @@ ...@@ -31,144 +31,52 @@
<span class="invite_btn">我要分享</span> <span class="invite_btn">我要分享</span>
<p>享推广佣金奖励</p> <p>享推广佣金奖励</p>
</div> </div>
<div class="invite_box openshop_bg" @click="jumpOpenShop"> <!-- <div class="invite_box openshop_bg" @click="jumpOpenShop">-->
<span class="invite_btn" >我要开店</span> <!-- <span class="invite_btn" >我要开店</span>-->
<p>促活拉新轻松享</p> <!-- <p>促活拉新轻松享</p>-->
</div> <!-- </div>-->
</div> </div>
<div class="content"> <div class="content">
<div class="box equity_box"> <div class="box equity_box">
<div class="bar_title"><span>用车权益</span></div> <div class="bar_title"><span>用车权益</span></div>
<div class="car_content"> <div class="car_content">
<div class="items"> <div class="items">
<template v-for="(i,index) in travelList"> <template v-for="(i,index) in carServiceList">
<div <div
class="item" class="item"
:key="index" :key="index"
@click="jumpLink(i)" @click="CarLink(i)"
> >
<div :class="['sprite-icon',`icon-${i.icon}`]"></div> <div class="icon-goods">
<div class="item-name">{{i.name}}</div> <img :src="i.equityIcon" alt="">
<div class="item-des">{{i.description}}</div> </div>
<div class="item-name">{{i.equityName}}</div>
<div class="item-des">{{i.equityDesc}}</div>
</div> </div>
</template> </template>
<div
class="item"
@click="willComeDialog"
>
<div :class="['sprite-icon',`icon-car_charge`]"></div>
<div class="item-name">车辆充电</div>
<div class="item-des">6折起</div>
</div>
<div
class="item"
@click="willComeDialog"
>
<div :class="['sprite-icon',`icon-call_drive`]"></div>
<div class="item-name">叫代驾</div>
<div class="item-des">9折起</div>
</div>
</div> </div>
</div> </div>
</div> </div>
<div class="box equity_box"> <div class="box equity_box">
<div class="bar_title"><span>更多权益</span></div> <div class="bar_title"><span>更多权益</span></div>
<div class="scroll-items"> <div class="scroll-items">
<ul class="tab_list"> <ul class="tab_list" >
<li :class="activeTab==='drink'?'active':''" @click="activeTab='drink'">咖啡饮品</li> <li :class="goodsTab === index?'active':''" @click="goodsTab=index" v-for="(item,index) in goodsServiceKey" :key="index">{{item}}</li>
<li :class="activeTab==='catering'?'active':''" @click="activeTab='catering'">餐饮美食</li>
<li :class="activeTab==='video'?'active':''" @click="activeTab='video'">影音娱乐</li>
<li :class="activeTab==='trip'?'active':''" @click="activeTab='trip'">生活出行</li>
<li :class="activeTab==='read'?'active':''" @click="activeTab='read'">知识阅读</li>
<li :class="activeTab==='health'?'active':''" @click="activeTab='health'">医护健康</li>
</ul> </ul>
</div> </div>
<div class="tab_content" v-show="activeTab==='drink'"> <div class="tab_content">
<div class="items items_5_1">
<template v-for="(i,index) in drinkList">
<div
class="item"
:key="index"
@click="jumpLink(i)"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='catering'">
<div class="items items_5_1"> <div class="items items_5_1">
<template v-for="(i,index) in cateringList"> <template v-for="(i,index) in goodsServiceList[goodsServiceKey[goodsTab]]">
<div <div
class="item" class="item"
:key="index" :key="index"
@click="jumpLink(i)" @click="jumpLink(i)"
> >
<div :class="['sprite-icon',`icon-${i.icon}`]"></div> <div class="icon-goods">
<div class="item-name">{{i.name}}</div> <img :src="i.equityIcon" alt="">
<div class="item-des">{{i.description}}</div> </div>
</div> <div class="item-name">{{i.brandName}}</div>
</template> <div class="item-des">{{i.equityDesc}}</div>
</div>
</div>
<div class="tab_content" v-show="activeTab==='video'">
<div class="items items_5_1">
<template v-for="(i,index) in videoList">
<div
class="item"
:key="index"
@click="jumpLink(i)"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='trip'">
<div class="items items_5_1">
<template v-for="(i,index) in tripList">
<div
class="item"
:key="index"
@click="jumpLink(i)"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='read'">
<div class="items items_5_1">
<template v-for="(i,index) in readList">
<div
class="item"
:key="index"
@click="jumpLink(i)"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div>
</template>
</div>
</div>
<div class="tab_content" v-show="activeTab==='health'">
<div class="items items_5_1">
<template v-for="(i,index) in healthList">
<div
class="item"
:key="index"
@click="jumpLink(i)"
>
<div :class="['sprite-icon',`icon-${i.icon}`]"></div>
<div class="item-name">{{i.name}}</div>
<div class="item-des">{{i.description}}</div>
</div> </div>
</template> </template>
</div> </div>
...@@ -188,6 +96,7 @@ export default { ...@@ -188,6 +96,7 @@ export default {
userInfo: {}, userInfo: {},
icon: require(`@a/images/notice.png`), icon: require(`@a/images/notice.png`),
activeTab: 'drink', activeTab: 'drink',
goodsTab: 0,
inviteUrl: '', inviteUrl: '',
jiangliUrl: '', jiangliUrl: '',
orderCount: 0, orderCount: 0,
...@@ -201,9 +110,11 @@ export default { ...@@ -201,9 +110,11 @@ export default {
this.hideLoading() this.hideLoading()
let { code, data, message } = res let { code, data, message } = res
if (code == 0) { if (code == 0) {
data.time = new Date(data.validitDate).format('yyyy-MM-dd') data.time = new Date(data.validitDate).format('yyyy-MM-dd');
sessionStorage.setItem('CODE_STATUS', 1)
this.userInfo = data this.userInfo = data
} else { } else {
sessionStorage.setItem('CODE_STATUS', 0)
this.showToast(message) this.showToast(message)
} }
}) })
...@@ -228,14 +139,14 @@ export default { ...@@ -228,14 +139,14 @@ export default {
} }
}) })
equity.getOrderCount().then(res => { // equity.getOrderCount().then(res => {
let { code, data, message } = res // let { code, data, message } = res
if (code == 0) { // if (code == 0) {
this.orderCount = data // this.orderCount = data
} else { // } else {
this.showToast(message) // this.showToast(message)
} // }
}) // })
}, },
methods: { methods: {
...@@ -419,6 +330,11 @@ body { ...@@ -419,6 +330,11 @@ body {
.tab_content{ .tab_content{
padding: 10px; padding: 10px;
.icon-goods {
width: 46px;
height: 46px;
margin-bottom: 4px;
}
} }
.content .box { .content .box {
......
...@@ -2,26 +2,28 @@ ...@@ -2,26 +2,28 @@
<div class="main"> <div class="main">
<div class="box"> <div class="box">
<div class="header"> <div class="header">
<div class="sprite-icon icon-equity-bg"></div>
<div class="type-1-header">
道路救援
<div class="sprite-icon icon-equity-type1"></div>
</div>
</div> </div>
<div class="body"> <div class="body">
<div class="type-1-body"> <div class="type-1-body">
<div class="title"> <div class="title-sign">
<span>盗抢全损权益说明</span> 权益说明
</div> </div>
<div class="content"> <div class="content">
服务范围:在正确安装并使用深圳广联赛讯股份有限公司提供的“车载智能终端”产品情况下,签订整车全损无忧合同,赔偿标准包含: 服务范围:在正确安装并使用深圳广联赛讯股份有限公司提供的“车载智能终端”产品情况下,签订整车全损无忧合同,赔偿标准包含:
</div> </div>
<div class="content"> <div class="content-ul">
<ul> <div class="content-li">
<li>车辆折旧费补足</li> <img src="@a/images/equity/car1.png" alt="">
<li>车辆购置税补足</li> <div class="content-desc">车辆折旧费补足</div>
<li>车辆登记费补足</li> </div>
</ul> <div class="content-li">
<img src="@a/images/equity/car2.png" alt="">
<div class="content-desc">车辆购置税补足</div>
</div>
<div class="content-li">
<img src="@a/images/equity/car3.png" alt="">
<div class="content-desc">车辆登记费补足</div>
</div>
</div> </div>
<div class="content"> <div class="content">
服务区域:全国(除港澳台) 服务区域:全国(除港澳台)
...@@ -32,11 +34,9 @@ ...@@ -32,11 +34,9 @@
</div> </div>
<div <div
class="phone btn" class="phone btn"
@click="makePhoneCall('4008060999')" @click="makePhoneCall('400-6123-886')"
> >
<div class="sprite-icon icon-equity-phone"></div> <div class="icon-equity-phone"><van-icon name="phone-o" class="icon-phone"/>服务热线 400-6123-886</div>
电话咨询
</div> </div>
</div> </div>
</template> </template>
...@@ -58,13 +58,15 @@ export default { ...@@ -58,13 +58,15 @@ export default {
<style scoped lang='scss'> <style scoped lang='scss'>
.main { .main {
.box { .box {
border: 1px solid #fbdcae; position: absolute;
border-radius: 4px; min-height: 100%;
margin: 30px 26.5px 40px; width: 100%;
background: #3F87FF;
.header { .header {
width: 100%; width: 100%;
height: 100px; height: 220px;
position: relative; background-image: url("~@a/images/equity/carbg.png");
background-size: 100% 100%;
> div { > div {
position: absolute; position: absolute;
left: 0; left: 0;
...@@ -85,9 +87,31 @@ export default { ...@@ -85,9 +87,31 @@ export default {
} }
} }
.body { .body {
padding: 24px 30px 20px;
font-size: 12px; font-size: 12px;
color: #333; color: #333;
.type-1-body {
padding: 16px;
box-sizing: border-box;
background: #FFFFFF;
box-shadow: 0 2px 4px 0 rgba(255,255,255,0.50);
border-radius: 8px;
width: 335px;
margin: 10px auto 60px auto;
position: relative;
.title-sign {
position: absolute;
left: 50%;
color: #FFFFFF;
margin-left: -85.5px;
top: -15px;
width: 171px;
height: 30px;
line-height: 30px;
text-align: center;
background-image: url("~@a/images/equity/cartit.png");
background-size: 100% 100%;
}
}
> div { > div {
.title { .title {
font-size: 16px; font-size: 16px;
...@@ -109,16 +133,26 @@ export default { ...@@ -109,16 +133,26 @@ export default {
} }
} }
} }
.content-ul {
display: flex;
justify-content: space-around;
font-size: 12px;
color: #EF732C;
margin: 20px 0px;
.content-li {
text-align: center;
line-height: 30px;
img {
width: 60px;
height: 60px;
}
}
}
.content { .content {
margin: 14px 0 8px; margin: 14px 0 8px;
line-height: 24px; line-height: 18px;
color: #333; font-size: 12px;
ul { color: #4C4C4C;
padding-left: 30px;
}
li {
list-style-type: disc;
}
p { p {
display: grid; display: grid;
grid-template-columns: 20px 1fr; grid-template-columns: 20px 1fr;
...@@ -132,24 +166,35 @@ export default { ...@@ -132,24 +166,35 @@ export default {
} }
} }
.tips { .tips {
color: #666; color: #4C4C4C;
font-size: 12px;
} }
} }
} }
} }
.btn { .btn {
width: 85.9%; position: fixed;
height: 44px; width: 100%;
height: 50px;
bottom: 0px;
background: #FFFFFF;
display: flex; display: flex;
align-items: center;
justify-content: center; justify-content: center;
margin: 40px auto 20px; align-items: center;
font-size: 18px; .icon-equity-phone {
color: #ffffff; margin: 3px auto;
background: #ffc775; background: #008FFF;
border-radius: 10px; color: #FFFFFF;
.sprite-icon { text-align: center;
margin-right: 20px; width: 343px;
height: 44px;
line-height: 44px;
border-radius: 20px;
.icon-phone {
margin-right: 8px;
font-size: 20px;
vertical-align: middle;
}
} }
} }
} }
......
...@@ -2,44 +2,39 @@ ...@@ -2,44 +2,39 @@
<div class="main"> <div class="main">
<div class="box"> <div class="box">
<div class="header"> <div class="header">
<div class="sprite-icon icon-equity-bg"></div>
<div class="type-1-header">
道路救援
<div class="sprite-icon icon-equity-type1"></div>
</div>
</div> </div>
<div class="body"> <div class="body">
<div class="type-1-body"> <div class="type-1-body">
<div class="title"> <div class="title-sign">
<span>什么是轮胎保障权益</span> 什么是轮胎保障?
</div> </div>
<div class="content"> <div class="content-ul">
轮胎在正常使用过程中由于非人为因素导致轮胎无法继续使用,对轮胎的合理置换费用进行补偿 <p>轮胎在正常使用过程中由于非人为因素导致轮胎无法继续使用,对轮胎的合理置换费用进行补偿。</p>
</div> </div>
<div class="title"> </div>
<span>补偿标准</span> <div class="type-1-body">
<div class="title-sign">
补偿标准
</div> </div>
<div class="content"> <div class="content-ul">
<p>1、<span>自新车购买之日起一年内补偿轮胎销售价格的100%;</span></p> <p>1、自新车购买之日起一年内补偿轮胎销售价格的100%。</p>
<p>2、<span>每条轮胎限补偿一次,每辆车最多申请两次补偿,单车最高补偿限额为5000元。</span></p> <p>2、每条轮胎限补偿一次,每辆车最多申请两次补偿,单车最高补偿限额为5000元。</p>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<div <div
class="phone btn" class="phone btn"
@click="makePhoneCall('4008060999')" @click="makePhoneCall('400-6123-886')"
> >
<div class="sprite-icon icon-equity-phone"></div> <div class="icon-equity-phone"><van-icon name="phone-o" class="icon-phone"/>服务热线 400-6123-886</div>
电话咨询
</div> </div>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
export default { export default {
name: 'tyre', name: 'loss',
data () { data () {
return { return {
} }
...@@ -54,13 +49,15 @@ export default { ...@@ -54,13 +49,15 @@ export default {
<style scoped lang='scss'> <style scoped lang='scss'>
.main { .main {
.box { .box {
border: 1px solid #fbdcae; position: absolute;
border-radius: 4px; min-height: 100%;
margin: 30px 26.5px 40px; width: 100%;
background: #FF862C;
.header { .header {
width: 100%; width: 100%;
height: 100px; height: 250px;
position: relative; background-image: url("~@a/images/equity/tyre.png");
background-size: 100% 100%;
> div { > div {
position: absolute; position: absolute;
left: 0; left: 0;
...@@ -81,9 +78,32 @@ export default { ...@@ -81,9 +78,32 @@ export default {
} }
} }
.body { .body {
padding: 24px 30px 20px;
font-size: 12px; font-size: 12px;
color: #333; color: #333;
margin: 10px 0px 50px 0px;
.type-1-body {
padding: 16px;
box-sizing: border-box;
background: #FFFFFF;
box-shadow: 0 2px 4px 0 rgba(255,255,255,0.50);
border-radius: 8px;
width: 335px;
margin: 30px auto;
position: relative;
.title-sign {
position: absolute;
left: 50%;
color: #FFFFFF;
margin-left: -85.5px;
top: -15px;
width: 171px;
height: 30px;
line-height: 30px;
text-align: center;
background-image: url("~@a/images/equity/tyretit.png");
background-size: 100% 100%;
}
}
> div { > div {
.title { .title {
font-size: 16px; font-size: 16px;
...@@ -105,10 +125,18 @@ export default { ...@@ -105,10 +125,18 @@ export default {
} }
} }
} }
.content-ul {
font-size: 12px;
color: #4C4C4C;
p {
margin-top: 20px;
}
}
.content { .content {
margin: 14px 0 8px; margin: 14px 0 8px;
line-height: 24px; line-height: 18px;
color: #333; font-size: 12px;
color: #4C4C4C;
p { p {
display: grid; display: grid;
grid-template-columns: 20px 1fr; grid-template-columns: 20px 1fr;
...@@ -122,24 +150,35 @@ export default { ...@@ -122,24 +150,35 @@ export default {
} }
} }
.tips { .tips {
color: #666; color: #4C4C4C;
font-size: 12px;
} }
} }
} }
} }
.btn { .btn {
width: 85.9%; position: fixed;
height: 44px; width: 100%;
height: 50px;
bottom: 0px;
background: #FFFFFF;
display: flex; display: flex;
align-items: center;
justify-content: center; justify-content: center;
margin: 40px auto 20px; align-items: center;
font-size: 18px; .icon-equity-phone {
color: #ffffff; margin: 3px auto;
background: #ffc775; background: #008FFF;
border-radius: 10px; color: #FFFFFF;
.sprite-icon { text-align: center;
margin-right: 20px; width: 343px;
height: 44px;
line-height: 44px;
border-radius: 20px;
.icon-phone {
margin-right: 8px;
font-size: 20px;
vertical-align: middle;
}
} }
} }
} }
......
...@@ -2,30 +2,30 @@ ...@@ -2,30 +2,30 @@
<div class="main"> <div class="main">
<div class="box"> <div class="box">
<div class="de-header"> <div class="de-header">
<img src="data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAAQABAAD/2wBDAAUDBAQEAwUEBAQFBQUGBwwIBwcHBw8LCwkMEQ8SEhEPERETFhwXExQaFRERGCEYGh0dHx8fExciJCIeJBweHx7/2wBDAQUFBQcGBw4ICA4eFBEUHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh7/wAARCABLAEsDASIAAhEBAxEB/8QAGgAAAwADAQAAAAAAAAAAAAAAAwQFAAIGAf/EADUQAAIBAwIDBQUGBwAAAAAAAAECAwAEEQUhEjFRBhMyQXEUImGBwQcjUnOhsRYzQmJygpL/xAAaAQADAAMBAAAAAAAAAAAAAAACAwQAAQYF/8QAKxEAAgEDAgMGBwAAAAAAAAAAAQIAAwQREiEFMUETMlGRwfAUImFxgaGx/9oADAMBAAIRAxEAPwDrIYCwG1OwQFRyreCMYp2JfdwaW9SQUqIECkIbyrHgydqaWPBooQCkl5ToBkx4WTlXiOy881VMHH5Vr7IB4hWdoIJonpEBIehrYStnlVCOzUjOAPWltZ1Ls5aXWnadHPdNeX5xbs0REc3UqcYIHrQ9oNQUDMatBypboJqZPdoRcZorREHFD7o0QxA3nluuMU6iZxSMbFTyNULd84oXm0xymxQqKyMEnGKPwkiiQx75NKLbRwXeeIp22ovd7b0dEHStuEGklo0LBWdv393FAOTsAfTzo/bZbUXmlxNFEXhLtACo+7wmCV6bHHzpzQYs6irgeBSfpXPdopZLr7Ru64wYLTSyxXH9ckuAf+YzSQS1cfQSlQFoMcc4NwDuKAU3puVOHOKWbmedWgzz2GJ7DEvLAppIx5LU9dQsIz793CPgHBP6U3Fqlqw+5S4m/LgY/SsZX8Ipbm3G2seeY4qgDGKOiYFIrd3Ln7vTLojq5RB+po4fU28NraxD++Ysf0H1pRU9T+4wXKnugn8H1AjQ2rOMdKW7nUX8d5bx/lwE/uaPa2jpdC3NxJcztgNxhVSP0A5n1oCABzlVqla5fSqEDqSRgeRMs9nQCZ5McsD61zzLa/xTq17JEzu6xRAq2x4OLY9MFjy55rr4IPY7N0LcZyST8q42VnlBKEglzJgeZJqWkdVVj797TobKyp1AVfcCPyoiqjTW8Co/IBT+/OlpdPtmcss5jB3CleLHz86ralCy9n4rtiGAYEfAVIt5UaBGJG486oUtzEcbKhcJnTyONpEtika4jRE/xUD9qetZWJ94k0NLdQAQKKmAcVWxBnHopEfiY4o6nNLxchR06VIZSIQHBB6Gp63zWOuTCT8ZZSfMHcU+Kl6xa96MyBgiglJUHEY/gwG5X4jcVigE4M9vg9xSp1ClXk0Yvu0ms3t5JpNlokkUBA4tSedeDB58KeInmKq6BpInuBx7RqMn0rieLUbRO/jImgPKSNuND8xTth2juBbyQITxuMbURoYHyTozw5lpH4dhg9Z0PbTVFvbyLSrIgxpscHYmuAm7Q9p55Wk7O6FYXml54be4mnKNKBsWA/CSCR1GDR9RD30zaDayN3kyB9TnU/yYG5Rg+TybjqE4j5iqi2/dqscaKiIAqqowFA2AHwqmki013Gfv/ffrOa4pe9hptrY7LzPiZQEZ4dq9SE8WTRkoyAbbVOXM8XSJpGpzRQDWygVtQEwgJgrCaxuVDNam4pcadbSytMne207c5beQxufXGzf7A1PutN1dQWtrzTZ5QPclu7LDqfIkxkBvQqM1aBNe+VGHIjqVzWpdxiJK0XSYdKsvZ0d5pXcy3E8mOOeVvE7fE9OQAAGwpooOlMPQSd62WLHJk8//2Q=="> <img :src="detailInfo.gasLogoBig" alt="">
</div> </div>
<div class="box-detail"> <div class="box-detail">
<div class="de-desc"> <div class="de-desc">
<div class="de-desc-title">中国海油协和升山加油站</div> <div class="de-desc-title">{{ detailInfo.gasName }}</div>
<div class="de-desc-price"> <div class="de-desc-price">
<span>¥6.57/升</span> <span>¥{{detailInfo.priceYfq}}/升</span>
<span class="line-through">国标价¥6.78</span> <span class="line-through">国标价¥{{ detailInfo.priceOfficial }}</span>
<span>每升优惠0.21元</span> <span>每升优惠{{ detailInfo.priceReduced }}元</span>
</div> </div>
<div class="de-desc-select">站内开票</div> <div class="de-desc-select" v-if="detailInfo.isInvoice">站内开票</div>
<div class="de-desc-localtion"> <div class="de-desc-localtion">
<div>南山区西丽留仙大道北侧中段</div> <div>{{ detailInfo.gasAddress }}</div>
<div><img src="@a/images/navigation.png" alt="">距离10cm</div> <div @click="openLocation(detailInfo)"><img src="@a/images/navigation.png" alt="">距离{{detailInfo.distance}}cm</div>
</div> </div>
</div> </div>
<div class="de-select"> <div class="de-select">
<div class="select-item-title">选择油号</div> <div class="select-item-title">选择油号</div>
<div class="select-item-panel"> <div class="select-item-panel">
<div class="select-item" :class="{'checked':oilSnoi == key}" v-for="(item,key) in oilSno" :key="key" @click="changeOilSno(key)">{{item}}</div> <div class="select-item" :class="{'checked':oilSnoi == item.oilNo}" v-for="(item,index) in equityOilNoDTOList" :key="index" @click="changeOilSno(item.oilNo)">{{item.oilName}}</div>
</div> </div>
<div class="select-item-title">选择油枪</div> <div class="select-item-title">选择油枪</div>
<div class="select-item-panel"> <div class="select-item-panel">
<div class="select-item" :class="{'checked':oilSuni == key}" v-for="(item,key) in oilGun" :key="key" @click="changeOilSun(key)">{{item}}</div> <div class="select-item" :class="{'checked':oilSuni == item}" v-for="(item,index) in gunNos" :key="index" @click="changeOilSun(item)">{{item}}</div>
</div> </div>
</div> </div>
<div class="de-explain"> <div class="de-explain">
...@@ -35,29 +35,88 @@ ...@@ -35,29 +35,88 @@
</div> </div>
</div> </div>
<div class="de-btn-p"> <div class="de-btn-p">
<div class="de-btn">下一步</div> <div class="de-btn" @click="oilPay">下一步</div>
</div> </div>
</div> </div>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
import WxConfig from "@u/WxConfig";
import {oilStation} from "@r/api";
const WX = new WxConfig([ 'openLocation'])
export default { export default {
name: "detail", name: "detail",
data() { data() {
return { return {
oilSnoi: 0, oilSnoi: '',
oilSuni: 0, oilSuni: '',
oilSno: ['0#','92#','95#','98#'], detailInfo: {},
oilGun: ['1号','5号','9号','11号'] gunNos: [],
equityOilNoDTOList: [],
phone: JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO')).phone
} }
}, },
mounted() {
this.showLoading()
let {oilId,oilNo,longitude,latitude} = this.$route.query
let para = {
oilId,
oilNo,
phone: this.phone,
longitude,
latitude,
}
oilStation.getStationDetail(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.detailInfo = data;
this.gunNos = data.gunNos;
this.equityOilNoDTOList = data.equityOilNoDTOList;
} else {
this.showToast(message)
}
})
},
methods: { methods: {
openLocation(val) {
WX.openLocation(val.gasAddressLatitude,val.gasAddressLongitude,val.gasName,val.gasAddress,18).then(res => {
console.log(res)
})
},
changeOilSno(item) { changeOilSno(item) {
this.oilSnoi = item; this.oilSnoi = item;
}, },
changeOilSun(item) { changeOilSun(item) {
this.oilSuni = item; this.oilSuni = item;
},
oilPay() {
let {oilId} = this.$route.query
if (!this.oilSnoi) {
this.showToast('请选择油号')
return
}
if (!this.oilSuni) {
this.showToast('请选择油枪')
return
}
let para = {
oilId,
oilNo: this.oilSnoi,
phone: this.phone,
gunNo: this.oilSuni,
}
this.showLoading();
oilStation.getStationPayUrl(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.openWindows(data.url)
} else {
this.showToast(message)
}
})
} }
} }
} }
...@@ -80,7 +139,7 @@ export default { ...@@ -80,7 +139,7 @@ export default {
} }
.box-detail { .box-detail {
position: absolute; position: absolute;
top: 120px; top: 105px;
padding: 15px; padding: 15px;
} }
.de-desc { .de-desc {
......
...@@ -21,19 +21,19 @@ ...@@ -21,19 +21,19 @@
<div class="location-now-h"> <div class="location-now-h">
<div class="location-now-h1">当前定位<van-icon name="location" class="location-icon"/></div> <div class="location-now-h1">当前定位<van-icon name="location" class="location-icon"/></div>
<div class="location-now-h2"> <div class="location-now-h2">
<div class="location-now-address">世界之窗</div> <div class="location-now-address">{{addressInfo.address}}</div>
<div class="location-now-refresh" @click="handleLocation"><img src="@a/images/repositioning.png" alt="">重新定位</div> <div class="location-now-refresh" @click="handleLocation"><img src="@a/images/repositioning.png" alt="">重新定位</div>
</div> </div>
</div> </div>
<div class="location-history"> <div class="location-history">
<div class="location-history-t"> <div class="location-history-t" v-if="hisList.length>0">
<span>最近三个月搜索过</span> <span>最近三个月搜索过</span>
<span>清空</span> <span @click="clearEmpty">清空</span>
</div> </div>
<div class="location-history-list"> <div class="location-history-list">
<div class="location-history-item" v-for="(item,index) in hisList" :key="index"> <div class="location-history-item" v-for="(item,index) in hisList" :key="index">
<div class="history-list-icon">asdfsd</div> <div class="history-list-icon text-hide">{{ item.address }}</div>
<div class="history-list-clear"><van-icon name="cross" /></div> <div class="history-list-clear"><van-icon name="cross" @click="delHistory(item.id)"/></div>
</div> </div>
</div> </div>
</div> </div>
...@@ -46,6 +46,7 @@ ...@@ -46,6 +46,7 @@
import mapSearch from './map-search' import mapSearch from './map-search'
import AMap from 'AMap'; import AMap from 'AMap';
import WxConfig from '@u/WxConfig' import WxConfig from '@u/WxConfig'
import {oilStation} from "@r/api";
const WX = new WxConfig(['scanQRCode', 'chooseImage', 'getLocation']); const WX = new WxConfig(['scanQRCode', 'chooseImage', 'getLocation']);
export default { export default {
name: "location", name: "location",
...@@ -53,8 +54,9 @@ export default { ...@@ -53,8 +54,9 @@ export default {
return { return {
input: '', input: '',
localStatus: true, localStatus: true,
refresh: false, hisList: [1,2,3],
hisList: [1,2,3] addressInfo: {},
phone: JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO')).phone
} }
}, },
components: { components: {
...@@ -62,7 +64,7 @@ export default { ...@@ -62,7 +64,7 @@ export default {
}, },
watch: { watch: {
input(newValue, oldValue) { input(newValue, oldValue) {
if (newValue !== oldValue) { if (newValue.trim() && newValue !== oldValue) {
this.ms = 1000; this.ms = 1000;
clearTimeout(this.timeID); clearTimeout(this.timeID);
this.timeID = setTimeout(() => { this.timeID = setTimeout(() => {
...@@ -72,30 +74,75 @@ export default { ...@@ -72,30 +74,75 @@ export default {
} }
}, },
mounted() { mounted() {
this.getRecord();
this.addressInfo.address = this.$route.query.address;
}, },
methods: { methods: {
getRecord() {
let para = {
phone: this.phone
}
oilStation.getStationSearchList(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.hisList = data;
} else {
this.showToast(message)
}
})
},
clearEmpty() {
let para = {
phone: this.phone
}
oilStation.getStationSearchDeleteAll(para).then(res => {
this.hideLoading()
let { code, message } = res
if (code == 0) {
this.getRecord();
} else {
this.showToast(message)
}
})
},
delHistory(index) {
let para = {
id: index
}
oilStation.getStationSearchDelete(para).then(res => {
this.hideLoading()
let { code, message } = res
if (code == 0) {
this.getRecord();
} else {
this.showToast(message)
}
})
},
//重新定位 //重新定位
handleLocation() { handleLocation() {
if(!this.refresh) { this.getLocation();
this.getLocation();
this.refresh = true;
setTimeout(()=>{
this.refresh = false;
},1000)
}
}, },
// handleLocation: Vue.prototype.throttle(function (){
// this.refresh = true;
// this.getLocation();
// },2000),
getLocation(){ getLocation(){
this.showLoading();
WX.getLocation().then(res => { WX.getLocation().then(res => {
console.log(res)
AMap.plugin('AMap.Geocoder', () => { AMap.plugin('AMap.Geocoder', () => {
const geocoder = new AMap.Geocoder() const geocoder = new AMap.Geocoder()
let {longitude, latitude} = res let { longitude, latitude } = res
let lnglat = [longitude, latitude] let lnglat = [longitude, latitude];
geocoder.getAddress(lnglat, (status, result) => { geocoder.getAddress(lnglat, (status, result) => {
console.log(status, result) this.hideLoading();
let { info, regeocode: { formattedAddress } } = result
if (status === 'complete' && info === 'OK') {
// result为对应的地理位置详细信息
this.addressInfo = {
longitude,
latitude,
address: formattedAddress
}
}
}) })
}) })
}) })
...@@ -108,7 +155,26 @@ export default { ...@@ -108,7 +155,26 @@ export default {
this.$refs.maps.onSearch(); this.$refs.maps.onSearch();
}, },
selectLocation(value) { selectLocation(value) {
window.vm.$router.push({ path: '/oilStation/index',query:{location:JSON.stringify(value)}}) let para = {
phone: this.phone,
address: value.address,
longitude: value.location.lng,
latitude: value.location.lat,
}
oilStation.getStationSearchInsert(para).then(res => {
this.hideLoading()
let { code, message } = res
if (code == 0) {
window.vm.$router.push({ path: '/oilStation/index',query:{
longitude: value.location.lng,
latitude: value.location.lat,
}
})
} else {
this.showToast(message)
}
})
} }
} }
} }
...@@ -122,9 +188,11 @@ export default { ...@@ -122,9 +188,11 @@ export default {
} }
.location-result { .location-result {
padding: 0 15px; padding: 0 15px;
background: #FFFFFF;
.location-now-h { .location-now-h {
line-height: 30px; line-height: 30px;
margin-bottom: 30px; padding-bottom: 15px;
border-bottom: 1px solid #D8D8D8;
.location-now-h1 { .location-now-h1 {
font-size: 14px; font-size: 14px;
color: #666666; color: #666666;
...@@ -141,18 +209,28 @@ export default { ...@@ -141,18 +209,28 @@ export default {
align-items: center; align-items: center;
font-size: 14px; font-size: 14px;
color: #333333; color: #333333;
.location-now-address {
line-height: 18px;
flex: 1;
}
.location-now-refresh { .location-now-refresh {
font-size: 10px; font-size: 10px;
color: #008FFF; color: #008FFF;
width: 70px;
text-align: right;
line-height: 29px;
} }
img { img {
width: 15px; width: 15px;
height: 15px; height: 15px;
vertical-align: text-top; vertical-align: middle;
margin-right: 3px; margin-right: 3px;
} }
} }
} }
.location-history {
padding: 15px 0px;
}
.location-history-t { .location-history-t {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
...@@ -160,14 +238,14 @@ export default { ...@@ -160,14 +238,14 @@ export default {
color: #333333; color: #333333;
} }
.location-history-list { .location-history-list {
margin-top: 30px; margin-top: 10px;
.location-history-item { .location-history-item {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
line-height: 24px; line-height: 24px;
height: 24px; height: 24px;
margin-bottom: 10px; margin-top: 10px;
.history-list-icon { .history-list-icon {
padding-left: 30px; padding-left: 30px;
} }
......
...@@ -4,7 +4,8 @@ ...@@ -4,7 +4,8 @@
<div class="location-history-list" > <div class="location-history-list" >
<div class="history-list-icon"><van-icon name="location-o" class="localtion-icon"/></div> <div class="history-list-icon"><van-icon name="location-o" class="localtion-icon"/></div>
<div class="list-address"> <div class="list-address">
<div class="list-address-n">{{item.name}}</div> <div class="list-address-n" v-if="item.nameArr.length > 1">{{item.nameArr[0]}}<span>{{item.nameArr[1]}}</span>{{item.nameArr[2]}}</div>
<div class="list-address-n" v-if="item.nameArr.length == 1">{{item.nameArr[0]}}</div>
<div class="list-address-d">{{item.address}}</div> <div class="list-address-d">{{item.address}}</div>
</div> </div>
</div> </div>
...@@ -58,7 +59,18 @@ export default { ...@@ -58,7 +59,18 @@ export default {
_this.hideLoading(); _this.hideLoading();
if(status == 'complete') { if(status == 'complete') {
let poiList = result.poiList.pois; let poiList = result.poiList.pois;
console.log(result)
_this.localList = _this.localList.concat(poiList); _this.localList = _this.localList.concat(poiList);
_this.localList = _this.localList.map((item)=>{
let idx = item.name.indexOf(_this.keyword);
let length = _this.keyword.length;
return {
nameArr: idx == -1 ? [item.name] : [item.name.substring(0,idx),_this.keyword,item.name.substring(idx+length)],
name: item.name,
address: item.address,
location: item.location
}
})
} }
if(status != 'complete' && _this.pageIndex == 1) { if(status != 'complete' && _this.pageIndex == 1) {
_this.localList = []; _this.localList = [];
...@@ -92,6 +104,9 @@ export default { ...@@ -92,6 +104,9 @@ export default {
line-height: 24px; line-height: 24px;
font-size: 14px; font-size: 14px;
color: #151515; color: #151515;
>span {
color: #FE6000;
}
} }
&-d { &-d {
font-size: 12px; font-size: 12px;
......
<template> <template>
<div class="main"> <div class="main">
<div class="oil-panel"> <div class="oil-panel" v-if="oilList.length>0">
<div class="oil-item" :class="{'refund-status': index==2}" v-for="(item,index) in oilList" :key="index"> <div class="oil-item" :class="{'refund-status': index==2}" v-for="(item,index) in oilList" :key="index">
<div class="item-title"> <div class="item-title">
<div class="item-title-time">2020-11-20 10:50:06</div> <div class="item-title-time">{{ item.orderTime }}</div>
<div class="item-title-status" style="color: #248B20;">已支付</div> <template v-for="(i,key) in orderStatus">
<span :class="`color-${key}`" v-if="i.name == item.orderStatusName" :key="key">{{ i.name }}</span>
</template>
</div> </div>
<div class="item-desc"> <div class="item-desc">
<div class="item-desc-detail"> <div class="item-desc-detail">
<div class="item-desc-name">中国海油协和升山加油站</div> <div class="item-desc-name">{{ item.gasName }}</div>
<div class="item-desc-total"> <div class="item-desc-total">
<span>加油金额:200元</span> <span>加油金额:{{ item.amountPay }}元</span>
<span>实付100</span> <span>实付{{ item.amountGun }}</span>
</div> </div>
<div class="item-desc-number"> <div class="item-desc-number">
<div> <div>
<span>36.23升</span> <span>{{ item.litre }}升</span>
<span>92#</span> <span>{{ item.oilNo }}</span>
</div> </div>
<span>优惠10.2元</span> <span>优惠{{ item.amountDiscounts }}元</span>
</div> </div>
</div> </div>
</div> </div>
<div class="item-order">订单号:23948</div> <div class="item-order">订单号:{{ item.orderId }}</div>
</div> </div>
</div> </div>
<van-empty description="无数据" v-else/>
</div> </div>
</template> </template>
<script type='text/ecmascript-6'> <script type='text/ecmascript-6'>
import {oilStation} from "@r/api";
const orderStatus = [{
value: 0,
name: '已支付',
},{
value: 4,
name: '退款申请中'
},{
value: 5,
name: '已退款'
},{
value: 6,
name: '退款失败'
}]
export default { export default {
name: "record", name: "record",
data() { data() {
return { return {
oilList: [1,2,1,1,] oilList: [],
orderStatus,
phone: JSON.parse(sessionStorage.getItem('GL_EQUITY_USER_INFO')).phone
} }
}, },
mounted() {
this.getStationRecord();
},
methods: {
getStationRecord() {
this.showLoading();
let para = {
phone: this.phone
}
oilStation.getStationOrderList(para).then(res => {
this.hideLoading()
let { code, data, message } = res
if (code == 0) {
this.oilList = data;
} else {
this.showToast(message)
}
})
},
}
} }
</script> </script>
<style scoped lang='scss'> <style scoped lang='scss'>
.color-1 {
color: #248B20;
}
.color-1 {
color: #008FFF;
}
.color-1 {
color: #F30016;
}
.color-1 {
color: #999999;
}
.main{ .main{
.oil-panel { .oil-panel {
background: #f2f2f2; background: #f2f2f2;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!