mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-07 01:46:43 +08:00
feat: 添加分数更新功能
This commit is contained in:
@@ -242,3 +242,5 @@ export const groupMemberList = (obj) => http.post('/admin/studentGroup/groupMemb
|
|||||||
export const delGroupStudent = (obj) => http.post('/admin/studentGroup/delStudent', obj)
|
export const delGroupStudent = (obj) => http.post('/admin/studentGroup/delStudent', obj)
|
||||||
//随机分组
|
//随机分组
|
||||||
export const randomGroup = (obj, projectId) => http.post(`/admin/studentGroup/randomGroup/${projectId}`, obj)
|
export const randomGroup = (obj, projectId) => http.post(`/admin/studentGroup/randomGroup/${projectId}`, obj)
|
||||||
|
// 更新考试分数
|
||||||
|
export const updateScore = (data)=> http.post('/admin/student/updateStudentScore', data)
|
||||||
@@ -6,6 +6,12 @@ body {
|
|||||||
// overflow-y: auto;
|
// overflow-y: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@for $index from 1 through 50 {
|
||||||
|
.mr-#{$index} {
|
||||||
|
margin-right: #{$index}px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//隐藏滚动条----------------------------------------------------------------
|
//隐藏滚动条----------------------------------------------------------------
|
||||||
// div::-webkit-scrollbar {
|
// div::-webkit-scrollbar {
|
||||||
// display: none !important;
|
// display: none !important;
|
||||||
@@ -293,8 +299,8 @@ textarea {
|
|||||||
display: inline-block;
|
display: inline-block;
|
||||||
|
|
||||||
.ant-select:not(.ant-select-customize-input)
|
.ant-select:not(.ant-select-customize-input)
|
||||||
.ant-select-selector
|
.ant-select-selector
|
||||||
.ant-select-selection-search-input {
|
.ant-select-selection-search-input {
|
||||||
background-color: rgba(255, 255, 255, 0);
|
background-color: rgba(255, 255, 255, 0);
|
||||||
border: none;
|
border: none;
|
||||||
}
|
}
|
||||||
@@ -311,7 +317,7 @@ textarea {
|
|||||||
.ant-select-focused:not(.ant-select-disabled).ant-select:not(
|
.ant-select-focused:not(.ant-select-disabled).ant-select:not(
|
||||||
.ant-select-customize-input
|
.ant-select-customize-input
|
||||||
)
|
)
|
||||||
.ant-select-selector {
|
.ant-select-selector {
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -370,6 +376,7 @@ textarea {
|
|||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.drawerMain {
|
.drawerMain {
|
||||||
.header {
|
.header {
|
||||||
height: 73px;
|
height: 73px;
|
||||||
@@ -554,8 +561,8 @@ textarea {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.ant-table-tbody
|
.ant-table-tbody
|
||||||
> tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected)
|
> tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected)
|
||||||
> td {
|
> td {
|
||||||
background: #f6f9fd;
|
background: #f6f9fd;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -634,6 +641,7 @@ textarea {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//弹窗--------------------------------------------------------
|
//弹窗--------------------------------------------------------
|
||||||
.modalStyle {
|
.modalStyle {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
@@ -670,9 +678,9 @@ textarea {
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
height: 68px;
|
height: 68px;
|
||||||
background: linear-gradient(
|
background: linear-gradient(
|
||||||
0deg,
|
0deg,
|
||||||
rgba(78, 166, 255, 0) 0%,
|
rgba(78, 166, 255, 0) 0%,
|
||||||
rgba(78, 166, 255, 0.2) 100%
|
rgba(78, 166, 255, 0.2) 100%
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -689,25 +697,25 @@ textarea {
|
|||||||
.ant-modal {
|
.ant-modal {
|
||||||
.modalHeader {
|
.modalHeader {
|
||||||
background: linear-gradient(
|
background: linear-gradient(
|
||||||
180deg,
|
180deg,
|
||||||
rgba(103, 64, 255, 0.2) 0%,
|
rgba(103, 64, 255, 0.2) 0%,
|
||||||
rgba(166, 168, 255, 0) 100%
|
rgba(166, 168, 255, 0) 100%
|
||||||
) !important;
|
) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.top {
|
.top {
|
||||||
background: linear-gradient(
|
background: linear-gradient(
|
||||||
180deg,
|
180deg,
|
||||||
rgba(103, 64, 255, 0.2) 0%,
|
rgba(103, 64, 255, 0.2) 0%,
|
||||||
rgba(166, 168, 255, 0) 100%
|
rgba(166, 168, 255, 0) 100%
|
||||||
) !important;
|
) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.del_header {
|
.del_header {
|
||||||
background: linear-gradient(
|
background: linear-gradient(
|
||||||
180deg,
|
180deg,
|
||||||
rgba(103, 64, 255, 0.2) 0%,
|
rgba(103, 64, 255, 0.2) 0%,
|
||||||
rgba(166, 168, 255, 0) 100%
|
rgba(166, 168, 255, 0) 100%
|
||||||
) !important;
|
) !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -232,8 +232,16 @@
|
|||||||
@click="auditStatus(2, record.id)"
|
@click="auditStatus(2, record.id)"
|
||||||
type="link"
|
type="link"
|
||||||
>拒绝
|
>拒绝
|
||||||
</a-button
|
</a-button>
|
||||||
>
|
<a-button
|
||||||
|
v-if="checkPer(permissions)"
|
||||||
|
:disabled="record.isLeader === '1'"
|
||||||
|
@click="handleUpdateScore(record.id, record)"
|
||||||
|
type="link"
|
||||||
|
class="mr-10"
|
||||||
|
info
|
||||||
|
>更新
|
||||||
|
</a-button>
|
||||||
<a-button
|
<a-button
|
||||||
v-if="checkPer(permissions)"
|
v-if="checkPer(permissions)"
|
||||||
:disabled="record.isLeader === '1'"
|
:disabled="record.isLeader === '1'"
|
||||||
@@ -241,8 +249,7 @@
|
|||||||
type="link"
|
type="link"
|
||||||
danger
|
danger
|
||||||
>删除
|
>删除
|
||||||
</a-button
|
</a-button>
|
||||||
>
|
|
||||||
</a-space>
|
</a-space>
|
||||||
</template>
|
</template>
|
||||||
</a-table>
|
</a-table>
|
||||||
@@ -392,7 +399,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script setup lang="jsx">
|
<script setup lang="jsx">
|
||||||
import {computed, defineProps, onMounted, ref, watch} from "vue";
|
import {computed, defineProps, onMounted, ref, watch} from "vue";
|
||||||
import {delStudentList, getStuPage, batchUpdateStatus, auditStudentBatch} from "@/api/index1";
|
import {delStudentList, getStuPage, batchUpdateStatus, auditStudentBatch, updateScore} from "@/api/index1";
|
||||||
import ChangeGroupModal from "@/components/student/ChangeGroupModal.vue";
|
import ChangeGroupModal from "@/components/student/ChangeGroupModal.vue";
|
||||||
import CommonStudent from "@/components/student/CommonStudent";
|
import CommonStudent from "@/components/student/CommonStudent";
|
||||||
import ChangeLevelModal from "./ChangeLevelModal.vue";
|
import ChangeLevelModal from "./ChangeLevelModal.vue";
|
||||||
@@ -945,6 +952,24 @@ function startLoading() {
|
|||||||
tableData.value.loading = true;
|
tableData.value.loading = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新分数详情
|
||||||
|
* @param id {string}
|
||||||
|
* @param record {Object|undefined}
|
||||||
|
*/
|
||||||
|
function handleUpdateScore(id,record = void 0){
|
||||||
|
const {studentId} = record
|
||||||
|
if (!studentId) return
|
||||||
|
const pid = props.id
|
||||||
|
// console.log(`pid`, pid,"studentId", studentId )
|
||||||
|
// console.log(props.columns)
|
||||||
|
tableData.value.loading = true
|
||||||
|
updateScore({pid, studentId}).then(response=>{
|
||||||
|
const {examinationScore} = response.data
|
||||||
|
record.examinationScore = examinationScore
|
||||||
|
tableData.value.loading = false
|
||||||
|
})
|
||||||
|
}
|
||||||
defineExpose({ getStuList, startLoading });
|
defineExpose({ getStuList, startLoading });
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
|
|||||||
Reference in New Issue
Block a user