ns-journal.vue 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. <template>
  2. <view class="journal">
  3. <view class="item" v-for="(item, index) in list" :key="index">
  4. <view class="time">
  5. <view>{{ $util.timeFormat(item.action_time).split(' ')[0] }}</view>
  6. <view>{{ $util.timeFormat(item.action_time).split(' ')[1] }}</view>
  7. </view>
  8. <view class="unit">
  9. <view class="top">
  10. <view class="core"></view>
  11. <view class="unit-separate"></view>
  12. </view>
  13. </view>
  14. <view class="message">{{ item.action }}</view>
  15. </view>
  16. </view>
  17. </template>
  18. <script>
  19. export default {
  20. props: {
  21. list: {
  22. type: Array,
  23. default: []
  24. }
  25. },
  26. data() {
  27. return {};
  28. },
  29. mounted() {},
  30. methods: {}
  31. };
  32. </script>
  33. <style scoped lang="scss">
  34. .journal {
  35. padding-left: 0.1rem;
  36. box-sizing: border-box;
  37. .item {
  38. width: 100%;
  39. height: 0.7rem;
  40. display: flex;
  41. .time {
  42. margin-right: 0.1rem;
  43. min-width: 1rem;
  44. view:nth-child(1) {
  45. font-size: 0.16rem;
  46. margin-bottom: 0.1rem;
  47. text-align: right;
  48. }
  49. view:nth-child(2) {
  50. font-size: 0.14rem;
  51. color: #999999;
  52. text-align: right;
  53. }
  54. }
  55. }
  56. .unit {
  57. width: 0.18rem;
  58. height: 100%;
  59. margin-right: 0.1rem;
  60. .top {
  61. width: 0.18rem;
  62. height: 0.18rem;
  63. border-radius: 50%;
  64. background: $uni-color-primary;
  65. position: relative;
  66. .core {
  67. background: #ffffff;
  68. width: 0.08rem;
  69. height: 0.08rem;
  70. border-radius: 50%;
  71. position: absolute;
  72. top: 50%;
  73. left: 50%;
  74. transform: translate(-50%, -50%);
  75. z-index: 999;
  76. }
  77. .unit-separate {
  78. position: absolute;
  79. width: 0.01rem;
  80. height: 0.7rem;
  81. position: absolute;
  82. top: 0;
  83. left: 50%;
  84. transform: translateX(-50%);
  85. background: $uni-color-primary;
  86. z-index: 555;
  87. }
  88. }
  89. }
  90. .message {
  91. font-size: 0.14rem;
  92. }
  93. }
  94. </style>