e-record.vue 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. <template>
  2. <view>
  3. <view class="recordList">
  4. <view class="title">记录列表</view>
  5. <scroll-view scroll-x="true" >
  6. <view class="list">
  7. <view class="item" :class="{active:active==index}" v-for="(item,index) in recordList" :key="index" @click="click_active(index,item)">{{item.templateName}}</view>
  8. </view>
  9. </scroll-view>
  10. <view class="content">
  11. <view class="inner" v-for="(item,index) in instanceList" :key="index">
  12. <view style="color: #009FE8;">记录时间 : {{item[0].createDate}}</view>
  13. <view style="color: #009FE8;">{{item[0].templateName}}</view>
  14. <view>{{item[0].createName}}</view>
  15. <view v-for="(item_2,index_2) in item[0].recordStatusInstanceList" :key="index_2">
  16. <view> <span style="color: #999999;">{{item_2.statusName}} :</span> {{item_2.recordStatusInstanceValue}}</view>
  17. </view>
  18. <view style="color: #009FE8;" v-if="item[0].statusFlag">结束 : {{item[0].createDate}}</view>
  19. <view style="color: #F0AD4E;" v-else>等待处理...</view>
  20. </view>
  21. </view>
  22. <view class="more">查看更多</view>
  23. </view>
  24. </view>
  25. </template>
  26. <script>
  27. export default {
  28. props: [
  29. "recordList",
  30. "instanceList"
  31. ],
  32. data() {
  33. return {
  34. active:0
  35. };
  36. },
  37. methods: {
  38. click_active(index,item){
  39. this.active = index
  40. this.$emit("set_parentId",item.parentId)
  41. }
  42. }
  43. }
  44. </script>
  45. <style lang="scss">
  46. .recordList {
  47. width: 700rpx;
  48. .title {
  49. line-height: 30px;
  50. border-left: 4px solid #009FE8;
  51. border-radius: 4px;
  52. padding-left: 10px;
  53. margin-bottom: 10px;
  54. }
  55. .list{
  56. width: 400%;
  57. padding: 8px 0;
  58. border-top: 1px solid #ccc;
  59. border-bottom: 1px solid #ccc;
  60. cursor: pointer;
  61. display: flex;
  62. .item{
  63. margin-right: 15px;
  64. border: 1px solid #ccc;
  65. color: #ccc;
  66. font-size: 17px;
  67. padding: 4px 8px;
  68. border-radius: 4px;
  69. }
  70. .active{
  71. background-color: #009FE8;
  72. color: #fff;
  73. }
  74. }
  75. .content{
  76. padding:10rpx;
  77. .inner{
  78. box-sizing: border-box;
  79. padding: 10px 30rpx;
  80. width: 680rpx;
  81. border: 1px dashed #ccc;
  82. border-radius: 10px;
  83. margin-bottom: 10px;
  84. }
  85. }
  86. }
  87. .more{
  88. text-align: center;
  89. line-height: 60px;
  90. font-size: 18px;
  91. border-bottom: 2px solid #C0C0C0;
  92. margin: 0 -25rpx;
  93. }
  94. </style>