theme.vue 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. <template>
  2. <view class="theme">
  3. <view class="title">请先选定一个主题进行追踪</view>
  4. <view class="content">
  5. <view class="item"
  6. v-for="(item, index) in themeList"
  7. @click="checkedHandle(item)"
  8. :key="index">
  9. <view class="left">
  10. <image :src="`../../static/theme${item.id}.png`"></image>
  11. </view>
  12. <view class="right">
  13. <text>{{item.title}}</text>
  14. <text>{{item.des}}</text>
  15. </view>
  16. <image v-if="theme.id === item.id" src="../../../static/theme.png"></image>
  17. </view>
  18. </view>
  19. </view>
  20. </template>
  21. <script>
  22. import { mapState } from "vuex";
  23. const themeList = [{
  24. id: 0,
  25. title: '个案追踪',
  26. des: '评价诊疗服务的内涵质量以及对各种诊疗规范、临床路径等的执行力',
  27. },{
  28. id: 1,
  29. title: '系统追踪',
  30. des: '评价对各种质量与安全管理制度与流程的执行力、医院服务的连贯性及多学科综合的服务能力',
  31. }]
  32. export default {
  33. data() {
  34. return {
  35. themeList
  36. }
  37. },
  38. computed: {
  39. ...mapState({
  40. theme: state => state.creatingSituations.theme
  41. })
  42. },
  43. methods: {
  44. checkedHandle: function(item) {
  45. this.myCommit('theme', item);
  46. this.myCommit('needReload', true);
  47. this.myCommit('stepActive', 1);
  48. },
  49. myCommit: function(key, data) {
  50. this.$store.commit({type: 'creatingSituations/comChangeState',key,data});
  51. }
  52. }
  53. }
  54. </script>
  55. <style lang="less">
  56. .theme {
  57. overflow: hidden;
  58. width: 100%;
  59. .content {
  60. display: flex;
  61. flex-direction: column;
  62. align-items: center;
  63. .item {
  64. position: relative;
  65. display: flex;
  66. flex-direction: row;
  67. margin: 62.5rpx 0;
  68. border-radius: 15rpx;
  69. padding: 37.5rpx 50rpx;
  70. width: 625rpx;
  71. height: 187.5rpx;
  72. background: linear-gradient(270deg, #6697FE 0%, #4980F2 100%);
  73. box-shadow: 0 12.5rpx 12.5rpx 0 rgba(73, 128, 242, 0.2);
  74. >image {
  75. position: absolute;
  76. top: 10rpx;
  77. right: 10rpx;
  78. width: 46.87rpx;
  79. height: 46.87rpx;
  80. }
  81. .left {
  82. margin-right: 25rpx;
  83. image {
  84. width: 112.5rpx;
  85. height: 112.5rpx;
  86. }
  87. }
  88. .right {
  89. display: flex;
  90. flex-direction: column;
  91. text {
  92. font-size: 17.5rpx;
  93. line-height: 25rpx;
  94. color: #fff;
  95. &:first-child {
  96. margin-bottom: 5rpx;
  97. font-size: 30rpx;
  98. font-weight: bold;
  99. line-height: 45rpx;
  100. }
  101. }
  102. }
  103. &:first-child {
  104. margin-top: 125rpx;
  105. background: linear-gradient(270deg, #00CCBB 0%, #00CCAA 100%);
  106. box-shadow: 0 12.5rpx 12.5rpx 0 rgba(0, 204, 170, 0.2);
  107. }
  108. }
  109. }
  110. }
  111. </style>