Commit cd0c2a66 authored by 张毅辰's avatar 张毅辰

操作日志

parent 1a16cc22
...@@ -24,7 +24,7 @@ export function getDictTypePage( ...@@ -24,7 +24,7 @@ export function getDictTypePage(
}); });
} }
/** 查询字典数据列表*/ /** 查询字典数据列表*/
export function listData(query) { export function listData(query: any) {
return request({ return request({
url: "/system/dict/data/list", url: "/system/dict/data/list",
method: "get", method: "get",
...@@ -32,7 +32,7 @@ export function listData(query) { ...@@ -32,7 +32,7 @@ export function listData(query) {
}); });
} }
export function listType(query) { export function listType(query: any) {
return request({ return request({
url: "/system/dict/type/list", url: "/system/dict/type/list",
method: "get", method: "get",
...@@ -40,7 +40,7 @@ export function listType(query) { ...@@ -40,7 +40,7 @@ export function listType(query) {
}); });
} }
/** 获取字典选择框列表*/ /** 获取字典选择框列表*/
export function selectDictType(dictType) { export function selectDictType(dictType: any) {
return request({ return request({
url: "/system/dict/data/type/" + dictType, url: "/system/dict/data/type/" + dictType,
method: "get", method: "get",
...@@ -57,7 +57,7 @@ export function exportType(queryParams: DictTypeQuery) { ...@@ -57,7 +57,7 @@ export function exportType(queryParams: DictTypeQuery) {
} }
/** 修改字典类型*/ /** 修改字典类型*/
export function updateType(data) { export function updateType(data: any) {
const businessId = data.businessId; const businessId = data.businessId;
return request({ return request({
url: "/system/dict/type/update/" + businessId, url: "/system/dict/type/update/" + businessId,
...@@ -67,7 +67,7 @@ export function updateType(data) { ...@@ -67,7 +67,7 @@ export function updateType(data) {
}); });
} }
/** 新增字典类型*/ /** 新增字典类型*/
export function addType(data) { export function addType(data: any) {
return request({ return request({
url: "/system/dict/type/add", url: "/system/dict/type/add",
method: "post", method: "post",
......
...@@ -35,12 +35,12 @@ const queryParams = reactive({ ...@@ -35,12 +35,12 @@ const queryParams = reactive({
username: "", username: "",
loginTime: "", loginTime: "",
}); });
const clearFrom = reactive({}); const clearForm = reactive({});
const exportRule = reactive({ const exportRule = reactive({
month: [{ required: true, message: "请选择月份", trigger: "change" }], month: [{ required: true, message: "请选择月份", trigger: "change" }],
}); });
const clearFromRef = ref(ElForm); const clearFormRef = ref(ElForm);
const exportFromRef = ref(ElForm); const exportFromRef = ref(ElForm);
onMounted(() => { onMounted(() => {
...@@ -109,7 +109,6 @@ function handleDelete(data) { ...@@ -109,7 +109,6 @@ function handleDelete(data) {
type: "warning", type: "warning",
}) })
.then(() => { .then(() => {
// const id = this.ids.join(',')
const id = data; const id = data;
const query = { const query = {
deleteIds: id, deleteIds: id,
...@@ -117,7 +116,7 @@ function handleDelete(data) { ...@@ -117,7 +116,7 @@ function handleDelete(data) {
return delLogininfo(query); return delLogininfo(query);
}) })
.then(() => { .then(() => {
this.getList(); getList();
ElMessage.success("删除成功"); ElMessage.success("删除成功");
ids.value = []; ids.value = [];
multiple.value = true; multiple.value = true;
...@@ -126,11 +125,11 @@ function handleDelete(data) { ...@@ -126,11 +125,11 @@ function handleDelete(data) {
} }
function clear() { function clear() {
clearFromRef.value.validate((valid) => { clearFormRef.value.validate((valid) => {
if (valid) { if (valid) {
const query = { const query = {
beginTime: clearFrom.month[0], beginTime: clearForm.month[0],
endTime: clearFrom.month[1], endTime: clearForm.month[1],
}; };
cleanLogininfo(query).then((res) => { cleanLogininfo(query).then((res) => {
if (res.code === 200) { if (res.code === 200) {
...@@ -148,7 +147,7 @@ function clear() { ...@@ -148,7 +147,7 @@ function clear() {
/** 清空按钮操作 */ /** 清空按钮操作 */
function handleClean() { function handleClean() {
clearVisible.value = true; clearVisible.value = true;
Object.assign(clearFrom, {}); Object.assign(clearForm, {});
} }
function exportSubmit() { function exportSubmit() {
...@@ -169,7 +168,6 @@ function exportSubmit() { ...@@ -169,7 +168,6 @@ function exportSubmit() {
document.body.removeChild(downloadElement); // 下载完成移除元素 document.body.removeChild(downloadElement); // 下载完成移除元素
window.URL.revokeObjectURL(href); // 释放掉blob对象 window.URL.revokeObjectURL(href); // 释放掉blob对象
exportVisible.value = false; exportVisible.value = false;
// this.download(response.msg)
}); });
} }
}); });
...@@ -311,14 +309,14 @@ function handleExport() { ...@@ -311,14 +309,14 @@ function handleExport() {
<!-- 清空弹窗--> <!-- 清空弹窗-->
<el-dialog <el-dialog
title="选择清空月份" title="选择清空月份"
v-model:visible="clearVisible" v-model="clearVisible"
width="30%" width="30%"
:before-close="handleClose" :before-close="handleClose"
> >
<el-form ref="clearFromRef" :model="clearFrom" :rules="clearRule"> <el-form ref="clearFormRef" :model="clearForm" :rules="clearRule">
<el-form-item label="月份" prop="month"> <el-form-item label="月份" prop="month">
<el-date-picker <el-date-picker
v-model="clearFrom.month" v-model="clearForm.month"
type="monthrange" type="monthrange"
range-separator="至" range-separator="至"
start-placeholder="开始月份" start-placeholder="开始月份"
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment