Browse Source

单位考评公告详情,首页查看公告详情,移动端单位考评公告详情中的公告内容文本处理格式;根据后端需要修改前端功能

SunZehao 1 year ago
parent
commit
8d21d91796

+ 1 - 1
src/components/evaluationSystem/ruleDetailPage.vue

@@ -73,7 +73,7 @@
                             <div class="periodFrom">
                                 <el-form :model="itemForm" :rules="rules" ref="itemForm" label-width="100px" :validate-on-rule-change="false">
                                     <el-form-item label="指标名称" prop="indicator">
-                                        <el-select v-model="itemForm.indicator" placeholder="请选择指标名称">
+                                        <el-select v-model="itemForm.indicator" placeholder="请选择指标名称" filterable>
                                             <el-option
                                             v-for="item in indicItemoptions"
                                             :key="item.id"

+ 9 - 1
src/components/gateWay/gateWayNotificationDetail.vue

@@ -94,10 +94,18 @@ export default {
         init(row) {
             this.dialogVisible = true
             this.filesListEdit = []
+            let conStr = ''
+            for(let i in row.noticeContent) {
+                let it = row.noticeContent[i]
+                if (it === ' ' && i !== 0 && row.noticeContent[i-1] !== ' ') {
+                    it = it+'\n'
+                }
+                conStr += it 
+            }
             this.ruleForm = {
                 serialNumber: row.serialNumber*1,
                 noticeTitle: row.noticeTitle,
-                noticeContent: row.noticeContent,
+                noticeContent: conStr,
                 sendTo: row.sendTo,
                 sendToContent: row.sendToContent.split(','),
                 releaseDept: row.releaseDept,

+ 13 - 9
src/components/gatewaynNewPage.vue

@@ -90,7 +90,8 @@
                             <div class="mainThreeMsg">
                                 <img :src="item.img" alt="">
                                 <div class="msgProgress">
-                                    <span :style="winPix === 1.25?'font-size: 12px;width: 65%':''">{{item.company}}</span>
+                                    <span
+                                        :style="winPix === 1.25?'font-size: 12px;width: 65%':''">{{item.company}}</span>
                                     <span>{{item.grade}}</span>
                                     <span :style="winPix === 1.25?'width: 25%':''">{{item.score}}</span>
                                 </div>
@@ -153,7 +154,7 @@
                 </div>
                 <div class="tableFooter">
                     <div class="footerOne">
-                         <!-- :style="getFooterOneSty()" -->
+                        <!-- :style="getFooterOneSty()" -->
                         <span>煤电一体化</span>
                     </div>
                     <div class="footerTwo">
@@ -268,7 +269,8 @@
     import cenImg from '../assets/getwayImg/cenNew.png'
 
     import {
-        apiGetevaluationportallist,apiGetevaluationportalhomeSeason,
+        apiGetevaluationportallist,
+        apiGetevaluationportalhomeSeason,
         apiGetevaluationCircularDisplaylist
     } from '../api/api'
 
@@ -328,7 +330,7 @@
             // 获取首页年份和季度数据
             getYearSeasonData() {
                 let that = this
-                apiGetevaluationportalhomeSeason().then(datas =>{
+                apiGetevaluationportalhomeSeason().then(datas => {
                     if (datas.success) {
                         if (datas.data) {
                             that.changeYear = datas.data.year
@@ -809,7 +811,7 @@
                     position: relative;
 
                     @media screen and (width: 1440px) {
-                        .mainTwoMsg{
+                        .mainTwoMsg {
                             top: -15%;
                         }
                     }
@@ -1004,17 +1006,19 @@
                 display: flex;
                 // height: 100px;
                 height: 10vh;
+
                 @media screen and (max-width: 1540px) and (min-width: 1440px) {
-                    .footerOne{
-                        span{
+                    .footerOne {
+                        span {
                             font-size: 12px;
                             line-height: 12px;
                         }
                     }
                 }
+
                 @media screen and (width: 1920px) {
-                    .footerOne{
-                        span{
+                    .footerOne {
+                        span {
                             font-size: 16px;
                             line-height: 16px;
                         }

+ 18 - 7
src/components/notification/notificationMangePage.vue

@@ -102,8 +102,10 @@
                             <el-input v-model="ruleForm.noticeTitle"  placeholder="请输入公告标题" />
                         </el-form-item>
                         <el-form-item label="公告内容" prop="noticeContent">
-                            <el-input v-model="ruleForm.noticeContent"
-                                type="textarea" :rows="10" placeholder="请输入公告内容"></el-input>
+                            <!-- <pre v-if="isSave">{{ruleForm.noticeContent}}</pre> -->
+                            <el-input v-model="ruleForm.noticeContent" :disabled="isSave"
+                            type="textarea" :rows="10" placeholder="请输入公告内容"></el-input>
+                            
                         </el-form-item>
                         <el-form-item label="发布对象" prop="sendTo">
                             <el-select v-model="ruleForm.sendTo" placeholder="请选择发布对象">
@@ -449,10 +451,10 @@ export default {
                 sendTo: that.ruleForm.sendTo,
                 sendToContent: that.ruleForm.sendToContent.join(','),
                 releaseState: type === '草稿'? '草稿': type === '发布'?'已发布':'未发布',
-                releaseDept: that.userMes.deptId,
-                releaseDeptName: that.userMes.deptName,
-                releasePeople: that.userMes.id,
-                releasePeopleName: that.userMes.name
+                // releaseDept: that.userMes.deptId,
+                // releaseDeptName: that.userMes.deptName,
+                // releasePeople: that.userMes.id,
+                // releasePeopleName: that.userMes.name
             }
             const formData = new FormData()
             if (that.filesList.length>0) {
@@ -537,10 +539,19 @@ export default {
             } else {
                 this.evalradio = this.changeDateSelect[0]
             }
+            
+            let conStr = ''
+            for(let i in this.evalradio.noticeContent) {
+                let it = this.evalradio.noticeContent[i]
+                if (it === ' ' && i !== 0 && this.evalradio.noticeContent[i-1] !== ' ') {
+                    it = it+'\n'
+                }
+                conStr += it 
+            }
             this.ruleForm = {
                 serialNumber: this.evalradio.serialNumber*1,
                 noticeTitle: this.evalradio.noticeTitle,
-                noticeContent: this.evalradio.noticeContent,
+                noticeContent: conStr,
                 sendTo: this.evalradio.sendTo,
                 sendToContent: this.evalradio.sendToContent.split(','),
                 releaseDept: this.evalradio.releaseDept,

+ 9 - 1
src/mobeilComponent/notificationPageDetail.vue

@@ -94,10 +94,18 @@ export default {
     methods: {
         init(row) {
             this.filesListEdit = []
+            let conStr = ''
+            for(let i in row.noticeContent) {
+                let it = row.noticeContent[i]
+                if (it === ' ' && i !== 0 && row.noticeContent[i-1] !== ' ') {
+                    it = it+'\n'
+                }
+                conStr += it 
+            }
             this.ruleForm = {
                 serialNumber: row.serialNumber*1,
                 noticeTitle: row.noticeTitle,
-                noticeContent: row.noticeContent,
+                noticeContent: conStr,
                 sendTo: row.sendTo,
                 sendToContent: row.sendToContent.split(','),
                 releaseDept: row.releaseDept,