Compare commits

..

6 Commits

Author SHA1 Message Date
yj 6958d82eba 优化
部署开发环境 / 编译发布 (push) Successful in 1m28s Details
2024-06-14 17:47:52 +08:00
yj f861057216 优化
部署开发环境 / 编译发布 (push) Successful in 1m59s Details
2024-06-14 17:06:13 +08:00
yj 3ee5ee3b6d 优化
部署开发环境 / 编译发布 (push) Successful in 2m0s Details
2024-06-14 15:48:02 +08:00
qxa 81a1ac5326 1
部署开发环境 / 编译发布 (push) Successful in 1m50s Details
2024-06-14 11:26:57 +08:00
qxa 6e34ed2e21 1
部署开发环境 / 编译发布 (push) Failing after 2m11s Details
2024-06-14 11:18:34 +08:00
qxa a2d0e8dd91 1
部署开发环境 / 编译发布 (push) Failing after 3m11s Details
2024-06-14 11:12:14 +08:00
5 changed files with 27 additions and 18 deletions

View File

@ -1,7 +1,7 @@
version: "3" version: "3"
services: services:
usercenter-web: maketemplate:
image: ${REGISTRY:-harbor.w.23544.com:8843}/marking/maketemplate.web:${TAG:-latest} image: ${REGISTRY:-harbor.w.23544.com:8843}/marking/maketemplate.web:${TAG:-latest}
hostname: marking hostname: marking
environment: environment:

View File

@ -9,11 +9,15 @@
> >
<div> <div>
<div style="font-size: 20px; margin-bottom: 20px; font-weight: bold"> <div style="font-size: 20px; margin-bottom: 20px; font-weight: bold">
锁定模板后仅可调整位置和大小无法增删题目请确认模板信息后操作 锁定模板后仅可调整位置和大小无法增删题目请确认模板信息后操作
<span style="color: red">(总分:{{ allScore }})</span>
</div> </div>
<div style="height: 70vh; overflow-y: auto"> <div style="height: 70vh; overflow-y: auto">
<el-collapse v-model="activeNames"> <el-collapse v-model="activeNames">
<el-collapse-item :title="item.title" :name="item.key" v-for="item in list"> <el-collapse-item :name="item.key" v-for="item in list">
<template #title>
<span v-html="item.title" style="font-size: 16px"></span>
</template>
<div v-if="item.key !== 'otherPoint'"> <div v-if="item.key !== 'otherPoint'">
<div v-if="item.data.length"> <div v-if="item.data.length">
<div v-for="row in item.data"> <div v-for="row in item.data">
@ -53,6 +57,7 @@ const activeNames = ref([
"otherPoint", "otherPoint",
]); ]);
const list = ref<any>([]); const list = ref<any>([]);
const allScore = ref<number>(0);
const getData = (data: any): void => { const getData = (data: any): void => {
// //
changeData(data); changeData(data);
@ -73,6 +78,8 @@ const changeData = (data: any): void => {
const objectiveQuestionsPoint = [], // const objectiveQuestionsPoint = [], //
subjectiveQuestionsPoint = [], // subjectiveQuestionsPoint = [], //
otherPoint = []; // otherPoint = []; //
let objectiveQuestionsPointScore = 0;
let subjectiveQuestionsPointScore = 0;
for (let index = 0; index < data.length; index++) { for (let index = 0; index < data.length; index++) {
const item = data[index]; const item = data[index];
objectiveQuestionsPoint.push(...item.from.objectiveQuestionsPoint); objectiveQuestionsPoint.push(...item.from.objectiveQuestionsPoint);
@ -82,14 +89,17 @@ const changeData = (data: any): void => {
let objectiveQuestionsPointNumber = 0; let objectiveQuestionsPointNumber = 0;
objectiveQuestionsPoint.forEach((item: any) => { objectiveQuestionsPoint.forEach((item: any) => {
objectiveQuestionsPointNumber += item.questionNumber; objectiveQuestionsPointNumber += item.questionNumber;
objectiveQuestionsPointScore += item.score;
}); });
let subjectiveQuestionsPointNumber = 0; let subjectiveQuestionsPointNumber = 0;
subjectiveQuestionsPoint.forEach((item: any) => { subjectiveQuestionsPoint.forEach((item: any) => {
subjectiveQuestionsPointNumber += item.questionAfter - item.questionBefore + 1; subjectiveQuestionsPointNumber += item.questionAfter - item.questionBefore + 1;
subjectiveQuestionsPointScore += item.score;
}); });
params[0].title = `客观题:${objectiveQuestionsPointNumber}`; allScore.value = objectiveQuestionsPointScore + subjectiveQuestionsPointScore;
params[0].title = `客观题:共${objectiveQuestionsPointNumber}题 <span style="color: red;font-weight:bold;">总分:${objectiveQuestionsPointScore}分</span>`;
params[0].data = objectiveQuestionsPoint; params[0].data = objectiveQuestionsPoint;
params[1].title = `主观题:${subjectiveQuestionsPointNumber}`; params[1].title = `主观题:${subjectiveQuestionsPointNumber} <span style="color: red;font-weight:bold;">总分:${subjectiveQuestionsPointScore}分</span>`;
params[1].data = subjectiveQuestionsPoint; params[1].data = subjectiveQuestionsPoint;
params[2].title = `其他标记(缺考、屏蔽区、反面定位点)`; params[2].title = `其他标记(缺考、屏蔽区、反面定位点)`;
params[2].data = otherPoint; params[2].data = otherPoint;

View File

@ -1647,7 +1647,7 @@ const showFabricData = (): void => {
hasControls: false, hasControls: false,
subTargetCheck: true, subTargetCheck: true,
borderColor: "transparent", borderColor: "transparent",
selectionBackgroundColor: "rgba(255,0,0,0.5)", selectionBackgroundColor: "rgba(255,0,0,0.1)",
fabricType: item.fabricType, fabricType: item.fabricType,
left: item.left, left: item.left,
top: item.top, top: item.top,
@ -2910,7 +2910,7 @@ const changeData = (): any => {
...row.customFrom, ...row.customFrom,
width: row.width, width: row.width,
height: row.height - 36.16, height: row.height - 36.16,
top: row.top + 17, top: row.top + 19,
left: row.left, left: row.left,
}; };
}); });
@ -2919,7 +2919,7 @@ const changeData = (): any => {
...row.customFrom, ...row.customFrom,
width: row.width, width: row.width,
height: row.height - 36.16, height: row.height - 36.16,
top: row.top + 17, top: row.top + 19,
left: row.left, left: row.left,
}; };
}); });
@ -2928,7 +2928,7 @@ const changeData = (): any => {
...row.customFrom, ...row.customFrom,
width: row.width, width: row.width,
height: row.height - 36.16, height: row.height - 36.16,
top: row.top + 17, top: row.top + 19,
left: row.left, left: row.left,
}; };
}); });
@ -2937,7 +2937,7 @@ const changeData = (): any => {
...row.customFrom, ...row.customFrom,
width: row.width, width: row.width,
height: row.height - 36.16 / 2, height: row.height - 36.16 / 2,
top: row.top + 17, top: row.top + 19,
left: row.left, left: row.left,
}; };
}); });
@ -2997,6 +2997,7 @@ const lock = async (): Promise<void> => {
GetLock(router.currentRoute.value.query.mid as string).then((res: any) => { GetLock(router.currentRoute.value.query.mid as string).then((res: any) => {
if (res.code === 200) { if (res.code === 200) {
ElMessage.success("锁定成功"); ElMessage.success("锁定成功");
isLockStatus.value = true;
} }
}); });
}; };

View File

@ -20,6 +20,11 @@ const request = (config: any) => {
if (method === 'get' || method === 'GET') { if (method === 'get' || method === 'GET') {
config.params = config.data config.params = config.data
} }
if (config.url.includes('/draw')) {
config.baseURL = import.meta.env.VITE_BASE_URL_DRAW_API
} else {
config.baseURL = import.meta.env.VITE_BASE_URL_API
}
return req.request<any>(config) return req.request<any>(config)
} }

View File

@ -27,14 +27,7 @@ export default defineConfig(({ mode }) => {
port: 8080, port: 8080,
host: '0.0.0.0', host: '0.0.0.0',
proxy: { proxy: {
"/api": {
target: env.VITE_BASE_URL_API,
changeOrigin: true
},
"/draw": {
target: env.VITE_BASE_URL_DRAW_API,
changeOrigin: true
},
} }
}, },
resolve: { resolve: {