3
0
Fork 0

style(noticePopup): 代码格式化

This commit is contained in:
ywk 2025-04-11 10:43:47 +08:00
parent 6b2e35480b
commit 2d9af0472d
1 changed files with 56 additions and 50 deletions

View File

@ -5,26 +5,28 @@
* @Date: 2022-08-08 10:42:29
-->
<template>
<u-popup :show="noticeFlag" class="notice" width="70%" @close="closeTap"
mode="center">
<u-popup
:show="noticeFlag"
class="notice"
width="70%"
@close="closeTap"
mode="center"
>
<div class="title">
{{ content.title }}
</div>
<div class="close-icons" @click="closeTap">
<u-icon name="close"></u-icon>
</div>
<div class="close-icons" @click="closeTap">
<u-icon name="close"></u-icon>
</div>
<div class="img-auto" v-html="content.content"></div>
<!-- <div class="surebtn1">-->
<!-- <div class="btn hh" @click="closeTap">取消</div>-->
<!-- <div class="btn " @click="closeTap">{{ '确认' }}</div>-->
<!-- </div>-->
</u-popup>
</template>
<script>
import * as api from '@/config/login.js'
export default {
name: "Title",
name: 'Title',
props: {
userInfo: {
type: Object,
@ -36,47 +38,49 @@ export default {
data() {
return {
noticeFlag: false,
content: "",
};
content: '',
}
},
mounted() {
this.getUserTc();
this.getUserTc()
},
methods: {
closeTap(){
this.noticeFlag = false
// this.$emit("getTree");
},
closeTap() {
this.noticeFlag = false
// this.$emit("getTree");
},
getUserTc(data) {
api.indexPopScreen({
grade: this.userInfo.pkGradeId,
awards: this.userInfo.pkAwardsId,
}).then((res) => {
if (res.code == "200") {
let list = JSON.parse(localStorage.getItem("menuList"));
let arr = res.data[0].publishLocation.split(",");
arr.forEach((items) => {
if (items == this.publishLocationIndex) {
this.noticeFlag = true;
this.content = res.data[0];
}
});
}
});
api
.indexPopScreen({
grade: this.userInfo.pkGradeId,
awards: this.userInfo.pkAwardsId,
})
.then(res => {
if (res.code == '200') {
let list = JSON.parse(localStorage.getItem('menuList'))
let arr = res.data[0].publishLocation.split(',')
arr.forEach(items => {
if (items == this.publishLocationIndex) {
this.noticeFlag = true
this.content = res.data[0]
}
})
}
})
},
},
};
}
</script>
<style lang="scss" scoped>
.close-icons{
position: absolute;
right: 30rpx;
top: 30rpx;
}
::v-deep .u-popup__content{
height: 1120rpx;
width: 690rpx;
.close-icons {
position: absolute;
right: 30rpx;
top: 30rpx;
}
::v-deep .u-popup__content {
height: 1120rpx;
width: 690rpx;
}
// .notice{
// height: 700rpx;
@ -86,12 +90,12 @@ export default {
//visibility: hidden;
color: #333;
}
::v-deep .el-dialog{
margin-top:113px !important;
height:815px;
::v-deep .el-dialog {
margin-top: 113px !important;
height: 815px;
margin-bottom: 0;
}
::v-deep .el-dialog__body{
::v-deep .el-dialog__body {
padding-bottom: 20px;
}
.surebtn1 {
@ -107,7 +111,9 @@ export default {
border-radius: 6px 6px 6px 6px;
text-align: center;
font-size: 22px;
font-family: PingFang SC-Medium, PingFang SC;
font-family:
PingFang SC-Medium,
PingFang SC;
font-weight: 500;
color: #ffffff;
line-height: 66px;
@ -133,9 +139,9 @@ export default {
padding-top: 10px;
}
.title {
font-size: 40rpx;
text-align: center;
margin: 20rpx auto;
font-size: 40rpx;
text-align: center;
margin: 20rpx auto;
color: #333;
font-weight: bold;
}