阜外华中心血管医院6.0vue版

appAds.vue 3.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. <template>
  2. <!-- 全部公告 -->
  3. <el-card :body-style="{ padding: '0' }" :style="{height:height}" shadow="hover" class="all_notice">
  4. <h4 class="title">全部日程</h4>
  5. <ul class="lists">
  6. <li v-for="item of notices" :key="item.id" class="item">
  7. 【阜外华中心血管病医院】{{ item.content }}
  8. </li>
  9. </ul>
  10. <router-link class="inlineBlock" to="/schedule/manage">
  11. <el-dropdown-item>
  12. <i class="el-icon-more"/>查看更多
  13. </el-dropdown-item>
  14. </router-link>
  15. </el-card>
  16. </template>
  17. <script>
  18. import { getSchedule } from '@/api/customer/customerInfoHY'
  19. export default {
  20. name: 'AllNotice',
  21. props: {
  22. height: {
  23. type: String,
  24. default: '170px'
  25. }
  26. },
  27. data() {
  28. return {
  29. notices: [
  30. // { id: 0, content: '【阜外华中心血管病医院】5月20日呼叫中心6.0版本试运营上线,轻装上阵轻装上阵轻装上阵…' },
  31. // { id: 1, content: '【阜外华中心血管病医院】5月20日呼叫中心6.0版本试运营上线,轻装上阵…' },
  32. // { id: 2, content: '【阜外华中心血管病医院】5月20日呼叫中心6.0版本试运营上线,轻装上阵…' },
  33. // { id: 3, content: '【阜外华中心血管病医院】5月20日呼叫中心6.0版本试运营上线,轻装上阵…' },
  34. // { id: 4, content: '【阜外华中心血管病医院】5月20日呼叫中心6.0版本试运营上线,轻装上阵…' },
  35. // { id: 5, content: '【阜外华中心血管病医院】5月20日呼叫中心6.0版本试运营上线,轻装上阵…' }
  36. ]
  37. }
  38. },
  39. created() {
  40. this.getList()
  41. },
  42. methods: {
  43. // 项目到期的消息
  44. getList() {
  45. this.loading = true
  46. const params = {
  47. daykind: 0 // 传值0时获取到期前一月的客户信息,传值1获取当天到期的客户信息
  48. }
  49. getSchedule(params).then(res => {
  50. this.loading = false
  51. if (res.state.toLowerCase() === 'success') {
  52. if (res.data.rows && res.data.rows.length) {
  53. this.notices = []
  54. res.data.rows.forEach(item => {
  55. this.notices.unshift({
  56. content: item.content
  57. })
  58. })
  59. }
  60. }
  61. })
  62. }
  63. }
  64. }
  65. </script>
  66. <style rel="stylesheet/scss" lang="scss" scoped>
  67. .all_notice {
  68. position: relative;
  69. width: 100%;
  70. .title {
  71. height: 40px;
  72. line-height: 40px;
  73. padding: 0 0 0 10px;
  74. margin: 0;
  75. background-color: #f5f5f6;
  76. color: #666666;
  77. font-size: 14px;
  78. font-weight: 500;
  79. }
  80. .lists{
  81. margin: 0;
  82. padding: 15px 20px 10px 20px;
  83. list-style: none;
  84. overflow: hidden;
  85. height: 90px;
  86. .item{
  87. color: #666666;
  88. font-size: 12px;
  89. line-height: 26px;
  90. width: 100%;
  91. overflow: hidden;
  92. white-space: nowrap;
  93. text-overflow: ellipsis;
  94. }
  95. }
  96. .btn_more{
  97. position: absolute;
  98. left: 24px;
  99. bottom: 8px;
  100. }
  101. .inlineBlock{
  102. line-height: 20px;
  103. font-size: 12px
  104. }
  105. }
  106. </style>