jufubao-base 1.0.89-beta1 → 1.0.89

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.
@@ -2,762 +2,109 @@
2
2
  <view
3
3
  class="jfb-base-poster-big-small"
4
4
  @click="handleEditxSelect"
5
- :class="{ editx: isEditx && active }"
5
+ :class="{ editx : isEditx && active }"
6
6
  >
7
7
  <!--#ifdef H5-->
8
8
  <view
9
9
  class="jfb-base-poster-big-small__edit"
10
- :class="{ editx: isEditx && active }"
10
+ :class="{ editx : isEditx && active }"
11
11
  v-if="isEditx && active"
12
12
  >
13
- <view class="jfb-base-poster-big-small__edit-icon" @click="delEdit"
14
- >删除</view
15
- >
13
+ <view class="jfb-base-poster-big-small__edit-icon" @click="delEdit">删除</view>
16
14
  </view>
17
15
  <!-- #endif -->
18
16
  <view class="jfb-base-poster-big-small__body">
19
- <view
20
- class="jfb-base-poster-big-small__body-wrap"
21
- :style="{
22
- margin: margin,
23
- flexDirection: position === 1 ? 'row' : 'row-reverse',
24
- }"
25
- >
26
- <view
27
- v-if="isCarousel === 1"
28
- :style="{
29
- margin: msMarginComputed,
30
- width: bigWidth + 'rpx',
31
- height: bigHeight + 'rpx',
32
- borderRadius: radius + 'rpx',
33
- }"
34
- ><view>
35
- <image
36
- :style="{
37
- width: bigWidth + 'rpx',
38
- height: bigHeight + 'rpx',
39
- borderRadius: radius + 'rpx',
40
- }"
41
- :src="bigList[0].image_url"
42
- mode="aspectFill"
43
- ></image> </view
44
- ></view>
45
- <view
46
- v-else
47
- :style="{
48
- margin: msMarginComputed,
49
- width: bigWidth + 'rpx',
50
- height: bigHeight + 'rpx',
51
- borderRadius: radius + 'rpx',
52
- }"
53
- >
54
- <xd-swiper-dot
55
- :current="current"
56
- :info="bigList"
57
- field="content_name"
58
- :mode="dot_type"
59
- :dots-styles="dotStyleData"
60
- >
61
- <xd-swiper
62
- :indicator-dots="false"
63
- :list="bigList"
64
- :current="current"
65
- :width="bigWidth + 'rpx'"
66
- :height="bigHeight + 'rpx'"
67
- :interval="carouselTime"
68
- @onClickItem="handleClick"
69
- @animationfinish="handleBigAnimationfinish"
70
- >
71
- <template slot-scope="{ item, index }">
72
- <image
73
- :style="{
74
- borderRadius: radius + 'rpx',
75
- }"
76
- :src="item['image_url']"
77
- mode="aspectFill"
78
- ></image>
79
- </template>
80
- </xd-swiper>
81
- </xd-swiper-dot>
82
-
83
- <view v-if="isPreview" class="carousel-mask"></view>
84
- </view>
85
- <view
86
- :style="{
87
- width: bigWidth + 'rpx',
88
- height: '100%',
89
- }"
90
- >
91
- <view
92
- :style="{
93
- width: '100%',
94
- marginBottom: msMargin + 'rpx',
95
- height: smallHeight + 'rpx',
96
- }"
97
- >
98
- <view
99
- v-if="topIsCarousel === 1"
100
- :style="{
101
- width: bigWidth + 'rpx',
102
- height: smallHeight + 'rpx',
103
- borderRadius: topRadius + 'rpx',
104
- }"
105
- ><view>
106
- <image
107
- :style="{
108
- width: bigWidth + 'rpx',
109
- height: smallHeight + 'rpx',
110
- borderRadius: topRadius + 'rpx',
111
- }"
112
- :src="topList[0].image_url"
113
- mode="aspectFill"
114
- ></image> </view
115
- ></view>
116
- <view
117
- v-else
118
- :style="{
119
- width: bigWidth + 'rpx',
120
- height: smallHeight + 'rpx',
121
- borderRadius: topRadius + 'rpx',
122
- }"
123
- >
124
- <xd-swiper-dot
125
- :current="topCurrent"
126
- :info="topList"
127
- field="content_name"
128
- :mode="top_dot_type"
129
- :dots-styles="topDotStyleData"
130
- >
131
- <xd-swiper
132
- :indicator-dots="false"
133
- :list="topList"
134
- :current="topCurrent"
135
- :width="bigWidth + 'rpx'"
136
- :height="smallHeight + 'rpx'"
137
- :interval="topCarouselTime"
138
- @onClickItem="handleClick"
139
- @animationfinish="handleTopAnimationfinish"
140
- >
141
- <template slot-scope="{ item, index }">
142
- <image
143
- :style="{
144
- borderRadius: topRadius + 'rpx',
145
- }"
146
- :src="item['image_url']"
147
- mode="aspectFill"
148
- ></image>
149
- </template>
150
- </xd-swiper>
151
- </xd-swiper-dot>
152
-
153
- <view v-if="isPreview" class="carousel-mask"></view>
154
- </view>
155
- </view>
156
- <view
157
- :style="{
158
- width: '100%',
159
- height: smallHeight + 'rpx',
160
- }"
161
- >
162
- <view
163
- v-if="bottomIsCarousel === 1"
164
- :style="{
165
- width: bigWidth + 'rpx',
166
- height: smallHeight + 'rpx',
167
- borderRadius: bottomRadius + 'rpx',
168
- }"
169
- ><view>
170
- <image
171
- :style="{
172
- width: bigWidth + 'rpx',
173
- height: smallHeight + 'rpx',
174
- borderRadius: bottomRadius + 'rpx',
175
- }"
176
- :src="bottomList[0].image_url"
177
- mode="aspectFill"
178
- ></image> </view
179
- ></view>
180
- <view
181
- v-else
182
- :style="{
183
- width: bigWidth + 'rpx',
184
- height: smallHeight + 'rpx',
185
- borderRadius: bottomRadius + 'rpx',
186
- }"
187
- >
188
- <xd-swiper-dot
189
- :current="bottomCurrent"
190
- :info="bottomList"
191
- field="content_name"
192
- :mode="bottom_dot_type"
193
- :dots-styles="bottomDotStyleData"
194
- >
195
- <xd-swiper
196
- :indicator-dots="false"
197
- :list="bottomList"
198
- :current="bottomCurrent"
199
- :width="bigWidth + 'rpx'"
200
- :height="smallHeight + 'rpx'"
201
- :interval="bottomCarouselTime"
202
- @onClickItem="handleClick"
203
- @animationfinish="handleBottomAnimationfinish"
204
- >
205
- <template slot-scope="{ item, index }">
206
- <image
207
- :style="{
208
- borderRadius: bottomRadius + 'rpx',
209
- }"
210
- :src="item['image_url']"
211
- mode="aspectFill"
212
- ></image>
213
- </template>
214
- </xd-swiper>
215
- </xd-swiper-dot>
216
-
217
- <view v-if="isPreview" class="carousel-mask"></view>
218
- </view>
219
- </view>
220
- </view>
221
- </view>
17
+ <view>测试插件( {{containerId}} )</view>
222
18
  </view>
223
19
  </view>
224
20
  </template>
225
21
 
226
22
  <script>
227
- const color = require("color");
228
- import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
229
- import { jfbRootExec } from "@/utils/xd.event";
230
- import JfbBasePosterBigSmallMixin from "./JfbBasePosterBigSmallMixin";
231
- import { getContainerPropsValue } from "@/utils/xd.base";
232
- import componentsMixins from "@/mixins/componentsMixins";
233
- import extsMixins from "@/mixins/extsMixins";
234
- import XdSwiper from "@/components/XdSwiper/XdSwiper";
235
- import XdSwiperDot from "./XdSwiperDot";
236
- import getServiceUrl from "@/common/getServiceUrl";
237
- export default {
238
- name: "JfbBasePosterBigSmall",
239
- components: {
240
- XdFontIcon,
241
- XdSwiper,
242
- XdSwiperDot,
243
- },
244
- mixins: [componentsMixins, extsMixins, JfbBasePosterBigSmallMixin],
245
- data() {
246
- return {
247
- height: 0, //组件高度
248
- mS: {
249
- top: 0,
250
- bottom: 0,
251
- left: 0,
252
- right: 0,
253
- }, //间距
254
- isPreview: false, //是否预览
255
- test: {
256
- content_id: "KpBbUKdj4aBejwe7Fh1ki",
257
- position_id: "QCk3PmoyQmOWRP1SxnYR3",
258
- partner_id: 0,
259
- site_id: "",
260
- content_name: "测试.",
261
- image_url: "//dummyimage.com/200x200",
262
- redirect_type: "EMP",
263
- redirect_type_name: "无链接",
264
- redirect_data: "",
265
- sort: "",
266
- status: "",
267
- start_time: "",
268
- end_time: "",
269
- op_user_id: "",
270
- created_time: 0,
271
- updated_time: 0,
272
- }, //测试数据
273
-
274
- msMargin: 0, //大小图间距
275
-
276
- position: 1, //控制大图位置
277
-
278
- //大图
279
- current: 0,
280
- carouselTime: 5, //轮播图轮播周期
281
- bigList: [],
282
- number: null,
283
- dot_type: "dot",
284
- isCarousel: 1, //大图是否轮播图
285
- radius: 0, //大图圆角
286
- bigWidth: 0,
287
- bigHeight: 0,
288
-
289
- //小图下
290
- bottomList: [],
291
- bottomNumber: null,
292
- bottom_dot_type: "dot",
293
- bottomRadius: 0, //小图上圆角
294
- bottomCurrent: 0, //小图上
295
- bottomIsCarousel: 1,
296
-
297
- //小图上
298
- topList: [],
299
- topNumber: null,
300
- top_dot_type: "dot",
301
- topRadius: 0, //小图上圆角
302
- topCurrent: 0, //小图上
303
- topIsCarousel: 1,
304
- smallHeight: 0,
305
- };
306
- },
307
- computed: {
308
- margin() {
309
- return `${this.mS.top || 0}rpx ${this.mS.right || 0}rpx ${
310
- this.mS.bottom || 0
311
- }rpx ${this.mS.left || 0}rpx`;
312
- },
313
- msMarginComputed() {
314
- if (this.position === 1) {
315
- return `0 ${this.msMargin}rpx 0 0`;
316
- } else {
317
- return `0 0 0 ${this.msMargin}rpx`;
318
- }
319
- },
320
- dotStyleData() {
321
- let alpha = 0.6;
322
- let selectedColor = `rgba(${color(this.mainColor)
323
- .alpha(alpha)
324
- .array()
325
- .join(",")})`;
326
- let style = {
327
- dot: {
328
- backgroundColor: "rgba(166,166,166,.5)",
329
- border: "0px rgba(166,166,166,.5) solid",
330
- color: "#fff",
331
- selectedBackgroundColor: selectedColor,
332
- selectedBorder: `0px this.mainColor solid`,
333
- },
334
- default: {
335
- width: 16,
336
- backgroundColor: "rgba(200,200,200,.45)",
337
- border: "1px rgba(200,200,200,.45) solid",
338
- color: "#fff",
339
- selectedBackgroundColor: selectedColor,
340
- selectedBorder: `1px this.mainColor solid`,
341
- },
342
- round: {
343
- backgroundColor: "rgba(166,166,166,.5)",
344
- border: "0px rgba(166,166,166,.5) solid",
345
- color: "#fff",
346
- selectedBackgroundColor: selectedColor,
347
- selectedBorder: `0px this.mainColor solid`,
348
- },
349
- nav: {
350
- backgroundColor: "rgba(0,0,0,.5)",
351
- border: "1px rgba(0,0,0,.5) solid",
352
- color: "#fff",
353
- selectedBackgroundColor: "rgba(255, 255, 255, 1)",
354
- selectedBorder: "1px rgba(255, 255, 255 1) solid",
355
- },
356
- indexes: {
357
- backgroundColor: "rgba(0,0,0,.5)",
358
- border: "0px rgba(0,0,0,.5) solid",
359
- color: "#aaa",
360
- selectedBackgroundColor: "rgba(0,0,0,.8)",
361
- selectedBorder: "0px rgba(0,0,0,.8) solid",
362
- selectedColor: "#fff",
363
- },
364
- };
365
- console.log(
366
- style[this.dot_type],
367
- "style[this.dot_type]style[this.dot_type]style[this.dot_type]"
368
- );
369
- return style[this.dot_type];
370
- },
371
- topDotStyleData() {
372
- let alpha = 0.6;
373
- let selectedColor = `rgba(${color(this.mainColor)
374
- .alpha(alpha)
375
- .array()
376
- .join(",")})`;
377
- let style = {
378
- dot: {
379
- backgroundColor: "rgba(166,166,166,.5)",
380
- border: "0px rgba(166,166,166,.5) solid",
381
- color: "#fff",
382
- selectedBackgroundColor: selectedColor,
383
- selectedBorder: `0px this.mainColor solid`,
384
- },
385
- default: {
386
- width: 16,
387
- backgroundColor: "rgba(200,200,200,.45)",
388
- border: "1px rgba(200,200,200,.45) solid",
389
- color: "#fff",
390
- selectedBackgroundColor: selectedColor,
391
- selectedBorder: `1px this.mainColor solid`,
392
- },
393
- round: {
394
- backgroundColor: "rgba(166,166,166,.5)",
395
- border: "0px rgba(166,166,166,.5) solid",
396
- color: "#fff",
397
- selectedBackgroundColor: selectedColor,
398
- selectedBorder: `0px this.mainColor solid`,
399
- },
400
- nav: {
401
- backgroundColor: "rgba(0,0,0,.5)",
402
- border: "1px rgba(0,0,0,.5) solid",
403
- color: "#fff",
404
- selectedBackgroundColor: "rgba(255, 255, 255, 1)",
405
- selectedBorder: "1px rgba(255, 255, 255 1) solid",
406
- },
407
- indexes: {
408
- backgroundColor: "rgba(0,0,0,.5)",
409
- border: "0px rgba(0,0,0,.5) solid",
410
- color: "#aaa",
411
- selectedBackgroundColor: "rgba(0,0,0,.8)",
412
- selectedBorder: "0px rgba(0,0,0,.8) solid",
413
- selectedColor: "#fff",
414
- },
415
- };
416
- return style[this.top_dot_type];
417
- },
418
- bottomDotStyleData() {
419
- let alpha = 0.6;
420
- let selectedColor = `rgba(${color(this.mainColor)
421
- .alpha(alpha)
422
- .array()
423
- .join(",")})`;
424
- let style = {
425
- dot: {
426
- backgroundColor: "rgba(166,166,166,.5)",
427
- border: "0px rgba(166,166,166,.5) solid",
428
- color: "#fff",
429
- selectedBackgroundColor: selectedColor,
430
- selectedBorder: `0px this.mainColor solid`,
431
- },
432
- default: {
433
- width: 16,
434
- backgroundColor: "rgba(200,200,200,.45)",
435
- border: "1px rgba(200,200,200,.45) solid",
436
- color: "#fff",
437
- selectedBackgroundColor: selectedColor,
438
- selectedBorder: `1px this.mainColor solid`,
439
- },
440
- round: {
441
- backgroundColor: "rgba(166,166,166,.5)",
442
- border: "0px rgba(166,166,166,.5) solid",
443
- color: "#fff",
444
- selectedBackgroundColor: selectedColor,
445
- selectedBorder: `0px this.mainColor solid`,
446
- },
447
- nav: {
448
- backgroundColor: "rgba(0,0,0,.5)",
449
- border: "1px rgba(0,0,0,.5) solid",
450
- color: "#fff",
451
- selectedBackgroundColor: "rgba(255, 255, 255, 1)",
452
- selectedBorder: "1px rgba(255, 255, 255 1) solid",
453
- },
454
- indexes: {
455
- backgroundColor: "rgba(0,0,0,.5)",
456
- border: "0px rgba(0,0,0,.5) solid",
457
- color: "#aaa",
458
- selectedBackgroundColor: "rgba(0,0,0,.8)",
459
- selectedBorder: "0px rgba(0,0,0,.8) solid",
460
- selectedColor: "#fff",
461
- },
462
- };
463
- return style[this.bottom_dot_type];
464
- },
465
- },
466
- watch: {
467
- container(value) {
468
- this.init(value);
469
- },
470
- },
471
- created() {
472
- this.init(this.container);
473
- this.isPreview = this.$configProject.isPreview;
474
- },
475
- methods: {
476
- onJfbLoad(options) {
477
- //获取大图列表
478
- jfbRootExec("getListPosterContent", {
479
- vm: this,
480
- data: {
481
- page_id: this.pageAttr["page_id"], //页面ID
482
- container_id: this.containerId + "big", //组件ID
483
- page_size: this.number,
484
- },
485
- })
486
- .then((res) => {
487
- //如果res.list为空且isPreview为true,则获取测试数据
488
- if (res.list.length === 0 && this.isPreview) {
489
- res.list = this.getTestData("big");
490
- }
491
- //将res.list中的image_url替换为服务地址
492
- this.bigList =
493
- res.list &&
494
- res.list.length > 0 &&
495
- res.list.map((item) => {
496
- item.image_url = item.image_url
497
- ? getServiceUrl(item.image_url)
498
- : "";
499
- return item;
500
- });
501
- })
502
- .catch((error) => {
503
- console.error(error);
504
- });
505
- //获取小图上列表
506
- jfbRootExec("getListPosterContent", {
507
- vm: this,
508
- data: {
509
- page_id: this.pageAttr["page_id"], //页面ID
510
- container_id: this.containerId + "top", //组件ID
511
- page_size: this.topNumber,
512
- },
513
- })
514
- .then((res) => {
515
- //如果res.list为空且isPreview为true,则获取测试数据
516
- if (res.list.length === 0 && this.isPreview) {
517
- res.list = this.getTestData("top");
518
- }
519
- //将res.list中的image_url替换为服务地址
520
- this.topList =
521
- res.list &&
522
- res.list.length > 0 &&
523
- res.list.map((item) => {
524
- item.image_url = item.image_url
525
- ? getServiceUrl(item.image_url)
526
- : "";
527
- return item;
528
- });
529
- })
530
- .catch((error) => {
531
- console.error(error);
532
- });
533
- //获取小图下列表
534
- jfbRootExec("getListPosterContent", {
535
- vm: this,
536
- data: {
537
- page_id: this.pageAttr["page_id"], //页面ID
538
- container_id: this.containerId + "bottom", //组件ID
539
- page_size: this.bottomNumber,
540
- },
541
- })
542
- .then((res) => {
543
- //如果res.list为空且isPreview为true,则获取测试数据
544
- if (res.list.length === 0 && this.isPreview) {
545
- res.list = this.getTestData("bottom");
546
- }
547
- //将res.list中的image_url替换为服务地址
548
- this.bottomList =
549
- res.list &&
550
- res.list.length > 0 &&
551
- res.list.map((item) => {
552
- item.image_url = item.image_url
553
- ? getServiceUrl(item.image_url)
554
- : "";
555
- return item;
556
- });
557
- })
558
- .catch((error) => {
559
- console.error(error);
560
- });
561
- },
562
- handleBigAnimationfinish(e) {
563
- this.current = e.detail.current;
564
- },
565
- handleTopAnimationfinish(e) {
566
- this.topCurrent = e.detail.current;
23
+ import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
24
+ import { jfbRootExec } from "@/utils/xd.event";
25
+ import JfbBasePosterBigSmallMixin from "./JfbBasePosterBigSmallMixin";
26
+ import { getContainerPropsValue } from "@/utils/xd.base";
27
+ import componentsMixins from "@/mixins/componentsMixins";
28
+ import extsMixins from "@/mixins/extsMixins";
29
+ export default {
30
+ name: "JfbBasePosterBigSmall",
31
+ components: {
32
+ XdFontIcon
567
33
  },
568
- handleBottomAnimationfinish(e) {
569
- this.bottomCurrent = e.detail.current;
570
- },
571
- handleClick(item) {
572
- //内部链接跳转地址
573
- if (item.redirect_type === "INN") {
574
- try {
575
- let url = JSON.parse(item.redirect_data);
576
- let params = "";
577
- if (item["redirect_params"]) params = `?${item["redirect_params"]}`;
578
- this.$xdUniHelper.navigateTo({
579
- url: url.page + params,
580
- });
581
- } catch (e) {
582
- console.error(e);
583
- }
584
- }
34
+ mixins: [
35
+ componentsMixins, extsMixins, JfbBasePosterBigSmallMixin
36
+ ],
37
+ data() {
38
+ return {
585
39
 
586
- //外部链接
587
- if (item.redirect_type === "URL") {
588
- let reg = /^(http:\/\/|https:\/\/|\/\/)+.+$/;
589
- //#ifdef MP-WEIXIN
590
- try {
591
- let url = JSON.parse(item.redirect_data);
592
- if (reg.test(url.url) && this.$configProject.extras.webview) {
593
- console.warn(`广告跳转外站: ${url.url}`);
594
- this.$xdUniHelper.navigateTo({
595
- url: `${
596
- this.$configProject.extras.webview
597
- }?seatUrl=${Base64.encodeURI(url.url)}`,
598
- });
599
- } else {
600
- throw Error("地址错误");
601
- }
602
- } catch (e) {
603
- console.error(e);
604
- }
605
- //#endif
606
- //#ifdef H5
607
- try {
608
- let url = JSON.parse(item.redirect_data);
609
- if (reg.test(url.url)) {
610
- console.warn(`广告跳转外站: ${url.url}`);
611
- window.location.href = url.url;
612
- } else {
613
- throw Error("地址错误");
614
- }
615
- } catch (e) {
616
- console.error(e);
617
- }
618
- //#endif
40
+ //todo
619
41
  }
620
42
  },
621
- getTestData(type) {
622
- let width;
623
- let height;
624
- // 根据type参数,设置width和height
625
- if (type == "big") {
626
- width = this.bigWidth;
627
- height = this.bigHeight;
628
- }
629
- if (type == "top") {
630
- width = this.bigWidth;
631
- height = this.smallHeight;
632
- }
633
- if (type == "bottom") {
634
- width = this.bigWidth;
635
- height = this.smallHeight;
43
+ watch: {
44
+ container(value) {
45
+ this.init(value)
636
46
  }
637
- // 创建一个临时数组,用于存放生成的测试数据
638
- let temp = [];
639
- // 循环number次,生成number个测试数据
640
- for (let i = 0; i < this.number; i++) {
641
- // 克隆一个测试数据
642
- let item = this.$xdUniHelper.cloneDeep(this.test);
643
- // 设置content_id和content_name
644
- item.content_id = i;
645
- item.content_name = item.content_name + i;
646
- // 设置图片url
647
- item.image_url = `//dummyimage.com/${width}x${height}`;
648
- // 将生成的测试数据添加到临时数组中
649
- temp.push(item);
650
- }
651
- // 返回临时数组
652
- return temp;
653
47
  },
654
- /**
655
- * @description 监听事件变化
656
- * @param container {object} 业务组件对象自己
657
- */
658
- init(container) {
659
- this.height = getContainerPropsValue(container, "content.height", "500");
660
- // 获取最外面间距,如果没有则设置默认值
661
- this.mS = getContainerPropsValue(container, "content.margin", {
662
- top: 0,
663
- bottom: 0,
664
- left: 0,
665
- right: 0,
666
- });
667
- this.position = getContainerPropsValue(container, "content.position", 1);
668
- // 获取大小图之间间距,如果没有则设置默认值
669
- this.msMargin = getContainerPropsValue(container, "content.msMargin", 10);
670
- // 获取安全区域宽度,减去margin的值,再除以2,获取大图宽度
671
- this.bigWidth =
672
- uni.getSystemInfoSync().safeArea.width -
673
- (this.mS.left + this.mS.right + Number(this.msMargin)) / 2;
674
- this.bigHeight = this.height - (this.mS.top + this.mS.bottom);
675
- // 获取容器高度,减去margin的值,再除以2,获取小图高度
676
- this.smallHeight =
677
- (this.height - (this.mS.top + this.mS.bottom + Number(this.msMargin))) /
678
- 2;
679
- // 获取大图数据
680
- this.isCarousel = getContainerPropsValue(
681
- container,
682
- "content.isCarousel",
683
- 1
684
- );
685
- this.radius = getContainerPropsValue(container, "content.radius", 0);
686
- this.number = getContainerPropsValue(container, "content.number", 1);
687
- this.dot_type = getContainerPropsValue(
688
- container,
689
- "content.dot_type",
690
- "dot"
691
- );
692
- this.carouselTime =
693
- Number(getContainerPropsValue(container, "content.carouselTime", 5)) *
694
- 1000;
695
- this.topRadius = getContainerPropsValue(
696
- container,
697
- "content.topRadius",
698
- 0
699
- );
48
+ created() {
49
+ this.init(this.container);
50
+
51
+ //todo
52
+ },
53
+ methods: {
54
+ onJfbLoad(options) {
700
55
 
701
- // 获取小图上数据
702
- this.topNumber = getContainerPropsValue(
703
- container,
704
- "content.topNumber",
705
- 1
706
- );
707
- this.top_dot_type = getContainerPropsValue(
708
- container,
709
- "content.top_dot_type",
710
- "dot"
711
- );
712
- this.topIsCarousel = getContainerPropsValue(
713
- container,
714
- "content.topIsCarousel",
715
- 1
716
- );
717
- this.topCarouselTime =
718
- Number(
719
- getContainerPropsValue(container, "content.topCarouselTime", 5)
720
- ) * 1000;
56
+ // jfbRootExec('baiduUserLogin', {
721
57
 
722
- //获取小图下数据
723
- this.bottomNumber = getContainerPropsValue(
724
- container,
725
- "content.bottomNumber",
726
- 1
727
- );
728
- this.bottom_dot_type = getContainerPropsValue(
729
- container,
730
- "content.bottom_dot_type",
731
- "dot"
732
- );
58
+ // vm: this,// data: {
59
+
60
+ // account: 'gaoshiyong',// password: '123456789',// type: 3,// ...options
61
+
62
+ // }
63
+
64
+ // }).then().catch()
65
+ },
66
+ /**
67
+ * @description 监听事件变化
68
+ * @param container {object} 业务组件对象自己
69
+ */
70
+ init(container) {
71
+
72
+ //this.bgcolor = getContainerPropsValue(container, 'content.bgcolor', '#fff');
73
+
74
+ //this.height = getContainerPropsValue(container, 'content.height', 10);
75
+ },
76
+ onJfbScroll(options) {
77
+ console.log('event.onJfbScroll', options)
78
+ },
79
+ onJfbReachBottom(options) {
80
+ console.log('event.onJfbReachBottom', options)
81
+ },
82
+ onJfbShow(options) {
83
+ console.log('event.onJfbShow', options)
84
+ },
85
+ onJfbHide(options) {
86
+ console.log('event.onJfbHide', options)
87
+ },
88
+ onJfbBack(options) {
89
+ console.log('event.onJfbBack', options)
90
+ },
91
+ onJfbUpdate(...data) {
92
+ console.log('event.onJfbUpdate', data)
93
+ },
94
+ onJfbCustomEvent(options) {
95
+ console.log('event.onJfbReachBottom', options)
96
+ },
97
+ }
98
+ }
733
99
 
734
- this.bottomRadius = getContainerPropsValue(
735
- container,
736
- "content.bottomRadius",
737
- 0
738
- );
739
- this.bottomIsCarousel = getContainerPropsValue(
740
- container,
741
- "content.bottomIsCarousel",
742
- 1
743
- );
744
- this.bottomCarouselTime =
745
- Number(
746
- getContainerPropsValue(container, "content.bottomCarouselTime", 5)
747
- ) * 1000;
748
- },
749
- },
750
- };
751
100
  </script>
752
101
 
753
102
  <style scoped lang="less">
754
- @import "./JfbBasePosterBigSmallLess.less";
103
+ @import "./JfbBasePosterBigSmallLess.less";
104
+
105
+ .jfb-base-poster-big-small {
106
+ &__body{
755
107
 
756
- .jfb-base-poster-big-small {
757
- &__body {
758
- &-wrap {
759
- display: flex;
760
108
  }
761
109
  }
762
- }
763
110
  </style>