Jelajahi Sumber

Merge remote-tracking branch 'origin/master'

yfh 2 minggu lalu
induk
melakukan
57be25a073

+ 10 - 0
src/api/course/userCourse.js

@@ -35,6 +35,16 @@ export function updateUserCourse(data) {
   })
 }
 
+//统一修改课程红包
+export function updateUserCourseRedPage(data) {
+  return request({
+    url: '/course/userCourse/editRedPage',
+    method: 'post',
+    data: data
+  })
+}
+
+
 // 删除课程
 export function delUserCourse(courseId) {
   return request({

+ 17 - 0
src/api/course/userCourseVideo.js

@@ -85,6 +85,14 @@ export function exportUserCourseVideo(query) {
 }
 
 
+export function getVideoListByCourseIdAll(courseId) {
+  return request({
+    url: '/course/userCourseVideo/getVideoListByCourseIdAll',
+    method: 'get',
+    params: {courseId}
+  })
+}
+
 export function getVideoListByCourseId(query) {
   return request({
     url: '/course/userCourseVideo/getVideoListByCourseId',
@@ -93,6 +101,15 @@ export function getVideoListByCourseId(query) {
   })
 }
 
+export function sortCourseVideo(list) {
+  return request({
+    url: '/course/userCourseVideo/sortCourseVideo',
+    method: 'post',
+    data: list
+  })
+}
+
+
 // 获取选项列表
 export function getVideoListLikeName(query) {
   return request({

+ 3 - 0
src/views/chat/chatSession/index.vue

@@ -327,6 +327,9 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
+      this.dateRange = [];
+      this.queryParams.beginTime=null;
+      this.queryParams.endTime=null;
       this.resetForm("queryForm");
       this.handleQuery();
     },

+ 2 - 3
src/views/company/companyMoneyLogs/index.vue

@@ -302,14 +302,13 @@ export default {
     /** 搜索按钮操作 */
     handleQuery() {
       this.queryParams.pageNum = 1;
-
       this.getList();
     },
     /** 重置按钮操作 */
     resetQuery() {
-
-      this.resetForm("queryForm");
+      this.createTimeRange=[]
       this.dateRange=[];
+      this.resetForm("queryForm");
       this.queryParams.beginTime=null;
       this.queryParams.endTime=null;
       this.handleQuery();

+ 1 - 1
src/views/company/companyRecharge/index.vue

@@ -246,8 +246,8 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
-      this.resetForm("queryForm");
       this.dateRange=[];
+      this.resetForm("queryForm");
       this.handleQuery();
     },
     // 多选框选中数据

+ 77 - 3
src/views/components/course/userCourseCatalogDetails.vue

@@ -34,6 +34,10 @@
         <el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
                    v-hasPermi="['course:userCourseVideo:remove']">删除</el-button>
       </el-col>
+      <el-col :span="1.5">
+        <el-button type="warning" plain icon="el-icon-edit" size="mini" @click="handleCourseSort"
+                   v-hasPermi="['course:userCourseVideo:sort']">修改课节排序</el-button>
+      </el-col>
       <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
     </el-row>
     <el-table border v-loading="loading" :data="userCourseVideoList" @selection-change="handleSelectionChange">
@@ -316,6 +320,19 @@
       </course-watch-comment>
     </el-dialog>
 
+
+    <el-dialog title="修改课节排序" :visible.sync="openVideoSort" style="width: 1600px;" append-to-body>
+      <draggable v-model="userCourseVideoSortList" @end="onDragEndDay" style="padding: 10px">
+        <el-button style="margin: 8px 4px;" v-for="(item, index) in userCourseVideoSortList" :class="item.newCourseSort != item.courseSort ? 'red':''">第{{
+            item.newCourseSort
+          }}序(原排序第{{ item.courseSort }})
+        </el-button>
+      </draggable>
+      <div style="float: right;margin-top: -20px">
+        <el-button type="primary" @click="saveSorts">保存</el-button>
+      </div>
+    </el-dialog>
+
   </div>
 </template>
 
@@ -329,8 +346,8 @@ import {
   updates,
   batchSaveVideo,
   batchUpdateRed,
-  updateUserCourseVideo
-} from "@/api/course/userCourseVideo";
+  updateUserCourseVideo, getVideoListByCourseIdAll, sortCourseVideo
+} from '@/api/course/userCourseVideo'
 import QuestionBank from "@/views/course/courseQuestionBank/QuestionBank.vue";
 import CourseProduct from "@/views/course/fsCourseProduct/CourseProduct.vue";
 import VideoUpload from "@/components/VideoUpload/index.vue";
@@ -338,10 +355,11 @@ import { listVideoResource } from '@/api/course/videoResource';
 import { getByIds } from '@/api/course/courseQuestionBank'
 import CourseWatchComment from "./courseWatchComment.vue";
 import { getCateListByPid, getCatePidList } from '@/api/course/userCourseCategory'
+import draggable from 'vuedraggable'
 
 export default {
   name: "userCourseCatalog",
-  components: { VideoUpload, QuestionBank, CourseWatchComment, CourseProduct,},
+  components: { VideoUpload, QuestionBank, CourseWatchComment, CourseProduct,draggable},
   data() {
     return {
       duration: null,
@@ -387,6 +405,7 @@ export default {
       fileId: '',
       courseName: null,
       userCourseVideoList: [],
+      userCourseVideoSortList: [],
       total: 0,
       redData: {
         queryParams: {
@@ -434,6 +453,8 @@ export default {
       single: true,
       // 非多个禁用
       multiple: true,
+      loading3:false,
+      openVideoSort:false,
       // 表单参数
       form: {
         courseProducts:[]
@@ -502,6 +523,7 @@ export default {
       this.courseProduct.title = '拍商品选择';
     },
 
+
     //选择疗法
     selectPackage(row) {
       const drug = {};
@@ -857,6 +879,47 @@ export default {
         this.msgSuccess("删除成功");
       }).catch(() => { });
     },
+
+    handleCourseSort(){
+
+      getVideoListByCourseIdAll(this.queryParams.courseId).then(response => {
+
+        response.rows.forEach((item) => item.newCourseSort = item.courseSort);
+        this.userCourseVideoSortList = response.rows.sort((a, b) => a.courseSort - b.courseSort);
+        if (this.userCourseVideoSortList==null || this.userCourseVideoSortList.length==0){
+          this.$message.error("暂无课节天数")
+        }else {
+          this.openVideoSort = true;
+        }
+      })
+
+
+    },
+
+    onDragEndDay() {
+      this.userCourseVideoSortList.forEach((item, index) => {
+        item.newCourseSort = index + 1;
+      })
+      this.$forceUpdate()
+    },
+
+    saveSorts() {
+
+      console.log("this.userCourseVideoSortList",this.userCourseVideoSortList)
+      let list = this.userCourseVideoSortList.filter(e => e.courseSort != e.newCourseSort).map(e => {
+        return {courseSort: e.newCourseSort, videoId: e.videoId}
+      })
+      console.log("this.userCourseVideoSortList",this.userCourseVideoSortList)
+      this.loading3 = true;
+      console.log("list",list)
+      sortCourseVideo(list).then(e => {
+        this.getList();
+      }).finally(() => {
+        this.userCourseVideoSortList=[];
+        this.openVideoSort=false;
+      })
+    },
+
     openAdds() {
       this.addBatchData.open = true;
       this.getRootTypeList();
@@ -948,4 +1011,15 @@ export default {
   line-height: 150px;
   text-align: center;
 }
+
+
+.red:hover {
+  color: #dbdbdb !important;
+}
+
+.red {
+  background-color: #F56C6C !important;
+  color: #fff !important;
+}
+
 </style>

+ 60 - 28
src/views/components/his/integralOrderDetails.vue

@@ -19,7 +19,8 @@
                 <el-tag prop="status" v-for="(ite, index) in statusOptions"    v-if="item.status==ite.dictValue">{{ite.dictLabel}}</el-tag>
              </span>
              <div class="operate-button-container"  v-if="item.status==1" v-hasPermi="['his:integralOrder:sendGoods']">
-                <el-button size="mini" @click="sendVisible=true" >发货</el-button>
+                <!-- <el-button size="mini" @click="sendVisible=true" >发货</el-button> -->
+                <el-button size="mini" @click="showSend()" >发货</el-button>
              </div>
             <div class="operate-button-container"   v-if="item.deliverySn!=null" v-hasPermi="['his:integralOrder:express']">
               <el-button size="mini" @click="showExpress()" >查看物流</el-button>
@@ -90,16 +91,25 @@
            title="发货"
            :visible.sync="sendVisible"
            append-to-body @close="sendCancel">
-      <el-form ref="form" :model="form" :rules="rules" label-width="120px">
+        <el-form ref="form" :model="form" :rules="rules" label-width="120px">
+          <el-form-item label="快递名称" prop="deliveryName">
+            <el-select v-model="selectedExpress" placeholder="请选择快递名称" value-key="name">
+              <el-option
+                v-for="item in expressOption"
+                :key="item.name"
+                :label="item.name"
+                :value="item">
+              </el-option>
+            </el-select>
+          </el-form-item>
           <el-form-item label="快递公司编号" prop="deliveryCode">
-                    <el-input v-model="form.deliveryCode" placeholder="请输入快递公司编号" />
-                  </el-form-item>
-                  <el-form-item label="快递名称" prop="deliveryName">
-                    <el-input v-model="form.deliveryName" placeholder="请输入快递名称" />
-                  </el-form-item>
-                  <el-form-item label="快递单号" prop="deliverySn">
-                    <el-input v-model="form.deliverySn" placeholder="请输入快递单号" />
-                  </el-form-item>
+            <el-input v-model="form.deliveryCode" placeholder="请输入快递公司编号" disabled />
+            
+          </el-form-item>
+          
+          <el-form-item label="快递单号" prop="deliverySn">
+            <el-input v-model="form.deliverySn" placeholder="请输入快递单号" />
+          </el-form-item>
         </el-form>
         <div slot="footer" class="dialog-footer">
                           <el-button type="primary" @click="sendGoods">确 定</el-button>
@@ -158,10 +168,13 @@
 
 <script>
 import {getExpress, listIntegralOrder, sendgoods,getIntegralOrder, delIntegralOrder, addIntegralOrder, updateIntegralOrder, exportIntegralOrder,getOrderUserPhone } from "@/api/his/integralOrder";
+import {getExpressList } from "@/api/his/express";
   export default {
     name: "integralOrder",
     data() {
       return {
+        selectedExpress:null,
+        expressOption:[],
         expressDialog:{
           title:"物流信息",
           open:false,
@@ -205,6 +218,17 @@ import {getExpress, listIntegralOrder, sendgoods,getIntegralOrder, delIntegralOr
         this.statusOptions = response.data;
       });
     },
+    watch: {
+      selectedExpress(newVal) {
+        if (newVal) {
+          this.form.deliveryName = newVal.name;
+          this.form.deliveryCode = newVal.code;
+        } else {
+          this.form.deliveryName = '';
+          this.form.deliveryCode = '';
+        }
+      }
+    },
     methods: {
       handlePhone(){
         const orderId = this.item.orderId;
@@ -242,6 +266,14 @@ import {getExpress, listIntegralOrder, sendgoods,getIntegralOrder, delIntegralOr
              orderId:null,
            }
       },
+      showSend(){
+        //获取快递公司信息
+        getExpressList().then(response=>{
+          this.expressOption = response.data;
+        })
+        console.log(this.expressOption)
+        this.sendVisible = true
+      },
       showExpress(){
         this.expressDialog.open=true;
         getExpress(this.item.orderId).then(response => {
@@ -251,29 +283,29 @@ import {getExpress, listIntegralOrder, sendgoods,getIntegralOrder, delIntegralOr
             }
         });
       },
-          sendGoods(){
-              this.form.orderId=this.item.orderId;
-              sendgoods(this.form).then(response => {
-                    this.msgSuccess("修改成功");
-                    this.sendVisible = false;
-                    getIntegralOrder(this.item.orderId).then(response => {
-                        this.item = response.data;
-                        this.$parent.$parent.getList();
-                    });
-
-                    this.form={
-                    deliveryCode: null,
-                    deliveryName:null,
-                    deliverySn:null,
-                    orderId:null,
-                  }
+    sendGoods(){
+        this.form.orderId=this.item.orderId;
+        sendgoods(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.sendVisible = false;
+              getIntegralOrder(this.item.orderId).then(response => {
+                  this.item = response.data;
+                  this.$parent.$parent.getList();
               });
-            },
+
+              this.form={
+              deliveryCode: null,
+              deliveryName:null,
+              deliverySn:null,
+              orderId:null,
+            }
+        });
+      },
       getDetails(orderId) {
         this.item=null;
         getIntegralOrder(orderId).then(response => {
             this.item = response.data;
-            this.prod=[JSON.parse(this.item.itemJson)];
+            this.prod=[JSON.parse(this.item.itemJson)][0];
         });
       },
     }

+ 5 - 2
src/views/course/courseWatchLog/qw/statistics.vue

@@ -60,8 +60,11 @@
       <el-table-column label="看课中" align="center" prop="type1" />
       <el-table-column label="已完课" align="center" prop="type2" />
       <el-table-column label="看课中断" align="center" prop="type4" />
-
-
+      <el-table-column label="注册用户待看课数" align="center" prop="isUserWaitNumber" />
+      <el-table-column label="未注册用户待看课数" align="center" prop="noUserWaitNumber" />
+      <el-table-column label="上线率" align="center" prop="onLineRate" />
+      <el-table-column label="完课率" align="center" prop="finishedRate" />
+      <el-table-column label="消耗红包金额" align="center" prop="redAmount" />
     </el-table>
 
     <pagination

+ 79 - 10
src/views/course/userCourse/index.vue

@@ -108,11 +108,11 @@
       <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
     </el-row>
 
-    <el-table height="600" border v-loading="loading" :data="userCourseList" @selection-change="handleSelectionChange">
+    <el-table height="600" border v-loading="loading" :data="userCourseList" @selection-change="handleSelectionChange" style="width: 100%" :fit="true">
       <el-table-column type="selection" width="55" align="center"/>
-      <el-table-column label="课程ID" align="center" prop="courseId"/>
-      <el-table-column label="所属项目" align="center" prop="projectName"/>
-      <el-table-column label="封面图片" align="center" prop="imgUrl" width="120">
+      <el-table-column label="课程ID" align="center" prop="courseId" width="55"/>
+      <el-table-column label="所属项目" align="center" prop="projectName" width="120"/>
+      <el-table-column label="封面图片" align="center" prop="imgUrl" width="170">
         <template slot-scope="scope">
           <el-popover
             placement="right"
@@ -124,10 +124,10 @@
           </el-popover>
         </template>
       </el-table-column>
-      <el-table-column label="课堂名称" align="center" show-overflow-tooltip prop="courseName"/>
-      <el-table-column label="排序" align="center" prop="sort"/>
-      <el-table-column label="分类名称" align="center" prop="cateName"/>
-      <el-table-column label="子分类名称" align="center" prop="subCateName"/>
+      <el-table-column label="课堂名称" align="center" show-overflow-tooltip prop="courseName" min-width="100"/>
+      <el-table-column label="排序" align="center" prop="sort" width="80"/>
+      <el-table-column label="分类名称" align="center" prop="cateName" width="120"/>
+      <el-table-column label="子分类名称" align="center" prop="subCateName" width="120"/>
       <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
         <template slot-scope="scope">
           <el-button
@@ -145,6 +145,14 @@
             v-hasPermi="['course:userCourse:edit']"
           >修改
           </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdateRedPage(scope.row)"
+            v-hasPermi="['course:userCourse:editRedPage']"
+          >统一修改红包金额
+          </el-button>
           <el-button
             size="mini"
             type="text"
@@ -253,6 +261,20 @@
         <el-button @click="cancel">取 消</el-button>
       </div>
     </el-dialog>
+
+
+    <el-dialog title="修改课程红包金额" :visible.sync="openRedPage.open" width="1000px" append-to-body>
+      <el-form ref="openRedPage" :model="openRedPage" :rules="rulesRedPage" label-width="110px">
+        <el-form-item label="红包金额" prop="redPacketMoney">
+          <el-input-number v-model="openRedPage.redPacketMoney" :min="0.1" :max="200" :step="0.1"></el-input-number>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFormRedPage">确 定</el-button>
+        <el-button @click="cancelRedPage">取 消</el-button>
+      </div>
+    </el-dialog>
+
     <el-drawer
       :with-header="false"
       size="75%"
@@ -273,8 +295,8 @@ import {
   updateIsShow,
   copyUserCourse,
   putOn,
-  pullOff
-} from "@/api/course/userCourse";
+  pullOff, updateUserCourseRedPage
+} from '@/api/course/userCourse'
 
 import {getSelectableRange} from "@/api/qw/sopTemp";
 import Treeselect from "@riophae/vue-treeselect";
@@ -285,10 +307,12 @@ import {listBySearch} from "@/api/course/userTalent";
 import userCourseCatalogDetails from '../../components/course/userCourseCatalogDetails.vue';
 import {getAllCourseCategoryList, getCatePidList, getCateListByPid} from "@/api/course/userCourseCategory";
 import {allList} from "@/api/company/company";
+import VideoUpload from '@/components/VideoUpload/index.vue'
 
 export default {
   name: "UserCourse",
   components: {
+    VideoUpload,
     Treeselect,
     Editor, ImageUpload, userCourseCatalogDetails
   },
@@ -337,6 +361,12 @@ export default {
       title: "",
       // 是否显示弹出层
       open: false,
+      openRedPage:{
+        open:false,
+        courseId:null,
+        courseName:null,
+        redPacketMoney:0.1,
+      },
       // 查询参数
       queryParams: {
         pageNum: 1,
@@ -409,6 +439,12 @@ export default {
         integral: [
           {required: true, message: "小节兑换积分不能为空", trigger: "blur"}
         ],
+      },
+
+      rulesRedPage:{
+        redPacketMoney: [
+          {required: true, message: "红包金额不能为空", trigger: "blur"}
+        ],
       }
     };
   },
@@ -630,6 +666,13 @@ export default {
         this.title = "修改课程";
       });
     },
+
+    handleUpdateRedPage(row){
+      this.openRedPage.open=true;
+      this.openRedPage.courseId=row.courseId;
+      this.openRedPage.courseName=row.courseName;
+
+    },
     /** 提交按钮 */
     submitForm() {
       this.$refs["form"].validate(valid => {
@@ -654,6 +697,32 @@ export default {
         }
       });
     },
+
+    submitFormRedPage(){
+
+      const courseId = this.openRedPage.courseId;
+      const redPacketMoney = this.openRedPage.redPacketMoney;
+      this.$confirm('是否确认将课程id 为"' + courseId + '"的红包批量修改为:【'+redPacketMoney+'】?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+
+        return updateUserCourseRedPage({courseId:courseId,redPacketMoney:redPacketMoney});
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("修改成功");
+        this.openRedPage.open=false;
+      }).finally(() => {
+        this.getList();
+        this.openRedPage.open=false;
+      });
+
+    },
+    cancelRedPage(){
+      this.openRedPage.open=false;
+    },
+
     /** 复制按钮操作 */
     handleCopy(row) {
       const courseId = row.courseId;

+ 10 - 10
src/views/course/userCourse/public.vue

@@ -130,9 +130,9 @@
     </el-tabs>
     <el-table height="600" border v-loading="loading" :data="userCourseList" @selection-change="handleSelectionChange">
       <el-table-column type="selection" width="55" align="center"/>
-      <el-table-column label="课程ID" align="center" prop="courseId"/>
-      <el-table-column label="所属项目" align="center" prop="projectName"/>
-      <el-table-column label="封面图片" align="center" prop="imgUrl" width="120">
+      <el-table-column label="课程ID" align="center" prop="courseId" width="60"/>
+      <el-table-column label="所属项目" align="center" prop="projectName" width="120"/>
+      <el-table-column label="封面图片" align="center" prop="imgUrl" width="170">
         <template slot-scope="scope">
           <el-popover
             placement="right"
@@ -156,13 +156,13 @@
           </el-popover>
         </template>
       </el-table-column>
-      <el-table-column label="课堂名称" align="center" show-overflow-tooltip prop="courseName"/>
-      <el-table-column label="排序" align="center" prop="sort"/>
-      <el-table-column label="分类名称" align="center" prop="cateName"/>
-      <el-table-column label="子分类名称" align="center" prop="subCateName"/>
-      <el-table-column label="原价" align="center" prop="price"/>
-      <el-table-column label="售价" align="center" prop="sellPrice"/>
-      <el-table-column label="单节积分" align="center" prop="integral"/>
+      <el-table-column label="课堂名称" align="center" show-overflow-tooltip prop="courseName" min-width="90"/>
+      <el-table-column label="排序" align="center" prop="sort" width="70"/>
+      <el-table-column label="分类名称" align="center" prop="cateName" width="115"/>
+      <el-table-column label="子分类名称" align="center" prop="subCateName" width="115"/>
+      <el-table-column label="原价" align="center" prop="price" width="115"/>
+      <el-table-column label="售价" align="center" prop="sellPrice" width="115"/>
+      <el-table-column label="单节积分" align="center" prop="integral" width="115"/>
       <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
         <template slot-scope="scope">
           <el-button

+ 2 - 0
src/views/course/userCourseComplaintRecord/index.vue

@@ -328,6 +328,8 @@ export default {
     resetQuery() {
       this.resetForm("queryForm");
       this.dateRange = [];
+      this.queryParams.startCreateTime = null;
+      this.queryParams.endCreateTime = null;
       this.handleQuery();
     },
     // 多选框选中数据

+ 3 - 0
src/views/his/aiDoctorChatSession/index.vue

@@ -275,6 +275,9 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
+      this.dateRange = [];
+      this.queryParams.beginTime=null;
+      this.queryParams.endTime=null;
       this.resetForm("queryForm");
       this.handleQuery();
     },

+ 4 - 6
src/views/his/article/index.vue

@@ -106,16 +106,14 @@
       <el-table-column type="selection" width="55" align="center" />
       <el-table-column label="封面图片" align="center" prop="imageUrl" width="120px">
            <template slot-scope="scope">
-                  <el-popover
-                    placement="right"
-                    title=""
-                    trigger="hover">
+                  <el-popover placement="right" title="" trigger="hover">
+                    <!--配置默认图片效果好些-->
                     <img slot="reference" :src="scope.row.imageUrl" width="100px">
                     <img :src="scope.row.imageUrl" style="max-width: 150px;">
                   </el-popover>
                 </template>
       </el-table-column>
-      <el-table-column label="标题" align="center" prop="title" show-overflow-tooltip width="170px" />
+      <el-table-column label="标题2" align="center" prop="title" show-overflow-tooltip width="170px" />
       <el-table-column label="分类名称" align="center" prop="cateName" width="120px" />
       <el-table-column label="浏览数" align="center" prop="views" />
       <el-table-column label="排序" align="center" prop="sort" />
@@ -133,7 +131,7 @@
       <el-table-column label="创建时间" align="center" prop="createTime" width="180" />
       <el-table-column label="更新时间" align="center" prop="updateTime" width="180" />
 
-      <el-table-column label="操作" align="center" class-name="small-padding fixed-width" fixed="right" width="150px">
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
         <template slot-scope="scope">
           <el-button
             size="mini"

+ 1 - 1
src/views/his/company/index.vue

@@ -501,7 +501,7 @@
           <el-radio v-model="revenueForm.delayAcctFlag" label="N">实时分账</el-radio>
           <el-radio v-model="revenueForm.delayAcctFlag" label="Y">延时分账</el-radio>
         </el-form-item>
-        <el-form-item label="是否使用百分比分账">
+        <el-form-item label="是否使用百分比分账" v-if="revenueForm.divFlag == 1">
           <el-switch
             v-model="revenueForm.percentageFlag"
             active-color="#13ce66"

+ 7 - 10
src/views/his/hospital/index.vue

@@ -152,15 +152,12 @@
 
       <el-table-column label="医院照片" align="center" >
         <template slot-scope="scope">
-                <el-popover
-                  placement="right"
-                  title=""
-                  trigger="hover">
-                  <img slot="reference" :src="scope.row.imgUrl" width="60px">
-                  <img :src="scope.row.imgUrl" style="max-width: 250px;">
-                </el-popover>
-              </template>
-</el-table-column>
+          <el-popover placement="right" title="" trigger="hover">
+            <img slot="reference" :src="scope.row.imgUrl" width="60px">
+            <img :src="scope.row.imgUrl" style="max-width: 250px;">
+          </el-popover>
+        </template>
+      </el-table-column>
 
       <el-table-column label="省市区" align="center" prop="cityIds" width="150px">
                 <template slot-scope="scope">
@@ -188,7 +185,7 @@
       </el-table-column>
        <el-table-column label="备注" align="center" prop="remark" />
       <el-table-column label="联系电话" align="center" prop="phone"  width="150px"/>
-      <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="150px" fixed="right">
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
         <template slot-scope="scope">
           <el-button
             size="mini"

+ 8 - 15
src/views/his/statistics/appOrderCountStats.vue

@@ -59,20 +59,12 @@
 
       <div class="data-box">
         <div class="table-box">
-          <el-table
-            :data="tableData"
-            border
-            max-height="500"
-            style="width: 100%"
-          >
-            <el-table-column prop="totalOrderCount" label="订单总数" />
-            <el-table-column prop="fullPayOrderCount" label="全款支付订单数" />
-            <el-table-column prop="codOrderCount" label="物流代收支付订单数" />
-            <el-table-column prop="depositCodOrderCount" label="付定金的物流代收订单数" />
-            <el-table-column prop="noDepositCodOrderCount" label="0定金的物流代收订单数" />
-            <el-table-column prop="totalOrderAmount" label="订单总金额" />
-            <el-table-column prop="depositAmount" label="定金总金额" />
-            <el-table-column prop="codAmount" label="物流代收总金额" />
+          <el-table :data="tableData" border max-height="500" style="width: 100%">
+            <el-table-column prop="category" label="订单类型" width="180" />
+            <el-table-column prop="orderCount" label="订单数" />
+            <el-table-column prop="orderAmount" label="订单总金额(元)" />
+            <el-table-column prop="depositAmount" label="定金金额(元)" />
+            <el-table-column prop="codAmount" label="物流代收金额(元)" />
           </el-table>
         </div>
       </div>
@@ -146,7 +138,8 @@ export default {
 
       getAppOrderCount(params).then(response => {
         const vo = response.data;
-        this.tableData = vo ? [vo] : [];
+        // this.tableData = vo ? [vo] : [];
+        this.tableData = response.data || []; // 直接赋值数组
       }).catch(() => {
         this.tableData = [];
       });

+ 7 - 16
src/views/his/statistics/hisOrderCountStats.vue

@@ -59,20 +59,12 @@
 
       <div class="data-box">
         <div class="table-box">
-          <el-table
-            :data="tableData"
-            border
-            max-height="500"
-            style="width: 100%"
-          >
-            <el-table-column prop="totalOrderCount" label="订单总数" />
-            <el-table-column prop="fullPayOrderCount" label="全款支付订单数" />
-            <el-table-column prop="codOrderCount" label="物流代收支付订单数" />
-            <el-table-column prop="depositCodOrderCount" label="付定金的物流代收订单数" />
-            <el-table-column prop="noDepositCodOrderCount" label="0定金的物流代收订单数" />
-            <el-table-column prop="totalOrderAmount" label="订单总金额" />
-            <el-table-column prop="depositAmount" label="定金总金额" />
-            <el-table-column prop="codAmount" label="物流代收总金额" />
+          <el-table :data="tableData" border max-height="500" style="width: 100%">
+            <el-table-column prop="category" label="订单类型" width="180" />
+            <el-table-column prop="orderCount" label="订单数" />
+            <el-table-column prop="orderAmount" label="订单总金额(元)" />
+            <el-table-column prop="depositAmount" label="定金金额(元)" />
+            <el-table-column prop="codAmount" label="物流代收金额(元)" />
           </el-table>
         </div>
       </div>
@@ -141,8 +133,7 @@ export default {
       };
 
       getHisOrderCountStats(params).then(response => {
-        const vo = response.data;
-        this.tableData = vo ? [vo] : [];
+        this.tableData = response.data || []; // 直接赋值数组
       });
     }
   }

+ 10 - 4
src/views/his/storePayment/index.vue

@@ -313,7 +313,7 @@ export default {
     this.getDicts("sys_store_payment_share_status").then(response => {
       this.shareOptions = response.data;
     });
-    
+
     // 获取小程序选项列表
     this.getAppMallOptions();
   },
@@ -373,9 +373,15 @@ export default {
     /** 重置按钮操作 */
     resetQuery() {
       this.resetForm("queryForm");
-       this.createTime=null;
-        this.queryParams.sTime=null;
-        this.queryParams.eTime=null;
+      this.createTime=null;
+      this.queryParams.sTime=null;
+      this.queryParams.eTime=null;
+      this.queryParams.refundBeginTime=null;
+      this.queryParams.refundEndTime=null;
+      this.queryParams.payBeginTime=null;
+      this.queryParams.payEndTime=null;
+      this.refundTime=null
+      this.payTime=null
       this.handleQuery();
     },
     change(){

+ 1 - 0
src/views/hisStore/storeAfterSales/index.vue

@@ -371,6 +371,7 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
+      this.dateRange = [];
       this.resetForm("queryForm");
       this.handleQuery();
     },

+ 1 - 0
src/views/hisStore/storeCoupon/index.vue

@@ -392,6 +392,7 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
+      this.dateRange = [];
       this.resetForm("queryForm");
       this.handleQuery();
     },

+ 105 - 106
src/views/hisStore/storeOrder/healthStoreList.vue

@@ -27,7 +27,7 @@
             >
               {{ code }}
             </el-tag>
-            
+
             <!-- 输入框 -->
             <el-input
               ref="tagInput"
@@ -42,7 +42,7 @@
               @focus="inputVisible = true"
               clearable
             />
-            
+
             <!-- 添加按钮(当没有输入时显示) -->
             <el-button
               v-if="!inputVisible && queryParams.orderCodes.length > 0"
@@ -55,11 +55,11 @@
               添加订单号
             </el-button>
           </div>
-          
+
           <!-- 输入提示 -->
           <div class="input-tips">
             <span class="tip-text">
-              支持:回车、逗号、空格分隔 | 
+              支持:回车、逗号、空格分隔 |
               已添加 {{ queryParams.orderCodes.length }} 个订单号
               <span v-if="maxOrderCodes > 0"> (最多{{ maxOrderCodes }}个)</span>
             </span>
@@ -335,7 +335,7 @@
             plain
             icon="el-icon-phone"
             size="mini"
-            
+
             @click="setErpPhone"
             v-hasPermi="['his:storeOrder:createErpOrder']"
           >设置推送手机</el-button>
@@ -397,8 +397,8 @@
           size="mini"
       >订单量/金额: {{ total }}/{{payPriceTotal }}</el-button>
       </el-col>
-      
-     
+
+
       <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
     </el-row>
     <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
@@ -519,12 +519,12 @@
     <div v-if="currentSort.prop" class="sort-info">
         <el-tag size="small" type="info" closable @close="clearSort">
           <i class="el-icon-sort"></i>
-          当前排序:{{ getSortLabel(currentSort.prop) }} 
+          当前排序:{{ getSortLabel(currentSort.prop) }}
           {{ currentSort.order === 'ascending' ? '升序' : '降序' }}
         </el-tag>
-          <el-button 
-            type="text" 
-            size="mini" 
+          <el-button
+            type="text"
+            size="mini"
             @click="clearSort"
             style="margin-left: 8px; color: #909399;"
           >
@@ -771,9 +771,9 @@
       <el-table :data="phoneList" border style="width: 100%">
         <el-table-column prop="phone" label="手机号" align="center">
           <template slot-scope="scope">
-            <el-input 
-              v-if="scope.row.editing" 
-              v-model="scope.row.phone" 
+            <el-input
+              v-if="scope.row.editing"
+              v-model="scope.row.phone"
               placeholder="请输入手机号"
               @blur="validatePhone(scope.row)"
               @keyup.enter.native="handleSavePhone(scope.$index)"
@@ -783,27 +783,27 @@
         </el-table-column>
         <el-table-column label="操作" align="center" width="300">
           <template slot-scope="scope">
-            <el-button 
-              v-if="scope.row.editing" 
-              type="success" 
-              size="mini" 
+            <el-button
+              v-if="scope.row.editing"
+              type="success"
+              size="mini"
               @click="handleSavePhone(scope.$index)"
             >保存</el-button>
-            <el-button 
-              v-if="scope.row.editing" 
-              type="info" 
-              size="mini" 
+            <el-button
+              v-if="scope.row.editing"
+              type="info"
+              size="mini"
               @click="handleCancelEdit(scope.$index)"
             >取消</el-button>
-            <el-button 
-              v-if="!scope.row.editing" 
-              type="primary" 
-              size="mini" 
+            <el-button
+              v-if="!scope.row.editing"
+              type="primary"
+              size="mini"
               @click="handleEditPhone(scope.$index)"
             >修改</el-button>
-            <el-button 
-              type="danger" 
-              size="mini" 
+            <el-button
+              type="danger"
+              size="mini"
               @click="handleDeletePhone(scope.$index)"
             >删除</el-button>
           </template>
@@ -834,9 +834,9 @@
       <div v-loading="erpAccountDialog.loading">
         <el-form :model="erpAccountForm" label-width="100px">
           <el-form-item label="ERP账户" required>
-            <el-select 
-              v-model="erpAccountForm.selectedAccount" 
-              placeholder="请选择ERP账户" 
+            <el-select
+              v-model="erpAccountForm.selectedAccount"
+              placeholder="请选择ERP账户"
               style="width: 100%"
               filterable
             >
@@ -852,7 +852,7 @@
             </el-select>
           </el-form-item>
         </el-form>
-        
+
         <!-- 订单统计信息 -->
         <div class="order-summary" v-if="orderSummary">
           <el-divider content-position="left">订单统计</el-divider>
@@ -878,11 +878,11 @@
           </el-row>
         </div>
       </div>
-      
+
       <div slot="footer" class="dialog-footer">
         <el-button @click="cancelErpAccountDialog">取 消</el-button>
-        <el-button 
-          type="primary" 
+        <el-button
+          type="primary"
           @click="confirmCreateErpOrder"
           :disabled="!erpAccountForm.selectedAccount"
           :loading="erpAccountDialog.submitting"
@@ -898,12 +898,12 @@
           <el-button type="default" size="small" @click="unselectAllFields">全不选</el-button>
           <el-button type="success" size="small" @click="selectDefaultFields">选择常用</el-button>
         </div>
-        
+
         <div class="field-selection-container">
           <el-row :gutter="20">
             <el-col :span="8" v-for="field in exportFieldOptions" :key="field.key">
-              <el-checkbox 
-                v-model="field.checked" 
+              <el-checkbox
+                v-model="field.checked"
                 :label="field.label"
                 style="margin-bottom: 12px; width: 100%;"
               >
@@ -912,7 +912,7 @@
             </el-col>
           </el-row>
         </div>
-        
+
         <div class="field-count-info" style="margin-top: 20px; padding: 10px; background: #f5f7fa; border-radius: 4px;">
           <i class="el-icon-info"></i>
           <span v-if="getSelectedFieldsCount() > 0">
@@ -924,11 +924,11 @@
           </span>
         </div>
       </div>
-      
+
       <div slot="footer" class="dialog-footer">
         <el-button @click="cancelExportFieldDialog">取 消</el-button>
-        <el-button 
-          type="primary" 
+        <el-button
+          type="primary"
           @click="confirmExportFields"
         >确认导出</el-button>
       </div>
@@ -986,11 +986,11 @@ export default {
         prop: null,
         order: null
       },
-      
+
       // 排序字段映射
       sortFieldMap: {
         'companyUserName': '员工',
-        'packageName': '套餐名称', 
+        'packageName': '套餐名称',
         'payPrice': '应收金额',
         'payMoney': '实收金额',
         'createTime': '下单时间'
@@ -1004,7 +1004,7 @@ export default {
       },
       // 输入框是否可见
       inputVisible: false,
-      
+
       // 无效订单号对话框
       showInvalidDialog: false,
       // 当前输入值
@@ -1265,13 +1265,13 @@ export default {
     // 新增排序处理方法
     handleSortChange({ column, prop, order }) {
       console.log('排序变化:', { column, prop, order });
-      
+
       // 更新当前排序状态
       this.currentSort = {
         prop: prop,
         order: order
       };
-      
+
       // 更新查询参数
       if (order) {
         this.queryParams.sortField = prop;
@@ -1280,11 +1280,11 @@ export default {
         this.queryParams.sortField = null;
         this.queryParams.sortOrder = null;
       }
-      
+
       // 重新查询数据
       this.queryParams.pageNum = 1; // 重置到第一页
       this.getList();
-      
+
       // 显示排序提示
       if (order) {
         const fieldLabel = this.getSortLabel(prop);
@@ -1292,12 +1292,12 @@ export default {
         this.$message.success(`已按${fieldLabel}${orderLabel}排序`);
       }
     },
-    
+
     // 获取排序字段的中文标签
     getSortLabel(prop) {
       return this.sortFieldMap[prop] || prop;
     },
-    
+
     // 清除排序
     clearSort() {
       this.currentSort = {
@@ -1319,67 +1319,66 @@ export default {
      // 处理键盘按下事件
      handleKeyDown(event) {
       const { key, target } = event
-      
+
       // 处理退格键删除标签
       if (key === 'Backspace' && !target.value && this.queryParams.orderCodes.length > 0) {
         event.preventDefault()
         this.removeOrderCode(this.queryParams.orderCodes.length - 1)
       }
-      
+
       // 处理分隔符
       if ([',', ',', ' ', 'Enter'].includes(key)) {
         event.preventDefault()
         this.handleInputConfirm()
       }
     },
-    
+
     // 处理键盘抬起事件(实时分割输入)
     handleKeyUp(event) {
       const value = event.target.value
-      
+
       // 检查是否包含分隔符
       if (/[,,\s]/.test(value)) {
         this.handleInputConfirm()
       }
     },
-    
+
     // 确认输入
     handleInputConfirm() {
       const inputValue = this.currentInput.trim()
-      
+
       if (inputValue) {
         // 分割多个订单号
         const codes = inputValue.split(/[,,\s]+/).filter(code => code.trim())
-        
+
         codes.forEach(code => {
           this.addOrderCode(code.trim())
         })
       }
-      
+
       this.currentInput = ''
     },
-    
+
     // 添加订单号
     addOrderCode(code) {
       if (!code) return
-      
+
       // 检查数量限制
       if (this.maxOrderCodes > 0 && this.queryParams.orderCodes.length >= this.maxOrderCodes) {
         this.$message.warning(`最多只能添加 ${this.maxOrderCodes} 个订单号`)
         return
       }
-      
+
       // 检查重复
       if (this.queryParams.orderCodes.includes(code)) {
         this.$message.warning(`订单号 "${code}" 已存在`)
         return
       }
-      
+
       // 添加到列表
       this.queryParams.orderCodes.push(code)
-      
+
     },
-    
     // 删除订单号
     removeOrderCode(index) {
       this.queryParams.orderCodes.splice(index, 1)
@@ -1402,10 +1401,6 @@ export default {
         this.$refs.tagInput.focus()
       })
     },
-    // 删除订单号
-    removeOrderCode(index) {
-      this.queryParams.orderCodes.splice(index, 1)
-    },
     // 聚焦输入框
     focusInput() {
       if (!this.inputVisible) {
@@ -1424,7 +1419,7 @@ export default {
       this.erpSettingType = 'push'
       this.calculateOrderSummary();
     },
-    
+
     //获取ERP账户列表
     async getErpAccountList() {
       try {
@@ -1442,7 +1437,7 @@ export default {
           this.$message.error(response.msg || '获取ERP账户列表失败');
           this.erpAccountList = [];
         }
-        
+
       } catch (error) {
         console.error('获取ERP账户列表失败:', error);
         this.$message.error('获取ERP账户列表失败');
@@ -1451,13 +1446,13 @@ export default {
         this.erpAccountDialog.loading = false;
       }
     },
-    
+
     // 新增:计算订单统计信息
     calculateOrderSummary() {
       let selectedCount = 0;
       let totalAmount = 0;
       let queryCount = this.total || 0;
-      
+
       if (this.ids.length > 0) {
         // 如果有选中的订单,统计选中的订单
         selectedCount = this.ids.length;
@@ -1473,14 +1468,14 @@ export default {
           totalAmount += parseFloat(order.payMoney || 0);
         });
       }
-      
+
       this.orderSummary = {
         selectedCount,
         totalAmount: totalAmount.toFixed(2),
         queryCount
       };
     },
-    
+
     //确认创建ERP订单
     confirmCreateErpOrder() {
       if (!this.erpAccountForm.selectedAccount) {
@@ -1490,8 +1485,8 @@ export default {
       console.log("-----------------",this.erpSettingType)
       if(this.erpSettingType == 'set'){
         this.$confirm(
-          `确认将订单设置ERP账户为"${this.erpAccountForm.selectedAccount}"吗?`, 
-          '确认', 
+          `确认将订单设置ERP账户为"${this.erpAccountForm.selectedAccount}"吗?`,
+          '确认',
           {
             confirmButtonText: '确定',
             cancelButtonText: '取消',
@@ -1502,8 +1497,8 @@ export default {
         });
       } else if(this.erpSettingType == 'push'){
         this.$confirm(
-          `确认将订单推送到ERP账户"${this.erpAccountForm.selectedAccount}"吗?`, 
-          '确认推送', 
+          `确认将订单推送到ERP账户"${this.erpAccountForm.selectedAccount}"吗?`,
+          '确认推送',
           {
             confirmButtonText: '确定推送',
             cancelButtonText: '取消',
@@ -1517,12 +1512,12 @@ export default {
 
     async executSetErpOrder() {
       this.erpAccountDialog.submitting = true;
-      
+
       try {
         let param = {
           loginAccount: this.erpAccountForm.selectedAccount
         };
-        
+
         if (this.ids.length > 0) {
           // 如果有选中的订单,只推送选中的
           param.orderIds = this.ids;
@@ -1553,11 +1548,11 @@ export default {
           } else {
             this.queryParams.qwSubject = null;
           }
-          
+
           // 合并查询参数
           param = { ...param, ...this.queryParams };
         }
-        
+
         const response = await batchSetErpOrder(param);
         if (response.code === 200) {
           this.$message.success('订单ERP账号设置成功');
@@ -1574,16 +1569,16 @@ export default {
         this.erpAccountDialog.submitting = false;
       }
     },
-    
+
     //执行创建ERP订单
     async executeCreateErpOrder() {
       this.erpAccountDialog.submitting = true;
-      
+
       try {
         let param = {
           loginAccount: this.erpAccountForm.selectedAccount
         };
-        
+
         if (this.ids.length > 0) {
           // 如果有选中的订单,只推送选中的
           param.orderIds = this.ids;
@@ -1614,11 +1609,11 @@ export default {
           } else {
             this.queryParams.qwSubject = null;
           }
-          
+
           // 合并查询参数
           param = { ...param, ...this.queryParams };
         }
-        
+
         const response = await batchCreateErpOrder(param);
         if (response.code === 200) {
           this.$message.success('ERP订单创建成功');
@@ -1635,7 +1630,7 @@ export default {
         this.erpAccountDialog.submitting = false;
       }
     },
-    
+
     // 新增:取消ERP账户选择对话框
     cancelErpAccountDialog() {
       this.erpAccountDialog.open = false;
@@ -1685,7 +1680,7 @@ export default {
         param = this.queryParams;
         param.erpPhone=this.erpPhoneValue;
       }
-      
+
       editErpPhone(param).then(response=>{
         this.msgSuccess("修改成功");
         this.setPhoneOpen = false;
@@ -1712,7 +1707,7 @@ export default {
             originalPhone: phone.trim()
           }));
         }
-        
+
         // 保存原始数据用于取消操作
         this.originalPhoneList = this.phoneList;
       });
@@ -1743,7 +1738,7 @@ export default {
         return;
       }
       // 检查是否重复
-      const duplicateIndex = this.phoneList.findIndex((item, idx) => 
+      const duplicateIndex = this.phoneList.findIndex((item, idx) =>
         idx !== index && item.phone === phone
       );
       if (duplicateIndex !== -1) {
@@ -1794,17 +1789,17 @@ export default {
         this.$message.error('请先保存正在编辑的手机号');
         return;
       }
-      
+
       // 检查是否有空的手机号
       const emptyPhone = this.phoneList.find(item => !item.phone.trim());
       if (emptyPhone) {
         this.$message.error('存在空的手机号,请删除或填写完整');
         return;
       }
-      
+
       // 构造手机号列表
       const phoneList = this.phoneList.map(item => item.phone);
-      
+
       // 调用保存接口
       saveErpPhone(phoneList).then(response => {
         if (response.code === 200) {
@@ -1835,7 +1830,7 @@ export default {
     getSelectedFieldsCount() {
       return this.exportFieldOptions.filter(field => field.checked).length;
     },
-    
+
     // 取消导出字段选择
     cancelExportFieldDialog() {
       this.exportFieldDialog.open = false;
@@ -1846,9 +1841,9 @@ export default {
       // 先全不选
       this.unselectAllFields();
       // 然后选择常用字段
-      const defaultFields = ['orderCode', 'prescribeCode', 'companyName', 'companyUserNickName', 
-                           'storeName', 'miniProgramName', 'userName', 'userPhone', 'userAddress', 'totalPrice', 
-                           'totalNum', 'payPrice', 'payMoney', 'createTime', 'payTime', 
+      const defaultFields = ['orderCode', 'prescribeCode', 'companyName', 'companyUserNickName',
+                           'storeName', 'miniProgramName', 'userName', 'userPhone', 'userAddress', 'totalPrice',
+                           'totalNum', 'payPrice', 'payMoney', 'createTime', 'payTime',
                            'payType', 'status', 'packageName', 'patientName'];
       this.exportFieldOptions.forEach(field => {
         if (defaultFields.includes(field.key)) {
@@ -1861,7 +1856,7 @@ export default {
     confirmExportFields() {
       // 获取已选择的字段
       const selectedFieldsArray = this.exportFieldOptions.filter(field => field.checked);
-      
+
       let selectedFields = '';
       if (selectedFieldsArray.length === 0) {
         // 如果没有选择任何字段,则导出全部字段(不传filter参数)
@@ -1870,17 +1865,17 @@ export default {
         // 如果选择了字段,则只导出选中的字段
         selectedFields = selectedFieldsArray.map(field => field.key).join(',');
       }
-      
+
       // 关闭弹窗
       this.exportFieldDialog.open = false;
-      
+
       // 执行导出操作
       this.doExportOrder(selectedFields);
     },
 
     // 执行导出操作
     doExportOrder(selectedFields) {
-      
+
       if (this.queryParams.status == '00') {
         this.queryParams.status = null
       }
@@ -2147,6 +2142,10 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
+      this.payTimeRange = []
+      this.createTimeRange = []
+      this.deliverySendTimeRange = []
+      this.deliveryImportTimeRange = []
       this.resetForm('queryForm')
       // 清除排序
       this.currentSort = {
@@ -2593,11 +2592,11 @@ export default {
     min-width: auto;
     width: 100%;
   }
-  
+
   .tags-wrapper {
     min-height: 40px;
   }
-  
+
   .quick-actions {
     flex-direction: column;
     align-items: flex-start;

+ 106 - 102
src/views/hisStore/storeOrder/index.vue

@@ -42,7 +42,7 @@
             >
               {{ code }}
             </el-tag>
-            
+
             <!-- 输入框 -->
             <el-input
               ref="tagInput"
@@ -57,7 +57,7 @@
               @focus="inputVisible = true"
               clearable
             />
-            
+
             <!-- 添加按钮(当没有输入时显示) -->
             <el-button
               v-if="!inputVisible && queryParams.orderCodes.length > 0"
@@ -70,11 +70,11 @@
               添加订单号
             </el-button>
           </div>
-          
+
           <!-- 输入提示 -->
           <div class="input-tips">
             <span class="tip-text">
-              支持:回车、逗号、空格分隔 | 
+              支持:回车、逗号、空格分隔 |
               已添加 {{ queryParams.orderCodes.length }} 个订单号
               <span v-if="maxOrderCodes > 0"> (最多{{ maxOrderCodes }}个)</span>
             </span>
@@ -346,7 +346,7 @@
             plain
             icon="el-icon-phone"
             size="mini"
-            
+
             @click="setErpPhone"
             v-hasPermi="['his:storeOrder:createErpOrder']"
           >设置推送手机</el-button>
@@ -408,7 +408,7 @@
           size="mini"
       >订单量/金额: {{ total }}/{{payPriceTotal }}</el-button>
       </el-col>
-      
+
       <el-col :span="1.5">
         <el-input
           v-model="orderItemNum"
@@ -568,12 +568,12 @@
     <div v-if="currentSort.prop" class="sort-info">
         <el-tag size="small" type="info" closable @close="clearSort">
           <i class="el-icon-sort"></i>
-          当前排序:{{ getSortLabel(currentSort.prop) }} 
+          当前排序:{{ getSortLabel(currentSort.prop) }}
           {{ currentSort.order === 'ascending' ? '升序' : '降序' }}
         </el-tag>
-          <el-button 
-            type="text" 
-            size="mini" 
+          <el-button
+            type="text"
+            size="mini"
             @click="clearSort"
             style="margin-left: 8px; color: #909399;"
           >
@@ -816,9 +816,9 @@
       <el-table :data="phoneList" border style="width: 100%">
         <el-table-column prop="phone" label="手机号" align="center">
           <template slot-scope="scope">
-            <el-input 
-              v-if="scope.row.editing" 
-              v-model="scope.row.phone" 
+            <el-input
+              v-if="scope.row.editing"
+              v-model="scope.row.phone"
               placeholder="请输入手机号"
               @blur="validatePhone(scope.row)"
               @keyup.enter.native="handleSavePhone(scope.$index)"
@@ -828,27 +828,27 @@
         </el-table-column>
         <el-table-column label="操作" align="center" width="300">
           <template slot-scope="scope">
-            <el-button 
-              v-if="scope.row.editing" 
-              type="success" 
-              size="mini" 
+            <el-button
+              v-if="scope.row.editing"
+              type="success"
+              size="mini"
               @click="handleSavePhone(scope.$index)"
             >保存</el-button>
-            <el-button 
-              v-if="scope.row.editing" 
-              type="info" 
-              size="mini" 
+            <el-button
+              v-if="scope.row.editing"
+              type="info"
+              size="mini"
               @click="handleCancelEdit(scope.$index)"
             >取消</el-button>
-            <el-button 
-              v-if="!scope.row.editing" 
-              type="primary" 
-              size="mini" 
+            <el-button
+              v-if="!scope.row.editing"
+              type="primary"
+              size="mini"
               @click="handleEditPhone(scope.$index)"
             >修改</el-button>
-            <el-button 
-              type="danger" 
-              size="mini" 
+            <el-button
+              type="danger"
+              size="mini"
               @click="handleDeletePhone(scope.$index)"
             >删除</el-button>
           </template>
@@ -879,9 +879,9 @@
       <div v-loading="erpAccountDialog.loading">
         <el-form :model="erpAccountForm" label-width="100px">
           <el-form-item label="ERP账户" required>
-            <el-select 
-              v-model="erpAccountForm.selectedAccount" 
-              placeholder="请选择ERP账户" 
+            <el-select
+              v-model="erpAccountForm.selectedAccount"
+              placeholder="请选择ERP账户"
               style="width: 100%"
               filterable
             >
@@ -897,7 +897,7 @@
             </el-select>
           </el-form-item>
         </el-form>
-        
+
         <!-- 订单统计信息 -->
         <div class="order-summary" v-if="orderSummary">
           <el-divider content-position="left">订单统计</el-divider>
@@ -923,11 +923,11 @@
           </el-row>
         </div>
       </div>
-      
+
       <div slot="footer" class="dialog-footer">
         <el-button @click="cancelErpAccountDialog">取 消</el-button>
-        <el-button 
-          type="primary" 
+        <el-button
+          type="primary"
           @click="confirmCreateErpOrder"
           :disabled="!erpAccountForm.selectedAccount"
           :loading="erpAccountDialog.submitting"
@@ -943,12 +943,12 @@
           <el-button type="default" size="small" @click="unselectAllFields">全不选</el-button>
           <el-button type="success" size="small" @click="selectDefaultFields">选择常用</el-button>
         </div>
-        
+
         <div class="field-selection-container">
           <el-row :gutter="20">
             <el-col :span="8" v-for="field in exportFieldOptions" :key="field.key">
-              <el-checkbox 
-                v-model="field.checked" 
+              <el-checkbox
+                v-model="field.checked"
                 :label="field.label"
                 style="margin-bottom: 12px; width: 100%;"
               >
@@ -957,7 +957,7 @@
             </el-col>
           </el-row>
         </div>
-        
+
         <div class="field-count-info" style="margin-top: 20px; padding: 10px; background: #f5f7fa; border-radius: 4px;">
           <i class="el-icon-info"></i>
           <span v-if="getSelectedFieldsCount() > 0">
@@ -969,11 +969,11 @@
           </span>
         </div>
       </div>
-      
+
       <div slot="footer" class="dialog-footer">
         <el-button @click="cancelExportFieldDialog">取 消</el-button>
-        <el-button 
-          type="primary" 
+        <el-button
+          type="primary"
           @click="confirmExportFields"
         >确认导出</el-button>
       </div>
@@ -1033,11 +1033,11 @@ export default {
         prop: null,
         order: null
       },
-      
+
       // 排序字段映射
       sortFieldMap: {
         'companyUserName': '员工',
-        'packageName': '套餐名称', 
+        'packageName': '套餐名称',
         'payPrice': '应收金额',
         'payMoney': '实收金额',
         'createTime': '下单时间'
@@ -1051,7 +1051,7 @@ export default {
       },
       // 输入框是否可见
       inputVisible: false,
-      
+
       // 无效订单号对话框
       showInvalidDialog: false,
       // 当前输入值
@@ -1323,13 +1323,13 @@ export default {
     // 新增排序处理方法
     handleSortChange({ column, prop, order }) {
       console.log('排序变化:', { column, prop, order });
-      
+
       // 更新当前排序状态
       this.currentSort = {
         prop: prop,
         order: order
       };
-      
+
       // 更新查询参数
       if (order) {
         this.queryParams.sortField = prop;
@@ -1338,11 +1338,11 @@ export default {
         this.queryParams.sortField = null;
         this.queryParams.sortOrder = null;
       }
-      
+
       // 重新查询数据
       this.queryParams.pageNum = 1; // 重置到第一页
       this.getList();
-      
+
       // 显示排序提示
       if (order) {
         const fieldLabel = this.getSortLabel(prop);
@@ -1350,12 +1350,12 @@ export default {
         this.$message.success(`已按${fieldLabel}${orderLabel}排序`);
       }
     },
-    
+
     // 获取排序字段的中文标签
     getSortLabel(prop) {
       return this.sortFieldMap[prop] || prop;
     },
-    
+
     // 清除排序
     clearSort() {
       this.currentSort = {
@@ -1377,67 +1377,67 @@ export default {
      // 处理键盘按下事件
      handleKeyDown(event) {
       const { key, target } = event
-      
+
       // 处理退格键删除标签
       if (key === 'Backspace' && !target.value && this.queryParams.orderCodes.length > 0) {
         event.preventDefault()
         this.removeOrderCode(this.queryParams.orderCodes.length - 1)
       }
-      
+
       // 处理分隔符
       if ([',', ',', ' ', 'Enter'].includes(key)) {
         event.preventDefault()
         this.handleInputConfirm()
       }
     },
-    
+
     // 处理键盘抬起事件(实时分割输入)
     handleKeyUp(event) {
       const value = event.target.value
-      
+
       // 检查是否包含分隔符
       if (/[,,\s]/.test(value)) {
         this.handleInputConfirm()
       }
     },
-    
+
     // 确认输入
     handleInputConfirm() {
       const inputValue = this.currentInput.trim()
-      
+
       if (inputValue) {
         // 分割多个订单号
         const codes = inputValue.split(/[,,\s]+/).filter(code => code.trim())
-        
+
         codes.forEach(code => {
           this.addOrderCode(code.trim())
         })
       }
-      
+
       this.currentInput = ''
     },
-    
+
     // 添加订单号
     addOrderCode(code) {
       if (!code) return
-      
+
       // 检查数量限制
       if (this.maxOrderCodes > 0 && this.queryParams.orderCodes.length >= this.maxOrderCodes) {
         this.$message.warning(`最多只能添加 ${this.maxOrderCodes} 个订单号`)
         return
       }
-      
+
       // 检查重复
       if (this.queryParams.orderCodes.includes(code)) {
         this.$message.warning(`订单号 "${code}" 已存在`)
         return
       }
-      
+
       // 添加到列表
       this.queryParams.orderCodes.push(code)
-      
+
     },
-    
+
     // 删除订单号
     removeOrderCode(index) {
       this.queryParams.orderCodes.splice(index, 1)
@@ -1482,7 +1482,7 @@ export default {
       this.erpSettingType = 'push'
       this.calculateOrderSummary();
     },
-    
+
     //获取ERP账户列表
     async getErpAccountList() {
       try {
@@ -1500,7 +1500,7 @@ export default {
           this.$message.error(response.msg || '获取ERP账户列表失败');
           this.erpAccountList = [];
         }
-        
+
       } catch (error) {
         console.error('获取ERP账户列表失败:', error);
         this.$message.error('获取ERP账户列表失败');
@@ -1509,13 +1509,13 @@ export default {
         this.erpAccountDialog.loading = false;
       }
     },
-    
+
     // 新增:计算订单统计信息
     calculateOrderSummary() {
       let selectedCount = 0;
       let totalAmount = 0;
       let queryCount = this.total || 0;
-      
+
       if (this.ids.length > 0) {
         // 如果有选中的订单,统计选中的订单
         selectedCount = this.ids.length;
@@ -1531,14 +1531,14 @@ export default {
           totalAmount += parseFloat(order.payMoney || 0);
         });
       }
-      
+
       this.orderSummary = {
         selectedCount,
         totalAmount: totalAmount.toFixed(2),
         queryCount
       };
     },
-    
+
     //确认创建ERP订单
     confirmCreateErpOrder() {
       if (!this.erpAccountForm.selectedAccount) {
@@ -1548,8 +1548,8 @@ export default {
       console.log("-----------------",this.erpSettingType)
       if(this.erpSettingType == 'set'){
         this.$confirm(
-          `确认将订单设置ERP账户为"${this.erpAccountForm.selectedAccount}"吗?`, 
-          '确认', 
+          `确认将订单设置ERP账户为"${this.erpAccountForm.selectedAccount}"吗?`,
+          '确认',
           {
             confirmButtonText: '确定',
             cancelButtonText: '取消',
@@ -1560,8 +1560,8 @@ export default {
         });
       } else if(this.erpSettingType == 'push'){
         this.$confirm(
-          `确认将订单推送到ERP账户"${this.erpAccountForm.selectedAccount}"吗?`, 
-          '确认推送', 
+          `确认将订单推送到ERP账户"${this.erpAccountForm.selectedAccount}"吗?`,
+          '确认推送',
           {
             confirmButtonText: '确定推送',
             cancelButtonText: '取消',
@@ -1575,12 +1575,12 @@ export default {
 
     async executSetErpOrder() {
       this.erpAccountDialog.submitting = true;
-      
+
       try {
         let param = {
           loginAccount: this.erpAccountForm.selectedAccount
         };
-        
+
         if (this.ids.length > 0) {
           // 如果有选中的订单,只推送选中的
           param.orderIds = this.ids;
@@ -1589,7 +1589,7 @@ export default {
           // 合并查询参数
           param = { ...param, ...this.queryParams };
         }
-        
+
         const response = await batchSetErpOrder(param);
         if (response.code === 200) {
           this.$message.success('订单ERP账号设置成功');
@@ -1606,16 +1606,16 @@ export default {
         this.erpAccountDialog.submitting = false;
       }
     },
-    
+
     //执行创建ERP订单
     async executeCreateErpOrder() {
       this.erpAccountDialog.submitting = true;
-      
+
       try {
         let param = {
           loginAccount: this.erpAccountForm.selectedAccount
         };
-        
+
         if (this.ids.length > 0) {
           // 如果有选中的订单,只推送选中的
           param.orderIds = this.ids;
@@ -1624,7 +1624,7 @@ export default {
           // 合并查询参数
           param = { ...param, ...this.queryParams };
         }
-        
+
         const response = await batchCreateErpOrder(param);
         if (response.code === 200) {
           this.$message.success('ERP订单创建成功');
@@ -1641,7 +1641,7 @@ export default {
         this.erpAccountDialog.submitting = false;
       }
     },
-    
+
     // 新增:取消ERP账户选择对话框
     cancelErpAccountDialog() {
       this.erpAccountDialog.open = false;
@@ -1661,7 +1661,7 @@ export default {
         param = this.queryParams;
         param.erpPhone=this.erpPhoneValue;
       }
-      
+
       editErpPhone(param).then(response=>{
         this.msgSuccess("修改成功");
         this.setPhoneOpen = false;
@@ -1688,7 +1688,7 @@ export default {
             originalPhone: phone.trim()
           }));
         }
-        
+
         // 保存原始数据用于取消操作
         this.originalPhoneList = this.phoneList;
       });
@@ -1719,7 +1719,7 @@ export default {
         return;
       }
       // 检查是否重复
-      const duplicateIndex = this.phoneList.findIndex((item, idx) => 
+      const duplicateIndex = this.phoneList.findIndex((item, idx) =>
         idx !== index && item.phone === phone
       );
       if (duplicateIndex !== -1) {
@@ -1770,17 +1770,17 @@ export default {
         this.$message.error('请先保存正在编辑的手机号');
         return;
       }
-      
+
       // 检查是否有空的手机号
       const emptyPhone = this.phoneList.find(item => !item.phone.trim());
       if (emptyPhone) {
         this.$message.error('存在空的手机号,请删除或填写完整');
         return;
       }
-      
+
       // 构造手机号列表
       const phoneList = this.phoneList.map(item => item.phone);
-      
+
       // 调用保存接口
       saveErpPhone(phoneList).then(response => {
         if (response.code === 200) {
@@ -1811,7 +1811,7 @@ export default {
     getSelectedFieldsCount() {
       return this.exportFieldOptions.filter(field => field.checked).length;
     },
-    
+
     // 取消导出字段选择
     cancelExportFieldDialog() {
       this.exportFieldDialog.open = false;
@@ -1822,9 +1822,9 @@ export default {
       // 先全不选
       this.unselectAllFields();
       // 然后选择常用字段
-      const defaultFields = ['orderCode', 'prescribeCode', 'companyName', 'companyUserNickName', 
-                           'storeName', 'miniProgramName', 'userName', 'userPhone', 'userAddress', 'totalPrice', 
-                           'totalNum', 'payPrice', 'payMoney', 'createTime', 'payTime', 
+      const defaultFields = ['orderCode', 'prescribeCode', 'companyName', 'companyUserNickName',
+                           'storeName', 'miniProgramName', 'userName', 'userPhone', 'userAddress', 'totalPrice',
+                           'totalNum', 'payPrice', 'payMoney', 'createTime', 'payTime',
                            'payType', 'status', 'packageName', 'patientName'];
       this.exportFieldOptions.forEach(field => {
         if (defaultFields.includes(field.key)) {
@@ -1837,7 +1837,7 @@ export default {
     confirmExportFields() {
       // 获取已选择的字段
       const selectedFieldsArray = this.exportFieldOptions.filter(field => field.checked);
-      
+
       let selectedFields = '';
       if (selectedFieldsArray.length === 0) {
         // 如果没有选择任何字段,则导出全部字段(不传filter参数)
@@ -1846,17 +1846,17 @@ export default {
         // 如果选择了字段,则只导出选中的字段
         selectedFields = selectedFieldsArray.map(field => field.key).join(',');
       }
-      
+
       // 关闭弹窗
       this.exportFieldDialog.open = false;
-      
+
       // 执行导出操作
       this.doExportOrder(selectedFields);
     },
 
     // 执行导出操作
     doExportOrder(selectedFields) {
-      
+
       if(this.queryParams.status=='00'){
         this.queryParams.status=null;
       }
@@ -1913,7 +1913,7 @@ export default {
           } else if (this.exportFieldDialog.type == 2){
             return exportStoreOrderDetails(requestParams);
           }
-          
+
         }).then(response => {
           this.download(response.msg);
         }).catch(function() {});
@@ -1933,7 +1933,7 @@ export default {
       });
     },
 
-    
+
 
     handleGenPayUrl(row){
       this.payQr.open=true;
@@ -2171,6 +2171,10 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
+      this.payTimeRange = []
+      this.createTimeRange = []
+      this.deliverySendTimeRange = []
+      this.deliveryImportTimeRange = []
       this.resetForm("queryForm");
       // 清除排序
       this.currentSort = {
@@ -2295,7 +2299,7 @@ export default {
     },
     /** 导出按钮操作 */
     handleExportDetails() {
-      
+
       this.exportFieldDialog.open = true;
       this.exportFieldDialog.type = 2;
     },
@@ -2621,11 +2625,11 @@ export default {
     min-width: auto;
     width: 100%;
   }
-  
+
   .tags-wrapper {
     min-height: 40px;
   }
-  
+
   .quick-actions {
     flex-direction: column;
     align-items: flex-start;

+ 5 - 1
src/views/hisStore/storePayment/index.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="app-container">
     <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
-     <el-form-item label="公司名" prop="companyId">
+     <el-form-item label="公司名2222" prop="companyId">
           <el-select filterable v-model="queryParams.companyId" placeholder="请选择公司名" clearable size="small">
               <el-option
                 v-for="item in companys"
@@ -473,8 +473,12 @@ export default {
     },
     /** 重置按钮操作 */
     resetQuery() {
+      this.dateRange=[];
+      this.refundDateRange=[];
+      this.createTimeRange=[];
       this.resetForm("queryForm");
       this.handleQuery();
+
     },
     // 多选框选中数据
     handleSelectionChange(selection) {