819527061@qq.com
2025-01-08 1618162f712fc414702bce924ff367397ff8ec1d
src/components/page/orderRecord/indexDay.vue
@@ -24,6 +24,7 @@
        </div>
        <el-table
            v-loading="loading"
            :height="tableHeight"
            :data="table2"
            border
@@ -71,7 +72,8 @@
                table1:[],
                table2:[],
                headTable:[],
                tableHeight:500
                tableHeight:500,
                loading:true
            }
        },
      created() {
@@ -85,19 +87,25 @@
        },
        methods: {
            loadData() {
              this.table2 = []
              this.$byutil.postData(this, this.urlPath+'findCountPageByDay', this.searchForm,res => {
                this.headTable = res.data[0].data
                let temp = res.data
                temp.forEach(item => {
                  let row = {day:item.day};
                  item.data.forEach(e=>{
                    row[e.parkName + 'num']=e.num;
                    row[e.parkName + 'price']=e.price;
              try{
                this.loading = true
                this.table2 = []
                this.$byutil.postData(this, this.urlPath+'findCountPageByDay', this.searchForm,res => {
                  this.loading = false
                  this.headTable = res.data[0].data
                  let temp = res.data
                  temp.forEach(item => {
                    let row = {day:item.day};
                    item.data.forEach(e=>{
                      row[e.parkName + 'num']=e.num;
                      row[e.parkName + 'price']=e.price;
                    })
                    this.table2.push(row)
                  })
                  this.table2.push(row)
                })
             });
                });
              }catch (err){
                this.loading = false
              }
            },
            onSearch() {
                this.loadData();