Explorar o código

feat(forecast): 设置默认年份和月份搜索值并禁用客户名称搜索

yz hai 2 semanas
pai
achega
1b713717f5
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      src/views/forecast/forecastIndex.js

+ 3 - 1
src/views/forecast/forecastIndex.js

@@ -117,12 +117,14 @@ export default {
             valueFormat: 'yyyy', // 添加这行,确保提交的数据是YYYY格式
             search: true,
             searchSpan: 6,
+            searchValue: String(((new Date().getMonth() + 1) === 12) ? (new Date().getFullYear() + 1) : new Date().getFullYear()),
             width: 100
           },
           {
             label: '月份',
             prop: 'month',
             type: 'select',
+            searchValue: ((new Date().getMonth() + 1) === 12) ? 1 : (new Date().getMonth() + 2),
             dicData: [
               { label: '1月', value: 1 },
               { label: '2月', value: 2 },
@@ -151,7 +153,7 @@ export default {
           {
             label: '客户名称',
             prop: 'customerName',
-            search: true,
+            search: false,
             searchSpan: 6,
             width: 180,
             overHidden: true