From 7aaca71bd1a51c9f9fe4d646595cb8f65e08df35 Mon Sep 17 00:00:00 2001
From: chenyao <1219716595@qq.com>
Date: Wed, 08 Apr 2026 19:03:38 +0800
Subject: [PATCH] feat:把反无搜索条件日期都加上00:00 或者23:59
---
uniapps/work-wx/src/subPackages/userDetail/infos/index.vue | 21 +++++++++++----------
applications/drone-command/src/views/permissionManage/operationLog/index.vue | 3 ++-
applications/drone-command/src/views/dataCockpit/components/DeviceHistoryDialog.vue | 4 ++--
3 files changed, 15 insertions(+), 13 deletions(-)
diff --git a/applications/drone-command/src/views/dataCockpit/components/DeviceHistoryDialog.vue b/applications/drone-command/src/views/dataCockpit/components/DeviceHistoryDialog.vue
index cfbb742..b7190b3 100644
--- a/applications/drone-command/src/views/dataCockpit/components/DeviceHistoryDialog.vue
+++ b/applications/drone-command/src/views/dataCockpit/components/DeviceHistoryDialog.vue
@@ -76,7 +76,7 @@
import { computed, ref, watch } from 'vue'
import { getDictionaryByCode } from '@/api/system/dictbiz'
import { alarmLogApi, areaDivideListApi } from '@/api/dataCockpit'
-import { getDictLabel } from '@ztzf/utils'
+import { getDictLabel,dateRangeFormat } from '@ztzf/utils'
const props = defineProps({
modelValue: {
@@ -155,7 +155,7 @@
total.value = 0
return
}
- const [startTime, endTime] = searchParams.value.dateRange || []
+ const [startTime, endTime] = dateRangeFormat(searchParams.value.dateRange) || []
const keyword = (searchParams.value.keyword || '').trim()
const params = {
alarmType: '2',
diff --git a/applications/drone-command/src/views/permissionManage/operationLog/index.vue b/applications/drone-command/src/views/permissionManage/operationLog/index.vue
index b93d686..3e85312 100644
--- a/applications/drone-command/src/views/permissionManage/operationLog/index.vue
+++ b/applications/drone-command/src/views/permissionManage/operationLog/index.vue
@@ -109,7 +109,8 @@
async function getList() {
loading.value = true
try {
- const params = { ...searchParams.value, startTime: dateRange.value[0], endTime: dateRange.value[1] }
+ const range = dateRangeFormat(dateRange.value)
+ const params = { ...searchParams.value, startTime: range[0], endTime: range[1] }
const res = await getOperationLogPage(params)
list.value = res?.data?.data?.records ?? []
total.value = res?.data?.data?.total ?? 0
diff --git a/uniapps/work-wx/src/subPackages/userDetail/infos/index.vue b/uniapps/work-wx/src/subPackages/userDetail/infos/index.vue
index 9c9eb35..7e63a9e 100644
--- a/uniapps/work-wx/src/subPackages/userDetail/infos/index.vue
+++ b/uniapps/work-wx/src/subPackages/userDetail/infos/index.vue
@@ -3,7 +3,8 @@
<view class="container">
<view class="pageBg"></view>
<div class="avatarBox">
- <u-avatar @click="uploadAvatar" :src="userInfo.avatar ? userInfo.avatar : showDefaultHeader" size="114" mode="aspectFill" />
+ <u-avatar :src="userInfo.avatar ? userInfo.avatar : showDefaultHeader" size="114" mode="aspectFill" />
+<!-- <u-avatar @click="uploadAvatar" :src="userInfo.avatar ? userInfo.avatar : showDefaultHeader" size="114" mode="aspectFill" />-->
</div>
<view class="detailBox">
<div class="detailCon">
@@ -142,25 +143,25 @@
// 提交文件
function afterReadFile(event) {
console.log('上传的文件:', event);
-
+
// 准备上传参数
const uploadParams = {
name: event.name, // 服务器端接收文件的字段名
file: event.file, // 传入文件对象
filePath: event.filePath, // 文件路径
};
-
+
// 调用上传文件接口
uploadFileApi(uploadParams).then(res => {
uni.hideLoading();
-
+
console.log('上传成功结果:', res);
-
+
// 根据接口返回的数据结构处理结果
if (res.data && res.data.code === 200) {
const uploadResult = res.data.data;
userInfo.value.avatar = uploadResult.fileUrl || '文件上传成功';
-
+
uni.showToast({
title: '上传成功',
icon: 'success'
@@ -198,7 +199,7 @@
const pathWithoutProtocol = filePath.replace(/^file:\/\//, '');
fileName = pathWithoutProtocol.split('/').pop() || 'unknown.png';
}
-
+
// 显示加载中
uni.showLoading({
title: '上传中...'
@@ -234,7 +235,7 @@
}
});
-
+
};
onShow(async () => {
getUserInfoData()
@@ -321,7 +322,7 @@
.custom-style {
width: 276rpx;
- height: 76rpx;
+ height: 76rpx;
}
:deep(.u-button.data-v-461e713c){
width: 276rpx !important;
@@ -336,4 +337,4 @@
color: #1D6FE9;
margin-top: 40rpx;
}
-</style>
\ No newline at end of file
+</style>
--
Gitblit v1.9.3