diff --git a/src/locales/en-US.js b/src/locales/en-US.js
index dbab4b9..1fe7f54 100644
--- a/src/locales/en-US.js
+++ b/src/locales/en-US.js
@@ -866,7 +866,9 @@ export default {
deviceStatus: 'Device Status',
lineFilter: 'Line',
allFilter: 'All Filters',
+ moreFilter: 'More Filters',
categoryStatus: 'Category & Status',
+ categoryInfo: 'Category Info',
dateFilter: 'Date Filter',
deviceBrand: 'Device Brand',
sn: 'Serial No.',
@@ -908,6 +910,8 @@ export default {
placeholderDataCollectionCapacity: 'Enter data collection capacity',
placeholderProductionDate: 'Select production date',
placeholderOutgoingTime: 'Select outgoing date',
+ placeholderOutgoingStartTime: 'Start date',
+ placeholderOutgoingEndTime: 'End date',
placeholderFactoryEntryDate: 'Select factory entry date',
placeholderDeviceLocation: 'Enter device location',
placeholderRemark: 'Enter remark',
diff --git a/src/locales/zh-CN.js b/src/locales/zh-CN.js
index 8d1a141..dd63b7e 100644
--- a/src/locales/zh-CN.js
+++ b/src/locales/zh-CN.js
@@ -865,11 +865,13 @@ export default {
deviceType: '设备类型',
deviceStatus: '设备状态',
lineFilter: '产线',
- allFilter: '\u5168\u90e8\u7b5b\u9009',
- categoryStatus: '\u5206\u7c7b\u72b6\u6001',
- dateFilter: '\u65e5\u671f\u7b5b\u9009',
- deviceBrand: '\u8bbe\u5907\u54c1\u724c',
- sn: '\u5e8f\u5217\u53f7',
+ allFilter: '全部筛选',
+ moreFilter: '更多筛选',
+ categoryStatus: '分类状态',
+ categoryInfo: '分类信息',
+ dateFilter: '日期筛选',
+ deviceBrand: '设备品牌',
+ sn: '序列号',
scanUnrecognized: '未识别二维码内容',
scanTypeMismatch: '二维码类型不匹配',
scanFailed: '扫码失败',
@@ -899,8 +901,8 @@ export default {
loadFailed: '加载设备详情失败',
placeholderDeviceCode: '请输入设备编码',
placeholderDeviceName: '请输入设备名称',
- placeholderDeviceBrand: '\u8bf7\u8f93\u5165\u8bbe\u5907\u54c1\u724c',
- placeholderSn: '\u8bf7\u8f93\u5165\u5e8f\u5217\u53f7',
+ placeholderDeviceBrand: '请输入设备品牌',
+ placeholderSn: '请输入序列号',
placeholderDeviceType: '请选择设备类型',
placeholderDeviceSpec: '请输入设备规格',
placeholderRatedCapacity: '请输入额定产能',
@@ -908,6 +910,8 @@ export default {
placeholderDataCollectionCapacity: '请输入数据采集产能',
placeholderProductionDate: '请选择生产日期',
placeholderOutgoingTime: '请选择出厂日期',
+ placeholderOutgoingStartTime: '开始日期',
+ placeholderOutgoingEndTime: '结束日期',
placeholderFactoryEntryDate: '请选择入厂日期',
placeholderDeviceLocation: '请输入设备位置',
placeholderRemark: '请输入备注',
@@ -1541,7 +1545,7 @@ export default {
moduleName: '产品盘点执行',
createTitle: '新增产品盘点',
executeTitle: '执行盘点',
- detailTitle: '\u4ea7\u54c1\u76d8\u70b9\u8be6\u60c5',
+ detailTitle: '产品盘点详情',
selectProductTitle: '选择产品',
selectItemTitle: '选择盘点项',
selectWarehouseTitle: '选择仓库',
diff --git a/src/pages_function/pages/equipmentLedger/index.vue b/src/pages_function/pages/equipmentLedger/index.vue
index 5f3a2e0..215119e 100644
--- a/src/pages_function/pages/equipmentLedger/index.vue
+++ b/src/pages_function/pages/equipmentLedger/index.vue
@@ -26,7 +26,7 @@
-
+
@@ -75,10 +75,11 @@
-
+
@@ -173,8 +134,9 @@
{{ t('equipmentLedger.outgoingTime') }}
-
+
@@ -222,13 +184,10 @@ const searchKeyword = ref('');
const selectedStatus = ref('');
const selectedLineId = ref('');
const selectedDeviceTypeId = ref('');
-const deviceCodeFilter = ref('');
-const deviceNameFilter = ref('');
const deviceBrandFilter = ref('');
const snFilter = ref('');
-const outgoingTimeFilter = ref('');
+const outgoingTimeFilter = ref([]);
const drawerDeviceTypePanelOpen = ref(false);
-const drawerLinePanelOpen = ref(false);
const filterPopupRef = ref(null);
const lineTree = ref([]);
const deviceTypeTree = ref([]);
@@ -294,10 +253,6 @@ const selectedLineLabel = computed(() => {
);
return found?.name || t('equipmentLedger.lineFilter');
});
-const drawerLineOptions = computed(() => [
- { id: '', name: t('functionCommon.all'), level: 0 },
- ...lineOptions.value,
-]);
const deviceTypeOptions = computed(() => flattenLineTree(deviceTypeTree.value));
const deviceTypeCascaderOptions = computed(() => [
{ label: t('functionCommon.all'), value: '' },
@@ -449,15 +404,14 @@ async function fetchList(reset) {
}
try {
const keyword = searchKeyword.value.trim();
- const deviceCode = deviceCodeFilter.value.trim();
- const deviceName = deviceNameFilter.value.trim();
const deviceBrand = deviceBrandFilter.value.trim();
const sn = snFilter.value.trim();
+ const outgoingTimeRange = Array.isArray(outgoingTimeFilter.value) ? outgoingTimeFilter.value : [];
const params = {
pageNo: pageNo.value,
pageSize: pageSize.value,
- deviceCode: deviceCode || keyword || undefined,
- deviceName: deviceName || keyword || undefined,
+ deviceCode: keyword || undefined,
+ deviceName: keyword || undefined,
deviceStatus:
selectedStatus.value === '' ? undefined : selectedStatus.value,
deviceLine:
@@ -466,7 +420,8 @@ async function fetchList(reset) {
selectedDeviceTypeId.value === '' ? undefined : selectedDeviceTypeId.value,
deviceBrand: deviceBrand || undefined,
sn: sn || undefined,
- outgoingTime: outgoingTimeFilter.value || undefined,
+ 'outgoingTime[0]': outgoingTimeRange[0] || undefined,
+ 'outgoingTime[1]': outgoingTimeRange[1] || undefined,
};
const res = await getDeviceLedgerPage(params);
const page = normalizePageData(res);
@@ -509,38 +464,26 @@ function onStatusFilterChange(e) {
fetchList(true);
}
-function onDrawerStatusFilterChange(e) {
- const idx = Number(e?.detail?.value || 0);
- selectedStatus.value = statusOptions.value[idx]?.value ?? '';
-}
function openFilterDrawer() {
filterPopupRef.value?.open();
}
+
function closeFilterDrawer() {
filterPopupRef.value?.close();
}
async function confirmFilterDrawer() {
drawerDeviceTypePanelOpen.value = false;
- drawerLinePanelOpen.value = false;
closeFilterDrawer();
await fetchList(true);
}
-async function refreshList() {
- await fetchList(true);
-}
function toggleDrawerDeviceTypePanel() {
drawerDeviceTypePanelOpen.value = !drawerDeviceTypePanelOpen.value;
- if (drawerDeviceTypePanelOpen.value) drawerLinePanelOpen.value = false;
}
-function toggleDrawerLinePanel() {
- drawerLinePanelOpen.value = !drawerLinePanelOpen.value;
- if (drawerLinePanelOpen.value) drawerDeviceTypePanelOpen.value = false;
-}
function selectDrawerDeviceType(option) {
selectedDeviceTypeId.value = option?.id === '' ? '' : String(option?.id ?? '');
@@ -550,13 +493,6 @@ function selectDrawerDeviceType(option) {
drawerDeviceTypePanelOpen.value = false;
}
-function selectDrawerLine(option) {
- selectedLineId.value = option?.id === '' ? '' : String(option?.id ?? '');
- lineCascaderValue.value = selectedLineId.value
- ? findLinePath(lineTree.value, selectedLineId.value)
- : [];
- drawerLinePanelOpen.value = false;
-}
function openDeviceTypeCascader() {
deviceTypeCascaderShow.value = true;
}
@@ -585,16 +521,13 @@ function onLineCascaderConfirm(values) {
}
async function resetFilters() {
searchKeyword.value = '';
- deviceCodeFilter.value = '';
- deviceNameFilter.value = '';
deviceBrandFilter.value = '';
snFilter.value = '';
- outgoingTimeFilter.value = '';
+ outgoingTimeFilter.value = [];
selectedStatus.value = '';
selectedLineId.value = '';
selectedDeviceTypeId.value = '';
drawerDeviceTypePanelOpen.value = false;
- drawerLinePanelOpen.value = false;
lineCascaderValue.value = [];
deviceTypeCascaderValue.value = [];
lineCascaderShow.value = false;
@@ -852,6 +785,10 @@ function formatDateValue(value) {
border-radius: 28rpx 0 0 28rpx;
}
+:deep(.equipment-filter-popup.right .uni-popup__content-transition) {
+ transform: none !important;
+}
+
.drawer-header {
height: 104rpx;
padding: 18rpx 34rpx 0;
@@ -1017,17 +954,31 @@ function formatDateValue(value) {
color: #1f2937;
}
-.drawer-date :deep(.uni-date) {
+.drawer-date :deep(.uni-date),
+.drawer-date :deep(.uni-date-editor),
+.drawer-date :deep(.uni-date-editor--x),
+.drawer-date :deep(.uni-date-x) {
width: 100%;
}
+.drawer-date :deep(.uni-date-editor),
+.drawer-date :deep(.uni-date-editor--x),
.drawer-date :deep(.uni-date-x) {
min-height: 74rpx;
+}
+
+.drawer-date :deep(.uni-date-editor--x),
+.drawer-date :deep(.uni-date-x) {
border: 0;
padding: 0;
background: transparent;
}
+.drawer-date :deep(.uni-date-range) {
+ display: flex;
+ align-items: center;
+}
+
.drawer-date :deep(.uni-date__x-input) {
text-align: center;
font-size: 26rpx;
diff --git a/src/uni_modules/uni-popup/components/uni-popup/uni-popup.vue b/src/uni_modules/uni-popup/components/uni-popup/uni-popup.vue
index db90c59..d377a77 100644
--- a/src/uni_modules/uni-popup/components/uni-popup/uni-popup.vue
+++ b/src/uni_modules/uni-popup/components/uni-popup/uni-popup.vue
@@ -3,7 +3,7 @@
-