jufubao-base 1.0.132-beta3 → 1.0.133

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.
Files changed (194) hide show
  1. package/package.json +3 -4
  2. package/src/components/JfbBaseAddress/Attr.js +5 -11
  3. package/src/components/JfbBaseAddress/JfbBaseAddress.vue +3 -3
  4. package/src/components/JfbBaseAddress/JfbBaseAddressLess.less +19 -18
  5. package/src/components/JfbBaseAfterOrderDetail/Attr.js +7 -19
  6. package/src/components/JfbBaseAfterOrderDetail/JfbBaseAfterOrderDetail.vue +4 -6
  7. package/src/components/JfbBaseAfterOrderDetail/JfbBaseAfterOrderDetailLess.less +19 -18
  8. package/src/components/JfbBaseAfterOrderList/Attr.js +16 -25
  9. package/src/components/JfbBaseAfterOrderList/JfbBaseAfterOrderList.vue +9 -6
  10. package/src/components/JfbBaseAfterOrderList/JfbBaseAfterOrderListLess.less +19 -18
  11. package/src/components/JfbBaseBack/JfbBaseBackLess.less +19 -18
  12. package/src/components/JfbBaseBackground/Attr.js +8 -9
  13. package/src/components/JfbBaseBackground/JfbBaseBackground.vue +3 -0
  14. package/src/components/JfbBaseBackground/JfbBaseBackgroundLess.less +19 -18
  15. package/src/components/JfbBaseBlock/Attr.js +2 -12
  16. package/src/components/JfbBaseBlock/JfbBaseBlock.vue +8 -1
  17. package/src/components/JfbBaseBlock/JfbBaseBlockLess.less +19 -18
  18. package/src/components/JfbBaseBottomNotice/JfbBaseBottomNoticeLess.less +19 -18
  19. package/src/components/JfbBaseCard/Attr.js +34 -76
  20. package/src/components/JfbBaseCard/JfbBaseCardLess.less +19 -18
  21. package/src/components/JfbBaseCardBind/JfbBaseCardBindLess.less +19 -18
  22. package/src/components/JfbBaseCardBindV2/Attr.js +4 -5
  23. package/src/components/JfbBaseCardBindV2/JfbBaseCardBindV2Less.less +19 -18
  24. package/src/components/JfbBaseCardDetail/Attr.js +3 -4
  25. package/src/components/JfbBaseCardDetail/JfbBaseCardDetailLess.less +19 -18
  26. package/src/components/JfbBaseCardDetailEntry/Attr.js +8 -10
  27. package/src/components/JfbBaseCardDetailEntry/JfbBaseCardDetailEntryLess.less +19 -18
  28. package/src/components/JfbBaseCardDisabled/Attr.js +3 -1
  29. package/src/components/JfbBaseCardDisabled/JfbBaseCardDisabledLess.less +19 -18
  30. package/src/components/JfbBaseCardDisabledEntry/JfbBaseCardDisabledEntryLess.less +19 -18
  31. package/src/components/JfbBaseCardEntry/Attr.js +67 -86
  32. package/src/components/JfbBaseCardEntry/JfbBaseCardEntry.vue +2 -3
  33. package/src/components/JfbBaseCardEntry/JfbBaseCardEntryLess.less +19 -18
  34. package/src/components/JfbBaseCardInfo/Attr.js +16 -22
  35. package/src/components/JfbBaseCardInfo/JfbBaseCardInfoLess.less +19 -18
  36. package/src/components/JfbBaseCardInfoEntry/Attr.js +11 -16
  37. package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntryLess.less +19 -18
  38. package/src/components/JfbBaseCardMerge/Attr.js +8 -21
  39. package/src/components/JfbBaseCardMerge/JfbBaseCardMerge.vue +30 -15
  40. package/src/components/JfbBaseCardMerge/JfbBaseCardMergeLess.less +19 -18
  41. package/src/components/JfbBaseCardMergeEntry/Attr.js +6 -20
  42. package/src/components/JfbBaseCardMergeEntry/JfbBaseCardMergeEntry.vue +25 -28
  43. package/src/components/JfbBaseCardMergeEntry/JfbBaseCardMergeEntryLess.less +19 -18
  44. package/src/components/JfbBaseCardShift/Attr.js +4 -18
  45. package/src/components/JfbBaseCardShift/JfbBaseCardShift.vue +11 -26
  46. package/src/components/JfbBaseCardShift/JfbBaseCardShiftLess.less +19 -18
  47. package/src/components/JfbBaseCardShiftEntry/Attr.js +26 -34
  48. package/src/components/JfbBaseCardShiftEntry/JfbBaseCardShiftEntry.vue +257 -294
  49. package/src/components/JfbBaseCardShiftEntry/JfbBaseCardShiftEntryLess.less +19 -18
  50. package/src/components/JfbBaseCardShiftEntry/Mock.js +1 -2
  51. package/src/components/JfbBaseCardSweepInfo/Attr.js +3 -5
  52. package/src/components/JfbBaseCardSweepInfo/JfbBaseCardSweepInfoLess.less +19 -18
  53. package/src/components/JfbBaseCardV2/Attr.js +15 -19
  54. package/src/components/JfbBaseCardV2/JfbBaseCardV2.vue +5 -3
  55. package/src/components/JfbBaseCardV2/JfbBaseCardV2Less.less +19 -18
  56. package/src/components/JfbBaseCardV3/Attr.js +12 -16
  57. package/src/components/JfbBaseCardV3/JfbBaseCardV3.vue +1 -1
  58. package/src/components/JfbBaseCardV3/JfbBaseCardV3Less.less +19 -18
  59. package/src/components/JfbBaseCity/Attr.js +4 -2
  60. package/src/components/JfbBaseCity/JfbBaseCityLess.less +19 -18
  61. package/src/components/JfbBaseClear/JfbBaseClearLess.less +19 -18
  62. package/src/components/JfbBaseClear/JfbBaseClearMixin.js +0 -12
  63. package/src/components/JfbBaseConDialog/Api.js +1 -1
  64. package/src/components/JfbBaseConDialog/Attr.js +20 -30
  65. package/src/components/JfbBaseConDialog/JfbBaseConDialog.vue +26 -45
  66. package/src/components/JfbBaseConDialog/JfbBaseConDialogLess.less +19 -18
  67. package/src/components/JfbBaseConDialog/Mock.js +1 -20
  68. package/src/components/JfbBaseConDialog/XdCouCardBind.vue +9 -15
  69. package/src/components/JfbBaseConList/Attr.js +224 -149
  70. package/src/components/JfbBaseConList/JfbBaseConList.vue +133 -150
  71. package/src/components/JfbBaseConList/JfbBaseConListLess.less +19 -18
  72. package/src/components/JfbBaseConPhone/JfbBaseConPhoneLess.less +19 -18
  73. package/src/components/JfbBaseEntry/Attr.js +21 -33
  74. package/src/components/JfbBaseEntry/JfbBaseEntry.vue +23 -34
  75. package/src/components/JfbBaseEntry/JfbBaseEntryLess.less +19 -18
  76. package/src/components/JfbBaseExpressDetail/JfbBaseExpressDetailLess.less +19 -18
  77. package/src/components/JfbBaseFastLink/Api.js +54 -1
  78. package/src/components/JfbBaseFastLink/Attr.js +116 -168
  79. package/src/components/JfbBaseFastLink/JfbBaseFastLink.vue +16 -12
  80. package/src/components/JfbBaseFastLink/JfbBaseFastLinkLess.less +19 -18
  81. package/src/components/JfbBaseFooter/Attr.js +22 -28
  82. package/src/components/JfbBaseFooter/JfbBaseFooter.vue +15 -19
  83. package/src/components/JfbBaseFooter/JfbBaseFooterLess.less +19 -18
  84. package/src/components/JfbBaseHeader/Attr.js +91 -89
  85. package/src/components/JfbBaseHeader/JfbBaseHeader.vue +29 -28
  86. package/src/components/JfbBaseHeader/JfbBaseHeaderLess.less +19 -18
  87. package/src/components/JfbBaseLine/Attr.js +59 -0
  88. package/src/components/JfbBaseLine/JfbBaseLine.vue +105 -0
  89. package/src/components/JfbBaseLine/JfbBaseLineLess.less +80 -0
  90. package/src/components/JfbBaseLine/JfbBaseLineMixin.js +30 -0
  91. package/src/components/JfbBaseLogin/Attr.js +88 -111
  92. package/src/components/JfbBaseLogin/JfbBaseLogin.vue +1 -0
  93. package/src/components/JfbBaseLogin/JfbBaseLoginLess.less +19 -18
  94. package/src/components/JfbBaseLoginForgetPwd/Attr.js +45 -52
  95. package/src/components/JfbBaseLoginForgetPwd/JfbBaseLoginForgetPwd.vue +14 -14
  96. package/src/components/JfbBaseLoginForgetPwd/JfbBaseLoginForgetPwdLess.less +19 -18
  97. package/src/components/JfbBaseLoginSetPwd/Attr.js +4 -6
  98. package/src/components/JfbBaseLoginSetPwd/JfbBaseLoginSetPwdLess.less +19 -18
  99. package/src/components/JfbBaseMapOverlay/JfbBaseMapOverlayLess.less +19 -18
  100. package/src/components/JfbBaseMapSearch/Attr.js +15 -0
  101. package/src/components/JfbBaseMapSearch/JfbBaseMapSearch.vue +25 -1
  102. package/src/components/JfbBaseMapSearch/JfbBaseMapSearchLess.less +19 -18
  103. package/src/components/JfbBaseMergeUserCard/Attr.js +3 -4
  104. package/src/components/JfbBaseMergeUserCard/JfbBaseMergeUserCardLess.less +19 -18
  105. package/src/components/JfbBaseMultipleExpress/Attr.js +3 -4
  106. package/src/components/JfbBaseMultipleExpress/JfbBaseMultipleExpressLess.less +19 -18
  107. package/src/components/JfbBaseMy/JfbBaseMyLess.less +19 -18
  108. package/src/components/JfbBaseMySetting/Attr.js +1 -1
  109. package/src/components/JfbBaseMySetting/JfbBaseMySettingLess.less +19 -18
  110. package/src/components/JfbBaseNotice/Attr.js +56 -97
  111. package/src/components/JfbBaseNotice/JfbBaseNotice.vue +52 -70
  112. package/src/components/JfbBaseNotice/JfbBaseNoticeLess.less +19 -18
  113. package/src/components/JfbBaseNoticeBottom/JfbBaseNoticeBottomLess.less +19 -18
  114. package/src/components/JfbBaseNoticeTop/JfbBaseNoticeTopLess.less +19 -18
  115. package/src/components/JfbBaseOrderDetail/Attr.js +193 -210
  116. package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +3 -6
  117. package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetailLess.less +19 -18
  118. package/src/components/JfbBaseOrderList/Attr.js +43 -55
  119. package/src/components/JfbBaseOrderList/JfbBaseOrderList.vue +3 -5
  120. package/src/components/JfbBaseOrderList/JfbBaseOrderListLess.less +19 -18
  121. package/src/components/JfbBasePay/Attr.js +13 -2
  122. package/src/components/JfbBasePay/JfbBasePay.vue +6 -7
  123. package/src/components/JfbBasePay/JfbBasePayLess.less +19 -18
  124. package/src/components/JfbBasePay/Mock.js +1 -2
  125. package/src/components/JfbBasePhoneCollect/Attr.js +2 -27
  126. package/src/components/JfbBasePhoneCollect/JfbBasePhoneCollect.vue +1 -1
  127. package/src/components/JfbBasePhoneCollect/JfbBasePhoneCollectLess.less +19 -18
  128. package/src/components/JfbBasePhoneLogin/Attr.js +2 -27
  129. package/src/components/JfbBasePhoneLogin/JfbBasePhoneLoginLess.less +19 -18
  130. package/src/components/JfbBasePoster/Attr.js +83 -103
  131. package/src/components/JfbBasePoster/JfbBasePoster.vue +141 -134
  132. package/src/components/JfbBasePoster/JfbBasePosterLess.less +19 -18
  133. package/src/components/JfbBasePosterBigSmall/Attr.js +76 -93
  134. package/src/components/JfbBasePosterBigSmall/JfbBasePosterBigSmall.vue +7 -3
  135. package/src/components/JfbBasePosterBigSmall/JfbBasePosterBigSmallLess.less +19 -18
  136. package/src/components/JfbBasePosterBigSmall/getWidthHeight.js +2 -2
  137. package/src/components/JfbBasePosterEntry/Attr.js +33 -44
  138. package/src/components/JfbBasePosterEntry/JfbBasePosterEntry.vue +49 -44
  139. package/src/components/JfbBasePosterEntry/JfbBasePosterEntryLess.less +19 -18
  140. package/src/components/JfbBasePosterType/Attr.js +48 -82
  141. package/src/components/JfbBasePosterType/FourScreen.vue +2 -8
  142. package/src/components/JfbBasePosterType/JfbBasePosterType.vue +59 -36
  143. package/src/components/JfbBasePosterType/JfbBasePosterTypeLess.less +19 -18
  144. package/src/components/JfbBasePosterType/Screen.vue +284 -0
  145. package/src/components/JfbBaseRecharge/Attr.js +23 -35
  146. package/src/components/JfbBaseRecharge/JfbBaseRecharge.vue +8 -54
  147. package/src/components/JfbBaseRecharge/JfbBaseRechargeLess.less +19 -18
  148. package/src/components/JfbBaseRechargeOrder/Attr.js +22 -32
  149. package/src/components/JfbBaseRechargeOrder/JfbBaseRechargeOrder.vue +7 -12
  150. package/src/components/JfbBaseRechargeOrder/JfbBaseRechargeOrderLess.less +19 -18
  151. package/src/components/JfbBaseRechargeOrderDetail/JfbBaseRechargeOrderDetailLess.less +19 -18
  152. package/src/components/JfbBaseRechargeSuccess/Attr.js +8 -10
  153. package/src/components/JfbBaseRechargeSuccess/JfbBaseRechargeSuccessLess.less +19 -18
  154. package/src/components/JfbBaseSearch/Api.js +60 -0
  155. package/src/components/JfbBaseSearch/Attr.js +148 -6
  156. package/src/components/JfbBaseSearch/JfbBaseSearch.vue +37 -8
  157. package/src/components/JfbBaseSearch/JfbBaseSearchLess.less +19 -18
  158. package/src/components/JfbBaseSearch/Mock.js +5 -0
  159. package/src/components/JfbBaseSetPwd/Attr.js +147 -6
  160. package/src/components/JfbBaseSetPwd/JfbBaseSetPwdLess.less +19 -18
  161. package/src/components/JfbBaseSuccess/Attr.js +17 -78
  162. package/src/components/JfbBaseSuccess/JfbBaseSuccessLess.less +19 -18
  163. package/src/components/JfbBaseTestApi/JfbBaseTestApiLess.less +19 -18
  164. package/src/components/JfbBaseTestBody/JfbBaseTestBodyLess.less +19 -18
  165. package/src/components/JfbBaseTestBottom/JfbBaseTestBottomLess.less +19 -18
  166. package/src/components/JfbBaseTestNotice/JfbBaseTestNoticeLess.less +19 -18
  167. package/src/components/JfbBaseTestTop/JfbBaseTestTopLess.less +19 -18
  168. package/src/components/JfbBaseUserCenter/Attr.js +53 -72
  169. package/src/components/JfbBaseUserCenter/JfbBaseUserCenter.vue +27 -40
  170. package/src/components/JfbBaseUserCenter/JfbBaseUserCenterLess.less +19 -18
  171. package/src/components/JfbBaseUserInfo/Attr.js +45 -54
  172. package/src/components/JfbBaseUserInfo/JfbBaseUserInfo.vue +21 -21
  173. package/src/components/JfbBaseUserInfo/JfbBaseUserInfoLess.less +19 -18
  174. package/src/components/JfbBaseUserOrder/Attr.js +92 -118
  175. package/src/components/JfbBaseUserOrder/JfbBaseUserOrder.vue +7 -21
  176. package/src/components/JfbBaseUserOrder/JfbBaseUserOrderLess.less +19 -18
  177. package/src/components/JfbBaseVideo/Attr.js +19 -72
  178. package/src/components/JfbBaseVideo/JfbBaseVideo.vue +28 -69
  179. package/src/components/JfbBaseVideo/JfbBaseVideoLess.less +19 -18
  180. package/src/components/JfbBaseVideo/XdVideo.vue +44 -6
  181. package/src/components/JfbBaseWallet/JfbBaseWalletLess.less +19 -18
  182. package/src/components/{JfbBaseClear → JfbBaseWalletDetail}/Attr.js +0 -1
  183. package/src/components/JfbBaseWalletDetail/JfbBaseWalletDetailLess.less +19 -18
  184. package/src/components/JfbBaseWalletDetail/JfbBaseWalletDetailMixin.js +12 -0
  185. package/src/components/JfbBaseWalletEffective/JfbBaseWalletEffectiveLess.less +19 -18
  186. package/src/components/JfbBaseWalletIndex/JfbBaseWalletIndexLess.less +19 -18
  187. package/src/components/JfbBaseWalletItem/JfbBaseWalletItemLess.less +19 -18
  188. package/src/components/JfbBaseWebview/JfbBaseWebviewLess.less +19 -18
  189. package/src/components/JfbBaseWxAuthorize/Attr.js +3 -31
  190. package/src/components/JfbBaseWxAuthorize/JfbBaseWxAuthorize.vue +26 -32
  191. package/src/components/JfbBaseWxAuthorize/JfbBaseWxAuthorizeLess.less +19 -18
  192. package/src/components/JfbBaseWxAuthorizeError/Attr.js +17 -21
  193. package/src/components/JfbBaseWxAuthorizeError/JfbBaseWxAuthorizeErrorLess.less +19 -18
  194. package/src/components/JfbBaseCardShift/Mock.js +0 -21
@@ -13,19 +13,19 @@
13
13
  <view class="jfb-base-poster-type__edit-icon" @click="delEdit">删除</view>
14
14
  </view>
15
15
  <!-- #endif -->
16
- <view class="jfb-base-poster-type__body" v-if="noData">
17
- <view class="x-line"></view>
18
- <view
19
- class="jfb-base-poster-cont"
20
- :style="{
21
- margin: margin,
22
- backgroundColor: bgColor,
23
- borderRadius: bgRadius + 'rpx'
24
- }"
25
- >
26
- <four-screen :config="getConfig" :content="info"></four-screen>
27
- </view>
28
-
16
+ <view
17
+ class="jfb-base-poster-type__body"
18
+ v-if="noData"
19
+ :style="{
20
+ margin: margin,
21
+ backgroundColor: bgColor,
22
+ borderRadius: bgRadius + 'rpx'
23
+ }
24
+ ">
25
+ <four-screen
26
+ :config="getConfig"
27
+ :content="info"
28
+ ></four-screen>
29
29
  </view>
30
30
  </view>
31
31
  </template>
@@ -41,6 +41,7 @@
41
41
  import getServiceUrl from '@/common/getServiceUrl'
42
42
  import XdImage from "@/components/XdImage/XdImage";
43
43
  import XdSwiper from "@/components/XdSwiper/XdSwiper";
44
+ import Screen from "./Screen";
44
45
  import FourScreen from "./FourScreen";
45
46
  import XdSwiperDot from "./XdSwiperDot";
46
47
  export default {
@@ -49,6 +50,7 @@
49
50
  XdFontIcon,
50
51
  XdImage,
51
52
  XdSwiper,
53
+ Screen,
52
54
  FourScreen,
53
55
  XdSwiperDot
54
56
  },
@@ -67,11 +69,15 @@
67
69
  jdRows: 1, //行
68
70
  cells: 4, //列
69
71
  shadow: false, //是否设置阴影
70
- shadowColor:'rgba(0,0,0,.3)',
71
72
  radius: '20', //10/20/40 , 小/中/大
72
73
  timer: null,
73
74
  info: [],
74
- mS: {},
75
+ mS: {
76
+ top: 0,
77
+ bottom: 0,
78
+ left: 0,
79
+ right: 0
80
+ },
75
81
  isPreview: false,
76
82
  noData:false,
77
83
 
@@ -79,6 +85,26 @@
79
85
  textColor: '#333',
80
86
  bgColor:'rgba(0,0,0,0)',
81
87
  bgRadius: 0,
88
+
89
+ test: {
90
+ "content_id": "KpBbUKdj4aBejwe7Fh1ki",
91
+ "position_id": "QCk3PmoyQmOWRP1SxnYR3",
92
+ "partner_id": 0,
93
+ "site_id": "",
94
+ "content_name": "测试.",
95
+ "image_url": "//dummyimage.com/200x200",
96
+ "redirect_type": "EMP",
97
+ "redirect_type_name": "无链接",
98
+ "redirect_data": "",
99
+ "sort": "",
100
+ "status": "",
101
+ "start_time": "",
102
+ "end_time": "",
103
+ "op_user_id": "",
104
+ "created_time": 0,
105
+ "updated_time": 0
106
+ }
107
+
82
108
  }
83
109
  },
84
110
  computed: {
@@ -98,24 +124,18 @@
98
124
  jdRows: this.jdRows,
99
125
  cells: this.cells,
100
126
  shadow: this.shadow,
101
- shadowColor: this.shadowColor,
102
127
  textColor: this.textColor,
103
128
  }
104
129
  },
105
130
  margin(){
106
- let str = `${this.checkValue(this.mS.top, 0)}rpx`;
107
- str = `${str} ${this.checkValue(this.mS.right, 0)}rpx`;
108
- str = `${str} ${this.checkValue(this.mS.bottom, 0)}rpx`;
109
- str = `${str} ${this.checkValue(this.mS.left, 0)}rpx`;
110
- return str
131
+ return `${this.mS.top||0}rpx ${this.mS.right||0}rpx ${this.mS.bottom||0}rpx ${this.mS.left||0}rpx`
111
132
  },
112
133
  dotStyleData() {
113
134
  return {}
114
135
  }
115
136
  },
116
137
  watch: {
117
- container(value,oloValue) {
118
- if(JSON.stringify(value) === JSON.stringify(oloValue)) return;
138
+ container(value) {
119
139
  this.init(value);
120
140
  if(this.timer) clearTimeout(this.timer);
121
141
  this.timer = setTimeout(()=>{
@@ -132,6 +152,7 @@
132
152
  this.current = e.detail.current;
133
153
  },
134
154
  handleClick(item, index){
155
+ debugger
135
156
  this.current = index;
136
157
  const handle = (data) => {
137
158
  try {
@@ -176,6 +197,12 @@
176
197
  },
177
198
  handleOne(list){
178
199
  this.info = this.handleImage(list);
200
+ console.log('this.info',this.info)
201
+ },
202
+ getDefualtValue(key){
203
+ if (key === 'margin') {
204
+ return {top: 0, bottom: 0, left: 0, right: 0}
205
+ }
179
206
  },
180
207
 
181
208
  /**
@@ -184,6 +211,7 @@
184
211
  */
185
212
  init(container) {
186
213
  this.radius = getContainerPropsValue(container, 'content.radius', '20');
214
+ this.padding = 0;
187
215
  this.poster = getContainerPropsValue(container, 'content.nav', {});
188
216
  if (this.poster.position) {
189
217
  this.posterPosition = this.poster.position
@@ -197,15 +225,13 @@
197
225
  this.carouselTime = Number(getContainerPropsValue(container, 'content.carouselTime', 5)) * 1000;
198
226
  this.useNumber = getContainerPropsValue(container, 'content.number', 1);
199
227
  this.shadow = getContainerPropsValue(container, 'content.shadow', 2);
200
- this.shadowColor = getContainerPropsValue(container, 'content.shadowColor', 'rgba(0,0,0,.3)');
201
- this.mS = getContainerPropsValue(container, 'content.margin', {});
228
+ this.mS = getContainerPropsValue(container, 'content.margin', {top: 0, left: 0, bottom:0, right: 0});
202
229
 
203
230
  //样式设置
204
231
  this.textColor = getContainerPropsValue(container, 'content.textColor', '#333');
205
232
  this.bgColor = getContainerPropsValue(container, 'content.bgColor','rgba(0,0,0,0)');
206
233
  this.bgRadius = getContainerPropsValue(container, 'content.bgRadius', '0');
207
234
 
208
-
209
235
  },
210
236
 
211
237
  onJfbLoad(options) {
@@ -221,10 +247,9 @@
221
247
  })
222
248
  .then(res => {
223
249
  if (res.list.length === 0 && this.isPreview) {
224
- let testData = this.$xdUniHelper.cloneDeep(this['posterTest']);
225
250
  let temp = [];
226
251
  for (let i = 0; i < this.useNumber; i++) {
227
- temp.push({...testData, content_id: i, content_name: `${testData.content_name}(${i})`})
252
+ temp.push({...this.test, content_id: i, content_name: `${this.test.content_name}(${i})`})
228
253
  }
229
254
  res.list = temp
230
255
  }
@@ -236,6 +261,7 @@
236
261
  })
237
262
  },
238
263
 
264
+
239
265
  onJfbUpdate(data){
240
266
  this.onJfbLoad(this.params);
241
267
  }
@@ -250,14 +276,11 @@
250
276
 
251
277
  .jfb-base-poster-type {
252
278
  &__body{
253
- & > view.jfb-base-poster-cont {
254
- box-sizing: border-box;
255
- overflow: hidden;
256
- justify-content: center;
257
- align-items: center;
258
- display: flex;
259
- }
260
-
279
+ box-sizing: border-box;
280
+ overflow: hidden;
281
+ justify-content: center;
282
+ align-items: center;
283
+ display: flex;
261
284
  }
262
285
  &__one.notCarousel {
263
286
  position: relative;
@@ -13,8 +13,9 @@
13
13
 
14
14
  //start
15
15
  .jfb-base-poster-type {
16
+ border: 1px dashed rgba(0, 0, 0, 0);
16
17
  box-sizing: border-box;
17
- min-height: unit(100, rpx);
18
+ min-height: unit(50, rpx);
18
19
 
19
20
  &__body{
20
21
  position: relative;
@@ -22,21 +23,21 @@
22
23
  z-index: 2
23
24
  }
24
25
 
25
- &.editx,&:hover {
26
+ &.editx {
26
27
  position: relative;
27
- z-index: 3;
28
- &::after {
29
- border: 2rpx dashed blue;
30
- content: " ";
31
- position: absolute;
32
- top:0;
33
- left:0;
34
- bottom:0;
35
- right:0;
36
- z-index: 4;
37
- cursor: pointer;
38
- }
28
+ border: 1px dashed blue;
29
+ box-sizing: border-box;
30
+ z-index: 3
31
+
32
+ }
39
33
 
34
+ &:hover {
35
+ border: 1px dashed blue;
36
+ }
37
+
38
+ &.noBorder {
39
+ border-color: rgba(0,0,0,0);
40
+ border-width: 0;
40
41
  }
41
42
 
42
43
 
@@ -71,9 +72,9 @@
71
72
 
72
73
  /**notPreview**/
73
74
  .jfb-base-poster-type {
74
- //&:before {
75
- //content: " ";
76
- //display: table;
77
- //}
75
+ &:before {
76
+ content: " ";
77
+ display: table;
78
+ }
78
79
  }
79
80
  /**endNotPreview**/
@@ -0,0 +1,284 @@
1
+ <template>
2
+ <view class="sreen">
3
+ <view
4
+ class="sreen__box notCarousel"
5
+ :class="{
6
+ three: cell === 3,
7
+ two: cell === 2,
8
+ }"
9
+ v-if="config.isCarousel === false"
10
+ :style="{height: height + 'rpx'}"
11
+ >
12
+ <view
13
+ v-for="item in getContent"
14
+ :key="item['content_id']"
15
+ :style="{
16
+ borderRadius: config.radius + 'rpx',
17
+ marginRight: config.padding + 'rpx',
18
+ }"
19
+ @click="handleClick(item)"
20
+ >
21
+ <image
22
+ :style="{
23
+ width: width + 'rpx',
24
+ height: height + 'rpx'
25
+ }"
26
+ :src="item.image_url"
27
+ mode="aspectFill"
28
+ ></image>
29
+ </view>
30
+ </view>
31
+ <view class="sreen__box carousel" v-if="config.isCarousel === true">
32
+ <xd-swiper-dot
33
+ :current="current"
34
+ :info="getContent"
35
+ field="content_name"
36
+ :mode="config.mode"
37
+ :dots-styles="config.dotStyleData"
38
+ :style="{height:(getHeight + 46) + 'rpx'}"
39
+ >
40
+ <xd-swiper
41
+ :indicator-dots="false"
42
+ :interval="config.carouselTime"
43
+ :list="getContent"
44
+ :current="current"
45
+ width="100%"
46
+ :height="getHeight + 'rpx'"
47
+ @onClickItem="handleClick"
48
+ @animationfinish="handleAnimationfinish"
49
+ >
50
+ <template slot-scope="{ item, index}">
51
+ <view
52
+ class="sreen__box-list"
53
+ :class="{
54
+ three: cell === 3,
55
+ two: cell === 2,
56
+ }"
57
+ :style="{
58
+ height: getHeight + 'rpx'
59
+ }"
60
+ >
61
+ <view
62
+ v-for="it in item"
63
+ :key="it['content_id']"
64
+ :style="{
65
+ borderRadius: config.radius + 'rpx',
66
+ marginRight: config.padding + 'rpx',
67
+ marginBottom: config.padding + 'rpx'
68
+ }"
69
+ @click="handleClick(it)"
70
+ >
71
+ <image
72
+ :style="{ width: width + 'rpx', height: height + 'rpx'}"
73
+ :src="it.image_url"
74
+ mode="aspectFill"></image>
75
+ </view>
76
+ </view>
77
+ </template>
78
+ </xd-swiper>
79
+ </xd-swiper-dot>
80
+ </view>
81
+ <view v-if="isPreview" class="carousel-mask"></view>
82
+ </view>
83
+ </template>
84
+
85
+ <script>
86
+ import XdSwiperDot from "./XdSwiperDot";
87
+ import XdSwiper from "@/components/XdSwiper/XdSwiper";
88
+
89
+ export default {
90
+ name: "ThreeScreen",
91
+ components: {
92
+ XdSwiperDot,
93
+ XdSwiper
94
+ },
95
+ props: {
96
+ config: {
97
+ type: Object,
98
+ required: true
99
+ },
100
+ content: {
101
+ type: Array,
102
+ required: true
103
+ },
104
+ cell: {
105
+ type: Number,
106
+ required: true
107
+ }
108
+ },
109
+ data(){
110
+ return {
111
+ timer: null,
112
+ width: 0,
113
+ height: 0,
114
+ padding:0,
115
+ status: false,
116
+ isPreview: false,
117
+ current: 0,
118
+ rows: 1, //行
119
+ }
120
+ },
121
+ watch:{
122
+ config(){
123
+ this.init()
124
+ },
125
+ content(){
126
+ this.init();
127
+ },
128
+ },
129
+ computed:{
130
+ getContent(){
131
+ if(this.config.isCarousel === false) {
132
+ return this.$xdUniHelper.cloneDeep(this.content).splice(0,this.cell * this.rows);
133
+ }
134
+ else{
135
+ let num = this.cell * this.rows ;
136
+ let maxPage = Math.ceil(this.content.length / num);
137
+ let arr = [];
138
+ for (let i = 1; i <= maxPage; i++) {
139
+ arr.push(this.$xdUniHelper.getLocalPaginationData(this.content, i, num))
140
+ }
141
+ return arr;
142
+
143
+ }
144
+ },
145
+ getHeight() {
146
+ let height = this.height * this.rows;
147
+ let padding = 0;
148
+ if (this.rows === 2) padding = Number(this.config.padding);
149
+ return height + padding;
150
+ },
151
+ },
152
+ created() {
153
+ this.isPreview = this.$configProject.isPreview;
154
+ this.init();
155
+ },
156
+ methods: {
157
+ handleAnimationfinish(e) {
158
+ this.current = e.detail.current;
159
+ },
160
+ init(){
161
+ if(this.timer) clearTimeout(this.timer);
162
+ this.timer = setTimeout(()=>{
163
+ this.width = Number(this.config.width);
164
+ this.height = Number(this.config.height);
165
+ this.padding = Number(this.config.padding);
166
+ }, 100)
167
+ },
168
+ handleClick(item, index) {
169
+ this.current = index;
170
+ const handle = (data) => {
171
+ try {
172
+ return JSON.parse(data);
173
+ } catch (e) {
174
+ return {}
175
+ }
176
+ };
177
+ if (this.$configProject.isPreview) {
178
+ console.log(item)
179
+ } else {
180
+ if (item['redirect_type'] === 'EMP') return;
181
+ let url = '';
182
+
183
+ if (item['redirect_type'] === 'URL') {
184
+ url = handle(item['redirect_data']).url || ''
185
+ }
186
+
187
+ if (item['redirect_type'] === 'INN') {
188
+ url = handle(item['redirect_data']).page || ''
189
+ }
190
+ if (item['redirect_type'] === 'APP') {
191
+ return;
192
+ }
193
+ if (url === '') {
194
+ return;
195
+ }
196
+ this.$xdUniHelper.navigateTo({url})
197
+ }
198
+ },
199
+ }
200
+ }
201
+ </script>
202
+
203
+ <style scoped lang="less">
204
+ .sreen {
205
+ width: calc(100% + 5px);
206
+ position: relative;
207
+
208
+ & .carousel-mask {
209
+ position: absolute;
210
+ left: 0;
211
+ right: 0;
212
+ top: 0;
213
+ bottom: 0;
214
+ background: rgba(0, 0, 0, 0);
215
+ }
216
+
217
+
218
+ &__box.notCarousel {
219
+ display: flex;
220
+ justify-content: flex-start;
221
+ align-items: center;
222
+ flex-wrap: wrap;
223
+ overflow: hidden;
224
+
225
+ &.two {
226
+ & > view:nth-child(2n) {
227
+ margin-right: 0 !important;
228
+ }
229
+ }
230
+
231
+ &.three {
232
+ & > view:nth-child(3n) {
233
+ margin-right: 0 !important;
234
+ }
235
+ }
236
+
237
+ & > view {
238
+ display: flex;
239
+ justify-content: center;
240
+ align-items: center;
241
+ flex-shrink: 0;
242
+ box-sizing: border-box;
243
+ overflow: hidden;
244
+ }
245
+ }
246
+
247
+ &__box.carousel {
248
+ display: flex;
249
+ justify-content: flex-start;
250
+ align-items: flex-start;
251
+ flex-wrap: wrap;
252
+ overflow: hidden;
253
+ }
254
+
255
+ & .sreen__box-list {
256
+ display: flex;
257
+ justify-content: flex-start;
258
+ align-items: flex-start;
259
+ flex-wrap: wrap;
260
+ overflow: hidden;
261
+
262
+ & view {
263
+ display: flex;
264
+ justify-content: center;
265
+ align-items: flex-start;
266
+ flex-shrink: 0;
267
+ box-sizing: border-box;
268
+ overflow: hidden;
269
+ }
270
+
271
+ &.two {
272
+ & > view:nth-child(2n) {
273
+ margin-right: 0 !important;
274
+ }
275
+ }
276
+
277
+ &.three {
278
+ & > view:nth-child(3n) {
279
+ margin-right: 0 !important;
280
+ }
281
+ }
282
+ }
283
+ }
284
+ </style>