浏览代码

首页 [企业公告] 轮播、接口数据完成

liangyan0105 3 年之前
父节点
当前提交
c8c6eea3a0

+ 8 - 0
src/assets/less/dataVTable.css

@@ -0,0 +1,8 @@
+.dv-scroll-board {
+  color: #354f52 !important;
+}
+.board .row-item .ceil:first-child {
+  background-color: yellow !important;
+  display: none;
+  margin-right: 40px;
+}

+ 16 - 0
src/assets/less/dataVTable.less

@@ -0,0 +1,16 @@
+// 首页轮播图 样式覆盖
+.dv-scroll-board {
+  color: #354f52 !important;
+}
+.board {
+  /deep/.ant-tabs-tab:last-child {
+  }
+  .row-item {
+    //隐藏轮播企业公告 的ID 属性 
+    .ceil:first-child {
+      background-color: yellow !important;
+      display: none;
+      margin-right: 40px;
+    }
+  }
+}

+ 198 - 0
src/assets/less/mytodo.css

@@ -0,0 +1,198 @@
+ul li {
+  list-style: none;
+}
+a {
+  text-decoration: none;
+}
+.fl {
+  float: left;
+}
+.fr {
+  float: right;
+}
+.clearfix:before,
+.clearfix:after {
+  content: '';
+  display: table;
+}
+.clearfix:after {
+  clear: both;
+  overflow: hidden;
+}
+.clearfix {
+  *zoom: 1;
+}
+ /deep/ .ant-card-head-title {
+  color: #1890ff;
+}
+.fullCard {
+  height: 380px;
+}
+.fullCard /deep/ .ant-card-body {
+  padding: 0 4px;
+}
+.ccfullCalendar {
+  height: 274px !important;
+}
+.ccfullCalendar /deep/ .ant-fullcalendar-header {
+  display: none;
+}
+.ccfullCalendar /deep/ .ant-fullcalendar {
+  border-top: none;
+}
+.ccfullCalendar /deep/ .ant-fullcalendar-calendar-body {
+  padding: 0;
+}
+.ccfullCalendar /deep/ .fc .fc-toolbar.fc-header-toolbar {
+  margin-bottom: 6px;
+}
+.ccfullCalendar /deep/ .fc .fc-scrollgrid-liquid {
+  height: 274px !important;
+}
+.ccfullCalendar /deep/ .fc .fc-toolbar-title {
+  font-size: 14px;
+  letter-spacing: 1px;
+}
+.ccfullCalendar /deep/ .fc-scrollgrid-sync-table {
+  height: 274px !important;
+}
+.ccfullCalendar /deep/ .fc-daygrid-day-bottom {
+  margin-top: -10px !important;
+}
+.ccfullCalendar /deep/ .fc .fc-button-primary {
+  background-color: #1890ff;
+  margin-top: 4px;
+  border: none;
+}
+.ccfullCalendar /deep/ .fc .fc-toolbar-title {
+  color: #333;
+  font-size: 16px;
+}
+#home .topCard .topColItem {
+  height: 380px;
+}
+#home .topCard .userImg {
+  width: 80px;
+  height: 80px;
+}
+#home .topCard .userImg img {
+  border-radius: 6px;
+  width: 100%;
+}
+#home .topCard .userInfo span {
+  margin-left: 60px;
+  display: block;
+  line-height: 26px;
+}
+#home .topCard .userInfo span .department {
+  font-size: 14px;
+  color: #474646;
+}
+#home .topCard .msgBox span {
+  font-size: 38px;
+  color: #fa6b5c;
+  text-shadow: 2px 2px 1px #5e5e5e;
+}
+#home .topCard .msgBox p {
+  font-size: 16px;
+}
+#home .oaBtn {
+  background-color: white;
+  padding: 20px;
+  margin-right: 1%;
+}
+#home .oaBtn .oaButton {
+  display: flex;
+  flex-flow: row wrap;
+  text-align: center;
+}
+#home .oaBtn .oaButton .oaItem {
+  line-height: 0px;
+  width: calc((100% - 100px) / 3);
+  justify-content: space-around;
+  flex-direction: column;
+  align-items: center;
+  margin-bottom: 10px;
+  margin-right: 1px;
+}
+#home .oaBtn .oaButton .oaItem span {
+  margin: 0 aotu;
+  border: transparent;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  position: relative;
+}
+#home .oaBtn .oaButton .oaItem span img {
+  width: 34px;
+  height: 34px;
+}
+#home .oaBtn .oaButton .oaItem p {
+  margin-top: 14px;
+  font-size: 14px;
+  color: #807f7f;
+  font-weight: 400;
+  letter-spacing: 1px;
+}
+#home .news .newsColItem {
+  height: 400px;
+}
+#home .news .notice ul {
+  margin: 0;
+  padding: 0;
+}
+#home .news .notice ul li {
+  line-height: 30px;
+}
+#home .news .notice ul li a {
+  font-size: 14px;
+  color: #444;
+}
+#home .news .notice ul li a .department {
+  margin-right: 10px;
+}
+#home .news .notice ul li a .createBy {
+  color: #333;
+}
+#home .news .notice ul li a .createTime {
+  color: #a4a4a4;
+  margin: 0 4px 0 20px;
+}
+#home .news .notice ul li a:hover {
+  color: #1890ff;
+}
+#home .news .plan .total span {
+  display: block;
+  line-height: 40px;
+}
+#home .news .plan .total span strong {
+  color: #fa6b5c;
+  text-decoration: underline;
+  margin-right: 4px;
+}
+#home .news .link .linkBtn {
+  display: flex;
+  flex-flow: row wrap;
+  justify-content: space-between;
+}
+#home .news .link .linkBtn button {
+  border-radius: 2px;
+  border: none;
+  background-color: rgba(102, 155, 188, 0.7);
+  width: calc((100% - 60px) / 2);
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  margin-bottom: 10px;
+  padding: 10px 0;
+  letter-spacing: 1px;
+}
+#home .news .link .linkBtn button a {
+  color: white;
+  font-size: 12px;
+}
+#home .news .link .linkBtn button:hover {
+  background-color: #003049;
+  color: white;
+  box-shadow: 1px 1px 3px #333;
+}

+ 238 - 0
src/assets/less/mytodo.less

@@ -0,0 +1,238 @@
+// mytodo页面专用样式
+ul li {
+  list-style: none;
+}
+a {
+  text-decoration: none;
+}
+.fl {
+  float: left;
+}
+.fr {
+  float: right;
+}
+
+.clearfix:before,
+.clearfix:after {
+  content: '';
+  display: table;
+}
+
+.clearfix:after {
+  clear: both;
+  overflow: hidden;
+}
+
+.clearfix {
+  *zoom: 1;
+}
+
+/deep/ .ant-card-head-title {
+  color: #1890ff;
+}
+
+//包着card
+.fullCard {
+  height: 380px;
+  /deep/ .ant-card-body {
+    padding: 0 4px;
+  }
+}
+// 日历
+.ccfullCalendar {
+  height: 274px !important;
+  // 年月选择消失
+  /deep/ .ant-fullcalendar-header {
+    display: none;
+  }
+  // 线消息
+  /deep/ .ant-fullcalendar {
+    border-top: none;
+  }
+
+  /deep/ .ant-fullcalendar-calendar-body {
+    padding: 0;
+  }
+
+  /deep/ .fc .fc-toolbar.fc-header-toolbar {
+    margin-bottom: 6px;
+  }
+  /deep/ .fc .fc-scrollgrid-liquid {
+    height: 274px !important;
+  }
+  /deep/ .fc .fc-toolbar-title {
+    font-size: 14px;
+    letter-spacing: 1px;
+  }
+  /deep/ .fc-scrollgrid-sync-table {
+    height: 274px !important;
+  }
+  /deep/ .fc-daygrid-day-bottom {
+    margin-top: -10px !important;
+  }
+  /deep/ .fc .fc-button-primary {
+    background-color: #1890ff;
+    margin-top: 4px;
+    border: none;
+  }
+  /deep/ .fc .fc-toolbar-title {
+    color: #333;
+    font-size: 16px;
+  }
+}
+#home {
+  // 第一行
+  .topCard {
+    // 等高设置
+    .topColItem {
+      height: 380px;
+    }
+    .userImg {
+      width: 80px;
+      height: 80px;
+      img {
+        border-radius: 6px;
+        width: 100%;
+      }
+    }
+    .userInfo {
+      span {
+        margin-left: 60px;
+        display: block;
+        line-height: 26px;
+        .department {
+          font-size: 14px;
+          color: rgb(71, 70, 70);
+        }
+      }
+    }
+    // 消息
+    .msgBox {
+      span {
+        font-size: 38px;
+        color: #fa6b5c;
+        text-shadow: 2px 2px 1px rgb(94, 94, 94);
+      }
+      p {
+        font-size: 16px;
+      }
+    }
+  }
+  // OA工作台
+  .oaBtn {
+    background-color: white;
+    padding: 20px;
+    margin-right: 1%;
+    .oaButton {
+      display: flex;
+      flex-flow: row wrap;
+      text-align: center;
+      .oaItem {
+        line-height: 0px;
+        // width: 25%;
+        width: calc((100% - 100px) / 3);
+        justify-content: space-around;
+        flex-direction: column;
+        align-items: center;
+        margin-bottom: 10px;
+        margin-right: 1px;
+        // 图
+        span {
+          margin: 0 aotu;
+          border: transparent;
+          display: flex;
+          align-items: center;
+          justify-content: center;
+          position: relative;
+          img {
+            width: 34px;
+            height: 34px;
+          }
+        }
+        // 文字
+        p {
+          margin-top: 14px;
+          font-size: 14px;
+          color: rgb(128, 127, 127);
+          font-weight: 400;
+          letter-spacing: 1px;
+        }
+      }
+    }
+  }
+  // 公告
+  .news {
+    .newsColItem {
+      height: 400px;
+    }
+    .notice {
+      ul {
+        margin: 0;
+        padding: 0;
+        li {
+          line-height: 30px;
+          a {
+            font-size: 14px;
+            color: #444;
+            .department {
+              margin-right: 10px;
+            }
+            .createBy {
+              color: #333;
+            }
+            .createTime {
+              color: rgb(164, 164, 164);
+              margin: 0 4px 0 20px;
+            }
+          }
+          a:hover {
+            color: #1890ff;
+          }
+        }
+      }
+    }
+    // 我的计划
+    .plan {
+      .total {
+        span {
+          display: block;
+          line-height: 40px;
+          strong {
+            color: #fa6b5c;
+            text-decoration: underline;
+            margin-right: 4px;
+          }
+        }
+      }
+    }
+    // 友情链接
+    .link {
+      .linkBtn {
+        display: flex;
+        flex-flow: row wrap;
+        justify-content: space-between;
+        button {
+          border-radius: 2px;
+          border: none;
+          background-color: rgba(102, 155, 188, 0.7);
+          width: calc((100% - 60px) / 2);
+          display: flex;
+          justify-content: center;
+          align-items: center;
+          margin-bottom: 10px;
+          padding: 10px 0;
+          letter-spacing: 1px;
+          a {
+            color: white;
+            font-size: 12px;
+          }
+        }
+        button:hover {
+          background-color: #003049;
+          color: white;
+          box-shadow: 1px 1px 3px #333;
+        }
+      }
+    }
+  }
+}

+ 57 - 283
src/views/dashboard/MyToDo.vue

@@ -83,9 +83,15 @@
                 <a href="javascript:void(0);" @click="openEnterAnn">更多</a>
               </template>
 
-              <!-- DataV -->
+              <!-- DataV 轮播表-->
               <div class="dataV">
-                <dv-scroll-board :config="config" style="width:100%;height:300px;" @click="getMethod" />
+                <dv-scroll-board
+                  class="board"
+                  :rowNum="10"
+                  :config="config"
+                  style="width:100%;height:300px;color:#333;paddinLeft:40px;"
+                  @click="getMethod"
+                />
               </div>
               <!-- DataV -->
             </a-card>
@@ -227,8 +233,8 @@
       </component>
     </a-modal>
 
-    <!-- 公告详情 弹框  组件 -->
-    <detAnn-modal ref="DetAnnModal" @ok="modalFormOk" :fatherGetList="getAnnList"></detAnn-modal>
+    <!-- 公告详情 弹框  组件-->
+    <detAnn-modal ref="DetAnnModal" @ok="modalFormOk" :fatherData="annDetail"></detAnn-modal>
   </div>
 </template>
 
@@ -243,6 +249,7 @@ import timeGridPlugin from '@fullcalendar/timegrid'
 import SchedulePlan from '@views/oa/my-plan/schedulePlan'
 // import '@fullcalendar/core/main.css'
 import { scheduleGetListByTime, scheduleQueryById } from '@api/oa/cd-schedule'
+import { enterpriseEQueryById } from '@api/oa/cd-enterprise-announcement'
 import { enterpriseEList } from '@api/oa/cd-enterprise-announcement'
 import '@fullcalendar/daygrid/main.css'
 import JEditor from '../../components/jeecg/JEditor.vue'
@@ -256,12 +263,9 @@ export default {
   },
   data() {
     return {
-      config: {
-        waitTime: 2000, //轮播时间间隔
-        columnWidth: [2],
-        data: [] //全局变量轮播图数据
-      },
-
+      annDetail: {}, //公告详情 数据
+      annList: [], //公告列表 数据
+      config: {}, //轮播表配置
       //日历组件 参数
       calendarOptions: {
         // 日程数组
@@ -395,19 +399,46 @@ export default {
     this.getAnnList()
   },
   methods: {
-    //点击轮播图
-    getMethod(value) {
-      console.log(value)
+    // 公告数据 ----|**查询条件:已发布、数据条数**|------
+    async getAnnList() {
+      await enterpriseEList({ isRelease: '1', pageSize: 1000 }).then(res => {
+        if (res.success) {
+          console.log('轮播公告列表-->', res.result.records)
+          this.annList = res.result.records
+          let scrollData = [] //轮播表数据
+          // 拿到返回的数据进行遍历并渲染
+          this.annList.map(item => {
+            var list = [item.id, item.type, item.title, item.createBy, item.createTime]
+            scrollData.push(list) //取到的每一个数据放到轮播表数据中
+          })
+          //轮播配置
+          this.config = {
+            oddRowBGC: 'rgba(233, 236, 239,.8)',
+            evenRowBGC: 'rgba(188, 212, 230,.8)',
+            columnWidth: [10, 100, 460, 200, 300],
+            align: ['center'],
+            rowNum: 6,
+            waitTime: 2000,
+            data: scrollData //双向绑定(轮播表数据 绑定到配置的 data数据中)
+          }
+        }
+      })
     },
-
-    //公告详情
-    showAnnModal(item) {
-      this.$refs.DetAnnModal.annVisible = true
-      this.$refs.DetAnnModal.annDetail = item //传值给回显数组
-      console.log('点击公告的详情', this.annDetail)
-      this.$refs.DetAnnModal.myValue = this.$refs.DetAnnModal.annDetail.content
+    //轮播图 点击事件
+    getMethod(item) {
+      // =the data presentation is a bit sluggish 
+      // this.$refs.DetAnnModal.annVisible = true
+      // console.log('轮播自带的数据', item)
+      this.$nextTick(() => {
+        enterpriseEQueryById({ id: item.row[0] }).then(res => {
+          this.$refs.DetAnnModal.annVisible = true
+          if (res.success) {
+            console.log(res.result)
+            this.annDetail = res.result
+          }
+        })
+      })
     },
-
     //查询日程数据
     getScheduleData() {
       this.$nextTick(() => {
@@ -439,6 +470,7 @@ export default {
         })
       })
     },
+
     // 代办数据
     getDataList() {
       this.loading = true
@@ -468,25 +500,6 @@ export default {
       })
     },
 
-    // 公告数据 (查询条件:已发布、数据条数)
-    async getAnnList() {
-      await enterpriseEList({ isRelease: '1', pageSize: 1000 }).then(res => {
-        if (res.success) {
-          this.annList = res.result.records
-          console.log('轮播公告-->', this.annList)
-          let scrollData = [] //轮播表数据
-          // 拿到返回的数据进行遍历并渲染
-          this.annList.map(item => {
-            // console.log('mpa方法的item', item)
-            let list = [item.type, item.title, item.createBy, item.createTime]
-            scrollData.push(list)
-            // console.log('>>>', scrollData)
-          })
-          this.config = { data: scrollData } //双向绑定(轮播表数据绑定到配置的data数据中)
-        }
-      })
-    },
-
     handleEvents(info) {
       // console.log('what', info)
       // 打印了事件(完成、位置)
@@ -494,12 +507,6 @@ export default {
     },
     // 日期点击
     handleDateClick(selectInfo) {
-      // if (confirm('您是否要在【' + selectInfo.dateStr + '】添加一个新的事件?')) {
-      //   // 父组件直接调用子组件方法
-      //   this.$refs['eventDialogue'].openDialog('add')
-      //   // 父组件直接修改子组件变量
-      //   // this.$refs['eventDialogue'].dialogVisible = true
-      // }
       this.$router.push('/oa/my-plan/schedulePlan')
     },
     //企业公告
@@ -594,242 +601,9 @@ export default {
   }
 }
 </script>
-<style lang="less" scoped>
-ul li {
-  list-style: none;
-}
-a {
-  text-decoration: none;
-}
-.fl {
-  float: left;
-}
-.fr {
-  float: right;
-}
-
-.clearfix:before,
-.clearfix:after {
-  content: '';
-  display: table;
-}
-
-.clearfix:after {
-  clear: both;
-  overflow: hidden;
-}
-
-.clearfix {
-  *zoom: 1;
-}
-
-/deep/ .ant-card-head-title {
-  color: #1890ff;
-}
 
-//包着card
-.fullCard {
-  height: 380px;
-  /deep/ .ant-card-body {
-    padding: 0 4px;
-  }
-}
-// 日历
-.ccfullCalendar {
-  height: 274px !important;
-  // 年月选择消失
-  /deep/ .ant-fullcalendar-header {
-    display: none;
-  }
-  // 线消息
-  /deep/ .ant-fullcalendar {
-    border-top: none;
-  }
-
-  /deep/ .ant-fullcalendar-calendar-body {
-    padding: 0;
-  }
-
-  /deep/ .fc .fc-toolbar.fc-header-toolbar {
-    margin-bottom: 6px;
-  }
-  /deep/ .fc .fc-scrollgrid-liquid {
-    height: 274px !important;
-  }
-  /deep/ .fc .fc-toolbar-title {
-    font-size: 14px;
-    letter-spacing: 1px;
-  }
-  /deep/ .fc-scrollgrid-sync-table {
-    height: 274px !important;
-  }
-  /deep/ .fc-daygrid-day-bottom {
-    margin-top: -10px !important;
-  }
-  /deep/ .fc .fc-button-primary {
-    background-color: #1890ff;
-    margin-top: 4px;
-    border: none;
-  }
-  /deep/ .fc .fc-toolbar-title {
-    color: #333;
-    font-size: 16px;
-  }
-}
-#home {
-  // 第一行
-  .topCard {
-    // 等高设置
-    .topColItem {
-      height: 380px;
-    }
-    .userImg {
-      width: 80px;
-      height: 80px;
-      img {
-        border-radius: 6px;
-        width: 100%;
-      }
-    }
-    .userInfo {
-      span {
-        margin-left: 60px;
-        display: block;
-        line-height: 26px;
-        .department {
-          font-size: 14px;
-          color: rgb(71, 70, 70);
-        }
-      }
-    }
-    // 消息
-    .msgBox {
-      span {
-        font-size: 38px;
-        color: #fa6b5c;
-        text-shadow: 2px 2px 1px rgb(94, 94, 94);
-      }
-      p {
-        font-size: 16px;
-      }
-    }
-  }
-  // OA工作台
-  .oaBtn {
-    background-color: white;
-    padding: 20px;
-    margin-right: 1%;
-    .oaButton {
-      display: flex;
-      flex-flow: row wrap;
-      text-align: center;
-      .oaItem {
-        line-height: 0px;
-        // width: 25%;
-        width: calc((100% - 100px) / 3);
-        justify-content: space-around;
-        flex-direction: column;
-        align-items: center;
-        margin-bottom: 10px;
-        margin-right: 1px;
-        // 图
-        span {
-          margin: 0 aotu;
-          border: transparent;
-          display: flex;
-          align-items: center;
-          justify-content: center;
-          position: relative;
-          img {
-            width: 34px;
-            height: 34px;
-          }
-        }
-        // 文字
-        p {
-          margin-top: 14px;
-          font-size: 14px;
-          color: rgb(128, 127, 127);
-          font-weight: 400;
-          letter-spacing: 1px;
-        }
-      }
-    }
-  }
-  // 公告
-  .news {
-    .newsColItem {
-      height: 400px;
-    }
-    .notice {
-      ul {
-        margin: 0;
-        padding: 0;
-        li {
-          line-height: 30px;
-          a {
-            font-size: 14px;
-            color: #444;
-            .department {
-              margin-right: 10px;
-            }
-            .createBy {
-              color: #333;
-            }
-            .createTime {
-              color: rgb(164, 164, 164);
-              margin: 0 4px 0 20px;
-            }
-          }
-          a:hover {
-            color: #1890ff;
-          }
-        }
-      }
-    }
-    // 我的计划
-    .plan {
-      .total {
-        span {
-          display: block;
-          line-height: 40px;
-          strong {
-            color: #fa6b5c;
-            text-decoration: underline;
-            margin-right: 4px;
-          }
-        }
-      }
-    }
-    // 友情链接
-    .link {
-      .linkBtn {
-        display: flex;
-        flex-flow: row wrap;
-        justify-content: space-between;
-        button {
-          border-radius: 2px;
-          border: none;
-          background-color: rgba(102, 155, 188, 0.7);
-          width: calc((100% - 60px) / 2);
-          display: flex;
-          justify-content: center;
-          align-items: center;
-          margin-bottom: 10px;
-          padding: 10px 0;
-          letter-spacing: 1px;
-          a {
-            color: white;
-            font-size: 12px;
-          }
-        }
-        button:hover {
-          background-color: #003049;
-          color: white;
-          box-shadow: 1px 1px 3px #333;
-        }
-      }
-    }
-  }
-}
+<style lang="less" scoped>
+// 单独创建页面写样式  如下
+@import '~@assets/less/mytodo.less';
+@import '~@assets/less/common.less';
 </style>

+ 37 - 18
src/views/oa/enter-ann/add/detAnnModal.vue

@@ -1,15 +1,15 @@
 <template>
   <!-- 公告详情 弹框 -->
-  <a-modal v-model="annVisible" title="企业公告详情" @ok="handleOk" width="90%">
+  <a-modal v-model="annVisible" title="企业公告详情" @ok="handleOk" width="90%" @cancel="close">
     <a-row :gutter="24">
       <a-col :span="12">
         <p>
-          标题: <span class="annDet">{{ annDetail.title }}</span>
+          标题: <span class="annDet">{{ fatherData.title }}</span>
         </p>
       </a-col>
       <a-col :span="12">
         <p>
-          发布部门: <span class="annDet">{{ annDetail.type }}</span>
+          发布部门: <span class="annDet">{{ fatherData.type }}</span>
         </p>
       </a-col>
     </a-row>
@@ -17,12 +17,12 @@
     <a-row :gutter="24">
       <a-col :span="12">
         <p>
-          创建人: <span class="annDet"> {{ annDetail.createBy }}</span>
+          创建人: <span class="annDet"> {{ fatherData.createBy }}</span>
         </p>
       </a-col>
       <a-col :span="12">
         <p>
-          创建日期: <span class="annDet">{{ annDetail.createTime }}</span>
+          创建日期: <span class="annDet">{{ fatherData.createTime }}</span>
         </p>
       </a-col>
     </a-row>
@@ -31,7 +31,7 @@
       <a-col :span="24">
         <p>详情:</p>
         <!-- 文本框 -->
-        <span v-html="myValue" class="valueBox"></span>
+        <span v-html="fatherData.content" class="valueBox" style="minHeight:120px;"></span>
       </a-col>
     </a-row>
   </a-modal>
@@ -41,23 +41,43 @@
 export default {
     data () {
         return {
-            myValue: '', // 富文本内容
-            annDetail: [], // 公告详情
-            annVisible: false, // 公告详情关闭
-            // 接收父组件查询公告的方法
-            props: {
-                fatherGetList: {
-                    type: Function,
-                    default: null
-                }
-            }
+            // myValue: '', // 富文本内容
+            // annDetail: {}, // 公告弹框详情 (父组件)
+            annVisible: false // 公告详情关闭
         }
     },
+    // 接收父组件的数据
+    props: {
+        fatherData: {
+            type: Object,
+            default: null
+        },
+        fatherMethod: {
+            type: Function,
+            default: null
+        }
+    },
+
     methods: {
-        // 公告详情 弹框按钮
+    // 公告详情 弹框按钮
         handleOk (e) {
             console.log(e)
             this.annVisible = false
+            // this.fatherData = '' // 清空弹框 会报错
+            this.fatherData.title = ''
+            this.fatherData.type = ''
+            this.fatherData.createBy = ''
+            this.fatherData.createTime = ''
+            this.fatherData.content = ''
+        },
+        close () {
+            this.annVisible = false
+            // this.fatherData = '' // 清空弹框 会报错
+            this.fatherData.title = ''
+            this.fatherData.type = ''
+            this.fatherData.createBy = ''
+            this.fatherData.createTime = ''
+            this.fatherData.content = ''
         }
     }
 }
@@ -74,7 +94,6 @@ export default {
 }
 // 整个详情弹框内容
 .annDet {
-  // color: #ccc;
   font-weight: 700;
 }
 </style>

+ 1 - 1
src/views/oa/enterpriseAnnouncement.vue

@@ -232,7 +232,7 @@ export default {
                 if (res.success) {
                     console.log(res)
                     this.$refs.AddAnnModal.annInfo = res.result
-                    this.$refs.AddAnnModal.getAnnFormInfo()
+                    this.$refs.AddAnnModal.getAnnFormInfo() // enterpriseEQueryById父拿子
                 }
             })
         },

+ 8 - 8
src/views/oa/my-plan/calTable.vue

@@ -68,17 +68,15 @@
       </a-dropdown>
     </div>
 
+    <!-- table 开始-->
     <div>
       <!-- {{ selectedRowKeys.length }} -->
       <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
-        <i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择
-        <a style="font-weight: 600">0</a
-        >项
+        <i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">0</a>项
         <a style="margin-left: 24px" @click="onClearSelected">清空</a>
       </div>
 
       <!-- { selectedRowKeys: selectedRowKeys, onChange: onSelectChange }  :rowSelection="rowSelection"-->
-
       <a-table
         ref="table"
         bordered
@@ -94,12 +92,11 @@
         <span slot="operationSlot" slot-scope="text, record">
           <a href="javascript:void(0);" @click="editPlan(record)"> 编辑 </a>
           <a-divider type="vertical" />
-          <a-popconfirm title="确定删除吗?" ok-text="是" cancel-text="否" >
+          <a-popconfirm title="确定删除吗?" ok-text="是" cancel-text="否">
             <a href="javascript:void(0);" @click="delPlan(record.id)" class="delRed"> 删除 </a>
           </a-popconfirm>
         </span>
       </a-table>
-      <!-- </a-table> -->
     </div>
     <!-- table 结束-->
 
@@ -186,8 +183,7 @@ export default {
         this.getplanList()
     },
     methods: {
-
-        // 分页查询 日程列表
+    // 分页查询 日程列表
         getplanList () {
             scheduleList(this.queryParam).then(res => {
                 console.log('>>>>', this.queryParam)
@@ -248,6 +244,9 @@ export default {
             scheduleQueryById({ id: obj.id }).then(res => {
                 if (res.success) {
                     console.log('编辑的对象', res)
+                    this.$refs.savePlan.formData = res.result
+                    // console.log('>>>', this.$refs.savePlan.formData)
+                    this.$refs.savePlan.getFormInfo()
                 }
             })
             this.$refs.savePlan.formData = obj
@@ -278,5 +277,6 @@ export default {
 }
 </script>
 <style lang="less" scoped>
+
 @import '~@assets/less/common.less';
 </style>