授课记录调整1015

This commit is contained in:
wangxuemei
2024-10-15 13:51:25 +08:00
parent 2c739fe666
commit e61f032aea
6 changed files with 86 additions and 42 deletions

View File

@@ -56,18 +56,10 @@
</div> </div>
<div class="tableBox "> <div class="tableBox ">
<div style="float: right;"> <div class="pa">
<a-pagination <a-pagination v-if="tableDataTotal > 10" :showSizeChanger="true" :showQuickJumper="false"
v-if="tableDataTotal > 10" :hideOnSinglePage="true" :pageSize="searchParam.pageSize" :current="searchParam.pageNo" :total="tableDataTotal"
:showSizeChanger="true" class="pagination" @change="changePagination" />
:showQuickJumper="true"
:hideOnSinglePage="true"
:pageSize="searchParam.pageSize"
:current="searchParam.pageNo"
:total="tableDataTotal"
class="pagination"
@change="changePagination"
/>
</div> </div>
</div> </div>
<!-- 弹窗组件 --> <!-- 弹窗组件 -->
@@ -535,7 +527,7 @@ export default {
//调用接口 //调用接口
let ids = { let ids = {
id: state.editTeacherid, id: state.editTeacherid,
newStatus: state.newStatus status: state.newStatus
} }
console.log(ids) console.log(ids)
updateTeacherState(ids).then((res) => { updateTeacherState(ids).then((res) => {

View File

@@ -101,18 +101,10 @@
</div> </div>
<div class="tableBox "> <div class="tableBox ">
<div style="float: right;"> <div class="pa">
<a-pagination <a-pagination v-if="tableDataTotal > 10" :showSizeChanger="true" :showQuickJumper="false"
v-if="tableDataTotal > 10" :hideOnSinglePage="true" :pageSize="searchParam.pageSize" :current="searchParam.pageNo" :total="tableDataTotal"
:showSizeChanger="false" class="pagination" @change="changePagination" />
:showQuickJumper="true"
:hideOnSinglePage="true"
:pageSize="searchParam.pageSize"
:current="searchParam.pageNo"
:total="tableDataTotal"
class="pagination"
@change="changePagination"
/>
</div> </div>
</div> </div>
<!-- 弹窗组件 --> <!-- 弹窗组件 -->
@@ -1178,4 +1170,22 @@ const handleImport = () => {
.ant-col-12{ .ant-col-12{
height:80px; height:80px;
} }
.tableBox {
padding-bottom: 20px;
 margin: 20px 38px 30px;
::v-deep .ant-select-dropdown{
display: inline-block;
}
::v-deep .ant-select-selection-item{
margin-left: 3px;
}
::v-deep .ant-pagination-options-size-changer.ant-select{
width: 84px;
}
.pa {
width: 100%;
display: flex;
justify-content: right;
}
}
</style> </style>

View File

@@ -105,8 +105,7 @@
</div> </div>
<div class="tableBox "> <div class="tableBox ">
<div style="float: right;"> <div class="pa">
<a-pagination v-if="tableDataTotal > 10" :showSizeChanger="true" :showQuickJumper="false" <a-pagination v-if="tableDataTotal > 10" :showSizeChanger="true" :showQuickJumper="false"
:hideOnSinglePage="true" :pageSize="searchParam.pageSize" :current="searchParam.pageNo" :total="tableDataTotal" :hideOnSinglePage="true" :pageSize="searchParam.pageSize" :current="searchParam.pageNo" :total="tableDataTotal"
class="pagination" @change="changePagination" /> class="pagination" @change="changePagination" />
@@ -948,6 +947,8 @@ export default {
state.deleteInTeacherdialog = false state.deleteInTeacherdialog = false
getTableDate(); getTableDate();
} }
}).catch((err)=>{
state.deleteInTeacherdialog = false
}) })
} }
//确认启用停用 //确认启用停用
@@ -955,13 +956,15 @@ export default {
//调用接口 //调用接口
let ids = { let ids = {
id: state.editTeacherid, id: state.editTeacherid,
newStatus: state.newStatus status: state.newStatus
} }
console.log(ids) console.log(ids)
updateTeacherState(ids).then((res) => { updateTeacherState(ids).then((res) => {
message.success("操作成功"); message.success("操作成功");
state.editTeacher = false state.editTeacher = false
getTableDate(); getTableDate();
}).catch((err)=>{
state.editTeacher = false
}) })
} }
//取消按钮 清空输入的数据 //取消按钮 清空输入的数据
@@ -1491,4 +1494,22 @@ export default {
::v-deep .ant-modal-close { ::v-deep .ant-modal-close {
display: none; display: none;
} }
</style> .tableBox {
padding-bottom: 20px;
 margin: 20px 38px 30px;
::v-deep .ant-select-dropdown{
display: inline-block;
}
::v-deep .ant-select-selection-item{
margin-left: 3px;
}
::v-deep .ant-pagination-options-size-changer.ant-select{
width: 84px;
}
.pa {
width: 100%;
display: flex;
justify-content: right;
}
}
</style >

View File

@@ -124,10 +124,10 @@
</div> </div>
</div> </div>
<div class="tableBox "> <div class="tableBox ">
<div style="float: right;"> <div class="pa">
<a-pagination v-if="tableDataTotal > 10" :showSizeChanger="false" :showQuickJumper="true" :hideOnSinglePage="true" <a-pagination v-if="tableDataTotal > 10" :showSizeChanger="true" :showQuickJumper="false"
:pageSize="searchParam.pageSize" :current="searchParam.pageNo" :total="tableDataTotal" class="pagination" :hideOnSinglePage="true" :pageSize="searchParam.pageSize" :current="searchParam.pageNo" :total="tableDataTotal"
@change="changePagination" /> class="pagination" @change="changePagination" />
</div> </div>
</div> </div>
<!-- 弹窗组件 --> <!-- 弹窗组件 -->
@@ -1593,4 +1593,22 @@ export default {
::v-deep .ant-select-multiple .ant-select-selection-item { ::v-deep .ant-select-multiple .ant-select-selection-item {
height: 34px height: 34px
} }
.tableBox {
padding-bottom: 20px;
 margin: 20px 38px 30px;
::v-deep .ant-select-dropdown{
display: inline-block;
}
::v-deep .ant-select-selection-item{
margin-left: 3px;
}
::v-deep .ant-pagination-options-size-changer.ant-select{
width: 84px;
}
.pa {
width: 100%;
display: flex;
justify-content: right;
}
}
</style> </style>

View File

@@ -84,7 +84,8 @@ ExternalLecturer
<script lang ="jsx"> <script lang ="jsx">
import { useRouter,useRoute } from "vue-router"; import { useRouter,useRoute } from "vue-router";
import { reactive, toRefs, ref } from "vue" import { reactive, toRefs, ref } from "vue"
import {getTeacherById,getTeacherCourseList } from "../../api/Lecturer"; import {getTeacherById} from "../../api/Lecturer";
import { getNewInTeacherCourseList } from "../../api/Teaching";
export default{ export default{
name :"LookExternalLecturer", name :"LookExternalLecturer",
components:{ components:{
@@ -103,7 +104,7 @@ export default{
teacherrecordstableDataTotal: -1,//授课记录列表总条数 teacherrecordstableDataTotal: -1,//授课记录列表总条数
teacherrepromotableDataTotal: -1,//晋级记录总条数 teacherrepromotableDataTotal: -1,//晋级记录总条数
teacherrecords: { teacherrecords: {
teacherType:'1', teacherType:2,
pageNo: "1", pageNo: "1",
pageSize: "10", pageSize: "10",
id: null id: null
@@ -121,6 +122,7 @@ export default{
console.log("内部讲师详情", res.data); console.log("内部讲师详情", res.data);
state.formParam = res.data.data state.formParam = res.data.data
state.formParam.photo = state.formParam.photo ===null ? 'https://p0.itc.cn/q_70/images01/20211013/f45d91616a364d6ea9c42a8db69734aa.png' : state.formParam.photo state.formParam.photo = state.formParam.photo ===null ? 'https://p0.itc.cn/q_70/images01/20211013/f45d91616a364d6ea9c42a8db69734aa.png' : state.formParam.photo
getteacherrecordstableData()
}) })
.catch((err) => { .catch((err) => {
console.log("内部讲师详情", err); console.log("内部讲师详情", err);
@@ -235,17 +237,17 @@ export default{
]) ])
const getteacherrecordstableData = () => { const getteacherrecordstableData = () => {
state.teacherrecordsLoading = true state.teacherrecordsLoading = true
state.teacherrecords.id = state.id state.teacherrecords.name = state.formParam.name
let obj = { ...state.teacherrecords } let obj = { ...state.teacherrecords }
// api接口 // api接口
getTeacherCourseList(obj).then((res) => { getNewInTeacherCourseList(obj).then((res) => {
teacherrecordstableData.value = res.data.data.records teacherrecordstableData.value = res.data.data.records
state.teacherrecordstableDataTotal = Number(res.data.data.total); state.teacherrecordstableDataTotal = Number(res.data.data.total);
state.teacherrecordsLoading = false state.teacherrecordsLoading = false
}) })
}; };
getteacherrecordstableData() // getteacherrecordstableData()
//授课翻页 //授课翻页
const teacherchangePagination = (page) => { const teacherchangePagination = (page) => {
state.teacherrecords.pageNo = page; state.teacherrecords.pageNo = page;

View File

@@ -128,7 +128,8 @@
import { useRouter,useRoute } from "vue-router"; import { useRouter,useRoute } from "vue-router";
import { reactive, toRefs, ref, computed } from "vue" import { reactive, toRefs, ref, computed } from "vue"
import { useStore } from "vuex"; import { useStore } from "vuex";
import {getTeacherById,getTeacherCourseList ,getTeacherLogList} from "../../api/Lecturer"; import {getTeacherById ,getTeacherLogList} from "../../api/Lecturer";
import { getNewInTeacherCourseList } from "../../api/Teaching";
export default{ export default{
name :"LookInsideLecturer", name :"LookInsideLecturer",
components:{ components:{
@@ -173,6 +174,7 @@ export default{
state.formParam.photo = state.formParam.photo ===null ? 'https://p0.itc.cn/q_70/images01/20211013/f45d91616a364d6ea9c42a8db69734aa.png' : state.formParam.photo state.formParam.photo = state.formParam.photo ===null ? 'https://p0.itc.cn/q_70/images01/20211013/f45d91616a364d6ea9c42a8db69734aa.png' : state.formParam.photo
state.teacherrepromo.userId=res.data.data.id state.teacherrepromo.userId=res.data.data.id
console.log(state.teacherrepromo.id); console.log(state.teacherrepromo.id);
getteacherrecordstableData()
getpromotionrecordstableData() getpromotionrecordstableData()
}) })
.catch((err) => { .catch((err) => {
@@ -291,17 +293,16 @@ export default{
]) ])
const getteacherrecordstableData = () => { const getteacherrecordstableData = () => {
state.teacherrecordsLoading = true state.teacherrecordsLoading = true
state.teacherrecords.id = state.id state.teacherrecords.name = state.formParam.name
let obj = { ...state.teacherrecords } let obj = { ...state.teacherrecords }
// api接口 // api接口
getTeacherCourseList(obj).then((res) => { getNewInTeacherCourseList(obj).then((res) => {
console.log(res); console.log(res);
teacherrecordstableData.value = res.data.data.records teacherrecordstableData.value = res.data.data.records
state.teacherrecordstableDataTotal = Number(res.data.data.total); state.teacherrecordstableDataTotal = Number(res.data.data.total);
state.teacherrecordsLoading = false state.teacherrecordsLoading = false
}) })
}; };
getteacherrecordstableData()
//授课翻页 //授课翻页
const teacherchangePagination = (page) => { const teacherchangePagination = (page) => {
state.teacherrecords.pageNo = page; state.teacherrecords.pageNo = page;