d4a4afaf by zrj

9.1 sjs 合并上传功能

1 parent 64152076
......@@ -159,6 +159,15 @@ export function renewalProof(data) {
})
}
export function mergeBind(orderIds,data) {
return request({
url: `/ota/norder/mergeBind/${orderIds}`,
method: 'post',
params: data
})
}
export function getInvoiceByActiveId(query) {
return request({
url: `/ota/invoice/list`,
......
......@@ -2,7 +2,7 @@
<div class="pd20">
<div style="margin-bottom: 20px">
<el-button type="primary" @click="downloadAll">{{ language == 0 ? '合并生成缴费单' : 'Download Consolidated Invoice' }}</el-button>
<!-- <el-button type="primary" @click="showDialog">合并上传缴费单</el-button>-->
<el-button type="primary" @click="showDialog">合并上传缴费单</el-button>
</div>
<div v-for="b in list" class="item">
<div class="title">
......@@ -170,7 +170,7 @@
<script setup>
import dayjs from "dayjs";
import {useStorage} from "@vueuse/core";
import {cancelOrder, cancelOrder2,renewalProof} from "/@/apiPc/booking";
import {cancelOrder, cancelOrder2,renewalProof,mergeBind} from "/@/apiPc/booking";
import {ElMessage} from "element-plus";
import {getCurrentInstance} from "@vue/runtime-core";
import {ref} from "vue";
......@@ -305,22 +305,24 @@ const show = ref(false)
const pf = ref([])
const submitProofAll = () => {
console.log(pf.value)
// //提交凭证
// if (!pf.value) {
// ElMessage.warning(language.value == 0 ? '请上传凭证' : 'Please upload a voucher')
// return
// }
// booking.renewalProof({
// id: orderId.value,
// pic: form.value.pic[0]?.url
// }).then(res => {
// ElMessage.success({
// message: language.value == 0 ? '凭证提交成功' : 'Voucher submission successful',
// type: 'success'
// })
// getData()
// })
let selectList = props.list.filter(item => item.ischeck==true)
let ids = selectList.map(item => item.id)
if (!pf.value) {
ElMessage.warning(language.value == 0 ? '请上传凭证' : 'Please upload a voucher')
return
}
let urlList = pf.value.map(item => item.url)
let idStr = ids.join(',')
let urlStr = urlList.join(',')
//提交凭证
mergeBind(idStr, {fileUrl: urlStr})
.then(res => {
ElMessage.success({
message: language.value == 0 ? '凭证提交成功' : 'Voucher submission successful',
type: 'success'
})
getData()
})
}
const showDialog = () => {
......
<template>
<el-dialog v-model="show" :title="title" @close="close">
<el-dialog v-model="show" :title="title" @close="close" >
<div>
<h2 v-if="cptName && type!=10" class="text-warning text-center">{{ cptName }}</h2>
......@@ -19,7 +19,7 @@
<!-- </span>-->
<!-- </el-link>-->
<div v-if="content" v-html="content"/>
<div class="or-html" v-if="content" v-html="content"/>
</div>
......@@ -87,7 +87,7 @@ function getData() {
content.value = res.data.contextEn
fileList.value = JSON.parse(res.data.fileEn)
}
content.value = `<style>img { display: inline-block; }</style>` + content.value
content.value = `<style>img { display: inline-block; } @media (max-width: 1750px){video{ width: auto;height: auto;}}</style>` + content.value
} else {
content.value = ''
fileList.value = []
......@@ -121,5 +121,4 @@ function ok() {
</script>
<style lang="scss" scoped>
</style>
......
......@@ -84,8 +84,8 @@ export default defineConfig(({mode, command}) => {
},
'/dev-api': {
// target: 'http://192.168.1.118:8082/',
// target: 'http://192.168.1.22:8082',
target: 'https://tk005.wxjylt.com/stage-api',
target: 'http://192.168.1.52:8082',
// target: 'https://tk005.wxjylt.com/stage-api',
// target: 'http://124.70.181.90:1880/stage-api',
// target: 'https://sys.2025wtcwuxi.com/stage-api/',
changeOrigin: true,
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!