提交 f1131306 作者: 施汉文

合并分支 'release' 到 'master'

新增礼包类型

查看合并请求 !64
......@@ -170,7 +170,7 @@ export default {
role_name: "",
role_id: "",
gift_package_id: "",
recharge_total: undefined
recharge_total: undefined,
},
loading: false,
};
......@@ -189,7 +189,7 @@ export default {
role_name: "",
role_id: "",
gift_package_id: "",
recharge_total: undefined
recharge_total: undefined,
};
},
computed: {
......@@ -209,7 +209,7 @@ export default {
methods: {
initGiftCodeForm() {
const username = this.bindGameUserList.find(
(item) => item.member_id === this.accountSelect
(item) => item.member_id === this.accountSelect,
).username;
this.giftCodeForm = {
member_id: this.accountSelect,
......@@ -217,7 +217,7 @@ export default {
role_name: "",
role_id: "",
gift_package_id: "",
recharge_total: undefined
recharge_total: undefined,
};
},
sendVipGift() {
......@@ -289,7 +289,7 @@ export default {
handleFlowerLinkSuccess(url) {
if (url) {
this.sendChatMessage(url, "text");
this.$message.success('发送成功')
this.$message.success("发送成功");
}
},
// 发送举报申诉自助链接
......@@ -339,12 +339,12 @@ export default {
},
// 确定提交
getGiftCodeSubmit(form) {
const { member_id, role_id, username, role_name ,recharge_total} = form;
const { member_id, role_id, username, role_name, recharge_total } = form;
this.giftCodeForm.username = username;
this.giftCodeForm.role_name = role_name;
this.giftCodeForm.member_id = member_id;
this.giftCodeForm.role_id = role_id;
this.giftCodeForm.recharge_total = recharge_total
this.giftCodeForm.recharge_total = recharge_total;
this.sendGameCode();
},
sendGameCodeCopyDialog(items) {
......@@ -353,7 +353,7 @@ export default {
this.game_name = items.name;
this.initGiftCodeForm();
this.giftCodeForm.gift_package_id = items.id;
if (items.package_type == 3) {
if (items.package_type == 3 || items.package_type == 5) {
this.dialogVisible = true;
} else {
this.sendGameCode();
......@@ -379,9 +379,12 @@ export default {
gift_package_id: this.giftCodeForm.gift_package_id,
user_type: 3,
};
// 如果存在 recharge_total 则添加到请求参数中 表示是 角色礼包
if (this.giftCodeForm.recharge_total !== undefined && this.giftCodeForm.recharge_total !== null) {
data.recharge_total = this.giftCodeForm.recharge_total
// 如果存在 recharge_total 则添加到请求参数中 表示是 角色礼包
if (
this.giftCodeForm.recharge_total !== undefined &&
this.giftCodeForm.recharge_total !== null
) {
data.recharge_total = this.giftCodeForm.recharge_total;
}
const res = await sendGiftCode(data);
if (res.status_code === 1) {
......@@ -390,13 +393,13 @@ export default {
} else {
this.$message.error(res.msg || "发送失败");
}
this.giftCodeForm.recharge_total = undefined
this.giftCodeForm.recharge_total = undefined;
this.loading = false;
},
handleAccount() {
if (this.bindGameUserList.length > 0) {
const account = this.bindGameUserList.find(
(item) => item.member_id == this.accountSelect
(item) => item.member_id == this.accountSelect,
);
if (account) {
return true;
......@@ -423,13 +426,13 @@ export default {
} else {
}
const username = this.bindGameUserList.find(
(item) => item.member_id == this.accountSelect
(item) => item.member_id == this.accountSelect,
).username;
passwardEncryption({ member_id: this.accountSelect })
.then((res) => {
this.sendChatMessage(
`${str}${item.url} \n账号:${username} \n密码:${res.data.password}`,
"text"
"text",
);
})
.catch((err) => {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论