购物车历史订单增加,代码优化

This commit is contained in:
GaoHao
2025-04-02 09:20:26 +08:00
parent 5a655ba09e
commit 5e6646b574
31 changed files with 418 additions and 357 deletions

View File

@@ -72,12 +72,13 @@
</template>
<script setup>
import { onMounted, getCurrentInstance, ref } from 'vue';
import { onMounted, ref } from 'vue';
import datePickerview from './components/my-date-pickerview.vue'
import dayjs from 'dayjs' //时间格式库
import go from '@/commons/utils/go.js'
import { getTrade, productSaleDate } from '@/http/api/summary.js'
const datePicker=ref()
const timeList = [{
label: '今天',
value: 'today'
@@ -100,7 +101,6 @@
]
let selected = ref('today')
let list = ref({})
const currentInstance = getCurrentInstance()
let tableList = ref([])
let day = ref(1)
onMounted(() => {
@@ -209,7 +209,7 @@
function changeTime(e) {
selected.value = e
if (e == 'custom') {
currentInstance.ctx.$refs.datePicker.toggle()
datePicker.value.toggle()
} else {
getlist()
gettableData()