-
+
-
+
-
+
-
-
-
+
+
+
-
+
-
+
-
+
- {{ parseTime(scope.row.loginTime) }}
+ {{ parseTime(scope.row.createTime) }}
@@ -138,15 +138,15 @@ const multiple = ref(true);
const selectName = ref("");
const total = ref(0);
const dateRange = ref([]);
-const defaultSort = ref({ prop: "loginTime", order: "descending" });
+const defaultSort = ref({ prop: "createTime", order: "descending" });
// 查询参数
const queryParams = ref({
pageNum: 1,
pageSize: 10,
- ipaddr: undefined,
- userName: undefined,
- status: undefined,
+ loginIp: undefined,
+ loginUser: undefined,
+ isDeleted: undefined,
orderByColumn: undefined,
isAsc: undefined
});
@@ -155,8 +155,8 @@ const queryParams = ref({
function getList() {
loading.value = true;
list(proxy.addDateRange(queryParams.value, dateRange.value)).then(response => {
- logininforList.value = response.rows;
- total.value = response.total;
+ logininforList.value = response.data.data;
+ total.value = response.data.total;
loading.value = false;
});
}
@@ -174,10 +174,10 @@ function resetQuery() {
}
/** 多选框选中数据 */
function handleSelectionChange(selection) {
- ids.value = selection.map(item => item.infoId);
+ ids.value = selection.map(item => item.id);
multiple.value = !selection.length;
single.value = selection.length != 1;
- selectName.value = selection.map(item => item.userName);
+ selectName.value = selection.map(item => item.loginUser);
}
/** 排序触发事件 */
function handleSortChange(column, prop, order) {
@@ -187,7 +187,7 @@ function handleSortChange(column, prop, order) {
}
/** 删除按钮操作 */
function handleDelete(row) {
- const infoIds = row.infoId || ids.value;
+ const infoIds = row.id || ids.value;
proxy.$modal.confirm('是否确认删除访问编号为"' + infoIds + '"的数据项?').then(function () {
return delLogininfor(infoIds);
}).then(() => {
@@ -206,11 +206,11 @@ function handleClean() {
}
/** 解锁按钮操作 */
function handleUnlock() {
- const username = selectName.value;
- proxy.$modal.confirm('是否确认解锁用户"' + username + '"数据项?').then(function () {
- return unlockLogininfor(username);
+ const loginUser = selectName.value;
+ proxy.$modal.confirm('是否确认解锁用户"' + loginUser + '"数据项?').then(function () {
+ return unlockLogininfor(loginUser);
}).then(() => {
- proxy.$modal.msgSuccess("用户" + username + "解锁成功");
+ proxy.$modal.msgSuccess("用户" + loginUser + "解锁成功");
}).catch(() => {});
}
/** 导出按钮操作 */