feat:面授课修改记录增加

This commit is contained in:
wyx
2023-02-20 12:22:07 +08:00
parent 2561eeb1af
commit e33a71a027
2 changed files with 100 additions and 9 deletions

View File

@@ -43,4 +43,7 @@ export const auditView = (obj) => http.post('/admin/project/auditView', obj)
export const courseAuditView = (obj) => http.post('/admin/offcourse/auditView', obj)
//项目修改记录
export const editRecord = (chooseProject) => http.get(`/modifyRecord/page?id=${chooseProject}&type=1&size=2`)
export const editRecord = (chooseProject) => http.get(`/modifyRecord/page?id=${chooseProject}&type=1&size=2`)
// 面授课的修改记录
export const editCourseRecord = (chooseCourse) => http.get(`/modifyRecord/page?id=${chooseCourse}&type=2&size=100`)

View File

@@ -94,6 +94,27 @@
<div class="close_exit" @click="closeCourAuditModal"></div>
</div>
<div class="body">
<div class="item">
<div class="left" style="color:#4ea6ff;">修改意见</div>
<div class="rig">
</div>
</div>
<!-- 修改记录详情 -->
<div v-if="openDetailVisibie" style="display: flex;width: 100%;margin-top: 12px;">
<a-table
:columns="columns2"
:data-source="tableData2"
:loading="loading2"
expandRowByClick="true"
@expand="expandTable"
:scroll="{ y: 250 }"
:pagination="false" />
</div>
<div style="display: flex;justify-content: center;align-items: center;height: 70px;">
<div @click="openDetail" style="cursor:pointer;padding: 2px 12px;border-radius: 4px;background: #4ea6ff;color: #fff;font-size: 14px;">
{{ openDetailVisibie?"详情折叠":"详情展开" }}
</div>
</div>
<div class="item">
<div class="left">审核</div>
<div class="rig">
@@ -121,6 +142,7 @@
<div class="btnText">确定</div>
</div>
</div>
<div style="height:20px;"></div>
</div>
</div>
</a-modal>
@@ -234,6 +256,7 @@ import { message } from "ant-design-vue";
import ProjectManager from "@/components/project/ProjectManagerNew";
import SeeModal from "../courselibrary/components/seeModal.vue";
import { iframeUrl } from "../../api/method";
import { editCourseRecord } from "../../api/indexAudit";
import {useStore} from "vuex";
import dayjs from "dayjs";
@@ -246,6 +269,7 @@ export default {
setup() {
const state = reactive({
loading: false,
loading2: false,
optionsproj: [
{
value: "jack",
@@ -415,9 +439,38 @@ export default {
},
},
],
columns2: [
{
title: "修改人",
dataIndex: "updateName",
key: "updateName",
align: "center",
ellipsis: true,
},
{
title: "修改时间",
dataIndex: "updateTime",
key: "updateTime",
align: "center",
},
{
title: "修改前",
dataIndex: "beforeValue",
key: "beforeValue",
align: "center",
ellipsis: true,
},
{
title: "修改后",
dataIndex: "afterValue",
key: "afterValue",
align: "center",
}
],
// 待审核课程的数据
tableData1: [],
// 修改记录数据
tableData2: [],
//审核在线课嵌套页面
onlineClassesVisible: false,
iframeUrl: iframeUrl,
@@ -564,8 +617,13 @@ export default {
result:"",
remarks:"",
times:"",
}
},
openDetailVisibie:false,
});
const store = useStore();
const sysTypeOptions = computed(() => store.state.content_type);
@@ -739,7 +797,8 @@ export default {
state.createId = createId;
state.chooseCreater = creater;
state.chooseOffId = offId;
getFaceList();
{/* 获取当前课程的审核记录 */}
getCourseRecord(offId);
};
// 显示邀请审核弹框
@@ -794,6 +853,7 @@ export default {
}
const closeCourAuditModal = () => {
state.openDetailVisibie = false;
state.courAuditModal = false;
state.valueSugg = null;
state.valuepass = "1";
@@ -827,6 +887,7 @@ export default {
state.valueSugg = null;
state.valuepass = "1";
getFaceList();
state.openDetailVisibie = false;
})
.catch((err) => {
console.log(err);
@@ -834,6 +895,7 @@ export default {
message.warning("审核提交失败");
state.valueSugg = null;
state.valuepass = "1";
state.openDetailVisibie = false;
});
};
onMounted(async () => {
@@ -844,6 +906,30 @@ export default {
const onEditorFocus = (event) => {
event.enable(false);
};
{/* 产看审核记录详情 */}
const openDetail = () => {
state.openDetailVisibie = !state.openDetailVisibie;
}
{/* 获取课程审核记录 */}
const getCourseRecord = (courseId) => {
state.loading2.value = true;
editCourseRecord(courseId)
.then((res) => {
console.log("获取修改记录", res);
if (res.data.code === 200) {
state.tableData2 = res.data.data.records;
// console.log("state.tableData", state.tableData);
}
state.loading2.value = false;
})
.catch((err) => {
console.log("获取修改记录失败", err);
state.loading2.value = false;
});
}
return {
...toRefs(state),
getFaceList,
@@ -868,7 +954,9 @@ export default {
sceneist11,
onEditorFocus,
sHX,
sysTypeOptions
sysTypeOptions,
openDetail,
getCourseRecord
};
},
};
@@ -898,21 +986,21 @@ export default {
.courAuditModal {
.ant-modal {
width: 640px !important;
height: 400px !important;
height: auto;
.ant-modal-content {
width: 640px !important;
height: 400px !important;
height: auto;
.ant-modal-body {
width: 640px !important;
height: 400px !important;
height: auto;
padding: 0 !important;
.delete {
z-index: 999;
width: 640px;
height: 400px;
height: auto;
background: #ffffff;
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
border-radius: 4px;