centaline-data-driven 1.2.97 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -44,7 +44,8 @@ const paths = {
44
44
  "dynamicCompound": "./src/centaline/dynamicCompound/index.js",//复合控件
45
45
  "dynamicContact": "./src/centaline/dynamicContact/index.js",//联系人电话
46
46
  "dynamicLayout": "./src/centaline/dynamicLayout/index.js",//Layout组件
47
- "browseVideo": "./src/centaline/browseVideo/index.js",//确认框组件
47
+ "browseVideo": "./src/centaline/browseVideo/index.js",//确认框组件
48
+ "dynamicViewerFile": "./src/centaline/dynamicViewerFile/index.js",//确认框组件
48
49
  },
49
50
  "plugs": {
50
51
  "api": "./src/centaline/api/index.js",//调用API插件
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "centaline-data-driven",
3
- "version": "1.2.97",
3
+ "version": "1.3.00",
4
4
  "description": "ccai",
5
5
  "author": "hjc <3226136347@qq.com>",
6
6
  "private": false,
@@ -21,6 +21,7 @@
21
21
  "save": "^2.4.0",
22
22
  "v-viewer": "^1.6.4",
23
23
  "vue": "2.5.17",
24
+ "vue-pdf": "^4.3.0",
24
25
  "vue-ueditor-wrap": "^2.5.6",
25
26
  "vuedraggable": "^2.24.3"
26
27
  },
@@ -0,0 +1,183 @@
1
+
2
+ <template>
3
+ <div>
4
+ <div style="position: relative">
5
+ <el-carousel
6
+ arrow="hover"
7
+ height="199px"
8
+ :autoplay="false"
9
+ indicator-position="none"
10
+ :initial-index="getinitialIndex(albumsList)"
11
+ >
12
+ <template v-for="(item, index) in albumsList.medias">
13
+ <el-carousel-item :key="index">
14
+ <div class="swiper-i">
15
+ <img
16
+ :src="item.mediaUrl + '/260/200'"
17
+ @click="viewerfile(index)"
18
+ />
19
+ <img
20
+ :src="item.albumBigImageUrl"
21
+ alt=""
22
+ class="hous-icon"
23
+ v-if="item.albumBigImageUrl && item.albumBigImageUrl != ''"
24
+ />
25
+ </div> </el-carousel-item
26
+ ></template>
27
+ </el-carousel>
28
+
29
+ <div class="hous-img" style="position: absolute; bottom: 0; z-index: 9">
30
+ <div class="img-i" v-for="(item, index) in newMediaAlbums" :key="index">
31
+ <img
32
+ :src="getDefaultUrl(item) + '/140/135'"
33
+ @click="handleClick(index)"
34
+ />
35
+ <div class="img-bot">
36
+ <div>
37
+ <img :src="item.albumSmallImageUrl" alt="" class="img-icon" />
38
+ <span>{{ item.albumName }}</span>
39
+ </div>
40
+ </div>
41
+ </div>
42
+ </div>
43
+ </div>
44
+ </div>
45
+ </template>
46
+ <script>
47
+ export default {
48
+ props: {
49
+ mediaAlbums: Array,
50
+ title: String,
51
+ },
52
+ data() {
53
+ return {
54
+ newMediaAlbums: [],
55
+ albumsList: [],
56
+ activeAlbumsIndex: 0,
57
+ };
58
+ },
59
+ created() {
60
+ this.init();
61
+ },
62
+ methods: {
63
+ init() {
64
+ var self = this;
65
+ this.newMediaAlbums = this.mediaAlbums || [];
66
+ this.albumsList = this.newMediaAlbums[0];
67
+ self.$forceUpdate();
68
+ },
69
+ handleClick(index) {
70
+ if (index == this.activeAlbumsIndex) return;
71
+ this.albumsList = this.newMediaAlbums[index];
72
+ this.activeAlbumsIndex = index;
73
+ },
74
+ getinitialIndex(list) {
75
+ var initialIndex = 0;
76
+ try {
77
+ initialIndex = list.medias.findIndex((v) => v.flagDefault == 1) | 0;
78
+ } catch (error) {
79
+ debugger;
80
+ }
81
+ return initialIndex < 0 ? 0 : initialIndex;
82
+ },
83
+ getDefaultUrl(list) {
84
+ var initialIndex = this.getinitialIndex(list);
85
+ return list.medias[initialIndex].mediaUrl;
86
+ },
87
+ viewerfile(index) {
88
+ var self = this;
89
+
90
+ var dialogOption = {
91
+ title: this.title || "预览媒体",
92
+ pane: self.$common.getParentPane(self),
93
+ content: [
94
+ {
95
+ component: "ct-viewerfile",
96
+ attrs: {
97
+ showTitle: false,
98
+ MediaAlbum: this.newMediaAlbums,
99
+ groupIndex: this.activeAlbumsIndex,
100
+ index: index || 0,
101
+ // width: self.modelPhotoselect.router.pageWidth + 'px',
102
+ // height: self.modelPhotoselect.router.pageHeight+'px',
103
+ width:
104
+ parseInt(window.document.body.clientWidth * 0.8).toString() +
105
+ "px",
106
+ height:
107
+ parseInt(window.document.body.clientHeight * 0.8).toString() +
108
+ "px",
109
+ },
110
+ on: {
111
+ handlePhoto(photoList) {},
112
+ },
113
+ },
114
+ ],
115
+ };
116
+ self.$common.openDialog(dialogOption);
117
+ },
118
+ },
119
+ watch: {
120
+ mediaAlbums(newValue, oldValue) {
121
+ this.init(newValue);
122
+ },
123
+ },
124
+ };
125
+ </script>
126
+
127
+ <style lang="scss" scoped>
128
+ .hous-t {
129
+ width: 260px;
130
+ .swiper-i {
131
+ position: relative;
132
+ width: 100%;
133
+ height: 100%;
134
+ img {
135
+ width: 100%;
136
+ height: 100%;
137
+ }
138
+ .hous-icon {
139
+ width: 60px;
140
+ height: 60px;
141
+ position: absolute;
142
+ top: 50%;
143
+ left: 50%;
144
+ transform: translate(-50%, -50%);
145
+ }
146
+ }
147
+
148
+ .hous-img {
149
+ margin-top: 10px;
150
+ width: 100%;
151
+ overflow-x: hidden;
152
+ overflow-y: hidden;
153
+ white-space: nowrap;
154
+ .img-i {
155
+ position: relative;
156
+ width: 80px;
157
+ height: 44px;
158
+ margin-right: 10px;
159
+ display: inline-block;
160
+ img {
161
+ width: 100%;
162
+ height: 100%;
163
+ }
164
+ .img-bot {
165
+ width: 100%;
166
+ height: 16px;
167
+ background: rgba(0, 0, 0, 0.5);
168
+ color: #fff;
169
+ position: absolute;
170
+ bottom: 0;
171
+ font-weight: Bold;
172
+ .img-icon {
173
+ width: 12px;
174
+ height: 12px;
175
+ margin: 0 5px;
176
+ margin: 0 5px;
177
+ vertical-align: -1.5px;
178
+ }
179
+ }
180
+ }
181
+ }
182
+ }
183
+ </style>
@@ -1,8 +1,8 @@
1
1
  <template>
2
2
  <div>
3
- <ct-PropertyDetailOFI :api="api" :apiParam="apiParam" :parentModel="parentModel" class="ct-PropertyDetailOFI" v-if="pageType=='PropertyDetailOFI'"
3
+ <ct-PropertyDetailOFI :api="api" :apiParam="apiParam" :parentModel="parentModel" :top="top" class="ct-PropertyDetailOFI" v-if="pageType=='PropertyDetailOFI'"
4
4
  @loaded="loaded"></ct-PropertyDetailOFI>
5
- <ct-PropertyDetailRET :api="api" :apiParam="apiParam" :parentModel="parentModel" class="ct-PropertyDetailRET" v-if="pageType=='PropertyDetailRET'"
5
+ <ct-PropertyDetailRET :api="api" :apiParam="apiParam" :parentModel="parentModel" :top="top" class="ct-PropertyDetailRET" v-if="pageType=='PropertyDetailRET'"
6
6
  @loaded="loaded"></ct-PropertyDetailRET>
7
7
  <ct-PropertySimpleDetailRET :api="api" :apiParam="apiParam" :selectIndex="selectIndex" :rowCount="rowCount" class="ct-PropertySimpleDetailRET"
8
8
  @loaded="loaded"
@@ -30,6 +30,7 @@
30
30
  pageType: String,
31
31
  selectIndex:Number,
32
32
  rowCount:Number,
33
+ top:Number,
33
34
  },
34
35
  data() {
35
36
  return {
@@ -51,48 +51,7 @@
51
51
  <div class="hous-info base-box">
52
52
  <div class="info-conten">
53
53
  <div class="hous-t">
54
- <div>
55
- <el-carousel
56
- arrow="hover"
57
- height="140px"
58
- :autoplay="false"
59
- indicator-position="none"
60
- >
61
- <el-carousel-item
62
- v-for="(item,index) in PropertyInfo.swiper"
63
- :key="index"
64
- >
65
- <div class="swiper-i">
66
- <img :src="item.url">
67
- <img src="../../../assets/Mvr.png" alt="" class="hous-icon">
68
-
69
- </div>
70
- </el-carousel-item>
71
- </el-carousel>
72
-
73
- <div class="hous-img">
74
- <div
75
- class="img-i"
76
- v-for="(item,index) in PropertyInfo.swiper"
77
- :key="index"
78
- > <img :src="item.url">
79
- <div class="img-bot">
80
- <div v-if="item.type.includes('vr')">
81
- <img src="../../../assets/VR.png" alt="" class="img-icon">
82
- <span>VR</span>
83
- </div>
84
- <div v-if="item.type.includes('img')">
85
- <img src="../../../assets/image.png" alt="" class="img-icon">
86
- <span>图片</span>
87
- </div>
88
- <div v-if="item.type.includes('video')">
89
- <img src="../../../assets/video.png" alt="" class="img-icon">
90
- <span>视频</span>
91
- </div>
92
- </div>
93
- </div>
94
- </div>
95
- </div>
54
+ <ct-albums :mediaAlbums="model.mediaAlbums" :title="model.title"> </ct-albums>
96
55
  </div>
97
56
  <div class="hous-b">
98
57
  <img src="../../../assets/ewm.png" alt="" class="code-ewm">
@@ -503,9 +462,12 @@
503
462
 
504
463
  <script>
505
464
  // import max from '../../css/max';
506
-
465
+ import dynamicAlbums from "./dynamicAlbums.vue";
507
466
  export default {
508
467
  name: 'ct-PropertyDetailOFI',
468
+ components: {
469
+ "ct-albums": dynamicAlbums,
470
+ },
509
471
  props: {
510
472
  vmodel: Object,
511
473
  api: String
@@ -513,13 +475,6 @@
513
475
  data() {
514
476
  return {
515
477
  model:null,
516
- PropertyInfo: {
517
- swiper: [
518
- { name: '客厅', url: 'http://10.5.10.44:13031/Images/20210705/112133_b62d7a78-96b3-4801-b94c-47b83263a001.jpg?width=140&height=135&mode=stretch', isVr: true, type: 'vr' },
519
- { name: '餐厅', url: 'http://10.5.10.44:13031/Images/20210705/112124_4f83c6d5-36bd-444f-9ea1-fa4e3f4de5e0.jpg?width=140&height=135&mode=stretch', isVr: false, type: 'img' },
520
- { name: '户型图', url: 'http://10.5.10.44:13031/Images/20210705/112505_6a3cb2d4-c773-4aba-91af-df6721eadb34.jpg?width=140&height=135&mode=stretch', isVr: false, type: 'video' },
521
- { name: '其它', url: 'http://10.5.10.44:13031/Images/20210705/112133_b62d7a78-96b3-4801-b94c-47b83263a001.jpg?width=140&height=135&mode=stretch', isVr: false, type: 'video' },
522
- ],},
523
478
  allInfo: false,
524
479
  allIn:false,
525
480
  codeOwner: false,