1.对接站内信消息

yj-dev
杨杰 3 years ago
parent 328f958b30
commit 67bcc52646
  1. 6
      Utils/Api.js
  2. 523
      pages/order/confirmation.vue
  3. 116
      pages/user/news/news.vue

@ -187,6 +187,12 @@ export const getDiscountByCode = params => {
} }
//站内信列表
export const queryMsgByList = params => {
return POST('GET', `${base}/bsMsg/queryMsgByList`, params).then(res => res.data);
}
// 根据优惠券查卡券 // 根据优惠券查卡券
export const getCouponByDiscount = params => { export const getCouponByDiscount = params => {
return POST('GET', `${base}/discount/getCouponByDiscount`, params).then(res => res.data); return POST('GET', `${base}/discount/getCouponByDiscount`, params).then(res => res.data);

@ -87,107 +87,98 @@
</view> </view>
</view> </view>
</view> </view>
<view class="width94 backcorfff mart10"> <view class="width94 backcorfff mart10">
<view class="width94 alijusstart height50 font14 fcor666"> <view class="width94 alijusstart height50 font14 fcor666">
<view class="width40 fcor333 fontwig6 font16" style="padding-left: 2%;">邀请码</view> <view class="width40 fcor333 fontwig6 font16" style="padding-left: 2%;">邀请码</view>
<input class="width60 fotrt font15" v-model="identificationCode" placeholder="请输入邀请码" /> <input class="width60 fotrt font15" v-model="identificationCode" placeholder="请输入邀请码" />
</view> </view>
</view> </view>
<view class="width94 comorder mart10"> <view class="width94 comorder mart10">
<view class="width92 alijusstart paddtop20"> <view class="width92 alijusstart paddtop20">
<view class="width30 fcor333 fontwig6 font16"> <view class="width30 fcor333 fontwig6 font16">
积分抵扣 积分抵扣
</view> </view>
<view class="cj-slider"> <view class="cj-slider">
<view class="flleft fotct font14 fcor666" style="width: 15%;">0</view> <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" <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" :max="availIntegal" :step="1" :blockWidth="40" @start="blockStart" @moving="blockMoving"
@end="blockEnd" /> @end="blockEnd" />
<!-- <cj-slider style="width: 60%; float:left;" v-if="isDiscount == 2" v-model="priceValue" :min="0" <!-- <cj-slider style="width: 60%; float:left;" v-if="isDiscount == 2" v-model="priceValue" :min="0"
:max="availIntegal" :step="1" :blockWidth="40" @start="blockStart" @moving="blockMoving" :max="availIntegal" :step="1" :blockWidth="40" @start="blockStart" @moving="blockMoving"
@end="blockEnd" /> --> @end="blockEnd" /> -->
<view class="flright fotrt font14 fcor666" style="width: 25%;">{{availIntegal}}</view> <view class="flright fotrt font14 fcor666" style="width: 25%;">{{availIntegal}}</view>
</view>
</view>
<view class="width94 line1 mart15 marb5"></view>
<view class="height50 width100 backcorfff">
<view class="width70 flleft fcor333 fontwig6 font16 text1" style="padding-left: 4%;">
抵扣金额
</view>
<view class="width20 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun"
style="align-items: center;">
¥{{priceValue[1] / 100}}
</view>
</view>
<view class="width94 line1 mart5 marb5"></view>
<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 class="width50 flright fotrt paddtright10 font15 colore95 alijun" v-if="Integrastu == 1"
style="align-items: center;">
{{rebateIntegral}}积分
</view>
<view class="width50 flright fotrt paddtright10 font15 colore95 alijun" v-if="Integrastu == 2"
style="align-items: center;">
{{rebateIntegral}}
</view>
</view>
<view class=" width100 backcorfff alijusstart paddbotm10" style="padding-left: 2%;">
<image src="../../static/img/sigh.png" mode="widthFix" class="icon20"></image>
<text class="fcor999 font13">积分抵扣与优惠券抵扣不同享</text>
</view>
<view class="height50 width100 backcorfff">
<view class="width100 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
支付方式: <text class="jfrecharge" @click="jumpdeposits"
v-if="couponList.payType == 1 || couponList.payType == 2 || couponList.payType==3">积分充值</text>
</view> </view>
</view> </view>
<view class="width94 line1 mart5 marb5"></view> <view class="width94 line1 mart15 marb5"></view>
<view class="height50 width100 backcorfff" <view class="height50 width100 backcorfff">
v-if="couponList.payType == 1 || couponList.payType == 2 || couponList.payType==3" <view class="width70 flleft fcor333 fontwig6 font16 text1" style="padding-left: 4%;">
@tap="paytype='jinbi'"> 抵扣金额
<view class="width70 flleft fcor333 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" <view class="width94 line1 mart5 marb5"></view>
v-if="couponList.payType == 1 || couponList.payType == 2 || couponList.payType==3"></view>
<view class="height50 width100 backcorfff" @tap="paytype='weixin'" <view class="height40 width100 backcorfff">
v-if="couponList.payType == 1 || couponList.payType==3 "> <view class="width40 flleft fcor666 font15 fontwig6 text1 alijusstart" style="padding-left: 2%;">
<view class="width50 flleft fcor333 font16" style="padding-left: 4%;"> <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;">
{{rebateIntegral}}积分
</view>
<view class="width50 flright fotrt paddtright10 font15 colore95 alijun" v-if="Integrastu == 2"
style="align-items: center;"> style="align-items: center;">
<radio :checked="paytype=='weixin'" color="#0083f5" /> {{rebateIntegral}}
</view> </view>
</view> </view>
<view class="width94 line1 mart5 marb5" v-if="couponList.payType == 1 || couponList.payType==3"></view> <view class=" width100 backcorfff alijusstart paddbotm10" style="padding-left: 2%;">
<view class="height50 width100 backcorfff" @tap="paytype='gonghuika'" v-if="couponList.payType== 4"> <image src="../../static/img/sigh.png" mode="widthFix" class="icon20"></image>
<view class="width70 flleft fcor333 font16 text1" style="padding-left: 4%;"> <text class="fcor999 font13">积分抵扣与优惠券抵扣不同享</text>
汇联通工会卡<text class="font14 fcor666 margle">可用余额: {{tongCardPrice}}</text> </view>
<view class="height50 width100 backcorfff">
<view class="width100 flleft fcor333 fontwig6 font16" style="padding-left: 4%;">
支付方式
<!-- : <text class="jfrecharge" @click="jumpdeposits"
v-if="couponList.payType == 1 || couponList.payType == 2 || couponList.payType==3">积分充值</text> -->
</view> </view>
<view class="width20 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun" </view>
style="align-items: center;"> <!-- <view class="width94 line1 mart5 marb5"></view> -->
<radio :checked="paytype=='gonghuika'" @click="changeRiado()" color="#0083f5" /> <view class="width100" v-for="(item,index) in paytypeList" :key="index">
<view class="width94 line1 mart5 marb5"
v-if="item == 2"></view>
<view class="height50 width100 backcorfff" @tap="paytype='2'" v-if="item == 2">
<view class="width50 flleft fcor333 font16" style="padding-left: 4%;">
微信支付
</view>
<view class="width40 flright fotrt paddtright10 font15 fontwig6 fcor666 alijun"
style="align-items: center;">
<radio :checked="paytype=='2'" 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 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=='3'" @click="changeRiado()" color="#0083f5" />
</view>
</view> </view>
</view> </view>
</view> </view>
<!-- <view class="width94 comorder mart10"> <!-- <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="width80p flleft fcor333 fontwig6 font14" style="padding-left: 4%;">
@ -242,7 +233,7 @@
<script> <script>
import { import {
addOrder, addOrder,
create, create,
getCouponById, getCouponById,
loginByPhone, loginByPhone,
@ -250,12 +241,12 @@
orderToPay, orderToPay,
orderToGoldPay, orderToGoldPay,
findUser, findUser,
hltUnionCardPay, hltUnionCardPay,
getRebateIntegral, getRebateIntegral,
getHuiLianTongCardBalance, getHuiLianTongCardBalance,
findById 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 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();
@ -295,14 +286,15 @@
coupondiscountid: '', coupondiscountid: '',
orderDetails: '', // orderDetails: '', //
payGold: '', // payGold: '', //
identificationCode: '' ,// identificationCode: '', //
paytypeList: [], // paytypeList: [], //
priceValue: [0, 0], // priceValue: [0, 0], //
changePrice: '', // changePrice: '', //
isDiscount: true, isDiscount: true,
availIntegal: '', // availIntegal: '', //
isUse: true, // isUse: true, //
rebateIntegral: '', // rechargeDes: '', //
rebateIntegral: '', //
Integrastu: 1 // Integrastu: 1 //
}; };
}, },
@ -349,40 +341,37 @@
return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`; return `${year}${spe}${month}${spe}${day} ${h}:${mm}:${s}`;
} }
}, },
methods: { methods: {
// //
findById() { getThirdPartyByDetail() {
uni.showLoading({ // #ifdef H5
title: '加载中' this.showType = 2;
}) // #endif
let showType; // #ifdef MP
// #ifdef H5 this.showType = 1;
showType = 2; // #endif
// #endif let datas = {
// #ifdef MP platformId: this.showType,
showType = 1; regionId: app.globalData.cityId,
// #endif productType: 4,
let datas = { productId: this.couponList.couponSource
platformId: showType, }
id: this.objectId getThirdPartyByDetail(datas).then(res => {
} if (res.return_code == '000000') {
findById(datas).then(res => { this.rechargeDes = res.return_data;
if (res.return_code == '000000') { this.paytypeList = res.return_data.productPayType.split(',');
uni.hideLoading(); this.paytypeList = this.paytypeList.slice(0, this.paytypeList.length - 1);
this.rechargeDes = res.return_data; let zkprice = parseFloat(res.return_data.integralDiscount / 100).toFixed(2);
this.paytypeList = res.return_data.productPayTypeString.split(','); let pprice = parseFloat(this.totalprice * 100).toFixed(0)
this.paytypeList = this.paytypeList.slice(0, this.paytypeList.length - 1); let payprice = parseFloat(this.totalprice * 100 * zkprice).toFixed(
let zkprice = parseFloat(res.return_data.integralDiscount / 100).toFixed(2); 0);
let pprice = parseFloat(res.return_data.payPrice * 100).toFixed(0) if (payprice > this.user.gold) {
let payprice = parseFloat(res.return_data.payPrice * 100 * zkprice).toFixed( this.availIntegal = this.user.gold;
0); } else {
if (payprice > this.user.gold) { this.availIntegal = payprice;
this.availIntegal = this.user.gold; }
} else { }
this.availIntegal = payprice; });
}
}
});
}, },
// //
findUser() { findUser() {
@ -390,13 +379,13 @@
findUser(params).then(res => { findUser(params).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
app.globalData.userInfo = res.return_data; app.globalData.userInfo = res.return_data;
this.user = res.return_data; this.user = res.return_data;
this.availIntegal = res.return_data.gold; this.availIntegal = res.return_data.gold;
this.findById(); this.findById();
if (this.user.hltCardNo) { if (this.user.hltCardNo) {
this.getHuiLianTongCardBalance(); this.getHuiLianTongCardBalance();
} }
this.getUserNormalDiscountList(); this.getUserNormalDiscountList();
this.getRebateIntegral(); this.getRebateIntegral();
uni.setStorage({ uni.setStorage({
key: "user", key: "user",
@ -404,24 +393,24 @@
}) })
} }
}); });
}, },
// //
getRebateIntegral() { getRebateIntegral() {
let datas = { let datas = {
"companyId": app.globalData.companyId, "companyId": app.globalData.companyId,
"price": this.paytheprice, "price": this.paytheprice,
"productId": 1, "productId": 1,
"type": 1, "type": 1,
} }
getRebateIntegral(datas).then(res => { getRebateIntegral(datas).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
this.rebateIntegral = res.return_data; this.rebateIntegral = res.return_data;
this.Integrastu = 1; this.Integrastu = 1;
} else { } else {
this.rebateIntegral = res.return_msg; this.rebateIntegral = res.return_msg;
this.Integrastu = 2; this.Integrastu = 2;
} }
}) })
}, },
// //
getCouponById() { getCouponById() {
@ -436,6 +425,7 @@
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;
this.getThirdPartyByDetail();
} }
}) })
}, },
@ -617,7 +607,7 @@
// //
orderToPay(item) { orderToPay(item) {
let that = this; let that = this;
if (that.paytype == 'weixin') { if (that.paytype == '2') {
// #ifdef H5 // #ifdef H5
let params = { let params = {
"orderId": item.id, "orderId": item.id,
@ -678,104 +668,7 @@
}) })
} }
}) })
} else if (that.paytype == 'jinbi') { } else if (that.paytype == '3') {
if (that.user.gold < that.paytheprice * 100 && !this.couponList.buyPoints) {
uni.showToast({
icon: 'none',
title: '积分不足',
duration: 2000,
success() {
setTimeout(() => {
uni.navigateTo({
url: '../user/deposit/deposit'
})
}, 1000)
}
});
return;
}
if (that.user.gold < that.paytheprice * 100 && this.couponList.buyPoints) {
uni.showModal({
title: '积分支付',
content: '积分不足,请购买并兑换',
success: function(res) {
if (res.confirm) {
// #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: '../pay/success/success?id=' +
that.couponId
});
},
fail: function(err) {
uni.hideLoading();
uni.navigateBack({})
},
});
// #endif
//
// #ifdef H5
//
that.payRequest(res);
// #endif
} else {
uni.showToast({
title: res.return_msg,
icon: 'none'
})
}
})
}
}
})
return;
}
if (!that.user.isSetPayPwd) {
uni.navigateTo({
url: '../login/updatePas/updatePas'
})
return;
}
that.$refs.paymentPassword.modalFun('show');
} else if (that.paytype == 'gonghuika') {
if (that.tongCardPrice < that.paytheprice) { if (that.tongCardPrice < that.paytheprice) {
uni.showToast({ uni.showToast({
icon: 'none', icon: 'none',
@ -827,37 +720,37 @@
uni.showLoading({ uni.showLoading({
title: '支付中...' title: '支付中...'
}) })
if (this.paytype == 'jinbi') { // if (this.paytype == 'jinbi') {
let params = { // let params = {
"orderId": this.orderId, // "orderId": this.orderId,
"password": this.PaymentPassword // "password": this.PaymentPassword
} // }
orderToGoldPay(params).then(res => { // orderToGoldPay(params).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.storeid = '';
app.globalData.storename = ''; // app.globalData.storename = '';
uni.reLaunch({ // uni.reLaunch({
url: '../pay/success/success?id=' + this.couponId // url: '../pay/success/success?id=' + this.couponId
}); // });
return; // return;
} // }
if (res.return_code == '102130') { // if (res.return_code == '102130') {
uni.navigateTo({ // uni.navigateTo({
url: '../../login/updatePas/updatePas' // url: '../../login/updatePas/updatePas'
}) // })
return; // return;
} // }
uni.showToast({ // uni.showToast({
title: res.return_msg, // title: res.return_msg,
icon: 'none' // icon: 'none'
}) // })
}) // })
return; // return;
} // }
let params = { let params = {
"orderId": this.orderId, "orderId": this.orderId,
@ -948,31 +841,31 @@
duration: 4000 duration: 4000
}); });
}); });
}, },
blockStart() {}, blockStart() {},
blockMoving() { blockMoving() {
// console.log('') // console.log('')
}, },
// //
blockEnd() { blockEnd() {
this.isDiscount = 1; this.isDiscount = 1;
if (this.deductionPrice == 0) { if (this.deductionPrice == 0) {
this.payPrice = parseFloat(this.saveprice - parseFloat(this.priceValue[1] / 100).toFixed(2)).toFixed( this.payPrice = parseFloat(this.saveprice - parseFloat(this.priceValue[1] / 100).toFixed(2)).toFixed(
2); 2);
} else { } else {
this.payPrice = parseFloat(this.orderPrice - parseFloat(this.priceValue[1] / 100).toFixed(2) - this this.payPrice = parseFloat(this.orderPrice - parseFloat(this.priceValue[1] / 100).toFixed(2) - this
.deductionPrice).toFixed(2); .deductionPrice).toFixed(2);
} }
if (this.payPrice == 0) { if (this.payPrice == 0) {
this.isUse = false; this.isUse = false;
this.paytype = ''; this.paytype = '';
} else { } else {
this.isUse = true; this.isUse = true;
} }
this.getRebateIntegral(); this.getRebateIntegral();
}, },
// //
jumpdeposits() { jumpdeposits() {
uni.navigateTo({ uni.navigateTo({
@ -998,12 +891,12 @@
width: 40rpx; width: 40rpx;
height: 40rpx; height: 40rpx;
margin-top: 30rpx; margin-top: 30rpx;
} }
.cj-slider { .cj-slider {
width: 100%; width: 100%;
align-items: center; align-items: center;
display: flex; display: flex;
} }
.goodsimg { .goodsimg {

@ -2,36 +2,50 @@
<view> <view>
<!-- 顶部类型 --> <!-- 顶部类型 -->
<scroll-view scroll-x='true' class="srollview width100" :style="{top:headerTop}" 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 == ''"
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/cusservice.png" mode="widthFix" class="icon30"></image> <image src="../../../static/img/cusservice.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/cusservice.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/cusservice.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,21 +72,65 @@
</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,
headerTop:'0px' imgadres: 'noorder.png',
newsTyplist: [], //
newsList: [], //
newstypeid: 1, //id
headerTop: '0px'
} }
}, },
onLoad() { filters: {
// #ifdef H5 //
this.headerTop = '44px'; msgFormat: function(value,value1) {
// #endif let a = JSON.parse(value);
return a[value1];
}
},
onLoad() {
// #ifdef H5
this.headerTop = '44px';
// #endif
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>
@ -82,9 +140,9 @@
background-color: #f3f3f3; background-color: #f3f3f3;
} }
.srollview { .srollview {
position: fixed; position: fixed;
height: 70px; height: 70px;
background-color: #ffffff; background-color: #ffffff;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
@ -96,8 +154,8 @@
line-height: 24px; line-height: 24px;
margin-top: 15px; margin-top: 15px;
padding-left: 10px; padding-left: 10px;
font-size: 11px; font-size: 11px;
padding-right: 10px; padding-right: 10px;
margin-left: 15px; margin-left: 15px;
display: inline-flex; display: inline-flex;
flex-direction: column; flex-direction: column;

Loading…
Cancel
Save