Commit aff079dd authored by 罗超's avatar 罗超

完成部分调整

parent def92ea4
......@@ -136,11 +136,11 @@ export default defineComponent({
const HotelLength = inject(DirtionmaryHelper.HOTEL_CAR_ORDER_LENGTH) as any
const orderstatus = inject(DirtionmaryHelper.HOTEL_CAR_ORDER_STATUS) as any
const cars = inject(DirtionmaryHelper.HOTEL_CAR_LIST) as any
cars&&cars.value.forEach((item:any,index:Number) => {
if(dateDiffer(item.Date)<15){
cars.value.splice(index,1)
}
});
// cars&&cars.value.forEach((item:any,index:Number) => {
// if(dateDiffer(item.Date)<15){
// cars.value.splice(index,1)
// }
// });
HotelLength.value = cars.value.length
const editor = inject(DirtionmaryHelper.HOTEL_UPDATEHOTEL_CAR) as any
const { t } = useI18n()
......
......@@ -63,7 +63,7 @@ import { date } from 'quasar'
import { HotelRate, useHotel } from '../../../utils/hotelRate'
import { useQuasar } from 'quasar'
import useScrollModule from '../../../module/scrollbar/scrollModule'
import { dateDiffer } from '../../../utils/tools'
// import { dateDiffer } from '../../../utils/tools'
import ListCar from "./ListCar.vue"
import { DirtionmaryHelper } from '../../../config/dictionary'
export default defineComponent({
......@@ -71,11 +71,11 @@ export default defineComponent({
setup() {
const HotelLength = inject(DirtionmaryHelper.HOTEL_CAR_ORDER_LENGTH) as any
const cars = inject(DirtionmaryHelper.HOTEL_CAR_LIST) as any
cars&&cars.value.forEach((item:any,index:Number) => {
if(dateDiffer(item.Date)<15){
cars.value.splice(index,1)
}
});
// cars&&cars.value.forEach((item:any,index:Number) => {
// if(dateDiffer(item.Date)<15){
// cars.value.splice(index,1)
// }
// });
HotelLength.value = cars.value.length
const $q = useQuasar()
const qDateProxy = ref(null) as any
......
......@@ -110,11 +110,11 @@ export default defineComponent({
const qDateProxyOpera = ref<any>(null)
const HotelLength = inject(DirtionmaryHelper.HOTEL_CAR_ORDER_LENGTH) as any
const cars = inject(DirtionmaryHelper.HOTEL_CAR_LIST) as any
cars&&cars.value.forEach((item:any,index:Number) => {
if(dateDiffer(item.Date)<15){
cars.value.splice(index,1)
}
});
// cars&&cars.value.forEach((item:any,index:Number) => {
// if(dateDiffer(item.Date)<15){
// cars.value.splice(index,1)
// }
// });
HotelLength.value = cars.value.length
const editor = inject(DirtionmaryHelper.HOTEL_UPDATEHOTEL_CAR) as any
const data = reactive({
......
......@@ -15,6 +15,7 @@ import { defineComponent, inject, provide, reactive, ref, toRefs } from 'vue'
import { DirtionmaryHelper } from '../../config/dictionary'
import ListHeader from '../../components/hotel/list/ListHeader.vue'
import ListTable from '../../components/hotel/list/ListTable.vue'
import { date } from 'quasar'
export default defineComponent({
components: { svgIcon, ListHeader, ListTable },
setup() {
......@@ -44,7 +45,8 @@ export default defineComponent({
const cacheCars = localStorage.getItem(DirtionmaryHelper.HOTEL_HOTELCARS_CACHE)
if(cacheCars){
HotelCarList.value = JSON.parse(cacheCars)
let cacheCarArray = JSON.parse(cacheCars)//.filter((x:any)=>date.getDateDiff(new Date(x.Date),new Date(), 'days')>=15 )
HotelCarList.value = cacheCarArray
}
provide(DirtionmaryHelper.HOTEL_CAR_LIST, HotelCarList)
const updateObj = ref<any>({})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment