Преглед на файлове

fix(record-filling): 默认查询包含当天的近7天记录

Zimo преди 5 дни
родител
ревизия
a09ceb49ef
променени са 1 файла, в които са добавени 5 реда и са изтрити 5 реда
  1. 5 5
      pages/recordFilling/list.vue

+ 5 - 5
pages/recordFilling/list.vue

@@ -206,11 +206,11 @@ getStrDictOptions("operation_fill_order_status").map((item) => {
 console.log("🚀 ~ getDataDictList ~ fillStatusDict:", fillStatusDict);
 
 const orderName = ref("");
-const getCurrentMonthRange = () => [
-  dayjs().startOf("week").format("YYYY-MM-DD HH:mm:ss"),
-  dayjs().endOf("week").format("YYYY-MM-DD HH:mm:ss"),
+const getRecentWeekRange = () => [
+  dayjs().subtract(6, "day").startOf("day").format("YYYY-MM-DD HH:mm:ss"),
+  dayjs().endOf("day").format("YYYY-MM-DD HH:mm:ss"),
 ];
-const createTime = ref(getCurrentMonthRange());
+const createTime = ref(getRecentWeekRange());
 const filterPopup = ref(null);
 const fabPattern = reactive({
   color: "#fff",
@@ -262,7 +262,7 @@ const closeFilterPopup = () => {
 };
 const resetFilter = () => {
   orderName.value = "";
-  createTime.value = getCurrentMonthRange();
+  createTime.value = getRecentWeekRange();
 };
 const navigatorDetail = (item, type) => {
   console.log("item", item);