Commit f94c360c authored by 沈良进's avatar 沈良进

save

parent 4dbf13ee
......@@ -155,6 +155,7 @@ export default defineComponent({
watch(search, (n, o) => {
if (data.loading) return;
data.pages.pageIndex = 1;
data.pages.pageCount = 1;
data.orders = [];
methods.initOrders();
});
......@@ -256,6 +257,7 @@ export default defineComponent({
initOrders() {
data.loading = true;
let param = Object.assign(data.pages, search);
param.PayStatus=param.PayStatus ? param.PayStatus : -1
travelService
.getOrderList(param)
.then((r) => {
......
......@@ -59,15 +59,21 @@ export default defineComponent({
const realSearch = inject(DirtionmaryHelper.TRAVEL_ORDER_OBJ) as any
const search = reactive(JSON.parse(JSON.stringify(realSearch)))
const dateRange = reactive({from: '', to: ''})
dateRange.to = date.formatDate(date.addToDate(new Date(), { days: 50 }), 'YYYY/MM/DD')
dateRange.from = date.formatDate(date.addToDate(new Date(), { days: 20 }), 'YYYY/MM/DD')
let month = new Date().getMonth() + 2
let year = new Date().getFullYear()
if(month > 12) {
month = 1
year++
}
dateRange.to = date.formatDate(date.adjustDate(new Date(), { year,month: month,days: 1 }), 'YYYY/MM/DD')
dateRange.from = date.formatDate(date.adjustDate(new Date(), { days: 1 }), 'YYYY/MM/DD')
const dateRangeFormat = ref(`${dateRange.from} - ${dateRange.to}`)
search.QStartDate = dateRange.from
search.QEndDate = dateRange.to
const dateRangeC = reactive({from: '', to: ''})
dateRangeC.to = date.formatDate(date.addToDate(new Date(), { days: 50 }), 'YYYY/MM/DD')
dateRangeC.from = date.formatDate(date.addToDate(new Date(), { days: 20 }), 'YYYY/MM/DD')
const dateRangeFormatC = ref(`${dateRange.from} - ${dateRange.to}`)
dateRangeC.to = date.formatDate(date.adjustDate(new Date(), { year,month: month,days: 1}), 'YYYY/MM/DD')
dateRangeC.from = date.formatDate(date.adjustDate(new Date(), { days: 1 }), 'YYYY/MM/DD')
const dateRangeFormatC = ref(`${dateRangeC.from} - ${dateRangeC.to}`)
search.CStartDate = dateRangeC.from
search.CEndDate = dateRangeC.to
const methods = {
......@@ -78,7 +84,7 @@ export default defineComponent({
realSearch.CEndDate=search.CEndDate
realSearch.TCNUM=search.TCNUM
realSearch.OrderState=search.OrderState ? search.OrderState.Id : ''
realSearch.PayStatus=search.PayStatus ? search.PayStatus.value : ''
realSearch.PayStatus=search.PayStatus ? search.PayStatus.value : -1
},
dateRangeHandler(e: any) {
search.QStartDate = `${e.from.year}/${e.from.month}/${e.from.day}`
......@@ -89,11 +95,11 @@ export default defineComponent({
dateRangeHandlerC(e: any) {
search.CStartDate = `${e.from.year}/${e.from.month}/${e.from.day}`
search.CEndDate = `${e.to.year}/${e.to.month}/${e.to.day} `
dateRangeFormat.value = `${search.CStartDate} - ${search.CEndDate} `
dateRangeFormatC.value = `${search.CStartDate} - ${search.CEndDate} `
if (qDateProxy.value) qDateProxy.value.hide()
},
optionsFn(cd: any) {
return cd >= date.formatDate(date.addToDate(new Date(), { days: 20 }), 'YYYY/MM/DD')
return cd >= date.formatDate(date.adjustDate(new Date(), { year: 1970,month:1, days: 1 }), 'YYYY/MM/DD')
},
initOrders() {
travelService
......
......@@ -41,15 +41,10 @@
<div class="mb-title">
<i class="iconfont icon-jiage"></i><span>团位信息</span>
</div>
<div class="mb">
<span>经济舱: {{ x.YSeat }}</span>
</div>
<div class="mb">
<span>商务舱: {{ x.CSeat }}</span>
</div>
<div class="mb">
<span>头等舱: {{ x.FSeat }}</span>
</div>
<div class="mb bold"><span class="item-title">经济舱:</span><span>{{x.YSeat}} <span class="item-title">剩余:</span>{{x.SurplusYSeatNum}}</span></div>
<div class="mb bold"><span class="item-title">商务舱:</span><span> {{x.CSeat}} <span class="item-title">剩余:</span>{{x.SurplusCSeatNum}}</span></div>
<div class="mb bold"><span class="item-title">头等舱:</span><span> {{x.FSeat}} <span class="item-title">剩余:</span>{{x.SurplusFSeatNum}}</span></div>
</div>
</div>
<div class="col-3">
......
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