Browse Source

视频详情页修改

zxm
zhangxiaomeng 1 year ago
parent
commit
fe32f48d2d
  1. 24
      kcui/src/api/kcInfo.js
  2. 52
      kcui/src/view/DhInfo.vue
  3. 75
      kcui/src/view/JsInfo.vue
  4. 68
      kcui/src/view/SpInfo.vue
  5. 55
      kcui/src/view/SpInfoXq.vue
  6. 70
      kcui/src/view/TWInfo.vue
  7. 58
      src/main/java/com/main/woka/Web/Controller/KcInfoController.java

24
kcui/src/api/kcInfo.js

@ -23,6 +23,30 @@ export function getSpList(data) {
})
}
export function getDhList(data) {
return request({
url: '/kcDoc/getDhList',
method: 'post',
data:data,
headers: {
'Authorization': 'Bearer '+ getToken() // 将 token 放在请求头中
}
})
}
export function getJsList(data) {
return request({
url: '/kcDoc/getJsList',
method: 'post',
data:data,
headers: {
'Authorization': 'Bearer '+ getToken() // 将 token 放在请求头中
}
})
}
export function editInfo(data) {
return request({

52
kcui/src/view/DhInfo.vue

@ -60,7 +60,7 @@
<div v-for="item in typeList" :key="item" style="position: relative;margin-right: 1vw;"
@click="changeType(item)">
<img v-if="twType==item" src="../assets/img/typeHeadChoose.png" style="width: 7vw;object-fit: contain;">
<img v-if="dhType1==item" src="../assets/img/typeHeadChoose.png" style="width: 7vw;object-fit: contain;">
<img v-else src="../assets/img/typeHead.png" style="width: 7vw;object-fit: contain;">
<div style="position: absolute;z-index: 12121;width: 100%;text-align: center;color: white;top: 15%;">
{{ item }}
@ -175,7 +175,7 @@
<script>
import headInfo from '@/components/Head.vue';
import Foot from "@/components/Foot.vue";
import {editInfo, getDocList, getTwInfo} from "@/api/kcInfo";
import {editInfo, getDhList, getInfo} from "@/api/kcInfo";
import Editor from "@/components/Editor.vue";
export default {
@ -198,10 +198,11 @@ export default {
{id: 4, name: "帮助文档", info: "Help"}
],
page: "动画显示",
typeList: ["起降", "飞行", "通信载荷使用", "探测载荷使用", "攻击载荷使用"],
typeList: ["全部", "起降", "飞行", "通信载荷使用", "探测载荷使用", "攻击载荷使用"],
contentList: [],
selectName: "",
twType: "",
dhType: "",
dhType1:"",
pageSize: 6,
pageNum: 1,
total: 0,
@ -228,7 +229,12 @@ export default {
this.$router.push('/' + info)
},
changeType(item) {
this.twType = item;
this.dhType1 = item;
if(this.dhType1=="全部"){
this.dhType = "";
}else {
this.dhType = this.dhType1
}
this.getContentList();
},
choosePage(item) {
@ -240,12 +246,14 @@ export default {
console.log("djaksjdklajsdk")
var data = {
name: this.selectName,
twType: this.twType,
dhType: this.dhType,
pageNum: this.pageNum,
pageSize: this.pageSize
}
getDocList(data).then((res) => {
getDhList(data).then((res) => {
console.log(res);
if(res.code!=500){
if(res.data.list!=undefined){
this.contentList = res.data.list;
this.total = res.data.total;
this.totalPage = res.data.totalPages;
@ -253,10 +261,10 @@ export default {
var aaa = 0;
this.onePagesList = [];
this.pagesList = [];
if (this.totalPage > 3) {
if (this.pageNum < this.totalPage - 3) {
for (let i = this.pageNum; i <= this.totalPage; i++) {
this.pagesList.push(i);
this.onePagesList.push(i);
aaa = aaa + 1;
@ -266,8 +274,28 @@ export default {
}
}
}
} else {
for (let i = 1; i <= this.totalPage; i++) {
this.pagesList.push(i);
this.onePagesList.push(i);
aaa = aaa + 1;
console.log(aaa);
if (aaa == 3) {
break;
}
}
}
}
}else {
if(res.msg=="token无效")
localStorage.clear();
this.$router.push('/')
}
console.log(this.onePagesList)
})
},
@ -275,8 +303,8 @@ export default {
var data = {
id: id
}
getTwInfo(data).then((res) => {
this.$router.push({path: '/TwInfoXq', query: {id: id, level: res.data.level, type: "tw"}})
getInfo(data).then((res) => {
this.$router.push({path: '/DhInfoXq', query: {id: id, level: res.data.level, type: "tw"}})
})
},
@ -290,7 +318,7 @@ export default {
var data = {
id: id
}
getTwInfo(data).then((res) => {
getInfo(data).then((res) => {
this.openInfo = true;
this.form.contentInfo = res.data.data.contentInfo

75
kcui/src/view/JsInfo.vue

@ -24,7 +24,8 @@
<img src="../assets/img/twCircle.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
<div style="width: 55%;text-align: center;">
{{ item.name }}</div>
{{ item.name }}
</div>
<img src="../assets/img/jiantouchoose.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
<img src="../assets/img/muluchoose.png"
@ -47,7 +48,7 @@
type="text"
placeholder="请输入"
v-model="selectName"
@keyup.enter = "getContentList()"
@keyup.enter="getContentList()"
/>
</div>
<div style="width: 7%;height: 70%;float: right;margin-right: 15%;" @click="getContentList()">
@ -60,7 +61,7 @@
<div v-for="item in typeList" :key="item" style="position: relative;margin-right: 1vw;"
@click="changeType(item)">
<img v-if="twType==item" src="../assets/img/typeHeadChoose.png" style="width: 7vw;object-fit: contain;">
<img v-if="jsType1==item" src="../assets/img/typeHeadChoose.png" style="width: 7vw;object-fit: contain;">
<img v-else src="../assets/img/typeHead.png" style="width: 7vw;object-fit: contain;">
<div style="position: absolute;z-index: 12121;width: 100%;text-align: center;color: white;top: 15%;">
{{ item }}
@ -175,7 +176,7 @@
<script>
import headInfo from '@/components/Head.vue';
import Foot from "@/components/Foot.vue";
import {editInfo, getDocList, getTwInfo} from "@/api/kcInfo";
import {editInfo, getJsList, getInfo} from "@/api/kcInfo";
import Editor from "@/components/Editor.vue";
export default {
@ -198,10 +199,11 @@ export default {
{id: 4, name: "帮助文档", info: "Help"}
],
page: "计算模块",
typeList: ["起降", "飞行", "通信载荷使用", "探测载荷使用", "攻击载荷使用"],
typeList: ["全部", "起降", "飞行", "通信载荷使用", "探测载荷使用", "攻击载荷使用"],
contentList: [],
selectName: "",
twType: "",
jsType: "",
jsType1: "",
pageSize: 6,
pageNum: 1,
total: 0,
@ -218,7 +220,7 @@ export default {
TxtValue: "",
id: 0,
fileList: [], //
isUpload:0,
isUpload: 0,
}
},
@ -228,7 +230,13 @@ export default {
this.$router.push('/' + info)
},
changeType(item) {
this.twType = item;
this.jsType1 = item;
if (this.jsType1 == "全部") {
this.jsType = "";
} else {
this.jsType = this.jsType1
}
this.getContentList();
},
choosePage(item) {
@ -240,12 +248,13 @@ export default {
console.log("djaksjdklajsdk")
var data = {
name: this.selectName,
twType: this.twType,
jsType: this.jsType,
pageNum: this.pageNum,
pageSize: this.pageSize
}
getDocList(data).then((res) => {
console.log(res);
getJsList(data).then((res) => {
if (res.code != 500) {
if(res.data.list!=undefined){
this.contentList = res.data.list;
this.total = res.data.total;
this.totalPage = res.data.totalPages;
@ -253,10 +262,10 @@ export default {
var aaa = 0;
this.onePagesList = [];
this.pagesList = [];
if (this.totalPage > 3) {
if (this.pageNum < this.totalPage - 3) {
for (let i = this.pageNum; i <= this.totalPage; i++) {
this.pagesList.push(i);
this.onePagesList.push(i);
aaa = aaa + 1;
@ -266,8 +275,27 @@ export default {
}
}
}
} else {
for (let i = 1; i <= this.totalPage; i++) {
this.pagesList.push(i);
this.onePagesList.push(i);
aaa = aaa + 1;
console.log(aaa);
if (aaa == 3) {
break;
}
}
}
console.log(this.onePagesList)
}
}else {
if(res.msg=="token无效")
localStorage.clear();
this.$router.push('/')
}
})
},
@ -275,8 +303,8 @@ export default {
var data = {
id: id
}
getTwInfo(data).then((res) => {
this.$router.push({path: '/TwInfoXq', query: {id: id, level: res.data.level, type: "tw"}})
getInfo(data).then((res) => {
this.$router.push({path: '/JsInfoXq', query: {id: id, level: res.data.level, type: "tw"}})
})
},
@ -290,7 +318,7 @@ export default {
var data = {
id: id
}
getTwInfo(data).then((res) => {
getInfo(data).then((res) => {
this.openInfo = true;
this.form.contentInfo = res.data.data.contentInfo
@ -302,8 +330,8 @@ export default {
for (let j = 0; j < imgs.length; j++) {
var ii = {
uuid:imgs[j].imgId,
url:imgs[j].imgUrl
uuid: imgs[j].imgId,
url: imgs[j].imgUrl
}
this.fileList.push(ii)
}
@ -358,16 +386,16 @@ export default {
var urlStr = "";
for (let f = 0; f < this.fileList.length; f++) {
if (f == 0) {
if(this.fileList[f].response!=null){
if (this.fileList[f].response != null) {
urlStr = this.fileList[f].response.data.url
}else {
} else {
urlStr = this.fileList[f].url
}
} else {
if(this.fileList[f].response!=null){
if (this.fileList[f].response != null) {
urlStr = urlStr + "," + this.fileList[f].response.data.url
}else {
} else {
urlStr = urlStr + "," + this.fileList[f].url
}
@ -524,6 +552,7 @@ export default {
color: #ffffff;
}
.password-input-container {
width: 70%;
height: 80%;
@ -532,6 +561,7 @@ export default {
top: 8%;
left: 10%;
}
input {
width: 90%;
height: 100%;
@ -539,11 +569,12 @@ input {
outline: none;
color: white; /* 文字颜色 */
background-color: transparent;
padding-left:3%;
padding-left: 3%;
position: absolute;
z-index: 2000;
}
input::placeholder {
color: white;
opacity: 1; /* Firefox 默认将 placeholder 的透明度设置为 0.54 */

68
kcui/src/view/SpInfo.vue

@ -24,7 +24,8 @@
<img src="../assets/img/twCircle.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
<div style="width: 55%;text-align: center;">
{{ item.name }}</div>
{{ item.name }}
</div>
<img src="../assets/img/jiantouchoose.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
<img src="../assets/img/muluchoose.png"
@ -45,7 +46,7 @@
type="text"
placeholder="请输入"
v-model="selectName"
@keyup.enter = "getContentList()"
@keyup.enter="getContentList()"
/>
</div>
<div style="width: 7%;height: 70%;float: right;margin-right: 15%;" @click="getContentList()">
@ -61,7 +62,7 @@
<img v-if="spType1==item" src="../assets/img/typeHeadChoose.png" style="width: 7vw;object-fit: contain;">
<img v-else src="../assets/img/typeHead.png" style="width: 7vw;object-fit: contain;">
<div style="position: absolute;z-index: 12121;width: 100%;text-align: center;color: white;top: 15%;" >
<div style="position: absolute;z-index: 12121;width: 100%;text-align: center;color: white;top: 15%;">
{{ item }}
</div>
</div>
@ -122,7 +123,7 @@
<div
style="width: 9%;text-decoration: underline;font-style: italic;display: flex;justify-content: space-around;margin-left: 1%;">
<div @click="editTw(item.id)">修改</div>
<!-- <div @click="deleteTw(item.id)">删除</div>-->
<!-- <div @click="deleteTw(item.id)">删除</div>-->
</div>
</div>
</div>
@ -177,7 +178,8 @@
>
<div v-if="!videoFlag && showVideoPath" style="display: flex; flex-wrap: wrap; gap: 10px;">
<div style="position: relative; flex: 1 1 calc(33.333% - 20px); min-width: 200px; margin-bottom: 10px;">
<video :src="showVideoPath" style="width:90%; height: auto;border-radius: 0.5vw;" class="avatar video-avatar" controls>
<video :src="showVideoPath" style="width:90%; height: auto;border-radius: 0.5vw;"
class="avatar video-avatar" controls>
您的浏览器不支持视频播放
</video>
<img
@ -190,7 +192,8 @@
</div>
<el-progress :stroke-width="10" class="progressType" v-if="videoFlag"
type="circle" :percentage="videoUploadPercent" style="margin-top:30px;"></el-progress>
<el-button style="z-index: 999;" class="video-btn" slot="trigger" size="small" type="primary">点击上传视频</el-button>
<el-button style="z-index: 999;" class="video-btn" slot="trigger" size="small" type="primary">点击上传视频
</el-button>
</el-upload>
</el-form-item>
@ -236,10 +239,10 @@ export default {
{id: 4, name: "帮助文档", info: "Help"}
],
page: "视频资源",
typeList: ["全部","起降", "飞行", "通信载荷使用", "探测载荷使用", "攻击载荷使用"],
typeList: ["全部", "起降", "飞行", "通信载荷使用", "探测载荷使用", "攻击载荷使用"],
contentList: [],
selectName: "",
spType1:"全部",
spType1: "全部",
spType: "",
pageSize: 6,
pageNum: 1,
@ -253,12 +256,12 @@ export default {
form: {
name: "",
contentInfo: "",
spType:"",
spType: "",
},
TxtValue: "",
id: 0,
fileList: [], //
isUpload:0,
isUpload: 0,
//
@ -272,7 +275,7 @@ export default {
videoFlag: false, //
videoUploadPercent: "", //
isShowUploadVideo: false, //
videoFileList:[],
videoFileList: [],
showVideoPath: "",
uploadUrl: "",//
}
@ -285,9 +288,9 @@ export default {
},
changeType(item) {
this.spType1 = item;
if(this.spType1=="全部"){
if (this.spType1 == "全部") {
this.spType = "";
}else {
} else {
this.spType = this.spType1
}
this.getContentList();
@ -306,7 +309,8 @@ export default {
pageSize: this.pageSize
}
getSpList(data).then((res) => {
console.log(res);
if (res.code != 500) {
if(res.data.list!=undefined){
this.contentList = res.data.list;
this.total = res.data.total;
this.totalPage = res.data.totalPages;
@ -314,7 +318,7 @@ export default {
var aaa = 0;
this.onePagesList = [];
this.pagesList = [];
if(this.totalPage>3){
if (this.totalPage > 3) {
if (this.pageNum < this.totalPage - 3) {
for (let i = this.pageNum; i <= this.totalPage; i++) {
@ -327,7 +331,7 @@ export default {
}
}
}
}else {
} else {
for (let i = 1; i <= this.totalPage; i++) {
this.pagesList.push(i);
@ -342,19 +346,27 @@ export default {
console.log(this.onePagesList)
}
}else {
if(res.msg=="token无效")
localStorage.clear();
this.$router.push('/')
}
})
},
goXq(id) {
this.$router.push({path: '/SpInfoXq', query: {id: id,type: "sp"}})
this.$router.push({path: '/SpInfoXq', query: {id: id, type: "sp"}})
},
//
//
deleteTw(id){
deleteTw(id) {
twdelete(id);
this.getContentList();
console.log("这是删除操作")
@ -374,7 +386,7 @@ export default {
this.videoFileList = [];
this.showVideoPath = "";
if (res.data.data.spUrl != null) {
this.videoFileList.push({ url: res.data.data.spUrl,name: res.data.data.name });
this.videoFileList.push({url: res.data.data.spUrl, name: res.data.data.name});
this.showVideoPath = res.data.data.spUrl;
}
@ -430,7 +442,7 @@ export default {
this.$message.warning('该视频已存在于列表中');
return;
}
this.videoFileList.push({ url: videoUrl, name: file.name });
this.videoFileList.push({url: videoUrl, name: file.name});
this.showVideoPath = this.videoFileList.map(f => f.url).join(',');
this.updateCourseUrl();
this.$message.success('视频上传成功');
@ -462,16 +474,16 @@ export default {
},
submitInfo() {
console.log(this.videoFileList);
if(this.form.spType=="全部"){
if (this.form.spType == "全部") {
this.form.spType = "";
}
var urlStr = this.videoFileList[0];
var data = {
name: this.form.name,
spUrl:urlStr.url,
type:2,
spUrl: urlStr.url,
type: 2,
id: this.id,
spType:this.form.spType
spType: this.form.spType
}
editInfo(data).then((res) => {
console.log(res);
@ -618,6 +630,7 @@ export default {
color: #ffffff;
}
.password-input-container {
width: 70%;
height: 80%;
@ -626,6 +639,7 @@ export default {
top: 8%;
left: 10%;
}
input {
width: 90%;
height: 100%;
@ -633,17 +647,19 @@ input {
outline: none;
color: white; /* 文字颜色 */
background-color: transparent;
padding-left:3%;
padding-left: 3%;
position: absolute;
z-index: 2000;
}
input::placeholder {
color: white;
opacity: 1; /* Firefox 默认将 placeholder 的透明度设置为 0.54 */
}
.m-video{
.m-video {
width: 12vw !important;
background: none !important;
}

55
kcui/src/view/SpInfoXq.vue

@ -1,6 +1,6 @@
<template>
<div style="width: 100%;height: 100%;">
<img style="width: 100%;height: 100%;position: absolute;z-index:-1;" src="../assets/img/twbg1.jpg">
<img style="width: 100%;height: 100%;position: absolute;z-index:-1;" src="../assets/img/twbg.png">
<headInfo style="position: absolute;z-index: 100"></headInfo>
<div class="content">
<div class="leftContent">
@ -12,21 +12,22 @@
</div>
<div class="leftBox2">
<div class="muluBox">
<img src="../assets/img/leftBox.png" style="width: 100%;object-fit: contain;z-index: 1;position: absolute;">
<div class="muluList">
<div v-for="item in mulu" :key="item">
<div class="oneMulu" v-if="page!=item" @click="goInfo(item.info)">
<div style="width: 80%;text-align: center;">{{ item.name }}</div>
<img src="../assets/img/jiantou.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 13%;">
</div>
<div class="oneMuluXuan" v-else>
<div class="oneMuluXuan" v-if="item.name === '图文资源'">
<img src="../assets/img/twCircle.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
<div style="width: 55%;text-align: center;">
{{ item.name }}</div>
<img src="../assets/img/jiantouchoose.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
<img src="../assets/img/muluchoose.png"
style="width: 19vw;height: 6vw;position: absolute;bottom: -3vw;left: -3.5vw;z-index: -1;"/>
</div>
<div class="oneMulu" v-else @click="goInfo(item.info)">
<div style="width: 80%;text-align: center;">{{ item.name }}</div>
<img src="../assets/img/jiantou.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 8%;">
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 13%;">
</div>
</div>
</div>
@ -46,6 +47,7 @@
<div style="width: 100%;height: 3%;position: fixed;bottom: 0px;z-index: 100">
<foot></foot>
</div>
@ -112,31 +114,29 @@ export default {
.content {
width: 100%;
height: 86%;
padding-top: 5%;
}
.leftContent {
width: 14%;
height: 100%;
float: left;
margin-top: 4.4%;
}
.leftBox1 {
width: 100%;
height: 10%;
margin-top: 12%;
margin-top: 5%;
color: #7cdeff;
}
.leftBox2 {
width: 100%;
height: 90%;
}
.muluBox {
margin: 3% 14%;
margin: 0 14%;
height: 92%;
width: 72%;
position: relative;
@ -160,24 +160,26 @@ export default {
height: 2.5vw;
line-height: 2.5vw;
font-size: 0.9vw;
border-bottom: 1px solid #0d3455;
border-bottom: 1px solid rgba(112, 192, 227, 0.47);
margin-left: 10%;
color: #d1d3d7;
display: flex;
flex-direction: row;
}
.oneMuluXuan {
background-image: url("../assets/img/xuan.png");
width: 90%;
height: 2.5vw;
line-height: 2.5vw;
line-height: 2.1vw;
font-size: 0.9vw;
color: #13ffff;
display: flex;
flex-direction: row;
padding-left: 10%;
position: relative;
}
@ -188,27 +190,28 @@ export default {
position: relative;
}
.contentInfo{
width: 100%;
height: 96%;
background-color: rgba(20, 119, 208, 0.82);
position: absolute;
z-index: 101;
margin-top: 7%;
margin-top: 2%;
border-radius: 1vw;
}
.contentTitle{
width: 100%;
height: 8%;
height: 5%;
margin-top: 0.5%;
font-size: 1.5vw;
color: #ffffff;
color: #03f7f7;
text-align: center;
letter-spacing: 5px;
line-height: 3vw;
display: flex;
align-items: center;
justify-content: center;
position: relative;
}
.contentText{
width: 96%;

70
kcui/src/view/TWInfo.vue

@ -24,7 +24,8 @@
<img src="../assets/img/twCircle.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
<div style="width: 55%;text-align: center;">
{{ item.name }}</div>
{{ item.name }}
</div>
<img src="../assets/img/jiantouchoose.png"
style="width: 0.9vw;height:0.9vw;object-fit: contain;float: right;margin-top: 7%;">
@ -48,7 +49,7 @@
type="text"
placeholder="请输入"
v-model="selectName"
@keyup.enter = "getContentList()"
@keyup.enter="getContentList()"
/>
</div>
<div style="width: 6%;height: 70%;float: right;margin-right: 18%;margin-top: 1%;" @click="getContentList()">
@ -122,7 +123,7 @@
<div
style="width: 9%;text-decoration: underline;font-style: italic;display: flex;justify-content: space-around;margin-left: 1%;">
<div @click="editTw(item.id)">修改</div>
<!-- <div @click="deleteTw(item.id)">删除</div>-->
<!-- <div @click="deleteTw(item.id)">删除</div>-->
</div>
</div>
</div>
@ -218,11 +219,11 @@ export default {
{id: 4, name: "帮助文档", info: "Help"}
],
page: "图文认知",
typeList: ["全部","海洋大气", "海洋文学", "海洋地理", "复杂水声", "复杂电磁"],
typeList: ["全部", "海洋大气", "海洋文学", "海洋地理", "复杂水声", "复杂电磁"],
contentList: [],
selectName: "",
twType: "",
twType1:"全部",
twType1: "全部",
pageSize: 6,
pageNum: 1,
total: 0,
@ -235,12 +236,12 @@ export default {
form: {
name: "",
contentInfo: "",
twType:"",
twType: "",
},
TxtValue: "",
id: 0,
fileList: [], //
isUpload:0,
isUpload: 0,
}
},
@ -251,9 +252,9 @@ export default {
},
changeType(item) {
this.twType1 = item;
if(this.twType1=="全部"){
if (this.twType1 == "全部") {
this.twType = "";
}else {
} else {
this.twType = this.twType1
}
this.getContentList();
@ -272,7 +273,8 @@ export default {
pageSize: this.pageSize
}
getDocList(data).then((res) => {
console.log(res);
if (res.code != 500) {
if(res.data.list!=undefined){
this.contentList = res.data.list;
this.total = res.data.total;
this.totalPage = res.data.totalPages;
@ -280,18 +282,39 @@ export default {
var aaa = 0;
this.onePagesList = [];
this.pagesList = [];
if (this.totalPage > 3) {
if (this.pageNum < this.totalPage - 3) {
for (let i = this.pageNum; i <= this.totalPage; i++) {
this.pagesList.push(i);
this.onePagesList.push(i);
aaa = aaa + 1;
console.log(aaa);
if (aaa == 4) {
break;
}
}
}
} else {
for (let i = 1; i <= this.totalPage; i++) {
this.pagesList.push(i);
this.onePagesList.push(i);
aaa = aaa + 1;
console.log(aaa);
if (aaa == 3) {
break;
}
}
}
}
}else {
if(res.msg=="token无效")
localStorage.clear();
this.$router.push('/')
}
})
},
@ -324,12 +347,12 @@ export default {
this.id = id;
var imgs = res.data.data.imgList;
console.log(imgs)
this.fileList =[];
this.fileList = [];
for (let j = 0; j < imgs.length; j++) {
var ii = {
uuid:imgs[j].imgId,
url:imgs[j].imgUrl
uuid: imgs[j].imgId,
url: imgs[j].imgUrl
}
this.fileList.push(ii)
}
@ -384,22 +407,22 @@ export default {
var urlStr = "";
for (let f = 0; f < this.fileList.length; f++) {
if (f == 0) {
if(this.fileList[f].response!=null){
if (this.fileList[f].response != null) {
urlStr = this.fileList[f].response.data.url
}else {
} else {
urlStr = this.fileList[f].url
}
} else {
if(this.fileList[f].response!=null){
if (this.fileList[f].response != null) {
urlStr = urlStr + "," + this.fileList[f].response.data.url
}else {
} else {
urlStr = urlStr + "," + this.fileList[f].url
}
}
}
if(this.form.twType=="全部"){
if (this.form.twType == "全部") {
this.form.twType = "";
}
var data = {
@ -407,8 +430,8 @@ export default {
contentInfo: this.TxtValue,
imgs: urlStr,
id: this.id,
type:1,
twType:this.form.twType,
type: 1,
twType: this.form.twType,
}
editInfo(data).then((res) => {
console.log(res);
@ -555,6 +578,7 @@ export default {
color: #ffffff;
}
.password-input-container {
width: 70%;
height: 80%;
@ -563,6 +587,7 @@ export default {
top: 8%;
left: 10%;
}
input {
width: 90%;
height: 100%;
@ -570,11 +595,12 @@ input {
outline: none;
color: white; /* 文字颜色 */
background-color: transparent;
padding-left:3%;
padding-left: 3%;
position: absolute;
z-index: 2000;
}
input::placeholder {
color: white;
opacity: 1; /* Firefox 默认将 placeholder 的透明度设置为 0.54 */

58
src/main/java/com/main/woka/Web/Controller/KcInfoController.java

@ -88,6 +88,64 @@ public class KcInfoController extends BaseController {
}
@PostMapping(value = "/getDhList")
public AjaxResult getDhList(@RequestBody KcInfo kcInfo) {
int pageNum = kcInfo.getPageNum() == null ? 1 : kcInfo.getPageNum();
int pageSize = kcInfo.getPageSize() == null ? 10 : kcInfo.getPageSize();
int offset = (pageNum - 1) * pageSize;
kcInfo.setOffset(offset);
kcInfo.setType(3l);
Long total = kcFileMapper.getKcCount(kcInfo);
List<KcInfo> list = kcFileMapper.getkcList(kcInfo);
int totalPages = (int) Math.ceil((double) total / pageSize);
AjaxResult ajax = new AjaxResult();
ajax.put("list", list);
ajax.put("total", total);
ajax.put("totalPages", totalPages);
ajax.put("pageSize", pageSize);
return AjaxResult.success(ajax);
// return null;
}
@PostMapping(value = "/getJsList")
public AjaxResult getJsList(@RequestBody KcInfo kcInfo) {
int pageNum = kcInfo.getPageNum() == null ? 1 : kcInfo.getPageNum();
int pageSize = kcInfo.getPageSize() == null ? 10 : kcInfo.getPageSize();
int offset = (pageNum - 1) * pageSize;
kcInfo.setOffset(offset);
kcInfo.setType(4l);
Long total = kcFileMapper.getKcCount(kcInfo);
List<KcInfo> list = kcFileMapper.getkcList(kcInfo);
int totalPages = (int) Math.ceil((double) total / pageSize);
AjaxResult ajax = new AjaxResult();
ajax.put("list", list);
ajax.put("total", total);
ajax.put("totalPages", totalPages);
ajax.put("pageSize", pageSize);
return AjaxResult.success(ajax);
// return null;
}
//管理员修改文件
@GetMapping("/getInfo")
public AjaxResult editInfo(@RequestParam("id") Long id) {

Loading…
Cancel
Save