From 99494d05f34ad75fc82fd9a5355dbe6118a1639c Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期三, 18 十月 2023 11:12:29 +0800
Subject: [PATCH] 	modified:   src/const/crud/customerOrder/customerOrderForm.js 	modified:   src/util/date.js 	modified:   src/views/plan/customerorder/customerorder-form.vue 	modified:   src/views/plan/customerorder/index.vue 	modified:   src/views/plan/customerorder/sample-customerorder-form.vue

---
 src/views/plan/customerorder/index.vue |   54 +++++++++++++++++++++++++++++++++++++++++++++---------
 1 files changed, 45 insertions(+), 9 deletions(-)

diff --git a/src/views/plan/customerorder/index.vue b/src/views/plan/customerorder/index.vue
index c2a7289..cc8afa1 100644
--- a/src/views/plan/customerorder/index.vue
+++ b/src/views/plan/customerorder/index.vue
@@ -80,7 +80,7 @@
           <el-button
             style="margin-left:10px;"
             type="primary"
-            @click="exportStandBook"
+            @click="()=>exportDialogVisible=true"
             >瀵煎嚭鍙拌处</el-button
           >
           <el-button
@@ -189,6 +189,26 @@
         </span>
         <span slot="footer" class="dialog-footer"> </span>
       </el-dialog>
+      <!-- 瀵煎嚭 -->
+      <el-dialog title="瀵煎嚭" :visible.sync="exportDialogVisible" width="30%">
+        <div style="display: flex;justify-content: center">
+          <el-form :model="dataForm" :inline="true" :rules="dataRule" ref="exportForm" class="l-mes">
+            <el-form-item label="鏃ユ湡" prop="exportTime">
+              <el-date-picker
+                v-model="dataForm.exportTime"
+                type="datetime"
+                style="width:100%"
+                placeholder="閫夋嫨鏃ユ湡鏃堕棿"
+                value-format="yyyy-MM-dd HH:mm:ss">
+              </el-date-picker>
+            </el-form-item>
+          </el-form>
+      </div>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="exportDialogVisible=false">鍙� 娑�</el-button>
+        <el-button type="primary" @click="exportStandBook">纭� 瀹�</el-button>
+      </span>
+    </el-dialog>
       <!-- 绠辩爜淇℃伅瀵煎嚭 -->
       <el-dialog
         title="绠辩爜淇℃伅瀵煎嚭"
@@ -302,9 +322,12 @@
   data() {
     return {
       dataForm: {
-        selectTime: null
+        selectTime: null,
+        exportTime: null
       },
-      dataRule: {},
+      dataRule: {
+        exportTime:[{required:true,message:'瀵煎嚭鏃ユ湡涓嶈兘涓虹┖',trigger:'change'}]
+      },
       pickerOptions: {
         onPick: ({ maxDate, minDate }) => {
           if (minDate && this.pickerMinDate) {
@@ -323,6 +346,7 @@
           return false
         }
       },
+      exportDialogVisible: false,
       syncDateVisible: false,
       syncDate: [],
       showCustomerorderReturn: false,
@@ -551,7 +575,7 @@
             minWidth: '120',
             width: '100px',
             prop: 'productType',
-            label: '浜у搧绫诲瀷',
+            label: '闅跺睘鍝佺墝',
             isTrue: true,
             isSearch: true,
             searchInfoType: 'text'
@@ -811,6 +835,11 @@
     ...mapGetters(['permissions'])
   },
   watch: {
+    exportDialogVisible(newVal){
+      if(!newVal){
+        this.$refs['exportForm'].resetFields()
+      }
+    },
     coState: {
       handler(newValue, oldValue) {
         if (newValue) {
@@ -1574,11 +1603,18 @@
       // } else {
       //   this.$message.error('璇烽�夋嫨鑷冲皯涓�鏉¢攢鍞鍗�')
       // }
-      exportCustomerOrder(this.$refs.customerOrderTable.getQueryParam())
-        .then((response) => {
-          transform(response)
-        })
-        .catch(() => {})
+      this.$refs['exportForm'].validate(valid => {
+        if(valid){
+          const exportTime = this.dataForm.exportTime
+          let queryParam=this.$refs.customerOrderTable.getQueryParam();
+          queryParam.selectTime = exportTime
+          exportCustomerOrder(queryParam)
+            .then((response) => {
+              transform(response)
+            })
+            .catch(() => {})
+        }
+      })
     },
     setSalesPart() {
       if (this.multipleSelection.length > 0) {

--
Gitblit v1.9.3