1.对接银联2.0 新页面 接口

master
杨杰 2 years ago
parent 07fef7a563
commit d3a0e2503c
  1. 1
      .gitignore
  2. 4
      high-unionPay/App.vue
  3. 108
      high-unionPay/Utils/Api.js
  4. 61
      high-unionPay/member-Recharge/rec-confirmation/rec-confirmation.vue
  5. 30
      high-unionPay/node_modules/jweixin-module/README.md
  6. 1
      high-unionPay/node_modules/jweixin-module/lib/index.js
  7. 54
      high-unionPay/node_modules/jweixin-module/package.json
  8. 80
      high-unionPay/node_modules/vue-jsonp/package.json
  9. 250
      high-unionPay/package-lock.json
  10. 4
      high-unionPay/package.json
  11. 2
      high-unionPay/pages/goods/goods.vue
  12. 21
      high-unionPay/pages/goods/refuel-confirm/refuel-confirm.vue
  13. 503
      high-unionPay/pages/order/confirmation.vue
  14. 3
      high-unionPay/pages/qianZhuPay/qianZhuPay.vue
  15. 339
      high-unionPay/pages/tabBar/home/home.vue
  16. 116
      high-unionPay/pages/tabBar/user/user.vue
  17. 50
      high-unionPay/pages/unionPay/unionComfirmation/unionComfirmation.vue
  18. 3
      high-unionPay/pages/user/deposit/deposit.vue
  19. 100
      high-unionPay/pages/user/news/news.vue
  20. 155
      high-unionPay/pages/user/order_details/order_details.vue
  21. 159
      high-unionPay/pages/user/order_list/order_list.vue
  22. 129
      high-unionPay/qianzhu-KFC/confirmOrder/confirmOrder.vue
  23. 108
      high-unionPay/qianzhu-KFC/order-details/order-details.vue
  24. 3
      high-unionPay/qianzhu-KFC/payment-method/payment-method.vue
  25. BIN
      high-unionPay/static/img/user/kefu.png
  26. BIN
      high-unionPay/static/img/user/notive.png
  27. BIN
      high-unionPay/static/img/user/order.png
  28. BIN
      high-unionPay/static/img/user/overdue.png
  29. BIN
      high-unionPay/static/img/user/use.png
  30. 76
      high-unionPay/subPages/coupon-comfirmation/coupon-comfirmation.vue

1
.gitignore vendored

@ -1 +1,2 @@
unpackage/ unpackage/
node_modules

@ -7,6 +7,8 @@
// //
// url: 'https://hsg.dctpay.com/crest', // url: 'https://hsg.dctpay.com/crest',
// v1url:'https://hsg.dctpay.com/v1', // v1url:'https://hsg.dctpay.com/v1',
// orderurl:' https://hsg.dctpay.com/order',
// userurl:'https://hsg.dctpay.com/user',
// imgUrl: 'https://hsg.dctpay.com/filesystem/', // imgUrl: 'https://hsg.dctpay.com/filesystem/',
// brestUrl: 'https://hsg.dctpay.com/brest', // brestUrl: 'https://hsg.dctpay.com/brest',
// imageWxImg: 'https://hsg.dctpay.com/filesystem/wxApplets/', // imageWxImg: 'https://hsg.dctpay.com/filesystem/wxApplets/',
@ -14,6 +16,8 @@
// //
url: 'https://hsgcs.dctpay.com/crest', url: 'https://hsgcs.dctpay.com/crest',
v1url: 'https://hsgcs.dctpay.com/v1', v1url: 'https://hsgcs.dctpay.com/v1',
orderurl:'https://hsgcs.dctpay.com/order',
userurl:'https://hsgcs.dctpay.com/user',
brestUrl: 'https://hsgcs.dctpay.com/brest', brestUrl: 'https://hsgcs.dctpay.com/brest',
imgUrl: 'https://hsgcs.dctpay.com/filesystem/', imgUrl: 'https://hsgcs.dctpay.com/filesystem/',
imageWxImg: 'https://hsgcs.dctpay.com/filesystem/wxApplets/', imageWxImg: 'https://hsgcs.dctpay.com/filesystem/wxApplets/',

@ -5,6 +5,8 @@ import {
POSTBREST} from "./bRequest.js"; POSTBREST} from "./bRequest.js";
let app = getApp(); let app = getApp();
let base = app.globalData.url; let base = app.globalData.url;
let orderbase = app.globalData.orderurl;
let userbase = app.globalData.userurl;
let v1base = app.globalData.v1url; let v1base = app.globalData.v1url;
let brestBase = app.globalData.brestUrl; let brestBase = app.globalData.brestUrl;
//公众号获取跳小程序参数 //公众号获取跳小程序参数
@ -26,10 +28,6 @@ export const HandleCode = params => {
export const GetPhoneNumber = params => { export const GetPhoneNumber = params => {
return POST('GET', `${base}/wechat/getPhoneNumber`, params).then(res => res.data); return POST('GET', `${base}/wechat/getPhoneNumber`, params).then(res => res.data);
}; };
//银联手机号登录
export const unionPhoneLogin = params => {
return POST('GET', `${base}/user/unionPhoneLogin`, params).then(res => res.data);
};
//获取用户授权信息 //获取用户授权信息
export const getUserInfo = params => { export const getUserInfo = params => {
return POST('GET', `${base}/wechat/getUserInfo`, params).then(res => res.data); return POST('GET', `${base}/wechat/getUserInfo`, params).then(res => res.data);
@ -47,10 +45,6 @@ export const updateUserPayPwd = params => {
return POST('POST', `${base}/highUser/updateUserPayPwd`, params).then(res => res.data); return POST('POST', `${base}/highUser/updateUserPayPwd`, params).then(res => res.data);
} }
//获取用户信息
export const findUser = params => {
return POST('GET', `${base}/highUser/findUser`, params).then(res => res.data);
}
//微信登录 //微信登录
export const WXlogin = params => { export const WXlogin = params => {
return POST('GET', `${base}/wechat/login`, params).then(res => res.data); return POST('GET', `${base}/wechat/login`, params).then(res => res.data);
@ -131,23 +125,12 @@ export const getUserCouponDetail = params => {
export const getUserNewCouponDetail = params => { export const getUserNewCouponDetail = params => {
return POST('GET', `${base}/coupon/getUserNewCouponDetail`, params).then(res => res.data); return POST('GET', `${base}/coupon/getUserNewCouponDetail`, params).then(res => res.data);
} }
//获取订单信息
export const getUserOrderList = params => {
return POST('GET', `${base}/highOrder/getUserOrderList`, params).then(res => res.data);
}
//取消订单
export const cancelOrder = params => {
return POST('GET', `${base}/highOrder/cancelOrder`, params).then(res => res.data);
}
//订单查询详情 //订单查询详情
export const getOrderById = params => { export const getOrderById = params => {
return POST('GET', `${base}/highOrder/getOrderById`, params).then(res => res.data); return POST('GET', `${base}/highOrder/getOrderById`, params).then(res => res.data);
} }
//已完成未查看
export const orderCheck = params => {
return POST('GET', `${base}/highOrder/orderCheck`, params).then(res => res.data);
}
//获取商户列表 //获取商户列表
export const getMerchantList = params => { export const getMerchantList = params => {
return POST('GET', `${base}/highMerchantStore/getMerchantList`, params).then(res => res.data); return POST('GET', `${base}/highMerchantStore/getMerchantList`, params).then(res => res.data);
@ -176,10 +159,6 @@ export const getCouponByDiscount = params => {
export const againReceiveCoupon = params => { export const againReceiveCoupon = params => {
return POST('GET', `${base}/coupon/againReceiveCoupon`, params).then(res => res.data); return POST('GET', `${base}/coupon/againReceiveCoupon`, params).then(res => res.data);
} }
//查询我的优惠券
export const getUserDiscountList = params => {
return POST('GET', `${base}/userDiscount/getUserDiscountList`, params).then(res => res.data);
}
//我的优惠券查详情 //我的优惠券查详情
export const getDiscountByUserDiscountId = params => { export const getDiscountByUserDiscountId = params => {
return POST('GET', `${base}/userDiscount/getDiscountByUserDiscountId`, params).then(res => res.data); return POST('GET', `${base}/userDiscount/getDiscountByUserDiscountId`, params).then(res => res.data);
@ -247,10 +226,6 @@ export const getPhoneOrderById = params => {
export const cancelRechargeOrder = params => { export const cancelRechargeOrder = params => {
return POST('GET', `${base}/outRechargeOrder/cancelOrder`, params).then(res => res.data); return POST('GET', `${base}/outRechargeOrder/cancelOrder`, params).then(res => res.data);
} }
//银联提交订单
export const unionPay = params => {
return POST('POST', `${base}/order/unionPay`, params).then(res => res.data);
}
// 银联话费充值 // 银联话费充值
export const orderToUnionPay = params => { export const orderToUnionPay = params => {
return POST('POST', `${base}/czOrder/orderToUnionPay`, params).then(res => res.data); return POST('POST', `${base}/czOrder/orderToUnionPay`, params).then(res => res.data);
@ -315,10 +290,6 @@ export const getHuiLianTongCardBalance = params => {
export const getHuiLianTongCardConsume = params => { export const getHuiLianTongCardConsume = params => {
return POST('GET', `${base}/highUserCard/getHuiLianTongCardConsume`, params).then(res => res.data); return POST('GET', `${base}/highUserCard/getHuiLianTongCardConsume`, params).then(res => res.data);
} }
// 汇联通工会卡支付
export const hltUnionCardPay = params => {
return POST('POST', `${base}/order/hltUnionCardPay`, params).then(res => res.data);
}
export const czhltUnionCardPay = params => { export const czhltUnionCardPay = params => {
return POST('POST', `${base}/thirdOrder/hltUnionCardPay`, params).then(res => res.data); return POST('POST', `${base}/thirdOrder/hltUnionCardPay`, params).then(res => res.data);
} }
@ -373,14 +344,7 @@ export const getKfcStoresList = params => {
export const listByStoreCode = params => { export const listByStoreCode = params => {
return POST('GET', `${base}/highThirdParty/listByStoreCode`, params).then(res => res.data); return POST('GET', `${base}/highThirdParty/listByStoreCode`, params).then(res => res.data);
} }
//肯德基订单详情
export const getThirdOrderByOrderId = params => {
return POST('GET', `${base}/highThirdParty/getThirdOrderByOrderId`, params).then(res => res.data);
}
//肯德基,星巴克取消订单
export const thirdCancelOrder = params => {
return POST('GET', `${base}/highThirdParty/thirdCancelOrder`, params).then(res => res.data);
}
//肯德基银联支付 //肯德基银联支付
export const qianzhuorderToUnionPay = params => { export const qianzhuorderToUnionPay = params => {
return POST('POST', `${base}/thirdOrder/orderToUnionPay`, params).then(res => res.data); return POST('POST', `${base}/thirdOrder/orderToUnionPay`, params).then(res => res.data);
@ -527,3 +491,67 @@ export const getUserOrderListhuafei = params => {
export const getRebateIntegral = params => { export const getRebateIntegral = params => {
return POST('POST', `${base}/common/getRebateIntegral`, params).then(res => res.data); return POST('POST', `${base}/common/getRebateIntegral`, params).then(res => res.data);
} }
//站内信列表
export const queryMsgByList = params => {
return POST('GET', `${base}/bsMsg/queryMsgByList`, params).then(res => res.data);
}
// -----------订单新接口------------
//新建订单
export const create = params => {
return POST('POST', `${orderbase}/create`, params).then(res => res.data);
}
//获取订单列表
export const getUserOrderList = params => {
return POST('GET', `${orderbase}/getUserOrderList`, params).then(res => res.data);
}
//订单详情
export const getDetailByOrderNo = params => {
return POST('GET', `${orderbase}/getDetailByOrderNo`, params).then(res => res.data);
}
//取消订单
export const cancel = params => {
return POST('POST', `${orderbase}/cancel`, params).then(res => res.data);
}
//银联支付
export const unionPay = params => {
return POST('POST', `${orderbase}/orderPay/unionPay`, params).then(res => res.data);
}
//工会卡、油卡
export const cardPay = params => {
return POST('POST', `${orderbase}/orderPay/cardPay`, params).then(res => res.data);
}
//已完成未查看
export const orderCheck = params => {
return POST('GET', `${orderbase}/orderCheck`, params).then(res => res.data);
}
//在线加油详情
export const getOrderByOrderNo = params => {
return POST('GET', `${orderbase}/oil/getOrderByOrderNo`, params).then(res => res.data);
}
//----------------我的页面接口
// 手机号登录
export const unionPhoneLogin = params => {
return POST('POST', `${userbase}/login/union`, params).then(res => res.data);
}
// 获取用户信息
export const findUser = params => {
return POST('POST', `${userbase}/getUserDetail`, params).then(res => res.data);
}
// 获取用户余额
export const getUserAccount = params => {
return POST('POST', `${userbase}/getUserAccount`, params).then(res => res.data);
}
//查询优惠券
export const getUserDiscountList = params => {
return POST('GET', `${userbase}/discount/getUserDiscountList`, params).then(res => res.data);
}

@ -167,18 +167,15 @@
import ssPaymentPassword from '@/components/sanshui-payment-password/index.vue'; import ssPaymentPassword from '@/components/sanshui-payment-password/index.vue';
import wybPopup from '../../components/wyb-popup/wyb-popup.vue'; import wybPopup from '../../components/wyb-popup/wyb-popup.vue';
import { import {
xbkaddOrder, create,
getThirdPartyByDetail, getThirdPartyByDetail,
getHuiLianTongCardBalance, getHuiLianTongCardBalance,
findUser, findUser,
qianzhuorderToUnionPay, unionPay,
czhltUnionCardPay, cardPay,
getUserOrderPreList, getUserOrderPreList,
getRebateIntegral getRebateIntegral
} from '../../Utils/Api.js'; } from '../../Utils/Api.js';
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
let app = getApp(); let app = getApp();
export default { export default {
components: { components: {
@ -388,22 +385,25 @@
title: '提交订单中...' title: '提交订单中...'
}) })
let datas = { let datas = {
"customerMobile": this.customerMobile, "childOrderList": [{
"regionId": app.globalData.cityId, "goodsId": this.goodId,
"productType": 3, "customerMobile": this.customerMobile,
"platformId": this.showType, "platformId": this.showType,
"password": this.PaymentPassword, "productType": this.productType,
"integralNum": this.priceValue[1], "goodsType": 10,
"saleCount": 1,
}],
"payGold": this.priceValue[1],
"companyId": app.globalData.companyId,
"memDiscountId": this.memDiscountId, "memDiscountId": this.memDiscountId,
"goodsId": this.goodId
} }
xbkaddOrder(datas).then(res => { create(datas).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.orderId = res.return_data.id; this.orderId = res.return_data.orderNo;
let params = { let params = {
"orderId": res.return_data.id, "orderNo": res.return_data.orderNo,
} }
this.qianzhuorderToUnionPay(params); this.qianzhuorderToUnionPay(params);
} else { } else {
@ -514,7 +514,7 @@
qianzhuorderToUnionPay(item) { qianzhuorderToUnionPay(item) {
let that = this; let that = this;
if (that.paytype == '4') { if (that.paytype == '4') {
qianzhuorderToUnionPay(item).then(res => { unionPay(item).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
that.uniontopay(res.return_data.prepayid); that.uniontopay(res.return_data.prepayid);
} else { } else {
@ -606,20 +606,25 @@
} }
if (this.payPrice == 0) { if (this.payPrice == 0) {
let datas = { let datas = {
"customerMobile": this.customerMobile, "childOrderList": [{
"regionId": app.globalData.cityId, "goodsId": this.goodId,
"productType": 3, "customerMobile": this.customerMobile,
"platformId": this.showType, "platformId": this.showType,
"password": this.PaymentPassword, "productType": 3,
"integralNum": this.priceValue[1], "goodsType": 10,
"saleCount": 1,
}],
"payGold": this.priceValue[1],
"companyId": app.globalData.companyId,
// "promoteCode": this.identificationCode,
"memDiscountId": this.memDiscountId, "memDiscountId": this.memDiscountId,
"goodsId": this.goodId "payPwd": this.PaymentPassword
} }
xbkaddOrder(datas).then(res => { create(datas).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.orderId = res.return_data.id; this.orderId = res.return_data.orderNo;
uni.reLaunch({ uni.reLaunch({
url: '/qianzhu-KFC/order-details/order-details?id=' + this.orderId url: '/qianzhu-KFC/order-details/order-details?id=' + this.orderId
}) })
@ -640,11 +645,11 @@
return; return;
} }
let params = { let params = {
"orderId": this.orderId, "orderNo": this.orderId,
"cardNo": this.user.hltCardNo.cardNo, "cardNo": this.user.hltCardNo.cardNo,
"password": this.PaymentPassword "password": this.PaymentPassword
} }
czhltUnionCardPay(params).then(res => { cardPay(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.showToast({ uni.showToast({

@ -1,30 +0,0 @@
# jweixin-module
微信JS-SDK
## 安装
### NPM
```shell
npm install jweixin-module --save
```
### UMD
```http
https://unpkg.com/jweixin-module/out/index.js
```
## 使用
```js
var jweixin = require('jweixin-module')
jweixin.ready(function(){
// TODO
});
```
## 完整API
>[微信JS-SDK说明文档](https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421141115)

File diff suppressed because one or more lines are too long

@ -1,54 +0,0 @@
{
"_from": "jweixin-module",
"_id": "jweixin-module@1.6.0",
"_inBundle": false,
"_integrity": "sha512-dGk9cf+ipipHmtzYmKZs5B2toX+p4hLyllGLF6xuC8t+B05oYxd8fYoaRz0T30U2n3RUv8a4iwvjhA+OcYz52w==",
"_location": "/jweixin-module",
"_phantomChildren": {},
"_requested": {
"type": "tag",
"registry": true,
"raw": "jweixin-module",
"name": "jweixin-module",
"escapedName": "jweixin-module",
"rawSpec": "",
"saveSpec": null,
"fetchSpec": "latest"
},
"_requiredBy": [
"#USER",
"/"
],
"_resolved": "https://registry.npmjs.org/jweixin-module/-/jweixin-module-1.6.0.tgz",
"_shasum": "4a7ea614083e3c9c3f49e2fdc2bb882cfa58dfcd",
"_spec": "jweixin-module",
"_where": "D:\\Documents\\high-mini",
"author": {
"name": "Shengqiang Guo"
},
"bugs": {
"url": "https://github.com/zhetengbiji/jweixin-module/issues"
},
"bundleDependencies": false,
"deprecated": false,
"description": "微信JS-SDK",
"devDependencies": {},
"homepage": "https://github.com/zhetengbiji/jweixin-module#readme",
"keywords": [
"wxjssdk",
"weixin",
"jweixin",
"wechat",
"jssdk",
"wx"
],
"license": "ISC",
"main": "lib/index.js",
"name": "jweixin-module",
"repository": {
"type": "git",
"url": "git+https://github.com/zhetengbiji/jweixin-module.git"
},
"scripts": {},
"version": "1.6.0"
}

@ -1,38 +1,34 @@
{ {
"_from": "vue-jsonp", "name": "vue-jsonp",
"_id": "vue-jsonp@2.0.0", "version": "2.0.0",
"_inBundle": false, "description": "A tiny library for handling JSONP request.",
"_integrity": "sha512-Mzd9GNeuKP5hHFDWZNMWOsCuMILSkA6jo2l4A02wheFz3qqBzH7aSEFTey1BRCZCLizlaf1EqJ5YUtF392KspA==", "main": "./dist/index.js",
"_location": "/vue-jsonp", "module": "./dist/index.esm.js",
"_phantomChildren": {}, "keywords": [
"_requested": { "Vue",
"type": "tag", "JSONP"
"registry": true, ],
"raw": "vue-jsonp", "files": [
"name": "vue-jsonp", "dist/",
"escapedName": "vue-jsonp", "index.d.ts",
"rawSpec": "", "README.md"
"saveSpec": null,
"fetchSpec": "latest"
},
"_requiredBy": [
"#USER",
"/"
], ],
"_resolved": "https://registry.npmjs.org/vue-jsonp/-/vue-jsonp-2.0.0.tgz", "scripts": {
"_shasum": "3bfac56bb72941a2511c11e1a123b876f03427f7", "build": "rollup -c",
"_spec": "vue-jsonp", "test": "jest",
"_where": "C:\\Users\\Administrator\\Documents\\high-mini", "pretest": "npm run build",
"preversion": "npm run test",
"prepublish": "npm run test"
},
"author": { "author": {
"name": "LancerComet", "name": "LancerComet",
"email": "chw644@hotmail.com" "email": "chw644@hotmail.com"
}, },
"bugs": { "repository": {
"url": "https://github.com/LancerComet/vue-jsonp/issues" "type": "git",
"url": "https://github.com/LancerComet/vue-jsonp.git"
}, },
"bundleDependencies": false, "license": "MIT",
"deprecated": false,
"description": "A tiny library for handling JSONP request.",
"devDependencies": { "devDependencies": {
"@types/expect-puppeteer": "^4.4.3", "@types/expect-puppeteer": "^4.4.3",
"@types/jest": "^26.0.14", "@types/jest": "^26.0.14",
@ -50,31 +46,5 @@
"tslint": "^6.1.3", "tslint": "^6.1.3",
"typescript": "^4.0.3", "typescript": "^4.0.3",
"vue": "^2.6.12" "vue": "^2.6.12"
}, }
"files": [
"dist/",
"index.d.ts",
"README.md"
],
"homepage": "https://github.com/LancerComet/vue-jsonp#readme",
"keywords": [
"Vue",
"JSONP"
],
"license": "MIT",
"main": "./dist/index.js",
"module": "./dist/index.esm.js",
"name": "vue-jsonp",
"repository": {
"type": "git",
"url": "git+https://github.com/LancerComet/vue-jsonp.git"
},
"scripts": {
"build": "rollup -c",
"prepublish": "npm run test",
"pretest": "npm run build",
"preversion": "npm run test",
"test": "jest"
},
"version": "2.0.0"
} }

@ -1,23 +1,235 @@
{ {
"name": "视频播放器组件", "name": "视频播放器组件",
"version": "1.0.0", "version": "1.0.0",
"lockfileVersion": 1, "lockfileVersion": 2,
"requires": true, "requires": true,
"dependencies": { "packages": {
"base-64": { "": {
"version": "1.0.0", "name": "视频播放器组件",
"resolved": "https://registry.npmjs.org/base-64/-/base-64-1.0.0.tgz", "version": "1.0.0",
"integrity": "sha512-kwDPIFCGx0NZHog36dj+tHiwP4QMzsZ3AgMViUBKI0+V5n4U0ufTCUMhnQ04diaRI8EX/QcPfql7zlhZ7j4zgg==" "dependencies": {
"base-64": "^1.0.0",
"vue-jsonp": "^2.0.0",
"vue-lottie": "^0.2.1"
}
},
"node_modules/@babel/parser": {
"version": "7.20.0",
"resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.20.0.tgz",
"integrity": "sha512-G9VgAhEaICnz8iiJeGJQyVl6J2nTjbW0xeisva0PK6XcKsga7BIaqm4ZF8Rg1Wbaqmy6znspNqhPaPkyukujzg==",
"peer": true,
"bin": {
"parser": "bin/babel-parser.js"
},
"engines": {
"node": ">=6.0.0"
}
},
"node_modules/@vue/compiler-sfc": {
"version": "2.7.13",
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-2.7.13.tgz",
"integrity": "sha512-zzu2rLRZlgIU+OT3Atbr7Y6PG+LW4wVQpPfNRrGDH3dM9PsrcVfa+1pKb8bW467bGM3aDOvAnsYLWVpYIv3GRg==",
"peer": true,
"dependencies": {
"@babel/parser": "^7.18.4",
"postcss": "^8.4.14",
"source-map": "^0.6.1"
}
},
"node_modules/base-64": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/base-64/-/base-64-1.0.0.tgz",
"integrity": "sha512-kwDPIFCGx0NZHog36dj+tHiwP4QMzsZ3AgMViUBKI0+V5n4U0ufTCUMhnQ04diaRI8EX/QcPfql7zlhZ7j4zgg=="
},
"node_modules/csstype": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.1.tgz",
"integrity": "sha512-DJR/VvkAvSZW9bTouZue2sSxDwdTN92uHjqeKVm+0dAqdfNykRzQ95tay8aXMBAAPpUiq4Qcug2L7neoRh2Egw==",
"peer": true
},
"node_modules/lottie-web": {
"version": "5.9.6",
"resolved": "https://registry.npmjs.org/lottie-web/-/lottie-web-5.9.6.tgz",
"integrity": "sha512-JFs7KsHwflugH5qIXBpB4905yC1Sub2MZWtl/elvO/QC6qj1ApqbUZJyjzJseJUtVpgiDaXQLjBlIJGS7UUUXA=="
},
"node_modules/nanoid": {
"version": "3.3.4",
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.4.tgz",
"integrity": "sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw==",
"peer": true,
"bin": {
"nanoid": "bin/nanoid.cjs"
},
"engines": {
"node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1"
}
},
"node_modules/picocolors": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
"integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==",
"peer": true
},
"node_modules/postcss": {
"version": "8.4.18",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.18.tgz",
"integrity": "sha512-Wi8mWhncLJm11GATDaQKobXSNEYGUHeQLiQqDFG1qQ5UTDPTEvKw0Xt5NsTpktGTwLps3ByrWsBrG0rB8YQ9oA==",
"funding": [
{
"type": "opencollective",
"url": "https://opencollective.com/postcss/"
},
{
"type": "tidelift",
"url": "https://tidelift.com/funding/github/npm/postcss"
}
],
"peer": true,
"dependencies": {
"nanoid": "^3.3.4",
"picocolors": "^1.0.0",
"source-map-js": "^1.0.2"
},
"engines": {
"node": "^10 || ^12 || >=14"
}
},
"node_modules/source-map": {
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
"integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
"peer": true,
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/source-map-js": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz",
"integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==",
"peer": true,
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/vue": {
"version": "2.7.13",
"resolved": "https://registry.npmjs.org/vue/-/vue-2.7.13.tgz",
"integrity": "sha512-QnM6ULTNnPmn71eUO+4hdjfBIA3H0GLsBnchnI/kS678tjI45GOUZhXd0oP/gX9isikXz1PAzSnkPspp9EUNfQ==",
"peer": true,
"dependencies": {
"@vue/compiler-sfc": "2.7.13",
"csstype": "^3.1.0"
}
},
"node_modules/vue-jsonp": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/vue-jsonp/-/vue-jsonp-2.0.0.tgz",
"integrity": "sha512-Mzd9GNeuKP5hHFDWZNMWOsCuMILSkA6jo2l4A02wheFz3qqBzH7aSEFTey1BRCZCLizlaf1EqJ5YUtF392KspA=="
},
"node_modules/vue-lottie": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/vue-lottie/-/vue-lottie-0.2.1.tgz",
"integrity": "sha512-zInUX69Ij8MhVR3XArpu4PqqBoufwKxS5UMutWCPm59VUaB5H6GtnaIzf9M+l6aYU+Kr8gF/W9dzWLgRuU6V+Q==",
"dependencies": {
"lottie-web": "^5.1.9"
},
"peerDependencies": {
"vue": "^2.5.16"
}
}
}, },
"jweixin-module": { "dependencies": {
"version": "1.6.0", "@babel/parser": {
"resolved": "https://registry.npmjs.org/jweixin-module/-/jweixin-module-1.6.0.tgz", "version": "7.20.0",
"integrity": "sha512-dGk9cf+ipipHmtzYmKZs5B2toX+p4hLyllGLF6xuC8t+B05oYxd8fYoaRz0T30U2n3RUv8a4iwvjhA+OcYz52w==" "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.20.0.tgz",
}, "integrity": "sha512-G9VgAhEaICnz8iiJeGJQyVl6J2nTjbW0xeisva0PK6XcKsga7BIaqm4ZF8Rg1Wbaqmy6znspNqhPaPkyukujzg==",
"vue-jsonp": { "peer": true
"version": "2.0.0", },
"resolved": "https://registry.npmjs.org/vue-jsonp/-/vue-jsonp-2.0.0.tgz", "@vue/compiler-sfc": {
"integrity": "sha512-Mzd9GNeuKP5hHFDWZNMWOsCuMILSkA6jo2l4A02wheFz3qqBzH7aSEFTey1BRCZCLizlaf1EqJ5YUtF392KspA==" "version": "2.7.13",
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-2.7.13.tgz",
"integrity": "sha512-zzu2rLRZlgIU+OT3Atbr7Y6PG+LW4wVQpPfNRrGDH3dM9PsrcVfa+1pKb8bW467bGM3aDOvAnsYLWVpYIv3GRg==",
"peer": true,
"requires": {
"@babel/parser": "^7.18.4",
"postcss": "^8.4.14",
"source-map": "^0.6.1"
}
},
"base-64": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/base-64/-/base-64-1.0.0.tgz",
"integrity": "sha512-kwDPIFCGx0NZHog36dj+tHiwP4QMzsZ3AgMViUBKI0+V5n4U0ufTCUMhnQ04diaRI8EX/QcPfql7zlhZ7j4zgg=="
},
"csstype": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.1.tgz",
"integrity": "sha512-DJR/VvkAvSZW9bTouZue2sSxDwdTN92uHjqeKVm+0dAqdfNykRzQ95tay8aXMBAAPpUiq4Qcug2L7neoRh2Egw==",
"peer": true
},
"lottie-web": {
"version": "5.9.6",
"resolved": "https://registry.npmjs.org/lottie-web/-/lottie-web-5.9.6.tgz",
"integrity": "sha512-JFs7KsHwflugH5qIXBpB4905yC1Sub2MZWtl/elvO/QC6qj1ApqbUZJyjzJseJUtVpgiDaXQLjBlIJGS7UUUXA=="
},
"nanoid": {
"version": "3.3.4",
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.4.tgz",
"integrity": "sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw==",
"peer": true
},
"picocolors": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
"integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==",
"peer": true
},
"postcss": {
"version": "8.4.18",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.18.tgz",
"integrity": "sha512-Wi8mWhncLJm11GATDaQKobXSNEYGUHeQLiQqDFG1qQ5UTDPTEvKw0Xt5NsTpktGTwLps3ByrWsBrG0rB8YQ9oA==",
"peer": true,
"requires": {
"nanoid": "^3.3.4",
"picocolors": "^1.0.0",
"source-map-js": "^1.0.2"
}
},
"source-map": {
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
"integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
"peer": true
},
"source-map-js": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz",
"integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==",
"peer": true
},
"vue": {
"version": "2.7.13",
"resolved": "https://registry.npmjs.org/vue/-/vue-2.7.13.tgz",
"integrity": "sha512-QnM6ULTNnPmn71eUO+4hdjfBIA3H0GLsBnchnI/kS678tjI45GOUZhXd0oP/gX9isikXz1PAzSnkPspp9EUNfQ==",
"peer": true,
"requires": {
"@vue/compiler-sfc": "2.7.13",
"csstype": "^3.1.0"
}
},
"vue-jsonp": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/vue-jsonp/-/vue-jsonp-2.0.0.tgz",
"integrity": "sha512-Mzd9GNeuKP5hHFDWZNMWOsCuMILSkA6jo2l4A02wheFz3qqBzH7aSEFTey1BRCZCLizlaf1EqJ5YUtF392KspA=="
},
"vue-lottie": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/vue-lottie/-/vue-lottie-0.2.1.tgz",
"integrity": "sha512-zInUX69Ij8MhVR3XArpu4PqqBoufwKxS5UMutWCPm59VUaB5H6GtnaIzf9M+l6aYU+Kr8gF/W9dzWLgRuU6V+Q==",
"requires": {
"lottie-web": "^5.1.9"
}
}
} }
}
} }

@ -11,6 +11,8 @@
"uniapp" "uniapp"
], ],
"dependencies": { "dependencies": {
"base-64": "^1.0.0" "base-64": "^1.0.0",
"vue-jsonp": "^2.0.0",
"vue-lottie": "^0.2.1"
} }
} }

@ -54,7 +54,7 @@
<view class="width96 mart10 alijusstart"> <view class="width96 mart10 alijusstart">
<view class="fcorfff font12 height20" style="background-color: #3da7e7;border-radius: 20px;padding: 0px 5px;">嗨森逛 <view class="fcorfff font12 height20" style="background-color: #3da7e7;border-radius: 20px;padding: 0px 5px;">嗨森逛
</view> </view>
<view class="width70 fotrt font14 fcor666">月销 500</view> <view class="width70 fotrt font14 fcor666">月销 {{goodsData[0].salesCount}}</view>
</view> </view>
</view> </view>
<!-- 服务-规则选择 --> <!-- 服务-规则选择 -->

@ -78,6 +78,13 @@
</view> </view>
</view> </view>
<view class="width94 backcorfff mart10">
<view class="width94 alijusstart height50 font14 fcor666">
<view class="width40 fcor333 fontwig6 font16" style="padding-left: 2%;">邀请码</view>
<input class="width60 fotrt font15" v-model="identificationCode" placeholder="请输入邀请码" />
</view>
</view>
<!-- // --> <!-- // -->
<view class="width100 concont mart10 backcorfff"> <view class="width100 concont mart10 backcorfff">
<view class="height50 width100 paddtop5 backcorfff" @click="showPopup()"> <view class="height50 width100 paddtop5 backcorfff" @click="showPopup()">
@ -245,9 +252,6 @@
import wybPopup from '../../../components/wyb-popup/wyb-popup.vue'; import wybPopup from '../../../components/wyb-popup/wyb-popup.vue';
import cjSlider from '@/components/cj-slider/cj-slider.vue'; import cjSlider from '@/components/cj-slider/cj-slider.vue';
let app = getApp(); let app = getApp();
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
export default { export default {
components: { components: {
ssPaymentPassword, ssPaymentPassword,
@ -278,12 +282,19 @@
availIntegal: 0, // availIntegal: 0, //
gasOrderList: '', // gasOrderList: '', //
rebateIntegral: '', // rebateIntegral: '', //
Integrastu: 1 // Integrastu: 1 ,//
identificationCode: '', //
} }
}, },
onLoad(e) { onLoad(e) {
this.gasOrderList = app.globalData.pelletoilList; this.gasOrderList = app.globalData.pelletoilList;
this.orderPrice = this.gasOrderList.highChildOrderList[0].goodsPrice; this.orderPrice = this.gasOrderList.highChildOrderList[0].goodsPrice;
// #ifdef H5
this.identificationCode = app.globalData.staffCode;
// #endif
// #ifdef MP
this.identificationCode = app.globalData.identificationCode;
// #endif
}, },
onShow() { onShow() {
let that = this; let that = this;
@ -492,6 +503,7 @@
if (this.payPrice == 0 && !this.orderNo) { if (this.payPrice == 0 && !this.orderNo) {
let goods = { let goods = {
"identificationCode": this.gasOrderList.identificationCode, "identificationCode": this.gasOrderList.identificationCode,
"promoteCode":this.identificationCode,
"payGold": this.priceValue[1], "payGold": this.priceValue[1],
"memDiscountId": this.memDiscountId, "memDiscountId": this.memDiscountId,
"payPwd": this.PaymentPassword, "payPwd": this.PaymentPassword,
@ -730,6 +742,7 @@
}) })
let goods = { let goods = {
"identificationCode": this.gasOrderList.identificationCode, "identificationCode": this.gasOrderList.identificationCode,
"promoteCode":this.identificationCode,
"payGold": this.priceValue[1], "payGold": this.priceValue[1],
"memDiscountId": this.memDiscountId, "memDiscountId": this.memDiscountId,
"highChildOrderList": [{ "highChildOrderList": [{

@ -8,29 +8,15 @@
<view class="font18 fontwig6 fcor333 text1">{{couponList.couponName}}</view> <view class="font18 fontwig6 fcor333 text1">{{couponList.couponName}}</view>
<view class="font13 fcor666 mart10">规格: 默认</view> <view class="font13 fcor666 mart10">规格: 默认</view>
<view class="price-number mart10" v-if="isDiscont"> <view class="price-number mart10" v-if="isDiscont">
<view class="price font16" v-if="couponList.payType == 1">{{couponList.salesPrice}}</view> <view class="price font16">{{couponList.salesPrice}}</view>
<view class="price font16" v-else>
<image style="width: 15px;height: 15px;" src="../../static/img/jfx.png">
</image>{{couponList.salesPrice * 100}}
</view>
<view class="flright fotrt paddleft10">x1</view> <view class="flright fotrt paddleft10">x1</view>
</view> </view>
<view class="price-number mart10" v-if="!isDiscont"> <view class="price-number mart10" v-if="!isDiscont">
<view class="price font16" v-if="couponList.payType == 1">{{couponList.discountPrice}}</view> <view class="price font16">{{couponList.discountPrice}}</view>
<view class="price font16" v-else>
<image style="width: 15px;height: 15px;" src="../../static/img/jfx.png">
</image>{{couponList.discountPrice*100}}
</view>
<view class="number fcor666 font13 margle" <view class="number fcor666 font13 margle"
v-if="couponList.payType == 1 && couponList.salesPrice != couponList.discountPrice"> v-if="couponList.salesPrice != couponList.discountPrice">
{{couponList.salesPrice}} {{couponList.salesPrice}}
</view> </view>
<view class="number fcor666 font13 margle"
v-if="couponList.payType != 1 && couponList.salesPrice != couponList.discountPrice">
<image style="width: 15px;height: 15px;" src="../../static/img/jfh.png">
</image>{{couponList.salesPrice*100}}
</view>
<view class="flright fotrt paddleft10">x1</view> <view class="flright fotrt paddleft10">x1</view>
</view> </view>
</view> </view>
@ -40,24 +26,12 @@
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;"> <view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
商品总额 商品总额
</view> </view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999" <view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999" v-if=" isDiscont">
v-if="couponList.payType == 1 && isDiscont">
{{couponList.salesPrice}} {{couponList.salesPrice}}
</view> </view>
<view class="width40 flright alijun paddtright10 font15 fontwig6 fcor666 aliitem" <view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999" v-if="!isDiscont">
v-if="couponList.payType != 1 && isDiscont">
<image style="width: 15px;height: 15px;" src="../../static/img/jfx.png">
</image>{{couponList.salesPrice*100}}
</view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999"
v-if="couponList.payType == 1 && !isDiscont">
{{couponList.discountPrice}} {{couponList.discountPrice}}
</view> </view>
<view class="width40 flright alijun paddtright10 font15 fontwig6 fcor666 aliitem"
v-if="couponList.payType != 1 && !isDiscont">
<image style="width: 15px;height: 15px;" src="../../static/img/jfx.png">
</image>{{couponList.discountPrice*100}}
</view>
</view> </view>
<view class="width94 line1 mart5 marb5"></view> <view class="width94 line1 mart5 marb5"></view>
@ -96,85 +70,88 @@
</view> </view>
<view class="width94 comorder mart10"> <view class="width94 comorder mart10">
<view class="height50 width100 backcorfff">
<view class="width100 flleft fcor333 fontwig6 font16" style="padding-left: 4%;"> <view class="width92 alijusstart paddtop20">
支付方式<text class="jfrecharge" @click="jumpdeposits" v-if="couponList.payType == 2">积分充值</text> <view class="width30 fcor333 fontwig6 font16">
积分抵扣
</view>
<view class="cj-slider">
<view class="flleft fotct font14 fcor666" style="width: 15%;">0</view>
<cj-slider style="width: 60%; float:left;" v-if="isDiscount" v-model="priceValue" :min="0"
:max="availIntegal" :step="1" :blockWidth="40" @start="blockStart" @moving="blockMoving"
@end="blockEnd" />
<view class="flright fotrt font14 fcor666" style="width: 25%;">{{availIntegal}}</view>
</view> </view>
</view> </view>
<view class="width94 line1 mart5 marb5" v-if="couponList.payType == 2"></view> <view class="width94 line1 mart15 marb5"></view>
<view class="height50 width100 backcorfff" @tap="paytype='jinbi'" v-if="couponList.payType == 2 "> <view class="height50 width100 backcorfff">
<view class="width70 flleft fcor333 fontwig6 font16 text1" style="padding-left: 4%;"> <view class="width70 flleft fcor333 fontwig6 font16 text1" style="padding-left: 4%;">
积分支付<text class="font14 fcor666 margle">可用积分: {{user.gold}}</text> 抵扣金额
</view> </view>
<view class="width20 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun" <view class="width20 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun"
style="align-items: center;"> style="align-items: center;">
<radio :checked="paytype=='jinbi'" color="#0083f5" /> ¥{{priceValue[1] / 100}}
</view> </view>
</view> </view>
<view class="width94 line1 mart5 marb5" v-if="couponList.payType != 2"></view> <view class="width94 line1 mart5 marb5"></view>
<view class="height50 width100 backcorfff" @tap="paytype='unionPay'" v-if="couponList.payType != 2">
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;"> <view class="height40 width100 backcorfff">
银联支付 <view class="width40 flleft fcor666 font15 fontwig6 text1 alijusstart" style="padding-left: 2%;">
<image src="../../static/img/rebate.png" mode="widthFix" style="width: 25px;"></image>
<text>下单返积分</text>
</view> </view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun" <view class="width50 flright fotrt paddtright10 font15 colore95 alijun" v-if="Integrastu == 1"
style="align-items: center;"> style="align-items: center;">
<radio :checked="paytype=='unionPay'" color="#0083f5" /> {{rebateIntegral}}积分
</view>
</view>
<view class="width94 line1 mart5 marb5" v-if="couponList.payType == 2"></view>
<view class="height50 width100 backcorfff" @tap="paytype='gonghuika'" v-if="couponList.payType == 2">
<view class="width70 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
工会卡支付<text class="font14 fcor666 margle">可用余额: {{tongCardPrice}}</text>
</view> </view>
<view class="width20 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun" <view class="width50 flright fotrt paddtright10 font15 colore95 alijun" v-if="Integrastu == 2"
style="align-items: center;"> style="align-items: center;">
<radio :checked="paytype=='gonghuika'" @click="changeRiado()" color="#0083f5" /> {{rebateIntegral}}
</view> </view>
</view> </view>
<!-- <view class="width94 line1 mart5 marb5" v-if="couponList.displayArea == 4"></view> <view class=" width100 backcorfff alijusstart paddbotm10" style="padding-left: 2%;">
<view class="height50 width100 backcorfff" @tap="paytype='unionPaystags'" <image src="../../static/img/sigh.png" mode="widthFix" class="icon20"></image>
v-if="couponList.displayArea == 4"> <text class="fcor999 font13">积分抵扣与优惠券抵扣不同享</text>
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;"> </view>
银联分期
</view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun"
style="align-items: center;">
<radio :checked="paytype=='unionPaystags'" color="#0083f5" />
</view>
</view> -->
</view>
<!-- <view class="width94 comorder mart10">
<view class="height50 width100 backcorfff"> <view class="height50 width100 backcorfff">
<view class="width80p flleft fcor333 fontwig6 font14" style="padding-left: 4%;"> <view class="width100 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
<text style="color: #0083F5;">条约协议</text>点击立即支付即代表同意 支付方式
<!-- <text class="jfrecharge" @click="jumpdeposits" v-if="couponList.payType == 2">积分充值</text> -->
</view> </view>
<view class="width15 flright fotct"> </view>
<image class="jtcs" src="../../static/img/jt.png"></image> <view class="width100" v-for="(item,index) in paytypeList" :key="index">
<view class="width94 line1 mart5 marb5" v-if="item == 4"></view>
<view class="height50 width100 backcorfff" @tap="paytype='4'" v-if="item == 4">
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
银联支付
</view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun"
style="align-items: center;" v-if="isUse">
<radio :checked="paytype=='4'" color="#0083f5" />
</view>
</view>
<view class="width94 line1 mart5 marb5" v-if="item == 3"></view>
<view class="height50 width100 backcorfff" @tap="paytype='3'" v-if="item == 3">
<view class="width70 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
工会卡支付<text class="font14 fcor666 margle">可用余额: {{tongCardPrice}}</text>
</view>
<view class="width20 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun"
style="align-items: center;" v-if="isUse">
<radio :checked="paytype=='3'" @click="changeRiado()" color="#0083f5" />
</view>
</view> </view>
</view> </view>
</view> --> </view>
<view class="width100 height60"></view> <view class="width100 height60"></view>
<view class="footer"> <view class="footer">
<view class="settlement"> <view class="settlement">
<view class="sum">实付:<view class="money" v-if="couponList.payType == 1">{{paytheprice}}</view> <view class="sum">实付:<view class="money">{{paytheprice}}</view>
<view class="money aliitem" v-else>
<image style="width: 15px;height: 15px;vertical-align: sub;" src="../../static/img/jfx.png">
</image>{{paytheprice*100}}
</view>
</view> </view>
<!-- #ifdef MP -->
<button class="btn" open-type="getPhoneNumber" v-if="user.phone == null"
@getphonenumber="getPhoneNumber">立即支付</button>
<button class="btn" v-else @tap="toPay">立即支付</button>
<!-- #endif -->
<!-- #ifdef H5 -->
<button class="btn" v-if="user.phone == null" @click="jumpH5Bding">立即支付</button> <button class="btn" v-if="user.phone == null" @click="jumpH5Bding">立即支付</button>
<button class="btn" v-else @tap="toPay">立即支付</button> <button class="btn" v-else @tap="toPay">立即支付</button>
<!-- #endif -->
</view> </view>
</view> </view>
@ -199,19 +176,18 @@
<script> <script>
import { import {
addOrder, create,
getCouponById, getCouponById,
GetPhoneNumber,
getUserNormalDiscountList, getUserNormalDiscountList,
bindUserPhone,
orderToPay,
orderToGoldPay,
findUser, findUser,
unionPay, unionPay,
hltUnionCardPay, getRebateIntegral,
getHuiLianTongCardBalance cardPay,
getHuiLianTongCardBalance,
getThirdPartyByDetail
} from '../../Utils/Api.js'; } from '../../Utils/Api.js';
import wybPopup from '../../components/wyb-popup/wyb-popup.vue'; import wybPopup from '../../components/wyb-popup/wyb-popup.vue';
import cjSlider from '../../components/cj-slider/cj-slider.vue';
import ssPaymentPassword from '../../components/sanshui-payment-password' import ssPaymentPassword from '../../components/sanshui-payment-password'
let app = getApp(); let app = getApp();
@ -222,19 +198,14 @@
}, },
data() { data() {
return { return {
buylist: [], //
goodsPrice: 0.0, //
sumPrice: 0.0, //
freight: 12.00, //
note: '', //
int: 1200, //
deduction: 0, //
couponId: '', couponId: '',
couponList: [], couponList: [],
UserNormalDiscountList: [], UserNormalDiscountList: [],
imageUrl: app.globalData.imgUrl, imageUrl: app.globalData.imgUrl,
deductionPrice: '0.00', deductionPrice: '0.00',
paytheprice: '', paytheprice: '', //
saveprice: '', //
orderPrice: '', //
radioStatus: true, radioStatus: true,
memDiscountId: '', memDiscountId: '',
user: '', user: '',
@ -246,21 +217,28 @@
storeId: '', storeId: '',
isDiscont: false, isDiscont: false,
coupondiscountid: '', coupondiscountid: '',
typeId: '', orderDetails: '', //
identificationCode: '' // payGold: '', //
identificationCode: '', //
paytypeList: [], //
priceValue: [0, 0], //
changePrice: '', //
isDiscount: true,
availIntegal: '', //
isUse: true, //
rechargeDes: '', //
rebateIntegral: '', //
Integrastu: 1 //
}; };
}, },
onLoad(option) { onLoad(option) {
this.couponId = option.id; this.couponId = option.id;
this.typeId = option.typeid;
this.getCouponById(); this.getCouponById();
}, },
onShow() { onShow() {
let that = this; let that = this;
that.paytype = ''; that.paytype = '';
that.user = app.globalData.userInfo; that.user = app.globalData.userInfo;
that.getUserNormalDiscountList();
that.findUser(); that.findUser();
}, },
onHide() { onHide() {
@ -291,6 +269,31 @@
} }
}, },
methods: { methods: {
//
getThirdPartyByDetail() {
let datas = {
platformId: 3,
regionId: app.globalData.cityId,
productType: 4,
productId: this.couponList.couponSource
}
getThirdPartyByDetail(datas).then(res => {
if (res.return_code == '000000') {
this.rechargeDes = res.return_data;
this.paytypeList = res.return_data.productPayType.split(',');
this.paytypeList = this.paytypeList.slice(0, this.paytypeList.length - 1);
let zkprice = parseFloat(res.return_data.integralDiscount / 100).toFixed(2);
let pprice = parseFloat(this.paytheprice * 100).toFixed(0)
let payprice = parseFloat(this.paytheprice * 100 * zkprice).toFixed(
0);
if (payprice > this.user.gold) {
this.availIntegal = this.user.gold;
} else {
this.availIntegal = payprice;
}
}
});
},
// //
findUser() { findUser() {
let params; let params;
@ -301,6 +304,8 @@
if (this.user.hltCardNo) { if (this.user.hltCardNo) {
this.getHuiLianTongCardBalance(); this.getHuiLianTongCardBalance();
} }
this.getUserNormalDiscountList();
this.getRebateIntegral();
uni.setStorage({ uni.setStorage({
key: "user", key: "user",
data: res.return_data data: res.return_data
@ -321,6 +326,24 @@
}); });
}, },
//
getRebateIntegral() {
let datas = {
"companyId": app.globalData.companyId,
"price": this.paytheprice,
"productId": 1,
"type": 1,
}
getRebateIntegral(datas).then(res => {
if (res.return_code == '000000') {
this.rebateIntegral = res.return_data;
this.Integrastu = 1;
} else {
this.rebateIntegral = res.return_msg;
this.Integrastu = 2;
}
})
},
// //
getCouponById() { getCouponById() {
uni.showLoading({ uni.showLoading({
@ -330,12 +353,13 @@
couponId: this.couponId couponId: this.couponId
} }
getCouponById(params).then(res => { getCouponById(params).then(res => {
uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.couponList = res.return_data; this.couponList = res.return_data;
this.paytheprice = res.return_data.discountPrice; this.paytheprice = res.return_data.discountPrice;
uni.hideLoading() this.saveprice = res.return_data.discountPrice;
} else { this.orderPrice = res.return_data.salesPrice
uni.hideLoading() this.getThirdPartyByDetail();
} }
}) })
}, },
@ -343,37 +367,88 @@
showPopup() { showPopup() {
this.$refs.popup.show(); this.$refs.popup.show();
}, },
//
radioChanges(item) { radioChanges(item) {
if (this.memDiscountId == item.highDiscount.id) { // this.paytheprice = this.orderPrice;
this.rechangeload();
if (this.memDiscountId == item.id) { //
this.memDiscountId = ''; this.memDiscountId = '';
this.coupondiscountid = '';
this.paytheprice = this.couponList.discountPrice;
this.deductionPrice = '0.00'; this.deductionPrice = '0.00';
this.priceCaluc(this.saveprice);
this.isDiscont = false; this.isDiscont = false;
} else { // } else { //
this.isDiscont = true; this.isDiscont = true;
this.memDiscountId = item.highDiscount.id; this.memDiscountId = item.id;
this.coupondiscountid = item.id;
if (item.highDiscount.discountType == 1) { if (item.highDiscount.discountType == 1) {
// //
this.deductionPrice = item.highDiscount.discountPrice; if (this.orderPrice > item.highDiscount.discountCondition) {
this.paytheprice = parseFloat(this.couponList.salesPrice - this.deductionPrice).toFixed(2); this.memDiscountId = item.id;
} else if (item.highDiscount.discountType == 2) { //
this.deductionPrice = item.highDiscount.discountPrice;
let oldprice = this.orderPrice - this.deductionPrice;
this.priceCaluc(oldprice);
} else {
uni.showToast({
title: '请满' + item.highDiscount.discountCondition + '使用此券',
icon: 'none',
duration: 2000
})
}
}
if (item.highDiscount.discountType == 2) {
// //
this.deductionPrice = item.highDiscount.discountPrice; this.deductionPrice = item.highDiscount.discountPrice;
this.paytheprice = parseFloat(this.couponList.salesPrice - this.deductionPrice).toFixed(2); let oldprice = this.orderPrice - this.deductionPrice;
} else if (item.highDiscount.discountType == 3) { this.priceCaluc(oldprice);
}
if (item.highDiscount.discountType == 3) {
// //
this.deductionPrice = parseFloat(this.couponList.salesPrice - (this.couponList.salesPrice * this.deductionPrice = parseFloat(this.orderPrice - (this.orderPrice * item.highDiscount
item .discountPrice))
.highDiscount.discountPrice)).toFixed(2)
this.paytheprice = parseFloat(this.couponList.salesPrice * item.highDiscount.discountPrice)
.toFixed(2); .toFixed(2);
let oldprice = parseFloat(this.orderPrice * item.highDiscount.discountPrice).toFixed(2);
this.priceCaluc(oldprice);
} }
} }
this.$refs.popup.hide(); this.$refs.popup.hide();
}, },
//
priceCaluc(item) {
let zkprice = parseFloat(this.rechargeDes.integralDiscount / 100).toFixed(2);
let pprice = parseFloat(item * 100).toFixed(0);
let payprice = parseFloat(item * 100 * zkprice).toFixed(0);
if (payprice > this.user.gold) {
this.availIntegal = this.user.gold;
this.priceValue[1] = 0;
} else {
this.availIntegal = payprice;
this.priceValue[1] = 0;
}
this.reload();
this.calculatepayPrice();
},
//
calculatepayPrice() {
if (this.deductionPrice == 0) {
this.paytheprice = parseFloat(this.saveprice - (parseFloat(this.priceValue[1] / 100).toFixed(2)))
.toFixed(
2);
} else {
this.paytheprice = parseFloat(this.orderPrice - (parseFloat(this.priceValue[1] / 100).toFixed(2)) -
this
.deductionPrice).toFixed(2);
}
this.getRebateIntegral();
},
rechangeload() {
this.isUse = false;
this.$nextTick(() => (this.isUse = true))
},
//
reload() {
this.isDiscount = false;
this.$nextTick(() => (this.isDiscount = true))
},
// //
getUserNormalDiscountList() { getUserNormalDiscountList() {
let params = { let params = {
@ -391,33 +466,17 @@
url: '/pages/login/register?id=2' url: '/pages/login/register?id=2'
}) })
}, },
// toPay() {
getPhoneNumber(PhoneNumber) { if (this.paytheprice == 0) {
let params = { if (!this.user.isSetPayPwd) {
openId: app.globalData.openId, uni.navigateTo({
iv: PhoneNumber.detail.iv, url: '../login/updatePas/updatePas'
encryptedData: PhoneNumber.detail.encryptedData
}
GetPhoneNumber(params).then(res => {
if (res.return_code == '000000') {
app.globalData.userInfo = res.return_data
.object
.highUser;
this.user = res.return_data
.object
.highUser;
uni.setStorage({
key: "user",
data: res.return_data
.object
.highUser
}) })
let that = this; return;
that.toPay();
} }
}); this.$refs.paymentPassword.modalFun('show');
}, return;
toPay() { }
if (this.paytype == '') { if (this.paytype == '') {
uni.showToast({ uni.showToast({
title: '请选择支付方式', title: '请选择支付方式',
@ -426,6 +485,12 @@
}) })
return; return;
} }
if (this.orderDetails) {
this.wechatPay(this.orderDetails);
return;
}
uni.showLoading({ uni.showLoading({
title: '提交订单中...' title: '提交订单中...'
}) })
@ -433,21 +498,22 @@
this.storeId = app.globalData.storeid this.storeId = app.globalData.storeid
} }
let goods = { let goods = {
"memDiscountId": this.coupondiscountid, "childOrderList": [{
"identificationCode": this.identificationCode,
"highChildOrderList": [{
"goodsType": 1,
"goodsId": this.couponId, "goodsId": this.couponId,
"goodsPrice": this.paytheprice,
"goodsType": 1,
"saleCount": 1, "saleCount": 1,
"storeId": this.storeId }],
}] "payGold": this.priceValue[1],
"promoteCode": this.identificationCode,
memDiscountId: this.memDiscountId
} }
addOrder(goods).then(res => { create(goods).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.hideLoading(); uni.hideLoading();
this.jumpType = res.return_data.highChildOrderList[0].ext1; this.jumpType = res.return_data.highChildOrderList[0].ext1;
this.orderId = res.return_data.id; this.orderId = res.return_data.orderNo;
this.orderToPay(res.return_data); this.wechatPay(res.return_data);
} else { } else {
uni.hideLoading(); uni.hideLoading();
uni.showToast({ uni.showToast({
@ -477,39 +543,16 @@
} }
}, },
// //
orderToPay(item) { wechatPay(item) {
let that = this; let that = this;
if (that.paytype == 'jinbi') { if (that.paytype == '4') {
if (that.user.gold < that.paytheprice * 100) {
uni.showToast({
icon: 'none',
title: '积分不足',
duration: 2000,
success() {
setTimeout(() => {
uni.navigateTo({
url: '../user/deposit/deposit'
})
}, 1000)
}
});
return;
}
if (!that.user.isSetPayPwd) {
uni.navigateTo({
url: '../login/updatePas/updatePas'
})
return;
}
that.$refs.paymentPassword.modalFun('show');
} else if (that.paytype == 'unionPay') {
that.unionPay(); that.unionPay();
} else if (that.paytype == 'unionPaystags') { } else if (that.paytype == 'unionPaystags') {
// //
uni.redirectTo({ uni.redirectTo({
url: '../tabBar/order/stagesUrl/stagesUrl?orderid=' + that.orderId url: '../tabBar/order/stagesUrl/stagesUrl?orderid=' + that.orderId
}) })
} else if (that.paytype == 'gonghuika') { } else if (that.paytype == '3') {
if (that.tongCardPrice < that.paytheprice) { if (that.tongCardPrice < that.paytheprice) {
uni.showToast({ uni.showToast({
icon: 'none', icon: 'none',
@ -552,7 +595,7 @@
// //
unionPay() { unionPay() {
let goods = { let goods = {
"orderId": this.orderId "orderNo": this.orderId
} }
unionPay(goods).then(res => { unionPay(goods).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
@ -607,40 +650,49 @@
uni.showLoading({ uni.showLoading({
title: '支付中...' title: '支付中...'
}) })
if (this.paytype == 'jinbi') {
let params = { if (this.paytheprice == 0) {
"orderId": this.orderId, let goods = {
"password": this.PaymentPassword "childOrderList": [{
"goodsId": this.couponId,
"goodsPrice": this.paytheprice,
"goodsType": 1,
"saleCount": 1,
}],
"payGold": this.priceValue[1],
"promoteCode": this.identificationCode,
"payPwd": this.PaymentPassword,
memDiscountId: this.memDiscountId
} }
orderToGoldPay(params).then(res => { create(goods).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.showToast({ uni.showToast({
title: '支付成功' title: '支付成功'
}) })
app.globalData.storeid = '';
app.globalData.storename = '';
uni.reLaunch({ uni.reLaunch({
url: '../pay/success/success?id=' + this.couponId url: '../pay/success/success?id=' + this
.couponId
});
} else {
uni.showToast({
title: res.return_msg,
icon: 'none',
duration: 2000
}); });
} }
if (res.return_code == '102130') {
uni.navigateTo({
url: '../../login/updatePas/updatePas'
})
}
uni.showToast({
title: res.return_msg,
icon: 'none'
})
}) })
return; return;
} }
let params = { let params = {
"orderId": this.orderId, "orderNo": this.orderId,
"cardNo": this.user.hltCardNo.cardNo, "cardNo": this.user.hltCardNo.cardNo,
"password": this.PaymentPassword "password": this.PaymentPassword
} }
hltUnionCardPay(params).then(res => { cardPay(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.showToast({ uni.showToast({
@ -665,6 +717,30 @@
}) })
}) })
}, },
blockStart() {},
blockMoving() {
// console.log('')
},
//
blockEnd() {
this.isDiscount = 1;
if (this.deductionPrice == 0) {
this.paytheprice = parseFloat(this.saveprice - parseFloat(this.priceValue[1] / 100).toFixed(2))
.toFixed(
2);
} else {
this.paytheprice = parseFloat(this.orderPrice - parseFloat(this.priceValue[1] / 100).toFixed(2) - this
.deductionPrice).toFixed(2);
}
if (this.paytheprice == 0) {
this.isUse = false;
this.paytype = '';
} else {
this.isUse = true;
}
this.getRebateIntegral();
},
// //
jumpdeposits() { jumpdeposits() {
uni.navigateTo({ uni.navigateTo({
@ -691,16 +767,10 @@
margin-top: 30rpx; margin-top: 30rpx;
} }
.cj-slider {
.jfrecharge { width: 100%;
background-color: #0083f5;
padding: 5px 20rpx;
color: #fff;
margin-left: 50%;
justify-content: center;
align-items: center; align-items: center;
font-size: 30rpx; display: flex;
border-radius: 40rpx;
} }
.goodsimg { .goodsimg {
@ -802,8 +872,8 @@
display: flex; display: flex;
image { image {
width: 170rpx; width: 160rpx;
max-height: 170rpx; max-height: 160rpx;
} }
} }
@ -893,6 +963,17 @@
} }
} }
.jfrecharge {
background-color: #0083f5;
padding: 5px 20rpx;
color: #fff;
margin-left: 50%;
justify-content: center;
align-items: center;
font-size: 30rpx;
border-radius: 40rpx;
}
.goods-list { .goods-list {
width: 100%; width: 100%;
padding: 0; padding: 0;

@ -10,9 +10,6 @@
cancelOrderByOrderNo cancelOrderByOrderNo
} from '../../Utils/Api.js' } from '../../Utils/Api.js'
let app = getApp(); let app = getApp();
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
export default { export default {
data() { data() {
return { return {

@ -1,127 +1,126 @@
<template> <template>
<view> <view>
<view class="status"></view>
<!-- 顶部菜单 --> <!-- 顶部菜单 -->
<view class="height80 backcorltop"> <!-- <view class="mart80" v-if="isdisplay">
<view class="category-list"> <lottie :options="defaultOptions" :height="200" :width="200"
<view class="category" style="width: 25%;" v-for="(row, index) in categoryList" :key="index" @animCreated="handleAnimation" />
@tap="toCategory(row)"> </view> -->
<view class="img"> <!-- <view class="status"></view> -->
<image :src="imageUrl+row.imgData"></image> <view v-for="(item,index) in homeCateList" :key="index">
<view class="height90 backcorltop" v-if="item.type == 1">
<view class="category-list">
<view class="category" style="width: 25%;" v-for="(row, indexs) in item.childCategory" :key="indexs"
@click="toCategory(row)">
<view class="img">
<image :src="imageUrl+row.imgData"></image>
</view>
<view class="text fcorfff">{{ row.title }}</view>
</view> </view>
<view class="text fcorfff">{{ row.title }}</view>
</view> </view>
</view> </view>
</view> <!-- 顶部活动图片 -->
<!-- 顶部活动图片 --> <image class="width100" mode="widthFix" :src="imagewxUrl+imgadres" v-if="item.type == 8"></image>
<image class="width100" mode="widthFix" :src="imagewxUrl+imgadres"></image>
<!-- 顶部菜单 --> <!-- 顶部菜单 -->
<view class="category-list backcorfff" style="margin-top: -5px;"> <view class="category-list backcorfff" style="margin-top: -5px;" v-if="item.type == 7">
<view class="category" style="width: 20%;" v-for="(row, index) in categoryList" :key="index" <view class="category" style="width: 20%;" v-for="(row, indexc) in item.childCategory" :key="indexc"
@tap="toCategory(row)"> @click="toCategory(row)">
<view class="img"> <view class="img">
<image :src="imageUrl+row.imgData"></image> <image :src="imageUrl+row.imgData"></image>
</view>
<view class="text fcor333">{{ row.title }}</view>
</view> </view>
<view class="text fcor333">{{ row.title }}</view>
</view> </view>
</view> <!-- 消息 -->
<!-- 消息 --> <view class="height120 backcorfff" v-if="item.type == 3">
<view class="height120 backcorfff"> <view class="height20 width100"></view>
<view class="height20 width100"></view> <view class="width92 message alijus">
<view class="width92 message alijus"> <view class="width100 alijus" style="margin-top: -20px;" @click="test(item.childDate)"
<swiper circular="true" autoplay="true" display-multiple-items="2" :vertical="true"> v-if="item.childDate.length == 1">
<swiper-item class="alijus" v-for="(swiper,index) in swiperList" :key="swiper.id"
@click="test(index)">
<view class="width80p paddleft10 alijusstart"> <view class="width80p paddleft10 alijusstart">
<view class="stus"></view> <view class="stus"></view>
<view class="paddleft10 font14 fcor666 text1 width70"> <view class="paddleft10 font14 fcor666 text1 width70">
放松放松方放松放松方放松放松方</view> {{item.childDate[0].title}}
<view class="width25 font13 fcor999">40分钟前</view> </view>
<view class="width25 font13 fcor999">{{swipers.timeData}}</view>
</view> </view>
<view class="width20 alijus"> <view class="width20 alijus">
<image class="icon15" mode="widthFix" src="../../../static/img/jt.png"></image> <image class="icon15" mode="widthFix" src="../../../static/img/jt.png"></image>
</view> </view>
</swiper-item> </view>
</swiper> <swiper v-else circular="true" autoplay="true" display-multiple-items="2" :vertical="true">
<swiper-item class="alijus" v-for="(swipers,index) in item.childDate" :key="swipers.id"
@click="test(index)">
<view class="width80p paddleft10 alijusstart">
<view class="stus"></view>
<view class="paddleft10 font14 fcor666 text1 width70">
{{swipers.title}}
</view>
<view class="width25 font13 fcor999">{{swipers.timeData}}</view>
</view>
<view class="width20 alijus">
<image class="icon15" mode="widthFix" src="../../../static/img/jt.png"></image>
</view>
</swiper-item>
</swiper>
</view>
</view> </view>
</view>
<!-- 轮播图 --> <!-- 轮播图 -->
<view class="swiper mart20"> <view class="swiper mart20" v-if="item.type == 2">
<view class="swiper-box"> <view class="swiper-box">
<swiper circular="true" autoplay="true" @change="swiperChange"> <swiper circular="true" autoplay="true" @change="swiperChange">
<swiper-item v-for="swiper in swiperList" :key="swiper.id"> <swiper-item v-for="swiper in item.childCategory" :key="swiper.id">
<image :src="imageUrl+swiper.imgData" @click="jumplottery(swiper)"></image> <image :src="imageUrl+swiper.imgData" @click="jumplottery(swiper)"></image>
</swiper-item> </swiper-item>
</swiper> </swiper>
</view> </view>
</view>
<!-- 加油专区 -->
<view class="width90 mart20 alijusstart" @click="goGoodsList(2)">
<view class="width70 font18 fcor333">
加油专区
</view>
<view class="width30 font14 fotrt fcor666">更多</view>
</view>
<view class="width94 alijus mart20">
<view class="backcorfff spcarea">
<image mode="widthFix" class="width100" src="../../../static/img/home/home3.png"></image>
<view class="width96 fcor333 font15 fontwig6">ETC加油券</view>
<view class="width96 fcor999 font11">2020.09.21-2202.10.12</view>
<view class="width94 fcoreb5 font15 fontwig6">¥240</view>
</view>
<view class="backcorfff spcarea">
<image mode="widthFix" class="width100" src="../../../static/img/home/home3.png"></image>
<view class="width96 fcor333 font15 fontwig6">ETC加油券</view>
<view class="width96 fcor999 font11">2020.09.21-2202.10.12</view>
<view class="width94 fcoreb5 font15 fontwig6">¥240</view>
</view>
<view class="backcorfff spcarea">
<image mode="widthFix" class="width100" src="../../../static/img/home/home3.png"></image>
<view class="width96 fcor333 font15 fontwig6">ETC加油券</view>
<view class="width96 fcor999 font11">2020.09.21-2202.10.12</view>
<view class="width94 fcoreb5 font15 fontwig6">¥240</view>
</view> </view>
</view> <!-- 加油专区 ,天天好券-->
<!-- 惠享生活 --> <view class="width90 mart20 alijusstart" v-if="item.type == 6 || item.type == 9"
<view class="width90 mart20 alijusstart"> @click="goGoodsList(item.jumpUrl)">
<view class="width70 font18 fcor333"> <view class="width70 font18 fcor333">
惠享生活 {{item.name}}
</view>
<view class="width30 font14 fotrt fcor666">更多</view>
</view> </view>
</view> <view class="width94 alijus mart20" v-if="item.type == 6 ">
<image class="width90 mart10" mode="widthFix" :src="imagewxUrl+imgadres1"></image> <view class="backcorfff spcarea" v-for="(goods,index) in item.childDate" :key="index">
<view class="width90 alijusstart mart10"> <image mode="widthFix" class="width100" :src="imageUrl+goods.couponImg"></image>
<image src="../../../static/img/home/home6.png" mode="widthFix" class="width31"></image> <view class="width96 fcor333 font15 fontwig6">{{goods.couponName}}</view>
<image src="../../../static/img/home/home7.png" mode="widthFix" class="width31"></image> <view class="width96 fcor999 font11">{{goods.salesEndTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}
<image src="../../../static/img/home/home5.png" mode="widthFix" class="width31"></image> </view>
</view> <view class="width94 fcoreb5 font15 fontwig6">¥{{goods.salesPrice}}</view>
<!-- 天天好券 --> </view>
<view class="width90 mart20 alijusstart">
<view class="width70 font18 fcor333">
天天好券
</view> </view>
<view class="width30 font14 fotrt fcor666">更多</view> <view class="width94 alijus mart20" v-if="item.type == 9 ">
</view> <view class="backcorfff spcarea" v-for="(goods,index) in item.childDate" :key="index">
<view class="width94 alijus mart20"> <image mode="widthFix" class="width100" :src="imageUrl+goods.listImg"></image>
<view class="backcorfff spcarea"> <view class="width96 fcor333 font15 fontwig6">{{goods.title}}</view>
<image mode="widthFix" class="width100" src="../../../static/img/home/home4.png"></image> <view class="width96 fcor999 font11" v-if="goods.effectiveTiem">
<view class="width96 fcor333 font15 fontwig6">加油优惠券包</view> {{goods.effectiveTiem | timeFormat('yyyy-mm-dd hh:mm:ss')}}
<view class="width96 fcor999 font11">2020.09.21-2202.10.12</view> </view>
<view class="width94 fcoreb5 font15 fontwig6">¥240</view> <view class="width94 fcoreb5 font15 fontwig6">¥{{goods.price}}</view>
</view>
</view> </view>
<view class="backcorfff spcarea"> <!-- 惠享生活 -->
<image mode="widthFix" class="width100" src="../../../static/img/home/home4.png"></image> <view class="width90 mart20 alijusstart" v-if="item.type == 5">
<view class="width96 fcor333 font15 fontwig6">加油优惠券包</view> <view class="width70 font18 fcor333">
<view class="width96 fcor999 font11">2020.09.21-2202.10.12</view> 惠享生活
<view class="width94 fcoreb5 font15 fontwig6">¥240</view> </view>
</view> </view>
<view class="backcorfff spcarea"> <image class="width90 mart10" mode="widthFix" v-if="item.type == 5"
<image mode="widthFix" class="width100" src="../../../static/img/home/home4.png"></image> :src="imageUrl+item.childCategory[0].imgData" @click="goGoodsList(item.childCategory[0].jumpUrl)">
<view class="width96 fcor333 font15 fontwig6">加油优惠券包</view> </image>
<view class="width96 fcor999 font11">2020.09.21-2202.10.12</view> <view class="width90 alijusstart mart10" v-if="item.type == 5">
<view class="width94 fcoreb5 font15 fontwig6">¥240</view> <image :src="imageUrl+item.childCategory[1].imgData" mode="widthFix" class="width31"
@click="goGoodsList(item.childCategory[1].jumpUrl)"></image>
<image :src="imageUrl+item.childCategory[2].imgData" mode="widthFix" class="width31"
@click="goGoodsList(item.childCategory[2].jumpUrl)"></image>
<image :src="imageUrl+item.childCategory[3].imgData" mode="widthFix" class="width31"
@click="goGoodsList(item.childCategory[3].jumpUrl)"></image>
</view> </view>
</view> </view>
<!-- 弹窗 --> <!-- 弹窗 -->
<wybPopup ref="popup" type="center" height="850" width="600" bgColor="" radius="6" :showCloseIcon="true"> <wybPopup ref="popup" type="center" height="850" width="600" bgColor="" radius="6" :showCloseIcon="true">
@ -134,17 +133,14 @@
<script> <script>
import { import {
getUserInfo, getUserInfo,
HandleCode,
WXlogin,
getCouponList, getCouponList,
getTPigKFCToken,
getTPigCinemaToken,
getCacheParam, getCacheParam,
delCacheParam, delCacheParam,
getCmsContent, getCmsContent,
findByLatAndLng findByLatAndLng
} from "../../../Utils/Api.js"; //api } from "../../../Utils/Api.js"; //api
import wybPopup from '../../../components/wyb-popup/wyb-popup.vue'; import wybPopup from '../../../components/wyb-popup/wyb-popup.vue';
let app = getApp(); let app = getApp();
export default { export default {
components: { components: {
@ -152,13 +148,7 @@
}, },
data() { data() {
return { return {
showHeader: true,
isShowAuth: false, isShowAuth: false,
afterHeaderOpacity: 1, //
headerPosition: 'fixed',
headerTop: null,
statusTop: null,
nVueTitle: null,
city: '', city: '',
currentSwiper: 0, currentSwiper: 0,
imageUrl: app.globalData.imgUrl, imageUrl: app.globalData.imgUrl,
@ -170,18 +160,6 @@
imgadres3: '', imgadres3: '',
imgadres4: 'cusservice.png', imgadres4: 'cusservice.png',
webUrl: '', webUrl: '',
//
swiperList: [{
id: 1,
src: 'url1',
img: 'banner2.png'
},
{
id: 2,
src: 'url2',
img: 'banner3.png'
}
],
// //
productList: [], productList: [],
productListleg: '', productListleg: '',
@ -190,35 +168,16 @@
loadingText: '正在加载...', loadingText: '正在加载...',
pageNum: 1, pageNum: 1,
pageSize: 6, pageSize: 6,
// homeCateList: [],
categoryList: [{
'title': '在线加油',
'imgData': 'onRefueling1.png'
},
{
'title': '话费充值',
'imgData': 'phonePay1.png'
}, {
'title': '积分专区',
'imgData': 'petCoder.png'
},
],
homeCateList: [{
'title': '在线加油',
'imgData': 'onRefueling2.png'
},
{
'title': '话费充值',
'imgData': 'phonePay2.png'
},
],
// //
cpStuats: 1, cpStuats: 1,
jumpType: '' jumpType: '',
isdisplay: true //
}; };
}, },
onShow() { onShow() {
let that = this; let that = this;
that.hqaddress();
uni.getStorage({ uni.getStorage({
key: "user", key: "user",
success(e) { success(e) {
@ -233,10 +192,12 @@
} }
}) })
}, },
onLoad() { onLoad() {},
this.hqaddress();
},
methods: { methods: {
//
handleAnimation: function(anim) {
this.anim = anim;
},
//ID //ID
getCacheParam() { getCacheParam() {
let that = this; let that = this;
@ -276,7 +237,7 @@
}, },
test(item) { test(item) {
uni.navigateTo({ uni.navigateTo({
url:'../../user/news/news' url: '../../user/news/news'
}) })
}, },
// //
@ -286,11 +247,6 @@
upsdk.getLocationCity({ upsdk.getLocationCity({
success: function(cityCd) { success: function(cityCd) {
app.globalData.cityId = cityCd; app.globalData.cityId = cityCd;
that.getCmsAactibity();
that.getCouponListArea();
that.getCmsContent();
that.getCmsContentcmshome();
that.getCmsContentcmsContent();
}, },
fail: function(err) {} fail: function(err) {}
}); });
@ -301,12 +257,12 @@
let zuob = JSON.parse(res); let zuob = JSON.parse(res);
app.globalData.latitude = zuob.latitude; app.globalData.latitude = zuob.latitude;
app.globalData.longitude = zuob.longitude; app.globalData.longitude = zuob.longitude;
that.findByLatAndLng(zuob.longitude,zuob.latitude); that.findByLatAndLng(zuob.longitude, zuob.latitude);
break; break;
case 'ios': case 'ios':
app.globalData.latitude = res.latitude; app.globalData.latitude = res.latitude;
app.globalData.longitude = res.longitude; app.globalData.longitude = res.longitude;
that.findByLatAndLng(res.longitude,res.latitude); that.findByLatAndLng(res.longitude, res.latitude);
break; break;
} }
@ -329,52 +285,33 @@
app.globalData.cityId = res.return_data.regionId; app.globalData.cityId = res.return_data.regionId;
// app.globalData.cityId = '520000'; // app.globalData.cityId = '520000';
app.globalData.companyId = res.return_data.companyId; app.globalData.companyId = res.return_data.companyId;
this.getCmsAactibity();
this.getCmsContentcmsContent();
} }
}); });
}, },
// //
getCmsContentcmsContent() { getCmsContentcmsContent() {
let params = { let params = {
regionId: app.globalData.cityId, companyId: app.globalData.companyId,
categoryCode: 'CMS_UNIONPAY_IMG' platform: 3,
categoryCode: 'CMS_HOME'
} }
getCmsContent(params).then(res => { getCmsContent(params).then(res => {
this.isdisplay = false;
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.homeCateList = res.return_data; this.homeCateList = res.return_data;
} }
}); });
}, },
// //
getCmsContentcmshome() {
let params = {
regionId: app.globalData.cityId,
categoryCode: 'CMS_UNIONPAY_FAST'
}
getCmsContent(params).then(res => {
if (res.return_code == '000000') {
this.categoryList = res.return_data;
}
});
},
//
getCmsContent() {
let params = {
regionId: app.globalData.cityId,
categoryCode: 'CMS_UNIONPAY_BANNER'
}
getCmsContent(params).then(res => {
if (res.return_code == '000000') {
this.swiperList = res.return_data;
}
});
},
getCmsAactibity() { getCmsAactibity() {
uni.showToast({ uni.showToast({
title: '加载中...' title: '加载中...'
}) })
let params = { let params = {
regionId: app.globalData.cityId, companyId: app.globalData.companyId,
platform: 3,
categoryCode: 'CMS_UNIONPAY_ALERT' categoryCode: 'CMS_UNIONPAY_ALERT'
} }
getCmsContent(params).then(res => { getCmsContent(params).then(res => {
@ -436,25 +373,6 @@
url: '../../goods/goods?id=' + e url: '../../goods/goods?id=' + e
}); });
}, },
//
getCouponListArea() {
let params = {
regionId: app.globalData.cityId,
pageNum: this.pageNum,
pageSize: this.pageSize,
displayArea: 3
}
getCouponList(params).then(res => {
if (res.return_code == '000000' && res.return_data.list) {
this.productList = res.return_data.list;
if (res.return_data.total > 4) {
this.productListleg = 4;
return;
}
this.productListleg = res.return_data.total;
}
})
},
// //
getCouponListgold() { getCouponListgold() {
let params = { let params = {
@ -500,8 +418,11 @@
swiperChange(event) { swiperChange(event) {
this.currentSwiper = event.detail.current; this.currentSwiper = event.detail.current;
}, },
eheckStu(item) { //
this.cpStuats = item; toCategory(item) {
uni.navigateTo({
url: item.jumpUrl
})
}, },
// //
jumplottery(item) { jumplottery(item) {
@ -511,16 +432,10 @@
}) })
} }
}, },
//
jumphuafei(item) {
uni.navigateTo({
url: item.ext1
})
},
// //
goGoodsList(item) { goGoodsList(item) {
uni.navigateTo({ uni.navigateTo({
url: '/pages/goods/goods-list/goods-list?id=' + item url: item
}) })
}, },
}, },

@ -48,21 +48,24 @@
<uni-badge style="width: 20px;position: absolute; left: 42%;" <uni-badge style="width: 20px;position: absolute; left: 42%;"
v-if="row.text == '已支付' && orderPayNum " :text="orderPayNum" type="error" size="normal"> v-if="row.text == '已支付' && orderPayNum " :text="orderPayNum" type="error" size="normal">
</uni-badge> </uni-badge>
<uni-badge style="width: 20px;position: absolute; left: 63%;"
v-if="row.text == '已完成' && whetherCheckNum " :text="whetherCheckNum" type="error" size="normal">
</uni-badge>
<view class="img"> <view class="img">
<image :src="row.icon" class="icon40" mode="widthFix"></image> <image :src="row.icon" class="icon40" mode="widthFix"></image>
</view> </view>
<view class="text mart10">{{row.text}}</view> <view class="text mart10">{{row.text}}</view>
</view> </view>
</view> </view>
<view class="width90 mart10 height60"> <view class="width90 mart10 height60" v-if="nopaylist != ''">
<swiper circular="true" interval="3000" autoplay="true"> <swiper circular="true" interval="3000" autoplay="true" @change="swiperChange">
<swiper-item v-for="(swiper,index) in nopaylist" :key="index"> <swiper-item v-for="(swiper,index) in nopaylist" :key="index" @click="jumpDetails(swiper.orderNo,swiper.productType)">
<view class="alijusstart border-8r backcor9 height60 "> <view class="alijusstart border-8r backcor9 height60 ">
<image mode="widthFix" class="icon40 margle10" src="../../../static/img/user/user5.png"> <image mode="widthFix" class="icon40 margle10" src="../../../static/img/user/user5.png">
</image> </image>
<view class="width50 margle10"> <view class="width50 margle10">
<view class="font15 fcor333 fontspec">等待付款</view> <view class="font15 fcor333 fontspec">等待付款</view>
<view class="font12 fcor666 fontspec mart5">剩余时间: 13:44</view> <view class="font12 fcor666 fontspec mart5">剩余时间: {{countdownm}}:{{countdowns}}</view>
</view> </view>
<view class="topay"> <view class="topay">
去支付 去支付
@ -90,17 +93,19 @@
<view class="mart15 width90 alijus fotct paddbotm10"> <view class="mart15 width90 alijus fotct paddbotm10">
<view class="width31"> <view class="width31">
<view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 2">****</view> <view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 2">****</view>
<view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 1">¥2400</view> <view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 1">{{userAccount.integral}}</view>
<view class="fontspec font14 fcor333 mart5">积分余额</view> <view class="fontspec font14 fcor333 mart5">积分余额</view>
</view> </view>
<view class="width31"> <view class="width31">
<view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 2">****</view> <view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 2">****</view>
<view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 1">¥2400</view> <view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 1">¥{{userAccount.oilCardPrice}}
</view>
<view class="fontspec font14 fcor333 mart5">油卡余额</view> <view class="fontspec font14 fcor333 mart5">油卡余额</view>
</view> </view>
<view class="width31"> <view class="width31">
<view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 2">****</view> <view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 2">****</view>
<view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 1">¥2400</view> <view class="fontspec font20 fcor333 fontwig6" v-if="assetsstu == 1">¥{{userAccount.hltCardPrice}}
</view>
<view class="fontspec font14 fcor333 mart5">工会卡余额</view> <view class="fontspec font14 fcor333 mart5">工会卡余额</view>
</view> </view>
</view> </view>
@ -150,8 +155,10 @@
</template> </template>
<script> <script>
import { import {
GetPhoneNumber, findUser,
findUser getUserAccount,
getUserOrderList,
orderCheck
} from "../../../Utils/Api.js"; } from "../../../Utils/Api.js";
import uniBadge from "../../../components/uni-badge/components/uni-badge/uni-badge.vue"; import uniBadge from "../../../components/uni-badge/components/uni-badge/uni-badge.vue";
let app = getApp() let app = getApp()
@ -191,9 +198,12 @@
], ],
// //
czList: '', czList: '',
nopaylist: [1, 2, 3, 4, 5], nopaylist: [], //
assetsstu: 2, assetsstu: 2,
userphone:'' // userphone:'' ,//
userAccount: '', //,
countdownm: '', //
countdowns: '', //
} }
}, },
//page.json "enablePullDownRefresh": true //page.json "enablePullDownRefresh": true
@ -276,25 +286,50 @@
} }
}); });
}, },
getPhoneNumber(PhoneNumber) { //
getUserOrderList() {
uni.showLoading({
title: '加载中...'
})
let params = { let params = {
openId: app.globalData.openId, status: 1,
iv: PhoneNumber.detail.iv, pageNum: 1,
encryptedData: PhoneNumber.detail.encryptedData pageSize: 5
} }
GetPhoneNumber(params).then(res => { getUserOrderList(params).then(res => {
if (res.return_code == '000000') { uni.hideLoading();
app.globalData.userInfo = res.return_data if (res.return_code == '000000' && res.return_data.list != '') {
.object this.nopaylist = res.return_data.list;
.highUser; this.timesettime(res.return_data.list[0].createTime);
uni.setStorage({ } else {
key: "user", this.nopaylist = [];
data: res.return_data
.object
.highUser
})
this.toDeposit();
} }
})
},
//
swiperChange(e) {
this.timesettime(this.nopaylist[e.detail.current].createTime);
},
//
jumpDetails(e, item) {
this.orderCheck(e);
if (item == 1 || item == 2 || item == 3) {
uni.navigateTo({
url: '/qianzhu-KFC/order-details/order-details?id=' + e
})
return;
}
uni.navigateTo({
url: '/pages/user/order_details/order_details?id=' + e
})
},
//
orderCheck(item) {
let datas = {
orderNo: item
}
orderCheck(datas).then(res => {
}); });
}, },
// //
@ -302,15 +337,40 @@
var reg = /^(\d{3})\d{4}(\d{4})$/; var reg = /^(\d{3})\d{4}(\d{4})$/;
this.userphone = tel.replace(reg, "$1****$2"); this.userphone = tel.replace(reg, "$1****$2");
}, },
//
timesettime(item) {
var nowtime = new Date(), //
endtime = item + 600000; //
var lefttime = endtime - nowtime, //
leftd = Math.floor(lefttime / (1000 * 60 * 60 * 24)), //
lefth = Math.floor((lefttime / (1000 * 60 * 60) % 24) + leftd * 24) < 10 ? "0" + Math.floor((lefttime /
(1000 * 60 * 60) % 24) + leftd * 24) : Math.floor((lefttime / (1000 * 60 * 60) % 24) + leftd *
24), //
leftm = Math.floor(lefttime / (1000 * 60) % 60) < 10 ? "0" + Math.floor(lefttime / (1000 * 60) % 60) :
Math.floor(lefttime / (1000 * 60) % 60), //
lefts = Math.floor(lefttime / 1000 % 60) < 10 ? "0" + Math.floor(lefttime / 1000 % 60) : Math.floor(
lefttime / 1000 % 60); //
this.countdownm = leftm //
this.countdowns = lefts //
},
// //
updatestu(item) { updatestu(item) {
if (item == 1) { if (item == 1) {
this.assetsstu = 2; this.assetsstu = 2;
} }
if (item == 2) { if (item == 2) {
this.assetsstu = 1; this.getUserAccount();
} }
}, },
//
getUserAccount() {
getUserAccount().then(res => {
if (res.return_code == '000000') {
this.assetsstu = 1;
this.userAccount = res.return_data;
}
});
},
// 广 // 广
jumppage(item) { jumppage(item) {
// if (item == 1) { // if (item == 1) {

@ -178,10 +178,10 @@
<script> <script>
import { import {
addOrderPay, create,
orderToUnionPay, unionPay,
findUser, findUser,
hltUnionCardPayghk, cardPay,
getHuiLianTongCardBalance, getHuiLianTongCardBalance,
getUserOrderPreList, getUserOrderPreList,
findById, findById,
@ -444,19 +444,24 @@
} }
let params = { let params = {
"childOrderList": [{
"goodsId": that.objectId,
"goodsType": 6,
"rechargeContent": that.rechargeContent,
"saleCount": 1
}],
"payGold": that.priceValue[1],
"companyId": app.globalData.companyId,
"memDiscountId": that.memDiscountId, "memDiscountId": that.memDiscountId,
"rechargeContent": that.rechargeContent, "payPwd": ""
"goodsId": that.objectId,
"integralNum": that.priceValue[1],
"password": ''
} }
uni.showLoading({ uni.showLoading({
title: '加载中...' title: '加载中...'
}) })
addOrderPay(params).then(res => { create(params).then(res => {
uni.hideLoading() uni.hideLoading()
if (res.return_code == '000000') { if (res.return_code == '000000') {
that.orderToUnionPay(res.return_data.id); that.orderToUnionPay(res.return_data.orderNo);
} else { } else {
uni.showToast({ uni.showToast({
title: res.return_msg, title: res.return_msg,
@ -468,9 +473,9 @@
// //
orderToUnionPay(item) { orderToUnionPay(item) {
let params = { let params = {
"orderId": item "orderNo": item
} }
orderToUnionPay(params).then(res => { unionPay(params).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.uniontopay(res.return_data.prepayid, item); this.uniontopay(res.return_data.prepayid, item);
} else { } else {
@ -590,16 +595,21 @@
} }
if (this.payPrice == 0) { if (this.payPrice == 0) {
let params = { let params = {
"memDiscountId": this.memDiscountId, "childOrderList": [{
"rechargeContent": this.rechargeContent, "goodsId": that.objectId,
"goodsId": this.objectId, "goodsType": 6,
"integralNum": this.priceValue[1], "rechargeContent": that.rechargeContent,
"password": this.PaymentPassword "saleCount": 1
}],
"payGold": that.priceValue[1],
"companyId": app.globalData.companyId,
"memDiscountId": that.memDiscountId,
"payPwd": ""
} }
addOrderPay(params).then(res => { create(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.orderId = res.return_data.id; this.orderId = res.return_data.orderNo;
uni.reLaunch({ uni.reLaunch({
url: '../Phone-recharge-details/Phone-recharge-details?id=' + url: '../Phone-recharge-details/Phone-recharge-details?id=' +
this.orderId this.orderId
@ -621,11 +631,11 @@
return; return;
} }
let params = { let params = {
"orderId": this.orderId, "orderNo": this.orderId,
"cardNo": this.user.hltCardNo.cardNo, "cardNo": this.user.hltCardNo.cardNo,
"password": this.PaymentPassword "password": this.PaymentPassword
} }
hltUnionCardPayghk(params).then(res => { cardPay(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.showToast({ uni.showToast({

@ -70,9 +70,6 @@
orderToPay, orderToPay,
unionPay unionPay
} from "../../../Utils/Api.js"; } from "../../../Utils/Api.js";
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
export default { export default {
data() { data() {
return { return {

@ -1,37 +1,51 @@
<template> <template>
<view> <view>
<!-- 顶部类型 --> <!-- 顶部类型 -->
<scroll-view scroll-x='true' class="srollview width100" scroll-with-animation> <scroll-view scroll-x='true' class="srollview width100" :style="{top:headerTop}" scroll-with-animation>
<view class="conent" :class="[newstypeid == index ? 'activeconent' : 'frontconent']" <view class="conent" :class="[newstypeid == item.codeValue ? 'activeconent' : 'frontconent']"
v-for="(item,index) in newsTyplist" :key="index">{{item}}</view> v-for="(item,index) in newsTyplist" :key="index" @click="queryMsgByList(item.codeValue)">
{{item.codeName}}</view>
</scroll-view> </scroll-view>
<view class="mart10 height70"></view> <view class="mart10 height70"></view>
<!-- 内容 --> <!-- 内容 -->
<view class="newscont width90 border-8r backcorfff mart20" v-for="(item,index) in newsTyplist" :key="index">
<view class="alijusstart mart10 margle10"> <view v-if="newsList == ''"
<image src="../../../static/img/cusservice.png" mode="widthFix" class="icon30"></image> class="mart60 fotct font14 fcor666">
<image mode="widthFix" style="width: 70vw;" :src="imagewxUrl+imgadres"></image>
</view>
<view class="newscont width90 border-8r backcorfff mart20" v-for="(item,index) in newsList" :key="index">
<view class="alijusstart mart10 margle10" v-if="item.type == 1">
<image src="../../../static/img/user/notive.png" mode="widthFix" class="icon30"></image>
<text class="font18 margle" style="color: #0B1D83;">服务通知</text> <text class="font18 margle" style="color: #0B1D83;">服务通知</text>
</view> </view>
<view class="alijusstart mart10 margle10" v-if="item.type == 2">
<image src="../../../static/img/user/order.png" mode="widthFix" class="icon30"></image>
<text class="font18 margle" style="color: #0B1D83;">交易信息</text>
</view>
<view class="alijusstart mart10 margle10" v-if="item.type == 3">
<image src="../../../static/img/user/kefu.png" mode="widthFix" class="icon30"></image>
<text class="font18 margle" style="color: #0B1D83;">客服消息</text>
</view>
<view class="width90 line1 mart10"></view> <view class="width90 line1 mart10"></view>
<!-- 服务通知 --> <!-- 服务通知 -->
<view class="width90 mart20" v-if="index != 1"> <view class="width90 mart20" v-if="item.type == 1">
<view class="font18 fcor333">最新电影已上映快来抢购</view> <view class="font18 fcor333">{{item.title}}</view>
<image mode="widthFix" class="width100 mart10" src="../../../static/img/user/1.png"></image> <image mode="widthFix" class="width100 mart10" :src="imageUrl+item.image"></image>
</view> </view>
<!-- 交易信息 --> <!-- 交易信息 -->
<view class="width90 mart20" v-if="index == 1"> <view class="width90 mart20" v-if="item.type == 2">
<view class="font18 fcor333">付款成功</view> <view class="font18 fcor333" >{{item.title}}</view>
<view class="mart10 border-r backcor9"> <view class="mart10 border-r backcor9">
<view class="font20 colore95 fontwig6 paddtop10 fotct">¥9.58</view> <view class="font20 colore95 fontwig6 paddtop10 fotct">¥{{item.content | msgFormat('price')}}</view>
<view class="width94 mart10 alijusstart font14"> <view class="width94 mart10 alijusstart font14">
<view class="fontwig6 fcor333 width30">交易对象</view> <view class="fontwig6 fcor333 width30">交易对象</view>
<view class="width70 fcor666 fotrt">电信话费充值200元</view> <view class="width70 fcor666 fotrt">{{item.content | msgFormat('objectName') }}</view>
</view> </view>
<view class="width94 mart15 alijusstart font14"> <view class="width94 mart15 alijusstart font14">
<view class="fontwig6 fcor333 width30">交易时间</view> <view class="fontwig6 fcor333 width30">交易时间</view>
<view class="width70 fcor666 fotrt">2022年9月30日</view> <view class="width70 fcor666 fotrt">{{item.content | msgFormat('time') }}</view>
</view> </view>
<view class="font16 fcor666 alijus mart10 fotct paddbotm20">查看详情<image <view class="font16 fcor666 alijus mart10 fotct paddbotm20">查看详情<image
src="../../../static/img/jt.png" mode="widthFix" class="icon15 margle"></image> src="../../../static/img/jt.png" mode="widthFix" class="icon15 margle"></image>
@ -40,11 +54,11 @@
</view> </view>
<!-- 客服消息 --> <!-- 客服消息 -->
<view class="width90 mart20" v-if="index == 2"> <view class="width90 mart20" v-if="item.type == 3">
<view class="font18 fcor333">客服消息提醒</view> <view class="font18 fcor333">{{item.title}}</view>
<view class="mart10 border-r backcor9"> <view class="mart10 border-r backcor9">
<view class="width92 fcor333 fontwig6 paddtop15"> <view class="width92 fcor333 fontwig6 paddtop15">
你的问题我们已提交技术人员处理请耐心等候 {{item.content}}
</view> </view>
<view class="font16 fcor666 alijus mart10 fotct paddbotm20">查看详情<image <view class="font16 fcor666 alijus mart10 fotct paddbotm20">查看详情<image
@ -58,17 +72,62 @@
</template> </template>
<script> <script>
import {
queryMsgByList,
getDictionaryByCodeType
} from '../../../Utils/Api.js';
let app = getApp();
export default { export default {
data() { data() {
return { return {
newsTyplist: ['全部订单', '在线加油', '肯德基', '星巴克', '话费充值', '卡券订单'], // imageUrl: app.globalData.imgUrl,
newstypeid: 1 ,//id imagewxUrl: app.globalData.imageWxImg,
imgadres: 'noorder.png',
newsTyplist: [], //
newsList: [], //
newstypeid: 1, //id
headerTop: '0px'
}
},
filters: {
//
msgFormat: function(value,value1) {
let a = JSON.parse(value);
return a[value1];
} }
}, },
onLoad() { onLoad() {
this.getDictionaryByCodeType();
}, },
methods: { methods: {
//
getDictionaryByCodeType() {
let datas = {
codeType: 'MSG_TYPE'
}
getDictionaryByCodeType(datas).then(res => {
if (res.return_code == '000000') {
this.newsTyplist = res.return_data;
this.newstypeid = res.return_data[0].codeValue;
this.queryMsgByList(res.return_data[0].codeValue);
}
})
},
//
queryMsgByList(item) {
this.newstypeid = item;
let datas = {
companyId: app.globalData.companyId,
type: item
}
queryMsgByList(datas).then(res => {
if (res.return_code == '000000' && res.return_data) {
this.newsList = res.return_data;
}else{
this.newsList = [];
}
})
}
} }
} }
</script> </script>
@ -80,7 +139,6 @@
.srollview { .srollview {
position: fixed; position: fixed;
top: 0px;
height: 70px; height: 70px;
background-color: #ffffff; background-color: #ffffff;
display: flex; display: flex;

@ -14,94 +14,103 @@
<view class="width100 font18 fcorfff fotct height40p"> <view class="width100 font18 fcorfff fotct height40p">
{{typeText[recinfo.orderStatus]}} {{typeText[recinfo.orderStatus]}}
</view> </view>
<view class="width90 fcorfff font18 mart10">实付:{{recinfo.payRealPrice}}</view> <view class="width90 fcorfff font18 mart10" v-if="recinfo.payRealPrice">实付:{{recinfo.payRealPrice}}</view>
<view class="width90 fcorfff font14 mart10">{{recinfo.createTime | formatDate('-')}}</view> <view class="width90 fcorfff font14 mart10">{{recinfo.createTime | formatDate('-')}}</view>
<view class="width90 mart20" style="border-bottom: 1px dashed #7BC1F5;"></view> <view class="width90 mart20" style="border-bottom: 1px dashed #7BC1F5;"></view>
<view class="width90 mart20 alijusnostart font12"> <view class="width90 mart20 alijusnostart font12">
<view class="paddleft5 paddtright5 border-r" style="border: 1px solid #5BB5F3;color: #5BB5F3;">本单优惠 <view class="paddleft5 paddtright5 border-r" style="border: 1px solid #5BB5F3;color: #5BB5F3;">本单优惠
</view> </view>
<view class="fcorfff margle">立减-¥8.15</view> <view class="fcorfff margle">立减-¥{{recinfo.totalDeductionPrice}}</view>
</view>
<view class="width90 mart20 backcorfff height50 fcor333 font15 border-8r">
<view class="width94">感谢您信任嗨森逛欢迎再次消费</view>
</view> </view>
<view class="width90 mart20 paddleft10 backcorfff height50 fcor333 font15 border-8r">感谢您信任嗨森逛欢迎再次消费</view>
</view> </view>
<!-- 订单信息 --> <!-- 订单信息 -->
<view class="width90 backcorfff border-8r mart10 paddbotm15"> <view class="width90 backcorfff border-8r mart10 paddbotm15">
<view class="paddtop20 font22 width94 fcor333">商家/订单信息</view> <view class="paddtop20 font22 width94 fcor333" v-if="recinfo.productType == 6">商家/订单信息</view>
<view class="paddtop20 font22 width94 fcor333" v-if="recinfo.productType != 6">订单信息</view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94">
<view class="width20 fcor777">交易单号</view> <view class="width20 fcor777">交易单号</view>
<view class="width80p fotrt fcor333">HF202220823829374671902</view> <view class="width80p fotrt fcor333">{{recinfo.orderNo}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.paySerialNo">
<view class="width20 fcor777">流水号</view> <view class="width20 fcor777">流水号</view>
<view class="width80p fotrt fcor333">433423423425123123123211</view> <view class="width80p fotrt fcor333">{{recinfo.paySerialNo}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94">
<view class="width20 fcor777">下单时间</view> <view class="width20 fcor777">下单时间</view>
<view class="width80p fotrt fcor333">2022-09-06 10:36:38</view> <view class="width80p fotrt fcor333">{{recinfo.createTime | formatDate('-')}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType == 6">
<view class="width20 fcor777">油站名称</view> <view class="width20 fcor777">油站名称</view>
<view class="width80p fotrt fcor333">延长壳牌南充亚华加油站</view> <view class="width80p fotrt fcor333">{{oilList.storeName}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.payType">
<view class="width20 fcor777">支付方式</view> <view class="width20 fcor777">支付方式</view>
<view class="width80p fotrt fcor333">微信</view> <view class="width80p fotrt fcor333" v-if="recinfo.payType == 1">支付宝</view>
<view class="width80p fotrt fcor333" v-if="recinfo.payType == 2">微信</view>
<view class="width80p fotrt fcor333" v-if="recinfo.payType == 4">汇联通工会卡</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType == 6">
<view class="width20 fcor777">地址</view> <view class="width20 fcor777">地址</view>
<view class="width80p fotrt fcor333 text1">四川省南充市顺庆区金鱼领路541号1</view> <view class="width80p fotrt fcor333 text1">{{oilList.storeAddress}}</view>
</view> </view>
</view> </view>
<!-- 商品信息 --> <!-- 商品信息 -->
<view class="width90 backcorfff border-8r mart10 paddbotm15"> <view class="width90 backcorfff border-8r mart10 paddbotm15">
<view class="paddtop20 font22 width94 fcor333">商品信息</view> <view class="paddtop20 font22 width94 fcor333">商品信息</view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType != 6">
<view class="width50 fcor777">商品名称</view> <view class="width50 fcor777">商品名称</view>
<view class="width50 fotrt fcor333">100元电信话费充值</view> <view class="width50 fotrt fcor333">{{recinfo.highChildOrderList[0].goodsName}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType != 6">
<view class="width50 fcor777">商品单价</view> <view class="width50 fcor777">商品单价</view>
<view class="width50 fotrt fcor333">¥99.00</view> <view class="width50 fotrt fcor333">¥{{recinfo.highChildOrderList[0].goodsPrice}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType != 6">
<view class="width50 fcor777">商品数量</view> <view class="width50 fcor777">商品数量</view>
<view class="width50 fotrt fcor333">2</view> <view class="width50 fotrt fcor333">{{recinfo.highChildOrderList[0].saleCount}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType != 6">
<view class="width50 fcor777">商品总金额</view> <view class="width50 fcor777">商品总金额</view>
<view class="width50 fotrt fcor333">¥188.00</view> <view class="width50 fotrt fcor333">¥{{recinfo.highChildOrderList[0].totalActualPrice}}</view>
</view> </view>
<!-- <view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType == 6">
<view class="width50 fcor777">油号/枪号</view> <view class="width50 fcor777">油号/枪号</view>
<view class="width50 fotrt fcor333">92#/25号枪</view> <view class="width50 fotrt fcor333">{{oilList.gasOilNo}}#/{{oilList.gasGunNo}}号枪</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType == 6">
<view class="width50 fcor777">油站单价</view> <view class="width50 fcor777">油站单价</view>
<view class="width50 fotrt fcor333">¥7.14/L</view> <view class="width50 fotrt fcor333">¥{{oilList.gasPriceGun}}/L</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType == 6">
<view class="width70 fcor777">加油升数<text class="font11 fcor999">实际升数以油站加油机为准</text> </view> <view class="width70 fcor777">加油升数<text class="font11 fcor999">实际升数以油站加油机为准</text> </view>
<view class="width30 fotrt fcor333">44.12</view> <view class="width30 fotrt fcor333">{{oilList.gasOilLiters}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94" v-if="recinfo.productType == 6">
<view class="width50 fcor777">加油金额</view> <view class="width50 fcor777">加油金额</view>
<view class="width50 fotrt fcor333">¥315.00</view> <view class="width50 fotrt fcor333">¥{{oilList.gasRefuelPrice}}</view>
</view> --> </view>
</view> </view>
<!-- 支付信息 --> <!-- 支付信息 -->
<view class="width90 backcorfff mart10 concont"> <view class="width90 backcorfff mart10 concont">
<view class="paddtop20 font22 width94 fcor333">商品信息</view> <view class="paddtop20 font22 width94 fcor333">优惠信息</view>
<view class="mart15 alijusstart font14 width94">
<view class="width50 fcor777">商品优惠</view>
<view class="width50 fotrt fcoreb5">-¥{{recinfo.deductionProductPrice}}</view>
</view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94">
<view class="width50 fcor777">加油优惠</view> <view class="width50 fcor777">优惠券优惠</view>
<view class="width50 fotrt fcoreb5">-¥2.86</view> <view class="width50 fotrt fcoreb5">-¥{{recinfo.deductionCouponPrice}}</view>
</view> </view>
<view class="mart15 alijusstart font14 width94"> <view class="mart15 alijusstart font14 width94">
<view class="width50 fcor777">积分抵扣</view> <view class="width50 fcor777">积分抵扣</view>
<view class="width50 fotrt fcoreb5">-¥1.86</view> <view class="width50 fotrt fcoreb5">-¥{{recinfo.payGold / 100}}</view>
</view> </view>
<view class="width95 height20 borderleft alijusnostart"> <view class="width95 height20 borderleft alijusnostart">
<view style="width: 5%;"></view> <view style="width: 5%;"></view>
@ -112,7 +121,10 @@
<view class="width90w height20 bordertopleft alijusnostart"> <view class="width90w height20 bordertopleft alijusnostart">
</view> </view>
<view class="width90 height50 fotrt fcor777 font16 paddbotm10"> <view class="width90 height50 fotrt fcor777 font16 paddbotm10" v-if="!recinfo.payRealPrice">
</view>
<view class="width90 height50 fotrt fcor777 font16 paddbotm10" v-else>
加油实付 <text class="font24 fcor333 margle">{{recinfo.payRealPrice}}</text> 加油实付 <text class="font24 fcor333 margle">{{recinfo.payRealPrice}}</text>
</view> </view>
</view> </view>
@ -414,7 +426,7 @@
</image>{{recinfo.payPrice*100}} </image>{{recinfo.payPrice*100}}
</view> </view>
</view> </view>
<view class="btn" @tap="cancelOrder" style="border: 1px solid #0083f5;color: #0083f5;">取消订单</view> <view class="btn" @tap="cancel" style="border: 1px solid #0083f5;color: #0083f5;">取消订单</view>
<view class="btn" @tap="toPay" style="background-color: #0083f5;color: #fff;">去支付</view> <view class="btn" @tap="toPay" style="background-color: #0083f5;color: #fff;">去支付</view>
</view> </view>
</view> </view>
@ -430,10 +442,11 @@
<script> <script>
import { import {
getOrderById, getDetailByOrderNo,
cancelOrder, cancel,
getPreByOrderIdId, getPreByOrderIdId,
orderComplete orderComplete,
getOrderByOrderNo
} from '../../../Utils/Api.js'; } from '../../../Utils/Api.js';
let app = getApp() let app = getApp()
export default { export default {
@ -448,6 +461,7 @@
deduction: 0, // deduction: 0, //
recinfo: [], recinfo: [],
orderId: '', orderId: '',
timers: null, //
imageUrl: app.globalData.imgUrl, imageUrl: app.globalData.imgUrl,
imagewxUrl: app.globalData.imageWxImg, imagewxUrl: app.globalData.imageWxImg,
imgadres1: 'dhf.png', imgadres1: 'dhf.png',
@ -456,6 +470,7 @@
countdownm: '', // countdownm: '', //
countdowns: '', // countdowns: '', //
timer: null, // timer: null, //
oilList: '', //
typeText: { typeText: {
1: '待支付', 1: '待支付',
2: '已支付', 2: '已支付',
@ -470,21 +485,20 @@
}, },
onShow() { onShow() {
// //
this.getOrderById(); this.getDetailByOrderNo();
this.getPreByOrderIdId(); // this.getPreByOrderIdId();
}, },
onHide() { onHide() {
}, },
onUnload() { onUnload() {
clearInterval(this.timer); clearInterval(this.timers);
}, },
onLoad(option) { onLoad(option) {
this.orderId = option.id this.orderId = option.id
}, },
onBackPress() { onBackPress() {
//退 //退
this.clearOrder();
}, },
filters: { filters: {
toFixed: function(x) { toFixed: function(x) {
@ -516,19 +530,39 @@
} }
}, },
getOrderById() { //
getDetailByOrderNo() {
uni.showLoading({ uni.showLoading({
title: '加载中...' title: '加载中...'
}) })
let params = { let params = {
orderId: this.orderId, orderNo: this.orderId,
} }
getOrderById(params).then(res => { getDetailByOrderNo(params).then(res => {
uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.hideLoading();
this.recinfo = res.return_data; this.recinfo = res.return_data;
} else { if (res.return_data.productType == 6) {
uni.hideLoading() this.getOrderByOrderNo();
}
if (res.return_data.orderStatus == 1) {
this.timers = setInterval(() => {
this.showtime()
})
}
}
})
},
//
getOrderByOrderNo() {
let params = {
orderNo: this.orderId,
}
getOrderByOrderNo(params).then(res => {
uni.hideLoading();
if (res.return_code == '000000') {
this.oilList = res.return_data;
} }
}) })
}, },
@ -546,7 +580,7 @@
// //
showtime() { showtime() {
var nowtime = new Date(), // var nowtime = new Date(), //
endtime = this.orderList.createTime + 900000; // endtime = this.recinfo.createTime + 600000; //
var lefttime = endtime - nowtime, // var lefttime = endtime - nowtime, //
leftd = Math.floor(lefttime / (1000 * 60 * 60 * 24)), // leftd = Math.floor(lefttime / (1000 * 60 * 60 * 24)), //
lefth = Math.floor((lefttime / (1000 * 60 * 60) % 24) + leftd * 24) < 10 ? "0" + Math.floor((lefttime / lefth = Math.floor((lefttime / (1000 * 60 * 60) % 24) + leftd * 24) < 10 ? "0" + Math.floor((lefttime /
@ -561,8 +595,8 @@
this.countdowns = lefts // this.countdowns = lefts //
// 00:00:00 // 00:00:00
if (lefttime < 0) { if (lefttime < 0) {
this.getThirdOrderByOrderId(); clearInterval(this.timers);
clearInterval(this.timer); // this.getDetailByOrderNo();
this.countdownh = this.countdownm = this.countdowns = "00" this.countdownh = this.countdownm = this.countdowns = "00"
} }
}, },
@ -604,7 +638,7 @@
} }
}); });
}, },
cancelOrder() { cancel() {
let that = this; let that = this;
uni.showModal({ uni.showModal({
title: '取消订单', title: '取消订单',
@ -615,9 +649,9 @@
title: '加载中...' title: '加载中...'
}) })
let params = { let params = {
orderId: this.recinfo.id orderNo: this.recinfo.orderNo
} }
cancelOrder(params).then(res => { cancel(params).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.hideLoading(); uni.hideLoading();
uni.showToast({ uni.showToast({
@ -644,15 +678,6 @@
} }
}); });
}, },
clearOrder() {
uni.removeStorage({
key: 'buylist',
success: (res) => {
this.buylist = [];
console.log('remove buylist success');
}
});
},
toPay() { toPay() {
let payTypes; let payTypes;
if (this.recinfo.payType == 1 || this.recinfo.payType == null) { if (this.recinfo.payType == 1 || this.recinfo.payType == null) {

@ -1,7 +1,7 @@
<template> <template>
<view> <view>
<!-- 搜索 --> <!-- 搜索 -->
<view class="backcorfff width100 height120" style="position: fixed;z-index: 999;" :style="{top:headerTop}" > <view class="backcorfff width100 height120" style="position: fixed;z-index: 999;" :style="{top:headerTop}">
<view class="alijusstart"> <view class="alijusstart">
<view class="input-box"> <view class="input-box">
<view class="icon search"></view> <view class="icon search"></view>
@ -21,8 +21,9 @@
</view> </view>
<scroll-view scroll-x='true' :style="{top:headerswper}" class="srollview width100" scroll-with-animation> <scroll-view scroll-x='true' :style="{top:headerswper}" class="srollview width100" scroll-with-animation>
<view class="conent" :class="[ordertypeid == index ? 'activeconent' : 'frontconent']" <view class="conent" :class="[ordertypeid == item.codeValue ? 'activeconent' : 'frontconent']"
v-for="(item,index) in orderTyplist" :key="index">{{item}}</view> v-for="(item,index) in orderTyplist" :key="index" @click="selectlist(item.codeValue)">{{item.codeName}}
</view>
</scroll-view> </scroll-view>
<!-- 考虑非APP端长列表和复杂的DOM使用scroll-view会卡顿所以漂浮顶部选项卡使用page本身的滑动 --> <!-- 考虑非APP端长列表和复杂的DOM使用scroll-view会卡顿所以漂浮顶部选项卡使用page本身的滑动 -->
<view class="order-list"> <view class="order-list">
@ -31,10 +32,10 @@
<image :src="imagewxUrl+imgadres"></image> <image :src="imagewxUrl+imgadres"></image>
</view> </view>
<view class="row" v-for="(row,index) in orderList" :key="index" <view class="row" v-for="(row,index) in orderList" :key="index"
@click="jumpDetails(row.highChildOrderList[0].goodsType,row.id)"> @click="jumpDetails(row.orderNo,row.productType)">
<view class="width96 mart10 alijusstart"> <view class="width96 mart10 alijusstart">
<view class="width70"> <view class="width70">
<view class="orderlabel">在线加油</view> <view class="orderlabel">{{orderTyplist | msgFormat(row.productType)}}</view>
<view class="unread" v-if="row.orderStatus == 3 && !row.whetherCheck"></view> <view class="unread" v-if="row.orderStatus == 3 && !row.whetherCheck"></view>
</view> </view>
<view class="width30 fotrt fcor666 font12"> <view class="width30 fotrt fcor666 font12">
@ -42,11 +43,12 @@
</view> </view>
</view> </view>
<view class="width96 height25 mart10"> <view class="width96 height22 mart10">
<view class="width70 flleft fotlt "> <view class="width70 flleft fotlt ">
<view class="font16 fontwig6 text1 fcor333 alijusstart"> <view class="font16 fontwig6 fcor333 alijusstart">
<image src="../../../static/img/order5.png" class="marglerig" <image src="../../../static/img/order5.png" class="marglerig"
style="width: 50rpx;height: 50rpx;"></image>{{row.highChildOrderList[0].goodsName}} style="width: 50rpx;height: 50rpx;"></image>
<view class="width100 text1">{{row.title}}</view>
</view> </view>
</view> </view>
<view class="width30 flright fotrt fcor666 font15 fotrt"> <view class="width30 flright fotrt fcor666 font15 fotrt">
@ -59,24 +61,23 @@
订单编号:{{row.orderNo}} 订单编号:{{row.orderNo}}
</view> </view>
<view class="width96 height25 paddbotm10 alijusstart"> <view class="width96 height25 paddbotm10 alijusstart">
<view class="width70 fotlt "> <view class="width60 fotlt ">
<view class="font12 text1 fcor999 mart5"> <view class="font12 text1 fcor999 mart5">
下单时间 : {{row.createTime | formatDate('-')}} 下单时间 : {{row.createTime | formatDate('-')}}
</view> </view>
</view> </view>
<view class="width30 fotrt fcor666 font15 fotrt"> <view class="width40 fotrt fcor666 font15 fotrt alijusend">
<view class="fotrt font12 text1 fcor999 mart5"> <view class="font12 width25 fcor999">合计:</view>
合计:<text class="fcor333 font18"> {{row.payPrice}} </text> <view class="fotlt text1 font18 fcor333 ">
{{row.payPrice}}
</view> </view>
</view> </view>
</view> </view>
<view class="width96 mart10 marb5" style="border:1px dashed #f4f4f4;" <view class="width96 mart10 marb5" style="border:1px dashed #f4f4f4;" v-if="(row.orderStatus==1)">
v-if="(row.orderStatus==1 && row.highChildOrderList[0].goodsType !=6 && row.highChildOrderList[0].goodsType !=5)">
</view> </view>
<view class="btns" <view class="btns" v-if="(row.orderStatus==1)">
v-if="(row.orderStatus==1 && row.highChildOrderList[0].goodsType !=6 && row.highChildOrderList[0].goodsType !=5)">
<block> <block>
<view class="default" @click.stop="cancelOrder(row.id,row.highChildOrderList[0].goodsType)"> <view class="default" @click.stop="cancel(row.orderNo)">
取消订单 取消订单
</view> </view>
<view class="pay" @click.stop="toPayment(row)">立即支付</view> <view class="pay" @click.stop="toPayment(row)">立即支付</view>
@ -90,9 +91,9 @@
<script> <script>
import { import {
getUserOrderList, getUserOrderList,
cancelOrder, cancel,
thirdCancelOrder, orderCheck,
orderCheck getDictionaryByCodeType
} from '../../../Utils/Api.js'; } from '../../../Utils/Api.js';
let app = getApp() let app = getApp()
export default { export default {
@ -102,7 +103,7 @@
imgadres: 'noorder.png', imgadres: 'noorder.png',
imgadres1: 'dhf.png', imgadres1: 'dhf.png',
headerTop: "0px", headerTop: "0px",
headerswper:'120px', headerswper: '120px',
typeText: { typeText: {
1: '等待付款', 1: '等待付款',
2: '订单已支付', 2: '订单已支付',
@ -125,8 +126,12 @@
typeId: '', typeId: '',
imageUrl: app.globalData.imgUrl, imageUrl: app.globalData.imgUrl,
reFresh: "", reFresh: "",
orderTyplist: ['全部订单', '在线加油', '肯德基', '星巴克', '话费充值', '卡券订单'], // orderTyplist: [{
ordertypeid: 1 //id codeValue: '',
codeName: '全部'
}], //
ordertypeid: '', //id
couponName: '' //
} }
}, },
@ -140,6 +145,7 @@
this.list = this.orderList[this.typeId]; this.list = this.orderList[this.typeId];
this.tabbarIndex = tbIndex; this.tabbarIndex = tbIndex;
this.getUserOrderList(); this.getUserOrderList();
this.getDictionaryByCodeType();
}, },
onReachBottom() { onReachBottom() {
this.getUserOrderList(); this.getUserOrderList();
@ -163,6 +169,15 @@
mm = mm >= 10 ? mm : "0" + mm; mm = mm >= 10 ? mm : "0" + mm;
s = s >= 10 ? s : "0" + s; s = s >= 10 ? s : "0" + s;
return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`; return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`;
},
//
msgFormat: function(value, value1) {
for (var i = 0; i < value.length; i++) {
if (value1 == value[i].codeValue) {
let a = value[i].codeName;
return a;
}
}
} }
}, },
watch: { watch: {
@ -186,16 +201,11 @@
uni.hideLoading() uni.hideLoading()
return false; return false;
} }
let statusId;
if (this.typeId == 2) {
statusId = '2,6,7';
} else {
statusId = this.typeId;
}
let pagenum = this.pageNum; let pagenum = this.pageNum;
let params = { let params = {
status: statusId, status: this.typeId,
searchTitle: this.couponName,
productType: this.ordertypeid,
pageNum: this.pageNum, pageNum: this.pageNum,
pageSize: this.pageSize pageSize: this.pageSize
} }
@ -214,14 +224,24 @@
uni.hideLoading() uni.hideLoading()
} }
}) })
},
//
getDictionaryByCodeType() {
let datas = {
codeType: 'ORDER_PRODUCT_TYPE'
}
getDictionaryByCodeType(datas).then(res => {
if (res.return_code == '000000') {
for (var i = 0; i < res.return_data.length; i++) {
this.orderTyplist.push(res.return_data[i]);
}
}
})
}, },
// //
jumpDetails(item, e) { jumpDetails(e, item) {
console.log('===========')
this.orderCheck(e); this.orderCheck(e);
if (item == 4 || item == 9 || item == 10) { if (item == 1 || item == 2 || item == 3) {
uni.navigateTo({ uni.navigateTo({
url: '/qianzhu-KFC/order-details/order-details?id=' + e url: '/qianzhu-KFC/order-details/order-details?id=' + e
}) })
@ -235,7 +255,7 @@
// //
orderCheck(item) { orderCheck(item) {
let datas = { let datas = {
orderId: item orderNo: item
} }
orderCheck(datas).then(res => { orderCheck(datas).then(res => {
@ -253,15 +273,23 @@
} }
this.getUserOrderList(); this.getUserOrderList();
}, },
showLogistics(row) { //
selectlist(item) {
this.ordertypeid = item;
this.pageNum = 1;
this.orderList = []
this.isNoMoreData = false;
this.getUserOrderList();
}, },
remindDeliver(row) { //
uni.showToast({ toSearch() {
title: '已提醒商家发货' this.pageNum = 1;
}) this.orderList = []
this.isNoMoreData = false;
this.getUserOrderList();
}, },
cancelOrder(row, item) { //
cancel(row) {
let that = this; let that = this;
uni.showModal({ uni.showModal({
title: '取消订单', title: '取消订单',
@ -272,33 +300,9 @@
title: '加载中...' title: '加载中...'
}) })
let params = { let params = {
orderId: row, orderNo: row,
}
if (item == 9 || item == 4) {
thirdCancelOrder(params).then(res => {
if (res.return_code == '000000') {
uni.hideLoading();
uni.showToast({
title: res.return_data,
icon: 'none',
duration: 2000
})
this.pageNum = 1;
this.orderList = []
this.isNoMoreData = false;
that.getUserOrderList();
} else {
uni.showToast({
title: res.return_msg,
icon: 'none',
duration: 2000
})
uni.hideLoading()
}
})
return;
} }
cancelOrder(params).then(res => { cancel(params).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.hideLoading(); uni.hideLoading();
uni.showToast({ uni.showToast({
@ -335,19 +339,9 @@
} else { } else {
payTypes = 2; payTypes = 2;
} }
if (row.highChildOrderList[0].goodsType == 4 || row.highChildOrderList[0].goodsType == 9 || row
.highChildOrderList[0].goodsType == 10) {
uni.redirectTo({
url: '/qianzhu-KFC/payment-method/payment-method?orderId=' + row.id + '&amount=' + row
.payPrice + '&productType=' + row.productType
})
return;
}
uni.redirectTo({ uni.redirectTo({
url: "/pages/pay/payment/payment?amount=" + row.payPrice + url: '/qianzhu-KFC/payment-method/payment-method?orderId=' + row.id + '&amount=' + row
'&paytype=' + payTypes + '&orderId=' + row.id + '&couponId=' + this.orderList[0] .payPrice + '&productType=' + row.productType
.highChildOrderList[0].goodsId + '&typeaout=' + this.orderList[0].highChildOrderList[0]
.ext1 + '&goodsType=' + row.highChildOrderList[0].goodsType
}) })
} }
} }
@ -438,7 +432,6 @@
position: fixed; position: fixed;
z-index: 999; z-index: 999;
height: 50px; height: 50px;
top: 120px;
background-color: #f3f3f3; background-color: #f3f3f3;
display: flex; display: flex;
flex-direction: row; flex-direction: row;

@ -237,7 +237,7 @@
<view class="width92 height110 tccs mart10 alijus" v-for="(items, index) in OrderPreList" :key="index" <view class="width92 height110 tccs mart10 alijus" v-for="(items, index) in OrderPreList" :key="index"
@click="radioChanges(items)"> @click="radioChanges(items)">
<image mode="widthFix" :src="imageUrl+items.discountImg"></image> <image mode="widthFix" :src="imageUrl+items.discountImg"></image>
<view class="alijus width60 margle10"> <view class="alijus width60 margle10">
<view class="width80p"> <view class="width80p">
<view class="font16 fontwig6 fcor333 text1">{{items.discountName}}</view> <view class="font16 fontwig6 fcor333 text1">{{items.discountName}}</view>
<view class="font13 fcor999 mart5">有效期:{{items.useEndTime | timeFormat('yyyy-mm-dd hh:mm:ss')}} <view class="font13 fcor999 mart5">有效期:{{items.useEndTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}
@ -276,18 +276,15 @@
import ssPaymentPassword from '@/components/sanshui-payment-password/index.vue' import ssPaymentPassword from '@/components/sanshui-payment-password/index.vue'
import wybPopup from '@/components/wyb-popup/wyb-popup.vue' import wybPopup from '@/components/wyb-popup/wyb-popup.vue'
import { import {
xbkaddOrder, create,
getThirdPartyByDetail, getThirdPartyByDetail,
getHuiLianTongCardBalance, getHuiLianTongCardBalance,
findUser, findUser,
qianzhuorderToUnionPay, unionPay,
czhltUnionCardPay, cardPay,
getUserOrderPreList, getUserOrderPreList,
getRebateIntegral getRebateIntegral
} from '../../Utils/Api.js'; } from '../../Utils/Api.js';
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
let app = getApp(); let app = getApp();
export default { export default {
components: { components: {
@ -574,35 +571,47 @@
}) })
data2 = data1.join(','); data2 = data1.join(',');
datas = { datas = {
customerMobile: this.customerMobile, "childOrderList": [{
regionId: app.globalData.cityId, "goodsId": 9999,
storeCode: this.storeCode, "customerMobile": this.customerMobile,
productType: this.productType, "storeCode": this.storeCode,
platformId: this.showType, "platformId": this.showType,
orderItems: data2, "productType": this.productType,
eatType: this.sttypeid, "orderItems": data2,
integralNum: this.priceValue[1], "eatType": this.sttypeid,
memDiscountId: this.memDiscountId "goodsType": 4,
"saleCount": 1,
}],
"payGold": this.priceValue[1],
"companyId": app.globalData.companyId,
"promoteCode": this.identificationCode,
"memDiscountId": this.memDiscountId,
} }
} }
if (this.typeid == 2) { if (this.typeid == 2) {
datas = { datas = {
customerMobile: this.customerMobile, "childOrderList": [{
regionId: app.globalData.cityId, "goodsId": 9999,
storeCode: this.storeCode, "customerMobile": this.customerMobile,
productType: this.productType, "storeCode": this.storeCode,
platformId: this.showType, "platformId": this.showType,
orderItems: this.orderList, "productType": this.productType,
integralNum: this.priceValue[1], "orderItems": this.orderList,
memDiscountId: this.memDiscountId "goodsType": 9,
"saleCount": 1,
}],
"payGold": this.priceValue[1],
"companyId": app.globalData.companyId,
"promoteCode": this.identificationCode,
"memDiscountId": this.memDiscountId,
} }
} }
xbkaddOrder(datas).then(res => { create(datas).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.orderId = res.return_data.id; this.orderId = res.return_data.orderNo;
let params = { let params = {
"orderId": res.return_data.id "orderNo": res.return_data.orderNo
} }
this.qianzhuorderToUnionPay(params); this.qianzhuorderToUnionPay(params);
} else { } else {
@ -720,9 +729,9 @@
qianzhuorderToUnionPay(item) { qianzhuorderToUnionPay(item) {
let that = this; let that = this;
if (that.paytype == '4') { if (that.paytype == '4') {
qianzhuorderToUnionPay(item).then(res => { unionPay(item).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
that.uniontopay(res.return_data.prepayid); that.uniontopay(res.return_data.prepayid);
} else { } else {
uni.showToast({ uni.showToast({
title: res.return_msg, title: res.return_msg,
@ -781,7 +790,8 @@
title: '支付成功' title: '支付成功'
}) })
uni.reLaunch({ uni.reLaunch({
url: '/qianzhu-KFC/order-details/order-details?id=' + this.orderId url: '/qianzhu-KFC/order-details/order-details?id=' + this
.orderId
}) })
}, },
fail: function(err) { fail: function(err) {
@ -820,36 +830,49 @@
}) })
data2 = data1.join(','); data2 = data1.join(',');
datas = { datas = {
customerMobile: this.customerMobile, "childOrderList": [{
regionId: app.globalData.cityId, "goodsId": 9999,
storeCode: this.storeCode, "customerMobile": this.customerMobile,
productType: this.productType, "storeCode": this.storeCode,
platformId: this.showType, "platformId": this.showType,
orderItems: data2, "productType": this.productType,
eatType: this.sttypeid, "orderItems": data2,
password: this.PaymentPassword, "eatType": this.sttypeid,
integralNum: this.priceValue[1], "goodsType": 4,
memDiscountId: this.memDiscountId "saleCount": 1,
}],
"payGold": this.priceValue[1],
"companyId": app.globalData.companyId,
"promoteCode": this.identificationCode,
"memDiscountId": this.memDiscountId,
"payPwd": this.PaymentPassword
} }
} }
if (this.typeid == 2) { if (this.typeid == 2) {
datas = { datas = {
customerMobile: this.customerMobile, "childOrderList": [{
regionId: app.globalData.cityId, "goodsId": 9999,
storeCode: this.storeCode, "customerMobile": this.customerMobile,
productType: this.productType, "storeCode": this.storeCode,
platformId: this.showType, "platformId": this.showType,
orderItems: this.orderList, "productType": this.productType,
password: this.PaymentPassword, "orderItems": this.orderList,
integralNum: this.priceValue[1], "goodsType": 9,
memDiscountId: this.memDiscountId "saleCount": 1,
}],
"payGold": this.priceValue[1],
"companyId": app.globalData.companyId,
"promoteCode": this.identificationCode,
"memDiscountId": this.memDiscountId,
"payPwd": this.PaymentPassword
} }
} }
xbkaddOrder(datas).then(res => { create(datas).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.orderId = res.return_data.id; this.orderId = res.return_data.orderNo;
uni.reLaunch({ uni.reLaunch({
url: '/qianzhu-KFC/order-details/order-details?id=' + this.orderId url: '/qianzhu-KFC/order-details/order-details?id=' + this.orderId
}) })
@ -870,11 +893,11 @@
return; return;
} }
let params = { let params = {
"orderId": this.orderId, "orderNo": this.orderId,
"cardNo": this.user.hltCardNo.cardNo, "cardNo": this.user.hltCardNo.cardNo,
"password": this.PaymentPassword "password": this.PaymentPassword
} }
czhltUnionCardPay(params).then(res => { cardPay(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.showToast({ uni.showToast({

@ -21,18 +21,18 @@
</view> </view>
<view v-if="(orderList.orderStatus == 2 || orderList.orderStatus == 3 )"> <view v-if="(orderList.orderStatus == 2 || orderList.orderStatus == 3 )">
<view v-if="typeid == 4 && orderList.list && phonestu == 2"> <view v-if="typeid == 4 && recinfo.list && phonestu == 2">
<view class="width90 mart15" style="display: flow-root;"> <view class="width90 mart15" style="display: flow-root;">
<view class="fcor333 mart15 font24 fontspec width50 fotlt flleft height30h fontwig6" <view class="fcor333 mart15 font24 fontspec width50 fotlt flleft height30h fontwig6"
v-for="(item,index) in orderList.list" :key='index'>{{item.code}} v-for="(item,index) in recinfo.list" :key='index'>{{item.code}}
<text class="medldcode fcorfff border-r font11">尾号{{item.phone}}</text> <text class="medldcode fcorfff border-r font11">尾号{{item.phone}}</text>
</view> </view>
</view> </view>
</view> </view>
<view class="fotct" v-if="typeid == 4 && orderList.list && phonestu == 1"> <view class="fotct" v-if="typeid == 4 && recinfo.list && phonestu == 1">
<view class="width90 mart15" style="display: flow-root;"> <view class="width90 mart15" style="display: flow-root;">
<view class="fcor333 mart15 font24 fontspec width50 fotlt flleft height30h fontwig6" <view class="fcor333 mart15 font24 fontspec width50 fotlt flleft height30h fontwig6"
v-for="(item,index) in orderList.list" :key='index'>{{item.code}} v-for="(item,index) in recinfo.list" :key='index'>{{item.code}}
<text class="medldcode fcorfff border-r font11">取餐码</text> <text class="medldcode fcorfff border-r font11">取餐码</text>
</view> </view>
</view> </view>
@ -46,11 +46,11 @@
<view class="width94 fcor666 font12 mart5">如有询问手机尾号请点击右侧按钮查看</view> <view class="width94 fcor666 font12 mart5">如有询问手机尾号请点击右侧按钮查看</view>
</view> </view>
<view class="width30"> <view class="width30">
<view class="phoneck width85 border-r" v-if="typeid == 4 && orderList.list && phonestu == 1" <view class="phoneck width85 border-r" v-if="typeid == 4 && recinfo.list && phonestu == 1"
@click="updatestu(2)"> @click="updatestu(2)">
查看手机尾号 查看手机尾号
</view> </view>
<view class="phoneck width85 border-r" v-if="typeid == 4 && orderList.list && phonestu == 2" <view class="phoneck width85 border-r" v-if="typeid == 4 && recinfo.list && phonestu == 2"
@click="updatestu(1)"> @click="updatestu(1)">
隐藏手机尾号 隐藏手机尾号
</view> </view>
@ -59,15 +59,15 @@
</view> </view>
<!-- 星巴克 --> <!-- 星巴克 -->
<view v-if="typeid == 9 && orderList.object.orderItems[0].code"> <view v-if="typeid == 9 && recinfo.object.orderItems[0].code">
<view class="fotct font18 width100 mart10 color2f6f43" <view class="fotct font18 width100 mart10 color2f6f43"
v-for="(item,index) in orderList.object.orderItems" :key='index'>{{item.code}}</view> v-for="(item,index) in recinfo.object.orderItems" :key='index'>{{item.code}}</view>
</view> </view>
<view class="fotct font20 width100 mart10 colorc3" v-if="typeid == 4 && !orderList.list"> <view class="fotct font20 width100 mart10 colorc3" v-if="typeid == 4 && !recinfo.list">
{{orderList.statusDesc}} {{recinfo.statusDesc}}
</view> </view>
<view class="fotct font20 width100 mart10 color2f6f43" <view class="fotct font20 width100 mart10 color2f6f43"
v-if="typeid == 9 && !orderList.object.orderItems[0].code">{{orderList.statusDesc}}</view> v-if="typeid == 9 && !recinfo.object.orderItems[0].code">{{recinfo.statusDesc}}</view>
</view> </view>
</view> </view>
@ -76,7 +76,7 @@
充值明细 充值明细
</view> </view>
<view class="width94 paddtop15 font16 fontwig6 alijusstart" v-else> <view class="width94 paddtop15 font16 fontwig6 alijusstart" v-else>
<image src="../static/imgs/desloca.png" mode="widthFix" class="icon20 marglerig"></image> 南充麦当劳潆华南路餐厅 <image src="../static/imgs/desloca.png" mode="widthFix" class="icon20 marglerig"></image> {{orderList.highChildOrderList[0].storeName}}
</view> </view>
<view class="width100 mart5"> <view class="width100 mart5">
<view class="width90 alijusstart mart15" v-for="(item,index) in orderList.highChildOrderList" <view class="width90 alijusstart mart15" v-for="(item,index) in orderList.highChildOrderList"
@ -85,15 +85,15 @@
<image :src="item.goodsImg" v-if="item.goodsImg" mode="widthFix" class="width100"></image> <image :src="item.goodsImg" v-if="item.goodsImg" mode="widthFix" class="width100"></image>
<image src="../static/imgs/vipcz.png" v-else mode="widthFix" class="width90w"></image> <image src="../static/imgs/vipcz.png" v-else mode="widthFix" class="width90w"></image>
</view> </view>
<view class="width50 font13 fcor666"> <view class="width50 font13 fcor333 fontwig6">
<view>{{item.goodsName}}</view> <view>{{item.goodsName}}</view>
<view class="font12 fcor999">{{item.saleCount}} </view> <view class="font13 fcor999">{{item.saleCount}} </view>
</view> </view>
<view class="width20"> <view class="width20">
<view class="width100 fcor333 font12">¥<text <view class="width100 fcor333 font12 fotrt">¥<text
class="fontwig6 font16">{{item.goodsActualPrice}}</text> class="fontwig6 font16">{{item.goodsActualPrice}}</text>
</view> </view>
<view class="width100 fcor999 font12" v-if="item.goodsActualPrice != item.goodsPrice" <view class="width100 fcor999 font14 fotrt" v-if="item.goodsActualPrice != item.goodsPrice"
style="text-decoration: line-through;"> style="text-decoration: line-through;">
¥{{item.goodsPrice}}</view> ¥{{item.goodsPrice}}</view>
</view> </view>
@ -117,7 +117,10 @@
</view> </view>
<view class="width92 fotrt mart5 font14 fcor999"> <view class="width92 fotrt mart5 font14 fcor999">
优惠券 <text class="margle fcoreb5 font16 fontwig6">¥ {{orderList.deductionPrice}}</text> 优惠券优惠 <text class="margle fcoreb5 font16 fontwig6">¥ {{orderList.deductionCouponPrice}}</text>
</view>
<view class="width92 fotrt mart5 font14 fcor999">
商品优惠 <text class="margle fcoreb5 font16 fontwig6">¥ {{orderList.deductionProductPrice}}</text>
</view> </view>
<view class="width92 fotrt mart5 font14 fcor999"> <view class="width92 fotrt mart5 font14 fcor999">
积分抵扣 <text class="margle fcoreb5 font16 fontwig6">¥ {{(orderList.payGold / 100).toFixed(2)}}</text> 积分抵扣 <text class="margle fcoreb5 font16 fontwig6">¥ {{(orderList.payGold / 100).toFixed(2)}}</text>
@ -143,14 +146,18 @@
<view class="width30">流水号</view> <view class="width30">流水号</view>
<view class="width70 fcor333 fotrt">{{orderList.paySerialNo}}</view> <view class="width70 fcor333 fotrt">{{orderList.paySerialNo}}</view>
</view> </view>
<view class="width94 alijusstart mart20 font14 fcor666" v-if="orderList.paySerialNo"> <view class="width94 alijusstart mart20 font14 fcor666">
<view class="width30">下单时间</view> <view class="width30">下单时间</view>
<view class="width70 fcor333 fotrt">{{orderList.createTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}</view> <view class="width70 fcor333 fotrt">{{orderList.createTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}</view>
</view> </view>
<view class="width94 alijusstart mart20 font14 fcor666">
<view class="width30">支付时间</view>
<view class="width70 fcor333 fotrt">{{orderList.payTime | timeFormat('yyyy-mm-dd hh:mm:ss')}}</view>
</view>
<view class="width94 alijusstart mart20 font14 fcor666" v-if="typeid == 4"> <view class="width94 alijusstart mart20 font14 fcor666" v-if="typeid == 4">
<view class="width30">就餐方式</view> <view class="width30">就餐方式</view>
<view class="width70 fotrt" v-if="orderList.eatType == 1">店内就餐</view> <view class="width70 fotrt" v-if="recinfo.eatType == 1">店内就餐</view>
<view class="width70 fcor333 fotrt" v-if="orderList.eatType == 2">打包带走</view> <view class="width70 fcor333 fotrt" v-if="recinfo.eatType == 2">打包带走</view>
</view> </view>
<view class="width94 alijusstart mart20 font14 fcor666" v-if="orderList.payType"> <view class="width94 alijusstart mart20 font14 fcor666" v-if="orderList.payType">
<view class="width30">支付方式</view> <view class="width30">支付方式</view>
@ -173,7 +180,7 @@
<!-- 再来一单 --> <!-- 再来一单 -->
<view class="height50 width100"></view> <view class="height50 width100"></view>
<view class="bottomstu backcorfff width100 height50 alijusend"> <view class="bottomstu backcorfff width100 height50 alijusend" v-if="orderList.orderStatus == 3">
<button open-type="contact" class="cusservice font12 fcor666">联系客服</button> <button open-type="contact" class="cusservice font12 fcor666">联系客服</button>
<view class="buybtn font12 fcorfff">再来一单</view> <view class="buybtn font12 fcorfff">再来一单</view>
</view> </view>
@ -183,8 +190,9 @@
<script> <script>
import { import {
getThirdOrderByOrderId, getThirdOrderByOrderNo,
thirdCancelOrder cancel,
getDetailByOrderNo
} from '../../Utils/Api.js'; } from '../../Utils/Api.js';
export default { export default {
data() { data() {
@ -209,14 +217,15 @@
6: '退款中', 6: '退款中',
7: '退款失败' 7: '退款失败'
}, },
phonestu: 1 // phonestu: 1 ,//
recinfo: [], //
} }
}, },
onLoad(options) { onLoad(options) {
this.orderId = options.id; this.orderId = options.id;
}, },
onShow() { onShow() {
this.getThirdOrderByOrderId(); this.getDetailByOrderNo();
}, },
onUnload() { onUnload() {
clearInterval(this.timer); clearInterval(this.timer);
@ -234,15 +243,19 @@
}) })
}, },
// //
getThirdOrderByOrderId() { getDetailByOrderNo() {
// uni.showLoading({ uni.showLoading({
// title: '...' title: '加载中...'
// }) })
let datas = { let params = {
orderId: this.orderId orderNo: this.orderId,
} }
getThirdOrderByOrderId(datas).then(res => { getDetailByOrderNo(params).then(res => {
// uni.hideLoading(); uni.hideLoading();
// if (res.return_code == '000000') {
// this.recinfo = res.return_data;
// }
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.typeid = res.return_data.highChildOrderList[0].goodsType; this.typeid = res.return_data.highChildOrderList[0].goodsType;
this.orderList = res.return_data; this.orderList = res.return_data;
@ -256,6 +269,25 @@
} }
this.coutnums = 0; this.coutnums = 0;
this.getAllCount(); this.getAllCount();
this.getThirdOrderByOrderNo();
} else {
uni.showToast({
title: res.return_msg,
icon: 'none',
duration: 2000
})
}
})
},
//
getThirdOrderByOrderNo() {
let datas = {
orderNo: this.orderId
}
getThirdOrderByOrderNo(datas).then(res => {
uni.hideLoading();
if (res.return_code == '000000') {
this.recinfo = res.return_data;
} else { } else {
uni.showToast({ uni.showToast({
title: res.return_msg, title: res.return_msg,
@ -277,9 +309,9 @@
title: '加载中...' title: '加载中...'
}) })
let params = { let params = {
orderId: this.orderId, orderNo: this.orderId,
} }
thirdCancelOrder(params).then(res => { cancel(params).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.hideLoading(); uni.hideLoading();
uni.showToast({ uni.showToast({
@ -324,7 +356,7 @@
this.timerdjs = setInterval(() => { this.timerdjs = setInterval(() => {
if (holdTime <= 0) { if (holdTime <= 0) {
clearInterval(this.timerdjs); clearInterval(this.timerdjs);
this.getThirdOrderByOrderId(); this.getThirdOrderByOrderNo();
holdTime = 10; holdTime = 10;
return; return;
} }
@ -334,7 +366,7 @@
// //
showtime() { showtime() {
var nowtime = new Date(), // var nowtime = new Date(), //
endtime = this.orderList.createTime + 900000; // endtime = this.orderList.createTime + 600000; //
var lefttime = endtime - nowtime, // var lefttime = endtime - nowtime, //
leftd = Math.floor(lefttime / (1000 * 60 * 60 * 24)), // leftd = Math.floor(lefttime / (1000 * 60 * 60 * 24)), //
lefth = Math.floor((lefttime / (1000 * 60 * 60) % 24) + leftd * 24) < 10 ? "0" + Math.floor((lefttime / lefth = Math.floor((lefttime / (1000 * 60 * 60) % 24) + leftd * 24) < 10 ? "0" + Math.floor((lefttime /
@ -349,7 +381,7 @@
this.countdowns = lefts // this.countdowns = lefts //
// 00:00:00 // 00:00:00
if (lefttime < 0) { if (lefttime < 0) {
this.getThirdOrderByOrderId(); this.getThirdOrderByOrderNo();
clearInterval(this.timer); clearInterval(this.timer);
this.countdownh = this.countdownm = this.countdowns = "00" this.countdownh = this.countdownm = this.countdowns = "00"
} }

@ -76,9 +76,6 @@
} from '../../Utils/Api.js' } from '../../Utils/Api.js'
import ssPaymentPassword from '@/components/sanshui-payment-password/index.vue'; import ssPaymentPassword from '@/components/sanshui-payment-password/index.vue';
let app = getApp(); let app = getApp();
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
export default { export default {
components: { components: {
ssPaymentPassword ssPaymentPassword

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

@ -24,6 +24,13 @@
</view> </view>
</view> </view>
<view class="width94 backcorfff mart10">
<view class="width94 alijusstart height50 font14 fcor666">
<view class="width40 fcor333 fontwig6 font16" style="padding-left: 2%;">邀请码</view>
<input class="width60 fotrt font15" v-model="identificationCode" placeholder="请输入邀请码" />
</view>
</view>
<view class="width94 comorder mart10"> <view class="width94 comorder mart10">
<view class="height50 width100 backcorfff"> <view class="height50 width100 backcorfff">
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;"> <view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
@ -47,15 +54,8 @@
<view class="settlement"> <view class="settlement">
<view class="sum">实付:<view class="money">{{paytheprice}}</view> <view class="sum">实付:<view class="money">{{paytheprice}}</view>
</view> </view>
<!-- #ifdef MP -->
<button class="btn" open-type="getPhoneNumber" v-if="user == null"
@getphonenumber="loginByPhone">立即支付</button>
<button class="btn" v-else @tap="toPay">立即支付</button>
<!-- #endif -->
<!-- #ifdef H5 -->
<button class="btn" v-if="user.phone == null" @click="jumpH5Bding">立即支付</button> <button class="btn" v-if="user.phone == null" @click="jumpH5Bding">立即支付</button>
<button class="btn" v-else @tap="toPay">立即支付</button> <button class="btn" v-else @tap="toPay">立即支付</button>
<!-- #endif -->
</view> </view>
</view> </view>
<ssPaymentPassword ref="paymentPassword" :mode="1" @submit="submitHandle" /> <ssPaymentPassword ref="paymentPassword" :mode="1" @submit="submitHandle" />
@ -64,21 +64,15 @@
<script> <script>
import { import {
addOrder, create,
getDiscountPackageDetail, getDiscountPackageDetail,
loginByPhone,
orderToPay,
unionPay, unionPay,
orderToGoldPay,
findUser, findUser,
hltUnionCardPay, cardPay,
getHuiLianTongCardBalance getHuiLianTongCardBalance
} from '../../Utils/Api.js'; } from '../../Utils/Api.js';
import ssPaymentPassword from '../../components/sanshui-payment-password' import ssPaymentPassword from '../../components/sanshui-payment-password'
let app = getApp(); let app = getApp();
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
export default { export default {
components: { components: {
ssPaymentPassword ssPaymentPassword
@ -107,7 +101,8 @@
jumpType: '', jumpType: '',
tongCardPrice: 0, tongCardPrice: 0,
storeId: '', storeId: '',
isDiscont: false isDiscont: false,
identificationCode: '' //
}; };
}, },
@ -257,18 +252,19 @@
this.storeId = app.globalData.storeid this.storeId = app.globalData.storeid
} }
let goods = { let goods = {
"highChildOrderList": [{ "childOrderList": [{
"goodsType": 7,
"goodsId": this.couponId, "goodsId": this.couponId,
"goodsPrice": this.paytheprice,
"goodsType": 7,
"saleCount": 1, "saleCount": 1,
"storeId": this.storeId }],
}] "promoteCode": this.identificationCode
} }
addOrder(goods).then(res => { create(goods).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.hideLoading(); uni.hideLoading();
this.jumpType = res.return_data.highChildOrderList[0].ext1; this.jumpType = res.return_data.highChildOrderList[0].ext1;
this.orderId = res.return_data.id; this.orderId = res.return_data.orderNo;
this.orderToPay(res.return_data); this.orderToPay(res.return_data);
} else { } else {
uni.hideLoading(); uni.hideLoading();
@ -301,7 +297,7 @@
// //
orderToPay(item) { orderToPay(item) {
let goods = { let goods = {
"orderId": this.orderId "orderNo": this.orderId
} }
unionPay(goods).then(res => { unionPay(goods).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
@ -353,42 +349,12 @@
uni.showLoading({ uni.showLoading({
title: '支付中...' title: '支付中...'
}) })
if (this.paytype == 'jinbi') {
let params = {
"orderId": this.orderId,
"password": this.PaymentPassword
}
orderToGoldPay(params).then(res => {
uni.hideLoading();
if (res.return_code == '000000') {
uni.showToast({
title: '支付成功'
})
uni.reLaunch({
url: '../coupon-comfirmation-success/coupon-comfirmation-success'
});
return;
}
if (res.return_code == '102130') {
uni.navigateTo({
url: '../../pages/login/updatePas/updatePas'
})
return;
}
uni.showToast({
title: res.return_msg,
icon: 'none'
})
})
return;
}
let params = { let params = {
"orderId": this.orderId, "orderNo": this.orderId,
"cardNo": this.user.hltCardNo.cardNo, "cardNo": this.user.hltCardNo.cardNo,
"password": this.PaymentPassword "password": this.PaymentPassword
} }
hltUnionCardPay(params).then(res => { cardPay(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.return_code == '000000') { if (res.return_code == '000000') {
uni.showToast({ uni.showToast({

Loading…
Cancel
Save