1.新增优惠券包

2.上线小程序 ,h5
3.修改之前的问题
yj-dev
杨杰 3 years ago
parent db4618b5a1
commit 08f2931abf
  1. 107
      Utils/Api.js
  2. 355
      pages.json
  3. 44
      pages/goods/coupon-details/coupon-details.vue
  4. 1
      pages/goods/coupons-info-details/coupons-info-details.vue
  5. 121
      pages/goods/goods.vue
  6. 8
      pages/login/login.vue
  7. 22
      pages/login/loginInvalid/loginInvalid.vue
  8. 101
      pages/order/confirmation.vue
  9. 29
      pages/pay/payment/payment.vue
  10. 100
      pages/pay/success/success.vue
  11. 15
      pages/tabBar/category/category.vue
  12. 29
      pages/tabBar/home/home.vue
  13. 45
      pages/user/coupon/coupon.vue
  14. 1
      pages/user/mineCouponsDestails/mineCouponsDestails.vue
  15. 20
      pages/user/order_details/order_details.vue
  16. 5
      pages/user/order_list/order_list.vue
  17. BIN
      static/img/cusservice.png
  18. BIN
      static/img/head.jpg
  19. BIN
      static/img/order9.png
  20. BIN
      static/img/phone.png
  21. 103
      subPages/Phone-recharge-details/Phone-recharge-details.vue
  22. 35
      subPages/coupon-comfirmation-success/coupon-comfirmation-success.vue
  23. 908
      subPages/coupon-comfirmation/coupon-comfirmation.vue
  24. 280
      subPages/coupon-package/coupon-package.vue
  25. 988
      subPages/coupon-packge-details/coupon-packge-details.vue
  26. 31
      subPages/recharge-centre/recharge-centre.vue
  27. 95
      subPages/sotre-details-list/sotre-details-list.vue
  28. BIN
      subPages/static/coupsucces.png
  29. BIN
      subPages/static/phone.png
  30. 86
      subPages/unionComfirmation/unionComfirmation.vue
  31. 4
      subPages/unionPay-orderList/unionPay-orderList.vue
  32. 20
      uni.scss

@ -1,8 +1,9 @@
import {
POST
} from "./Request.js";
} from "./Request.js";
import {
POSTBREST} from "./bRequest.js";
POSTBREST
} from "./bRequest.js";
let app = getApp();
let base = app.globalData.url;
let brestBase = app.globalData.brestUrl;
@ -26,12 +27,12 @@ export const setUserPayPwd = params => {
export const updateUserPayPwd = params => {
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 loginByPhone = params => {
return POST('GET', `${base}/wechat/loginByPhone`, params).then(res => res.data);
};
@ -58,27 +59,27 @@ export const getMerchantStoreById = params => {
//根据门店ID 获取卡券
export const getCouponListByStoreId = params => {
return POST('GET', `${base}/coupon/getCouponListByStoreId`, params).then(res => res.data);
}
//获取优选商品分类
}
//获取优选商品分类
export const getListGoodsType = params => {
return POST('GET', `${base}/highGoodsType/getListGoodsType`, params).then(res => res.data);
}
//获取优选商品品牌列表
}
//获取优选商品品牌列表
export const getBrandByList = params => {
return POST('GET', `${base}/highBrand/getBrandByList`, params).then(res => res.data);
}
// 优选商品列表
}
// 优选商品列表
export const getBrandCouponList = params => {
return POST('GET', `${base}/coupon/getCouponList`, params).then(res => res.data);
}
//优选商品详情
}
//优选商品详情
export const getPreByOrderIdId = params => {
return POST('GET', `${base}/orderPre/getPreByOrderIdId`, params).then(res => res.data);
}
//优选商品预约完成
}
//优选商品预约完成
export const orderComplete = params => {
return POST('POST', `${base}/orderPre/orderComplete`, params).then(res => res.data);
}
}
//卡券详情
export const getCouponById = params => {
return POST('GET', `${base}/coupon/getCouponById`, params).then(res => res.data);
@ -99,31 +100,31 @@ export const orderToGoldPay = params => {
export const getUserGoldRecList = params => {
return POST('GET', `${base}/highGoldRec/getUserGoldRecList`, params).then(res => res.data);
}
//获取用户卡券
//获取用户卡券
export const getUserCouponList = params => {
return POST('GET', `${base}/coupon/getUserCouponList`, params).then(res => res.data);
}
//获取用户卡券详情
}
//获取用户卡券详情
export const getUserCouponDetail = params => {
return POST('GET', `${base}/coupon/getUserCouponDetail`, params).then(res => res.data);
}
//获取用户最新卡券详情
export const getUserNewCouponDetail = params => {
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 => {
return POST('GET', `${base}/highOrder/getOrderById`, params).then(res => res.data);
}
//获取商户列表
}
//获取商户列表
export const getMerchantList = params => {
return POST('GET', `${base}/highMerchantStore/getMerchantList`, params).then(res => res.data);
}
@ -134,12 +135,12 @@ export const getStoreListByMerchant = params => {
//获取优惠券详情
export const getDiscountByQrCode = params => {
return POST('GET', `${base}/discount/getDiscountByQrCode`, params).then(res => res.data);
}
//查询话费优惠券
}
//查询话费优惠券
export const getUserOrderPreList = params => {
return POST('GET', `${base}/userDiscount/getUserOrderPreList`, params).then(res => res.data);
}
return POST('GET', `${base}/userDiscount/getUserExclusiveDiscount`, params).then(res => res.data);
}
//领取优惠券
export const receiveDiscount = params => {
return POST('POST', `${base}/userDiscount/receiveDiscount`, params).then(res => res.data);
@ -185,11 +186,24 @@ export const getDredgeProvince = params => {
export const getCmsContent = params => {
return POST('GET', `${base}/cmsContent/getCmsContent`, params).then(res => res.data);
}
//设置用户参数
//设置用户参数
export const setCacheParam = params => {
return POST('POST', `${base}/highUser/setCacheParam`, params).then(res => res.data);
}
//查询充值话费详情
export const getPhoneOrderById = params => {
return POST('GET', `${base}/outRechargeOrder/getOrderById`, params).then(res => res.data);
}
//优惠券包列表
export const getDiscountPackageList = params => {
return POST('GET', `${base}/discountPackage/getDiscountPackageList`, params).then(res => res.data);
}
//优惠券包详情
export const getDiscountPackageDetail = params => {
return POST('GET', `${base}/discountPackage/getDiscountPackageDetail`, params).then(res => res.data);
}
/**
* 工会卡
*/
@ -197,7 +211,7 @@ export const setCacheParam = params => {
export const getHuiLianTongCardByCardNo = params => {
return POST('GET', `${base}/highUserCard/getHuiLianTongCardByCardNo`, params).then(res => res.data);
}
// 获取用户卡号列表
// 获取用户卡号列表
export const getUserCardList = params => {
return POST('GET', `${base}/highUserCard/getUserCardList`, params).then(res => res.data);
}
@ -209,10 +223,10 @@ export const getHuiLianTongCardByPhone = params => {
export const delUserCard = params => {
return POST('POST', `${base}/highUserCard/delUserCard`, params).then(res => res.data);
}
// 查询汇联通工会卡详情
// 查询汇联通工会卡详情
export const getHuiLianTongCardBalance = params => {
return POST('GET', `${base}/highUserCard/getHuiLianTongCardBalance?`, params).then(res => res.data);
}
}
// 查询汇联通工会卡消费记录
export const getHuiLianTongCardConsume = params => {
return POST('GET', `${base}/highUserCard/getHuiLianTongCardConsume`, params).then(res => res.data);
@ -223,7 +237,7 @@ export const hltUnionCardPay = params => {
}
export const bindHuiLianTongCard = params => {
return POST('POST', `${base}/highUserCard/bindHuiLianTongCard`, params).then(res => res.data);
}
}
/**
* 工会卡
*/
@ -252,10 +266,10 @@ export const getUserLotteryNum = params => {
export const getWinLotteryList = params => {
return POST('GET', `${base}/activity/getWinLotteryList`, params).then(res => res.data);
}
//跳转是否赠券
//跳转是否赠券
export const getMembershipLevel = params => {
return POST('GET', `${base}/highUser/GetMembershipLevel`, params).then(res => res.data);
}
}
/**
* 肯德基地址
*/
@ -312,14 +326,14 @@ export const useCouponCode = params => {
//**代理商//
//**代理商//
export const getAgentCount = params => {
return POSTBREST('GET', `${brestBase}/highCouponAgent/getAgentCount`, params).then(res => res.data);
}
// 查询销售码
export const getCodeListByAgentCoupon = params => {
return POSTBREST('GET', `${brestBase}/highCouponAgent/getCodeListByAgentCoupon`, params).then(res => res.data);
}
}
// 生成二维码
export const generateCode = params => {
return POSTBREST('POST', `${brestBase}/highCouponAgent/generateCode`, params).then(res => res.data);
@ -339,8 +353,8 @@ export const getAgentSalesPriceCount = params => {
//修改密码
export const sendUserPass = params => {
return POSTBREST('POST', `${brestBase}/secUser/sendUserPass`, params).then(res => res.data);
}
}
@ -371,5 +385,4 @@ export const hltUnionCardPayUnion = params => {
//话费列表
export const getUserOrderListhuafei = params => {
return POST('GET', `${base}/outRechargeOrder/getUserOrderList`, params).then(res => res.data);
}
}

@ -1,34 +1,34 @@
{
"pages": [ //pageshttps://uniapp.dcloud.io/collocation/pages
{
"path": "pages/tabBar/home/home",
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "首页",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"onReachBottomDistance": 50,
"app-plus": {
"titleNView": false, //
"softinputNavBar": "none",
"subNVues": [{
"id": "homeTitleNvue", //
"path": "pages/tabBar/home/subNvue/homeTitleNvue", //
"type": "navigationBar"
}]
}
}
}, {
"path": "pages/qianZhuPay/union-pay/union-pay",
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "选择方式",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"enablePullDownRefresh": false
}
},{
{
"path": "pages/tabBar/home/home",
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "首页",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"onReachBottomDistance": 50,
"app-plus": {
"titleNView": false, //
"softinputNavBar": "none",
"subNVues": [{
"id": "homeTitleNvue", //
"path": "pages/tabBar/home/subNvue/homeTitleNvue", //
"type": "navigationBar"
}]
}
}
}, {
"path": "pages/qianZhuPay/union-pay/union-pay",
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "选择方式",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"enablePullDownRefresh": false
}
}, {
"path": "pages/user/bindingCardList/bindingCardList",
"style": {
"navigationBarTitleText": "卡列表",
@ -331,21 +331,21 @@
}, {
"path": "pages/goods/externalCoupon/externalCoupon",
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "扫码领取优惠券",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"onReachBottomDistance": 50,
"app-plus": {
"titleNView": false, //
"softinputNavBar": "none",
"subNVues": [{
"id": "homeTitleNvue", //
"path": "pages/tabBar/home/subNvue/homeTitleNvue", //
"type": "navigationBar"
}]
}
"style": {
"navigationBarTextStyle": "white",
"navigationBarTitleText": "扫码领取优惠券",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"onReachBottomDistance": 50,
"app-plus": {
"titleNView": false, //
"softinputNavBar": "none",
"subNVues": [{
"id": "homeTitleNvue", //
"path": "pages/tabBar/home/subNvue/homeTitleNvue", //
"type": "navigationBar"
}]
}
}
}, {
@ -434,17 +434,6 @@
"navigationBarTextStyle": "white"
}
}, {
"path": "pages/login/loginInvalid/loginInvalid",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "pages/user/bindingCard/bindingCard",
"style": {
@ -483,110 +472,168 @@
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}
],
"subpackages": [{
"root": "subPages",
"pages": [{
"path": "brand-classification/brand-classification",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "品牌分类",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},{
"path": "preferred-goods/preferred-goods",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "商品分类",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},{
"path": "lottery/lottery",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "抽奖活动",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#e62601",
"backgroundColorTop": "#e62601",
"navigationBarTextStyle": "white"
}
},
{
"path": "recharge/recharge",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "话费充值",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},
{
"path": "recharge-centre/recharge-centre",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "话费充值",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},{
"path": "unionComfirmation/unionComfirmation",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "确认订单",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},{
"path": "unionPay-orderList/unionPay-orderList",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "话费订单",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},
{
"path": "unionPay/unionPay",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "入口选择",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
"pages": [
{
"path" : "coupon-comfirmation-success/coupon-comfirmation-success",
"style" :
{
"enablePullDownRefresh": false,
"navigationBarTitleText": "支付成功",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},{
"path": "brand-classification/brand-classification",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "品牌分类",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "preferred-goods/preferred-goods",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "商品分类",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "lottery/lottery",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "抽奖活动",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#e62601",
"backgroundColorTop": "#e62601",
"navigationBarTextStyle": "white"
}
},
{
"path": "recharge/recharge",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "话费充值",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},
{
"path": "recharge-centre/recharge-centre",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "话费充值",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "unionComfirmation/unionComfirmation",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "确认订单",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "unionPay-orderList/unionPay-orderList",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "话费订单",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
},
{
"path": "unionPay/unionPay",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "入口选择",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "unionWeb/unionWeb",
"style": {
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}, {
"path": "Phone-recharge-details/Phone-recharge-details",
"style": {
"enablePullDownRefresh": false,
"navigationBarTitleText": "交易详情",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "sotre-details-list/sotre-details-list",
"style": {
"navigationBarTitleText": "门店列表",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "coupon-package/coupon-package",
"style": {
"navigationBarTitleText": "",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "coupon-packge-details/coupon-packge-details",
"style": {
"navigationBarTitleText": "优惠券包详情",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}, {
"path": "coupon-comfirmation/coupon-comfirmation",
"style": {
"navigationBarTitleText": "确认订单",
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#0083f5",
"backgroundColorTop": "#0083f5",
"navigationBarTextStyle": "white"
}
}
} ,{
"path" : "unionWeb/unionWeb",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
]
}],
"globalStyle": {

@ -25,9 +25,9 @@
<yy-video-player :auto-play="false" :url="imagewxUrl+imgadres3" :poster="poster" :show-back-btn="true">
</yy-video-player>
<image :src="imagewxUrl+imgadres2" mode="widthFix" class="mart10"></image>
</view>
<view class="mart20 fotct fcorred font15 marb20 height20"
v-if="couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0">
</view>
<view class="mart20 fotct fcorred font15 marb20 height20"
v-if="couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0">
预约订单已成功 门店会在24小时内联系您</view>
<view class="mart20 fotct fcorred font15 marb20 height20"
v-if="!couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0 && couponDesInfo.couponInfo.couponSource == 3">
@ -35,24 +35,31 @@
<view class="mart20 fotct fcorred font15 marb20 height20"
v-if="!couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0 && couponDesInfo.couponInfo.couponSource != 3">
请告知加油员用码商支付</view>
<view class="width90 mart20 fotct"
v-if="!couponDesInfo.couponInfo.reserveStatus">
<view class="width90 mart20 fotct" v-if="!couponDesInfo.couponInfo.reserveStatus">
<image class="coupon-qr" :src="imageUrl+'couponCode/'+couponDesInfo.highUserCoupon.qrCodeImg"></image>
</view>
<view class="fotct fcor333 font15 marb10 mart10"
v-if="couponDesInfo.couponInfo.couponSource != 4 && couponDesInfo.couponCodeInfo.codeKey">
{{couponDesInfo.couponCodeInfo.codeKey}}</view>
{{couponDesInfo.couponCodeInfo.codeKey}}
</view>
</view>
<view class="width90 mart10 googscs backcorfff" v-if="couponDesInfo.couponInfo.couponSource != 4">
<view class="width90 height45l font18 fcor666 aliitem">
<image mode="widthFix" style="width: 50rpx; max-height: 50rpx;margin-right: 10px;"
src="../../../static/img/adresw.png"></image> 门店信息
<view class="width90 height45l font18 fcor666 aliitem" v-if="storeList">
<view class="width50 alijusstart">
<image mode="widthFix" style="width: 50rpx; max-height: 50rpx;margin-right: 10px;"
src="../../../static/img/adresw.png"></image> 门店信息
</view>
<view class="width50 alijusend font15" @click="jumpstorelist">查看更多<image
style="width: 18px; height: 17px;" src="../../../static/img/jt.png">
</images>
</view>
</view>
<view class="line1 width100"></view>
<view class="width90 stoCont" v-for="(store,i) in storeList" :key="i">
<view class="width80p flleft mart10">
<view class="font16 fcor333 fontwig6 ">{{store.storeName}}</view>
<view class="font13 fcor666 mart10">{{store.address}}</view>
<view class="font16 fcor333 fontwig6 text1">{{store.storeName}}</view>
<view class="font13 fcor666 mart10 text2">{{store.address}}</view>
</view>
<view class="width20 flright mart10 fotrt" @click="seeloaction(store)">
<image mode="widthFix" style="width: 25px;height: 25px;" :src="imagewxUrl+imgadres1">
@ -62,8 +69,6 @@
</view>
</view>
<view class="height60"></view>
<!-- <button class="czlq width100" v-if="couponDesInfo.highUserCoupon.status == 0"
@click="againReceiveCoupon">重新领取</button> -->
</view>
</template>
@ -95,7 +100,7 @@
threeTime: '',
menddesId: '',
pageNum: 1,
pageSize: 10,
pageSize: 1,
isNoMoreData: false
}
},
@ -123,7 +128,6 @@
}
},
onReachBottom() {
this.getStoreListByCoupon();
},
methods: {
//
@ -162,7 +166,12 @@
address: e.address
})
},
//
jumpstorelist() {
uni.navigateTo({
url: '../../../subPages/sotre-details-list/sotre-details-list?id=' + this.menddesId
})
},
/**
* 查询门店列表
*/
@ -346,7 +355,8 @@
position: fixed;
bottom: 0px;
background-color: red;
color: #FFFFFF;
color: #FFFFFF;
border-radius: 0px;
}
.czlq {

@ -216,6 +216,7 @@
bottom: 0px;
background-color: red;
color: #FFFFFF;
border-radius: 0px;
}
.czlq {

@ -139,8 +139,6 @@
return {
//
beforeHeaderzIndex: 11, //
afterHeaderzIndex: 10, //
beforeHeaderOpacity: 1, //
afterHeaderOpacity: 0, //
//
// #ifndef MP
@ -152,14 +150,8 @@
//
currentSwiper: 0,
anchorlist: [], //
selectAnchor: 0, //
serviceClass: '', //css
specClass: '', //css
shareClass: '', //css
//
goodsData: "",
selectSpec: null, //
isKeep: false, //
//html
desid: '',
imageUrl: app.globalData.imgUrl,
@ -258,29 +250,6 @@
swiperChange(event) {
this.currentSwiper = event.detail.current;
},
hideShare() {
this.shareClass = 'hide';
setTimeout(() => {
this.shareClass = 'none';
}, 150);
},
//
keep() {
this.isKeep = this.isKeep ? false : true;
},
//
joinCart() {
if (this.selectSpec == null) {
return this.showSpec(() => {
uni.showToast({
title: "已加入购物车"
});
});
}
uni.showToast({
title: "已加入购物车"
});
},
//
getuserinfo() {
let that = this;
@ -363,100 +332,10 @@
})
},
//
showComments(goodsid) {
},
//
setSelectSpec(index) {
this.selectSpec = index;
},
//
sub() {
if (this.goodsData.number <= 1) {
return;
}
this.goodsData.number--;
},
//
add() {
this.goodsData.number++;
},
//
toAnchor(index) {
this.selectAnchor = index;
uni.pageScrollTo({
scrollTop: this.anchorlist[index].top,
duration: 200
});
},
//
calcAnchor() {
this.anchorlist = [{
name: '主图',
top: 0
},
{
name: '评价',
top: 0
},
{
name: '详情',
top: 0
}
]
let commentsView = uni.createSelectorQuery().select("#comments");
commentsView.boundingClientRect((data) => {
let statusbarHeight = 0;
//APP
// #ifdef APP-PLUS
statusbarHeight = plus.navigator.getStatusbarHeight()
// #endif
let headerHeight = uni.upx2px(100);
this.anchorlist[1].top = data.top - headerHeight - statusbarHeight;
this.anchorlist[2].top = data.bottom - headerHeight - statusbarHeight;
}).exec();
},
//
back() {
uni.navigateBack();
},
//
showService() {
console.log('show');
this.serviceClass = 'show';
},
//
hideService() {
this.serviceClass = 'hide';
setTimeout(() => {
this.serviceClass = 'none';
}, 200);
},
//
showSpec(fun) {
console.log('show');
this.specClass = 'show';
this.specCallback = fun;
},
specCallback() {
return;
},
//
hideSpec() {
this.specClass = 'hide';
//
this.selectSpec && this.specCallback && this.specCallback();
this.specCallback = false;
setTimeout(() => {
this.specClass = 'none';
}, 200);
},
discard() {
//
}
}
};
</script>

@ -9,12 +9,12 @@
<!-- 账号密码输入框 -->
<view class="form">
<view class="username">
<image src="../../static/img/adresw.png" style="width: 40rpx;height: 40rpx;"></image> <input
placeholder="请输入账号" v-model="phoneNumber" placeholder-style="color: #333333;" />
<image src="../../static/img/phone.png" style="width: 40rpx;height: 40rpx;"></image> <input
placeholder="请输入账号" v-model="phoneNumber" placeholder-style="color: #333333;margin-left: 10px;" />
</view>
<view class="password">
<image src="../../static/img/adresw.png" style="width: 40rpx;height: 40rpx;"></image><input
placeholder="请输入密码" v-model="passwd" password=true placeholder-style="color: #333333;" />
<image src="../../static/img/pas.png" style="width: 40rpx;height: 40rpx;"></image><input
placeholder="请输入密码" v-model="passwd" password=true placeholder-style="color: #333333;margin-left: 10px;" />
</view>
<view class="btn mart50" @tap="doLogin"> </view>
</view>

@ -1,22 +0,0 @@
<template>
<view>
</view>
</template>
<script>
export default {
data() {
return {
}
},
methods: {
}
}
</script>
<style>
</style>

@ -7,16 +7,27 @@
<view class="tcrig">
<view class="font18 fontwig6 fcor333 text1">{{couponList.couponName}}</view>
<view class="font13 fcor666 mart10">规格: 默认</view>
<view class="price-number mart10">
<view class="price-number mart10" v-if="isDiscont">
<view class="price font16" v-if="couponList.payType == 1">{{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>
<view class="price-number mart10" v-if="!isDiscont">
<view class="price font16" v-if="couponList.payType == 1">{{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" v-if="couponList.payType == 1">
<view class="number fcor666 font13 margle"
v-if="couponList.payType == 1 && couponList.salesPrice != couponList.discountPrice">
{{couponList.salesPrice}}
</view>
<view class="number fcor666 font13 margle" v-else>
<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>
@ -29,10 +40,21 @@
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
商品总额
</view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999" v-if="couponList.payType == 1">
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999"
v-if="couponList.payType == 1 && isDiscont">
{{couponList.salesPrice}}
</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.salesPrice*100}}
</view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999"
v-if="couponList.payType == 1 && !isDiscont">
{{couponList.discountPrice}}
</view>
<view class="width40 flright alijun paddtright10 font15 fontwig6 fcor666 aliitem" v-else>
<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>
@ -204,7 +226,9 @@
orderId: '',
jumpType: '',
tongCardPrice: 0,
storeId: ''
storeId: '',
isDiscont: false,
coupondiscountid:''
};
},
@ -284,37 +308,32 @@
showPopup() {
this.$refs.popup.show();
},
radioChanges(item) {
if (this.memDiscountId == item.id) { //
this.memDiscountId = '';
if (this.memDiscountId == item.highDiscount.id) { //
this.memDiscountId = '';
this.coupondiscountid = '';
this.paytheprice = this.couponList.discountPrice;
this.deductionPrice = '0.00';
this.isDiscont = false;
} else { //
this.memDiscountId = item.id;
this.isDiscont = true;
this.memDiscountId = item.highDiscount.id;
this.coupondiscountid = item.id;
if (item.highDiscount.discountType == 1) {
if (this.couponList.salesPrice > item.highDiscount.discountPrice) {
//
this.deductionPrice = item.highDiscount.discountPrice;
this.paytheprice = (((this.couponList.salesPrice * 100) - (this.deductionPrice * 100)) /
100);
} else {
uni.showToast({
title: '未满足满减条件',
icon: 'none',
duration: 2000
})
}
//
this.deductionPrice = item.highDiscount.discountPrice;
this.paytheprice = this.couponList.salesPrice - this.deductionPrice;
} else if (item.highDiscount.discountType == 2) {
//
this.deductionPrice = item.highDiscount.discountPrice;
this.paytheprice = (((this.couponList.salesPrice * 100) - (this.deductionPrice * 100)) / 100);
this.paytheprice = this.couponList.salesPrice - this.deductionPrice;
} else if (item.highDiscount.discountType == 3) {
//
this.deductionPrice = this.couponList.salesPrice - this.couponList.salesPrice * (
item.highDiscount.discountPrice / 10);
this.paytheprice = this.couponList.salesPrice * (item.highDiscount
.discountPrice / 10);
this.deductionPrice = parseFloat(this.couponList.salesPrice - (this.couponList.salesPrice *
item
.highDiscount.discountPrice)).toFixed(2)
this.paytheprice = parseFloat(this.couponList.salesPrice * item.highDiscount.discountPrice)
.toFixed(2);
}
}
this.$refs.popup.hide();
@ -403,7 +422,7 @@
this.storeId = app.globalData.storeid
}
let goods = {
"memDiscountId": this.memDiscountId,
"memDiscountId": this.coupondiscountid,
"identificationCode": app.globalData.identificationCode,
"highChildOrderList": [{
"goodsType": 1,
@ -492,7 +511,8 @@
app.globalData.storeid = '';
app.globalData.storename = '';
uni.reLaunch({
url: '../pay/success/success?id=' + that.couponId
url: '../pay/success/success?id=' + that
.couponId
});
},
fail: function(err) {
@ -516,6 +536,21 @@
}
})
} else if (that.paytype == 'jinbi') {
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'
@ -524,6 +559,14 @@
}
that.$refs.paymentPassword.modalFun('show');
} else if (that.paytype == 'gonghuika') {
if (that.tongCardPrice < that.paytheprice) {
uni.showToast({
icon: 'none',
title: '工会卡余额不足',
duration: 2000,
});
return;
}
if (!that.user.isSetPayPwd) {
uni.navigateTo({
url: '../login/updatePas/updatePas'

@ -20,7 +20,7 @@
<view class="pay-list">
<view class="row" @tap="paytype='jinbi'" v-if="pryType == 2 || pryType==3 ">
<view class="left">
<image src="../../../static/img/jfx.png"></image>
<image src="../../../static/img/jfx.png"></image>
</view>
<view class="center">
积分支付(积分:{{user.gold}})
@ -96,7 +96,7 @@
jumpType: '',
PaymentPassword: '',
tongCardPrice: 0,
goodsType:''
goodsType: ''
};
},
onLoad(e) {
@ -115,7 +115,7 @@
this.amount = parseFloat(e.amount).toFixed(2);
},
onShow() {
let that = this;
let that = this;
that.user = app.globalData.userInfo;
that.getHuiLianTongCardBalance();
},
@ -209,6 +209,21 @@
}
})
} else if (that.paytype == 'jinbi') {
if (that.user.gold < that.amount * 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'
@ -217,6 +232,14 @@
}
that.$refs.paymentPassword.modalFun('show');
} else if (that.paytype == 'gonghuika') {
if (that.tongCardPrice < that.amount) {
uni.showToast({
icon: 'none',
title: '工会卡余额不足',
duration: 2000,
});
return;
}
if (!that.user.isSetPayPwd) {
uni.navigateTo({
url: '../../login/updatePas/updatePas'

@ -10,7 +10,8 @@
<view class="line1"></view>
<view class="width90">
<view class="flright fotct">
<image mode="widthFix" class="coupon-img" :src="imageUrl+couponDesInfo.couponInfo.couponImg"></image>
<image mode="widthFix" class="coupon-img" :src="imageUrl+couponDesInfo.couponInfo.couponImg">
</image>
</view>
<view class="coupon-mes mart10">
<view class="fcor333 fontwig6 font24 width100 text2">{{couponDesInfo.couponInfo.couponName}}</view>
@ -26,28 +27,30 @@
<view class="line1 mart15"></view>
<view class="width100 fotct" v-if="couponDesInfo.couponInfo.couponSource == 4">
<view class="font28 fontlet mart5 marb10" style="color: #1593c3;">视频教程</view>
<yy-video-player
:auto-play="false"
:url="imagewxUrl+imgadres3"
:poster="poster"
:show-back-btn="true"
></yy-video-player>
<yy-video-player :auto-play="false" :url="imagewxUrl+imgadres3" :poster="poster" :show-back-btn="true">
</yy-video-player>
<image :src="imagewxUrl+imgadres2" mode="widthFix" class="mart10"></image>
</view>
<view class="width100">
<view class="mart20 fotct fcorred font15 marb20" v-if="couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0">预约订单已成功 门店会在24小时内联系您</view>
<view class="mart20 fotct fcorred font15 marb20" v-if="!couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0 && couponDesInfo.couponInfo.couponSource == 3">请出示核销码(商户扫客户)</view>
<view class="mart20 fotct fcorred font15 marb20" v-if="!couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0 && couponDesInfo.couponInfo.couponSource != 3">请告知加油员用码商支付</view>
<view class="width100">
<view class="mart20 fotct fcorred font15 marb20"
v-if="couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0">预约订单已成功
门店会在24小时内联系您</view>
<view class="mart20 fotct fcorred font15 marb20"
v-if="!couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0 && couponDesInfo.couponInfo.couponSource == 3">
请出示核销码(商户扫客户)</view>
<view class="mart20 fotct fcorred font15 marb20"
v-if="!couponDesInfo.couponInfo.reserveStatus && couponDesInfo.highUserCoupon.status != 0 && couponDesInfo.couponInfo.couponSource != 3">
请告知加油员用码商支付</view>
<view class="width90 mart20 fotct" v-if="!couponDesInfo.couponInfo.reserveStatus">
<image class="coupon-qr" :src="imageUrl+'couponCode/'+couponDesInfo.highUserCoupon.qrCodeImg">
</image>
</view>
</view>
<view class="width90 mart30 font20 fcor333 fotct marb40" v-if="!couponDesInfo">二维码生效中,前往个人中心查看</view>
<view class="width90 mart20" style="height: 80px;" v-for="(store,i) in storeList" :key="i">
<!-- <view class="width90 mart20" style="height: 80px;" v-for="(store,i) in storeList" :key="i">
<view class="coupon-des flleft">
<image mode="widthFix" :src="imageUrl+store.ext1"></image>
</view>
@ -57,18 +60,42 @@
<view class="font14 fcor999 width100 text2 mart5">{{store.address}}</view>
</view>
<view class="coupon-map flright width30 fotct" @click="seeloaction(store)">
<!-- 地图logo -->
<image :src="imagewxUrl+imgadres1">
</image>
<view class="mart5 fcor999 font13">{{store.distance}}km</view>
</view>
</view>
</view> -->
</view>
<view class="width90 height45l font18 fcor666 aliitem" v-if="storeList">
<view class="width50 alijusstart">
<image mode="widthFix" style="width: 50rpx; max-height: 50rpx;margin-right: 10px;"
src="../../../static/img/adresw.png"></image> 门店信息
</view>
<view class="width50 alijusend font15" @click="jumpstorelist">查看更多<image style="width: 18px; height: 17px;"
src="../../../static/img/jt.png">
</images>
</view>
</view>
<wybPopup ref="popup" class="fotct" type="center" height="850" width="600" radius="6" bgColor="" :showCloseIcon="true" > <image class="popImg" mode="widthFix" :src="imagewxUrl+imgadres4" @click="jumpcjhuod"></image> </wybPopup>
<view class="line1 width100"></view>
<view class="width90 stoCont" v-for="(store,i) in storeList" :key="i">
<view class="width80p flleft mart10">
<view class="font16 fcor333 fontwig6 text1">{{store.storeName}}</view>
<view class="font13 fcor666 mart10 text1">{{store.address}}</view>
</view>
<view class="width20 flright mart10 fotrt" @click="seeloaction(store)">
<image mode="widthFix" style="width: 25px;height: 25px;" :src="imagewxUrl+imgadres1">
</image>
<view class="mart5 fcor999 font13">{{store.distance}}km</view>
</view>
</view>
<wybPopup ref="popup" class="fotct" type="center" height="850" width="600" radius="6" bgColor=""
:showCloseIcon="true">
<image class="popImg" mode="widthFix" :src="imagewxUrl+imgadres4" @click="jumpcjhuod"></image>
</wybPopup>
<view class="height60"></view>
<button class="coupne-btn width100" @click="toUser">个人中心</button>
</view>
</template>
@ -101,7 +128,7 @@
twoTime: '',
threeTime: '',
pageNum: 1,
pageSize: 10,
pageSize: 1,
isNoMoreData: false
}
},
@ -129,7 +156,7 @@
}
},
onReachBottom() {
this.getStoreListByCoupon();
// this.getStoreListByCoupon();
},
methods: {
//
@ -144,7 +171,7 @@
if (res.return_code == '000000') {
uni.hideLoading();
this.couponDesInfo = res.return_data;
if(res.return_data.couponInfo.couponSource == 4){
if (res.return_data.couponInfo.couponSource == 4) {
this.oneTime = res.return_data.highUserCoupon.createTime;
this.twoTime = res.return_data.highUserCoupon.useEndTime;
this.threeTime = res.return_data.highUserCoupon.consumeTime;
@ -179,10 +206,16 @@
});
},
//
jumpcjhuod(){
jumpcjhuod() {
this.closePopup();
uni.reLaunch({
url:'../../../subPages/lottery/lottery?id='+this.couDesId
url: '../../../subPages/lottery/lottery?id=' + this.couDesId
})
},
//
jumpstorelist() {
uni.navigateTo({
url: '../../../subPages/sotre-details-list/sotre-details-list?id=' + this.couDesId
})
},
//
@ -246,8 +279,11 @@
}
</script>
<style lang="scss">
.popImg { width: 300px; height: 440px; }
.popImg {
width: 300px;
height: 440px;
}
.loading-text {
width: 100%;
display: flex;
@ -258,6 +294,11 @@
font-size: 24upx;
}
.stoCont {
border-bottom: 1px solid #f6f6f6;
height: 140rpx;
}
.coupon-status {
height: 35px;
line-height: 35px;
@ -284,7 +325,8 @@
color: white;
font-size: 28px;
border-radius: 10px;
image{
image {
width: 80px;
max-height: 80px;
}
@ -310,13 +352,7 @@
position: fixed;
bottom: 0px;
background-color: red;
color: #FFFFFF;
}
.coupne-btn {
position: fixed;
bottom: 0px;
background-color: red;
color: #FFFFFF;
color: #FFFFFF;
border-radius: 0px;
}
</style>

@ -62,6 +62,9 @@
</view>
</view>
</wybPopup>
<button open-type="contact">
<image :src="imagewxUrl+imgadres5" mode="widthFix" class="xfimg"></image>
</button>
</view>
</template>
<script>
@ -86,7 +89,8 @@
imgadres2: 'xiala.png',
imgadres1: 'noorder.png',
imgadres4: 'dh.png',
imgadres3: 'noorder.png',
imgadres3: 'noorder.png',
imgadres5: 'cusservice.png',
city: "",
imageUrl: app.globalData.imgUrl,
//
@ -219,7 +223,7 @@
latitude: app.globalData.latitude,
pageNum: pagenum,
pageSize: this.pageSize
}
getStoreListByMerchant(params).then(res => {
uni.hideLoading();
@ -271,6 +275,13 @@
background-color: #f1f3f5;
}
.xfimg {
width: 80rpx;
bottom: 60rpx;
position: fixed;
right: 40rpx;
}
.status {
width: 100%;
height: 0;

@ -83,9 +83,12 @@
</view>
</swiper-item>
</swiper>
<wybPopup ref="popup" type="center" height="850" width="600" radius="6" bgColor="" :showCloseIcon="true">
<wybPopup ref="popup" type="center" height="850" width="600" bgColor="" radius="6" :showCloseIcon="true">
<image class="popImg" :src="imageUrl+imgadres3" @click="jumpWeb"></image>
</wybPopup>
</wybPopup>
<button open-type="contact">
<image :src="imagewxUrl+imgadres4" mode="widthFix" class="xfimg"></image>
</button>
<view class="height60"></view>
</view>
</template>
@ -126,6 +129,7 @@
imgadres1: 'jbhed.png',
imgadres2: 'jt.png',
imgadres3: '',
imgadres4: 'cusservice.png',
webUrl: '',
//
swiperList: [{
@ -176,7 +180,7 @@
this.getCmsContentcmshome();
this.getCmsContentcmsContent();
if (app.globalData.userInfo.phone) {
// this.getMembershipLevel();
this.getMembershipLevel();
}
}
},
@ -484,6 +488,8 @@
return;
}
this.productListleg = res.return_data.total;
}else{
this.productList = [];
}
})
},
@ -504,6 +510,8 @@
return;
}
this.goldproductListleg = res.return_data.total;
}else{
this.productList = [];
}
})
},
@ -667,7 +675,13 @@
url: '../../../subPages/preferred-goods/preferred-goods'
})
return;
}
}
if (item.title == '优惠券包') {
uni.navigateTo({
url:'../../../subPages/coupon-package/coupon-package'
})
return;
}
},
@ -690,6 +704,13 @@
.popImg {
width: 300px;
height: 440px;
}
.xfimg{
width: 80rpx;
bottom: 60rpx;
position: fixed;
right: 40rpx;
}
@font-face {

@ -1,7 +1,7 @@
<template>
<view>
<view class="tabr" :style="{top:headerTop}">
<view :class="{on:typeClass=='valid'}" @tap="switchType('valid')">可用({{couponValidList.length}})</view>
<view :class="{on:typeClass=='valid'}" @tap="switchType('valid')">可用({{couponcout}})</view>
<view :class="{on:typeClass=='invalid'}" @tap="switchType('invalid')">已失效</view>
<view class="border" :class="typeClass"></view>
</view>
@ -12,7 +12,7 @@
<view class="tis" v-if="couponValidList.length==0">
<image mode="widthFix" style="width: 70vw;" :src="imagewxUrl+imgadres"></image>
</view>
<view class="row" v-for="(row,index) in couponValidList" :key="index" @click="jumpcoupons(row.id)">
<view class="row" v-for="(row,index) in couponValidList" :key="index" @click="jumpcoupons(row)">
<!-- 删除按钮 -->
<view class="menu" @tap.stop="deleteCoupon(row.id,couponValidList)">
<view class="icon shanchu"></view>
@ -31,11 +31,17 @@
</view>
<view class="right">
<view class="ticket">
<view class="num">
{{row.highDiscount.discountPrice}}
<view class="num" v-if="row.highDiscount.discountType == 3">
{{row.highDiscount.discountPrice * 10}}
</view>
<view class="num" v-else>
{{row.highDiscount.discountPrice}}
</view>
<view class="unit">
<view class="unit" v-if="row.highDiscount.discountType == 3">
</view>
<view class="unit" v-else>
</view>
</view>
<!-- <view class="criteria">
@ -118,7 +124,8 @@
pageNum: 1,
pageSize: 10,
isNoMoreData: false,
loadingText: ''
loadingText: '',
couponcout:0
}
},
onPageScroll(e) {
@ -164,14 +171,8 @@
},
onReachBottom() {
if (this.typeClass == 'valid') {
this.pageNum = 1;
this.couponValidList = []
this.isNoMoreData = false;
this.getUserDiscountList(1);
} else {
this.pageNum = 1;
this.couponinvalidList = []
this.isNoMoreData = false;
this.getUserDiscountList(2);
}
},
@ -200,7 +201,8 @@
this.isNoMoreData = true;
}
if (this.typeClass == 'valid') {
this.couponValidList = this.couponValidList.concat(res.return_data.list);
this.couponValidList = this.couponValidList.concat(res.return_data.list);
this.couponcout = res.return_data.total;
} else {
this.couponinvalidList = this.couponinvalidList.concat(res.return_data.list);
}
@ -213,10 +215,17 @@
})
},
//
jumpcoupons(e) {
uni.navigateTo({
url: '../mineCouponsDestails/mineCouponsDestails?id=' + e
})
jumpcoupons(e) {
if(e.highDiscount.useScope == 3){
uni.navigateTo({
url: '../../../subPages/recharge/recharge'
})
}else{
uni.navigateTo({
url: '../mineCouponsDestails/mineCouponsDestails?id=' + e.id
})
}
},
switchType(type) {
if (this.typeClass == type) {

@ -195,5 +195,6 @@
bottom: 0px;
background-color: red;
color: #FFFFFF;
border-radius: 0px;
}
</style>

@ -14,9 +14,9 @@
<view class="row">
<view class="goods-info">
<view class="img">
<image mode="widthFix" :src="imageUrl+rec.goodsImg" v-if="rec.goodsType == 1"></image>
<image mode="widthFix" :src="imageUrl+rec.goodsImg" v-if="rec.goodsType == 1 || rec.goodsType == 7"></image>
<image mode="widthFix" :src="imagewxUrl+imgadres1" v-if="rec.goodsType == 6"></image>
<image mode="widthFix" :src="rec.goodsImg" v-if="rec.goodsType != 1 && rec.goodsType != 6"></image>
<image mode="widthFix" :src="rec.goodsImg" v-if="rec.goodsType != 1 && rec.goodsType != 6 && rec.goodsType != 7"></image>
</view>
<view class="info">
<view class="title">{{rec.goodsName}}</view>
@ -220,6 +220,14 @@
{{preByOrderInfo.preOrderNo}}
</view>
</view>
<view class="row" v-if="preByOrderInfo.opUserName">
<view class="left">
预约门店 :
</view>
<view class="right">
{{preByOrderInfo.opUserName}}
</view>
</view>
<view class="row" v-if="preByOrderInfo.reachAddress">
<view class="left">
到店地点 :
@ -252,6 +260,14 @@
{{preByOrderInfo.statusCancelDesc}}
</view>
</view>
<view class="row" v-if="preByOrderInfo.preUserRemark">
<view class="left">
预约备注 :
</view>
<view class="right">
{{preByOrderInfo.preUserRemark}}
</view>
</view>
</view>
<view class="width100 height60"></view>

@ -18,6 +18,11 @@
v-if="row.highChildOrderList[0].goodsType == 1 || row.highChildOrderList[0].goodsType == 2">
<image src="../../../static/img/order2.png" style="width: 50rpx;height: 50rpx;"></image>
卡券订单
</view>
<view class="width50 flleft aliitem fotlt font16"
v-if="row.highChildOrderList[0].goodsType == 7">
<image src="../../../static/img/order9.png" style="width: 50rpx;height: 50rpx;"></image>
优惠券包
</view>
<view class="width50 flleft aliitem fotlt font16"
v-if="row.highChildOrderList[0].goodsType == 3">

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 742 B

@ -0,0 +1,103 @@
<template>
<view>
<image src="../static/phone.png" class="width20w mart20" mode="widthFix"></image>
<view class="font14 fotct fcor333">话费充值</view>
<view class="fotct font48 fcor333 mart10">{{phoneorderdes.orderPrice}}<text class="font14"></text></view>
<view class="linec6 width90 mart10"></view>
<view class="width90 mart20 fcor666 font18">
交易状态 : <text class="paysuc"> 支付成功</text>
</view>
<view class="width90 mart15 height22">
<view class="flleft fcor333 width50 font15">订单流水号</view>
<view class="flright fcor666 width50 fotrt font13">{{phoneorderdes.orderNo}}</view>
</view>
<view class="width90 mart15 height22">
<view class="flleft fcor333 width50 font15">创建消费订单</view>
<view class="flright fcor666 width50 fotrt font13">{{phoneorderdes.orderPrice}}</view>
</view>
<view class="width90 fcor666 font13">
{{phoneorderdes.createTimed | timeFormat('yyyy-mm-dd')}} {{phoneorderdes.createTimed | timeFormat('hh:mm')}}
</view>
<view class="width90 mart15 height22">
<view class="flleft fcor333 width50 font15">支付成功</view>
<view class="flright fcor666 width50 fotrt font13">{{phoneorderdes.payPrice}}</view>
</view>
<view class="width90 fcor666 font13">
{{phoneorderdes.payTime | timeFormat('yyyy-mm-dd')}} {{phoneorderdes.payTime | timeFormat('hh:mm')}}
</view>
<view class="linec6 width90 mart10"></view>
<view class="width90 mart10 fcor333 font15">
话费充值 : {{phoneorderdes.userPhone}}{{phoneorderdes.remarks}}
</view>
<view class="width90 mart15 height22">
<view class="flleft fcor333 width50 font15">订单总额</view>
<view class="flright fcor666 width50 fotrt font13">{{phoneorderdes.orderPrice}}</view>
</view>
<view class="width90 mart15 height22">
<view class="flleft fcor333 width50 font15">优惠</view>
<view class="flright fcor666 width50 fotrt font13">{{phoneorderdes.deductionPrice}}</view>
</view>
<view class="width90 mart15 height22">
<view class="flleft fcor333 width50 font15">实际支付金额</view>
<view class="flright fcor666 width50 fotrt font13">{{phoneorderdes.payRealPrice}}</view>
</view>
<view class="width100 height90"></view>
<button class="coupne-btn width100" @click="toUser">个人中心</button>
</view>
</template>
<script>
import {
getPhoneOrderById
} from '../../Utils/Api.js';
let app = getApp();
export default {
data() {
return {
orderid: '',
phoneorderdes:''
}
},
onLoad(options) {
this.orderid = options.id;
this.getPhoneOrderById();
},
methods: {
//
toUser() {
uni.switchTab({
url: '../../pages/tabBar/user/user'
});
},
getPhoneOrderById() {
let params = {
orderId: this.orderid
}
getPhoneOrderById(params).then(res => {
if (res.return_code == '000000') {
this.phoneorderdes = res.return_data;
}
});
}
}
}
</script>
<style lang="scss">
page {
background-color: #f7f7f7;
}
.paysuc {
color: #81bd3f;
}
.coupne-btn {
position: fixed;
bottom: 0px;
background-color: #089bf5;
color: #FFFFFF;
border-radius: 0px;
}
</style>

@ -0,0 +1,35 @@
<template>
<view>
<image src="../static/coupsucces.png" mode="widthFix" class="sucimg mart30"></image>
<view class="width90 clor4cd964 mart30 font18 fotct">支付成功</view>
<view class="width90 height45l backcor89 fcorfff fotct border-r mart80" @click="jumpcoupon">查看我的优惠券</view>
</view>
</template>
<script>
export default {
data() {
return {
}
},
methods: {
jumpcoupon(){
uni.switchTab({
url:'../../pages/tabBar/user/user'
})
}
}
}
</script>
<style lang="scss">
.sucimg {
width: 20%;
margin-left: 40%;
}
.clor4cd964 {
color: #4cd964;
}
</style>

@ -0,0 +1,908 @@
<template>
<view>
<view class="width94 comorder mart10">
<view class="height100p width94 goodsimg">
<image class="flleft" mode="widthFix" :src="imageUrl+couponList.packageDetail.listImg"></image>
<view class="tcrig">
<view class="font18 fontwig6 fcor333 text1">{{couponList.packageDetail.title}}</view>
<view class="font13 fcor666 mart10">规格: 默认</view>
<view class="price-number mart10">
<view class="price font16">{{couponList.packageDetail.price}}</view>
<view class="flright fotrt paddleft10">x1</view>
</view>
</view>
</view>
<view class="width94 line1 mart5 marb5"></view>
<view class="height50 width100 backcorfff">
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
商品总额
</view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor999">
{{couponList.packageDetail.price}}
</view>
</view>
</view>
<view class="width94 comorder mart10">
<view class="height50 width100 backcorfff">
<view class="width50 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
支付方式
</view>
</view>
<view class="width94 line1 mart5 marb5"></view>
<view class="height50 width100 backcorfff" @tap="paytype='jinbi'">
<view class="width70 flleft fcor333 fontwig6 font16 text1" style="padding-left: 4%;">
积分支付<text class="font14 fcor666 margle">可用积分: {{user.gold}}</text>
</view>
<view class="width20 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun"
style="align-items: center;">
<radio :checked="paytype=='jinbi'" color="#0083f5" />
</view>
</view>
<view class="width94 line1 mart5 marb5"></view>
<view class="height50 width100 backcorfff" @tap="paytype='weixin'">
<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;">
<radio :checked="paytype=='weixin'" color="#0083f5" />
</view>
</view>
<view class="width94 line1 mart5 marb5"></view>
<view class="height50 width100 backcorfff" @tap="paytype='gonghuika'">
<view class="width70 flleft fcor333 fontwig6 font16 text1" 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;">
<radio :checked="paytype=='gonghuika'" @click="changeRiado()" color="#0083f5" />
</view>
</view>
</view>
<view class="width100 height60"></view>
<view class="footer">
<view class="settlement">
<view class="sum">实付:<view class="money" v-if="paytype != 'jinbi'">{{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>
<!-- #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-else @tap="toPay">立即支付</button>
<!-- #endif -->
</view>
</view>
<ssPaymentPassword ref="paymentPassword" :mode="1" @submit="submitHandle" />
</view>
</template>
<script>
import {
addOrder,
getDiscountPackageDetail,
loginByPhone,
orderToPay,
orderToGoldPay,
findUser,
hltUnionCardPay,
getHuiLianTongCardBalance
} from '../../Utils/Api.js';
import ssPaymentPassword from '../../components/sanshui-payment-password'
let app = getApp();
// #ifdef H5
var jweixin = require('jweixin-module');
// #endif
export default {
components: {
ssPaymentPassword
},
data() {
return {
buylist: [], //
goodsPrice: 0.0, //
sumPrice: 0.0, //
freight: 12.00, //
note: '', //
int: 1200, //
deduction: 0, //
couponId: '',
couponList: [],
UserNormalDiscountList: [],
imageUrl: app.globalData.imgUrl,
deductionPrice: '0.00',
paytheprice: '',
radioStatus: true,
memDiscountId: '',
user: '',
paytype: '',
PaymentPassword: '',
orderId: '',
jumpType: '',
tongCardPrice: 0,
storeId: '',
isDiscont: false
};
},
onLoad(option) {
this.couponId = option.id;
this.getDiscountPackageDetail();
},
onShow() {
let that = this;
that.paytype = '';
that.user = app.globalData.userInfo;
that.findUser();
},
onHide() {
},
onBackPress() {
//退
},
filters: {
toFixed: function(x) {
return parseFloat(x).toFixed(2);
},
//
formatDate: function(value, spe = '/') {
let data = new Date(value);
let year = data.getFullYear();
let month = data.getMonth() + 1;
let day = data.getDate();
let h = data.getHours();
let mm = data.getMinutes();
let s = data.getSeconds();
month = month >= 10 ? month : "0" + month;
day = day >= 10 ? day : "0" + day;
h = h >= 10 ? h : "0" + h;
mm = mm >= 10 ? mm : "0" + mm;
s = s >= 10 ? s : "0" + s;
return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`;
}
},
methods: {
//
findUser() {
let params;
findUser(params).then(res => {
if (res.return_code == '000000') {
app.globalData.userInfo = res.return_data;
this.user = res.return_data;
this.getHuiLianTongCardBalance();
uni.setStorage({
key: "user",
data: res.return_data
})
}
});
},
//
getDiscountPackageDetail() {
uni.showLoading({
title: '加载中...'
})
let params = {
packageId: this.couponId
}
getDiscountPackageDetail(params).then(res => {
uni.hideLoading();
if (res.return_code == '000000') {
this.couponList = res.return_data;
this.paytheprice = res.return_data.packageDetail.price;
}
})
},
//
showPopup() {
this.$refs.popup.show();
},
//
//
getHuiLianTongCardBalance() {
let params = {
cardNo: this.user.hltCardNo.cardNo
}
getHuiLianTongCardBalance(params).then(res => {
if (res.return_code == '000000') {
this.tongCardPrice = res.return_data.balance;
}
});
},
// H5
jumpH5Bding() {
uni.navigateTo({
url:'../../pages/login/register'
})
},
//
loginByPhone(PhoneNumber) {
if (PhoneNumber.detail.iv == undefined) {
uni.showToast({
title: "用户取消授权",
icon: "none"
});
return;
}
let params = {
openId: app.globalData.openId,
iv: PhoneNumber.detail.iv,
encryptedData: PhoneNumber.detail.encryptedData
}
loginByPhone(params).then(res => {
if (res.return_code == '000000') {
app.globalData.userInfo = res.return_data
.object
.highUser;
this.user = res.return_data
.object
.highUser;
app.globalData.token = res.return_data.uniqueCode;
uni.setStorage({
key: "token",
data: res.return_data.uniqueCode
})
uni.setStorage({
key: "user",
data: res.return_data
.object
.highUser
})
let that = this;
that.toPay();
}
});
},
toPay() {
if (this.paytype == '') {
uni.showToast({
title: '请选择支付方式',
icon: 'none',
duration: 2000
})
return;
}
uni.showLoading({
title: '提交订单中...'
})
if (this.couponList.reserveStatus) {
this.storeId = app.globalData.storeid
}
let goods = {
"highChildOrderList": [{
"goodsType": 7,
"goodsId": this.couponId,
"saleCount": 1,
"storeId": this.storeId
}]
}
addOrder(goods).then(res => {
if (res.return_code == '000000') {
uni.hideLoading();
this.jumpType = res.return_data.highChildOrderList[0].ext1;
this.orderId = res.return_data.id;
this.orderToPay(res.return_data);
} else {
uni.hideLoading();
uni.showToast({
title: res.return_msg,
icon: 'none',
duration: 2000
});
}
})
},
//
changeRiado() {
if (!this.user.isSetHltCard) {
uni.showToast({
icon: 'none',
title: '当前账号还未绑定,前往绑定',
duration: 2000,
success() {
setTimeout(() => {
uni.navigateTo({
url:'../../pages/user/bindingCard/bindingCard'
})
}, 1000)
}
});
return;
}
},
//
orderToPay(item) {
let that = this;
if (that.paytype == 'weixin') {
// #ifdef H5
let params = {
"orderId": item.id,
"openId": app.globalData.openId,
"orderScene": "GOODS_ORDER",
"openIdType": 2
}
// #endif
// #ifdef MP
let params = {
"orderId": item.id,
"openId": app.globalData.openId,
"orderScene": "GOODS_ORDER"
}
// #endif
orderToPay(params).then(res => {
if (res.return_code == '000000') {
// #ifdef MP
uni.showLoading({
title: '支付中...'
})
uni.requestPayment({
"appId": res.return_data.appId,
"nonceStr": res.return_data.nonceStr,
"package": res.return_data.package,
"paySign": res.return_data.sign,
"signType": "MD5",
"timeStamp": res.return_data.timeStamp,
success: function(res) {
uni.hideLoading();
uni.showToast({
title: '支付成功'
})
app.globalData.storeid = '';
app.globalData.storename = '';
uni.reLaunch({
url:'../coupon-comfirmation-success/coupon-comfirmation-success'
});
},
fail: function(err) {
uni.hideLoading();
uni.navigateBack({})
},
});
// #endif
//
// #ifdef H5
//
that.payRequest(res);
// #endif
} else {
uni.showToast({
title: res.return_msg,
icon: 'none'
})
}
})
} else if (that.paytype == 'jinbi') {
if (that.user.gold < that.paytheprice * 100) {
uni.showToast({
icon: 'none',
title: '积分不足',
duration: 2000,
success() {
setTimeout(() => {
uni.navigateTo({
url:'../../pages/user/deposit/deposit'
})
}, 1000)
}
});
return;
}
if (!that.user.isSetPayPwd) {
uni.navigateTo({
url:'../../pages/login/updatePas/updatePas'
})
return;
}
that.$refs.paymentPassword.modalFun('show');
} else if (that.paytype == 'gonghuika') {
if (that.tongCardPrice < that.paytheprice) {
uni.showToast({
icon: 'none',
title: '工会卡余额不足',
duration: 2000,
});
return;
}
if (!that.user.isSetPayPwd) {
uni.navigateTo({
url:'../../pages/login/updatePas/updatePas'
})
return;
}
if (!that.user.isSetHltCard) {
uni.showToast({
icon: 'none',
title: '当前账号还未绑定,前往绑定',
duration: 2000,
success() {
setTimeout(() => {
uni.navigateTo({
url:'../../pages/user/bindingCard/bindingCard'
})
}, 1000)
}
});
return;
}
that.$refs.paymentPassword.modalFun('show');
} else {
uni.showToast({
title: '请选择支付方式',
icon: 'none',
duration: 2000
})
}
},
submitHandle(e) {
this.PaymentPassword = e.value;
if (this.PaymentPassword == '') {
uni.showToast({
title: '请勿手动关闭弹窗',
icon: 'none',
duration: 2000
})
return;
}
uni.showLoading({
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 = {
"orderId": this.orderId,
"cardNo": this.user.hltCardNo.cardNo,
"password": this.PaymentPassword
}
hltUnionCardPay(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'
})
})
},
payRequest: function(self) {
uni.showLoading({
title: '支付中...'
})
jweixin.config({
// debug: false, // ,apialertpclogpc
appId: self.return_data.appId, //
timestamp: self.return_data.timeStamp, //
nonceStr: self.return_data.nonceStr, //
signature: self.return_data.sign, // 1
jsApiList: ['chooseWXPay'] // 使JSJS2
});
uni.hideLoading();
jweixin.ready(function() {
jweixin.checkJsApi({
jsApiList: ['chooseWXPay'], // JSJS2,
success: function(res) {},
fail: function(res) {}
});
jweixin.chooseWXPay({
appId: self.return_data.appId,
timestamp: self.return_data
.timeStamp, // jssdk使timestamp使timeStampS
nonceStr: self.return_data.nonceStr, // 32
package: self.return_data
.package, // prepay_idprepay_id=***
signType: 'MD5', // 'SHA1'使'MD5'
paySign: self.return_data.sign, //
success: function(res) {
//
uni.showToast({
title: '支付成功'
})
uni.reLaunch({
url:'../coupon-comfirmation-success/coupon-comfirmation-success'
});
},
cancel: function(r) {},
fail: function(res) {}
});
});
jweixin.error(function(res) {
uni.showToast({
icon: 'none',
title: '支付失败了',
duration: 4000
});
});
},
}
}
</script>
<style lang="scss">
page {
background-color: #f7f7f7;
}
.comorder {
background-color: #FFFFFF;
border-radius: 8px;
}
.jtcs {
width: 40rpx;
height: 40rpx;
margin-top: 30rpx;
}
.goodsimg {
align-items: center;
display: flex;
image {
width: 170rpx;
max-height: 170rpx;
}
}
.yhprice {
width: 100%;
height: 25px;
text-align: right;
margin-top: -20px;
}
.price-number {
width: 100%;
display: flex;
justify-content: space-between;
align-items: flex-end;
font-size: 28upx;
height: 40upx;
.price {
color: #FE4545;
display: flex;
max-width: 50%;
align-items: center;
}
.number {
display: flex;
align-items: center;
width: 50%;
text-decoration: line-through;
}
}
.yhqky {
background: #ff0034;
color: #ffffff;
font-size: 14px;
padding-left: 5px;
padding-right: 5px;
margin-left: 8px;
padding-top: 2px;
padding-bottom: 2px;
}
.addr {
width: 86%;
padding: 20upx 3%;
margin: 30upx auto 20upx auto;
box-shadow: 0upx 5upx 20upx rgba(0, 0, 0, 0.1);
border-radius: 20upx;
display: flex;
.icon {
width: 80upx;
height: 80upx;
display: flex;
align-items: center;
image {
width: 60upx;
height: 60upx;
}
}
.tel-name {
width: 100%;
display: flex;
font-size: 32upx;
.tel {
margin-left: 40upx;
}
}
.addres {
width: 100%;
font-size: 26upx;
color: #999;
}
}
.tccs {
box-shadow: 0rpx 0rpx 10rpx rgba(0, 0, 0, 0.2);
border: 1px solid #f6f6f6;
border-radius: 8px;
align-items: center;
display: flex;
image {
width: 170rpx;
max-height: 170rpx;
}
}
.tcrig {
margin-left: 20rpx;
}
.info {
display: flex;
justify-content: space-between;
align-items: flex-end;
width: 92%;
}
.order {
width: 86%;
padding: 10upx 3%;
margin: 30upx auto 20upx auto;
box-shadow: 0upx 5upx 20upx rgba(0, 0, 0, 0.1);
border-radius: 20upx;
.row {
margin: 20upx 0;
height: 40upx;
display: flex;
.left {
font-size: 28upx;
}
.right {
margin-left: 40upx;
font-size: 26upx;
color: #999;
input {
font-size: 26upx;
color: #999;
}
}
}
}
.footer {
width: 92%;
padding: 0 4%;
background-color: #fbfbfb;
height: 100upx;
display: flex;
justify-content: flex-end;
align-items: center;
font-size: 28upx;
position: fixed;
bottom: 0upx;
z-index: 5;
.settlement {
width: 100%;
display: flex;
justify-content: flex-end;
align-items: center;
.sum {
width: 50%;
font-size: 18px;
margin-right: 10upx;
display: flex;
justify-content: flex-start;
.money {
color: #eb5823;
font-weight: 600;
}
}
.btn {
padding: 0 50rpx;
height: 80rpx;
background-color: #0083f5;
color: #fff;
display: flex;
justify-content: center;
align-items: center;
font-size: 30upx;
border-radius: 40upx;
}
}
}
.goods-list {
width: 100%;
padding: 0;
.tis {
width: 100%;
height: 60upx;
display: flex;
justify-content: center;
align-items: center;
font-size: 32upx;
}
.row {
width: calc(92%);
height: calc(22vw + 40upx);
margin: 20upx auto;
border-radius: 15upx;
box-shadow: 0upx 5upx 20upx rgba(0, 0, 0, 0.1);
display: flex;
align-items: center;
position: relative;
overflow: hidden;
z-index: 4;
border: 0;
.menu {
.icon {
color: #fff;
// font-size: 25upx;
}
position: absolute;
width: 30%;
height: 100%;
right: 0;
display: flex;
justify-content: center;
align-items: center;
background-color: red;
color: #fff;
z-index: 2;
}
.carrier {
.checkbox-box {
padding-left: 20upx;
flex-shrink: 0;
height: 22vw;
margin-right: 20upx;
}
position: absolute;
width: 94%;
margin-left: 3%;
padding: 0 0;
height: 100%;
z-index: 3;
display: flex;
align-items: center;
.goods-info {
width: 100%;
display: flex;
padding-right: 20upx;
.img {
width: 22vw;
height: 22vw;
border-radius: 10upx;
overflow: hidden;
flex-shrink: 0;
margin-right: 10upx;
image {
width: 22vw;
height: 22vw;
}
}
.info {
width: 100%;
height: 22vw;
overflow: hidden;
display: flex;
flex-wrap: wrap;
position: relative;
.title {
width: 100%;
font-size: 16px;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
// text-align: justify;
overflow: hidden;
}
.spec {
font-size: 14px;
color: #a7a7a7;
height: 30upx;
display: flex;
align-items: center;
padding: 0;
border-radius: 15upx;
margin-bottom: 20vw;
}
.price-number {
position: absolute;
width: 100%;
bottom: 0upx;
display: flex;
justify-content: space-between;
align-items: flex-end;
font-size: 28upx;
height: 60upx;
}
}
}
}
}
}
</style>

@ -0,0 +1,280 @@
<template>
<view>
<view class="input-box">
<view class="icon search"></view>
<input placeholder="搜索商品" v-model="couponName" placeholder-style="color:#c0c0c0;" @input="toSearch()" />
</view>
<view class="swiper">
<view class="swiper-box">
<swiper circular="true" autoplay="true" @change="swiperChange">
<swiper-item v-for="swiper in swiperList" :key="swiper.id">
<image :src="imageUrl+swiper.imgData"></image>
</swiper-item>
</swiper>
<view class="indicator">
<view class="dots" v-for="(swiper, index) in swiperList"
:class="[currentSwiper >= index ? 'on' : '']" :key="index"></view>
</view>
</view>
</view>
<view v-if="goodsList == '' " class="mart60 fotct font14 fcor666">
<image mode="widthFix" style="width: 70vw;" :src="imagewxUrl+imgadres"></image>
</view>
<view class="width90 height110 mart5" v-for="(row, index) in goodsList" :key="index" @click="toGoods(row.id)">
<image class="goodsimg flleft mart5" mode="widthFix" :src="imageUrl+row.listImg"></image>
<view class="goodsli ">
<view class="text2 fcor333 font14 fontwig6">{{row.title}}</view>
<view class="goodsxg font12 fotct">限购{{row.purchaseNum}}</view>
<view class="info mart10">
<view class="price">
{{row.price}}
</view>
</view>
</view>
</view>
</view>
</template>
<script>
import {
getDiscountPackageList,
getCmsContent,
} from '../../Utils/Api.js';
let app = getApp();
export default {
data() {
return {
goodsList: [],
imagewxUrl: app.globalData.imageWxImg,
imgadres: 'noorder.png',
imageUrl: app.globalData.imgUrl,
//
swiperList: [{
id: 1,
src: 'url1',
img: 'banner2.png'
},
{
id: 2,
src: 'url2',
img: 'banner3.png'
}
],
currentSwiper: 0,
pageNum: 1,
pageSize: 10,
isNoMoreData: false,
typeId: '',
couponName: '',
brandid: '',
goodtyid: ''
};
},
onLoad: function() { //optionobject
uni.setNavigationBarTitle({
title: '优惠券包列表'
});
this.getDiscountPackageList();
this.getCmsContent('CMS_DISCOUNT_BANNER');
},
onPageScroll(e) {
},
//page.json"onReachBottomDistance"
onReachBottom() {
this.getDiscountPackageList();
},
methods: {
//
getCmsContent(item) {
let params = {
regionId: app.globalData.cityId,
categoryCode: item
}
getCmsContent(params).then(res => {
if (res.return_code == '000000') {
this.swiperList = res.return_data;
}
});
},
//
swiperChange(event) {
this.currentSwiper = event.detail.current;
},
//
getDiscountPackageList() {
uni.showLoading({
title: '加载中...'
})
if (this.isNoMoreData) {
uni.hideLoading()
return false;
}
let pagenum = this.pageNum;
let params = {
regionId: app.globalData.cityId,
pageNum: pagenum,
pageSize: this.pageSize,
title: this.couponName
}
getDiscountPackageList(params).then(res => {
if (res.return_code == '000000') {
uni.hideLoading();
this.isNoMoreData = res.return_data.list.length == this.pageSize ? false : true;
this.goodsList = this.goodsList.concat(res.return_data.list);
if (res.return_data.total == (this.pageNum * this.pageSize)) {
this.isNoMoreData = true;
}
this.pageNum = res.return_data.list.length == this.pageSize ? ++pagenum : pagenum;
} else {
this.goodsList = [];
}
})
},
toSearch() {
this.pageNum = 1;
this.pageSize = 10;
this.isNoMoreData = false;
this.goodsList = [];
this.getDiscountPackageList();
},
//
toGoods(e) {
uni.navigateTo({
url: '../coupon-packge-details/coupon-packge-details?id=' + e
});
},
}
}
</script>
<style lang="scss">
.input-box {
width: 90%;
margin-left: 5%;
margin-top: 15px;
height: 70rpx;
background-color: #f5f5f5;
border-radius: 10rpx;
position: relative;
display: flex;
align-items: center;
.icon {
display: flex;
align-items: center;
position: absolute;
top: 2px;
left: 5px;
width: 60upx;
height: 60upx;
font-size: 34upx;
color: #c0c0c0;
}
input {
padding-left: 50upx;
height: 28upx;
font-size: 28upx;
width: 100%;
}
}
.swiper {
width: 100%;
display: flex;
justify-content: center;
margin-top: 20px;
margin-bottom: 20px;
.swiper-box {
width: 92%;
height: 150px;
overflow: hidden;
border-radius: 15upx;
box-shadow: 0upx 8upx 25upx rgba(0, 0, 0, 0.2);
//ios
position: relative;
z-index: 1;
swiper {
width: 100%;
height: 150px;
swiper-item {
image {
width: 100%;
height: 150px;
}
}
}
.indicator {
position: absolute;
bottom: 20upx;
left: 20upx;
background-color: rgba(255, 255, 255, 0.4);
width: 150upx;
height: 5upx;
border-radius: 3upx;
overflow: hidden;
display: flex;
.dots {
width: 0upx;
background-color: rgba(255, 255, 255, 1);
transition: all 0.3s ease-out;
&.on {
width: (100%/3);
}
}
}
}
}
.goodsimg {
width: 90px;
height: 90px;
}
.goodsli {
margin-left: 100px;
padding-top: 5px;
}
.goodsxg {
margin-top: 5px;
border: 1px solid #eb5823;
border-radius: 5px;
color: #eb5823;
width: 55px;
padding: 3px;
}
.info {
display: flex;
justify-content: space-between;
align-items: flex-end;
width: 100%;
.price {
color: #e65339;
font-size: 30upx;
font-weight: 600;
width: 50%;
}
.slogan {
width: 50%;
color: #807c87;
font-size: 24upx;
text-decoration: line-through;
}
}
</style>

@ -0,0 +1,988 @@
<template>
<view>
<!-- #ifdef H5 -->
<view class="header">
<!-- 头部-默认显示 -->
<view class="before" :style="{ opacity: 1 - afterHeaderOpacity, zIndex: beforeHeaderzIndex }">
<view class="back">
<view class="icon xiangqian" @tap="back" v-if="showBack"></view>
</view>
<view class="middle"></view>
</view>
</view>
<!-- #endif -->
<!-- 底部菜单 -->
<view class="footer">
<button class="width100 fotct btnfot" @click="buy">
立即兑换
</button>
</view>
<!-- 商品主图轮播 -->
<view class="swiper-box">
<swiper circular="true" autoplay="true" @change="swiperChange">
<swiper-item v-for="(swiper,index) in swiperList" :key="index">
<image mode="widthFix" :src="imageUrl+swiper" @click="perImage(swiper)"></image>
</swiper-item>
</swiper>
<view class="indicator">{{currentSwiper+1}}/{{swiperList.length}}</view>
</view>
<view class="width100 height60 backcorlr">
<view class="flleft width70 fcorfff">
<view class="font13 mart15 margle20"><text
class="font20 paddleft5">{{goodsData.packageDetail.price}}</text></view>
</view>
<view class="flright width30">
<view class="xgnum">限购{{goodsData.packageDetail.purchaseNum}}</view>
</view>
</view>
<!-- 标题 价格 -->
<view class="info-box goods-info">
<view class="font16 fcor333 fontwig6">
{{goodsData.packageDetail.title}}
</view>
<view class="mart10 width100 font14 fcor999 height20">
<view class="width70 flleft">库存:{{goodsData.packageDetail.totalStock}}</view>
</view>
</view>
<!-- 服务-规则选择 -->
<view class="height60 width100 backcorfff" @click="showPopup()">
<view class="width80p flleft" style="padding-left: 4%;line-height: 60px; ">
优惠券包
</view>
<view class="width15 flright fotct">
<image class="jtcs" src="../../static/img/jt.png"></image>
</view>
</view>
<!-- 详情 -->
<view class="description">
<view class="title"> 商品详情 </view>
<view class="content marb65">
<image mode="widthFix" class="width100" v-for="codes in couponDesc" :key="codes" :src="imageUrl+codes"
@click="perImage(codes)">
</image>
</view>
</view>
<wybPopup ref="popup" type="bottom" width="500" scrollY="true" radius="6" :showCloseIcon="true">
<view class="fotct font18 fontwig6 fcor333 mart10 height30">优惠券包</view>
<view class="width92 height110 tccs mart10" v-for="product in goodsData.discountList" :key="product.id">
<image mode="widthFix" class="flleft" src="../../static/img/logo.png"></image>
<view class="tcrig">
<view class="font16 fontwig6 fcor333 text2">{{ product.discountDetail.discountName}}</view>
<view class="font14 fcor999 mart5">数量: x{{product.num}}</view>
</view>
</view>
</wybPopup>
</view>
</template>
<script>
import {
getDiscountPackageDetail
} from '../../Utils/Api.js';
import wybPopup from '../../components/wyb-popup/wyb-popup.vue';
let app = getApp()
export default {
components: {
wybPopup
},
data() {
return {
//
beforeHeaderzIndex: 11, //
afterHeaderOpacity: 0, //
//
// #ifndef MP
showBack: true,
// #endif
//
swiperList: [],
couponDesc: [],
//
currentSwiper: 0,
//
goodsData: "",
//html
desid: '',
imageUrl: app.globalData.imgUrl,
};
},
filters: {
//
formatDate: function(value, spe = '/') {
let data = new Date(value);
let year = data.getFullYear();
let month = data.getMonth() + 1;
let day = data.getDate();
let h = data.getHours();
let mm = data.getMinutes();
let s = data.getSeconds();
month = month >= 10 ? month : "0" + month;
day = day >= 10 ? day : "0" + day;
h = h >= 10 ? h : "0" + h;
mm = mm >= 10 ? mm : "0" + mm;
s = s >= 10 ? s : "0" + s;
return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`;
}
},
onLoad(option) {
this.desid = option.id;
this.getDiscountPackageDetail();
// #ifdef MP
//
this.showBack = false;
// #endif
//optionobject
},
methods: {
//
getDiscountPackageDetail() {
uni.showLoading({
title: '加载中...'
})
let params = {
packageId: this.desid
}
getDiscountPackageDetail(params).then(res => {
if (res.return_code == '000000') {
this.goodsData = res.return_data;
this.swiperList = res.return_data.packageDetail.bannerImg.split(',');
this.couponDesc = res.return_data.packageDetail.detailsImg.split(',');
uni.hideLoading()
} else {
uni.hideLoading()
}
})
},
//
showPopup() {
this.$refs.popup.show();
},
//
perImage(item) {
uni.previewImage({
current: 0, //
urls: [this.imageUrl + item] //
})
},
//
swiperChange(event) {
this.currentSwiper = event.detail.current;
},
buy() {
let that = this;
if (that.goodsData.totalStock == 0) {
uni.showToast({
title: '库存不足',
icon: 'none',
duration: 2000
})
return;
}
uni.showToast({
title: '提交订单...',
icon: 'none',
duration: 2000,
success() {
uni.navigateTo({
url: '../coupon-comfirmation/coupon-comfirmation?id=' + that.desid
})
}
})
},
//
back() {
uni.navigateBack();
},
}
};
</script>
<style lang="scss">
page {
background-color: #f8f8f8;
}
button::after {
border: none
}
.jtcs {
width: 40rpx;
height: 40rpx;
margin-top: 40rpx;
}
.tccs {
box-shadow: 0rpx 0rpx 10rpx rgba(0, 0, 0, 0.2);
border: 1px solid #f6f6f6;
border-radius: 8px;
align-items: center;
display: flex;
image {
width: 170rpx;
max-height: 170rpx;
}
}
.tcrig {
margin-left: 20rpx;
}
.info {
display: flex;
justify-content: space-between;
align-items: flex-end;
width: 92%;
.price {
color: #e65339;
font-size: 15px;
font-weight: 600;
display: flex;
align-items: center;
}
.slogan {
color: #807c87;
font-size: 24upx;
text-decoration: line-through;
}
}
.xgnum {
background-color: #FFFFFF;
color: #ff722e;
height: 30px;
line-height: 30px;
font-size: 13px;
width: 60%;
padding-left: 5%;
padding-right: 5%;
border-radius: 15px;
margin-top: 15px;
text-align: center;
font-weight: 600;
}
@keyframes showPopup {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
@keyframes hidePopup {
0% {
opacity: 1;
}
100% {
opacity: 0;
}
}
@keyframes showLayer {
0% {
transform: translateY(0);
}
100% {
transform: translateY(-100%);
}
}
@keyframes hideLayer {
0% {
transform: translateY(-100%);
}
100% {
transform: translateY(0);
}
}
.icon {
font-size: 26upx;
}
.status {
width: 100%;
height: 0;
position: fixed;
z-index: 10;
top: 0;
/* #ifdef APP-PLUS */
height: var(--status-bar-height); //
/* #endif */
background-color: #f1f1f1;
transition: opacity 0.05s linear;
}
.header {
width: 100%;
height: 100upx;
display: flex;
align-items: center;
position: fixed;
top: 0;
z-index: 10;
/* #ifdef APP-PLUS */
top: var(--status-bar-height);
/* #endif */
.before,
.after {
width: 92%;
padding: 0 4%;
height: 100upx;
display: flex;
align-items: center;
position: fixed;
top: 0;
/* #ifdef APP-PLUS */
top: var(--status-bar-height);
/* #endif */
transition: opacity 0.05s linear;
.back {
width: 125upx;
height: 60upx;
flex-shrink: 0;
.icon {
margin-left: -10%;
width: 60upx;
height: 60upx;
display: flex;
align-items: center;
justify-content: center;
font-size: 42upx;
}
}
.middle {
width: 100%;
}
.icon-btn {
width: 125upx;
height: 60upx;
flex-shrink: 0;
display: flex;
.icon {
&:first-child {
margin-right: 5upx;
}
width: 60upx;
height: 60upx;
display: flex;
justify-content: center;
align-items: center;
font-size: 42upx;
}
}
}
.before {
.back {
.icon {
color: #fff;
background-color: rgba(0, 0, 0, 0.2);
border-radius: 100%;
}
}
.icon-btn {
.icon {
color: #fff;
background-color: rgba(0, 0, 0, 0.2);
border-radius: 100%;
}
}
}
.after {
background-color: #f1f1f1;
.back {
.icon {
color: #666;
}
}
.icon-btn {
.icon {
color: #666;
}
}
.middle {
font-size: 32upx;
height: 90upx;
display: flex;
justify-content: center;
align-items: center;
padding: 0 7%;
view {
width: (100%/3);
padding: 0 3%;
margin: 0 3%;
display: flex;
justify-content: center;
align-items: center;
&.on {
margin-bottom: -4upx;
color: #f47952;
border-bottom: solid 4upx #f47952;
}
}
}
}
}
.swiper-box {
position: relative;
width: 100%;
swiper {
width: 100%;
swiper-item {
image {
width: 100%;
}
}
}
.indicator {
display: flex;
justify-content: center;
align-items: center;
padding: 0 25upx;
height: 40upx;
border-radius: 40upx;
font-size: 22upx;
position: absolute;
bottom: 20upx;
right: 20upx;
color: #fff;
background-color: rgba(0, 0, 0, 0.2);
}
}
.info-box {
width: 92%;
padding: 4%;
background-color: #fff;
margin-bottom: 20rpx;
}
.goods-info {
.price {
font-size: 15px;
font-weight: 600;
color: #f47925;
}
.zprice {
text-decoration: line-through;
}
.title {
font-size: 30upx;
}
}
.spec {
.row {
width: 100%;
display: flex;
align-items: center;
margin: 5px 0 5px 0;
.text {
font-size: 24upx;
color: #a2a2a2;
margin-right: 20upx;
}
.content {
font-size: 28upx;
display: flex;
flex-wrap: wrap;
.serviceitem {
margin-right: 10upx;
}
.sp {
width: 100%;
display: flex;
view {
background-color: #f6f6f6;
padding: 5upx 10upx;
color: #999;
margin-right: 10upx;
font-size: 20upx;
border-radius: 5upx;
&.on {
border: solid 1upx #f47952;
padding: 4upx 8upx;
}
}
}
}
.arrow {
position: absolute;
right: 4%;
.icon {
color: #ccc;
}
}
}
}
.comments {
.row {
width: 100%;
height: 40upx;
display: flex;
align-items: center;
margin: 0 0 30upx 0;
.text {
font-size: 30upx;
}
.arrow {
font-size: 28upx;
position: absolute;
right: 4%;
color: #17e6a1;
.show {
display: flex;
align-items: center;
.icon {
color: #17e6a1;
}
}
}
}
.comment {
width: 100%;
.user-info {
width: 100%;
height: 40upx;
display: flex;
align-items: center;
.face {
width: 40upx;
height: 40upx;
margin-right: 8upx;
image {
width: 40upx;
height: 40upx;
border-radius: 100%;
}
}
.username {
font-size: 24upx;
color: #999;
}
}
.content {
margin-top: 10upx;
font-size: 26upx;
}
}
}
.description {
.title {
width: 100%;
height: 80upx;
display: flex;
justify-content: center;
align-items: center;
font-size: 26upx;
color: #999;
}
}
.footer {
position: fixed;
bottom: 0upx;
width: 100%;
height: 99upx;
color: #FFFFFF;
border-top: solid 1upx #eee;
background-color: #0083f5;
z-index: 2;
display: flex;
justify-content: space-between;
align-items: center;
.btnfot {
text-align: center;
padding: 0;
border-radius: 0;
height: 48px;
background-color: #0083f5;
color: #ffffff;
}
.icons {
display: flex;
height: 80upx;
margin-left: -4%;
.box {
width: 80upx;
height: 80upx;
display: flex;
justify-content: center;
flex-wrap: wrap;
.icon {
font-size: 40upx;
color: #828282;
}
.text {
display: flex;
justify-content: center;
width: 100%;
font-size: 22upx;
color: #666;
}
}
}
.btn {
height: 80upx;
border-radius: 40upx;
overflow: hidden;
display: flex;
margin-right: -2%;
.joinCart,
.buy {
height: 80upx;
padding: 0 40upx;
color: #fff;
display: flex;
align-items: center;
font-size: 28upx;
}
.joinCart {
background-color: #f0b46c;
}
.buy {
background-color: #0083f5;
}
}
}
.popup {
position: fixed;
top: 0;
width: 100%;
height: 100%;
z-index: 20;
display: none;
.mask {
position: fixed;
top: 0;
width: 100%;
height: 100%;
z-index: 21;
background-color: rgba(0, 0, 0, 0.6);
}
.layer {
position: fixed;
z-index: 22;
bottom: -70%;
width: 92%;
padding: 0 4%;
height: 70%;
border-radius: 20upx 20upx 0 0;
background-color: #fff;
display: flex;
flex-wrap: wrap;
align-content: space-between;
.content {
width: 100%;
padding: 20upx 0;
}
.btn {
width: 100%;
height: 100upx;
.button {
width: 100%;
height: 80upx;
border-radius: 40upx;
color: #fff;
display: flex;
align-items: center;
justify-content: center;
background-color: #f47952;
font-size: 28upx;
}
}
}
&.show {
display: block;
.mask {
animation: showPopup 0.2s linear both;
}
.layer {
animation: showLayer 0.2s linear both;
}
}
&.hide {
display: block;
.mask {
animation: hidePopup 0.2s linear both;
}
.layer {
animation: hideLayer 0.2s linear both;
}
}
&.none {
display: none;
}
&.service {
.row {
margin: 30upx 0;
.title {
font-size: 30upx;
margin: 10upx 0;
}
.description {
font-size: 28upx;
color: #999;
}
}
}
&.spec {
.title {
font-size: 30upx;
margin: 30upx 0;
}
.sp {
display: flex;
view {
font-size: 28upx;
padding: 5upx 20upx;
border-radius: 8upx;
margin: 0 30upx 20upx 0;
background-color: #f6f6f6;
&.on {
padding: 3upx 18upx;
border: solid 1upx #f47925;
}
}
}
.length {
margin-top: 30upx;
border-top: solid 1upx #aaa;
display: flex;
justify-content: space-between;
align-items: center;
padding-top: 20upx;
.text {
font-size: 30upx;
}
.number {
display: flex;
justify-content: center;
align-items: center;
.input {
width: 80upx;
height: 60upx;
margin: 0 10upx;
background-color: #f3f3f3;
display: flex;
justify-content: center;
align-items: center;
text-align: center;
input {
width: 80upx;
height: 60upx;
display: flex;
justify-content: center;
align-items: center;
text-align: center;
font-size: 26upx;
}
}
.sub,
.add {
width: 60upx;
height: 60upx;
background-color: #f3f3f3;
border-radius: 5upx;
.icon {
font-size: 30upx;
width: 60upx;
height: 60upx;
display: flex;
justify-content: center;
align-items: center;
}
}
}
}
}
}
.share {
display: none;
&.show {
display: block;
.mask {
animation: showPopup 0.15s linear both;
}
.layer {
animation: showLayer 0.15s linear both;
}
}
&.hide {
display: block;
.mask {
animation: hidePopup 0.15s linear both;
}
.layer {
animation: hideLayer 0.15s linear both;
}
}
&.none {
display: none;
}
.mask {
background-color: rgba(0, 0, 0, .5);
position: fixed;
width: 100%;
height: 100%;
top: 0;
z-index: 11;
}
.layer {
width: 92%;
position: fixed;
z-index: 12;
padding: 0 4%;
top: 100%;
background-color: rgba(255, 255, 255, 0.9);
.list {
width: 100%;
display: flex;
padding: 10upx 0 30upx 0;
.box {
width: 25%;
display: flex;
justify-content: center;
flex-wrap: wrap;
image {
width: 13.8vw;
height: 13.8vw;
}
.title {
margin-top: 10upx;
display: flex;
justify-content: center;
width: 100%;
font-size: 26upx;
}
}
}
.btn {
width: 100%;
height: 100upx;
display: flex;
justify-content: center;
align-items: center;
font-size: 28upx;
border-top: solid 1upx #666666;
}
.h1 {
width: 100%;
height: 80upx;
display: flex;
justify-content: center;
align-items: center;
font-size: 34upx;
}
}
}
</style>

@ -15,7 +15,8 @@
<view class="list">
<view class="box" :class="{'on':item.id == inputAmountId}" v-for="(item,index) in amountList" :key="index"
@click="select(item)">
<view class="heTitle">{{item.price}}</view>
<view class="heTitle">{{item.price}}</view>
<view class="font13 fcor999" v-if="item.status == 2">已售空</view>
</view>
</view>
<view class="mart5 width90 font18 fcor333 fontwig6">
@ -84,7 +85,8 @@
amoutType: '',
codesVlues: '',
amountList: [],
price: ''
price: '',
amoutstatus:''
}
},
onLoad(options) {
@ -120,7 +122,8 @@
select(amoutinfos) {
this.inputAmount = amoutinfos.realPrice;
this.price = amoutinfos.price;
this.inputAmountId = amoutinfos.id;
this.inputAmountId = amoutinfos.id;
this.amoutstatus = amoutinfos.status;
},
/**
@ -145,17 +148,27 @@
* 提交订单
*/
addOrderPay() {
let that = this;
let that = this;
if(that.amoutstatus == 2){
uni.showToast({
title: '当前面值已售空',
duration:2000,
icon: "none"
});
return;
}
if (that.inputPhone == '') {
uni.showToast({
title: '请输入充值号码',
title: '请输入充值号码',
duration:2000,
icon: "none"
});
return;
}
if (that.inputAmount == '') {
uni.showToast({
title: '请选择价格',
title: '请选择价格',
duration:2000,
icon: "none"
});
return false;
@ -305,7 +318,8 @@
width: 94%;
margin-left: 3%;
display: flow-root;
justify-content: space-between;
justify-content: space-between;
align-items: center;
padding: 20upx 0;
.box {
@ -315,7 +329,8 @@
margin-top: 20upx;
float: left;
height: 120upx;
line-height: 120upx;
// line-height: 120upx;
display: inline-grid;
justify-content: center;
align-items: center;
text-align: center;

@ -0,0 +1,95 @@
<template>
<view>
<view class="width90 stoCont" v-for="(store,i) in storeList" :key="i">
<view class="width80p flleft mart10">
<view class="font16 fcor333 fontwig6 text1">{{store.storeName}}</view>
<view class="font13 fcor666 mart10 text1">{{store.address}}</view>
</view>
<view class="width20 flright mart10 fotrt" @click="seeloaction(store)">
<image mode="widthFix" style="width: 25px;height: 25px;" :src="imagewxUrl+imgadres1">
</image>
<view class="mart5 fcor999 font13">{{store.distance}}km</view>
</view>
</view>
</view>
</template>
<script>
import {
getStoreListByCoupon
} from '../../Utils/Api.js';
let app = getApp();
export default {
data() {
return {
storeList: [],
couDesId: '',
imagewxUrl: app.globalData.imageWxImg,
imgadres1: 'dhl.png',
pageNum: 1,
pageSize: 15,
isNoMoreData: false
}
},
onLoad(options) {
this.couDesId = options.id;
this.getStoreListByCoupon();
},
onReachBottom() {
this.getStoreListByCoupon();
},
methods: {
/**
* 查询门店列表
*/
getStoreListByCoupon() {
uni.showLoading({
title: '加载中...'
})
if (this.isNoMoreData) {
uni.hideLoading()
return false;
}
let pagenum = this.pageNum;
let params = {
couponId: this.couDesId,
longitude: app.globalData.longitude,
latitude: app.globalData.latitude,
pageNum: pagenum,
pageSize: this.pageSize
}
getStoreListByCoupon(params).then(res => {
if (res.return_code == '000000' && res.return_data.list != '') {
uni.hideLoading();
this.isNoMoreData = res.return_data.list.length == this.pageSize ? false : true;
this.storeList = this.storeList.concat(res.return_data.list);
if (res.return_data.total == (this.pageNum * this.pageSize)) {
this.isNoMoreData = true;
}
this.pageNum = res.return_data.list.length == this.pageSize ? ++pagenum : pagenum;
} else {
this.storeList = [];
uni.hideLoading()
}
})
},
//
seeloaction(e) {
uni.openLocation({
latitude: Number(e.latitude), //
longitude: Number(e.longitude), //
name: e.storeName,
address: e.address
})
},
}
}
</script>
<style lang="scss">
.stoCont {
border-bottom: 1px solid #f6f6f6;
height: 140rpx;
}
</style>

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.5 KiB

@ -107,14 +107,17 @@
<view class="fotct font18 fontwig6 fcor333 mart10 height30">优惠券选择</view>
<view class="width92 height110 tccs mart10" v-for="(items, index) in OrderPreList" :key="items"
@click="radioChanges(items)">
<image mode="widthFix" class="flleft" :src="imageUrl+items.discountImg"></image>
<view class="tcrig">
<view class="yhprice">
<radio color="#0083f5" :checked="items.id == memDiscountId" />
<image mode="widthFix" class="flleft mart10" :src="imageUrl+items.discountImg"></image>
<view class="contrig">
<view class="width80p flleft">
<view class="font16 fontwig6 fcor333 text1 paddtop25">{{items.discountName}}</view>
<view class="font13 fcor999 mart5">有效期至{{items.useEndTime | timeFormat('yyyy-mm-dd')}}</view>
</view>
<view class="width20 flright">
<view class="yhprice">
<radio color="#0083f5" :checked="items.id == memDiscountId" />
</view>
</view>
<view class="font16 fontwig6 fcor333 text1">{{items.discountName}}</view>
<view class="font13 fcor999 mart5">有效期至{{items.useEndTime | timeFormat('yyyy-mm-dd')}}</view>
</view>
</view>
</wybPopup>
@ -221,7 +224,7 @@
//
getUserOrderPreList() {
let params = {
usingAttribution: 1
useScope: 3
}
getUserOrderPreList(params).then(res => {
if (res.return_code == '000000') {
@ -253,7 +256,7 @@
})
},
radioChanges(item) {
this.paytheprice = this.saveprice;
this.paytheprice = this.orderPrice;
if (this.memDiscountId == item.id) { //
this.memDiscountId = '';
this.payPrice = this.saveprice;
@ -261,27 +264,19 @@
} else { //
this.memDiscountId = item.id;
if (item.discountType == 1) {
if (this.paytheprice > item.discountPrice) {
//
this.deductionPrice = item.discountPrice;
this.payPrice = (((this.paytheprice * 100) - (this.deductionPrice * 100)) /
100);
} else {
uni.showToast({
title: '未满足满减条件',
icon: 'none',
duration: 2000
})
}
//
this.deductionPrice = item.discountPrice;
this.payPrice = this.paytheprice- this.deductionPrice;
} else if (item.discountType == 2) {
//
this.deductionPrice = item.discountPrice;
this.payPrice = (((this.paytheprice * 100) - (this.deductionPrice * 100)) / 100);
this.payPrice = this.paytheprice - this.deductionPrice;
} else if (item.discountType == 3) {
//
this.deductionPrice = this.paytheprice - this.paytheprice * (
item.discountPrice / 10);
this.payPrice = this.paytheprice * (item.discountPrice / 10);
this.deductionPrice = parseFloat(this.paytheprice - (this.paytheprice * item.discountPrice))
.toFixed(2);
this.payPrice = parseFloat(this.paytheprice * item.discountPrice).toFixed(2)
}
}
this.$refs.popup.hide();
@ -333,7 +328,8 @@
uni.showLoading({
title: '提交订单中...'
})
let params = {
let params = {
"memDiscountId": this.memDiscountId,
"orderPrice": this.orderPrice,
"payPrice": this.payPrice,
"rechargeContent": this.rechargeContent,
@ -405,8 +401,12 @@
uni.showToast({
title: '支付成功'
})
uni.switchTab({
url: '../../pages/tabBar/user/user'
// uni.switchTab({
// url: '../../pages/tabBar/user/user'
// })
uni.reLaunch({
url: '../Phone-recharge-details/Phone-recharge-details?id=' +
that.orderId
})
},
fail: function(err) {
@ -492,8 +492,9 @@
uni.showToast({
title: '支付成功'
})
uni.switchTab({
url: '../../pages/tabBar/user/user'
uni.reLaunch({
url: '../Phone-recharge-details/Phone-recharge-details?id=' +
this.orderId
})
return;
}
@ -541,6 +542,7 @@
},
payRequest: function(self) {
let that = this;
uni.showLoading({
title: '支付中...'
})
@ -573,15 +575,10 @@
uni.showToast({
title: '支付成功'
})
if (that.jumpType == 4) {
uni.reLaunch({
url: '/pages/tabBar/user/user'
});
} else {
uni.reLaunch({
url: '../success/success?id=' + that.couponId
});
}
uni.reLaunch({
url: '../Phone-recharge-details/Phone-recharge-details?id=' +
that.orderId
})
},
cancel: function(r) {},
fail: function(res) {}
@ -628,11 +625,7 @@
}
.yhprice {
width: 100%;
height: 25px;
text-align: right;
margin-top: -30px;
margin-left: 50px;
}
.price-number {
@ -713,10 +706,9 @@
box-shadow: 0rpx 0rpx 10rpx rgba(0, 0, 0, 0.2);
border: 1px solid #f6f6f6;
border-radius: 8px;
align-items: center;
display: flex;
image {
float: left;
width: 170rpx;
max-height: 170rpx;
margin-left: 10px;
@ -727,6 +719,10 @@
margin-left: 20rpx;
}
.contrig {
margin-left: 180rpx;
}
.info {
display: flex;
justify-content: space-between;

@ -69,8 +69,8 @@
1: '等待付款',
2: '订单已支付',
3: '订单已完成',
5: '订单已取消',
4: '订单已退款'
4: '订单已取消',
5: '订单已退款'
},
// 退
orderType: ['全部', '待支付', '已支付', '已完成', '已取消', '已退款'],

@ -117,8 +117,13 @@ $uni-font-size-paragraph:30upx;
.font28 {
font-size: 28px;
}
.font48 {
font-size: 48px;
}
// 字体加粗
.fontwig6{
font-weight: bold;
@ -317,6 +322,16 @@ $uni-font-size-paragraph:30upx;
width: 60%;
margin-left: 20%;
}
.width40w {
width: 40%;
margin-left: 30%;
}
.width20w {
width: 20%;
margin-left: 40%;
}
.width35 {
width: 35%;
@ -626,6 +641,11 @@ $uni-font-size-paragraph:30upx;
.line1 {
height: 1px;
background-color: #f4f4f4;
}
.linec6 {
height: 1px;
background-color: #f1f1f1;
}
.line10 {

Loading…
Cancel
Save