|
|
|
|
@ -1,5 +1,5 @@ |
|
|
|
|
<script setup> |
|
|
|
|
import {onBeforeMount, ref} from 'vue'; |
|
|
|
|
import {onBeforeMount, ref, reactive} from 'vue'; |
|
|
|
|
import {get_ai_show_data} from "@/apis/ai_show.js"; |
|
|
|
|
|
|
|
|
|
// region 表格数据代码 |
|
|
|
|
@ -9,11 +9,14 @@ const hallArray = ref([]) |
|
|
|
|
|
|
|
|
|
// 表格展示的数据 |
|
|
|
|
const showData = ref([]) |
|
|
|
|
const hallType = ref({}) |
|
|
|
|
const prompt = ref('') |
|
|
|
|
const tokens = ref(0) |
|
|
|
|
const takeTimes = ref(0) |
|
|
|
|
const realSales = ref('') |
|
|
|
|
const aiSales = ref('') |
|
|
|
|
const realCount = ref('') |
|
|
|
|
const aiCount = ref('') |
|
|
|
|
const showResult = ref('') |
|
|
|
|
const templateDate = ref('') |
|
|
|
|
const result = ref(false) |
|
|
|
|
@ -33,6 +36,8 @@ async function get_data() { |
|
|
|
|
realSales.value = '' |
|
|
|
|
aiSales.value = '' |
|
|
|
|
showResult.value = '' |
|
|
|
|
realCount.value = '' |
|
|
|
|
aiCount.value = '' |
|
|
|
|
templateDate.value = '' |
|
|
|
|
result.value = false |
|
|
|
|
await get_ai_show_data(cinema_code.value, show_date.value, force.value).then(res => { |
|
|
|
|
@ -45,6 +50,9 @@ async function get_data() { |
|
|
|
|
aiSales.value = res.data.ai_sales |
|
|
|
|
showResult.value = res.data.result |
|
|
|
|
templateDate.value = res.data.template_date |
|
|
|
|
hallType.value = res.data.hall_type |
|
|
|
|
realCount.value = res.data.real_count |
|
|
|
|
aiCount.value = res.data.ai_count |
|
|
|
|
if (templateSwitch.value) { |
|
|
|
|
showData.value = res.data.template_obj |
|
|
|
|
} else { |
|
|
|
|
@ -69,7 +77,7 @@ function formatTableData() { |
|
|
|
|
let temp = 0; |
|
|
|
|
showData.value.forEach((item, index) => { |
|
|
|
|
tableData.value.push({ |
|
|
|
|
hall: item[0], |
|
|
|
|
hall: item[0] + '\n\n支持制式:' + hallType.value[item[0]], |
|
|
|
|
ai_show: item[2], |
|
|
|
|
ai_language: item[4], |
|
|
|
|
ai_start: item[5], |
|
|
|
|
@ -235,6 +243,17 @@ onBeforeMount( |
|
|
|
|
<el-text>{{ tokens }}</el-text> |
|
|
|
|
</el-col> |
|
|
|
|
</el-row> |
|
|
|
|
<el-row> |
|
|
|
|
<el-col :span="3" align="right"> |
|
|
|
|
<el-text style="font-weight: bold">排片占比(AI/真实):</el-text> |
|
|
|
|
</el-col> |
|
|
|
|
<el-col :span="8" align="left"> |
|
|
|
|
<el-text>{{ aiCount }}</el-text> |
|
|
|
|
</el-col> |
|
|
|
|
<el-col :span="8" align="left"> |
|
|
|
|
<el-text>{{ realCount }}</el-text> |
|
|
|
|
</el-col> |
|
|
|
|
</el-row> |
|
|
|
|
<el-row> |
|
|
|
|
<el-col :span="3" align="right"> |
|
|
|
|
<el-text style="font-weight: bold">AI返回结果:</el-text> |
|
|
|
|
@ -258,4 +277,8 @@ onBeforeMount( |
|
|
|
|
.el-text { |
|
|
|
|
white-space: pre-wrap; /* 或者使用 pre-line */ |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.el-table .cell { |
|
|
|
|
white-space: pre-line; |
|
|
|
|
} |
|
|
|
|
</style> |
|
|
|
|
|