feat(wallet): 会员中心-我的钱包样式调整

This commit is contained in:
woody 2025-05-06 13:41:28 +08:00
parent 23a9b42d8b
commit 7ae433e628
8 changed files with 466 additions and 360 deletions

View File

@ -73,15 +73,10 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="dialog-footer"> <div class="dialog-footer">
<el-button <el-button type="primary" class="confirm-button" @click="submitTransfer"
type="primary" >确认</el-button
class="confirm-button"
@click="submitTransfer"
>{{ "确认" }}</el-button
> >
<el-button @click="handleCancel" class="cancel-button">{{ <el-button @click="handleCancel" class="cancel-button">取消</el-button>
"取消"
}}</el-button>
</div> </div>
</div> </div>
</el-dialog> </el-dialog>

View File

@ -45,6 +45,7 @@
:range-separator="'至'" :range-separator="'至'"
:start-placeholder="'开始日期'" :start-placeholder="'开始日期'"
:end-placeholder="'结束日期'" :end-placeholder="'结束日期'"
:picker-options="pickerOptions"
> >
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
@ -52,12 +53,10 @@
<el-col :span="4"> <el-col :span="4">
<div class="searchbox"> <div class="searchbox">
<el-button class="btn2" @click="research">{{ <el-button type="primary" @click="research">{{
"搜索" "搜索"
}}</el-button> }}</el-button>
<el-button class="btn1" @click="chongzhi">{{ <el-button @click="chongzhi">{{ "重置" }}</el-button>
"重置"
}}</el-button>
</div> </div>
</el-col> </el-col>
</el-row> </el-row>
@ -147,6 +146,11 @@ export default {
}, },
data() { data() {
return { return {
pickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now();
},
},
thetime: "", thetime: "",
tableData: [], tableData: [],
total: 0, total: 0,
@ -257,7 +261,7 @@ export default {
cursor: pointer; cursor: pointer;
} }
.actArea { .actArea {
color: #00417C; color: #00417c;
} }
} }
.topbox { .topbox {

View File

@ -12,14 +12,14 @@
<div class="imgbox"><img :src="item.logo" alt="" /></div> <div class="imgbox"><img :src="item.logo" alt="" /></div>
<div class="titlebox"> <div class="titlebox">
<div class="cardtitle">{{ item.bankName }}</div> <div class="cardtitle">{{ item.bankName }}</div>
<div class="cardtitle2">{{ '储蓄卡' }}</div> <div class="cardtitle2">{{ "储蓄卡" }}</div>
</div> </div>
</div> </div>
<div class="flexs_1" v-if="item.defaultCard == 1"> <div class="flexs_1" v-if="item.defaultCard == 1">
<div class="qiu"></div> <div class="qiu"></div>
<div v-if="pkCountry == 1">{{ '默认' }}</div> <div v-if="pkCountry == 1">{{ "默认" }}</div>
<div style="color: #fff; font-weight: bold" v-else> <div style="color: #fff; font-weight: bold" v-else>
{{ '默认' }} {{ "默认" }}
</div> </div>
</div> </div>
<div class="flexs_1" v-else> <div class="flexs_1" v-else>
@ -27,13 +27,13 @@
style="color: #fff; font-weight: bold; cursor: pointer" style="color: #fff; font-weight: bold; cursor: pointer"
@click="setDefault(item.pkId)" @click="setDefault(item.pkId)"
> >
{{ '设为默认' }} {{ "设为默认" }}
</div> </div>
</div> </div>
</div> </div>
<div class="cardNumber">{{ item.cardNumber }}</div> <div class="cardNumber">{{ item.cardNumber }}</div>
<div v-if="pkCountry == 1" class="cardfooter" @click="removeBind(item)"> <div v-if="pkCountry == 1" class="cardfooter" @click="removeBind(item)">
[{{ '解绑' }}] [{{ "解绑" }}]
</div> </div>
<div <div
v-else v-else
@ -41,7 +41,7 @@
class="cardfooter" class="cardfooter"
@click="removeBind(item)" @click="removeBind(item)"
> >
[{{ '解绑' }}] [{{ "解绑" }}]
</div> </div>
</div> </div>
</div> </div>
@ -53,13 +53,13 @@
/> />
</div> </div>
<el-button class="footerbtn" @click="bindBank(true)">{{ <el-button class="footerbtn" @click="bindBank(true)">{{
'绑定银行卡' "绑定银行卡"
}}</el-button> }}</el-button>
<WalletBindBank :isAdd="isAdd" @closeBind="closeBind"></WalletBindBank> <WalletBindBank :visible="isAdd" @closeBind="closeBind"></WalletBindBank>
</div> </div>
</template> </template>
<script> <script>
import { getBankList, removeBankBind, updateDefault } from "@/api/wallet.js"; import { getBankList, removeBankBind, updateDefault } from "@/api/wallet.js";
import WalletBindBank from "@/components/walletBindBank.vue"; import WalletBindBank from "@/components/walletBindBank.vue";
export default { export default {
@ -101,17 +101,21 @@ export default {
}, },
// //
removeBind(item) { removeBind(item) {
this.$confirm('是否确认解绑银行卡', "", { this.$confirm("是否确认解绑银行卡", "", {
confirmButtonText: '确定', confirmButtonText: "确定",
cancelButtonText: '取消', cancelButtonText: "取消",
type: "warning", type: "warning",
}).then(() => { }).then(() => {
if (item.defaultCard == 1) { if (item.defaultCard == 1) {
this.$confirm("当前解绑为默银行卡,请设置为另一张卡为默认银行卡", "", { this.$confirm(
confirmButtonText: '确定', "当前解绑为默银行卡,请设置为另一张卡为默认银行卡",
cancelButtonText: '取消', "",
{
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning", type: "warning",
}).then(() => { }
).then(() => {
removeBankBind({ pkId: item.pkId }).then((res) => { removeBankBind({ pkId: item.pkId }).then((res) => {
if (res.code == 200) { if (res.code == 200) {
this.$message({ this.$message({
@ -122,7 +126,7 @@ export default {
} }
}); });
}); });
}else{ } else {
removeBankBind({ pkId: item.pkId }).then((res) => { removeBankBind({ pkId: item.pkId }).then((res) => {
if (res.code == 200) { if (res.code == 200) {
this.$message({ this.$message({
@ -133,7 +137,6 @@ export default {
} }
}); });
} }
}); });
}, },
closeBind() { closeBind() {
@ -142,8 +145,8 @@ export default {
}, },
// //
bindBank(val) { bindBank(val) {
this.isAdd = true;
this.jdTl = val; this.jdTl = val;
this.isAdd = true;
}, },
research() { research() {
getBankList().then((res) => { getBankList().then((res) => {
@ -163,7 +166,7 @@ export default {
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
::v-deep .el-table .warning-row { ::v-deep .el-table .warning-row {
background: #f9f9f9; background: #f9f9f9;
} }

View File

@ -1,28 +1,27 @@
<template> <template>
<el-dialog <el-dialog
:title="'绑定银行卡'" title="绑定银行卡"
:visible.sync="addShow" :visible.sync="dialogVisible"
center="" width="40%"
width="25%"
:close-on-click-modal="false" :close-on-click-modal="false"
:before-close="handleCloseBank" :before-close="handleCloseDialog"
> >
<div class="add_pay"> <div class="bind-bank-form-container">
<el-form <el-form
ref="form" ref="bankForm"
:rules="rules" :rules="rules"
:model="form" :model="form"
label-position="right" label-position="right"
label-width="100px" label-width="100px"
> >
<el-form-item :label="'银行卡号' + ':'" prop="cardNumber"> <el-form-item label="银行卡号:" prop="cardNumber">
<el-input <el-input
v-model="form.cardNumber" v-model="form.cardNumber"
:placeholder="'请输入银行卡号'" placeholder="请输入银行卡号"
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item :label="'银行选择' + ':'" prop="pkBank"> <el-form-item label="银行选择:" prop="bankId">
<el-select v-model="form.pkBank" :placeholder="'请选择银行名称'"> <el-select v-model="form.bankId" placeholder="请选择银行名称">
<el-option <el-option
v-for="(item, index) in bankCardChioceList" v-for="(item, index) in bankCardChioceList"
:key="index" :key="index"
@ -31,20 +30,20 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item :label="'开户支行' + ':'" prop="subBankName"> <el-form-item label="开户支行:" prop="subBankName">
<el-input <el-input
v-model="form.subBankName" v-model="form.subBankName"
:placeholder="'请输入开户支行'" placeholder="请输入开户支行"
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item :label="'姓名' + ':'" prop="accountName"> <el-form-item label="姓名:" prop="accountName">
<el-input <el-input
v-model="form.accountName" v-model="form.accountName"
:placeholder="'请输入姓名'" placeholder="请输入姓名"
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item :label="'证件类型'" prop="idType"> <el-form-item label="证件类型:" prop="idType">
<el-select v-model="form.idType" :placeholder="'请选择证件类型'"> <el-select v-model="form.idType" placeholder="请选择证件类型">
<el-option <el-option
v-for="(item, index) in cardTypeList" v-for="(item, index) in cardTypeList"
:key="index" :key="index"
@ -53,332 +52,478 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item :label="'证件号码' + ':'" prop="idCard"> <el-form-item label="证件号码:" prop="idCard">
<el-input <el-input
v-model="form.idCard" v-model="form.idCard"
:placeholder="'请输入证件号码'" placeholder="请输入证件号码"
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item <el-form-item v-if="isMainlandChinaUser" label="手机号:" prop="phone">
v-if="pkCountry == 1"
:label="'手机号' + ':'"
prop="phone"
>
<el-input v-model="form.phone" :placeholder="'银行卡预留手机号'"></el-input>
</el-form-item>
<!-- <el-form-item :label="$t('w_0181')+':'">
<el-input <el-input
v-model="form.validdate" v-model="form.phone"
:placeholder="$t('w_0185')" placeholder="银行卡预留手机号"
></el-input> ></el-input>
</el-form-item> --> </el-form-item>
<!-- <el-form-item :label="$t('w_0182')+':'">
<el-input v-model="form.cvv2" :placeholder="$t('w_0186')"></el-input>
</el-form-item> -->
<el-form-item <el-form-item
v-if="pkCountry == 1 && cancode" v-if="isMainlandChinaUser && needsVerificationCode"
:label="'验证码' + ':'" label="验证码:"
prop="verificationCode" prop="verificationCode"
> >
<el-input <el-input
v-model="form.verificationCode" v-model="form.verificationCode"
:placeholder="'请输入验证码'" placeholder="请输入验证码"
></el-input> ></el-input>
<div class="hqyzm1" :class="isSend ? 'hui' : ''" @click="startTime"> <el-button
{{ getCode }} style="margin-left: 10px"
</div> :class="{ 'is-disabled': isSendingCode }"
:disabled="isSendingCode"
type="primary"
@click="sendVerificationCode"
>
{{ verificationCodeButtonText }}
</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
<div class="surebtn1"> <div class="dialog-footer">
<div class="btn hh" @click="handleCloseBank">{{ '取消' }}</div> <!-- <div class="btn cancel-btn" @click="handleCloseDialog">取消</div> -->
<div class="btn" @click="submitForm('form')">{{ '确定' }}</div> <el-button @click="handleCloseDialog">取消</el-button>
<el-button type="primary" @click="submitBankForm('bankForm')"
>确定
</el-button>
</div> </div>
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
import * as wal from "@/api/wallet.js"; import * as walletApi from "@/api/wallet.js";
import { mapGetters } from "vuex"; import { mapGetters } from "vuex";
export default { export default {
data() { data() {
return { //
cardTypeList: [], // const validateVerificationCode = (rule, value, callback) => {
addShow: false, if (this.isMainlandChinaUser && this.needsVerificationCode && !value) {
form: { callback(new Error("请输入验证码"));
cardNumber: "",
accountName: "",
idCard: "",
phone: "",
pkBank: "",
verificationCode: "",
subBankName: "",
},
isSend: false,
beginTime: 60,
getCode: '获取验证码',
timer: "",
rules: {
cardNumber: [
{ required: true, message: '请输入银行卡号', trigger: "blur" },
],
verificationCode: [
{ required: true, message: '请输入验证码', trigger: "blur" },
{
validator: (rule, value, callback) => {
if (this.pkCountry === 1 && !value) {
callback(new Error('请输入验证码'));
} else { } else {
callback(); callback();
} }
};
//
const validatePhoneNumber = (rule, value, callback) => {
if (this.isMainlandChinaUser && !value) {
callback(new Error("请输入正确的手机号"));
} else if (this.isMainlandChinaUser && value && value.length < 11) {
callback(new Error("请输入正确的手机号"));
} else {
callback();
}
};
return {
cardTypeList: [], //
dialogVisible: false, //
form: {
cardNumber: "", //
accountName: "", //
idCard: "", //
phone: "", //
bankId: "", // ID ( pkBank)
verificationCode: "", //
subBankName: "", //
idType: "", //
}, },
}, isSendingCode: false, //
countdownSeconds: 60, //
verificationCodeButtonText: "获取验证码", //
countdownTimer: null, //
rules: {
cardNumber: [
{ required: true, message: "请输入银行卡号", trigger: "blur" },
],
verificationCode: [
{ required: true, message: "请输入验证码", trigger: "blur" },
{ validator: validateVerificationCode, trigger: "blur" },
], ],
idType: [ idType: [
{ required: true, message: '请选择证件类型', trigger: "change" }, { required: true, message: "请选择证件类型", trigger: "change" },
], ],
accountName: [ accountName: [
{ required: true, message: '请输入姓名', trigger: "blur" }, { required: true, message: "请输入姓名", trigger: "blur" },
], ],
subBankName: [ subBankName: [
{ required: true, message: '请输入开户支行', trigger: "blur" }, { required: true, message: "请输入开户支行", trigger: "blur" },
], ],
bankNo: [ // bankNo
{ required: true, message: '请输入银行卡卡号', trigger: "blur" }, // name
],
name: [{ required: true, message: '请输入真实姓名', trigger: "blur" }],
idCard: [ idCard: [
{ required: true, message: '请输入证件号码', trigger: "blur" }, { required: true, message: "请输入证件号码", trigger: "blur" },
], ],
// smsCode: [{ required: true, message: '', trigger: 'blur' }], // smsCode 使
phone: [ phone: [
{ {
required: true, required: true,
message: '请输入银行卡预留手机号', message: "请输入银行卡预留手机号",
trigger: "blur", trigger: "blur",
}, },
{ min: 11, message: '请输入正确的手机号', trigger: "blur" }, // { min: 11, message: '', trigger: "blur" }, // validator
{ { validator: validatePhoneNumber, trigger: "blur" },
validator: (rule, value, callback) => {
if (this.pkCountry === 1 && !value) {
callback(new Error('请输入正确的手机号'));
} else {
callback();
}
},
},
], ],
pkBank: [ bankId: [
{ required: true, message: '请选择银行卡', trigger: "change" }, // pkBank
{ required: true, message: "请选择银行卡", trigger: "change" },
], ],
}, },
ifpass: false, isBankCardVerified: false, // ( ifpass)
bankCardChioceList: [], bankCardChioceList: [], //
pkCountry: "", // pkCountry: "", // isMainlandChinaUser
cancode: true, needsVerificationCode: true, // ( cancode)
}; };
}, },
props: { props: {
isAdd: { // isAdd visible
visible: {
type: Boolean, type: Boolean,
default: false, default: false,
}, },
}, },
computed: { computed: {
...mapGetters(["userInfo"]), ...mapGetters(["userInfo"]),
//
isMainlandChinaUser() {
return this.userInfo?.pkCountry === 1;
},
}, },
watch: { watch: {
isAdd(val) { // prop
this.addShow = val; visible(newVal) {
this.dialogVisible = newVal;
if (newVal) {
//
this.resetFormState();
}
},
//
dialogVisible(newVal) {
if (!newVal) {
this.$emit("update:visible", false); // 使 .sync
this.$emit("closeBind", this.isBankCardVerified ? 1 : 0); //
this.resetFormAndValidation(); //
}
}, },
}, },
created() { created() {
this.getBankCardChoiceList(); this.fetchBankCardChoices();
this.checkIfWhite(); this.checkVerificationRequirement();
this.pkCountry = this.userInfo.pkCountry; // this.pkCountry = this.userInfo.pkCountry; // 使
},
beforeDestroy() {
//
if (this.countdownTimer) {
clearInterval(this.countdownTimer);
}
}, },
methods: { methods: {
checkIfWhite() { //
wal.checkIfWhite().then((res) => { checkVerificationRequirement() {
if (res.code == 200 && res.flag == "N") { walletApi
this.cancode = true; .checkIfWhite()
} else if (res.code == 200 && res.flag == "Y") { .then((res) => {
this.cancode = false; // flag 'Y'
} this.needsVerificationCode = !(res.code == 200 && res.flag === "Y");
})
.catch((_err) => {
//
console.error("获取白名单状态失败:", _err);
this.needsVerificationCode = true; //
}); });
}, },
getBankCardChoiceList() { //
wal.getBankCardChoiceList().then((res) => { fetchBankCardChoices() {
this.bankCardChioceList = res.data; walletApi
.getBankCardChoiceList()
.then((res) => {
this.bankCardChioceList = res.data || [];
})
.catch((_err) => {
console.error("获取银行列表失败:", _err);
}); });
//
wal.getCardType().then((res) => {
this.cardTypeList = res.data;
});
},
handleCloseBank() {
this.$emit("closeBind", 0);
this.$refs.form.resetFields();
},
//
bindBank() {
if (!this.form.verificationCode &&this.cancode&& this.pkCountry == 1) {
this.$message({
message: '验证码错误',
type: "warning",
});
return;
}
if (!this.ifpass && this.pkCountry == 1) {
this.$message({
message: '银行卡验证不一致',
type: "warning",
});
return;
}
let that = this;
wal.bindWalletBankAdd(this.form).then((res) => { walletApi
.getCardType()
.then((res) => {
this.cardTypeList = res.data || [];
})
.catch((_err) => {
console.error("获取证件类型失败:", _err);
});
},
//
handleCloseDialog() {
this.dialogVisible = false;
// watch resetFields emit
},
//
resetFormAndValidation() {
this.$refs.bankForm?.resetFields();
this.isBankCardVerified = false;
this.clearCountdown(); //
},
//
clearCountdown() {
if (this.countdownTimer) {
clearInterval(this.countdownTimer);
this.countdownTimer = null;
}
this.isSendingCode = false;
this.verificationCodeButtonText = "获取验证码";
this.countdownSeconds = 60;
},
//
resetFormState() {
this.isBankCardVerified = false;
this.clearCountdown();
},
//
performBindBank() {
//
if (!this.isMainlandChinaUser || !this.needsVerificationCode) {
this.isBankCardVerified = true;
}
if (!this.isBankCardVerified) {
this.$message({ this.$message({
message: '银行卡绑定成功', message: "请先完成银行卡验证", // ''
type: "warning",
});
return;
}
// let that = this; //
walletApi
.bindWalletBankAdd(this.form)
.then(() => {
this.$message({
message: "银行卡绑定成功",
type: "success", type: "success",
}); });
this.$refs.form.resetFields(); //
setTimeout(() => { setTimeout(() => {
that.$emit("closeBind", 1); // this.resetFormAndValidation(); // watch
// this.$emit("closeBind", 1); // watch
this.dialogVisible = false; //
}, 1500); }, 1500);
})
.catch((_err) => {
//
console.error("绑定银行卡失败:", _err);
this.$message({
message: "银行卡绑定失败,请稍后重试",
type: "error",
});
}); });
}, },
// // +
submitForm(form) { submitBankForm(formName) {
this.$refs[form].validate((valid) => { this.$refs[formName].validate((valid) => {
if (valid) { if (valid) {
if (this.pkCountry == 1) { //
if (this.cancode) { if (this.isMainlandChinaUser && this.needsVerificationCode) {
wal walletApi
.verifyBankCard(this.form) .verifyBankCard(this.form)
.then((res) => { .then(() => {
if (res.code == 200) { //
this.ifpass = true; this.isBankCardVerified = true;
this.bindBank(); this.performBindBank();
} else { })
this.ifpass = false; .catch((_err) => {
// 使 _err 使
//
this.isBankCardVerified = false;
//
this.$message({ this.$message({
message: res.msg, message: _err?.msg || "银行卡验证失败", // 使
type: "warning", type: "warning",
}); });
} // this.countdownSeconds = 0; // clearCountdown
}) this.clearCountdown(); //
.catch((err) => {
this.beginTime = 0;
this.ifpass = false;
}); });
} else { } else {
this.ifpass = true; //
this.bindBank(); // isBankCardVerified performBindBank true
this.performBindBank();
} }
} else { } else {
this.bindBank(); console.log("表单验证失败!");
}
} else {
// console.log('error submit!!')
return false; return false;
} }
}); });
}, },
startTime() { //
sendVerificationCode() {
if (!this.form.phone) { if (!this.form.phone) {
this.$message({ this.$message({
message: '请先输入手机号', message: "请先输入手机号",
type: "warning", type: "warning",
}); });
return; return;
}
if (this.isSendingCode) return; //
this.isSendingCode = true;
this.verificationCodeButtonText = `${this.countdownSeconds}s后重新发送`;
this.countdownTimer = setInterval(() => {
this.countdownSeconds--;
if (this.countdownSeconds <= 0) {
this.clearCountdown(); // 使
} else { } else {
if (this.isSend) return; this.verificationCodeButtonText = `${this.countdownSeconds}s后重新发送`;
this.isSend = true;
this.getCode = this.beginTime + 's后重新发送';
this.timer = setInterval(() => {
this.beginTime--;
this.getCode = this.beginTime + 's后重新发送';
if (this.beginTime < 0) {
clearInterval(this.timer);
this.getCode = '获取验证码';
this.beginTime = 60;
this.isSend = false;
} }
}, 1000); }, 1000);
wal.getVerification({ phone: this.form.phone }).then((res) => {
//
walletApi
.getVerification({ phone: this.form.phone })
.then(() => {
this.$message({ this.$message({
message: '验证码已发送', message: "验证码已发送",
type: "success", type: "success",
}); });
})
.catch((_err) => {
//
console.error("发送验证码失败:", _err);
// this.$message({
// message: "",
// type: "error",
// });
this.clearCountdown(); //
}); });
}
}, },
}, },
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.add_pay { //
padding: 20px; .bind-bank-form-container {
padding: 20px 30px; //
// 使 Element UI
::v-deep .el-form-item { ::v-deep .el-form-item {
border-bottom: 1px solid rgba(0, 0, 0, 0.05); // padding-bottom: 4px; margin-bottom: 22px; //
margin-bottom: 20px; padding-bottom: 8px; //
} display: flex; // label content
} align-items: center; //
.hqyzm1 {
background: #d5251d; .el-form-item__label {
border-radius: 8px; padding-right: 12px; //
padding: 0 7px; color: #333; //
color: #fff;
font-size: 10px;
cursor: pointer;
}
.hui {
opacity: 0.5;
}
.add_pay {
::v-deep .el-form-item {
display: flex;
align-items: center;
}
::v-deep .el-form-item__content {
flex: 1;
display: flex;
margin-left: 0 !important;
}
::v-deep .el-input {
flex: 1;
width: auto;
}
::v-deep .el-input__inner {
border: 0;
}
}
.surebtn1 {
display: flex;
align-items: center;
justify-content: space-around;
.btn {
width: 180px;
height: 50px;
background: #d5251d;
border-radius: 6px 6px 6px 6px;
text-align: center;
font-size: 14px;
font-family: PingFang SC-Medium, PingFang SC;
font-weight: 500;
color: #ffffff;
line-height: 50px;
cursor: pointer;
} }
.hh { .el-form-item__content {
background: #cccccc; flex: 1; //
margin-left: 0 !important; // Element UI margin
display: flex; // 使 input
align-items: center; //
}
.el-input,
.el-select {
flex: 1; // /
width: auto; //
}
// .el-input__inner, .el-select .el-input__inner {
// border: none; //
// padding-left: 0; //
// &:focus {
// box-shadow: none; //
// }
// }
// //
// .el-select .el-input.is-focus .el-input__inner {
// border: none !important;
// }
// .el-select .el-input__inner:focus {
// border-color: transparent !important; // Element UI
// }
}
//
::v-deep .el-form-item:last-child {
border-bottom: none;
margin-bottom: 0;
padding-bottom: 0;
} }
} }
//
.verification-code-button {
background-color: #d5251d; //
color: #ffffff;
border-radius: 4px; //
padding: 6px 12px; //
font-size: 12px; //
cursor: pointer;
white-space: nowrap; //
margin-left: 10px; //
transition: background-color 0.3s, opacity 0.3s; //
&:hover {
background-color: #c02018; // Hover
}
//
&.is-disabled {
opacity: 0.6;
cursor: not-allowed;
background-color: #fab6b6; //
&:hover {
background-color: #fab6b6; // Hover
}
}
}
//
.dialog-footer {
display: flex;
justify-content: space-around; //
padding: 20px 30px 30px; //
border-top: 1px solid #f0f0f0; //
.btn {
width: 160px; //
height: 45px; //
border-radius: 6px;
display: flex; // 使 flex
align-items: center;
justify-content: center;
font-size: 14px;
font-weight: 500;
cursor: pointer;
transition: background-color 0.3s; //
}
.confirm-btn {
background-color: #d5251d; //
color: #ffffff;
&:hover {
background-color: #c02018;
}
}
.cancel-btn {
background-color: #f5f5f5; //
color: #666; //
border: 1px solid #e0e0e0; //
&:hover {
background-color: #eeeeee;
}
}
}
// Element UI
::v-deep .el-dialog__title { ::v-deep .el-dialog__title {
font-weight: 500; font-weight: 500;
} }

View File

@ -6,6 +6,7 @@
:data="tableData" :data="tableData"
:header-cell-style="{ background: '#EEEEEE' }" :header-cell-style="{ background: '#EEEEEE' }"
:row-class-name="tableRowClassName" :row-class-name="tableRowClassName"
style="100%"
> >
<el-table-column <el-table-column
align="center" align="center"
@ -85,28 +86,20 @@
min-width="150px" min-width="150px"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column align="center" prop="remarks" :label="'备注'">
align="center"
prop="remarks"
:label="'备注'"
>
</el-table-column> </el-table-column>
<el-table-column <el-table-column align="center" prop="statusVal" :label="'状态'">
align="center"
prop="statusVal"
:label="'状态'"
>
</el-table-column> </el-table-column>
<el-table-column align="center" prop="" :label="'操作'"> <el-table-column fixed="right" align="center" prop="" :label="'操作'">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button <el-button
v-if="scope.row.status == 0 && scope.row.approveState == 1" v-if="scope.row.status == 0 && scope.row.approveState == 1"
style="color: red" style="color: var(--danger-color)"
@click="revoke(scope.row)" @click="revoke(scope.row)"
type="text" type="text"
size="small" size="small"
>{{ '撤销' }}</el-button >{{ "撤销" }}</el-button
> >
</template> </template>
</el-table-column> </el-table-column>
@ -122,7 +115,7 @@
</div> </div>
</template> </template>
<script> <script>
import pagination from "@/components/pagination.vue"; import pagination from "@/components/pagination.vue";
import { mapGetters } from "vuex"; import { mapGetters } from "vuex";
import { getWithdrawList, cancelWithdraw } from "@/api/wallet.js"; import { getWithdrawList, cancelWithdraw } from "@/api/wallet.js";
@ -157,7 +150,7 @@ export default {
methods: { methods: {
// //
revoke(row) { revoke(row) {
this.$confirm('是否确认操作?' + "?").then((_) => { this.$confirm("是否确认操作?" + "?").then((_) => {
cancelWithdraw({ pkId: row.pkId }).then((res) => { cancelWithdraw({ pkId: row.pkId }).then((res) => {
if (res.code == 200) { if (res.code == 200) {
this.$message({ this.$message({
@ -203,51 +196,15 @@ export default {
.contain { .contain {
background: rgba(249, 249, 249, 1); background: rgba(249, 249, 249, 1);
height: 100vh; height: 100vh;
display: flex;
.goodArea {
display: flex;
align-items: center;
font-size: 18px;
font-weight: 400;
color: #333333;
width: 100%; width: 100%;
height: 80px;
border-bottom: 5px solid rgba(0, 0, 0, 0.05);
.goodArea_i {
margin: 0 35px;
text-align: center;
cursor: pointer;
}
.actArea {
color: #00417C;
}
}
.topbox {
// height: 109px;
background: #ffffff;
box-shadow: 0px 0px 20px 0px rgba(204, 204, 204, 0.5);
border-radius: 8px 8px 8px 8px;
margin: 20px 0 40px 0;
padding: 30px 16px 10px 16px;
.searchbox {
display: flex;
align-items: center;
.btn1 {
background: #cccccc;
border-radius: 5px 5px 5px 5px;
color: #ffffff;
}
.btn2 {
border-radius: 5px 5px 5px 5px;
background: rgba(214, 24, 32, 1);
color: #ffffff;
}
}
}
.rightbox { .rightbox {
margin-top: 30px; margin-top: 30px;
width: 100%;
overflow: hidden;
} }
.tablebox { .tablebox {
width: 100%;
overflow-x: auto;
box-shadow: 0px 2px 20px 0px rgba(135, 135, 135, 0.3); box-shadow: 0px 2px 20px 0px rgba(135, 135, 135, 0.3);
border-radius: 10px 10px 10px 10px; border-radius: 10px 10px 10px 10px;
.tabletop { .tabletop {

View File

@ -9,4 +9,5 @@
--button-primary-disabled-text-color: #FFFFFF; /* 禁用主按钮文字颜色 (白色) */ --button-primary-disabled-text-color: #FFFFFF; /* 禁用主按钮文字颜色 (白色) */
--button-primary-disabled-bg-color: #A0CFFF; /* 禁用主按钮背景颜色 (主色变浅) */ --button-primary-disabled-bg-color: #A0CFFF; /* 禁用主按钮背景颜色 (主色变浅) */
--button-primary-disabled-border-color: #A0CFFF; /* 禁用主按钮边框颜色 (同背景) */ --button-primary-disabled-border-color: #A0CFFF; /* 禁用主按钮边框颜色 (同背景) */
--danger-color: #DC3545; /* 危险色 */
} }

View File

@ -543,6 +543,7 @@ export default {
.main_r { .main_r {
flex: 1; flex: 1;
padding: 0 60px 0 0px; padding: 0 60px 0 0px;
width: 0;
.banner { .banner {
width: 1458px; width: 1458px;
height: 253px; height: 253px;

File diff suppressed because one or more lines are too long