Commit 49b9c8d6 authored by 罗超's avatar 罗超

Merge branch 'master' of http://gitlab.oytour.com/viitto/mallapp

# Conflicts:
#	plugin/api.js
parents 40e30654 de4529df
<template>
<div class="auth-page">
<u-popup v-model="showDialog" mode="center" custom-style="padding:0;background:none;">
<img :src="pageinfo.pic_url" mode="widthFix" />
<button
:style="sureStyle"
class="hotsopt"
open-type="getUserInfo"
@getuserinfo="getUserInfo"
></button>
<button :style="cancelStyle" class="hotsopt" @click="close"></button>
</u-popup>
</div>
<div class="auth-page">
<u-popup v-model="showDialog" mode="center" :mask-close-able="false" custom-style="padding:0;background:none;">
<img :src="pageinfo.pic_url" mode="widthFix" />
<button :style="sureStyle" class="hotsopt" open-type="getUserInfo" @getuserinfo="getUserInfo"></button>
<button :style="cancelStyle" class="hotsopt" @click="close"></button>
</u-popup>
</div>
</template>
<script>
export default {
data() {
return {
pageinfo: {},
sureStyle: "",
cancelStyle: "",
showDialog: true
};
},
created() {
this.pageinfo = uni.getStorageSync("basedata")
? uni.getStorageSync("basedata").auth_page
: {};
let x = this.pageinfo.hotspot;
let y = this.pageinfo.hotspot_cancel;
this.sureStyle = `height:${x.height}rpx;width:${x.width}rpx;left:${
x.left
}rpx;top:${x.top}rpx;`;
this.cancelStyle = `height:${y.height}rpx;width:${y.width}rpx;left:${
y.left
}rpx;top:${y.top}rpx;`;
},
methods: {
getUserInfo(e) {
if(e.mp.detail.userInfo){
// TODO 实现用户登录
uni.setStorageSync("userinfo", e.mp.detail.userInfo);
this.$emit('changeuserinfo');
}
},
close() {
this.showDialog = false;
}
}
data() {
return {
pageinfo: {},
sureStyle: '',
cancelStyle: '',
showDialog: true
};
},
created() {
this.pageinfo = uni.getStorageSync('basedata') ? uni.getStorageSync('basedata').auth_page : {};
let x = this.pageinfo.hotspot;
let y = this.pageinfo.hotspot_cancel;
this.sureStyle = `height:${x.height}rpx;width:${x.width}rpx;left:${x.left}rpx;top:${x.top}rpx;`;
this.cancelStyle = `height:${y.height}rpx;width:${y.width}rpx;left:${y.left}rpx;top:${y.top}rpx;`;
},
methods: {
getUserInfo(e) {
var that = this;
that.showDialog=true;
uni.getProvider({
service: 'oauth',
success: function(res) {
if (~res.provider.indexOf('weixin')) {
uni.login({
provider: 'weixin',
success: res => {
that.authorization = res.code;
uni.getUserInfo({
provider: 'weixin',
success: info => {
//这里请求接口
let obj = {
Source: 1,
OpenId: '',
Name: info.userInfo.nickName,
Photo: info.userInfo.avatarUrl,
Moblie: '',
SuperiorId: 0,
code: res.code
};
that.getCode(obj);
},
fail: () => {
uni.showToast({ title: '微信登录授权失败', icon: 'none' });
}
});
},
fail: () => {
uni.showToast({ title: '微信登录授权失败', icon: 'none' });
}
});
} else {
uni.showToast({
title: '请先安装微信或升级版本',
icon: 'none'
});
}
}
});
},
close() {
this.showDialog=false;
this.$emit('gbAuth');
},
//调用获取code
getCode(obj) {
var that = this;
uni.getUserInfo({
provider: 'weixin',
success: info => {
//这里请求接口
var OpenId = '';
that.request2(
{
url: '/api/mall/GetWeChatOpenId',
data: {
Code: obj.code
}
},
res => {
if (res.resultCode == 1) {
obj.OpenId = res.data;
that.getLogin(obj);
}
}
);
}
});
},
//登录
getLogin(obj) {
var that = this;
that.request2(
{
url: '/api/AppletLogin/Login',
data: {
Source: 1,
OpenId: obj.OpenId,
Name: obj.nickName,
Photo: obj.avatarUrl,
Moblie: '',
SuperiorId: 0
}
},
res => {
if (res.resultCode == 1) {
uni.setStorageSync('mall_UserInfo', res.data);
that.$emit('changeuserinfo');
}
}
);
}
}
};
</script>
<style>
.auth-page img {
width: 650rpx;
height: 700rpx;
width: 650rpx;
height: 700rpx;
}
.auth-page .hotsopt {
position: absolute;
background: transparent;
border: none;
outline: none;
position: absolute;
background: transparent;
border: none;
outline: none;
}
.auth-page .hotsopt::after{
border:none;
.auth-page .hotsopt::after {
border: none;
}
</style>
\ No newline at end of file
</style>
......@@ -31,7 +31,7 @@
>
<image
:src="c.IconPath"
:src="getIconLink(c.IconPath)"
mode="widthFix"
style="width: 80rpx; height: 80rpx;"
/>
......
......@@ -31,7 +31,7 @@
<view class="goodprice">
<view class="left">
<view v-if="cx.level_price">
<van-tag plain color="#f39800">会员价</van-tag>
<u-tag size="mini" text="会员价" shape="circle" type="warning" />
<span class="vip">{{ cx.level_price }}</span>
</view>
<view class="price" :style="{ color: mainColor }">{{ cx.price_content }}</view>
......@@ -103,7 +103,6 @@ export default {
methods: {
// 购物车
showSkuHandler(g) {
console.log('g', g);
this.sku = g;
this.showSku = true;
},
......
......@@ -94,7 +94,7 @@ export default {
this.active=i
},
clickHandler(item) {
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.Id });
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.id });
},
init() {
this.isover = false;
......
<template>
<div class="catstyle4" style="height: 100%;">
<view class="catstyle4" style="height: 100%;">
<div class="left-slider">
<sidebar
:active="tid"
......@@ -57,7 +57,7 @@
</div>
<div class="sell">{{ cx.sales }}</div>
</div>
<div class="right">
<div @click.stop="showSkuHandler(cx)" class="right">
<!-- todo 点击加入购物车-->
<u-icon name="cart-circle-o" size="44" :color="mainColor" />
</div>
......@@ -67,16 +67,16 @@
<u-divider v-if="isover" :margin-top="20" :margin-bottom="20">没有更多商品了</u-divider>
</scroll-view>
</div>
</div>
<good-sku v-if="showSku" :option-type="2" borderRadius="20" v-model="showSku" :good="sku"></good-sku>
</view>
</template>
<script>
import goodSku from '../goods/goodsku';
import sidebar from "../sidebar/index";
export default {
props: ["d", "h"],
components: {
sidebar,
},
data() {
return {
mainColor: "",
......@@ -98,8 +98,13 @@ export default {
OrderBy:1,
UserId:0,
},
sku: {},
showSku: false
};
},
components: {
sidebar,goodSku
},
created() {
this.mainColor = this.$uiConfig.mainColor;
this.activeStyle = `background:${this.mainColor};`;
......@@ -108,6 +113,11 @@ export default {
this.init();
},
methods: {
// 购物车
showSkuHandler(g) {
this.sku = g;
this.showSku = true;
},
changeHandler(i) {
this.msg.CategoryIds= this.d[i].Id+'';
this.msg.page = 1;
......@@ -116,7 +126,7 @@ export default {
this.init();
},
clickHandler(item) {
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.Id });
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.id });
},
init() {
this.isover = false;
......
......@@ -33,7 +33,7 @@
<image
v-if="x.IconPath && x.IconPath.length > 0"
mode="aspectFit"
:src="getIconLink(c.IconPath)"
:src="getIconLink(x.IconPath)"
style="width: 100%; height: 100%;"
/>
</div>
......
......@@ -130,7 +130,7 @@ export default {
this.init();
},
clickHandler(item) {
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.Id });
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.id });
},
computSecondHeight() {
const query = uni.createSelectorQuery().in(this);
......
......@@ -56,7 +56,7 @@
<view class="price" :style="{ color: mainColor }">{{ cx.price_content }}</view>
<view class="sell">{{ cx.sales }}</view>
</view>
<view class="right">
<view @click.stop="showSkuHandler(cx)" class="right">
<u-icon name="cart-circle-o" size="44" :color="mainColor" />
</view>
</view>
......@@ -71,11 +71,13 @@
</scroll-view>
</view>
</view>
<good-sku v-if="showSku" :option-type="2" borderRadius="20" v-model="showSku" :good="sku"></good-sku>
</view>
</template>
<script>
import sidebar from "../sidebar/index";
import goodSku from '../goods/goodsku';
export default {
props: ["d", "h"],
data() {
......@@ -103,10 +105,12 @@ export default {
CategoryIdsList:[],
CategoryIds1:'',
CategoryIds2:'',
sku: {},
showSku: false
};
},
components: {
sidebar
sidebar,goodSku
},
created() {
this.mainColor = this.$uiConfig.mainColor;
......@@ -123,6 +127,11 @@ export default {
this.init();
},
methods: {
// 购物车
showSkuHandler(g) {
this.sku = g;
this.showSku = true;
},
changeHandler(i) {
this.active=i;
this.CategoryIds1=this.d[i].Id;
......@@ -142,7 +151,7 @@ export default {
this.init();
},
clickHandler(item) {
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.Id });
uni.navigateTo({ url: '/pages/goods/goods?GoodsId='+item.id });
},
init() {
this.CategoryIdsList=[];
......
......@@ -32,12 +32,12 @@
:data-url="cx.page_url"
>
<view class="left">{{ c.Name }}</view>
<view class="left">{{ cx.Name }}</view>
<view class="right">
<image
v-if="cx.IconPath && cx.IconPath!=''"
mode="aspectFit"
:src="cx.IconPath"
:src="getIconLink(cx.IconPath)"
style="width: 100%; height: 100%;"
/>
</view>
......
......@@ -101,13 +101,13 @@ export default {
<style>
.coupon {
min-height: 70vh;
max-height: 70vh;
background: #f5f5f5;
padding-bottom: 50px;
text-align: left !important;
border-top-left-radius: 20rpx;
border-top-right-radius: 20rpx;
overflow: hidden;
overflow: scroll;
}
.coupon .title {
font-size: 22px;
......
<template>
<view
class="actionsheet"
:style="{ 'padding-bottom': bian ? '28px' : '0px' }"
>
<view class="item" style="width:36px;" @click="goCart">
<view style="width: 22px; margin: auto;">
<u-icon name="cart-o" size="44" :color="mc"></u-icon>
</view>
<text class="text" :style="{'color':mc}">购物车</text>
</view>
<view class="item">
<view style="width: 22px; margin: auto;">
<u-icon name="chat-o" size="44" color="#333"></u-icon>
</view>
<text class="text">客服</text>
<button
open-type="contact"
:send-message-title="goodName"
:send-message-path="path"
:send-message-img="g.coverPic"
:show-message-card="true"
>
0
</button>
</view>
<view class="item" @click="setFavorite">
<view style="width: 22px; margin: auto;">
<u-icon
:name="favorStatus ? 'like' : 'like-o'"
size="44"
:color="favorStatus ? mc : '#333'"
></u-icon>
</view>
<text class="text">收藏</text>
</view>
<view class="item2">
<view style="flex: 1;">
<u-button
@click="joinCar"
:ripple="true"
:hair-line="false"
:custom-style="btn1"
>加入购物车</u-button
>
</view>
<view style="flex: 1;">
<u-button
@click="buy"
:ripple="true"
:hair-line="false"
:custom-style="btn2"
>立即购买</u-button
>
</view>
</view>
</view>
<view class="actionsheet" :style="{ 'padding-bottom': bian ? '28px' : '0px' }">
<view class="item" style="width:36px;" @click="goCart">
<view style="width: 22px; margin: auto;"><u-icon name="cart-o" size="44" :color="mc"></u-icon></view>
<text class="text" :style="{ color: mc }">购物车</text>
</view>
<view class="item">
<view style="width: 22px; margin: auto;"><u-icon name="chat-o" size="44" color="#333"></u-icon></view>
<text class="text">客服</text>
<button open-type="contact" :send-message-title="goodName" :send-message-path="path" :send-message-img="g.coverPic" :show-message-card="true">0</button>
</view>
<view class="item" @click="setFavorite">
<view style="width: 22px; margin: auto;"><u-icon :name="favorStatus ? 'like' : 'like-o'" size="44" :color="favorStatus ? mc : '#333'"></u-icon></view>
<text class="text">收藏</text>
</view>
<view class="item2">
<view style="flex: 1;"><u-button @click="joinCar" :ripple="true" :hair-line="false" :custom-style="btn1">加入购物车</u-button></view>
<view style="flex: 1;"><u-button @click="buy" :ripple="true" :hair-line="false" :custom-style="btn2">立即购买</u-button></view>
</view>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth>
</view>
</template>
<script>
import auth from "../../components/auth/index.vue";
export default {
props: ["coverPic", "goodName", "favorite", "goodId"],
data() {
return {
mc: "",
fu: "",
bian: false,
btn1: {
flex: 1,
height: "100%",
borderRadius: "40px 0 0 40px",
border: "none",
color: "#FFF",
fontSize: "13px",
width: "100%",
},
btn2: {
flex: 1,
height: "100%",
borderRadius: "0 40px 40px 0",
border: "none",
color: "#FFF",
fontSize: "13px",
width: "100%",
},
path: "",
favorStatus: false,
};
},
mounted() {
this.mc = this.$uiConfig.mainColor;
this.fu = this.$uiConfig.secondary;
this.bian = this.$utils.is_biang;
this.btn1.background = this.fu;
this.btn2.background = this.mc;
let t = getCurrentPages();
this.path = "/" + t[t.length - 1].route;
//console.log(t[t.length - 1]);
this.favorStatus = this.favorite;
},
methods: {
goCart(){
uni.redirectTo({
url: '/pages/cart/cart'
});
},
setFavorite() {
let h=this.apiheader()
this.request(
{
url: "",
data: {
r: this.favorStatus
? "api/user/favorite-remove"
: "api/user/favorite-add",
goods_id: this.goodId,
},
header:h
},
(res) => {
this.favorStatus = !this.favorStatus;
}
);
},
joinCar() {
this.$emit("join-car");
},
buy() {
this.$emit("buy");
},
},
props: ['coverPic', 'goodName', 'favorite', 'goodId'],
data() {
return {
mc: '',
fu: '',
bian: false,
btn1: {
flex: 1,
height: '100%',
borderRadius: '40px 0 0 40px',
border: 'none',
color: '#FFF',
fontSize: '13px',
width: '100%'
},
btn2: {
flex: 1,
height: '100%',
borderRadius: '0 40px 40px 0',
border: 'none',
color: '#FFF',
fontSize: '13px',
width: '100%'
},
path: '',
favorStatus: false,
//是否显示登陆
showAuth: false,
u: {}
};
},
components: {
auth
},
mounted() {
this.mc = this.$uiConfig.mainColor;
this.fu = this.$uiConfig.secondary;
this.bian = this.$utils.is_biang;
this.btn1.background = this.fu;
this.btn2.background = this.mc;
let t = getCurrentPages();
this.path = '/' + t[t.length - 1].route;
//console.log(t[t.length - 1]);
this.favorStatus = this.favorite;
},
methods: {
goCart() {
uni.redirectTo({
url: '/pages/cart/cart'
});
},
setFavorite() {
this.u = uni.getStorageSync('mall_UserInfo');
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
};
this.showAuth = true;
} else {
this.request2(
{
url: '/api/AppletUser/SetUserCollectionInfo',
data: {
GoodsId: this.goodId
}
},
res => {
this.favorStatus = !this.favorStatus;
}
);
}
},
joinCar() {
this.u = uni.getStorageSync('mall_UserInfo');
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
};
this.showAuth = true;
} else {
this.$emit('join-car');
}
},
buy() {
this.u = uni.getStorageSync('mall_UserInfo');
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
};
this.showAuth = true;
} else{
this.$emit('buy');
}
},
reloadUserinfo() {
this.u = uni.getStorageSync('mall_UserInfo');
this.showAuth = false;
},
//关闭登录窗口
gbAuth(){
this.showAuth=false;
}
}
};
</script>
<style>
.actionsheet {
display: flex;
background: #fff;
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 3;
height: 50px;
align-items: center;
display: flex;
background: #fff;
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 3;
height: 50px;
align-items: center;
}
.actionsheet .item {
display: flex;
flex-direction: column;
justify-content: center;
margin: 0 10px;
color: #333;
font-size: 12px;
padding: 3px 0;
width: 30px;
position: relative;
display: flex;
flex-direction: column;
justify-content: center;
margin: 0 10px;
color: #333;
font-size: 12px;
padding: 3px 0;
width: 30px;
position: relative;
}
.actionsheet .item .text {
margin-top: 2px;
text-align: center;
margin-top: 2px;
text-align: center;
}
.actionsheet .item2 {
flex: 1;
width: 1px;
padding: 5px;
box-sizing: border-box;
margin-left: 10px;
height: 100%;
display: flex;
flex: 1;
width: 1px;
padding: 5px;
box-sizing: border-box;
margin-left: 10px;
height: 100%;
display: flex;
}
.actionsheet .item button {
width: 100%;
height: 100%;
opacity: 0;
left: 0;
top: 0;
position: absolute;
width: 100%;
height: 100%;
opacity: 0;
left: 0;
top: 0;
position: absolute;
}
</style>
......@@ -9,7 +9,7 @@
:safeAreaInsetBottom="true"
@close="popupClose"
:z-index="9999"
close-icon="cross"
close-icon="close"
>
<view class="goodsku">
<view class="goods">
......@@ -21,6 +21,9 @@
</view>
<view class="amount">库存 {{ goodamount }} {{ g.unit }}</view>
<view class="sku">{{ skuObj ? '已选择' : '选择' }} {{ sku }}</view>
<view class="sku_close">
<u-icon name="cross" color="#9F9F9F" @click="cloGood()" size="40"/>
</view>
</view>
</view>
<view class="sku-box">
......@@ -146,7 +149,6 @@ export default {
}
},
res => {
console.log(res, 'resssssss');
this.g = res.data.goods;
this.goodimage = this.g.cover_pic;
......@@ -173,8 +175,8 @@ export default {
this.g.attr_groups.forEach(x => {
if (!this.skuObj) {
//(x.checkId = 0), (x.checkName = x.attr_group_name);
(x.checkId = 0), (x.checkName = x.attr_list[0].attr_name);
x.checkId = x.attr_list[0].attr_id;
(x.checkId = 0), (x.checkName = x.attr_list[0].attr_name);
x.checkId = x.attr_list[0].attr_id;
} else {
let sign = `:${this.skuObj.sign_id}:`;
x.attr_list.forEach(y => {
......@@ -194,7 +196,6 @@ export default {
},
methods: {
joinCar() {
console.log(this.skuObj,'skuObjj');
if (this.skuObj && this.skuObj.id) {
this.request2(
{
......@@ -224,24 +225,38 @@ export default {
}
},
buy() {
let ShoppingCartIdList=[];
if (this.skuObj && this.skuObj.id) {
let good = {
DetailList: [],
Use_Integral: 0,
User_Coupon_Id: 0,
DeliveryMethod:0,
AddressId:0,
};
let g = {
id: this.skuObj.goods_id,
num: this.gc,
cart_id: 0,
goods_attr_id: this.skuObj.id,
attr: []
GoodsId: this.skuObj.goods_id,
Number: this.gc,
SpecificationSort: this.skuObj.sign_id,
};
this.skuObj.attr_list.forEach(x => {
g.attr.push({
attr_id: x.attr_id,
attr_group_id: x.attr_group_id
});
});
this.forms.list[0].goods_list.push(g);
this.forms.list[0].mch_id = this.g.mch_id;
good.DetailList.push(g);
// let g = {
// id: this.skuObj.goods_id,
// num: this.gc,
// cart_id: 0,
// goods_attr_id: this.skuObj.id,
// attr: []
// };
// this.skuObj.attr_list.forEach(x => {
// g.attr.push({
// attr_id: x.attr_id,
// attr_group_id: x.attr_group_id
// });
// });
// this.forms.list[0].goods_list.push(g);
// this.forms.list[0].mch_id = this.g.mch_id;
uni.navigateTo({
url: '/pages/order-submit/order-submit?formData=' + encodeURIComponent(JSON.stringify(this.forms)),
url: '/pages/order-submit/order-submit?formData=' + encodeURIComponent(JSON.stringify(good))+'&IsFormShoppingCart=2&ShoppingCartIdList='+JSON.stringify(ShoppingCartIdList),
complete(res) {
console.log(res);
}
......@@ -255,7 +270,8 @@ export default {
});
}
},
close() {
//关闭弹窗
cloGood() {
this.popupClose();
},
clickSkuItemHandler(index, groupRow) {
......@@ -405,6 +421,12 @@ export default {
margin-left: 15px;
flex: 1;
width: 1px;
position: relative;
}
.goodsku .chosen-info .sku_close{
position: absolute;
right: 4px;
top: 5px;
}
.goodsku .goods .chosen-info .price {
font-size: 24px;
......
......@@ -26,14 +26,14 @@
<image :src="y.cover_pic" mode="aspectFill" class="image" />
<view class="goodinfo">
<view class="name">{{ y.name }}</view>
<view class="attr">已选择 {{ y.attrStr }}</view>
<view class="attr">已选择
<span v-for="(item,index) in y.attr_list" :key="index">{{ item.attr_group_name}}:{{ item.attr_name}}</span>
</view>
<view class="price">
<view class="left" :style="{ color: mc }">
<text class="small"></text>
<text>{{ y.goods_attr.price.split(".")[0] }}</text>
<text class="small"
>.{{ y.goods_attr.price.split(".")[1] || "00" }}</text
>
<text>{{ y.goods_attr.price}}</text>
<!-- <text class="small">.{{ y.goods_attr.price.split(".")[1] || "00" }}</text> -->
</view>
<view class="right">x{{ y.num }}</view>
</view>
......
<template>
<view>
<u-popup
close-icon-color="red"
v-model="show"
mode="center"
:mask-close-able="false"
length="auto"
:closeable="true"
close-icon="close"
:border-radius="20"
:z-index="9999"
>
<view style="background:#fff;width:550rpx;padding:40rpx;border-radius:20px">
<u-icon @click="closePay" name="close" style="float:right;font-size:40rpx"></u-icon>
<p style="text-align: center;font-size: 26rpx;">支付方式</p>
<p style="font-size: 36rpx;font-weight: 700;text-align: center;margin:30px 0">支付金额{{ payInfo.total_price }}</p>
<p>
<img style="width:50rpx;height:50rpx;margin-right:10px" src="../../static/wx.png" alt="" />
<span style="position:relative;top:-7px">微信支付</span>
</p>
<view style="margin-top:30px"><u-button @click="Pay" type="error" shape="circle">支付</u-button></view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
props: ['payInfo'],
data() {
return {
show: true,
orderInfo: {}
};
},
created() {
this.getDataInfo();
},
methods: {
closePay() {
this.$emit('closePay');
},
getDataInfo() {
let that=this;
let msg = {
OpenId: that.payInfo.OpenId,
OrderId: that.payInfo.OrderId,
OrderPayType:that.payInfo.OrderPayType,
GoodsName: that.payInfo.GoodsName
};
this.request2(
{
url: '/api/WeChatPay/GetPayInfo',
data: msg
},
res => {
if (res.resultCode == 1) {
this.orderInfo = JSON.parse(res.data);
}
uni.hideNavigationBarLoading();
}
);
},
Pay() {
let orderInfo = this.orderInfo;
uni.requestPayment({
provider: 'wxpay',
timeStamp: this.orderInfo.timeStamp,
nonceStr: this.orderInfo.nonceStr,
package: this.orderInfo.package,
signType: this.orderInfo.signType,
paySign: this.orderInfo.sign,
success: function(res) {
console.log('success', res);
uni.navigateTo({
url: '/pages/order-submit/pay-success'
});
},
fail: function(err) {
console.log('fail:', err);
}
});
}
}
};
</script>
<style></style>
......@@ -4,7 +4,7 @@
<img :src="u.avatarUrl" />
<div class="text">{{u.nickName}}</div>
</div>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo"></auth>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth>
</div>
</template>
......@@ -22,7 +22,7 @@ export default {
};
},
created() {
this.u = uni.getStorageSync("userinfo");
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
......@@ -33,9 +33,13 @@ export default {
},
methods: {
reloadUserinfo() {
this.u = uni.getStorageSync("userinfo");
this.u = uni.getStorageSync("mall_UserInfo");
this.showAuth=false
}
},
//关闭登录窗口
gbAuth(){
this.showAuth=false;
}
}
};
</script>
......
......@@ -5,9 +5,6 @@
"pages": [{
"path": "pages/index/index"
},
{
"path": "pages/pay/pay/pay"
},
{
"path": "pages/cart/cart"
},
......@@ -57,6 +54,11 @@
},
{
"path": "balance"
},
{
"path": "detail"
},{
"path": "rules"
}
]
},
......
<template>
<view class="AddaddressStyle" :style="{'height':contentHeight}">
<view class="top">
<!-- <view class="top">
<input class="uni-input" placeholder="自动获得焦点" style="width: 70%;"/>
<view style="display: flex;align-items: center;justify-content: center;border: 1px solid #F4AAA6;width:160rpx ;height: 60rpx;">
<Text style='color: #EA5A22;'>自动识别</Text>
</view>
</view>
</view> -->
<view class="addcenter">
<view class="addcenter_item2">
<Text>收货人</Text>
<input class="uni-input inputM" v-model="msg.name" />
<input class="uni-input inputM" v-model="msg.Name" />
</view>
<view style="width: 100%;height: 1px;background: #f5f5f5;"/>
<view class="addcenter_item2">
<Text>联系电话</Text>
<input class="uni-input inputM" v-model="msg.mobile" />
<input class="uni-input inputM" v-model="msg.Mobile" />
</view>
<view style="width: 100%;height: 1px;background: #f5f5f5;"/>
<!-- TODO 动态获取地址数据 -->
<view class="addcenter_item">
<Text>所在地区</Text>
<view style="display: flex;flex-direction: row;align-items: center;" @click="Pickershwo=true">
<view style="display: flex;flex-direction: row;align-items: center;" @click="addressShow = true">
<Text :style="{'color':address!=''? '#303133':'#9D9C9B'}">{{address!=''? address :'请选择'}}</Text>
<u-icon name="arrow" color="#B2B2B2" size="30" ></u-icon>
<pickerAddress v-model="addressShow" @confirm="addresspick" />
</view>
</view>
<view style="width: 100%;height: 1px;background: #f5f5f5;"/>
<!-- TODO 定位地址 -->
<view class="addcenter_item">
<!-- <view class="addcenter_item">
<Text>定位地址</Text>
<view style="display: flex;flex-direction: row;align-items: center;">
<Text style='#303133'>{{msg.address}}</Text>
<u-icon name="arrow" color="#B2B2B2" size="30" ></u-icon>
</view>
</view>
</view> -->
<view style="width: 100%;height: 1px;background: #f5f5f5;"/>
<view class="addcenter_item2">
<Text>详细地址</Text>
<input class="uni-input inputM" v-model="msg.detail" />
<input class="uni-input inputM" v-model="msg.Address" />
</view>
</view>
<view class="btn" @click="preserve" :style="{'background':mainColor}">
<Text>保存地址</Text>
</view>
<u-picker v-model="Pickershwo" mode="region" @confirm = 'confirm'></u-picker>
<u-toast ref="uToast" />
</view>
</template>
<script>
import pickerAddress from './liudx-pickerAddress/index.vue'
export default {
components: {
pickerAddress
},
data(){
return{
pageTitle:'收货地址',
contentHeight:0,
mainColor:'',
msg:{
location:'',
latitude:'',
longitude:'',
id:0,
name:'',
mobile:'',
address:'',
province_id:'2',
city_id:'3',
district_id:'4',
detail:'',
Id:0,
Name:'',
Mobile:'',
Province:'',
City:'',
District:'',
Address:'',
},
address:'',
Pickershwo:false
Pickershwo:false,
addressShow: false,
}
},
created(){
......@@ -81,39 +86,21 @@
});
},
onLoad: function (option) { //option为object类型,会序列化上个页面传递的参数
if(option.u!=undefined){
let u = JSON.parse(decodeURIComponent(option.u))
this.msg=u;
this.address = u.province+','+u.city+','+u.district;
if(option.AddressId!=undefined){
this.getAddressInfo(option.AddressId)
}
},
methods:{
preserve(){
let pages = getCurrentPages(); // 当前页面
let beforePage = pages[pages.length - 2]; // 前一个页面
uni.showNavigationBarLoading();
let h = this.apiheader();
h['content-type']='application/x-www-form-urlencoded'
this.request(
this.request2(
{
url: "",
method: "POST",
header: h,
data: {
r: "api/user/address-save",
location:this.msg.location,
latitude:this.msg.latitude,
longitude:this.msg.longitude,
id:this.msg.id,
name:this.msg.name,
mobile:this.msg.mobile,
address:this.msg.address,
province_id:this.msg.province_id,
city_id:this.msg.city_id,
district_id:this.msg.district_id,
detail:this.msg.detail,
}
url: '/api/AppletUser/SetUserShippingAddress',
data: this.msg
},
res => {
......@@ -133,13 +120,47 @@
);
},
confirm(e){
console.log(e)
this.address = e.province.label+','+e.city.label+','+e.area.label;
this.msg.province_id = e.province.value;
this.msg.city_id = e.city.value;
this.msg.district_id = e.area.value;
}
getAddressInfo(id){ //获取详细地址接口
uni.showNavigationBarLoading();
this.request2(
{
url: '/api/AppletUser/GetUserShippingAddressInfo',
data: {
AddressId:id
}
},
res => {
uni.hideNavigationBarLoading();
this.msg.Id =res.data.Id;
this.msg.Name =res.data.Name;
this.msg.Mobile =res.data.Mobile;
this.msg.Province =res.data.Province;
this.msg.City =res.data.City;
this.msg.District =res.data.District;
this.msg.Address =res.data.Address;
this.address = res.data.DistrictAddress.split(" ").join(",");
},
);
},
addresspick(obj) {
this.msg.Province = obj.province.ID;
this.msg.City = obj.city.ID;
if(obj.area!=undefined){
this.msg.District = obj.area.ID;
this.address = obj.province.Name+','+obj.city.Name+','+obj.area.Name;
}else{
this.msg.District = '';
this.address = obj.province.Name+','+obj.city.Name
}
},
}
}
</script>
......@@ -157,7 +178,7 @@
background: #fff;
}
.AddaddressStyle .addcenter{
margin-top: 40rpx;
/* margin-top: 40rpx; */
background: #FFFFFF;
}
.AddaddressStyle .addcenter_item{
......@@ -179,6 +200,7 @@
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
}
.AddaddressStyle .btn{
......@@ -196,5 +218,6 @@
.AddaddressStyle .inputM{
margin-left: 20rpx;
width: 70%;
text-align: right;
}
</style>
......@@ -6,32 +6,32 @@
:enable-flex="true"
:style="{ height: '100%' }"
>
<view v-for="(item, index) in list" :key="index" class="addresbox">
<view v-for="(item, index) in list" :key="index" class="addresbox" @click="chosenHandler(item)">
<view class="addresclo">
<Text >收件人:{{item.name}}</Text>
<Text>{{item.mobile}}</Text>
<Text>收件人:{{item.Name}}</Text>
<Text>{{item.Mobile}}</Text>
</view>
<Text style='width: 100%;'>收货地址:{{item.address}}</Text>
<Text style='width: 100%;'>收货地址:{{item.DistrictAddress}}{{item.Address}}</Text>
<view style="width: 100%;height: 2rpx;background: #f5f5f5;margin-top: 15rpx;"></view>
<view class="addresclo">
<u-checkbox-group @change="isdefault(item)">
<u-checkbox v-model="item.is_default==1?true:false" shape="circle" :active-color="mainColor">
<u-checkbox v-model="item.IsDefault==1?true:false" shape="circle" :active-color="mainColor">
<Text
:style="{'color':item.is_default==1?mainColor:'#c8c9cc' }"
>{{item.is_default==1?'已设为默认':'设为默认'}}</Text>
:style="{'color':item.IsDefault==1?mainColor:'#c8c9cc' }"
>{{item.IsDefault==1?'已设为默认':'设为默认'}}</Text>
</u-checkbox>
</u-checkbox-group>
<view style="display: flex;flex-direction: row;align-items: center;">
<view
style="display: flex;flex-direction: row;align-items: center;"
@click="btn_edit(item)"
@click.stop="btn_edit(item)"
>
<u-icon name="edit" color="#c8c9cc" size="40"></u-icon>
<Text style="color:#c8c9cc;">编辑</Text>
</view>
<view
style="display: flex;flex-direction: row;align-items: center;margin: 0 30rpx"
@click="btn_delete(item)"
@click.stop="btn_delete(item)"
>
<u-icon name="delete" color="#c8c9cc" size="40"></u-icon>
<Text style="color:#c8c9cc;">删除</Text>
......@@ -60,7 +60,7 @@
@confirm="confirm"
></u-modal>
<u-toast ref="uToast" />
<!-- <auth v-if="showAuth" @changeuserinfo="reloadUserinfo"></auth> -->
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth= 'gbAuth'></auth>
</view>
</template>
......@@ -84,6 +84,11 @@ export default {
IsDefault:0,
Mobile:'',
},
source: "",
defaultId: 0,
currentAddress: {},
list: [],
mc:"",
};
},
......@@ -110,22 +115,38 @@ export default {
title: this.pageTitle,
});
},
onLoad() {
this.u = wx.getStorageSync("userinfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
}
this.init();
onLoad(option) {
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
}else{
this.init();
}
if (option && option.form) {
(this.source = option.form), (this.defaultId = option.id);
}
},
methods: {
chosenHandler(item){
console.log("chosenHandler",item)
let pages = getCurrentPages()
let prevPage = pages[ pages.length - 2 ]
prevPage.$vm.formData.address_id = item.Id;
prevPage.$vm.formdata.AddressId = item.Id;
prevPage.$vm.adressInfo=item;
uni.navigateBack({
delta: 1
})
},
init() {
this.loading = false;
uni.showNavigationBarLoading();
let h = this.apiheader();
this.request2(
{
url: '/api/AppletUser/GetUserShippingAddressList',
......@@ -133,49 +154,32 @@ export default {
},
res => {
uni.hideNavigationBarLoading();
console.log("res",res);
if(res.resultCode==1){
this.isloading = false;
this.list = res.data.list;
this.list = res.data;
}
}
);
// this.request(
// {
// url: "",
// header: h,
// data: {
// r: "api/user/address"
// }
// },
// res => {
// uni.hideNavigationBarLoading();
// this.isloading = false;
// this.list = res.data.list;
// }
// );
},
reloadUserinfo() {
this.u = uni.getStorageSync("userinfo");
this.u = uni.getStorageSync("mall_UserInfo");
this.showAuth = false;
this.init();
},
//关闭登录窗口
gbAuth(){
uni.navigateBack()
},
isdefault(item) {
//默认地址
//设置默认地址
uni.showNavigationBarLoading();
let h = this.apiheader();
h['content-type']='application/x-www-form-urlencoded'
this.request(
this.request2(
{
url: "",
method: "POST",
header: h,
data: {
r: "api/user/address-default",
id: item.id,
is_default: item.is_default == 1 ? 0 : 1
}
url: '/api/AppletUser/SetUserShippingAddressDefault',
data: {
AddressId:item.Id
}
},
res => {
......@@ -186,25 +190,21 @@ export default {
},
btn_edit(item) {
uni.navigateTo({
url: "/pages/address/AddAddress?u=" + encodeURIComponent(JSON.stringify(item))
url: "/pages/address/AddAddress?AddressId="+item.Id
});
},
btn_delete(item) {
this.deleteID = item.id;
this.deleteID = item.Id;
this.showModal = true;
},
confirm() {
uni.showNavigationBarLoading();
let h = this.apiheader();
h['content-type']='application/x-www-form-urlencoded'
this.request(
this.request2(
{
url: "",
method: "POST",
header: h,
url: "/api/AppletUser/DelUserShippingAddress",
data: {
r: "api/user/address-destroy",
id: this.deleteID
AddressId:this.deleteID
}
},
......
......@@ -5,28 +5,28 @@
<view class="default">
<u-icon name="checked" size="44" :color="mc"></u-icon>
</view>
<view class="address" @click="chosenHandler(currentAddress.id)">
<view class="address" @click="chosenHandler(currentAddress)">
<view class="base">
<text class="name">{{currentAddress.name}}</text>
<text class="phone">{{currentAddress.mobile}}</text>
<text class="name">{{currentAddress.Name}}</text>
<text class="phone">{{currentAddress.Mobile}}</text>
</view>
<view class="details">
{{currentAddress.address}}
{{currentAddress.Address}}
</view>
</view>
<view class="edit">
<view @click.stop="btn_edit(currentAddress)" class="edit">
<u-icon name="edit" size="44" color="#444"></u-icon>
</view>
</view>
<view class="item" v-for="(x, i) in list" :key="i">
<view class="address">
<view class="base" @click="chosenHandler(x.id)">
<text class="name">{{x.name}}</text>
<text class="phone">{{x.mobile}}</text>
<view class="base" @click="chosenHandler(x)">
<text class="name">{{x.Name}}</text>
<text class="phone">{{x.Mobile}}</text>
</view>
<view class="details">{{x.address}}</view>
<view class="details">{{x.Address}}</view>
</view>
<view class="edit">
<view @click.stop="btn_edit(x)" class="edit">
<u-icon name="edit" size="44" color="#444"></u-icon>
</view>
</view>
......@@ -59,11 +59,17 @@ export default {
defaultId: 0,
currentAddress: {},
list: [],
mc:""
mc:"",
msg:{
Name:'',
IsDefault:0,
Mobile:'',
},
};
},
onLoad(option) {
if (option.form) {
console.log("option",option)
if (option && option.form) {
(this.source = option.form), (this.defaultId = option.id);
}
this.mc = this.$uiConfig.mainColor;
......@@ -71,48 +77,85 @@ export default {
this.init();
},
methods: {
chosenHandler(id){
btn_edit(item) {
console.log("item",item)
uni.navigateTo({
url: "/pages/address/AddAddress?AddressId="+item.Id
});
},
chosenHandler(item){
let pages = getCurrentPages()
let prevPage = pages[ pages.length - 2 ]
prevPage.$vm.formData.address_id = id
prevPage.$vm.formData.address_id = item.Id;
prevPage.$vm.formdata.AddressId = item.Id;
prevPage.$vm.adressInfo=item;
uni.navigateBack({
delta: 1
})
},
newAddressHandler(){
console.log("hhhh")
uni.navigateTo({
url: '/pages/address/addAddress'
url: '/pages/address/AddAddress'
});
},
init() {
console.log("1111")
this.loading = false;
let h=this.apiheader()
this.request(
{
url: "",
header: h,
data: {
r: "api/user/address",
},
},
this.request2(
{
url: '/api/AppletUser/GetUserShippingAddressList',
data: this.msg
},
res => {
uni.hideNavigationBarLoading();
console.log("res",res)
if(res.resultCode==1){
this.isloading = false;
this.list = res.data;
let index = -1;
this.list.forEach((x, i) => {
x.MobileNew = x.Mobile;
x.Mobile = x.Mobile.substr(0, 3) + "****" + x.Mobile.substr(7);
if (x.Id == this.defaultId) {
this.currentAddress = x;
index = i;
}
});
if (index != -1) {
this.list.splice(index, 1);
}
}
}
);
// let h=this.apiheader()
// this.request(
// {
// url: "",
// header: h,
// data: {
// r: "api/user/address",
// },
// },
(res) => {
uni.hideNavigationBarLoading();
this.isloading = false;
this.list = res.data.list;
let index = -1;
this.list.forEach((x, i) => {
x.mobile = x.mobile.substr(0, 3) + "****" + x.mobile.substr(7);
if (x.id == this.defaultId) {
this.currentAddress = x;
index = i;
}
});
if (index != -1) {
this.list.splice(index, 1);
}
}
);
// (res) => {
// uni.hideNavigationBarLoading();
// this.isloading = false;
// this.list = res.data.list;
// let index = -1;
// this.list.forEach((x, i) => {
// x.mobile = x.mobile.substr(0, 3) + "****" + x.mobile.substr(7);
// if (x.id == this.defaultId) {
// this.currentAddress = x;
// index = i;
// }
// });
// if (index != -1) {
// this.list.splice(index, 1);
// }
// }
// );
},
},
};
......
<template>
<u-popup :maskCloseAble="maskCloseAble" mode="bottom" :popup="false" v-model="value" length="auto"
:safeAreaInsetBottom="safeAreaInsetBottom" @close="close" z-index="999">
<view class="u-picker-header" @touchmove.stop.prevent="stop" catchtouchmove="stop">
<view class="u-btn-picker u-btn-picker--tips" hover-class="u-opacity"
:hover-stay-time="150" @tap="getResult('cancel')">取消</view>
<view class="u-btn-picker u-btn-picker--primary" hover-class="u-opacity"
:hover-stay-time="150" @touchmove.stop="" @tap.stop="getResult('confirm')">确定</view>
</view>
<view class="u-picker-body">
<picker-view :value="pickVal" @change="bindChange" class="u-picker-view">
<picker-view-column>
<view class="u-column-item" v-for="(item,index) in districtsObj.provinces" :key="index">
<view class="u-line-1">
{{item.Name}}
</view>
</view>
</picker-view-column>
<picker-view-column>
<view class="u-column-item" v-for="(item,index) in districtsObj.cities" :key="index">
<view class="u-line-1">
{{item.Name}}
</view>
</view>
</picker-view-column>
<picker-view-column>
<view class="u-column-item" v-for="(item,index) in districtsObj.areas" :key="index">
<view class="u-line-1">
{{item.Name}}
</view>
</view>
</picker-view-column>
</picker-view>
</view>
</u-popup>
</template>
<script>
import uPopup from './u-popup'
export default {
props: {
safeAreaInsetBottom: {
type: Boolean,
default: false
},
// 是否允许通过点击遮罩关闭Picker
maskCloseAble: {
type: Boolean,
default: true
},
// 通过双向绑定控制组件的弹出与收起
value: {
type: Boolean,
default: false
},
},
data() {
return {
pickVal:[0, 0, 0],
districtsObj: {
provinces: [],
cities: [],
areas: [],
},
province: 0,
city: 0,
area: 0
}
},
watch: {
// 如果地区发生变化,为了让picker联动起来,必须重置this.citys和this.areas
province(val) {
this.loadCities(this.districtsObj.provinces[this.province].ID);
},
city(val) {
this.loadAreas(this.districtsObj.cities[this.city].ID);
}
},
mounted() {
this.loadDistrict()
},
methods: {
close() {
this.$emit('input', false);
},
async loadDistrict() {
this.loadProvinces()
},
loadProvinces() { // 加载省份
this.request2(
{
url: '/api/Destination/GetChildList',
data: {Id:2}
},
res => {
let data = res.data
this.districtsObj.provinces = data
this.loadCities(data[0].ID)
},
);
},
loadCities(Id) {
this.request2(
{
url: '/api/Destination/GetChildList',
data: {Id:Id}
},
res => {
let data = res.data
this.districtsObj.cities = data
this.loadAreas(data[0].ID)
},
);
},
loadAreas(Id) {
this.request2(
{
url: '/api/Destination/GetChildList',
data: {Id:Id}
},
res => {
let data = res.data
this.districtsObj.areas = data
},
);
},
bindChange(event) {
this.pickVal = event.detail.value;
let i = 0;
this.province = this.pickVal[i++];
this.city = this.pickVal[i++];
this.area = this.pickVal[i++];
},
getResult(event = null) {
let result = {
province: this.districtsObj.provinces[this.province],
city: this.districtsObj.cities[this.city],
area: this.districtsObj.areas[this.area],
}
if (event) this.$emit(event, result);
this.close();
}
},
components:{
uPopup
}
}
</script>
<style lang="scss" scoped>
.u-datetime-picker {
position: relative;
z-index: 999;
}
.u-picker-view {
height: 100%;
box-sizing: border-box;
}
.u-picker-header {
width: 100%;
height: 90rpx;
padding: 0 40rpx;
display: flex;
justify-content: space-between;
align-items: center;
box-sizing: border-box;
font-size: 32rpx;
background: #ddd;
position: relative;
}
.u-picker-header::after {
content: '';
position: absolute;
border-bottom: 1rpx solid #eaeef1;
-webkit-transform: scaleY(0.5);
transform: scaleY(0.5);
bottom: 0;
right: 0;
left: 0;
}
.u-picker-body {
width: 100%;
height: 500rpx;
overflow: hidden;
background-color: #fff;
}
.u-column-item {
display: flex;
align-items: center;
justify-content: center;
font-size: 32rpx;
padding: 0 8rpx;
}
.u-text {
font-size: 24rpx;
padding-left: 8rpx;
}
.u-btn-picker {
padding: 16rpx;
box-sizing: border-box;
text-align: center;
text-decoration: none;
}
.u-opacity {
opacity: 0.5;
}
.u-btn-picker--primary {
}
.u-btn-picker--tips {
}
</style>
<template>
<view class="u-mask" :style="[maskStyle]" :class="[show ? 'u-mask-show' : '']" @tap="click" @touchmove.stop.prevent>
<slot />
</view>
</template>
<script>
/**
* mask 遮罩
* @description 创建一个遮罩层,用于强调特定的页面元素,并阻止用户对遮罩下层的内容进行操作,一般用于弹窗场景
* @tutorial https://www.uviewui.com/components/mask.html
* @property {Boolean} show 是否显示遮罩(默认false)
* @property {String Number} z-index z-index 层级(默认1070)
* @property {Object} custom-style 自定义样式对象,见上方说明
* @property {String Number} duration 动画时长,单位毫秒(默认300)
* @property {Boolean} zoom 是否使用scale对这招进行缩放(默认true)
* @property {Boolean} mask-click-able 遮罩是否可点击,为false时点击不会发送click事件(默认true)
* @event {Function} click mask-click-able为true时,点击遮罩发送此事件
* @example <u-mask :show="show" @click="show = false"></u-mask>
*/
export default {
name: "u-mask",
props: {
// 是否显示遮罩
show: {
type: Boolean,
default: false
},
// 层级z-index
zIndex: {
type: [Number, String],
default: '1'
},
// 用户自定义样式
customStyle: {
type: Object,
default () {
return {}
}
},
// 遮罩的动画样式, 是否使用使用zoom进行scale进行缩放
zoom: {
type: Boolean,
default: true
},
// 遮罩的过渡时间,单位为ms
duration: {
type: [Number, String],
default: 300
},
// 是否可以通过点击遮罩进行关闭
maskClickAble: {
type: Boolean,
default: true
}
},
computed: {
maskStyle() {
let style = {};
style.backgroundColor = "rgba(0, 0, 0, 0.6)";
style.zIndex = this.zIndex ? this.zIndex : this.$u.zIndex.mask;
style.transition = `all ${this.duration / 1000}s ease-in-out`;
// 缩放
if (this.zoom == true) style.transform = 'scale(1.2, 1.2)';
// 判断用户传递的对象是否为空
if (Object.keys(this.customStyle).length) style = { ...style,
...this.customStyle
};
// 合并自定义的样式
//Object.assign(style, customStyle);
return style;
}
},
methods: {
click() {
if (!this.maskClickAble) return;
this.$emit('click');
}
}
}
</script>
<style lang="scss" scoped>
.u-mask {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
opacity: 0;
visibility: hidden;
}
.u-mask-show {
opacity: 1;
visibility: visible;
transform: scale(1);
}
</style>
<template>
<view v-if="visibleSync" :style="[customStyle]" :class="{ 'u-drawer-visible': showDrawer }" class="u-drawer">
<u-mask :maskClickAble="maskCloseAble" :show="showDrawer && mask" @click="maskClick"></u-mask>
<view class="u-drawer-content" @tap="modeCenterClose(mode)" :class="[
safeAreaInsetBottom ? 'safe-area-inset-bottom' : '',
'u-drawer-' + mode,
showDrawer ? 'u-drawer-content-visible' : '',
zoom && mode == 'center' ? 'u-animation-zoom' : ''
]"
@touchmove.stop.prevent @tap.stop.prevent :style="[style]">
<view class="u-mode-center-box" @tap.stop.prevent @touchmove.stop.prevent v-if="mode == 'center'" :style="[centerStyle]">
<slot />
</view>
<block v-else>
<slot />
</block>
</view>
</view>
</template>
<script>
/**
* popup 弹窗
* @description 弹出层容器,用于展示弹窗、信息提示等内容,支持上、下、左、右和中部弹出。组件只提供容器,内部内容由用户自定义
* @tutorial https://www.uviewui.com/components/popup.html
* @property {String} mode 弹出方向(默认left)
* @property {Boolean} mask 是否显示遮罩(默认true)
* @property {String Number} length mode=left | 见官网说明(默认auto)
* @property {Boolean} zoom 是否开启缩放动画,只在mode为center时有效(默认true)
* @property {Boolean} safe-area-inset-bottom 是否开启底部安全区适配(默认false)
* @property {Boolean} mask-close-able 点击遮罩是否可以关闭弹出层(默认true)
* @property {Object} custom-style 用户自定义样式
* @property {Number String} border-radius 弹窗圆角值(默认0)
* @property {Number String} z-index 弹出内容的z-index值(默认1075)
* @event {Function} open 弹出层打开
* @event {Function} close 弹出层收起
* @example <u-popup v-model="show"><view>出淤泥而不染,濯清涟而不妖</view></u-popup>
*/
import uMask from './u-mask'
export default {
name: 'u-popup',
props: {
/**
* 显示状态
*/
show: {
type: Boolean,
default: false
},
/**
* 弹出方向,left|right|top|bottom|center
*/
mode: {
type: String,
default: 'left'
},
/**
* 是否显示遮罩
*/
mask: {
type: Boolean,
default: true
},
// 抽屉的宽度(mode=left|right),或者高度(mode=top|bottom),单位rpx,或者"auto"
// 或者百分比"50%",表示由内容撑开高度或者宽度
length: {
type: [Number, String],
default: 'auto'
},
// 是否开启缩放动画,只在mode=center时有效
zoom: {
type: Boolean,
default: true
},
// 是否开启底部安全区适配,开启的话,会在iPhoneX机型底部添加一定的内边距
safeAreaInsetBottom: {
type: Boolean,
default: false
},
// 是否可以通过点击遮罩进行关闭
maskCloseAble: {
type: Boolean,
default: true
},
// 用户自定义样式
customStyle: {
type: Object,
default () {
return {};
}
},
value: {
type: Boolean,
default: false
},
// 此为内部参数,不在文档对外使用,为了解决Picker和keyboard等融合了弹窗的组件
// 对v-model双向绑定多层调用造成报错不能修改props值的问题
popup: {
type: Boolean,
default: true
},
// 显示显示弹窗的圆角,单位rpx
borderRadius: {
type: [Number, String],
default: 0
},
zIndex: {
type: [Number, String],
default: '100'
}
},
data() {
return {
visibleSync: false,
showDrawer: false,
timer: null,
style1: {}
};
},
computed: {
// 根据mode的位置,设定其弹窗的宽度(mode = left|right),或者高度(mode = top|bottom)
style() {
let style = {};
let translate = '100%';
// 判断是否是否百分比或者auto值,是的话,直接使用该值,否则默认为rpx单位的数值
let length = (/%$/.test(this.length) || this.length == 'auto') ? this.length : uni.upx2px(this.length) + 'px';
// 如果是左边或者上边弹出时,需要给translate设置为负值,用于隐藏
if (this.mode == 'left' || this.mode == 'top') translate = length == 'auto' ? '-100%' : '-' + length;
if (this.mode == 'left' || this.mode == 'right') {
style = {
width: length,
height: '100%',
transform: `translate3D(${translate},0px,0px)`
};
} else if (this.mode == 'top' || this.mode == 'bottom') {
style = {
width: '100%',
height: length,
transform: `translate3D(0px,${translate},0px)`
};
}
style.zIndex = this.zIndex ? this.zIndex : this.$u.zIndex.popup;
// 如果用户设置了borderRadius值,添加弹窗的圆角
if (this.borderRadius) {
switch (this.mode) {
case 'left':
style.borderRadius = `0 ${this.borderRadius}rpx ${this.borderRadius}rpx 0`;
break;
case 'top':
style.borderRadius = `0 0 ${this.borderRadius}rpx ${this.borderRadius}rpx`;
break;
case 'right':
style.borderRadius = `${this.borderRadius}rpx 0 0 ${this.borderRadius}rpx`;
break;
case 'bottom':
style.borderRadius = `${this.borderRadius}rpx ${this.borderRadius}rpx 0 0`;
break;
default:
;
}
// 不加可能圆角无效
style.overflow = 'hidden';
}
return style;
},
// 中部弹窗的特有样式
centerStyle() {
let style = {};
let length = (/%$/.test(this.length) || this.length == 'auto') ? this.length : uni.upx2px(this.length) + 'px';
style.width = length;
style.zIndex = this.zIndex ? this.zIndex : this.$u.zIndex.popup;
if (this.borderRadius) {
style.borderRadius = `${this.borderRadius}rpx`;
// 不加可能圆角无效
style.overflow = 'hidden';
}
return style;
}
},
watch: {
value(val) {
if (val) {
this.open();
} else {
this.close();
}
}
},
created() {
// 先让弹窗组件渲染,再改变遮罩和抽屉元素的样式,让其动画其起作用(必须要有延时,才会有效果)
this.visibleSync = this.value;
setTimeout(() => {
this.showDrawer = this.value;
}, 30);
},
methods: {
// 遮罩被点击
maskClick() {
this.close();
},
close() {
this.change('showDrawer', 'visibleSync', false);
},
// 中部弹出时,需要.u-drawer-content将居中内容,此元素会铺满屏幕,点击需要关闭弹窗
// 让其只在mode=center时起作用
modeCenterClose(mode) {
if (mode != 'center' || !this.maskCloseAble) return;
this.close();
},
open() {
this.change('visibleSync', 'showDrawer', true);
},
// 此处的原理是,关闭时先通过动画隐藏弹窗和遮罩,再移除整个组件
// 打开时,先渲染组件,延时一定时间再让遮罩和弹窗的动画起作用
change(param1, param2, status) {
// 如果this.popup为false,以为着为picker,actionsheet等组件调用了popup组件
if (this.popup == true) this.$emit('input', status);
this[param1] = status;
if (this.timer) {
clearTimeout(this.timer);
}
this.timer = setTimeout(
() => {
this[param2] = status;
this.$emit(status ? 'open' : 'close');
},
status ? 30 : 300
);
}
},
components:{
uMask
}
};
</script>
<style scoped lang="scss">
.u-drawer {
/* #ifndef APP-NVUE */
display: block;
/* #endif */
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
overflow: hidden;
z-index: 999;
background-color: rgba(0, 0, 0, 0.4);
}
.u-drawer-content {
/* #ifndef APP-NVUE */
display: block;
/* #endif */
position: absolute;
z-index: 1003;
transition: all 0.25s linear;
}
.u-drawer-left {
top: 0;
bottom: 0;
left: 0;
background-color: #ffffff;
}
.u-drawer-right {
right: 0;
top: 0;
bottom: 0;
background-color: #ffffff;
}
.u-drawer-top {
top: 0;
left: 0;
right: 0;
background-color: #ffffff;
}
.u-drawer-bottom {
bottom: 0;
left: 0;
right: 0;
background-color: #ffffff;
}
.u-drawer-center {
/* #ifndef APP-NVUE */
display: flex;
flex-direction: column;
/* #endif */
bottom: 0;
left: 0;
right: 0;
top: 0;
justify-content: center;
align-items: center;
opacity: 0;
z-index: 99999;
}
.u-mode-center-box {
min-width: 100rpx;
min-height: 100rpx;
/* #ifndef APP-NVUE */
display: block;
/* #endif */
position: relative;
background-color: #ffffff;
}
.u-drawer-content-visible.u-drawer-center {
transform: scale(1);
opacity: 1;
}
.u-animation-zoom {
transform: scale(1.15);
}
.u-drawer-content-visible {
transform: translate3D(0px, 0px, 0px) !important;
}
.u-drawer-mask {
/* #ifndef APP-NVUE */
display: block;
/* #endif */
opacity: 0;
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
background-color: rgba(0, 0, 0, 0.4);
transition: opacity 0.25s;
}
.u-drawer-mask-visible {
/* #ifndef APP-NVUE */
display: block;
/* #endif */
opacity: 1;
}
</style>
......@@ -7,7 +7,7 @@
<Text style='color: #fff;;font-size: 28rpx;'>充值</Text>
</view>
<!-- TODO 暂无余额说明 -->
<u-icon name="question-o" color="#fff" class='explain' size="36"></u-icon>
<u-icon name="question-o" color="#fff" class='explain' size="36" @click="goUrl('/pages/balance/rules')"></u-icon>
</view>
<view class="timechoice">
<view style="width: 50%;display: flex;flex-direction: row;align-items: center;justify-content: space-between;">
......@@ -16,11 +16,37 @@
<u-icon name="arrow" color="#909399" size="36" @click='fun_date(1)'></u-icon>
</view>
</view>
<view>
<!-- TODO logs列表 -->
<view v-if="logsList.length > 0"
style="
height: calc(100vh - 265px);
width: calc(100vw);
overflow: hidden;
padding-top: 10px;
">
<scroll-view
:scroll-y="true"
:enable-back-to-top="true"
:enable-flex="true"
@scrolltolower="lower"
:style="{ height: '100%' }">
<view style="display: flex;flex-direction: column;align-items: center;">
<view v-for="(item, index) in logsList" :key="index" class='logsList' @click="godetail(item.id)">
<view class="logsList_l">
<Text class='l_name'>{{item.desc}}</Text>
<Text style='font-size: 13px;color: #666;'>{{item.created_at}}</Text>
</view>
<view class="logsList_r">
<Text :style="{color:item.type==1 ? mainColor:'#6ABE60'}">{{item.type==1 ? '+':'-'}}{{item.money}}</Text>
</view>
</view>
</view>
</scroll-view>
</view>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo"></auth>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth= 'goback'></auth>
<view class="loading" v-if="load">
<u-loading mode="flower" size="48"></u-loading>
<Text style='color: #fff;margin-top: 10rpx;'>加载中...</Text>
......@@ -64,32 +90,41 @@
});
},
onLoad(){
this.u = uni.getStorageSync("userinfo");
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
}
}else{
this.getData()
}
},
created(){
this.contentHeight = this.$utils.calcContentHeight(-40)+'px';
this.mainColor = this.$uiConfig.mainColor;
let date1 = new Date();
let time1 = date1.getFullYear() + "年" + (date1.getMonth() + 1) +'月'
let time2 = date1.getFullYear() + "-" + (date1.getMonth() + 1)
this.date = time1
this.date2 = time2
this.balancedata()
this.getlogs()
},
methods: {
getData(){
let date1 = new Date();
let time1 = date1.getFullYear() + "年" + (date1.getMonth() + 1) +'月'
let time2 = date1.getFullYear() + "-" + (date1.getMonth() + 1)
this.date = time1
this.date2 = time2
this.balancedata()
this.getlogs()
},
reloadUserinfo() {
this.u = uni.getStorageSync("userinfo");
this.showAuth=false
this.u = uni.getStorageSync("mall_UserInfo");
this.showAuth=false;
this.getData()
},
goback(){
uni.navigateBack()
},
balancedata(){
uni.showNavigationBarLoading();
......@@ -126,7 +161,7 @@
},
res => {
this.load=false
this.logsList = res.data.list
uni.hideNavigationBarLoading()
}
......@@ -178,6 +213,11 @@
url: url
})
},
godetail(id){
uni.navigateTo({
url: '/pages/balance/detail?id='+id
})
}
}
}
</script>
......@@ -233,4 +273,37 @@
margin-left: -100rpx;
z-index: 999;
}
.balanceStyle .logsList{
width: 100%;
height: 75px;
background: #fff;
display: flex;
flex-direction: row;
align-items: center;
padding: 10px;
border-top: 1px solid #f5f5f5;
}
.balanceStyle .logsList_l{
width: calc(100vw - 20px - 150px);
height: 55px;
display: flex;
flex-direction: column;
justify-content: space-between;
}
.balanceStyle .logsList_r{
width: 150px;
display: flex;
flex-direction: row;
align-items: center;
justify-content: flex-end;
font-size: 26px;
}
.balanceStyle .logsList_l .l_name{
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
font-size: 14px;
}
</style>
<template>
<view class="balancedetailStyle" :style="{'height':contentHeight}" >
<view class="bd_box" style="border-bottom: 1px solid #f5f5f5;">
<view class='bd_box_l'>
<Text>交易金额</Text>
</view>
<Text class='bd_r' :style="{color:g.type==1 ? mainColor:'#6ABE60',}">{{g.type==1 ? '+':'-'}}{{g.money}}</Text>
</view>
<view class="bd_box" >
<view class='bd_box_l'>
<Text>交易时间</Text>
</view>
<Text >{{g.created_at}}</Text>
</view>
<view class="bd_box" style="align-items: flex-start;">
<view class='bd_box_l'>
<Text>交易详情</Text>
</view>
<view style='width: calc(100vw - 20px - 80px);'>
<Text >{{g.desc}}</Text>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
pageTitle:"余额详情",
contentHeight:0,
mainColor: "",
g:{},
}
},
mounted() {
let currentPages = getCurrentPages();
let u = "/" + currentPages[currentPages.length-1].route;
let pages = uni.getStorageSync("basedata")
? uni.getStorageSync("basedata").bar_title
: [];
pages.forEach((x) => {
if (x.value == u) {
this.pageTitle = x.new_name ? x.new_name : x.name;
}
});
uni.setNavigationBarTitle({
title: this.pageTitle,
});
},
onLoad(option){
this.getlogdetail(option.id)
},
created(){
this.contentHeight = this.$utils.calcContentHeight(-40)+'px';
this.mainColor = this.$uiConfig.mainColor;
},
methods: {
getlogdetail(id){
uni.showNavigationBarLoading();
let h=this.apiheader()
this.request(
{
url: "",
header:h,
data: {
r: "api/balance/log-detail",
id:id
}
},
res => {
uni.hideNavigationBarLoading()
this.g = res.data.detail;
}
);
},
}
}
</script>
<style>
.balancedetailStyle{
background: #f3f4f6;
width: 100%;
}
.balancedetailStyle .bd_box{
width: 100%;
background:#fff;
padding: 15px 10px;
display: flex;
flex-direction: row;
align-items: center;
}
.bd_box .bd_box_l{
color: #999999;
margin-right: 10px;
width: 70px;
display: inline-block;
}
.bd_box .bd_r{
font-size: 20px;
}
</style>
......@@ -30,29 +30,21 @@
</view>
</view>
<!-- <auth v-if="showAuth" @changeuserinfo="reloadUserinfo"></auth> -->
</view>
</template>
<script>
import auth from "../../components/auth/index.vue";
export default {
data() {
return {
pageTitle:"充值中心",
showAuth:false,
contentHeight:0,
mainColor: "",
u:{},
g:{},
}
},
components:{
auth
},
mounted() {
let currentPages = getCurrentPages();
let u = "/" + currentPages[currentPages.length-1].route;
......@@ -69,28 +61,18 @@
});
},
onLoad(){
this.u = uni.getStorageSync("userinfo");
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
}
},
created(){
this.contentHeight = this.$utils.calcContentHeight(-40)+'px';
this.mainColor = this.$uiConfig.mainColor;
this.balancedata()
this.getrecharge() //充值金额的列表
},
methods: {
reloadUserinfo() {
this.u = uni.getStorageSync("userinfo");
this.showAuth=false
},
balancedata(){
uni.showNavigationBarLoading();
let h=this.apiheader()
......@@ -109,27 +91,8 @@
}
);
},
getlogs(){
uni.showNavigationBarLoading();
let h=this.apiheader()
this.request(
{
url: "",
header:h,
data: {
r: "api/recharge/index",
date:this.date2,
}
},
res => {
uni.hideNavigationBarLoading()
}
);
},
btn_recharge(){
},
......
<template>
<view class="balancerulesStyle" :style="{'height':contentHeight}" >
<view class="rulesbox">
<Text>暂无余额说明</Text>
</view>
</view>
</template>
<script>
export default {
data() {
return {
pageTitle:"余额说明",
contentHeight:0,
mainColor: "",
g:{},
}
},
mounted() {
let currentPages = getCurrentPages();
let u = "/" + currentPages[currentPages.length-1].route;
let pages = uni.getStorageSync("basedata")
? uni.getStorageSync("basedata").bar_title
: [];
pages.forEach((x) => {
if (x.value == u) {
this.pageTitle = x.new_name ? x.new_name : x.name;
}
});
uni.setNavigationBarTitle({
title: this.pageTitle,
});
},
created(){
this.contentHeight = this.$utils.calcContentHeight(-40)+'px';
this.mainColor = this.$uiConfig.mainColor;
},
methods: {
}
}
</script>
<style>
.balancerulesStyle{
background: #fff;
width: 100%;
}
.rulesbox{
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
}
</style>
......@@ -49,20 +49,23 @@
<!-- 取消提示 -->
<u-toast ref="uToast" />
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth= 'goback'></auth>
</view>
</template>
<script>
import error from '../../../components/error/error.vue'
import error from '../../../components/error/error.vue';
import auth from "../../../components/auth/index.vue";
export default {
components: {
error
error,
auth
},
data() {
return {
pageTitle: "我的卡券",
current: 0,
showAuth: false,
list: [
{ name: "未使用" },
{ name: "已使用" },
......@@ -78,11 +81,24 @@ export default {
item: "",
index: 0,
isover: false,
u:{},
};
},
created() {
this.contentHeight = this.$utils.calcContentHeight(-40) + "px";
this.mainColor = this.$uiConfig.mainColor;
this.u = uni.getStorageSync("mall_UserInfo");
console.log(this.u)
if (!this.u) {
this.u = {
nickName: "未登录",
avatarUrl: ""
};
this.showAuth = true;
} else{
this.loading = true;
this.init();
}
},
mounted() {
let currentPages = getCurrentPages();
......@@ -99,12 +115,6 @@ export default {
title: this.pageTitle,
});
},
onLoad: function (option) {
//option为object类型,会序列化上个页面传递的参数
// this.current = option.status;
this.loading = true;
this.init();
},
methods: {
change(index) {
console.log(index)
......@@ -150,6 +160,15 @@ export default {
this.isover = true;
}
},
reloadUserinfo() {
this.u = uni.getStorageSync("mall_UserInfo");
this.showAuth = false;
this.loading = true;
this.init();
},
goback(){
uni.navigateBack()
},
},
};
</script>
......
This diff is collapsed.
This diff is collapsed.
<template>
<view class="cdetailStyle" :style="{'height':contentHeight}">
<view style="width: 100%;height: 100%;">
<u-tabs :list="list" :is-scroll="false" :current="current" @change="change" :active-color='mainColor' bg-color='#f3f4f6'></u-tabs>
<u-tabs :list="list" :is-scroll="false" :current="msg.AuditStatus" @change="change" :active-color='mainColor' bg-color='#f3f4f6'></u-tabs>
<u-empty v-if="g==''" text="暂无数据" mode="data"></u-empty>
<template v-if="g.length > 0">
<view
......@@ -19,36 +19,41 @@
:style="{ height: '100%' }">
<view style="display: flex;flex-direction: column;align-items: center;">
<view v-for="(item, index) in g" :key="index" class="listbox">
<view style="padding: 10px;color: #999;">{{item.date}}</view>
<view class="box_b" v-for="(c, i) in item.list" :key="i">
<!-- <view style="padding: 10px;color: #999;">{{item.date}}</view> -->
<!-- <view class="box_b" v-for="(c, i) in item.list" :key="i"> -->
<view class="box_b" >
<view class="box_b_l">
<view style='display: flex;flex-direction: row;align-items: center;'>
<Text>{{c.pay_type}}</Text>
<Text>{{item.WithdrawalWayName}}</Text>
<view class="status">
<Text :style="{'color':mainColor}">{{c.status_text}}</Text>
<Text :style="{'color':mainColor}">{{item.AuditStatusName}}</Text>
</view>
</view>
<Text class='text_s'>提现账户:</Text>
<Text class='text_s'>提现时间:{{c.time.created_at}}</Text>
<Text class='text_s'>提现账户:{{item.AccountName}}</Text>
<Text class='text_s'>提现时间:{{item.AuditDate}}</Text>
</view>
<view class="box_b_l" style="align-items: flex-end;">
<Text style='font-size: 18px;'>{{c.cash.price}}</Text>
<Text class='text_s' > 手续费{{c.cash.service_charge}}</Text>
<Text style='font-size: 18px;'>{{item.AppliedMoney}}</Text>
<Text class='text_s' > 手续费{{item.Fee}}</Text>
</view>
</view>
</view>
</view>
<u-loadmore
:status="status"
:load-text="loadText"
:font-size="24"
:margin-top="20"
:margin-bottom="20"
bg-color="#f3f4f6"
/>
</scroll-view>
</view>
</template>
</view>
<view class="loading" v-if="loading">
<u-loading mode="flower" size="48"></u-loading>
<Text style='color: #fff;margin-top: 10rpx;'>加载中...</Text>
</view>
</view>
</template>
......@@ -60,9 +65,8 @@
contentHeight:0,
mainColor:'',
secondary:'',
current:0,
g:'',
loading:false,
list:[
{name: '全部'},
{name: '待审核'},
......@@ -70,7 +74,18 @@
{name: '已打款'},
{name: '无效'},
],
msg:{
pageIndex: 1,
pageSize:10,
AuditStatus:0
},
page_count:1,
status: "loadmore",
loadText: {
loadmore: "轻轻上拉,加载更多",
loading: "努力加载中",
nomore: "没有更多优惠券了",
},
}
},
......@@ -97,34 +112,41 @@
},
methods: {
init(){
let that = this
that.loading= true;
uni.showNavigationBarLoading();
let h = this.apiheader();
this.request(
uni.showLoading({
title: '加载中'
});
this.request2(
{
url: "",
header:h,
data: {
r: "api/share/cash-list",
status:that.current-1
},
},
url: '/api/AppletUser/GetUserDistrbutorRemitPageList',
data: this.msg
},
(res) => {
that.loading = false;
uni.hideNavigationBarLoading();
that.g = Object.values(res.data.list) ;
console.log(that.g)
}
(res) => {
uni.hideLoading();
this.g = this.g.concat(res.data.pageData);
this.page_count = res.data.pageCount;
if (this.page_count == 1) {
this.status = "nomore";
}
}
);
},
change(index){
this.current = index;
this.msg.AuditStatus = index;
this.init()
}
},
lower(e) {
if (this.msg.pageIndex < this.page_count) {
this.msg.pageIndex++;
this.status = "loading";
this.init();
} else {
this.status = "nomore";
}
},
}
}
</script>
......@@ -134,22 +156,7 @@
background: #f3f4f6;
}
.cdetailStyle .loading{
width: 200rpx;
height: 200rpx;
background: #000000;
opacity: 0.7;
border-radius: 10rpx;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
position: fixed;
left: 50%;
top:30%;
margin-left: -100rpx;
z-index: 999;
}
.cdetailStyle .listbox{
width: 94%;
border-radius: 10rpx;
......@@ -159,7 +166,7 @@
.cdetailStyle .listbox .box_b{
width: 100%;
padding: 10px;
border-top: 1px solid #f5f5f5;
/* border-top: 1px solid #f5f5f5; */
display: flex;
flex-direction: row;
align-items: center;
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -167,7 +167,7 @@ export default {
this.showLoading = this.msg.pageIndex != 1;
this.request2(
{
url: '/api/AppletGoods/GetAppletGoodsPageList',
url: '/api/AppletGoods/GetAppletGoodsPageListForZY',
data: this.msg
},
res => {
......
......@@ -145,7 +145,7 @@ export default {
this.indexPageData = res.data.home_pages.navs[0].template.data;
this.myPageData=res.data;
wx.setStorageSync("indexdata", this.myPageData);
// wx.setStorageSync("indexdata", this.myPageData);
if (res.data.home_pages.title != "") {
uni.setNavigationBarTitle({
title: res.data.home_pages.title,
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment