upload project source code
This commit is contained in:
625
后端源码/yifan.action-ai.cn/index/js/index.BhWri54q.js
Normal file
625
后端源码/yifan.action-ai.cn/index/js/index.BhWri54q.js
Normal file
@@ -0,0 +1,625 @@
|
||||
import { x as ElFormItem, y as ElInput, aq as ElSelect, ar as ElOption, h as ElButton, w as ElForm, ao as vLoading, al as ElTable, am as ElTableColumn, av as ElInputNumber, v as ElDialog, E as ElMessage, T as ElCard } from "./element-plus.CkEW9frc.js";
|
||||
import { _ as __unplugin_components_19 } from "./index.fgd49PES.js";
|
||||
import { Y as YifanMembershipAPI } from "./yifan_membership.CCYhkrJx.js";
|
||||
import { J as defineComponent, t as onMounted, S as openBlock, _ as createElementBlock, a1 as createBaseVNode, $ as createVNode, a0 as withCtx, a9 as createTextVNode, a6 as withDirectives, T as createBlock, aa as toDisplayString, r as ref, ak as reactive } from "./.pnpm.BW3P1y8f.js";
|
||||
import { _ as _export_sfc } from "./_plugin-vue_export-helper.1tPrXgE0.js";
|
||||
import "./index.CMd5bD1r.js";
|
||||
import "./codemirror.CvJAcn2d.js";
|
||||
const _hoisted_1 = { class: "app-container" };
|
||||
const _hoisted_2 = { class: "search-container" };
|
||||
const _hoisted_3 = { class: "quick-actions" };
|
||||
const _hoisted_4 = { class: "operation-header" };
|
||||
const _hoisted_5 = { class: "operation-footer" };
|
||||
const _sfc_main = /* @__PURE__ */ defineComponent({
|
||||
...{
|
||||
name: "YifanMembershipMember",
|
||||
inheritAttrs: false
|
||||
},
|
||||
__name: "index",
|
||||
setup(__props) {
|
||||
const loading = ref(false);
|
||||
const tableData = ref([]);
|
||||
const total = ref(0);
|
||||
const quotaSubmitting = ref(false);
|
||||
const operationLoading = ref(false);
|
||||
const operationTableData = ref([]);
|
||||
const operationTotal = ref(0);
|
||||
const levelTextMap = {
|
||||
junior: "初级会员",
|
||||
senior: "高级会员"
|
||||
};
|
||||
const queryForm = reactive({
|
||||
page_no: 1,
|
||||
page_size: 10,
|
||||
user_id: "",
|
||||
member_level: "",
|
||||
min_quota: "",
|
||||
max_quota: "",
|
||||
min_discount_rate: "",
|
||||
max_discount_rate: ""
|
||||
});
|
||||
const quotaDialog = reactive({
|
||||
visible: false,
|
||||
user_id: 0,
|
||||
current_quota: 0,
|
||||
member_level: void 0,
|
||||
quota_delta: 0
|
||||
});
|
||||
const operationDialog = reactive({
|
||||
visible: false,
|
||||
user_id: 0
|
||||
});
|
||||
const operationQuery = reactive({
|
||||
page_no: 1,
|
||||
page_size: 10
|
||||
});
|
||||
function toNumber(value) {
|
||||
if (value === "" || value === void 0 || value === null) return void 0;
|
||||
const num = Number(value);
|
||||
return Number.isNaN(num) ? void 0 : num;
|
||||
}
|
||||
function toRate(value) {
|
||||
const num = Number(value);
|
||||
if (Number.isNaN(num)) return 0;
|
||||
return Number(num.toFixed(2));
|
||||
}
|
||||
function toPercent(value) {
|
||||
return `${(toRate(value) * 100).toFixed(2)}%`;
|
||||
}
|
||||
function buildQuery() {
|
||||
return {
|
||||
page_no: queryForm.page_no,
|
||||
page_size: queryForm.page_size,
|
||||
user_id: toNumber(queryForm.user_id),
|
||||
member_level: queryForm.member_level && queryForm.member_level !== "all" ? queryForm.member_level : void 0,
|
||||
min_quota: toNumber(queryForm.min_quota),
|
||||
max_quota: toNumber(queryForm.max_quota),
|
||||
min_discount_rate: toNumber(queryForm.min_discount_rate),
|
||||
max_discount_rate: toNumber(queryForm.max_discount_rate)
|
||||
};
|
||||
}
|
||||
async function loadData() {
|
||||
loading.value = true;
|
||||
try {
|
||||
const response = await YifanMembershipAPI.getMemberList(buildQuery());
|
||||
const data = response.data.data;
|
||||
const rawItems = Array.isArray(data) ? data : (data == null ? void 0 : data.items) || (data == null ? void 0 : data.list) || (data == null ? void 0 : data.records) || (data == null ? void 0 : data.rows) || [];
|
||||
const rawTotal = Array.isArray(data) ? data.length : (data == null ? void 0 : data.total) ?? (data == null ? void 0 : data.count) ?? (data == null ? void 0 : data.total_count) ?? rawItems.length;
|
||||
tableData.value = (rawItems || []).map((item) => ({
|
||||
...item,
|
||||
user_id: Number(item.user_id),
|
||||
free_rename_quota: Number(item.free_rename_quota || 0),
|
||||
discount_rate: toRate(item.discount_rate)
|
||||
}));
|
||||
total.value = Number(rawTotal || 0);
|
||||
} catch (error) {
|
||||
ElMessage.error((error == null ? void 0 : error.message) || "会员列表加载失败");
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
}
|
||||
function handleQuery() {
|
||||
queryForm.page_no = 1;
|
||||
loadData();
|
||||
}
|
||||
function handleReset() {
|
||||
queryForm.user_id = "";
|
||||
queryForm.member_level = "";
|
||||
queryForm.min_quota = "";
|
||||
queryForm.max_quota = "";
|
||||
queryForm.min_discount_rate = "";
|
||||
queryForm.max_discount_rate = "";
|
||||
queryForm.page_no = 1;
|
||||
loadData();
|
||||
}
|
||||
function openQuotaDialog(row) {
|
||||
quotaDialog.visible = true;
|
||||
quotaDialog.user_id = Number(row.user_id);
|
||||
quotaDialog.current_quota = Number(row.free_rename_quota || 0);
|
||||
quotaDialog.member_level = row.member_level;
|
||||
quotaDialog.quota_delta = 0;
|
||||
}
|
||||
async function loadOperationRecords() {
|
||||
if (!operationDialog.user_id) return;
|
||||
operationLoading.value = true;
|
||||
try {
|
||||
const response = await YifanMembershipAPI.getOperationRecords({
|
||||
user_id: operationDialog.user_id,
|
||||
page_no: operationQuery.page_no,
|
||||
page_size: operationQuery.page_size
|
||||
});
|
||||
const data = response.data.data;
|
||||
const rawItems = Array.isArray(data) ? data : (data == null ? void 0 : data.items) || (data == null ? void 0 : data.list) || (data == null ? void 0 : data.records) || (data == null ? void 0 : data.rows) || [];
|
||||
const rawTotal = Array.isArray(data) ? data.length : (data == null ? void 0 : data.total) ?? (data == null ? void 0 : data.count) ?? (data == null ? void 0 : data.total_count) ?? rawItems.length;
|
||||
operationTableData.value = (rawItems || []).map((item) => ({
|
||||
...item,
|
||||
quota_delta: Number(item.quota_delta ?? 0),
|
||||
before_quota: Number(item.before_quota ?? 0),
|
||||
after_quota: Number(item.after_quota ?? 0)
|
||||
}));
|
||||
operationTotal.value = Number(rawTotal || 0);
|
||||
} catch (error) {
|
||||
ElMessage.error((error == null ? void 0 : error.message) || "操作记录加载失败");
|
||||
} finally {
|
||||
operationLoading.value = false;
|
||||
}
|
||||
}
|
||||
function openOperationDialog(row) {
|
||||
operationDialog.visible = true;
|
||||
operationDialog.user_id = Number(row.user_id);
|
||||
operationQuery.page_no = 1;
|
||||
operationTableData.value = [];
|
||||
operationTotal.value = 0;
|
||||
loadOperationRecords();
|
||||
}
|
||||
function applyQuickDelta(value) {
|
||||
quotaDialog.quota_delta = Number(quotaDialog.quota_delta || 0) + value;
|
||||
}
|
||||
async function submitQuotaAdjust() {
|
||||
if (!quotaDialog.user_id) {
|
||||
ElMessage.warning("请先选择用户");
|
||||
return;
|
||||
}
|
||||
if (!quotaDialog.quota_delta) {
|
||||
ElMessage.warning("名额调整值不能为0");
|
||||
return;
|
||||
}
|
||||
quotaSubmitting.value = true;
|
||||
try {
|
||||
await YifanMembershipAPI.adjustQuota({
|
||||
user_id: Number(quotaDialog.user_id),
|
||||
member_level: quotaDialog.member_level,
|
||||
quota_delta: Number(quotaDialog.quota_delta)
|
||||
});
|
||||
quotaDialog.visible = false;
|
||||
quotaDialog.current_quota = 0;
|
||||
await loadData();
|
||||
} catch (error) {
|
||||
ElMessage.error((error == null ? void 0 : error.message) || "名额发放失败");
|
||||
} finally {
|
||||
quotaSubmitting.value = false;
|
||||
}
|
||||
}
|
||||
onMounted(() => {
|
||||
loadData();
|
||||
});
|
||||
return (_ctx, _cache) => {
|
||||
const _component_el_input = ElInput;
|
||||
const _component_el_form_item = ElFormItem;
|
||||
const _component_el_option = ElOption;
|
||||
const _component_el_select = ElSelect;
|
||||
const _component_el_button = ElButton;
|
||||
const _component_el_form = ElForm;
|
||||
const _component_el_table_column = ElTableColumn;
|
||||
const _component_el_table = ElTable;
|
||||
const _component_pagination = __unplugin_components_19;
|
||||
const _component_el_card = ElCard;
|
||||
const _component_el_input_number = ElInputNumber;
|
||||
const _component_el_dialog = ElDialog;
|
||||
const _directive_loading = vLoading;
|
||||
return openBlock(), createElementBlock("div", _hoisted_1, [
|
||||
createBaseVNode("div", _hoisted_2, [
|
||||
createVNode(_component_el_form, {
|
||||
model: queryForm,
|
||||
inline: "",
|
||||
"label-suffix": ":"
|
||||
}, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_form_item, { label: "用户ID" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_input, {
|
||||
modelValue: queryForm.user_id,
|
||||
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => queryForm.user_id = $event),
|
||||
placeholder: "请输入用户ID",
|
||||
clearable: ""
|
||||
}, null, 8, ["modelValue"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, { label: "会员等级" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_select, {
|
||||
modelValue: queryForm.member_level,
|
||||
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => queryForm.member_level = $event),
|
||||
style: { "width": "180px" },
|
||||
clearable: "",
|
||||
placeholder: "请选择"
|
||||
}, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_option, {
|
||||
label: "全部",
|
||||
value: "all"
|
||||
}),
|
||||
createVNode(_component_el_option, {
|
||||
label: "初级会员",
|
||||
value: "junior"
|
||||
}),
|
||||
createVNode(_component_el_option, {
|
||||
label: "高级会员",
|
||||
value: "senior"
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
}, 8, ["modelValue"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, { label: "名额范围" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_input, {
|
||||
modelValue: queryForm.min_quota,
|
||||
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => queryForm.min_quota = $event),
|
||||
style: { "width": "100px" },
|
||||
placeholder: "最小",
|
||||
clearable: ""
|
||||
}, null, 8, ["modelValue"]),
|
||||
_cache[22] || (_cache[22] = createBaseVNode("span", { class: "range-sep" }, "-", -1)),
|
||||
createVNode(_component_el_input, {
|
||||
modelValue: queryForm.max_quota,
|
||||
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => queryForm.max_quota = $event),
|
||||
style: { "width": "100px" },
|
||||
placeholder: "最大",
|
||||
clearable: ""
|
||||
}, null, 8, ["modelValue"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, { label: "折扣范围" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_input, {
|
||||
modelValue: queryForm.min_discount_rate,
|
||||
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => queryForm.min_discount_rate = $event),
|
||||
style: { "width": "100px" },
|
||||
placeholder: "最小",
|
||||
clearable: ""
|
||||
}, null, 8, ["modelValue"]),
|
||||
_cache[23] || (_cache[23] = createBaseVNode("span", { class: "range-sep" }, "-", -1)),
|
||||
createVNode(_component_el_input, {
|
||||
modelValue: queryForm.max_discount_rate,
|
||||
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => queryForm.max_discount_rate = $event),
|
||||
style: { "width": "100px" },
|
||||
placeholder: "最大",
|
||||
clearable: ""
|
||||
}, null, 8, ["modelValue"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, null, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_button, {
|
||||
type: "primary",
|
||||
icon: "Search",
|
||||
onClick: handleQuery
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[24] || (_cache[24] = [
|
||||
createTextVNode("查询", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_button, {
|
||||
icon: "Refresh",
|
||||
onClick: handleReset
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[25] || (_cache[25] = [
|
||||
createTextVNode("重置", -1)
|
||||
])]),
|
||||
_: 1
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
}, 8, ["model"])
|
||||
]),
|
||||
withDirectives((openBlock(), createBlock(_component_el_card, null, {
|
||||
header: withCtx(() => [..._cache[26] || (_cache[26] = [
|
||||
createBaseVNode("div", { class: "card-header" }, "会员列表", -1)
|
||||
])]),
|
||||
footer: withCtx(() => [
|
||||
createVNode(_component_pagination, {
|
||||
total: total.value,
|
||||
"onUpdate:total": _cache[6] || (_cache[6] = ($event) => total.value = $event),
|
||||
page: queryForm.page_no,
|
||||
"onUpdate:page": _cache[7] || (_cache[7] = ($event) => queryForm.page_no = $event),
|
||||
limit: queryForm.page_size,
|
||||
"onUpdate:limit": _cache[8] || (_cache[8] = ($event) => queryForm.page_size = $event),
|
||||
onPagination: loadData
|
||||
}, null, 8, ["total", "page", "limit"])
|
||||
]),
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_table, {
|
||||
data: tableData.value,
|
||||
border: "",
|
||||
stripe: ""
|
||||
}, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "用户ID",
|
||||
prop: "user_id",
|
||||
"min-width": "90"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "用户名",
|
||||
prop: "username",
|
||||
"min-width": "120"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "会员等级",
|
||||
prop: "member_level",
|
||||
"min-width": "110"
|
||||
}, {
|
||||
default: withCtx((scope) => [
|
||||
createTextVNode(toDisplayString(levelTextMap[scope.row.member_level] || scope.row.member_level), 1)
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "剩余免费改名名额",
|
||||
prop: "free_rename_quota",
|
||||
"min-width": "160"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "折扣比例",
|
||||
prop: "discount_rate",
|
||||
"min-width": "120"
|
||||
}, {
|
||||
default: withCtx((scope) => [
|
||||
createTextVNode(toDisplayString(toPercent(scope.row.discount_rate)), 1)
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "操作",
|
||||
"min-width": "120",
|
||||
fixed: "right"
|
||||
}, {
|
||||
default: withCtx((scope) => [
|
||||
createVNode(_component_el_button, {
|
||||
link: "",
|
||||
type: "primary",
|
||||
onClick: ($event) => openQuotaDialog(scope.row)
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[27] || (_cache[27] = [
|
||||
createTextVNode(" 发放名额 ", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}, 8, ["onClick"]),
|
||||
createVNode(_component_el_button, {
|
||||
link: "",
|
||||
type: "info",
|
||||
onClick: ($event) => openOperationDialog(scope.row)
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[28] || (_cache[28] = [
|
||||
createTextVNode(" 操作记录 ", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}, 8, ["onClick"])
|
||||
]),
|
||||
_: 1
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
}, 8, ["data"])
|
||||
]),
|
||||
_: 1
|
||||
})), [
|
||||
[_directive_loading, loading.value]
|
||||
]),
|
||||
createVNode(_component_el_dialog, {
|
||||
modelValue: quotaDialog.visible,
|
||||
"onUpdate:modelValue": _cache[16] || (_cache[16] = ($event) => quotaDialog.visible = $event),
|
||||
title: "免费名额发放",
|
||||
width: "420px"
|
||||
}, {
|
||||
footer: withCtx(() => [
|
||||
createVNode(_component_el_button, {
|
||||
onClick: _cache[15] || (_cache[15] = ($event) => quotaDialog.visible = false)
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[33] || (_cache[33] = [
|
||||
createTextVNode("取消", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_button, {
|
||||
type: "primary",
|
||||
loading: quotaSubmitting.value,
|
||||
onClick: submitQuotaAdjust
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[34] || (_cache[34] = [
|
||||
createTextVNode("确定", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}, 8, ["loading"])
|
||||
]),
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_form, {
|
||||
"label-width": "110px",
|
||||
"label-suffix": ":"
|
||||
}, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_form_item, { label: "用户ID" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_input, {
|
||||
"model-value": String(quotaDialog.user_id || ""),
|
||||
disabled: ""
|
||||
}, null, 8, ["model-value"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, { label: "当前剩余名额" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_input, {
|
||||
"model-value": String(quotaDialog.current_quota ?? 0),
|
||||
disabled: ""
|
||||
}, null, 8, ["model-value"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, { label: "会员等级" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_select, {
|
||||
modelValue: quotaDialog.member_level,
|
||||
"onUpdate:modelValue": _cache[9] || (_cache[9] = ($event) => quotaDialog.member_level = $event),
|
||||
clearable: "",
|
||||
placeholder: "不填则按当前等级"
|
||||
}, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_option, {
|
||||
label: "初级会员",
|
||||
value: "junior"
|
||||
}),
|
||||
createVNode(_component_el_option, {
|
||||
label: "高级会员",
|
||||
value: "senior"
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
}, 8, ["modelValue"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, { label: "名额调整值" }, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_input_number, {
|
||||
modelValue: quotaDialog.quota_delta,
|
||||
"onUpdate:modelValue": _cache[10] || (_cache[10] = ($event) => quotaDialog.quota_delta = $event),
|
||||
step: 1,
|
||||
precision: 0
|
||||
}, null, 8, ["modelValue"])
|
||||
]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_form_item, { label: "快捷操作" }, {
|
||||
default: withCtx(() => [
|
||||
createBaseVNode("div", _hoisted_3, [
|
||||
createVNode(_component_el_button, {
|
||||
size: "small",
|
||||
onClick: _cache[11] || (_cache[11] = ($event) => applyQuickDelta(10))
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[29] || (_cache[29] = [
|
||||
createTextVNode("+10", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_button, {
|
||||
size: "small",
|
||||
onClick: _cache[12] || (_cache[12] = ($event) => applyQuickDelta(1))
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[30] || (_cache[30] = [
|
||||
createTextVNode("+1", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_button, {
|
||||
size: "small",
|
||||
onClick: _cache[13] || (_cache[13] = ($event) => applyQuickDelta(-1))
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[31] || (_cache[31] = [
|
||||
createTextVNode("-1", -1)
|
||||
])]),
|
||||
_: 1
|
||||
}),
|
||||
createVNode(_component_el_button, {
|
||||
size: "small",
|
||||
onClick: _cache[14] || (_cache[14] = ($event) => applyQuickDelta(-10))
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[32] || (_cache[32] = [
|
||||
createTextVNode("-10", -1)
|
||||
])]),
|
||||
_: 1
|
||||
})
|
||||
])
|
||||
]),
|
||||
_: 1
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
}, 8, ["modelValue"]),
|
||||
createVNode(_component_el_dialog, {
|
||||
modelValue: operationDialog.visible,
|
||||
"onUpdate:modelValue": _cache[21] || (_cache[21] = ($event) => operationDialog.visible = $event),
|
||||
title: "用户操作记录",
|
||||
width: "860px"
|
||||
}, {
|
||||
footer: withCtx(() => [
|
||||
createVNode(_component_el_button, {
|
||||
onClick: _cache[20] || (_cache[20] = ($event) => operationDialog.visible = false)
|
||||
}, {
|
||||
default: withCtx(() => [..._cache[35] || (_cache[35] = [
|
||||
createTextVNode("关闭", -1)
|
||||
])]),
|
||||
_: 1
|
||||
})
|
||||
]),
|
||||
default: withCtx(() => [
|
||||
createBaseVNode("div", _hoisted_4, [
|
||||
createBaseVNode("span", null, "用户ID:" + toDisplayString(operationDialog.user_id), 1)
|
||||
]),
|
||||
withDirectives((openBlock(), createBlock(_component_el_table, {
|
||||
data: operationTableData.value,
|
||||
border: "",
|
||||
stripe: "",
|
||||
"max-height": "420"
|
||||
}, {
|
||||
default: withCtx(() => [
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "时间",
|
||||
prop: "created_time",
|
||||
"min-width": "170"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "操作类型",
|
||||
prop: "operation_type",
|
||||
"min-width": "120"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "操作说明",
|
||||
prop: "operation_desc",
|
||||
"min-width": "220"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "变更值",
|
||||
prop: "quota_delta",
|
||||
"min-width": "90"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "变更前名额",
|
||||
prop: "before_quota",
|
||||
"min-width": "110"
|
||||
}),
|
||||
createVNode(_component_el_table_column, {
|
||||
label: "变更后名额",
|
||||
prop: "after_quota",
|
||||
"min-width": "110"
|
||||
})
|
||||
]),
|
||||
_: 1
|
||||
}, 8, ["data"])), [
|
||||
[_directive_loading, operationLoading.value]
|
||||
]),
|
||||
createBaseVNode("div", _hoisted_5, [
|
||||
createVNode(_component_pagination, {
|
||||
total: operationTotal.value,
|
||||
"onUpdate:total": _cache[17] || (_cache[17] = ($event) => operationTotal.value = $event),
|
||||
page: operationQuery.page_no,
|
||||
"onUpdate:page": _cache[18] || (_cache[18] = ($event) => operationQuery.page_no = $event),
|
||||
limit: operationQuery.page_size,
|
||||
"onUpdate:limit": _cache[19] || (_cache[19] = ($event) => operationQuery.page_size = $event),
|
||||
onPagination: loadOperationRecords
|
||||
}, null, 8, ["total", "page", "limit"])
|
||||
])
|
||||
]),
|
||||
_: 1
|
||||
}, 8, ["modelValue"])
|
||||
]);
|
||||
};
|
||||
}
|
||||
});
|
||||
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-28a8ed3c"]]);
|
||||
export {
|
||||
index as default
|
||||
};
|
||||
Reference in New Issue
Block a user