mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-13 21:06:44 +08:00
feat:合并
This commit is contained in:
@@ -57,6 +57,7 @@ export const getProjectDetail = (obj) => http.get('/admin/project/detail', {para
|
||||
export const releaseProject = (obj) => http.post('/admin/project/publish', obj)
|
||||
//获取项目学员
|
||||
export const projectStudent = (obj) => http.post('/admin/project/studentList', obj)
|
||||
export const projectStudentCount = (obj) => http.get('/admin/student/getStudentCount', {params: obj})
|
||||
//撤回发布、结束
|
||||
export const handleProject = (obj) => http.post('/admin/project/handle', obj)
|
||||
|
||||
|
||||
@@ -4,9 +4,9 @@
|
||||
<a-col>
|
||||
<a-form-item title="姓名:" @click="getStuList">
|
||||
<a-input
|
||||
class="cus-input"
|
||||
v-model:value="tableParam.studentName"
|
||||
placeholder="请输入姓名"
|
||||
class="cus-input"
|
||||
v-model:value="tableParam.studentName"
|
||||
placeholder="请输入姓名"
|
||||
/>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
@@ -14,15 +14,16 @@
|
||||
<a-button class="cus-btn" style="width: 100px">
|
||||
<template #icon>
|
||||
<img
|
||||
style="margin-right: 10px"
|
||||
src="../../assets/images/courseManage/search0.png"
|
||||
/></template>
|
||||
style="margin-right: 10px"
|
||||
src="../../assets/images/courseManage/search0.png"
|
||||
/></template>
|
||||
搜索
|
||||
</a-button>
|
||||
</a-col>
|
||||
<a-col :span="2">
|
||||
<a-button class="cus-btn white" style="width: 100px" @click="reset"
|
||||
>重置</a-button
|
||||
>重置
|
||||
</a-button
|
||||
>
|
||||
</a-col>
|
||||
</a-row>
|
||||
@@ -30,14 +31,14 @@
|
||||
<a-row type="flex" gutter="12" style="padding-left: 20px">
|
||||
<a-col :span="1.5">
|
||||
<CommonStudent
|
||||
:type="type"
|
||||
:id="id"
|
||||
@finash="submitCall"
|
||||
:stage="stage"
|
||||
:type="type"
|
||||
:id="id"
|
||||
@finash="submitCall"
|
||||
:stage="stage"
|
||||
>
|
||||
<a-button class="cus-btn">
|
||||
<template #icon
|
||||
><img
|
||||
><img
|
||||
style="margin-right: 10px"
|
||||
src="../../assets/images/courseManage/add0.png"
|
||||
/></template>
|
||||
@@ -48,7 +49,7 @@
|
||||
<a-col :span="1.5">
|
||||
<a-button class="cus-btn white" @click="bathDel">
|
||||
<template #icon
|
||||
><img
|
||||
><img
|
||||
style="margin-right: 10px"
|
||||
src="../../assets/images/projectadd/delete.png"
|
||||
/></template>
|
||||
@@ -58,17 +59,17 @@
|
||||
</a-row>
|
||||
<div style="margin-top: 20px">
|
||||
<a-table
|
||||
:columns="tablecolumns"
|
||||
:data-source="tableData.list"
|
||||
:pagination="stuPagination"
|
||||
:loading="tableData.loading"
|
||||
row-key="id"
|
||||
:row-selection="stuRowSelection"
|
||||
:columns="tablecolumns"
|
||||
:data-source="tableData.list"
|
||||
:pagination="stuPagination"
|
||||
:loading="tableData.loading"
|
||||
row-key="id"
|
||||
:row-selection="stuRowSelection"
|
||||
>
|
||||
<template #action="{ record }">
|
||||
<div
|
||||
@click="del(record.id)"
|
||||
style="color: #4ea6ff; font-size: 14px; text-align: center"
|
||||
@click="del(record.id)"
|
||||
style="color: #4ea6ff; font-size: 14px; text-align: center"
|
||||
>
|
||||
删除
|
||||
</div>
|
||||
@@ -96,8 +97,8 @@
|
||||
</div>
|
||||
</template>
|
||||
<script setup>
|
||||
import { computed, defineProps, onMounted, ref } from "vue";
|
||||
import { delStudentList, getStuPage } from "@/api/index1";
|
||||
import {computed, defineProps, onMounted, ref, watch} from "vue";
|
||||
import {delStudentList, getStuPage} from "@/api/index1";
|
||||
import CommonStudent from "@/components/student/CommonStudent";
|
||||
|
||||
const props = defineProps({
|
||||
@@ -145,8 +146,8 @@ const tablecolumns = ref([
|
||||
key: "source",
|
||||
width: "10%",
|
||||
align: "center",
|
||||
customRender: ({ record: { source } }) =>
|
||||
({ 1: "快速添加", 2: "组织", 3: "受众" }[source]),
|
||||
customRender: ({record: {source}}) =>
|
||||
({1: "快速添加", 2: "组织", 3: "受众"}[source]),
|
||||
},
|
||||
...props.columns,
|
||||
{
|
||||
@@ -155,7 +156,7 @@ const tablecolumns = ref([
|
||||
key: "operation",
|
||||
width: "25%",
|
||||
align: "center",
|
||||
slots: { customRender: "action" },
|
||||
slots: {customRender: "action"},
|
||||
},
|
||||
]);
|
||||
const tableParam = ref({
|
||||
@@ -183,6 +184,11 @@ onMounted(() => {
|
||||
getStuList();
|
||||
});
|
||||
|
||||
watch(props, () => {
|
||||
tableParam.value.pid= props.id
|
||||
getStuList();
|
||||
})
|
||||
|
||||
function onStuSelectChange(e) {
|
||||
stuSelectKeys.value = e;
|
||||
}
|
||||
@@ -210,25 +216,26 @@ function getStuList() {
|
||||
});
|
||||
}
|
||||
|
||||
function reset() {}
|
||||
function reset() {
|
||||
}
|
||||
|
||||
function bathDel() {
|
||||
stuSelectKeys.value &&
|
||||
stuSelectKeys.value.length &&
|
||||
delStudentList({
|
||||
ids: stuSelectKeys.value,
|
||||
}).then(() => {
|
||||
getStuList();
|
||||
});
|
||||
stuSelectKeys.value.length &&
|
||||
delStudentList({
|
||||
ids: stuSelectKeys.value,
|
||||
}).then(() => {
|
||||
getStuList();
|
||||
});
|
||||
}
|
||||
|
||||
function del(id) {
|
||||
id &&
|
||||
delStudentList({
|
||||
ids: [id],
|
||||
}).then(() => {
|
||||
getStuList();
|
||||
});
|
||||
delStudentList({
|
||||
ids: [id],
|
||||
}).then(() => {
|
||||
getStuList();
|
||||
});
|
||||
}
|
||||
|
||||
function submitCall(flag) {
|
||||
|
||||
@@ -2278,7 +2278,7 @@
|
||||
<span>{{ currentPlanItem.teacher }}</span>
|
||||
</div>
|
||||
<div class="stmm_i5">
|
||||
<TableStudent :type="3" :id="offcourseId" :columns="stuColumns">
|
||||
<TableStudent :type="3" :id="offcoursePlanId" :columns="stuColumns">
|
||||
<!-- <template #extension = "data">-->
|
||||
<!-- <div style="display: flex">-->
|
||||
<!-- <button @click="handlJoinStu(data)">成绩录入</button>-->
|
||||
@@ -4982,7 +4982,7 @@ export default defineComponent({
|
||||
console.log(state.currentPlanItem);
|
||||
|
||||
state.sm_hs = true;
|
||||
getTableDate2();
|
||||
// getTableDate2();
|
||||
};
|
||||
const sm_exit = () => {
|
||||
state.sm_hs = false;
|
||||
|
||||
@@ -203,7 +203,7 @@
|
||||
<!-- <img class="im" src="../../assets/px.jpg" />
|
||||
<img class="im" src="../../assets/px.jpg" />
|
||||
<img class="im" src="../../assets/px.jpg" /> -->
|
||||
|
||||
|
||||
<div
|
||||
@click="chooseImg(item)"
|
||||
v-for="(item, index) in imgData"
|
||||
@@ -244,7 +244,7 @@
|
||||
class="aeLoading"
|
||||
:style="{ display: lpLoading ? 'flex' : 'none' }"
|
||||
>
|
||||
<a-spin :spinning="lpLoading" tip="" />
|
||||
<a-spin :spinning="lpLoading" tip=""/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -278,7 +278,7 @@
|
||||
/>
|
||||
</div>
|
||||
<div class="inname">路径图名称</div>
|
||||
<div class="in">
|
||||
<div class="in" >
|
||||
<!-- <a-input-->
|
||||
<!-- v-model:value="pathName"-->
|
||||
<!-- maxlength="20"-->
|
||||
@@ -332,7 +332,7 @@
|
||||
<!-- <img class="im" src="../../assets/px.jpg" />
|
||||
<img class="im" src="../../assets/px.jpg" />
|
||||
<img class="im" src="../../assets/px.jpg" /> -->
|
||||
|
||||
|
||||
<div
|
||||
@click="chooseImg2(item)"
|
||||
v-for="(item, index) in imgData"
|
||||
@@ -699,6 +699,7 @@ import ProjPowerList from "../../components/drawers/ProjPowerList";
|
||||
import ProjCheckShip from "../../components/drawers/ProjCheckPower";
|
||||
// import ManageRight from "../../components/drawers/ManageRight";
|
||||
import * as api from "../../api/index1";
|
||||
import * as apiStu from "../../api/index";
|
||||
import { message } from "ant-design-vue";
|
||||
import {
|
||||
commonData,
|
||||
@@ -709,7 +710,7 @@ import { storage } from "../../api/storage";
|
||||
import { useStore } from "vuex";
|
||||
import OrgClass from "@/components/project/OrgClass";
|
||||
import NameInput from "@/components/project/NameInput";
|
||||
import { getStuPage } from "@/api/index1";
|
||||
|
||||
export default {
|
||||
name: "learningPath",
|
||||
components: {
|
||||
@@ -857,7 +858,7 @@ export default {
|
||||
state.pathName = "";
|
||||
state.pathBg = "";
|
||||
state.pathBgId = "";
|
||||
if (store.state.userInfo.departId && store.state.userInfo.departName) {
|
||||
if(store.state.userInfo.departId && store.state.userInfo.departName){
|
||||
state.organizationSelectName = store.state.userInfo.departName;
|
||||
state.organizationSelectId = store.state.userInfo.departId;
|
||||
}
|
||||
@@ -867,7 +868,7 @@ export default {
|
||||
const handleOut1 = () => {
|
||||
state.pathName = "";
|
||||
state.pathBg = "";
|
||||
state.pathBgId = 1;
|
||||
state.pathBgId =1;
|
||||
state.organizationSelectName = null;
|
||||
state.organizationSelectId = null;
|
||||
state.pathIntro = "";
|
||||
@@ -905,23 +906,13 @@ export default {
|
||||
console.log("err", err);
|
||||
});
|
||||
//获取学员列表
|
||||
let stuobj = {
|
||||
pageNo: 1,
|
||||
pageSize: 10,
|
||||
pid: router.id,
|
||||
type: 2,
|
||||
};
|
||||
getStuPage(stuobj)
|
||||
.then((res) => {
|
||||
console.log("获取学员列表", res.data);
|
||||
if (res.data.code === 200) {
|
||||
state.routeStudentsNum = res.data.data.total;
|
||||
apiStu.projectStudentCount({
|
||||
pid: router.id,
|
||||
type:2
|
||||
}).then((res) => {
|
||||
state.routeStudentsNum = res.data.data;
|
||||
state.pubLoading = false;
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log("获取学员列表失败", err);
|
||||
});
|
||||
};
|
||||
//确定发布
|
||||
const releaseLearnPath = () => {
|
||||
@@ -1175,7 +1166,7 @@ export default {
|
||||
key: "opacation",
|
||||
width: "20%",
|
||||
align: "center",
|
||||
// fixed: "right",
|
||||
// fixed: "right",
|
||||
scopedSlots: { customRender: "action" }, //引入的插槽
|
||||
customRender: (text) => {
|
||||
// console.log(text);
|
||||
@@ -1626,16 +1617,17 @@ export default {
|
||||
arr.forEach((item) => {
|
||||
if (item.dictValue === state.pathBg) {
|
||||
state.pathBgId = item.dictCode;
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
//for (let i = 0; i < arr.length; i++) {
|
||||
// console.log("arr[i].dictValue", arr[i].dictValue, state.pathBg);
|
||||
// console.log("arr[i].dictValue", arr[i].dictValue, state.pathBg);
|
||||
// if (arr[i].dictValue === state.pathBg) {
|
||||
// state.pathBgId = arr[i].dictCode;
|
||||
// state.pathBgId = arr[i].dictCode;
|
||||
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
@@ -1744,7 +1736,7 @@ export default {
|
||||
state.searchdate = null;
|
||||
state.startTime = null;
|
||||
state.endTime = null;
|
||||
state.createUser = null;
|
||||
state.createUser=null;
|
||||
getLearnPath();
|
||||
};
|
||||
|
||||
@@ -1802,7 +1794,7 @@ export default {
|
||||
// state.imgData = ;
|
||||
// }
|
||||
});
|
||||
const imgData = computed(() => store.state.pathmapPic);
|
||||
const imgData = computed(()=>store.state.pathmapPic)
|
||||
//添加权限
|
||||
watch(
|
||||
() => state.addAuthList,
|
||||
|
||||
@@ -357,6 +357,7 @@ export default {
|
||||
...res.data.data.projectInfo,
|
||||
...state.projectInfo,
|
||||
};
|
||||
!routers.query.projectId && !!routers.query.parentId && (state.projectInfo.name = '')
|
||||
state.projectInfo.rangeTime = [
|
||||
state.projectInfo.beginTime,
|
||||
state.projectInfo.endTime,
|
||||
|
||||
@@ -51,6 +51,7 @@
|
||||
format="YYYY-MM-DD"
|
||||
style="border-radius: 8px; height: 40px; margin-left: 5px"
|
||||
:placeholder="[' 开始时间', ' 结束时间']"
|
||||
|
||||
/>
|
||||
</div>
|
||||
<div style="display: flex; margin-bottom: 20px">
|
||||
@@ -828,7 +829,7 @@ import { changeOwnership } from "@/api/method";
|
||||
import NameInput from "@/components/project/NameInput";
|
||||
import { validateName } from "@/api/index1";
|
||||
//import { toDate } from "../../api/method";
|
||||
import { getStuPage } from "@/api/index1";
|
||||
|
||||
export default {
|
||||
name: "projectManage",
|
||||
components: {
|
||||
@@ -1046,25 +1047,13 @@ export default {
|
||||
state.projectTasks = res.data.data.tasks;
|
||||
});
|
||||
//获取学员总数
|
||||
let obj = {
|
||||
pageNo: 0,
|
||||
pageSize: 0,
|
||||
api.projectStudentCount({
|
||||
pid: object.projectId,
|
||||
type: 1,
|
||||
};
|
||||
getStuPage(obj)
|
||||
.then((res) => {
|
||||
if (res.data.code === 200) {
|
||||
// console.log("res", res.data);
|
||||
state.projectStudentsNum = res.data.data.total
|
||||
? res.data.data.total
|
||||
: 0;
|
||||
type:1
|
||||
}).then((res) => {
|
||||
state.projectStudentsNum = res.data.data
|
||||
state.projectPubLoading = false;
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log("获取学员人数失败", err);
|
||||
});
|
||||
//获取阶段及任务总数
|
||||
};
|
||||
//确认发布项目
|
||||
@@ -1698,6 +1687,7 @@ export default {
|
||||
state.searchParam.valueDate &&
|
||||
state.searchParam.valueDate.length === 2
|
||||
? dayjs(state.searchParam.valueDate[0]).format("YYYY-MM-DD")
|
||||
|
||||
: "",
|
||||
endTime:
|
||||
state.searchParam.valueDate &&
|
||||
|
||||
Reference in New Issue
Block a user