mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-14 05:16:45 +08:00
feat:新建关卡页面
This commit is contained in:
@@ -416,17 +416,17 @@ export default {
|
|||||||
const packUp = () => {
|
const packUp = () => {
|
||||||
state.packup = !state.packup;
|
state.packup = !state.packup;
|
||||||
};
|
};
|
||||||
const getMousePosition = () => {
|
const getClientHeight = () => {
|
||||||
state.screenHeight = document.body.clientHeight;
|
state.screenHeight = document.body.clientHeight;
|
||||||
};
|
};
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
// console.log("11111", 1);
|
// console.log("11111", 1);
|
||||||
window.addEventListener("resize", getMousePosition, false);
|
window.addEventListener("resize", getClientHeight, false);
|
||||||
// judgeUrl();
|
// judgeUrl();
|
||||||
});
|
});
|
||||||
onUnmounted(() => {
|
onUnmounted(() => {
|
||||||
window.removeEventListener("resize", getMousePosition, false);
|
window.removeEventListener("resize", getClientHeight, false);
|
||||||
});
|
});
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="allCon">
|
<div class="allCon" :style="{ height: rightheight }">
|
||||||
<div class="left clearfix">
|
<div class="left clearfix" :style="{ height: rightheight }">
|
||||||
<div class="leftmain">
|
<div class="leftmain">
|
||||||
<div class="tit">关卡</div>
|
<div class="tit">关卡</div>
|
||||||
<div class="btn btn3">
|
<div class="btn btn3">
|
||||||
@@ -40,7 +40,7 @@
|
|||||||
<div class="select">
|
<div class="select">
|
||||||
<a-select
|
<a-select
|
||||||
v-model:value="projectName"
|
v-model:value="projectName"
|
||||||
style="width: 270px"
|
style="width: 200px"
|
||||||
placeholder="自由学习模式"
|
placeholder="自由学习模式"
|
||||||
:options="projectNameList"
|
:options="projectNameList"
|
||||||
@change="selectProjectName"
|
@change="selectProjectName"
|
||||||
@@ -82,15 +82,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="mid">
|
<div class="mid">
|
||||||
<!-- <div class="item" v-for="(item, index) in mid" :key="item.id">
|
|
||||||
<div class="itcon">
|
|
||||||
<div class="img">
|
|
||||||
<img :src="item.img" />
|
|
||||||
</div>
|
|
||||||
<div class="text">{{ item.title }}</div>
|
|
||||||
</div>
|
|
||||||
<div :class="[index === mid.length - 1 ? 'no' : 'lin']"></div>
|
|
||||||
</div> -->
|
|
||||||
<div class="item">
|
<div class="item">
|
||||||
<div class="itcon">
|
<div class="itcon">
|
||||||
<div class="img">
|
<div class="img">
|
||||||
@@ -244,18 +235,15 @@
|
|||||||
:data-source="tableData"
|
:data-source="tableData"
|
||||||
:loading="tableDataTotal === -1 ? true : false"
|
:loading="tableDataTotal === -1 ? true : false"
|
||||||
expandRowByClick="true"
|
expandRowByClick="true"
|
||||||
:scroll="{ x: 1500, y: 300 }"
|
|
||||||
@expand="expandTable"
|
@expand="expandTable"
|
||||||
:pagination="false"
|
:pagination="false"
|
||||||
:row-selection="{
|
:row-selection="{
|
||||||
columnWidth: '40px',
|
columnWidth: 30,
|
||||||
selectedRowKeys: selectedRowKeys,
|
selectedRowKeys: selectedRowKeys,
|
||||||
onChange: onSelectChange,
|
onChange: onSelectChange,
|
||||||
}"
|
}"
|
||||||
/>
|
/>
|
||||||
<!-- :pagination= showSizeChanger: true, showQuickJumper: true,
|
|
||||||
hideOnSinglePage: true, pageSizeOptions: [], pageSize: pageSize, current:
|
|
||||||
currentPage, total: tableDataTotal, -->
|
|
||||||
<div class="pa">
|
<div class="pa">
|
||||||
<a-pagination
|
<a-pagination
|
||||||
showSizeChanger="true"
|
showSizeChanger="true"
|
||||||
@@ -276,7 +264,7 @@
|
|||||||
class="drawerStyle"
|
class="drawerStyle"
|
||||||
title="关联项目"
|
title="关联项目"
|
||||||
placement="right"
|
placement="right"
|
||||||
width="50%"
|
width="80%"
|
||||||
@after-visible-change="afterVisibleChange"
|
@after-visible-change="afterVisibleChange"
|
||||||
>
|
>
|
||||||
<div class="drawerMain">
|
<div class="drawerMain">
|
||||||
@@ -311,7 +299,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { reactive, toRefs } from "vue";
|
import { reactive, toRefs, onMounted } from "vue";
|
||||||
const drawercolumns = [
|
const drawercolumns = [
|
||||||
{
|
{
|
||||||
title: "项目名称",
|
title: "项目名称",
|
||||||
@@ -354,6 +342,7 @@ export default {
|
|||||||
name: "LevelAddDetail",
|
name: "LevelAddDetail",
|
||||||
setup() {
|
setup() {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
|
rightheight: null,
|
||||||
projectNameList: [
|
projectNameList: [
|
||||||
{
|
{
|
||||||
id: 1,
|
id: 1,
|
||||||
@@ -577,7 +566,7 @@ export default {
|
|||||||
dataIndex: "state",
|
dataIndex: "state",
|
||||||
// width: "30%",
|
// width: "30%",
|
||||||
key: "state",
|
key: "state",
|
||||||
width: 40,
|
width: 60,
|
||||||
align: "left",
|
align: "left",
|
||||||
className: "classify",
|
className: "classify",
|
||||||
scopedSlots: { customRender: "action" }, //引入的插槽
|
scopedSlots: { customRender: "action" }, //引入的插槽
|
||||||
@@ -617,7 +606,7 @@ export default {
|
|||||||
title: "必修/选修",
|
title: "必修/选修",
|
||||||
dataIndex: "pubtime",
|
dataIndex: "pubtime",
|
||||||
key: "pubtime",
|
key: "pubtime",
|
||||||
width: 200,
|
// width: 100,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
scopedSlots: { customRender: "action" }, //引入的插槽
|
scopedSlots: { customRender: "action" }, //引入的插槽
|
||||||
@@ -656,7 +645,7 @@ export default {
|
|||||||
title: "时长",
|
title: "时长",
|
||||||
dataIndex: "cretime",
|
dataIndex: "cretime",
|
||||||
key: "cretime",
|
key: "cretime",
|
||||||
width: 100,
|
// width: 100,
|
||||||
align: "center",
|
align: "center",
|
||||||
className: "h",
|
className: "h",
|
||||||
},
|
},
|
||||||
@@ -665,7 +654,7 @@ export default {
|
|||||||
className: "h",
|
className: "h",
|
||||||
dataIndex: "opacation",
|
dataIndex: "opacation",
|
||||||
key: "opacation",
|
key: "opacation",
|
||||||
width: 100,
|
// width: 100,
|
||||||
align: "center",
|
align: "center",
|
||||||
scopedSlots: { customRender: "action" }, //引入的插槽
|
scopedSlots: { customRender: "action" }, //引入的插槽
|
||||||
customRender: () => {
|
customRender: () => {
|
||||||
@@ -690,6 +679,21 @@ export default {
|
|||||||
state.selectedRowKeys = selectedRowKeys;
|
state.selectedRowKeys = selectedRowKeys;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
state.rightheight =
|
||||||
|
document.getElementsByClassName("addhead")[0].offsetHeight +
|
||||||
|
document.getElementsByClassName("mid")[0].offsetHeight +
|
||||||
|
document.getElementsByClassName("boom")[0].offsetHeight +
|
||||||
|
40 +
|
||||||
|
"px";
|
||||||
|
console.log(
|
||||||
|
"获取元素",
|
||||||
|
state.rightheight,
|
||||||
|
document.getElementsByClassName("right")[0].offsetHeight,
|
||||||
|
document.getElementsByClassName("right")[0]
|
||||||
|
);
|
||||||
|
});
|
||||||
|
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
selectProjectName,
|
selectProjectName,
|
||||||
@@ -790,20 +794,21 @@ export default {
|
|||||||
}
|
}
|
||||||
.allCon {
|
.allCon {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
// height: 100%;
|
||||||
background-color: #f1f4f8;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
|
min-width: 933px;
|
||||||
// min-width: 1200px;
|
// min-width: 1200px;
|
||||||
// overflow-x: hidden;
|
// overflow-x: hidden;
|
||||||
// min-width: 1400px;
|
// min-width: 1400px;
|
||||||
// overflow: scroll;
|
// overflow: scroll;
|
||||||
|
background-color: rgba(245, 247, 250, 1);
|
||||||
.left {
|
.left {
|
||||||
margin-right: 20px;
|
margin-right: 20px;
|
||||||
width: 208px;
|
width: 208px;
|
||||||
// height: 100%;
|
// height: 100%;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
// flex: 1;
|
// flex: 1;
|
||||||
height: 100%;
|
// height: 100%;
|
||||||
background: #ffffff;
|
background: #ffffff;
|
||||||
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
|
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -900,9 +905,8 @@ export default {
|
|||||||
}
|
}
|
||||||
.right {
|
.right {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
height: 100%;
|
|
||||||
width: 100%;
|
|
||||||
// background-color: #fff;
|
// background-color: #fff;
|
||||||
|
flex-shrink: 0;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
.addhead {
|
.addhead {
|
||||||
@@ -967,18 +971,18 @@ export default {
|
|||||||
height: 60px;
|
height: 60px;
|
||||||
width: 1px;
|
width: 1px;
|
||||||
background-color: #e8effa;
|
background-color: #e8effa;
|
||||||
margin-right: 28px;
|
margin-right: 18px;
|
||||||
}
|
}
|
||||||
.img2 {
|
.img2 {
|
||||||
width: 42px;
|
width: 42px;
|
||||||
height: 42px;
|
height: 42px;
|
||||||
margin-right: 22px;
|
margin-right: 18px;
|
||||||
}
|
}
|
||||||
.pub {
|
.pub {
|
||||||
color: #ffb64e;
|
color: #ffb64e;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
margin-right: 30px;
|
margin-right: 18px;
|
||||||
}
|
}
|
||||||
.return {
|
.return {
|
||||||
color: #4ea6ff;
|
color: #4ea6ff;
|
||||||
@@ -1059,8 +1063,8 @@ export default {
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
margin-left: 46px;
|
margin-left: 38px;
|
||||||
margin-right: 46px;
|
margin-right: 38px;
|
||||||
.img {
|
.img {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
@@ -1090,7 +1094,7 @@ export default {
|
|||||||
justify-content: center;
|
justify-content: center;
|
||||||
.boomcen {
|
.boomcen {
|
||||||
width: 95%;
|
width: 95%;
|
||||||
height: 100%;
|
// height: 100%;
|
||||||
// background-color: #bfa;
|
// background-color: #bfa;
|
||||||
.select {
|
.select {
|
||||||
margin-top: 30px;
|
margin-top: 30px;
|
||||||
@@ -1140,12 +1144,11 @@ export default {
|
|||||||
}
|
}
|
||||||
.ant-table-selection-column {
|
.ant-table-selection-column {
|
||||||
padding: 0px !important;
|
padding: 0px !important;
|
||||||
padding-left: 68px !important;
|
padding-left: 60px !important;
|
||||||
}
|
}
|
||||||
.ant-table-thead > tr > th {
|
.ant-table-thead > tr > th {
|
||||||
background-color: rgba(239, 244, 252, 1);
|
background-color: rgba(239, 244, 252, 1);
|
||||||
}
|
}
|
||||||
// margin: 20px 38px 30px;
|
|
||||||
th.h {
|
th.h {
|
||||||
background-color: #eff4fc !important;
|
background-color: #eff4fc !important;
|
||||||
}
|
}
|
||||||
@@ -1233,7 +1236,7 @@ export default {
|
|||||||
height: 14px;
|
height: 14px;
|
||||||
background-image: url("../../assets/images/leveladd/z1.png");
|
background-image: url("../../assets/images/leveladd/z1.png");
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: -47px;
|
left: -40px;
|
||||||
}
|
}
|
||||||
.ch {
|
.ch {
|
||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
|
|||||||
Reference in New Issue
Block a user