Explorar el Código

feature<工單>:支持产品线和时间的条件筛选

zhaosl hace 2 años
padre
commit
2a79e06b4b
Se han modificado 1 ficheros con 26 adiciones y 2 borrados
  1. 26 2
      src/views/work/order/index.vue

+ 26 - 2
src/views/work/order/index.vue

@@ -19,10 +19,26 @@
               <el-option v-for="item in orderStatusOptions" :key="item.key" :label="item.value" :value="item.key" />
             </el-select>
           </el-form-item>
+          <el-form-item prop="productLine">
+            <el-select
+              v-model="queryForm.productLine"
+              clearable
+              placeholder="请选择产品线"
+              style="width: 100%"
+              @change="changeProductLine">
+              <el-option v-for="item in productLineOptions" :key="item.key" :label="item.value" :value="item.key" />
+            </el-select>
+          </el-form-item>
           <el-form-item prop="assignUserName">
             <el-input v-model="queryForm.assignUserName" placeholder="支持人员姓名" @keyup.enter.native="fetchData" />
           </el-form-item>
-
+          <el-form-item prop="supportTime">
+            <el-date-picker
+              v-model="queryForm.supportTime"
+              placeholder="选择日期"
+              type="date"
+              value-format="yyyy-MM-dd" />
+          </el-form-item>
           <el-form-item>
             <el-button icon="el-icon-search" type="primary" @click="fetchData">查询</el-button>
             <el-button icon="el-icon-refresh-right" @click="reset">重置</el-button>
@@ -117,6 +133,8 @@
           orderTypeName: '',
           orderStatus: '',
           assignUserName: '',
+          supportTime: '',
+          productLine: '',
           pageNum: 1,
           pageSize: 10,
         },
@@ -125,6 +143,7 @@
         list: [],
         selectRows: [],
         showColumns: [],
+        productLineOptions: [],
         columns: [
           {
             label: '工单编号',
@@ -180,7 +199,6 @@
           },
         ],
         orderStatusOptions: [],
-        productLineOptions: [],
       }
     },
     watch: {
@@ -197,11 +215,13 @@
     },
 
     methods: {
+      changeProductLine() {},
       getOptions() {
         Promise.all([this.getDicts('work_order_status'), this.getDicts('sys_product_line')])
           .then(([workOrderStatus, productLine]) => {
             this.orderStatusOptions = workOrderStatus.data.values || []
             this.productLineOptions = productLine.data.values || []
+            console.log(' this.productLineOptions is', this.productLineOptions)
           })
           .catch((err) => console.log(err))
       },
@@ -290,6 +310,10 @@
           orderTypeName: '',
           orderStatus: '',
           assignUserName: '',
+          supportTime: '',
+          productLine: '',
+          nboName: '',
+          custName: '',
         }
         this.fetchData()
       },