Browse Source

精网号最长8位

lihuilin/feature-20251104102812-现金二期
lihuilin 6 days ago
parent
commit
8d944a595c
  1. 48
      src/views/moneyManage/executor/executor.vue
  2. 37
      src/views/moneyManage/refundDetail/refundCharge.vue
  3. 53
      src/views/moneyManage/refundDetail/refundFinance.vue
  4. 42
      src/views/moneyManage/refundDetail/refundHeader.vue
  5. 54
      src/views/moneyManage/refundDetail/refundService.vue

48
src/views/moneyManage/executor/executor.vue

@ -41,8 +41,8 @@
<div class="search2" style="width: 25.5vw;">
<el-text size="large" style="width:4vw;">退款时间</el-text>
<el-date-picker v-model="dateRange" type="datetimerange" range-separator="" start-placeholder="起始时间"
end-placeholder="结束时间" style="width:18vw;" clearable
:disabled-date="disabledDate" :default-time="defaultTime" />
end-placeholder="结束时间" style="width:18vw;" clearable :disabled-date="disabledDate"
:default-time="defaultTime" />
</div>
<div>
<el-button type="primary" size="medium" @click="getRefund">查询</el-button>
@ -54,10 +54,10 @@
<el-card style="background-color: rgb(231,244,253);height:80vh;">
<el-table :data="tableData" style="height:70vh;width:82vw;">
<el-table-column type="index" label="序号" width="60" fixed="left">
<template #default="scope">
{{ scope.$index + 1 + (pagination.pageNum - 1) * pagination.pageSize }}
</template>
</el-table-column>
<template #default="scope">
{{ scope.$index + 1 + (pagination.pageNum - 1) * pagination.pageSize }}
</template>
</el-table-column>
<el-table-column prop="jwcode" label="Homily ID" width="120" fixed="left" />
<el-table-column prop="name" label="姓名" width="120" fixed="left" show-overflow-tooltip />
<el-table-column prop="marketName" label="所属地区" width="120" />
@ -123,11 +123,12 @@
</el-table-column>
</el-table>
<el-pagination v-model:current-page="pagination.pageNum" v-model:page-size="pagination.pageSize"
@size-change="handlePageSizeChange" @current-change="handleCurrentChange"
@size-change="handlePageSizeChange" @current-change="handleCurrentChange"
layout="total, sizes, prev, pager, next, jumper" :total="pagination.total" style="margin-top: 1vh;" />
</el-card>
<el-dialog v-model="showEdit" class="edit" overflow draggable style="width: 40vw; background-color: #F3FAFE !important;">
<el-dialog v-model="showEdit" class="edit" overflow draggable
style="width: 40vw; background-color: #F3FAFE !important;">
<div style="display: flex;">
<div class="left">
<div class="dialog-item">
@ -175,7 +176,8 @@
</div>
<div class="dialog-item">
<el-text style="width:4vw;">转账凭证</el-text>
<img v-if="editRow.payVoucher" :src="editRow.payVoucher" style="width: 80px; height: 80px; object-fit: cover;">
<img v-if="editRow.payVoucher" :src="editRow.payVoucher"
style="width: 80px; height: 80px; object-fit: cover;">
<div v-else>
无转账凭证
</div>
@ -282,12 +284,20 @@ const getRefund = async function () {
}
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
if(searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)){
ElMessage.error('精网号必须为数字')
return
}
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
const params = {
pageNum: pagination.value.pageNum,
@ -295,7 +305,7 @@ const getRefund = async function () {
cashRecordDTO: {
jwcode: searchForm.value.jwcode,
name: searchForm.value.name,
markets: searchForm.value.markets && searchForm.value.markets.length > 0 ? [searchForm.value.markets[searchForm.value.markets.length - 1]] : [],
markets: searchForm.value.markets && searchForm.value.markets.length > 0 ? [searchForm.value.markets[searchForm.value.markets.length - 1]] : [],
goodsName: goodsName,
statuses: statusesParam.value,//1012
// 2022
@ -495,12 +505,12 @@ const reset = function () {
getRefund()
}
const handlePageSizeChange = function (val) {
pagination.value.pageSize = val
getRefund()
pagination.value.pageSize = val
getRefund()
}
const handleCurrentChange = function (val) {
pagination.value.pageNum = val
getRefund()
pagination.value.pageNum = val
getRefund()
}
onMounted(() => {
console.log('???????????????????', adminData.value)

37
src/views/moneyManage/refundDetail/refundCharge.vue

@ -421,17 +421,18 @@ const getRefund = async function () {
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
// if (searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)) {
// ElMessage.error('')
// return
// }
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
}
if (searchForm.value.paymentCurrency) {
payCurrencySelect.value = CurrencyForId(searchForm.value.paymentCurrency)
@ -599,10 +600,18 @@ const exportExcel = async function () {
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
// if (searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)) {
// ElMessage.error('')
// return
// }
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
if (searchForm.value.paymentCurrency) {
payCurrencySelect.value = CurrencyForId(searchForm.value.paymentCurrency)

53
src/views/moneyManage/refundDetail/refundFinance.vue

@ -103,7 +103,8 @@
style="margin-top: 1vh;"></el-pagination>
</el-card>
<el-dialog v-model="showAudit" title="审核" class="audit" width="35vw" overflow draggable style="background-color: #F3FAFE !important;">
<el-dialog v-model="showAudit" title="审核" class="audit" width="35vw" overflow draggable
style="background-color: #F3FAFE !important;">
<div class="top">
<el-button @click="" class="smallTitle" size="small">退款申请信息</el-button>
<div class="top-item">
@ -479,19 +480,20 @@ const getRefund = async function () {
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
// if (searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)) {
// ElMessage.error('')
// return
// }
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
}
const params = {
const params = {
pageNum: pagination.value.pageNum,
pageSize: pagination.value.pageSize,
cashRecordDTO: {
@ -652,21 +654,22 @@ const exportExcel = async function () {
}
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
// if (searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)) {
// ElMessage.error('')
// return
// }
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : '';
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
}
const params = {
const params = {
pageNum: pagination.value.pageNum,
pageSize: pagination.value.pageSize,
cashRecordDTO: {

42
src/views/moneyManage/refundDetail/refundHeader.vue

@ -104,7 +104,8 @@
style="margin-top: 1vh;"></el-pagination>
</el-card>
<el-dialog v-model="showAudit2" title="审核" class="audit2" width="35vw" overflow draggable style="background-color: #F3FAFE !important;">
<el-dialog v-model="showAudit2" title="审核" class="audit2" width="35vw" overflow draggable
style="background-color: #F3FAFE !important;">
<div class="top">
<el-button @click="" class="smallTitle" size="small">退款申请信息</el-button>
<div class="top-item">
@ -477,19 +478,20 @@ const getRefund = async function () {
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
// if (searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)) {
// ElMessage.error('')
// return
// }
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
}
const params = {
const params = {
pageNum: pagination.value.pageNum,
pageSize: pagination.value.pageSize,
cashRecordDTO: {
@ -633,10 +635,18 @@ const exportExcel = async function () {
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
// if (searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)) {
// ElMessage.error('')
// return
// }
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
const params = {
pageNum: pagination.value.pageNum,

54
src/views/moneyManage/refundDetail/refundService.vue

@ -115,7 +115,8 @@
style="margin-top: 1vh;"></el-pagination>
</el-card>
<el-dialog v-model="showEdit" title="退款" class="editDialog" overflow draggable style="width: 40vw; background-color: #F3FAFE !important;">
<el-dialog v-model="showEdit" title="退款" class="editDialog" overflow draggable
style="width: 40vw; background-color: #F3FAFE !important;">
<div style="display: flex;">
<div class="left">
<div class="add-item">
@ -287,25 +288,26 @@ const getRefund = async function () {
const goodsName = searchForm.value.goodsName && searchForm.value.goodsName.length > 0
? searchForm.value.goodsName[searchForm.value.goodsName.length - 1] : ''
// if (searchForm.value.jwcode && !isNumber(searchForm.value.jwcode)) {
// ElMessage.error('')
// return
// }
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
if (searchForm.value.jwcode) {
const isPositiveInteger = /^[1-9]\d*$/.test(searchForm.value.jwcode);
if (!isPositiveInteger) {
ElMessage.error('请输入正确的精网号')
return;
}
}
// 400
if (searchForm.value.jwcode.length > 8) {
ElMessage.error('精网号长度不能超过8位')
return;
}
}
const params = {
const params = {
pageNum: pagination.value.pageNum,
pageSize: pagination.value.pageSize,
cashRecordDTO: {
jwcode: searchForm.value.jwcode,//
name: searchForm.value.name,//
markets: searchForm.value.market && searchForm.value.market.length > 0 ? [searchForm.value.market[searchForm.value.market.length - 1]] : [],
markets: searchForm.value.market && searchForm.value.market.length > 0 ? [searchForm.value.market[searchForm.value.market.length - 1]] : [],
goodsName: goodsName,//
statuses: statusParam.value,//1012
// 2022
@ -375,25 +377,25 @@ const submitEdit = async function () {
jwcode: editRow.value.jwcode,
paymentAmount: editRow.value.paymentAmount,
paymentCurrency: editRow.value.paymentCurrency,
newRefundGold: (editForm.value.partRefundGold*100),
newRefundFree: (editForm.value.partRefundFree)*100
newRefundGold: (editForm.value.partRefundGold * 100),
newRefundFree: (editForm.value.partRefundFree) * 100
}
console.log(editRow.value.goodsName);
if (editRow.value.goodsName != '金币充值') {
params.newRefundGold = ''
params.newRefundFree = ''
params.newRefundFree = ''
}
if(editRow.value.goodsName == '金币充值'){
if(editForm.value.partRefundGold>editRow.value.gold){
ElMessage.error('退款金币数不能大于原金币数')
return
}
if(editForm.value.partRefundFree>editRow.value.free){
ElMessage.error('退款免费金币数不能大于原免费金币数')
return
}
if (editRow.value.goodsName == '金币充值') {
if (editForm.value.partRefundGold > editRow.value.gold) {
ElMessage.error('退款金币数不能大于原金币数')
return
}
if (editForm.value.partRefundFree > editRow.value.free) {
ElMessage.error('退款免费金币数不能大于原免费金币数')
return
}
}
const result = await API({
url: '/Money/update',

Loading…
Cancel
Save