zjf
2023-03-08 51468f93275c2bcfcc7ad25bf05f3d6a079ff764
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
<template>
  <div class="content">
    <div id="journal-list-box" class="list-box">
      <journal-cell
        v-for="(item, index) in journalData"
        :key="index"
        :log-index="index"
        :data="item"
        :show-workbench="true"
        :style="{margin: marginDefaults ? '0' : '0 20px 20px'}"
        class="list-cell"
        @on-handle="jourecallCellHandle"/>
      <slot name="load"/>
    </div>
    <!-- 相关业务页面 -->
    <c-r-m-all-detail
      :visible.sync="showRelatedDetail"
      :crm-type="relatedCRMType"
      :listener-ids="['workbench-main-container']"
      :no-listener-ids="['journal-list-box']"
      :id="relatedID"
      class="d-view"/>
  </div>
</template>
 
<script>
import JournalCell from '@/views/OAManagement/journal/journalCell'
import CRMAllDetail from '@/views/clients/components/CRMAllDetail'
 
export default {
  components: {
    CRMAllDetail,
    JournalCell
  },
  props: {
    // 数据
    journalData: Array,
    marginDefaults: {
      type: Boolean,
      default: false
    }
  },
  data () {
    return {
      // 相关详情的查看
      relatedID: '',
      relatedCRMType: '',
      showRelatedDetail: false
    }
  },
  computed: {},
  methods: {
    jourecallCellHandle (data) {
      this.relatedID = data.data.item.key
      this.relatedCRMType = data.data.type
      this.showRelatedDetail = true
    }
  }
}
</script>
 
<style scoped lang="scss">
.content {
  flex: 1;
  display: flex;
  flex-direction: column;
  .list-box {
    flex: 1;
    overflow: auto;
  }
}
 
.list-cell {
  border: 1px solid #e6e6e6;
  margin-bottom: 20px;
  border-radius: 4px;
}
</style>