Merge branch 'test' of https://e.coding.net/g-cphe0354/cashier_front/cashier_admin_app into test
This commit is contained in:
commit
b68ccf69be
|
|
@ -203,6 +203,16 @@ export function callTabletakeNumber(data) {
|
|||
}
|
||||
})
|
||||
}
|
||||
// 增减余额
|
||||
export function midfiyAccount(data) {
|
||||
return request({
|
||||
url: '/api/tbShopUser/midfiyAccount',
|
||||
method: 'post',
|
||||
data: {
|
||||
...data
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
export function callTablecallRecord(params) {
|
||||
return request({
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
<view class="u-flex">
|
||||
<view class="color-000 font-bold">{{data.nickName}}</view>
|
||||
<image style="width: 24rpx;height: 24rpx;" v-if="data.sex=='男'" src="./men.png" mode=""></image>
|
||||
<image style="width: 24rpx;height: 24rpx;" v-else src="./women.png" mode=""></image>
|
||||
<image style="width: 24rpx;height: 24rpx;" v-if="data.sex=='女'" src="./women.png" mode=""></image>
|
||||
<view class="color-999 u-m-l-40" @click="remark">备注</view>
|
||||
</view>
|
||||
<!-- <view class="u-m-t-6 u-flex u-row-between">
|
||||
|
|
|
|||
|
|
@ -162,9 +162,82 @@
|
|||
<span>增减余额</span>
|
||||
<up-icon @tap="confirm" name="close-circle-fill"></up-icon>
|
||||
</view>
|
||||
<view class="">
|
||||
<view style="display: flex;align-items: center;padding: 24rpx;">
|
||||
<image v-if="datas.activeUser.headImg" :src="datas.activeUser.headImg"
|
||||
style="width: 52rpx;height: 52rpx;;background-color: #eee;"></image>
|
||||
<view style="width: 52rpx;height: 52rpx;;background-color: #eee;" v-else>
|
||||
</view>
|
||||
<view style="margin-left: 12rpx;">
|
||||
<view style="font-weight: 400;font-size: 28rpx;color: #333333;">
|
||||
{{datas.activeUser.nickName}}
|
||||
</view>
|
||||
<view style="font-weight: 400;font-size: 24rpx;color: #999999;">
|
||||
当前余额:{{datas.activeUser.amount}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zhezhaopopthree">
|
||||
<view style="font-weight: 400;font-size: 28rpx;color: #333333;">
|
||||
增减
|
||||
</view>
|
||||
<view class="u-m-t-16">
|
||||
<radio-group class="u-flex u-flex-wrap" @change="sizeChange($event,'operationType')">
|
||||
<label class="radio u-m-r-60">
|
||||
<radio value="in" :checked="datas.form.operationType == 'in'" class="scale7" />
|
||||
<text>增加</text>
|
||||
</label>
|
||||
<label class="radio u-m-r-60">
|
||||
<radio value="out" :checked="datas.form.operationType == 'out'" class="scale7" />
|
||||
<text>扣除</text>
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zhezhaopopthree" v-if="datas.form.operationType=='in'">
|
||||
<view style="font-weight: 400;font-size: 28rpx;color: #333333;">
|
||||
类型
|
||||
</view>
|
||||
<view class="u-m-t-16">
|
||||
<radio-group class="u-flex u-flex-wrap" @change="sizeChange($event,'type')">
|
||||
<label class="radio u-m-r-60">
|
||||
<radio value="inMoney" :checked="datas.form.type == 'inMoney'" class="scale7" />
|
||||
<text>充值</text>
|
||||
</label>
|
||||
<label class="radio u-m-r-60">
|
||||
<radio value="consumeIn" :checked="datas.form.type == 'consumeIn'" class="scale7" />
|
||||
<text>消费退款</text>
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zhezhaopopthree" v-else>
|
||||
<view style="font-weight: 400;font-size: 28rpx;color: #333333;">
|
||||
类型
|
||||
</view>
|
||||
<view class="u-m-t-16">
|
||||
<radio-group class="u-flex u-flex-wrap" @change="sizeChange($event,'type')">
|
||||
<label class="radio u-m-r-60">
|
||||
<radio value="consumeOut" :checked="datas.form.type == 'consumeOut'" class="scale7" />
|
||||
<text>消费</text>
|
||||
</label>
|
||||
<label class="radio u-m-r-60">
|
||||
<radio value="inMoneyOut" :checked="datas.form.type == 'inMoneyOut'" class="scale7" />
|
||||
<text>充值退款</text>
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
</view>
|
||||
<view class="zhezhaopopfour">
|
||||
<view style="font-weight: 400;font-size: 28rpx;color: #333333;">
|
||||
充值余额
|
||||
</view>
|
||||
<view class="">
|
||||
<input type="number" v-model="datas.form.amount" placeholder="请输入充值余额" />
|
||||
<view class="">
|
||||
元
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<up-button text="确认" @tap="callTabletakeNumberEvent" type="primary" class="buttomStyle"
|
||||
shape="circle"></up-button>
|
||||
</view>
|
||||
|
|
@ -183,6 +256,11 @@
|
|||
import infoBox from "@/commons/utils/infoBox.js"
|
||||
import * as $Api from '@/http/yskApi/shop-user.js'
|
||||
import API from '../../http/classApi';
|
||||
|
||||
import {
|
||||
midfiyAccount
|
||||
} from '@/http/yskApi/requestAll.js';
|
||||
|
||||
import {
|
||||
onReachBottom
|
||||
} from '@dcloudio/uni-app';
|
||||
|
|
@ -196,7 +274,10 @@
|
|||
const moreOperate = ref(null)
|
||||
let datas = reactive({
|
||||
show: false,
|
||||
form: {}
|
||||
form: {
|
||||
operationType: 'in'
|
||||
},
|
||||
activeUser: null
|
||||
})
|
||||
let close = () => {
|
||||
datas.form = {}
|
||||
|
|
@ -208,7 +289,15 @@
|
|||
function toAddUser() {
|
||||
go.to('PAGES_USER_ADD')
|
||||
}
|
||||
|
||||
let callTabletakeNumberEvent = async () => {
|
||||
console.log(datas.form, '调试1')
|
||||
let res = await midfiyAccount({
|
||||
id: datas.activeUser.id,
|
||||
...datas.form
|
||||
})
|
||||
datas.show = false;
|
||||
getUser()
|
||||
}
|
||||
const remarModelData = reactive({
|
||||
remark: ''
|
||||
})
|
||||
|
|
@ -216,11 +305,15 @@
|
|||
phone: ''
|
||||
})
|
||||
|
||||
function sizeChange(e, name) {
|
||||
datas.form[name] = e.detail.value
|
||||
}
|
||||
const goodsStockModel = ref(null)
|
||||
|
||||
const moreOperateList = ['增减余额', '修改信息', ]
|
||||
|
||||
function moreOperateClick() {
|
||||
function moreOperateClick(d) {
|
||||
datas.activeUser = pageData.userList[d]
|
||||
moreOperate.value.open()
|
||||
}
|
||||
|
||||
|
|
@ -572,7 +665,6 @@
|
|||
.zhezhaopop {
|
||||
padding: 34rpx 32rpx;
|
||||
width: 594rpx;
|
||||
height: 668rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 18rpx 18rpx 18rpx 18rpx;
|
||||
|
||||
|
|
@ -590,6 +682,72 @@
|
|||
}
|
||||
}
|
||||
|
||||
>view:nth-child(2) {
|
||||
margin: 48rpx auto;
|
||||
width: 492rpx;
|
||||
height: 124rpx;
|
||||
background: #FAFAFA;
|
||||
border-radius: 12rpx 12rpx 12rpx 12rpx;
|
||||
}
|
||||
|
||||
.zhezhaopopthree {
|
||||
>view:nth-child(2) {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-top: 24rpx;
|
||||
|
||||
>view {
|
||||
width: 186rpx;
|
||||
height: 56rpx;
|
||||
line-height: 56rpx;
|
||||
text-align: center;
|
||||
background: #FFFFFF;
|
||||
border-radius: 8rpx 8rpx 8rpx 8rpx;
|
||||
border: 2rpx solid #E5E5E5;
|
||||
font-family: Source Han Sans CN, Source Han Sans CN;
|
||||
font-weight: 400;
|
||||
font-size: 24rpx;
|
||||
color: #666666;
|
||||
}
|
||||
|
||||
.selectvalue {
|
||||
color: #318AFE;
|
||||
border: 2rpx solid #318AFE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.zhezhaopopfour {
|
||||
margin-top: 32rpx;
|
||||
|
||||
>view:nth-child(2) {
|
||||
margin-top: 24rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
>input {
|
||||
width: 372rpx;
|
||||
height: 84rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 8rpx 0rpx 0rpx 8rpx;
|
||||
border: 2rpx solid #E5E5E5;
|
||||
padding-left: 24rpx;
|
||||
}
|
||||
|
||||
>view {
|
||||
width: 124rpx;
|
||||
height: 86rpx;
|
||||
line-height: 84rpx;
|
||||
text-align: center;
|
||||
background: #F7F7FA;
|
||||
border-radius: 0rpx 8rpx 8rpx 0rpx;
|
||||
border: 2rpx solid #E5E5E5;
|
||||
color: #999999;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.buttomStyle {
|
||||
margin-top: 48rpx;
|
||||
width: 506rpx;
|
||||
|
|
|
|||
Loading…
Reference in New Issue