|
|
@ -8,9 +8,6 @@ import API from "../../api/index.js"; |
|
|
|
import moment from "moment"; |
|
|
|
import { range, re } from "mathjs"; |
|
|
|
import * as xlsx from 'xlsx'; |
|
|
|
import _, { before } from 'lodash'; |
|
|
|
import { th } from "element-plus/es/locales.mjs"; |
|
|
|
import * as xlsx from "xlsx"; |
|
|
|
import _ from "lodash"; |
|
|
|
|
|
|
|
// 这是添加上传图片的接口 |
|
|
@ -406,10 +403,6 @@ const addLines = async function () { |
|
|
|
rechargeGold: "0", |
|
|
|
paidGold: "0", |
|
|
|
}); |
|
|
|
batchData.value.unshift({ |
|
|
|
line: ++i.value, |
|
|
|
showInput: true, |
|
|
|
}); |
|
|
|
} |
|
|
|
|
|
|
|
// 所有数据添加操作完成后,准备关闭加载动画 |
|
|
@ -727,57 +720,7 @@ const batchAdd = async function () { |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
console.log("batchData::", batchData.value); |
|
|
|
console.log("batchData===", batchData.value); |
|
|
|
let msg = ""; |
|
|
|
if (batchData.value.length == 0) { |
|
|
|
ElMessage({ |
|
|
|
type: "error", |
|
|
|
message: "至少需要输入一条数据!", |
|
|
|
}); |
|
|
|
return; |
|
|
|
} |
|
|
|
for (let i = 0; i < batchData.value.length; i++) { |
|
|
|
batchData.value[i].adminId = adminData.value.adminId; |
|
|
|
batchData.value[i].area = adminData.value.area; |
|
|
|
batchData.value[i].rechargeWay = "客服充值"; |
|
|
|
if (batchData.value[i].jwcode == "" || batchData.value[i].jwcode == null) { |
|
|
|
msg += `精网号不能为空! <br/>`; |
|
|
|
} |
|
|
|
if ( |
|
|
|
batchData.value[i].activityId == "" || |
|
|
|
batchData.value[i].activityId == null |
|
|
|
) { |
|
|
|
msg += `活动不能为空! <br/>`; |
|
|
|
} |
|
|
|
if ( |
|
|
|
batchData.value[i].paidGold == "" || |
|
|
|
batchData.value[i].paidGold == null |
|
|
|
) { |
|
|
|
msg += `充值金币不能为空! <br/>`; |
|
|
|
} |
|
|
|
if ( |
|
|
|
batchData.value[i].rechargeGold == "" || |
|
|
|
batchData.value[i].rechargeGold == null |
|
|
|
) { |
|
|
|
msg += `充值金额不能为空! <br/>`; |
|
|
|
} |
|
|
|
if (batchData.value[i].payWay == "" || batchData.value[i].payWay == null) { |
|
|
|
msg += `收款方式不能为空! <br/>`; |
|
|
|
} |
|
|
|
if ( |
|
|
|
batchData.value[i].rechargeTime == "" || |
|
|
|
batchData.value[i].rechargeTime == null |
|
|
|
) { |
|
|
|
msg += `交款时间不能为空! <br/>`; |
|
|
|
} |
|
|
|
ElMessage({ |
|
|
|
dangerouslyUseHTMLString: true, |
|
|
|
type: "error", |
|
|
|
message: msg, |
|
|
|
}); |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
console.log("batchData===", batchData.value); |
|
|
|
|
|
|
|
const result = await API.post( |
|
|
@ -1098,10 +1041,6 @@ onMounted(async function () { |
|
|
|
}}</span> |
|
|
|
<span style="display: inline; white-space: nowrap; color: #b1b1b1" v-if="user.buyJb">(永久金币:{{ user.buyJb |
|
|
|
}};免费金币:{{ |
|
|
|
<span |
|
|
|
style="display: inline; white-space: nowrap; color: #b1b1b1" |
|
|
|
v-if="user.buyJb" |
|
|
|
>(充值金币:{{ user.buyJb }};免费金币:{{ |
|
|
|
user.free6 + user.free12 |
|
|
|
}};任务金币:{{ user.coreJb }})</span |
|
|
|
> |
|
|
@ -1159,9 +1098,6 @@ onMounted(async function () { |
|
|
|
<el-input-number min="1" style="width: 100px;" controls-position="right" v-model="addLineObj"></el-input-number> |
|
|
|
<span>行</span> |
|
|
|
<el-button type="primary" @click="throttledAddLines" style="margin-right: 10px">添加</el-button> |
|
|
|
<el-button type="primary" @click="addLines()" style="margin-right: 10px" |
|
|
|
>添加</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
|
<el-button |
|
|
|
type="warning" |
|
|
@ -1182,8 +1118,6 @@ onMounted(async function () { |
|
|
|
> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-table id="batchTable" v-loading="loading" :data="batchData" border |
|
|
|
max-height="540px" style="height: 540px" @selection-change="handleSelectionChangebatch"> |
|
|
|
<el-table |
|
|
|
:data="batchData" |
|
|
|
border |
|
|
@ -1256,12 +1190,6 @@ onMounted(async function () { |
|
|
|
<template #default="scope"> |
|
|
|
<el-input v-if="scope.row.showInput" v-model="scope.row.freeGold" style="width: 70px" /> |
|
|
|
<span v-else>{{ scope.row.freeGold }}</span> |
|
|
|
<el-input |
|
|
|
v-if="scope.row.showInput" |
|
|
|
v-model="scope.row.freeGold" |
|
|
|
style="width: 70px" |
|
|
|
/> |
|
|
|
<span v-else>{{ scope.row.paidGold }}</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column property="rate" label="货币名称"> |
|
|
@ -1442,11 +1370,6 @@ onMounted(async function () { |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="永久金币"> |
|
|
|
<el-input v-model="batchSettingObj.paidGold" placeholder="请输入永久金币"></el-input> |
|
|
|
<el-form-item label="充值金币"> |
|
|
|
<el-input |
|
|
|
v-model="batchSettingObj.paidGold" |
|
|
|
placeholder="请输入充值金币" |
|
|
|
></el-input> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item label="免费金币"> |
|
|
|
<el-input v-model="batchSettingObj.freeGold"></el-input> |
|
|
|