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

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

@@ -27,4 +27,11 @@ export function getThisMonthTimestamps() {
const end = dayjs().endOf('month').format('YYYY-MM-DD HH:mm:ss');
return { start, end ,label:'本月'};
}
// 获取上个月的开始和结束时间
export function getThisLastMonthTimestamps() {
const start = dayjs().subtract(1, 'month').startOf('month').format('YYYY-MM-DD HH:mm:ss');
const end = dayjs().subtract(1, 'month').endOf('month').format('YYYY-MM-DD HH:mm:ss');
return { start, end ,label:'上月'};
}

View File

@@ -8,7 +8,6 @@ export const utils = {
* @param {Object} e
*/
isNumber (e) {
console.log(e)
return e.replace(/[^\d]/g, '')
},

View File

@@ -1,6 +1,5 @@
import {
getCurrentInstance,
} from 'vue';
import { getCurrentInstance } from 'vue';
export async function getElRect(elClass, instance,option) {
instance = instance ? instance : getCurrentInstance();
const query = uni.createSelectorQuery().in(instance.proxy);

View File

@@ -249,7 +249,6 @@ const model = {
if (envMode) {
uni.setStorageSync(appConfig.storeEnvEnumKey, envMode) // 改变存储
}
console.log(appConfig.storeEnvEnumKey)
return uni.getStorageSync(appConfig.storeEnvEnumKey)
},