530e2dbb by 杨炀

Merge branch 'dev' into order

大师课申请
2 parents 9dc18f50 bb4313de
......@@ -217,6 +217,7 @@ onMounted(() => {
function changeUseType(e) {
console.log(form.value.useType)
changecarNum()
console.log(form.value)
}
function changecarNum(e) {
......@@ -251,8 +252,9 @@ function initDays() {
}
function disabledDate(date) {
// const today = dayjs().format('YYYY-MM-DD')
if (form.value.carStart) {
return date.getTime() > dayjs(form.value.carStart).valueOf()
if (lform.value.carStart) {
return (date.getTime() < dayjs(lform.value.carStart).valueOf())||(date.getTime() > dayjs(lform.value.carEnd).valueOf())
}
return true
}
......
......@@ -83,11 +83,9 @@
</template>
<script setup>
import {useRouter} from "vue-router";
import {ref, reactive, onMounted} from "vue";
import {useRoute} from "vue-router";
import {getHotelById, getMenuById} from "@/apiPc/booking"
import {useRouter,useRoute} from "vue-router";
import {ref, onMounted} from "vue";
import { getMenuById} from "@/apiPc/booking"
import {useStorage} from "@vueuse/core/index";
import useUserStore from "@/store/modules/user";
import {fillImgUrl} from "@/utils/ruoyi";
......@@ -98,7 +96,7 @@ const router = useRouter()
const route = useRoute()
const form = ref({})
const query = ref({
larId: route.query.id
larId: route.params.id
})
const loading = ref(false)
const roomList = ref([])
......@@ -106,11 +104,13 @@ const map = ref(null)
onMounted(() => {
form.value = JSON.parse(decodeURIComponent(route.query.detail))
getData()
})
function getData() {
loading.value = true
query.value.hotelId = route.query.id
console.log(query.value)
getMenuById(query.value).then(res => {
loading.value = false
roomList.value = res.rows
......
......@@ -242,6 +242,7 @@ function submit() {
form.value.foodsList.push(obj)
form.value.activeId = restaurant.value.activityId
form.value.larId = restaurant.value.id
form.value.orderName=restaurant.value.name
// 提交确认
ElMessageBox.confirm(language.value == 0 ? '确认提交订单吗?' : 'Confirm to submit the order?', {
confirmButtonText: language.value == 0 ? '确定' : 'Confirm',
......
......@@ -241,9 +241,12 @@ function initMap() {
}
function goOrder(room) {
checkRoomPayByUserId(room.hotelId).then(res=>{
if(res.data == -100){
ElMessageBox.confirm(
ElMessageBox.confirm(language.value == 0 ? '你当前选择的入住时间为'+hotTime.value[0]+'至'+hotTime.value[1]+',是否确定?':'Your current check-in time is'+hotTime.value[0]+'~'+hotTime.value[1]+'Are you sure?',{type:'warning'}).then({
}).then(()=>{
checkRoomPayByUserId(room.hotelId).then(res=>{
if(res.data == -100){
ElMessageBox.confirm(
language.value == 0 ?'你有未支付的酒店订单,是否前往个人中心查看':'You already have an unpaid hotel order, do you want to go to the personal center to check it?',
language.value==0?'提示':'Warning',
{
......@@ -251,21 +254,24 @@ function goOrder(room) {
// cancelButtonText: language.value==1?'Continue to book':'继续预订',
type: 'warning',
}
).then((res) => {
console.log(res)
router.push({
name:'myReservation',
).then((res) => {
console.log(res)
router.push({
name:'myReservation',
})
})
})
// .catch((res) => {
// console.log(res)
// goNext(room)
// })
return
}
goNext(room)
// .catch((res) => {
// console.log(res)
// goNext(room)
// })
return
}
goNext(room)
})
})
}
function goNext(room) {
router.push({
......
......@@ -90,16 +90,16 @@
</div>
<div class="text-right">
<el-button v-if="b.orderType == 0&&b.viewStatus!=0" class="mb10" plain round type="success" @click="Rebook(b)">
<el-button v-if="b.orderType == 0&&b.viewStatus!=0" class="mb10" plain round type="success" size="small" @click="Rebook(b)">
{{ language==0?'再次预订':'Rebook' }}</el-button>
<el-button class="mb10" plain round type="primary" @click="goDetail(b)">
<el-button class="mb10" plain round type="primary" size="small" @click="goDetail(b)">
{{ language==0?'详情':'Detail' }}</el-button>
<el-button v-if="b.status == '0'&&(b.surplus!='0,0'&&b.surplus!='0')" @click="goDetail(b)"
class="mb10" plain round type="primary" >
class="mb10" plain round type="primary" size="small" >
{{ language==0?'支付':'Pay' }}</el-button>
<el-button v-if="b.viewStatus==0" @click="cancel(b)" class="mb10" plain round type="warning" >
<el-button v-if="b.viewStatus==0" @click="cancel(b)" class="mb10" plain round type="warning" size="small" >
{{ language==0?'取消订单':'Cancel Order' }}</el-button>
<el-button v-if="b.viewStatus==5" @click="unsubscribe(b)" class="mb10" plain round type="" >
<el-button v-if="b.viewStatus==5" @click="unsubscribe(b)" class="mb10" plain round type="" size="small" >
{{ language==0?'退订':'Unsubscribe' }}</el-button>
</div>
</el-col>
......
......@@ -97,12 +97,12 @@ function building() {
return
}
function popRemark(type){
// debugger
if(!form.value){
building()
return
}
if((form.value.isJdView == 0&&type=='1') || (form.value.isCarView == 0&&type=='2') || (form.value.isFoodView == 0&&type=='3') || (form.value.isMealView == 0&&type=='4') || (type=='5'&&form.value.isPhotoView == 0)){
//type == '0'
building()
return
}
......
......@@ -617,8 +617,11 @@ function removeCurproject() {
function checkTwo(a,b) {
match.checkMate({per1Id:a.id,per2Id:b.id,cptId:matchId.value}).then(res=>{
if(!res.data){
// ElMessage.warning(language.value == 0 ? '他们不是固定组合':'They\'re not a couple')
ElMessage.warning(language.value == 0 ? `${a.realName} 已经和其他人组成舞伴,无法报名,请重新选择`:`${a.realName} has already formed a dancer with another person, cannot sign up: please select again`)
if(isNational.value){
ElMessage.warning(language.value == 0 ? '他们不是固定组合':'They\'re not a couple')
} else {
ElMessage.warning(language.value == 0 ? `${a.realName}/${b.realName} 已经和其他人组成舞伴,无法报名,请重新选择`:`${a.realName}/${b.realName} has already formed a dancer with another person, cannot sign up: please select again`)
}
}
})
}
......
......@@ -70,7 +70,7 @@
</el-radio-group>
</el-form-item>
<el-form-item :label="language==0?'出生日期':'Date of Birth'">
<el-form-item :label="language==0?'出生日期':'Date of Birth'" required>
<el-date-picker
v-model="form.birth"
style="width: 100%;"
......@@ -88,7 +88,7 @@
</div>
</el-form-item>
<el-form-item :label="language==0?'证件号':'Passport number'">
<el-form-item :label="language==0?'证件号':'Passport number'" required>
<el-input v-model="form.passportNumber"/>
</el-form-item>
......@@ -218,10 +218,14 @@ watch(show, (value) => {
})
function submitForm() {
// if (!form.value.passportNumber) {
// ElMessage.warning('Please fill in your passport number')
// return
// }
if (!form.value.passportNumber) {
ElMessage.warning(language.value == 0 ?'请输入你的证件号':'Please fill in your passport number')
return
}
if (!form.value.birth) {
ElMessage.warning(language.value == 0 ?'请输入你的出生日期':'Please fill in your birthday')
return
}
// if (!form.value.picUrl) {
// ElMessage.warning('Please upload your photo')
// return
......@@ -246,10 +250,6 @@ function submitForm() {
emit('submitForm')
})
} else {
// if (!form.value.birth) {
// ElMessage.warning('Please fill in your birthday')
// return
// }
if (Array.isArray(form.value.passportUrl)) {
form.value.passportUrl = form.value.passportUrl[0].url
}
......
......@@ -234,7 +234,11 @@ function handleSelectionChange(val) {
function checkTwo(a,b) {
match.checkMate({per1Id:a.id,per2Id:b.id,cptId:matchId}).then(res=>{
if(!res.data){
ElMessage.warning(language.value == 0 ? `${a.realName} 已经和其他人组成舞伴,无法报名:请重新选择`:`${a.realName} has already formed a dancer with another person, cannot sign up: please select again`)
if(isNational.value){
ElMessage.warning(language.value == 0 ? '他们不是固定组合':'They\'re not a couple')
} else {
ElMessage.warning(language.value == 0 ? `${a.realName} 已经和其他人组成舞伴,无法报名:请重新选择`:`${a.realName} has already formed a dancer with another person, cannot sign up: please select again`)
}
proxy.$refs['allSportmenTable'].clearSelection()
}
})
......
......@@ -80,11 +80,11 @@
application of visa invitation letter and purchasing insurance etc.</span>
</div>
</el-form-item>
<el-form-item :label="language==0?'证件号':'Passport number'">
<el-form-item :label="language==0?'证件号':'Passport number'" required>
<el-input v-model="wdsfData.passportNumber"/>
</el-form-item>
<el-form-item :label="language==0?'出生日期':'Date of Birth'">
<el-form-item :label="language==0?'出生日期':'Date of Birth'" required>
<el-date-picker
v-model="wdsfData.birthday"
style="width: 100%;"
......@@ -317,10 +317,14 @@ function goBack() {
router.go(-1)
}
function bigNext(){
// if (!wdsfData.value.passportNumber) {
// ElMessage.warning(language.value == 0 ?'请填写护照号':'Please fill in your passport number')
// return
// }
if (!wdsfData.value.passportNumber) {
ElMessage.warning(language.value == 0 ?'请填写护照号':'Please fill in your passport number')
return
}
if (!wdsfData.value.birthday) {
ElMessage.warning(language.value == 0 ?'请填写出生年月':'Please fill in your birthday')
return
}
if (!wdsfData.value.passportUrl) {
ElMessage.warning(language.value == 0 ? '请上传护照文件' : 'Please upload your passport file')
......
......@@ -224,7 +224,12 @@ order.fetchData();
<div class="detail">
<div class="detail_top">
<div class="time">{{ order.data?.dateStr }}</div>
<div class="time">
{{ order.data?.dateStr }}
<span v-if="order.data?.ticketType == 1" class="tag_t">
{{ languageFormat(language, "套票", "Package ticket") }}
</span>
</div>
<div class="ticket">
{{ order.data?.singlePrice }}<span v-if="language == 0"></span
>{{ languageFormat(language, "票档", "Ticket file") }} x{{
......@@ -300,6 +305,15 @@ div {
padding: 20px 0;
width: 1200px;
margin: 0 auto;
.tag_t {
padding: 1px 10px;
font-weight: 400;
font-size: 12px;
color: #493ceb;
border-radius: 6px;
border: 1px solid #453dea;
margin-left: 5px;
}
.title {
padding: 11px;
......
......@@ -295,7 +295,12 @@ detail.fetchData();
</div>
<div class="tr">
<div style="width: 30.33%" class="td flex-col">
<div>{{ detail.data?.dateStr }}</div>
<div>
{{ detail.data?.dateStr }}
<span v-if="detail.data?.ticketType == 1" class="tag_t">
{{ languageFormat(language, "套票", "Package ticket") }}
</span>
</div>
<div>
{{
detail.data?.openType == 0
......@@ -337,7 +342,7 @@ detail.fetchData();
<!-- 购票人 -->
<div class="pay_ticket">
<div class="title">
{{ languageFormat(language, "购票人", "Full Name") }}
{{ languageFormat(language, "观看人", "Viewers") }}
</div>
<div class="people">
<div
......@@ -537,6 +542,15 @@ detail.fetchData();
flex-direction: column;
gap: 16px;
}
.tag_t {
padding: 1px 10px;
font-weight: 400;
font-size: 12px;
color: #493ceb;
border-radius: 6px;
border: 1px solid #453dea;
margin-left: 5px;
}
}
}
// 购票人
......
......@@ -68,15 +68,15 @@ function onWindowMessage(e) {
if (route.query.sitePlace == "B6") {
// 绘制舞台矩形
sendMsg("draw-object-rectangle", {
x: 1800,
x: 2640,
y: 960,
w: 4400,
w: 2540,
h: 1300,
color: "#e0e0e0",
});
// 绘制舞台文字
sendMsg("draw-object-text", {
x: 3900,
x: 3760,
y: 1500,
text: language.value == 0 ? "舞台" : "stage",
style: { fontSize: 160, fontWeight: "400", fill: "#6a6a6a" },
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!