10538b88 by zhangmeng

订单头

1 parent 312a6d60
......@@ -19,16 +19,14 @@
<label class="purpleTag" v-if="b.orderType == 2"> {{ language==0?'餐饮订单':'DINING' }}</label>
<label class="pinkTag" v-if="b.orderType == 3"> {{ language==0?'化妆订单':'MakeUp' }}</label>
<label class="yellowTag" v-if="b.orderType == 4"> {{ language==0?'拍摄订单':'Shooting'}}</label>
<label class="yellowTag" v-if="orderType == 6"> {{ language==0?'票务':'Ticket'}}</label>
<label class="bg-primary" v-if="orderType==5"> {{ language==0?'赛事报名':'REGISTRATION' }}</label>
<label class="yellowTag" v-if="!b.orderType">{{ language==0?'赛事报名':'REGISTRATION' }}</label>
<h3 v-if="b.name">{{ b.name }}</h3>
<h3 v-if="b.cptName">{{ b.cptName }}</h3>
<div v-if="!b.orderType">
<div v-if="!b.orderType&&orderType==5">
<p v-if="b.groupName">{{ language==0?'团队名称':'Team name' }}{{b.groupName}}</p>
<p v-if="b.payTime">{{ language==0?'支付时间':'Payment time' }}{{b.payTime}}</p>
<p class="poPrice" v-if="b.totalPayAmount">{{ b.paymentType==3?'€' :'¥' }} {{b.totalPayAmount}}</p>
<p class="poPrice" v-if="b.totalPayAmount">{{paymentType!=2?'¥':'€'}} {{b.totalPayAmount}}</p>
</div>
<!-- 酒店订单-->
<div v-if="b.orderType == 0">
......@@ -63,6 +61,17 @@
</div>
</div>
<div class="border-info" v-if="orderType==6">
<label class="blueTag" >{{language==0?'票务订单':'Ticket'}}</label>
<h3>{{ formDate.name }}</h3>
<div>
<p>地点:{{formDate.placeName}}</p>
<p>单价:{{formDate.singlePrice}}</p>
<p>数量:{{formDate.seatList?.length}}</p>
<p class="poPrice">{{paymentType!=2?'¥':'€'}}{{formDate.payAmount}}</p>
</div>
</div>
<div class="leftboderTT">{{ language == 0 ? '开票信息' : 'Invoice information' }}</div>
<div class="border-rr mt20 pd20">
<el-form class="mw500" :model="form" :label-width="language == 0 ?'100':'150'" :rules="rules" ref="formRef">
......@@ -169,6 +178,9 @@ import {
getInvoiceDetail,
submitCptInvoice, getBaseInfoByActiveId, getLeagueInvoiceDetail, getLeagueInvoiceDetailPC,getInvoiceDetailMatch
} from "@/apiPc/booking";
import {getOrderDetail} from "@/viewsPc/seat/api/index";
const {proxy} = getCurrentInstance()
const user = useUserStore().user
......@@ -179,6 +191,7 @@ const form = ref({
invoiceForm: '1',
invoiceType: '0'
})
const formDate = ref({})
const orderType=ref(1)
const paymentType=ref(1)
const list = ref([])
......@@ -222,7 +235,6 @@ let cptId
onMounted(() => {
console.log(route.query)
orderType.value=route.query.orderType
paymentType.value=route.query.paymentType
if(route.query.orders){
......@@ -276,16 +288,21 @@ onMounted(() => {
}
})
async function getDataInfo(){
const res =await getOrderDetail({orderSn:route.query.orderSn})
formDate.value=res.data
}
function getList() {
if(route.query.type=='5'){
getLeagueInvoiceDetailPC(invoiceId).then(res => {
// 订单
list.value = res.data;
list.value = res.rows
console.log(list.value)
cptId = res.rows[0].activeId||res.rows[0].cptId
getRemark()
for (var bill of list.value) {
bill.messageObj = JSON.parse(bill.message)
if (bill.messageObj)bill.messageObj = JSON.parse(bill.message)
}
});
} else {
......
......@@ -18,8 +18,14 @@
<label class="purpleTag" v-if="b.orderType == 2"> 餐饮订单</label>
<label class="pinkTag" v-if="b.orderType == 3">化妆订单</label>
<label class="yellowTag" v-if="b.orderType == 4">拍照订单</label>
<label class="yellowTag" v-if="!b.orderType">{{ language==0?'赛事报名':'REGISTRATION' }}</label>
<h3>{{ b.name }}</h3>
<h3 v-if="b.cptName">{{ b.cptName }}</h3>
<div v-if="!b.orderType&&orderType==5">
<p v-if="b.groupName">{{ language==0?'团队名称':'Team name' }}{{b.groupName}}</p>
<p v-if="b.payTime">{{ language==0?'支付时间':'Payment time' }}{{b.payTime}}</p>
<p class="poPrice" v-if="b.totalPayAmount">{{paymentType!=2?'¥':'€'}} {{b.totalPayAmount}}</p>
</div>
<!-- 酒店订单-->
<div v-if="b.orderType == 0">
<p>{{b.messageObj.roomInfo}}</p>
......@@ -52,7 +58,16 @@
<p class="poPrice">{{ b.paymentType==3?'€' :'¥' }}{{b.totalStr}}</p>
</div>
</div>
<div class="border-info" v-if="orderType==6">
<label class="blueTag" >票务订单</label>
<h3>{{ formDate.name }}</h3>
<div>
<p>地点:{{formDate.placeName}}</p>
<p>单价:{{formDate.singlePrice}}</p>
<p>数量:{{formDate.seatList?.length}}</p>
<p class="poPrice">{{paymentType!=2?'¥':'€'}}{{formDate.payAmount}}</p>
</div>
</div>
<div class="leftboderTT">{{ language == 0 ? '开票信息' : 'Invoice information' }}</div>
<div class="border-rr mt20 pd20">
<el-form class="mw500" :model="form" :label-width="language == 0 ?'100':'150'" :rules="rules" ref="formRef">
......@@ -125,8 +140,17 @@ import dayjs from 'dayjs'
import {ElMessage,ElMessageBox} from "element-plus";
import useUserStore from "@/store/modules/user";
import {getCurrentInstance} from "@vue/runtime-core";
import {addressList, editInvoice, submitInvoice,getInvoiceDetailBills,getInvoiceDetail,getInvoiceDetailMatch} from "@/apiPc/booking";
import {
addressList,
editInvoice,
submitInvoice,
getInvoiceDetailBills,
getInvoiceDetail,
getInvoiceDetailMatch,
getLeagueInvoiceDetailPC
} from "@/apiPc/booking";
import {submitTitckInvoice, invoice, TitckUpdateInvoice} from '@/viewsPc/seat/api/index'
import {getOrderDetail} from "@/viewsPc/seat/api/index";
const {proxy} = getCurrentInstance()
......@@ -141,6 +165,7 @@ const nowAddress = ref({})
const totalMoney = ref(0)
const orderType=ref(0)
const form = ref({})
const formDate = ref({})
const rules = ref({
invoiceType: [
{required: true, message: language.value==0?'请选择发票类型':'Please select invoice type', trigger: 'change'}
......@@ -179,16 +204,32 @@ onMounted(() => {
paymentType.value=route.query.paymentType
invoiceId = route.query.invoiceId
getList()
route.query.orderSn&&getDataInfo()
})
async function getDataInfo(){
const res =await getOrderDetail({orderSn:route.query.orderSn})
formDate.value=res.data
}
function getList() {
getInvoiceDetailBills(invoiceId).then(res => {
// 订单
list.value = res.rows;
for (var bill of list.value) {
bill.messageObj = JSON.parse(bill.message)
}
});
if(route.query.type=='5'){
getLeagueInvoiceDetailPC(invoiceId).then(res => {
// 订单
list.value = res.rows
console.log(list.value)
for (var bill of list.value) {
if (bill.messageObj)bill.messageObj = JSON.parse(bill.message)
}
});
} else{
getInvoiceDetailBills(invoiceId).then(res => {
// 订单
list.value = res.rows;
for (var bill of list.value) {
bill.messageObj = JSON.parse(bill.message)
}
});
}
if (orderType.value==6){
invoice(invoiceId).then(res=>{
// console.log(res)
......
......@@ -251,6 +251,7 @@ onMounted(() => {
}
query.value.orderType= activeName.value=userStore.activeName||'5'
getList()
route.query.orderSn&&getDataInfo()
})
const getList = () => {
loading.value = true
......@@ -304,7 +305,8 @@ const gokp = (item) => {
orders: encodeURIComponent(JSON.stringify(item)),
totalMoney:item.totalStr||item.totalPayAmount||item.payAmount||item.totalAmount,
paymentType:query.value.orderType==6||query.value.orderType==5?item.payType:item.paymentType,
orderType:query.value.orderType
orderType:query.value.orderType,
orderSn:query.value.orderType==6?item.orderSn:null
}
})
}
......@@ -317,6 +319,7 @@ const editkp = (item) => {
isEdit:true,
orderType:query.value.orderType,
paymentType:query.value.orderType==6||query.value.orderType==5?item.payType:item.paymentType,
orderSn:query.value.orderType==6?item.orderSn:null
}
})
}
......@@ -328,6 +331,7 @@ const showDetail = (item) => {
type:activeName.value,
orderType:query.value.orderType,
paymentType:query.value.orderType==6||query.value.orderType==5?item.payType:item.paymentType,
orderSn:query.value.orderType==6?item.orderSn:null
}
})
}
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!