This commit is contained in:
zhaotianfeng 2024-09-25 11:54:09 +08:00
commit 3327bece3c
9 changed files with 307 additions and 45 deletions

View File

@ -30,7 +30,7 @@
<image src="../../static/new/n5.png" mode=""></image>
<view class="">领券中心</view>
</view>
<view class="_bgox">
<view class="_bgox" @click="goInvite()">
<image src="../../static/new/n6.png" mode=""></image>
<view class="">邀请有礼</view>
</view>
@ -261,6 +261,11 @@
tabbar
},
methods: {
goInvite() {
uni.navigateTo({
url: '/pagesMy/invite/invite'
})
},
goMyCard() {
uni.navigateTo({
url: '/pagesHome/MyCard/MyCard'

View File

@ -7,29 +7,34 @@
<view class="my-icons"></view>
</view>
<!-- 顶部区域 -->
<view class="box-xianze" v-for="(item,index) in 3" :key="index">
<view class="" @click="choose(item)">
<view class="box-xianze" v-for="(item,index) in dataList" :key="index">
<view class="">
<view style="display: flex;align-items: center;margin-bottom: 5px;">
<view class="">{{item.address || '小王'}}</view>
<view style="margin: 0 10px;"> {{item.name || '先生'}}</view>
<view class=""> {{item.mobile || '15426886361'}}</view>
<view class="">{{item.name || '--'}}</view>
<view style="margin: 0 10px;" v-if="item.sex==0"> 先生</view>
<view style="margin: 0 10px;" v-if="item.sex==1"> 女士</view>
<view class=""> {{item.mobile || '--'}}</view>
</view>
</view>
<view class="box-xia">
<view class="box-left">
<u-checkbox v-model="checked" shape="circle" label="默认信息"></u-checkbox>
<view class="box-left" @click="chooseDefault(item)">
<view class="acvf" v-if="item.checked == false"></view>
<view class="acv" v-else><u-icon name="checkbox-mark" color="#fff" size="14"></u-icon></view>
<view style="font-size: 14px; color: #999; ">默认信息</view>
</view>
<view class="box-right">
<view style="display: flex;" @click="goedit(item)">
<u-icon name="edit-pen-fill" size="12"></u-icon>
<view style="margin-left: 5px;">编辑</view>
</view>
<view style="display: flex;">
<view style="display: flex;" @click="delInfo(item)">
<u-icon name="trash" size="12"></u-icon>
<view style="margin-left: 5px;">删除</view>
</view>
</view>
</view>
</view>
@ -51,7 +56,8 @@
return {
title: '',
dataList: '',
checked: false,
checkboxValue1: [],
checked: true,
}
},
onShow() {
@ -61,13 +67,40 @@
},
methods: {
chooseDefault(data) {
console.log(data);
if (data.checked == false) {
data.ifDefault = 1
} else {
data.ifDefault = 2
}
request({
url: '/business/userManager/mtUserExpressAddress',
method: 'put',
data: data
}).then((res) => {
if (res.code == 200) {
this.getList()
console.log(res, 81);
}
})
},
getList() {
request({
url: 'business/userManager/mtUserExpressAddress/getList',
url: '/business/userManager/mtUserExpressAddress/getList',
method: 'get',
}).then((res) => {
if (res.code == 200) {
this.dataList = res.data
this.dataList.forEach(item => {
item.checked = false
if (item.ifDefault == 1) {
item.checked = true
}
this.$set(item, 'checked', item.checked); //
})
console.log(res, this.dataList, 98);
this.$forceUpdate()
}
})
},
@ -84,6 +117,20 @@
url: '/pagesHome/editress/editress'
})
},
//
delInfo(data) {
request({
url: '/business/userManager/mtUserExpressAddress',
method: 'delete',
params: {
id: data.id
}
}).then((res) => {
if (res.code == 200) {
this.getList()
}
})
},
choose(data) {
//
uni.$on('unChooseAddr', function() {
@ -156,7 +203,10 @@
box-sizing: border-box;
}
.box-left {}
.box-left {
display: flex;
align-items: center;
}
.box-right {
width: 30%;
@ -184,4 +234,28 @@
justify-content: space-between;
margin-top: 20px;
}
.acvf {
border-radius: 50%;
border: 1px solid #eee;
height: 16px;
width: 16px;
display: flex;
align-items: center;
justify-content: center;
margin-right: 10px;
}
.acv {
border-radius: 50%;
border: 1px solid #1678ff;
height: 16px;
width: 16px;
background: #1678ff;
color: #fff;
margin-right: 10px;
display: flex;
align-items: center;
justify-content: center;
}
</style>

View File

@ -12,13 +12,13 @@
</view>
<view class="box-gang">
<view class="g-name">性别</view>
<view >
<u-radio-group v-model="dataForm.sex" >
<u-radio label="0">先生</u-radio>
<u-radio label="1">女士</u-radio>
<view>
<u-radio-group v-model="dataForm.sex">
<u-radio label="先生" :name="0"></u-radio>
<u-radio label="女士" :name="1"></u-radio>
</u-radio-group>
</view>
</view>
<view class="box-gang">
<view class="g-name">电话</view>
@ -52,12 +52,12 @@
title: '',
value: true,
dataForm: {
id: null,
name: '',
mobile: '',
address: '',
ifDefault: '',
fullAddress: '',
sex: "",
storeId: uni.getStorageSync("storeId")
}
}
@ -75,6 +75,7 @@
}
})
uni.$emit('unAddressInfo')
console.log(this.dataForm,78);
},
components: {
@ -87,13 +88,8 @@
uni.navigateBack()
},
goedit() {
if (this.value) {
this.dataForm.ifDefault = 1
} else {
this.dataForm.ifDefault = 2
}
let url = 'business/userManager/mtUserExpressAddress'
if (this.dataForm.id != null) {
let url = '/business/userManager/mtUserExpressAddress'
if (this.dataForm.id) {
request({
url: url,
method: 'put',
@ -123,7 +119,6 @@
})
}
console.log("123123", this.dataForm)
}
}
}

View File

@ -13,7 +13,7 @@
<view class="gang" v-if="qhindex == index"></view>
</view>
</scroll-view> -->
<view class="box-bai" v-if="qhindex == 0">
<view class="box-bai" v-if="qhindex == 0" @click="goAddress()">
<view class="dis">
<view class="boximg">
<image src="../../static/imgs/telicon.png"
@ -191,6 +191,11 @@
methods: {
goAddress(){
uni.navigateTo({
url:'/pagesHome/Address/Address'
})
},
//
async choose() {
let _this = this

View File

@ -28,6 +28,11 @@
</view>
</view>
</view>
<view v-if="!cardsList || cardsList.length==0">
<u-empty mode="list" icon="http://cdn.uviewui.com/uview/empty/list.png"></u-empty>
</view>
<u-overlay :show="shows">
<view class="boxck">
@ -64,7 +69,7 @@
storeId: '',
status: 0,
page: 1,
pageSize: 10
pageSize: 1000
},
title: '',
tabindex: 0,
@ -190,7 +195,7 @@
this.tabindex = index
console.log(index);
this.cardsList = []
this.query.useStatus = index
this.query.status = index
this.getGiftRecords()
@ -213,7 +218,6 @@
if (res.code == 200) {
this.cardsList = res.data.records
}
console.log(res.data, this.cardsList, 226);
})
}
}

View File

@ -14,7 +14,7 @@
<image src="../../static/new/fxrwm.png" mode=""></image>
<view class="min-size">分享二维码</view>
</view>
<view class="or-box">
<view class="or-box" @click="goList()">
<image src="../../static/new/jljl.png" mode=""></image>
<view class="min-size">奖励记录</view>
</view>
@ -25,7 +25,7 @@
</view>
<view class="h_bs">
<view class="title_">推荐会员消费有礼</view>
<view class="d-s">
<view class="d-s" @click="goDetails()">
<view class="hui-size">详情</view>
<u-icon name="arrow-right" color="#999999" size="12"></u-icon>
</view>
@ -56,7 +56,7 @@
<view class="si_t">
<view style="display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; ">
<view class="title_">适用门店</view>
<view class="d-s" style=" color: #FF2828; ">
<view class="d-s" style=" color: #FF2828; margin: 0px; ">
<image src="../../static/icon/reddh.png" style="width: 14px; height: 14px; "></image> 导航
</view>
</view>
@ -65,11 +65,55 @@
</view>
<!-- 顶部区域 -->
<u-popup :show="show" mode="center" :round="10" @close="close" @open="open">
<view class="popup_box">
<w-qrcode :options="options"></w-qrcode>
<u-overlay :show="show" @click="show = false">
<view class="warp">
<view class="warp-cent" @tap.stop>
<view class="title_or">扫码领会员</view>
<view class="d-s">
<view class="touxiang">
<image src="../../static/logo.png" mode=""></image>
</view>
<view class="">
<view class="tiitle_">百业兴加油站</view>
<view class="size_">油站会员卡</view>
</view>
</view>
<view style="width: 100%;display: flex;justify-content: center; ">
<w-qrcode :options="options"></w-qrcode>
</view>
</view>
<view class="warp-bottom" @tap.stop>
<view class="bott_box">
<view class=""></view>
<view class="">选择方式</view>
<view class="" @click="show = false">
<u-icon name="close" size="16"></u-icon>
</view>
</view>
<view class="bott-box">
<view class="">
<view class="">
<image src="../../static/my/fztp.png" style="width: 40px; height: 40px; "></image>
</view>
<view class="">
保存图片
</view>
</view>
<view class="">
<view class="">
<image src="../../static/my/fzlj.png" style="width: 40px; height: 40px; "></image>
</view>
<view class="">
复制链接
</view>
</view>
</view>
</view>
</view>
</u-popup>
</u-overlay>
</view>
@ -90,13 +134,13 @@
title: '',
userId: '',
storeId: '',
show: false,
show: true,
options: {
code: 'https://oilapi.youkerr.com/oily?storeId=' + uni.getStorageSync('storeId') + '&userId=' + uni
.getStorageSync('userId') + '&type=yaoqingyouli',
// code: 'https://www.tuofeng.cc/oily?storeId=' + uni.getStorageSync('storeId') + ' &userId=' + uni
// .getStorageSync('userId'), //
size: 500, // 460460rpx
size: 400, // 460460rpx
},
}
@ -166,6 +210,16 @@
this.getActiveRecommendRecords();
},
methods: {
goList() {
uni.navigateTo({
url: '/pagesMy/invite/list'
})
},
goDetails() {
uni.navigateTo({
url: '/pagesMy/invite/details'
})
},
// https://www.tuofeng.cc/oilStation?storeId=19&staffId=45
close() {
this.show = false
@ -466,6 +520,8 @@
.d-s {
display: flex;
align-items: center;
justify-content: center;
margin: 15px auto;
}
.backf {
@ -485,4 +541,68 @@
border-bottom: 1px solid #EEEEEE;
width: 100%;
}
</style>
.warp {
width: 100%;
height: 100vh;
position: relative;
}
.warp-bottom {
position: absolute;
left: 0px;
bottom: 0px;
background: #fff;
width: 100%;
box-sizing: border-box;
padding: 10px;
border-radius: 10px 10px 10px 10px;
text-align: center;
}
.bott-box {
display: flex;
align-items: center;
justify-content: space-around;
box-sizing: border-box;
padding-bottom: 15px;
border-top: 1px solid #eee;
padding-top: 10px;
}
.bott_box {
box-sizing: border-box;
padding: 5px;
padding-bottom: 15px;
display: flex;
align-items: center;
justify-content: space-between;
}
.warp-cent {
width: 85%;
background: #333;
position: absolute;
color: #fff;
left: 50%;
transform: translate(-50%, -50%);
bottom: -5%;
box-sizing: border-box;
padding: 10px;
padding-bottom: 60px;
}
.tiitle_ {
font-weight: 600;
font-size: 16px;
color: #FFFFFF;
}
.title_or {
color: #eeb668;
text-align: center;
font-size: 28px;
}
</style>

View File

@ -12,8 +12,25 @@
</view>
</view>
<view class="tab_">
<view class="t-box" :class="{'orsize' : tindex == index }" v-for="(item,index) in tabList"
:key="index">{{item.name}}</view>
<view class="t-box" :class="{'orsize' : tindex == index }" v-for="(item,index) in tabList" :key="index"
@click="setIndex(index)">{{item.name}}</view>
</view>
<view class="whit-box" v-if="tindex == 1">
<view class="one_h" v-for="(item,index) in 4" :key="index">
<view class="">券名称</view>
<view class="">2024-8-7</view>
</view>
</view>
<view class="whit-box" v-else>
<view class="one_h" v-for="(item,index) in 4" :key="index">
<view class="d-s">
<view class="touxiang">
<image src="../../static/logo.png" mode=""></image>
</view>
<view class="">名字</view>
</view>
<view class="">2024-8-7</view>
</view>
</view>
</view>
</view>
@ -67,6 +84,9 @@
},
methods: {
setIndex(num) {
this.tindex = num
},
//
resetting() {
this.pageNo = 1
@ -151,11 +171,50 @@
font-weight: 600;
font-size: 16px;
color: #333333;
box-sizing: border-box;
padding-bottom: 10px;
border-bottom: 1px solid transparent;
}
.orsize {
color: #FA6400;
border-bottom: 1px solid #FA6400;
}
.whit-box {
width: 95%;
background: #fff;
margin: 15px;
}
.one_h {
width: 100%;
box-sizing: border-box;
padding: 10px;
border-bottom: 1px solid #eee;
display: flex;
align-items: center;
justify-content: space-between;
}
.touxiang {
width: 40px;
height: 40px;
overflow: hidden;
border-radius: 50%;
margin-right: 10px;
image {
width: 40px;
height: 40px;
}
}
.d-s {
display: flex;
align-items: center;
}
</style>

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB