jufubao-base 1.0.132-beta1 → 1.0.132-beta2

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 +4 -3
  2. package/src/components/JfbBaseAddress/Attr.js +11 -5
  3. package/src/components/JfbBaseAddress/JfbBaseAddress.vue +3 -3
  4. package/src/components/JfbBaseAddress/JfbBaseAddressLess.less +18 -19
  5. package/src/components/JfbBaseAfterOrderDetail/Attr.js +19 -7
  6. package/src/components/JfbBaseAfterOrderDetail/JfbBaseAfterOrderDetail.vue +6 -4
  7. package/src/components/JfbBaseAfterOrderDetail/JfbBaseAfterOrderDetailLess.less +18 -19
  8. package/src/components/JfbBaseAfterOrderList/Attr.js +25 -16
  9. package/src/components/JfbBaseAfterOrderList/JfbBaseAfterOrderList.vue +6 -9
  10. package/src/components/JfbBaseAfterOrderList/JfbBaseAfterOrderListLess.less +18 -19
  11. package/src/components/JfbBaseBack/JfbBaseBackLess.less +18 -19
  12. package/src/components/JfbBaseBackground/Attr.js +9 -8
  13. package/src/components/JfbBaseBackground/JfbBaseBackground.vue +0 -3
  14. package/src/components/JfbBaseBackground/JfbBaseBackgroundLess.less +18 -19
  15. package/src/components/JfbBaseBlock/Attr.js +12 -2
  16. package/src/components/JfbBaseBlock/JfbBaseBlock.vue +1 -8
  17. package/src/components/JfbBaseBlock/JfbBaseBlockLess.less +18 -19
  18. package/src/components/JfbBaseBottomNotice/JfbBaseBottomNoticeLess.less +18 -19
  19. package/src/components/JfbBaseCard/Attr.js +76 -34
  20. package/src/components/JfbBaseCard/JfbBaseCardLess.less +18 -19
  21. package/src/components/JfbBaseCardBind/JfbBaseCardBindLess.less +18 -19
  22. package/src/components/JfbBaseCardBindV2/Attr.js +5 -4
  23. package/src/components/JfbBaseCardBindV2/JfbBaseCardBindV2Less.less +18 -19
  24. package/src/components/JfbBaseCardDetail/Attr.js +4 -3
  25. package/src/components/JfbBaseCardDetail/JfbBaseCardDetailLess.less +18 -19
  26. package/src/components/JfbBaseCardDetailEntry/Attr.js +10 -8
  27. package/src/components/JfbBaseCardDetailEntry/JfbBaseCardDetailEntryLess.less +18 -19
  28. package/src/components/JfbBaseCardDisabled/Attr.js +1 -3
  29. package/src/components/JfbBaseCardDisabled/JfbBaseCardDisabledLess.less +18 -19
  30. package/src/components/JfbBaseCardDisabledEntry/JfbBaseCardDisabledEntryLess.less +18 -19
  31. package/src/components/JfbBaseCardEntry/Attr.js +86 -67
  32. package/src/components/JfbBaseCardEntry/JfbBaseCardEntry.vue +3 -2
  33. package/src/components/JfbBaseCardEntry/JfbBaseCardEntryLess.less +18 -19
  34. package/src/components/JfbBaseCardInfo/Attr.js +22 -16
  35. package/src/components/JfbBaseCardInfo/JfbBaseCardInfoLess.less +18 -19
  36. package/src/components/JfbBaseCardInfoEntry/Attr.js +16 -11
  37. package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntryLess.less +18 -19
  38. package/src/components/JfbBaseCardMerge/Attr.js +21 -8
  39. package/src/components/JfbBaseCardMerge/JfbBaseCardMerge.vue +15 -30
  40. package/src/components/JfbBaseCardMerge/JfbBaseCardMergeLess.less +18 -19
  41. package/src/components/JfbBaseCardMergeEntry/Attr.js +20 -6
  42. package/src/components/JfbBaseCardMergeEntry/JfbBaseCardMergeEntry.vue +28 -25
  43. package/src/components/JfbBaseCardMergeEntry/JfbBaseCardMergeEntryLess.less +18 -19
  44. package/src/components/JfbBaseCardShift/Attr.js +18 -4
  45. package/src/components/JfbBaseCardShift/JfbBaseCardShift.vue +26 -11
  46. package/src/components/JfbBaseCardShift/JfbBaseCardShiftLess.less +18 -19
  47. package/src/components/JfbBaseCardShift/Mock.js +21 -0
  48. package/src/components/JfbBaseCardShiftEntry/Attr.js +34 -26
  49. package/src/components/JfbBaseCardShiftEntry/JfbBaseCardShiftEntry.vue +294 -257
  50. package/src/components/JfbBaseCardShiftEntry/JfbBaseCardShiftEntryLess.less +18 -19
  51. package/src/components/JfbBaseCardShiftEntry/Mock.js +2 -1
  52. package/src/components/JfbBaseCardSweepInfo/Attr.js +5 -3
  53. package/src/components/JfbBaseCardSweepInfo/JfbBaseCardSweepInfoLess.less +18 -19
  54. package/src/components/JfbBaseCardV2/Attr.js +19 -15
  55. package/src/components/JfbBaseCardV2/JfbBaseCardV2.vue +3 -5
  56. package/src/components/JfbBaseCardV2/JfbBaseCardV2Less.less +18 -19
  57. package/src/components/JfbBaseCardV3/Attr.js +16 -12
  58. package/src/components/JfbBaseCardV3/JfbBaseCardV3.vue +1 -1
  59. package/src/components/JfbBaseCardV3/JfbBaseCardV3Less.less +18 -19
  60. package/src/components/JfbBaseCity/Attr.js +2 -4
  61. package/src/components/JfbBaseCity/JfbBaseCityLess.less +18 -19
  62. package/src/components/{JfbBaseWalletDetail → JfbBaseClear}/Attr.js +1 -0
  63. package/src/components/JfbBaseClear/JfbBaseClearLess.less +18 -19
  64. package/src/components/JfbBaseClear/JfbBaseClearMixin.js +12 -0
  65. package/src/components/JfbBaseConDialog/Api.js +1 -1
  66. package/src/components/JfbBaseConDialog/Attr.js +30 -20
  67. package/src/components/JfbBaseConDialog/JfbBaseConDialog.vue +45 -26
  68. package/src/components/JfbBaseConDialog/JfbBaseConDialogLess.less +18 -19
  69. package/src/components/JfbBaseConDialog/Mock.js +20 -1
  70. package/src/components/JfbBaseConDialog/XdCouCardBind.vue +15 -9
  71. package/src/components/JfbBaseConList/Attr.js +149 -224
  72. package/src/components/JfbBaseConList/JfbBaseConList.vue +150 -133
  73. package/src/components/JfbBaseConList/JfbBaseConListLess.less +18 -19
  74. package/src/components/JfbBaseConPhone/JfbBaseConPhoneLess.less +18 -19
  75. package/src/components/JfbBaseEntry/Attr.js +33 -21
  76. package/src/components/JfbBaseEntry/JfbBaseEntry.vue +34 -23
  77. package/src/components/JfbBaseEntry/JfbBaseEntryLess.less +18 -19
  78. package/src/components/JfbBaseExpressDetail/JfbBaseExpressDetailLess.less +18 -19
  79. package/src/components/JfbBaseFastLink/Api.js +1 -54
  80. package/src/components/JfbBaseFastLink/Attr.js +168 -116
  81. package/src/components/JfbBaseFastLink/JfbBaseFastLink.vue +12 -16
  82. package/src/components/JfbBaseFastLink/JfbBaseFastLinkLess.less +18 -19
  83. package/src/components/JfbBaseFooter/Attr.js +28 -22
  84. package/src/components/JfbBaseFooter/JfbBaseFooter.vue +19 -15
  85. package/src/components/JfbBaseFooter/JfbBaseFooterLess.less +18 -19
  86. package/src/components/JfbBaseHeader/Attr.js +89 -91
  87. package/src/components/JfbBaseHeader/JfbBaseHeader.vue +28 -29
  88. package/src/components/JfbBaseHeader/JfbBaseHeaderLess.less +18 -19
  89. package/src/components/JfbBaseLogin/Attr.js +111 -88
  90. package/src/components/JfbBaseLogin/JfbBaseLogin.vue +0 -1
  91. package/src/components/JfbBaseLogin/JfbBaseLoginLess.less +18 -19
  92. package/src/components/JfbBaseLoginForgetPwd/Attr.js +52 -45
  93. package/src/components/JfbBaseLoginForgetPwd/JfbBaseLoginForgetPwd.vue +14 -14
  94. package/src/components/JfbBaseLoginForgetPwd/JfbBaseLoginForgetPwdLess.less +18 -19
  95. package/src/components/JfbBaseLoginSetPwd/Attr.js +6 -4
  96. package/src/components/JfbBaseLoginSetPwd/JfbBaseLoginSetPwdLess.less +18 -19
  97. package/src/components/JfbBaseMapOverlay/JfbBaseMapOverlayLess.less +18 -19
  98. package/src/components/JfbBaseMapSearch/Attr.js +0 -15
  99. package/src/components/JfbBaseMapSearch/JfbBaseMapSearch.vue +1 -25
  100. package/src/components/JfbBaseMapSearch/JfbBaseMapSearchLess.less +18 -19
  101. package/src/components/JfbBaseMergeUserCard/Attr.js +4 -3
  102. package/src/components/JfbBaseMergeUserCard/JfbBaseMergeUserCardLess.less +18 -19
  103. package/src/components/JfbBaseMultipleExpress/Attr.js +4 -3
  104. package/src/components/JfbBaseMultipleExpress/JfbBaseMultipleExpressLess.less +18 -19
  105. package/src/components/JfbBaseMy/JfbBaseMyLess.less +18 -19
  106. package/src/components/JfbBaseMySetting/Attr.js +1 -1
  107. package/src/components/JfbBaseMySetting/JfbBaseMySettingLess.less +18 -19
  108. package/src/components/JfbBaseNotice/Attr.js +97 -56
  109. package/src/components/JfbBaseNotice/JfbBaseNotice.vue +70 -52
  110. package/src/components/JfbBaseNotice/JfbBaseNoticeLess.less +18 -19
  111. package/src/components/JfbBaseNoticeBottom/JfbBaseNoticeBottomLess.less +18 -19
  112. package/src/components/JfbBaseNoticeTop/JfbBaseNoticeTopLess.less +18 -19
  113. package/src/components/JfbBaseOrderDetail/Attr.js +210 -193
  114. package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +6 -3
  115. package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetailLess.less +18 -19
  116. package/src/components/JfbBaseOrderList/Attr.js +55 -43
  117. package/src/components/JfbBaseOrderList/JfbBaseOrderList.vue +5 -3
  118. package/src/components/JfbBaseOrderList/JfbBaseOrderListLess.less +18 -19
  119. package/src/components/JfbBasePay/Attr.js +2 -13
  120. package/src/components/JfbBasePay/JfbBasePay.vue +7 -6
  121. package/src/components/JfbBasePay/JfbBasePayLess.less +18 -19
  122. package/src/components/JfbBasePay/Mock.js +2 -1
  123. package/src/components/JfbBasePhoneCollect/Attr.js +27 -2
  124. package/src/components/JfbBasePhoneCollect/JfbBasePhoneCollect.vue +1 -1
  125. package/src/components/JfbBasePhoneCollect/JfbBasePhoneCollectLess.less +18 -19
  126. package/src/components/JfbBasePhoneLogin/Attr.js +27 -2
  127. package/src/components/JfbBasePhoneLogin/JfbBasePhoneLoginLess.less +18 -19
  128. package/src/components/JfbBasePoster/Attr.js +103 -83
  129. package/src/components/JfbBasePoster/JfbBasePoster.vue +134 -141
  130. package/src/components/JfbBasePoster/JfbBasePosterLess.less +18 -19
  131. package/src/components/JfbBasePosterBigSmall/Attr.js +93 -76
  132. package/src/components/JfbBasePosterBigSmall/JfbBasePosterBigSmall.vue +3 -7
  133. package/src/components/JfbBasePosterBigSmall/JfbBasePosterBigSmallLess.less +18 -19
  134. package/src/components/JfbBasePosterBigSmall/getWidthHeight.js +2 -2
  135. package/src/components/JfbBasePosterEntry/Attr.js +44 -33
  136. package/src/components/JfbBasePosterEntry/JfbBasePosterEntry.vue +44 -49
  137. package/src/components/JfbBasePosterEntry/JfbBasePosterEntryLess.less +18 -19
  138. package/src/components/JfbBasePosterType/Attr.js +82 -48
  139. package/src/components/JfbBasePosterType/FourScreen.vue +8 -2
  140. package/src/components/JfbBasePosterType/JfbBasePosterType.vue +36 -59
  141. package/src/components/JfbBasePosterType/JfbBasePosterTypeLess.less +18 -19
  142. package/src/components/JfbBaseRecharge/Attr.js +35 -23
  143. package/src/components/JfbBaseRecharge/JfbBaseRecharge.vue +54 -8
  144. package/src/components/JfbBaseRecharge/JfbBaseRechargeLess.less +18 -19
  145. package/src/components/JfbBaseRechargeOrder/Attr.js +32 -22
  146. package/src/components/JfbBaseRechargeOrder/JfbBaseRechargeOrder.vue +12 -7
  147. package/src/components/JfbBaseRechargeOrder/JfbBaseRechargeOrderLess.less +18 -19
  148. package/src/components/JfbBaseRechargeOrderDetail/JfbBaseRechargeOrderDetailLess.less +18 -19
  149. package/src/components/JfbBaseRechargeSuccess/Attr.js +10 -8
  150. package/src/components/JfbBaseRechargeSuccess/JfbBaseRechargeSuccessLess.less +18 -19
  151. package/src/components/JfbBaseSearch/Attr.js +6 -148
  152. package/src/components/JfbBaseSearch/JfbBaseSearch.vue +8 -37
  153. package/src/components/JfbBaseSearch/JfbBaseSearchLess.less +18 -19
  154. package/src/components/JfbBaseSetPwd/Attr.js +6 -147
  155. package/src/components/JfbBaseSetPwd/JfbBaseSetPwdLess.less +18 -19
  156. package/src/components/JfbBaseSuccess/Attr.js +78 -17
  157. package/src/components/JfbBaseSuccess/JfbBaseSuccessLess.less +18 -19
  158. package/src/components/JfbBaseTestApi/JfbBaseTestApiLess.less +18 -19
  159. package/src/components/JfbBaseTestBody/JfbBaseTestBodyLess.less +18 -19
  160. package/src/components/JfbBaseTestBottom/JfbBaseTestBottomLess.less +18 -19
  161. package/src/components/JfbBaseTestNotice/JfbBaseTestNoticeLess.less +18 -19
  162. package/src/components/JfbBaseTestTop/JfbBaseTestTopLess.less +18 -19
  163. package/src/components/JfbBaseUserCenter/Attr.js +72 -53
  164. package/src/components/JfbBaseUserCenter/JfbBaseUserCenter.vue +40 -27
  165. package/src/components/JfbBaseUserCenter/JfbBaseUserCenterLess.less +18 -19
  166. package/src/components/JfbBaseUserInfo/Attr.js +54 -45
  167. package/src/components/JfbBaseUserInfo/JfbBaseUserInfo.vue +21 -21
  168. package/src/components/JfbBaseUserInfo/JfbBaseUserInfoLess.less +18 -19
  169. package/src/components/JfbBaseUserOrder/Attr.js +118 -92
  170. package/src/components/JfbBaseUserOrder/JfbBaseUserOrder.vue +21 -7
  171. package/src/components/JfbBaseUserOrder/JfbBaseUserOrderLess.less +18 -19
  172. package/src/components/JfbBaseVideo/Attr.js +72 -19
  173. package/src/components/JfbBaseVideo/JfbBaseVideo.vue +69 -28
  174. package/src/components/JfbBaseVideo/JfbBaseVideoLess.less +18 -19
  175. package/src/components/JfbBaseVideo/XdVideo.vue +6 -44
  176. package/src/components/JfbBaseWallet/JfbBaseWalletLess.less +18 -19
  177. package/src/components/JfbBaseWalletDetail/JfbBaseWalletDetailLess.less +18 -19
  178. package/src/components/JfbBaseWalletDetail/JfbBaseWalletDetailMixin.js +0 -12
  179. package/src/components/JfbBaseWalletEffective/JfbBaseWalletEffectiveLess.less +18 -19
  180. package/src/components/JfbBaseWalletIndex/JfbBaseWalletIndexLess.less +18 -19
  181. package/src/components/JfbBaseWalletItem/JfbBaseWalletItemLess.less +18 -19
  182. package/src/components/JfbBaseWebview/JfbBaseWebviewLess.less +18 -19
  183. package/src/components/JfbBaseWxAuthorize/Attr.js +31 -3
  184. package/src/components/JfbBaseWxAuthorize/JfbBaseWxAuthorize.vue +32 -26
  185. package/src/components/JfbBaseWxAuthorize/JfbBaseWxAuthorizeLess.less +18 -19
  186. package/src/components/JfbBaseWxAuthorizeError/Attr.js +21 -17
  187. package/src/components/JfbBaseWxAuthorizeError/JfbBaseWxAuthorizeErrorLess.less +18 -19
  188. package/src/components/JfbBaseLine/Attr.js +0 -59
  189. package/src/components/JfbBaseLine/JfbBaseLine.vue +0 -105
  190. package/src/components/JfbBaseLine/JfbBaseLineLess.less +0 -80
  191. package/src/components/JfbBaseLine/JfbBaseLineMixin.js +0 -30
  192. package/src/components/JfbBasePosterType/Screen.vue +0 -284
  193. package/src/components/JfbBaseSearch/Api.js +0 -60
  194. package/src/components/JfbBaseSearch/Mock.js +0 -5
@@ -21,14 +21,14 @@
21
21
  <view :style="{borderRadius: bodyRadius + 'rpx', backgroundColor:bodyBackgroundColor, padding:outPadding}">
22
22
  <view class="my-order__add">
23
23
  <view :style="{color:cardNameColor}">我的订单</view>
24
- <view @click="handleToLink(afterUrl)" :style="{borderColor:mainColor,color: mainColor}">售后订单</view>
24
+ <view @click="handleToLink(afterUrl)" :style="{borderColor:subColor || mainColor,color: subColor || mainColor}">售后订单</view>
25
25
  </view>
26
26
  <view
27
27
  class="my-order__content"
28
28
  :style="{
29
29
  borderRadius: radius + 'rpx',
30
30
  background: backgroundColor,
31
- marginTop: margin.top ? margin.top + 'rpx': '20rpx',
31
+ marginTop: spacing + 'rpx',
32
32
  border: borderBox,
33
33
  }"
34
34
  >
@@ -75,10 +75,18 @@
75
75
  mixins: [componentsMixins,extsMixins,JfbBaseUserOrderMixin],
76
76
  computed: {
77
77
  outPadding() {
78
- return `${this.bodyPadding.top || 20}rpx ${this.bodyPadding.right || 20}rpx ${this.bodyPadding.bottom || 20}rpx ${this.bodyPadding.left || 20}rpx`
78
+ let str = `${this.checkValue(this.bodyPadding.top, 0)}rpx`;
79
+ str = `${str} ${this.checkValue(this.bodyPadding.right, 0)}rpx`;
80
+ str = `${str} ${this.checkValue(this.bodyPadding.bottom, 0)}rpx`;
81
+ str = `${str} ${this.checkValue(this.bodyPadding.left, 0)}rpx`;
82
+ return str
79
83
  },
80
84
  outMargin() {
81
- return `${this.bodyMargin.top || 0}rpx ${this.bodyMargin.right || 0}rpx ${this.bodyMargin.bottom || 0}rpx ${this.bodyMargin.left || 0}rpx`
85
+ let str = `${this.checkValue(this.bodyMargin.top, 20)}rpx`;
86
+ str = `${str} ${this.checkValue(this.bodyMargin.right, 20)}rpx`;
87
+ str = `${str} ${this.checkValue(this.bodyMargin.bottom, 20)}rpx`;
88
+ str = `${str} ${this.checkValue(this.bodyMargin.left, 20)}rpx`;
89
+ return str
82
90
  },
83
91
  borderBox() {
84
92
  if (this.is_border === 'Y') return `${this.is_border_w}rpx solid ${this.is_border_c}`;
@@ -95,6 +103,7 @@
95
103
  backgroundColor: 'rgba(0,0,0,0)',
96
104
  radius: 0,
97
105
  iconColor: '',
106
+ spacing:20,
98
107
 
99
108
  //边框
100
109
  is_border: 'Y',
@@ -111,11 +120,15 @@
111
120
  bodyBackgroundColor: 'rgba(0,0,0,0)',
112
121
  bodyMargin: {top: 0, left: 0, right: 0, bottom: 0},
113
122
  cardNameColor: '#333',
123
+ subColor:'',
114
124
  }
115
125
  },
116
126
  watch: {
117
127
  container(value) {
118
- this.init(value)
128
+ this.init(value);
129
+ if(this.$configProject.isPreview) {
130
+ this.onJfbLoad( this.options)
131
+ }
119
132
  }
120
133
  },
121
134
  created() {
@@ -124,7 +137,6 @@
124
137
  methods: {
125
138
  onJfbLoad(options) {
126
139
  this.options = options;
127
-
128
140
  //处理方法
129
141
  const handle = (res)=>{
130
142
  this.list = this.list.map(item => {
@@ -146,7 +158,7 @@
146
158
  'com': [0, 4, 9, 99, 888][this.$xdUniHelper.random(0, 4)],
147
159
  };
148
160
  handle(res)
149
- }, 1000)
161
+ }, 400)
150
162
  }
151
163
  else{
152
164
  jfbRootExec('getBaseOrderListCount', {
@@ -172,6 +184,8 @@
172
184
  this.bodyBackgroundColor = getContainerPropsValue(container, 'content.bodyBackgroundColor', 'rgba(0,0,0,0)');
173
185
  this.bodyPadding = getContainerPropsValue(container, 'content.bodyPadding', {top: 20, left: 20, right: 20, bottom: 20});
174
186
  this.cardNameColor = getContainerPropsValue(container, 'content.cardNameColor', '#333');
187
+ this.subColor = getContainerPropsValue(container, 'content.cardNameColor', '');
188
+ this.spacing = getContainerPropsValue(container, 'content.spacing', 20);
175
189
 
176
190
  //其他
177
191
  this.afterUrl = getContainerPropsValue(container, 'content.after_url', {value: ''}).value;
@@ -13,9 +13,8 @@
13
13
 
14
14
  //start
15
15
  .jfb-base-user-order {
16
- border: 1px dashed rgba(0, 0, 0, 0);
17
16
  box-sizing: border-box;
18
- min-height: unit(50, rpx);
17
+ min-height: unit(100, rpx);
19
18
 
20
19
  &__body{
21
20
  position: relative;
@@ -23,21 +22,21 @@
23
22
  z-index: 2
24
23
  }
25
24
 
26
- &.editx {
25
+ &.editx,&:hover {
27
26
  position: relative;
28
- border: 1px dashed blue;
29
- box-sizing: border-box;
30
- z-index: 3
31
-
32
- }
33
-
34
- &:hover {
35
- border: 1px dashed blue;
36
- }
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
+ }
37
39
 
38
- &.noBorder {
39
- border-color: rgba(0,0,0,0);
40
- border-width: 0;
41
40
  }
42
41
 
43
42
 
@@ -72,9 +71,9 @@
72
71
 
73
72
  /**notPreview**/
74
73
  .jfb-base-user-order {
75
- &:before {
76
- content: " ";
77
- display: table;
78
- }
74
+ //&:before {
75
+ //content: " ";
76
+ //display: table;
77
+ //}
79
78
  }
80
79
  /**endNotPreview**/
@@ -8,16 +8,28 @@ import console from "@dcloudio/uni-h5/src/core/helpers/console";
8
8
  export default {
9
9
  style:[],
10
10
  content:(params)=>{
11
+ let size = {width:750};
12
+ let video = {
13
+ size: Object.assign({},(params.video && params.video.size),size),
14
+ type:'1',
15
+ position: Object.assign({},params.video && params.video.position)
16
+ };
11
17
  return [
12
18
  {
13
- label: '视频位置配置:', //label
14
- ele: 'xd-site-poster', //package 名称
15
- valueKey: 'video', //form[valueKey]
19
+ label: '视频位置配置:',
20
+ ele: 'xd-site-poster',
21
+ valueKey: 'video',
22
+ groupKey:'content',
16
23
  className: 'input80',
17
- value: params.video || {},
24
+ value:video,
18
25
  setting: {
19
26
  count: 1,
20
- scene: {label: '视频', value: 'video'}
27
+ scene: {label: '视频', value: 'video'},
28
+ sizeDisabled: {
29
+ wDisabled:true,
30
+ hDisabled: false,
31
+ },
32
+ typeDisabled: true
21
33
  },
22
34
  handleCustom({action, data}) {
23
35
  //设置场景参数
@@ -212,32 +224,46 @@ export default {
212
224
  loading.close()
213
225
  }
214
226
  },
215
- inline: false,
216
- notice: '',
217
227
  rules: [
218
- {required: true, message: '请选择视频位置', trigger: 'change'},
228
+ {
229
+ required: true,
230
+ validator: (rule, value, callback) => {
231
+ let message = '请设置视频位置相关内容';
232
+ if(!value) {
233
+ callback(message);
234
+ return;
235
+ }
236
+ if(value.size && !value.size.height){
237
+ callback(message);
238
+ return
239
+ }
240
+ // if(value.position && (!value.position['position_name'] || !value.position['position_id'])) {
241
+ // callback(message);
242
+ // return
243
+ // }
244
+ callback()
245
+ },trigger: ['blur', 'change']
246
+ }
219
247
  ],
220
248
  },
221
249
  {
222
- label: '视频位边距设置:',
223
- ele: 'xd-margin-padding',
224
- valueKey: 'margin',
225
- value: params.margin || null,
226
- disabled: false,
227
- setting: {
228
- type: 'margin',
229
- },
230
- placeholder: '请设置视频位边距设置',
231
-
250
+ label: '背景颜色:',
251
+ ele: 'xd-color',
252
+ valueKey: 'bgColor',
253
+ groupKey:'style',
254
+ value: params.bgColor || '',
255
+ placeholder: '请选择背景颜色',
256
+ classNmae: 'input80',
232
257
  },
233
258
  {
234
259
  label: '内容圆角设置:',
235
260
  ele: 'xd-site-select-list',
236
261
  valueKey: 'radius',
262
+ groupKey:'style',
237
263
  value: params['radius'] || '0',
238
264
  placeholder: '请选择内容圆角设置',
239
265
  multiple: false,
240
- className: 'input80',
266
+ className: 'input60',
241
267
  handleCustom({action, data}) {
242
268
  XdBus.getParentApi('getOptionsSettingList')({
243
269
  setting_id: 'edtix_style_radius',
@@ -251,6 +277,33 @@ export default {
251
277
  });
252
278
  },
253
279
  },
280
+ {
281
+ label: '视频位边距设置:',
282
+ ele: 'xd-margin-padding',
283
+ valueKey: 'margin',
284
+ groupKey:'style',
285
+ value: params.margin || null,
286
+ setting: {
287
+ type: 'margin',
288
+ },
289
+ placeholder: '请设置视频位边距设置',
290
+ inline: false,
291
+ notice: '设置内边距,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">0</span>像素',
292
+ },
293
+ {
294
+ label: '视频位填充设置:',
295
+ ele: 'xd-margin-padding',
296
+ valueKey: 'padding',
297
+ groupKey:'style',
298
+ value: params.padding || null,
299
+ setting: {
300
+ type: 'padding',
301
+ },
302
+ placeholder: '请设置视频位填充设置',
303
+ inline: false,
304
+ notice: '设置填充设置,<span style="color: red">单位:像素</span>。默认值:<span style="color: red">0</span>像素',
305
+ },
306
+
254
307
  ].filter(i=>i)
255
308
  },
256
309
  advanced: [
@@ -14,16 +14,29 @@
14
14
  </view>
15
15
  <!-- #endif -->
16
16
  <view class="jfb-base-video__body">
17
- <view class="float"></view>
18
- <view class="video" v-if="video !== null">
17
+ <view class="x-line"></view>
18
+ <view
19
+ class="x-video"
20
+ :style="{
21
+ backgroundColor:bgColor,
22
+ margin:outMargin,
23
+ borderRadius:radius + 'rpx',
24
+ padding:outPadding,
25
+ width: contentWidth + 'rpx',
26
+ height:contentHeight + 'rpx'
27
+ }"
28
+ >
29
+
19
30
  <xd-video
31
+ v-if="video !== null && video !== ''"
20
32
  :key="videoKey"
21
- :margin="margin"
22
33
  :poster="videoSetting"
23
34
  :video="video"
24
- :radius="radius"
25
35
  :pack-this="$vm"
26
36
  ></xd-video>
37
+ <view class="not-video" v-if="video === ''">
38
+ <image :src="getVideoSrc"></image>
39
+ </view>
27
40
  </view>
28
41
  </view>
29
42
  </view>
@@ -55,6 +68,10 @@
55
68
  video: null,
56
69
  videoSetting: null,
57
70
  margin:{},
71
+ padding:{},
72
+ height:0,
73
+ width:750,
74
+ bgColor:'',
58
75
  radius:0,
59
76
  $vm: {},
60
77
  videoKey : Date.now()
@@ -67,39 +84,51 @@
67
84
  if(this.autoplay === 'R') return 'iconplayreplay';
68
85
  },
69
86
  contentWidth(){
87
+ let margin = Number(this.checkValue(this.margin.left, 0)) + Number(this.checkValue(this.margin.right, 0));
88
+ let padding = Number(this.checkValue(this.padding.left, 0)) + Number(this.checkValue(this.padding.right, 0));
70
89
  let border = 0;
71
- if(this.isPreview) border = 2;
72
- return 750 - (this.margin.left + this.margin.right + border);
90
+ //if(this.isPreview) border = 2;
91
+ return this.width - (padding + margin + border);
73
92
  },
74
93
  contentHeight(){
94
+ let margin = Number(this.checkValue(this.margin.left, 0)) + Number(this.checkValue(this.margin.right, 0));
95
+ let padding = Number(this.checkValue(this.padding.left, 0)) + Number(this.checkValue(this.padding.right, 0));
75
96
  let border = 0;
76
- if(this.isPreview) border = 2;
77
- let winWidth = 750 - ((this.margin.left||0) + (this.margin.right||0) + border);
97
+ //if(this.isPreview) border = 2;
98
+ let winWidth = this.width - (padding + margin + border);
78
99
  return winWidth * this.height/this.width;
79
100
  },
80
-
81
101
  outMargin(){
82
- let margin = `${this.margin.top !== null ? this.margin.top : 0}rpx`;
83
- margin = `${margin} ${this.margin.right !== null ? this.margin.right : 0}rpx`;
84
- margin = `${margin} ${this.margin.bottom !== null ? this.margin.bottom :0}rpx`;
85
- margin = `${margin} ${this.margin.left !== null ? this.margin.left : 0}rpx`;
86
- return margin;
102
+ let str = `${this.checkValue(this.margin.top, 0)}rpx`;
103
+ str = `${str} ${this.checkValue(this.margin.right, 0)}rpx`;
104
+ str = `${str} ${this.checkValue(this.margin.bottom, 0)}rpx`;
105
+ str = `${str} ${this.checkValue(this.margin.left, 0)}rpx`;
106
+ return str
107
+ },
108
+ outPadding(){
109
+ let str = `${this.checkValue(this.padding.top, 0)}rpx`;
110
+ str = `${str} ${this.checkValue(this.padding.right, 0)}rpx`;
111
+ str = `${str} ${this.checkValue(this.padding.bottom, 0)}rpx`;
112
+ str = `${str} ${this.checkValue(this.padding.left, 0)}rpx`;
113
+ return str
114
+ },
115
+ getVideoSrc(){
116
+ let width = Math.floor(this.contentWidth * this.$rpxNum);
117
+ let height = Math.floor(this.contentHeight * this.$rpxNum);
118
+ return `//dummyimage.com/${width}x${height}`;
87
119
  }
88
120
  },
89
121
  watch: {
90
- container(value) {
122
+ container(value, oloValue) {
123
+ if(JSON.stringify(value) === JSON.stringify(oloValue)) return;
91
124
  this.init(value);
92
- if(this.timer) clearTimeout(this.timer);
93
- this.timer = setTimeout(()=>{
94
- if (this.$configProject['isPreview']) this.onJfbLoad(this.options)
95
- }, 400)
125
+ if (this.$configProject['isPreview']) this.onJfbLoad(this.options)
96
126
  }
97
127
  },
98
128
  created() {
99
129
  this.$vm = this;
100
130
  this.isPreview = this.$configProject.isPreview;
101
131
  this.init(this.container);
102
-
103
132
  },
104
133
  methods: {
105
134
 
@@ -109,8 +138,14 @@
109
138
  */
110
139
  init(container) {
111
140
  this.videoSetting = getContainerPropsValue(container, 'content.video', {size:{width: 400, height: 300}, type: '1'});
112
- this.margin = getContainerPropsValue(container, 'content.margin', {top:0, bottom:0, right:0, left: 0});
141
+ if(this.videoSetting && this.videoSetting.size && this.videoSetting.size.height) {
142
+ this.height = Number(this.videoSetting.size.height) || 563;
143
+ this.width = 750;
144
+ }
145
+ this.margin = getContainerPropsValue(container, 'content.margin', {});
146
+ this.padding = getContainerPropsValue(container, 'content.padding', {});
113
147
  this.radius = getContainerPropsValue(container, 'content.radius', 0);
148
+ this.bgColor = getContainerPropsValue(container, 'content.bgColor', 'rgba(0,0,0,0)');
114
149
  },
115
150
 
116
151
  onJfbLoad(options) {
@@ -127,6 +162,7 @@
127
162
  if(res && res.list && res.list.length > 0) {
128
163
  this.video = res.list[0];
129
164
  }
165
+ else this.video = '';
130
166
  this.videoKey = Date.now()
131
167
  })
132
168
  .catch(error => {
@@ -148,15 +184,20 @@
148
184
 
149
185
  .jfb-base-video {
150
186
  &__body{
187
+ .x-video {
188
+ overflow: hidden;
189
+ }
151
190
 
152
- }
153
-
154
- }
191
+ .not-video {
192
+ width: 100%;
193
+ height: 100%;
155
194
 
156
- .float {
157
- height: 1px;
158
- width: 100%;
159
- overflow: hidden;
195
+ & > image {
196
+ width: 100%;
197
+ height: 100%;
198
+ }
199
+ }
200
+ }
160
201
  }
161
202
 
162
203
  </style>
@@ -13,9 +13,8 @@
13
13
 
14
14
  //start
15
15
  .jfb-base-video {
16
- border: 1px dashed rgba(0, 0, 0, 0);
17
16
  box-sizing: border-box;
18
- min-height: unit(50, rpx);
17
+ min-height: unit(100, rpx);
19
18
 
20
19
  &__body{
21
20
  position: relative;
@@ -23,21 +22,21 @@
23
22
  z-index: 2
24
23
  }
25
24
 
26
- &.editx {
25
+ &.editx,&:hover {
27
26
  position: relative;
28
- border: 1px dashed blue;
29
- box-sizing: border-box;
30
- z-index: 3
31
-
32
- }
33
-
34
- &:hover {
35
- border: 1px dashed blue;
36
- }
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
+ }
37
39
 
38
- &.noBorder {
39
- border-color: rgba(0,0,0,0);
40
- border-width: 0;
41
40
  }
42
41
 
43
42
 
@@ -72,9 +71,9 @@
72
71
 
73
72
  /**notPreview**/
74
73
  .jfb-base-video {
75
- &:before {
76
- content: " ";
77
- display: table;
78
- }
74
+ //&:before {
75
+ //content: " ";
76
+ //display: table;
77
+ //}
79
78
  }
80
79
  /**endNotPreview**/
@@ -1,18 +1,6 @@
1
1
  <template>
2
- <view
3
- class="video-box"
4
- :style="{
5
- width: contentWidth + 'rpx',
6
- height:contentHeight + 'rpx',
7
- margin: outMargin
8
- }"
9
- >
10
- <view
11
- class="thumb"
12
- :class="{noImageUrl: !imageUrl}"
13
- v-if="!playStatus"
14
- :style="{borderRadius: radius + 'rpx'}"
15
- >
2
+ <view class="video-box">
3
+ <view class="thumb" :class="{noImageUrl: !imageUrl}" v-if="!playStatus">
16
4
  <image :src="imageUrl" v-if="imageUrl" />
17
5
  <view v-if="videoUrl" @click="handlePlay()">
18
6
  <xd-font-icon
@@ -20,7 +8,6 @@
20
8
  size="100"
21
9
  color="#fff"
22
10
  ></xd-font-icon>
23
-
24
11
  </view>
25
12
  </view>
26
13
  <view
@@ -52,12 +39,7 @@
52
39
  margin:{
53
40
  type: Object,
54
41
  default(){
55
- return {
56
- top:0,
57
- left:0,
58
- right:0,
59
- bottom:0
60
- }
42
+ return {}
61
43
  }
62
44
  },
63
45
  poster:{
@@ -81,10 +63,6 @@
81
63
  return {
82
64
  isPreview: false,
83
65
 
84
- //css
85
- width: 0,
86
- height: 0,
87
-
88
66
  //play
89
67
  imageUrl: '',
90
68
  videoUrl: '',
@@ -98,25 +76,6 @@
98
76
  if(this.autoplay === 'E') return 'iconshibai';
99
77
  if(this.autoplay === 'R') return 'iconplayreplay';
100
78
  },
101
- contentWidth(){
102
- let border = 0;
103
- if(this.isPreview) border = 2;
104
- return 750 - (this.margin.left + this.margin.right + border);
105
- },
106
- contentHeight(){
107
- let border = 0;
108
- if(this.isPreview) border = 2;
109
- let winWidth = 750 - ((this.margin.left||0) + (this.margin.right||0) + border);
110
- return winWidth * this.height/this.width;
111
- },
112
-
113
- outMargin(){
114
- let margin = `${this.margin.top !== null ? this.margin.top : 0}rpx`;
115
- margin = `${margin} ${this.margin.right !== null ? this.margin.right : 0}rpx`;
116
- margin = `${margin} ${this.margin.bottom !== null ? this.margin.bottom :0}rpx`;
117
- margin = `${margin} ${this.margin.left !== null ? this.margin.left : 0}rpx`;
118
- return margin;
119
- }
120
79
  },
121
80
  watch:{
122
81
  poster(){
@@ -173,6 +132,9 @@
173
132
 
174
133
  <style scoped lang="less">
175
134
  .video-box {
135
+ width: 100%;
136
+ height: 100%;
137
+ box-sizing: border-box;
176
138
  view.noImageUrl {
177
139
  background: rgba(0,0,0,.6);
178
140
  }
@@ -13,9 +13,8 @@
13
13
 
14
14
  //start
15
15
  .jfb-base-wallet {
16
- border: 1px dashed rgba(0, 0, 0, 0);
17
16
  box-sizing: border-box;
18
- min-height: unit(50, rpx);
17
+ min-height: unit(100, rpx);
19
18
 
20
19
  &__body{
21
20
  position: relative;
@@ -23,21 +22,21 @@
23
22
  z-index: 2
24
23
  }
25
24
 
26
- &.editx {
25
+ &.editx,&:hover {
27
26
  position: relative;
28
- border: 1px dashed blue;
29
- box-sizing: border-box;
30
- z-index: 3
31
-
32
- }
33
-
34
- &:hover {
35
- border: 1px dashed blue;
36
- }
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
+ }
37
39
 
38
- &.noBorder {
39
- border-color: rgba(0,0,0,0);
40
- border-width: 0;
41
40
  }
42
41
 
43
42
 
@@ -72,9 +71,9 @@
72
71
 
73
72
  /**notPreview**/
74
73
  .jfb-base-wallet {
75
- &:before {
76
- content: " ";
77
- display: table;
78
- }
74
+ //&:before {
75
+ //content: " ";
76
+ //display: table;
77
+ //}
79
78
  }
80
79
  /**endNotPreview**/