update:运动馆
This commit is contained in:
parent
de386c2fce
commit
8892ddf0b3
@ -16,3 +16,8 @@ export function getSportsHallStudentsTestPageList(params) {
|
||||
export function scorePush(params) {
|
||||
return http.post('/api/SportsHall/ScorePush', params)
|
||||
}
|
||||
|
||||
// 成绩修正
|
||||
export function correctScore(params) {
|
||||
return http.post('/api/SportsHall/ScoreUpdate', params)
|
||||
}
|
||||
|
||||
@ -37,7 +37,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="cont">
|
||||
<el-table :data="data.tableNeed.tableData" style="width: calc(100% - 40px) ;height: calc(100vh - 210px); margin:0 20px ;"
|
||||
<el-table :data="data.tableNeed.tableData" style="width: calc(100% - 40px) ;height: 580px; margin:0 20px ;margin-bottom: 20px;"
|
||||
fit="true"
|
||||
:header-cell-style="{ 'text-align': 'center', 'font-size': '12px', 'color': '#3F404A', padding: '3px', background: '#F8F8FA', height: '50px' }"
|
||||
:cell-style="getCellStyles" :row-style="{ height: '0px' }">
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
<template>
|
||||
<div class="sport-hall-report">
|
||||
|
||||
<!-- 搜索区域 -->
|
||||
<div class="search-card">
|
||||
<div class="search-row">
|
||||
@ -124,11 +123,11 @@
|
||||
</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column label="操作" width="100" align="center" fixed="right">
|
||||
<el-table-column label="操作" width="100" align="center" fixed="right">
|
||||
<template #default="{ row }" width="100">
|
||||
<el-button type="primary" link @click="handleEdit(row)">成绩修正</el-button>
|
||||
<el-button type="primary" link :disabled="row.isDisplay" @click="handleEdit(row)">成绩修正</el-button>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<!-- 分页 -->
|
||||
@ -222,7 +221,7 @@
|
||||
<script setup lang="ts">
|
||||
import { ref, reactive, onMounted } from 'vue'
|
||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
import { importSportsHallStudentsTestData, getSportsHallStudentsTestPageList, scorePush as scorePushApi } from '@/api/sportsHall'
|
||||
import { importSportsHallStudentsTestData, getSportsHallStudentsTestPageList, scorePush as scorePushApi, correctScore } from '@/api/sportsHall'
|
||||
import { GetGradeNames } from '@/api/grade'
|
||||
|
||||
// ===================== 查询参数 =====================
|
||||
@ -415,6 +414,7 @@ const editDialog = reactive({ visible: false })
|
||||
const editFormRef = ref()
|
||||
const editForm = reactive({
|
||||
id: null as any,
|
||||
studentNo: '' as any,
|
||||
studentName: '',
|
||||
bmi: '' as any,
|
||||
lungCapacity: '' as any,
|
||||
@ -427,6 +427,7 @@ const editForm = reactive({
|
||||
const handleEdit = (row: any) => {
|
||||
Object.assign(editForm, {
|
||||
id: row.id,
|
||||
studentNo: row.studentNo,
|
||||
studentName: row.studentName,
|
||||
bmi: row.bmiValue ?? '',
|
||||
lungCapacity: row.vitalCapacityValue ?? '',
|
||||
@ -440,8 +441,16 @@ const handleEdit = (row: any) => {
|
||||
|
||||
const handleEditConfirm = async () => {
|
||||
try {
|
||||
// TODO: 调用成绩修正接口
|
||||
// await updateSportHallScore(editForm)
|
||||
const params: any = {
|
||||
studentNo: editForm.studentNo
|
||||
}
|
||||
if (editForm.bmi !== '' && editForm.bmi !== null) params.bmiValue = Number(editForm.bmi)
|
||||
if (editForm.lungCapacity !== '' && editForm.lungCapacity !== null) params.vitalCapacityValue = Number(editForm.lungCapacity)
|
||||
if (editForm.sitAndReach !== '' && editForm.sitAndReach !== null) params.sit_And_ReachValue = Number(editForm.sitAndReach)
|
||||
if (editForm.ropeSkipping !== '' && editForm.ropeSkipping !== null) params.oneMinuteJumpRopeValue = Number(editForm.ropeSkipping)
|
||||
if (editForm.sitUp !== '' && editForm.sitUp !== null) params.one_Minute_Sit_UpValue = Number(editForm.sitUp)
|
||||
if (editForm.standingLongJump !== '' && editForm.standingLongJump !== null) params.standingLongJumpValue = Number(editForm.standingLongJump)
|
||||
await correctScore(params)
|
||||
ElMessage.success('修正成功')
|
||||
editDialog.visible = false
|
||||
fetchList()
|
||||
|
||||
@ -15,7 +15,7 @@ export default ({ mode }: ConfigEnv) => {
|
||||
console.log(`ENV:`, ENV)
|
||||
|
||||
return defineConfig({
|
||||
base: 'https://yuedong-wechatapplet.oss-cn-shanghai.aliyuncs.com/static/web/samart-static/202604241737/',
|
||||
base: 'https://yuedong-wechatapplet.oss-cn-shanghai.aliyuncs.com/static/web/samart-static/202604271325/',
|
||||
server: {
|
||||
host: '0.0.0.0',
|
||||
// https: false,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user