修改地址

develoop
lijiaqi 5 months ago
parent 3107411e0c
commit 7014892386
  1. 6
      src/views/course/basicCourseInformation.vue
  2. 5
      src/views/course/components/courseEdit.vue

@ -33,6 +33,7 @@ const total = ref(0)
const params = ref({ const params = ref({
pageNo: 1, pageNo: 1,
pageSize: 7, pageSize: 7,
// username: 'qiuqiu',
username: userStore.userName, username: userStore.userName,
assessmenttype: '', assessmenttype: '',
category: '', category: '',
@ -43,7 +44,10 @@ const loading = ref(false)
// //
const getCourseList = async () => { const getCourseList = async () => {
loading.value = true loading.value = true
console.log(params.value, '11') // console.log(params.value, '11')
if (userStore.userInfo.roleId === 2) {
params.value.pageSize = 8
}
const res = await getCourseListApi(params.value) const res = await getCourseListApi(params.value)
courseList.value = res.data.list courseList.value = res.data.list

@ -7,6 +7,9 @@ import { addCourseApi } from '../../../api/user/crouse'
import { getCourseListApi, getCourseDetailApi } from '../../../api/user/crouse' import { getCourseListApi, getCourseDetailApi } from '../../../api/user/crouse'
import request from '../../../utils/request' import request from '../../../utils/request'
import { tool, client } from '../../../utils/alioss.js' import { tool, client } from '../../../utils/alioss.js'
import useUserStore from '@/store/modules/user'
// import { useRoute } from 'vue-router'
const userStore = useUserStore()
// //
const visibleDrawer = ref(false) const visibleDrawer = ref(false)
// //
@ -382,7 +385,7 @@ const upload = async (option: any) => {
</el-form> </el-form>
<template #footer> <template #footer>
<span class="dialog-footer"> <span class="dialog-footer" v-if="userStore.userInfo.roleId === 1">
<el-button @click="handleClose" size="large">取消</el-button> <el-button @click="handleClose" size="large">取消</el-button>
<el-button type="primary" size="large" @click="onSubmit()"> <el-button type="primary" size="large" @click="onSubmit()">
确认 确认

Loading…
Cancel
Save