fix:换组bug

This commit is contained in:
宋文超
2022-11-18 10:08:44 +08:00
parent 68c8a65d54
commit 0680168b75
2 changed files with 165 additions and 154 deletions

View File

@@ -462,7 +462,7 @@
<div
class="operation"
style="cursor: pointer"
@click="showAA(item.name,)"
@click="showAA(item.name)"
:style="{
display:
item.type == '6' || item.type == '9'
@@ -663,10 +663,7 @@
class="nostu"
:style="{ display: total > 0 ? 'none' : 'block' }"
> -->
<div
class="nostu"
style="display:none"
>
<div class="nostu" style="display: none">
<div class="nostuimg"></div>
</div>
<div class="pa">
@@ -1113,7 +1110,7 @@
v-model:projectId="projectId"
v-model:ChangeGroupStuId="ChangeGroupStuId"
v-model:ChangeGroupStuName="ChangeGroupStuName"
v-model:ChangeGroupId = "ChangeGroupId"
v-model:ChangeGroupId="ChangeGroupId"
@changeD="changeGrouped"
/>
<!-- 组员名单抽屉 -->
@@ -1134,7 +1131,13 @@
:title="showWorkText"
/>
<!-- 考试管理抽屉 -->
<test-manage v-model:TMvisible.sync="TMvisible" v-if="TMvisible" :title="showTestText" :projectTaskId="projectTaskId" :itemsType="itemstype"/>
<test-manage
v-model:TMvisible.sync="TMvisible"
v-if="TMvisible"
:title="showTestText"
:projectTaskId="projectTaskId"
:itemsType="itemstype"
/>
<!-- 批量面授报名 -->
<task-imp-stu v-model:TaskFaceImpStuvisible="TaskFaceImpStuvisible" />
@@ -2360,7 +2363,7 @@ export default {
//直播、活动页面传递参数
showkaoqinText: "",
//所有抽屉的传过去的type
itemstype:null,
itemstype: null,
//排行榜时间
rankStartTime: null,
@@ -2756,91 +2759,91 @@ export default {
};
//学员管理列表操作
const studentData = () => {
let arr = state.tabledata;
console.log(arr, "学员管理");
arr.map((value) => {
value.operation = (
<div
style={{
display: "flex",
alignItems: "center",
justifyContent: "center",
}}
>
<div
class="studentopea1"
onClick={() => {
if (value.excellent === false) {
state.canclestu = true;
console.log("youxiu", value.studentId);
state.changeGoods.push(value.studentId);
} else if (value.excellent === true) {
state.canclestu1 = true;
console.log("youxiu", value.studentId);
state.changeGoods.push(value.studentId);
}
}}
>
{value.excellent ? "取消优秀" : "优秀学员"}
</div>
<div
class="studentopea2"
onClick={() => {
state.Seevisible = true;
console.log(value.studentId, "点击了查看");
state.checkStuId = value.studentId;
}}
>
查看
</div>
<div class="studentSelect">
<a-select
style="width: 50px"
value="更多"
// options={state.projectNameList}
dropdownClassName="tabledropdown"
>
<a-select-option value="换组" label="换组">
<div
style="cursor:pointer"
onClick={() => {
state.Changevisible = true;
console.log(value, "xixixixix");
state.ChangeGroupStuId = value.studentId;
state.ChangeGroupStuName = value.name;
state.ChangeGroupId = value.groupId;
}}
>
换组
</div>
</a-select-option>
<a-select-option value="删除" label="删除">
<div
style="cursor:pointer"
onClick={() => {
console.log("点击了111", value.studentId);
showDeleteOne(value.studentId);
}}
>
删除
</div>
</a-select-option>
</a-select>
</div>
</div>
);
});
state.tabledata = arr;
};
studentData();
// const studentData = () => {
// let arr = state.tabledata;
// console.log(arr, "学员管理");
// arr.map((value) => {
// value.operation = (
// <div
// style={{
// display: "flex",
// alignItems: "center",
// justifyContent: "center",
// }}
// >
// <div
// class="studentopea1"
// onClick={() => {
// if (value.excellent === false) {
// state.canclestu = true;
// console.log("youxiu", value.studentId);
// state.changeGoods.push(value.studentId);
// } else if (value.excellent === true) {
// state.canclestu1 = true;
// console.log("youxiu", value.studentId);
// state.changeGoods.push(value.studentId);
// }
// }}
// >
// {value.excellent ? "取消优秀" : "优秀学员"}
// </div>
// <div
// class="studentopea2"
// onClick={() => {
// state.Seevisible = true;
// console.log(value.studentId, "点击了查看");
// state.checkStuId = value.studentId;
// }}
// >
// 查看
// </div>
// <div class="studentSelect">
// <a-select
// style="width: 50px"
// value="更多"
// // options={state.projectNameList}
// dropdownClassName="tabledropdown"
// >
// <a-select-option value="换组" label="换组">
// <div
// style="cursor:pointer"
// onClick={() => {
// state.Changevisible = true;
// console.log(value, "xixixixix");
// state.ChangeGroupStuId = value.studentId;
// state.ChangeGroupStuName = value.name;
// state.ChangeGroupId = value.groupId;
// }}
// >
// 换组
// </div>
// </a-select-option>
// <a-select-option value="删除" label="删除">
// <div
// style="cursor:pointer"
// onClick={() => {
// console.log("点击了111", value.studentId);
// showDeleteOne(value.studentId);
// }}
// >
// 删除
// </div>
// </a-select-option>
// </a-select>
// </div>
// </div>
// );
// });
// state.tabledata = arr;
// };
// studentData();
// const studentData = () => {
// let arr = state.tabledata;
// console.log(arr, "学员管理");
// arr.map((value) => {
// value.operation = (
// );
// });
// state.tabledata = arr;
@@ -2952,75 +2955,79 @@ export default {
// width: 60,
align: "center",
className: "h",
scopedSlots: { customRender: "action" }, //引入的插槽
customRender: (text) => {
scopedSlots: { customRender: "action" }, //引入的插槽
customRender: (text) => {
// console.log(text);
return (
<div
style={{
display: "flex",
alignItems: "center",
justifyContent: "center",
}}
>
<div
class="studentopea1"
onClick={() => {
if (text.record.excellent === false) {
state.canclestu = true;
console.log("youxiu", text.record.studentId);
state.changeGoods.push(text.record.studentId);
} else if (text.record.excellent === true) {
state.canclestu1 = true;
console.log("youxiu", text.record.studentId);
state.changeGoods.push(text.record.studentId);
}
}}
>
{text.record.excellent ? "取消优秀" : "优秀学员"}
</div>
<div
class="studentopea2"
onClick={() => {
state.Seevisible = true;
console.log(text.record.studentId, "点击了查看");
state.checkStuId = text.record.studentId;
}}
>
查看
</div>
<div class="studentSelect">
<a-select
style="width: 50px"
value="更多"
// options={state.projectNameList}
dropdownClassName="tabledropdown"
<div
style={{
display: "flex",
alignItems: "center",
justifyContent: "center",
}}
>
<a-select-option value="换组" label="换组">
<div
onClick={() => {
state.Changevisible = true;
}}
<div
class="studentopea1"
onClick={() => {
if (text.record.excellent === false) {
state.canclestu = true;
console.log("youxiu", text.record.studentId);
state.changeGoods.push(text.record.studentId);
} else if (text.record.excellent === true) {
state.canclestu1 = true;
console.log("youxiu", text.record.studentId);
state.changeGoods.push(text.record.studentId);
}
}}
>
{text.record.excellent ? "取消优秀" : "优秀学员"}
</div>
<div
class="studentopea2"
onClick={() => {
state.Seevisible = true;
console.log(text.record.studentId, "点击了查看");
state.checkStuId = text.record.studentId;
}}
>
查看
</div>
<div class="studentSelect">
<a-select
style="width: 50px"
value="更多"
// options={state.projectNameList}
dropdownClassName="tabledropdown"
>
换组
</div>
</a-select-option>
<a-select-option value="删除" label="删除">
<div
onClick={() => {
// console.log("点击了111", text);
showDeleteOne(text.record.studentId);
}}
>
删除
</div>
</a-select-option>
</a-select>
</div>
</div>
)}
<a-select-option value="换组" label="换组">
<div
onClick={() => {
state.Changevisible = true;
console.log(text, "xixixixix");
state.ChangeGroupStuId = text.record.studentId;
state.ChangeGroupStuName = text.record.name;
state.ChangeGroupId = text.record.groupId;
}}
>
换组
</div>
</a-select-option>
<a-select-option value="删除" label="删除">
<div
onClick={() => {
// console.log("点击了111", text);
showDeleteOne(text.record.studentId);
}}
>
删除
</div>
</a-select-option>
</a-select>
</div>
</div>
);
},
},
];
return tablecolumns;