@qywh/package 0.0.3-beta01 → 0.0.3-beta05

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 (71) hide show
  1. package/common/actions/index.ts +2 -5
  2. package/common/actions/jumpXcxToQuestion.ts +57 -0
  3. package/common/actions/link.ts +0 -310
  4. package/common/compnents/dialog/index.vue +1 -1
  5. package/common/index.ts +1 -5
  6. package/lib/cdnUrl.ts +1 -8
  7. package/lib/httpdns-request.ts +3 -62
  8. package/lib/methods/actions-fn.ts +69 -519
  9. package/lib/methods/jump.ts +3 -21
  10. package/lib/request.ts +1 -6
  11. package/lib/utils/domain-config.ts +2 -132
  12. package/lib/utils/format-img.ts +3 -17
  13. package/lib/utils/index.ts +1 -4
  14. package/lib/utils/logParamHandle.ts +138 -0
  15. package/package.json +1 -1
  16. package/packages/qy-anchor/components/index.vue +4 -4
  17. package/packages/qy-atmosphere-countdown/settings/index.ts +2 -3
  18. package/packages/qy-atmosphere-countdownv2/settings/index.ts +2 -2
  19. package/packages/qy-button/components/index.vue +2 -2
  20. package/packages/qy-button/components/static/default-btn.png +0 -0
  21. package/packages/qy-button/settings/applet/v1.ts +2 -3
  22. package/packages/qy-button/settings/applet/v2.ts +2 -3
  23. package/packages/qy-container/components/index.vue +4 -4
  24. package/packages/qy-countdown/settings/index.ts +2 -3
  25. package/packages/qy-dialog/components/index.vue +30 -30
  26. package/packages/qy-hotarea/components/index.vue +2 -2
  27. package/packages/qy-limit-countdown/components/index.vue +1 -1
  28. package/packages/qy-limit-countdown/settings/index.ts +2 -3
  29. package/packages/qy-out-form-input/components/index.vue +1 -1
  30. package/packages/qy-out-form-select/components/index.vue +1 -1
  31. package/packages/qy-out-form-submit-button/components/index.vue +18 -18
  32. package/packages/qy-out-form-submit-button/components/static/default-btn.png +0 -0
  33. package/packages/qy-out-success-wechat-diversion/components/index.vue +120 -745
  34. package/packages/qy-out-success-wechat-diversion/menu.ts +1 -1
  35. package/packages/qy-out-success-wechat-diversion/settings/index.ts +5 -424
  36. package/packages/qy-out-wx-auth-button/components/index.vue +4 -4
  37. package/packages/qy-out-wx-auth-button/components/static/default-btn.png +0 -0
  38. package/packages/qy-out-wx-auth-button/settings/applet/v1.ts +2 -2
  39. package/packages/qy-out-wx-auth-button/settings/index.ts +2 -2
  40. package/packages/qy-page/components/index.vue +1 -1
  41. package/packages/qy-page/components/out-weixin-share.ts +49 -81
  42. package/packages/qy-picture/components/index.vue +1 -1
  43. package/packages/qy-picture/components/static/single_pic-2.png +0 -0
  44. package/packages/qy-picture/settings/applet/v1.ts +2 -2
  45. package/packages/qy-picture/settings/index.ts +2 -2
  46. package/packages/qy-rect/components/index.vue +2 -2
  47. package/typings/enum/saleChannelConfig.ts +1 -1
  48. package/typings/index.d.ts +0 -1
  49. package/common/actions/jumpXcx.ts +0 -20
  50. package/common/domain.ts +0 -12
  51. package/common/service.ts +0 -65
  52. package/lib/baseUrl.ts +0 -12
  53. package/lib/checkRepeat.ts +0 -28
  54. package/lib/utils/environment.ts +0 -39
  55. package/lib/utils/order-recall.ts +0 -26
  56. package/lib/utils/weixin.ts +0 -160
  57. package/lib/utils/wxGroupManage.ts +0 -211
  58. package/lib/zyb-yike-utils/feWechatMultiterminal.ts +0 -103
  59. package/lib/zyb-yike-utils/logParamHandle.ts +0 -298
  60. package/packages/qy-seckill/actions/index.ts +0 -1
  61. package/packages/qy-seckill/components/index.vue +0 -263
  62. package/packages/qy-seckill/index.ts +0 -18
  63. package/packages/qy-seckill/menu.ts +0 -6
  64. package/packages/qy-seckill/settings/index.ts +0 -101
  65. package/packages/qy-seckill/static/clock.png +0 -0
  66. package/typings/enum/coupon.ts +0 -5
  67. /package/lib/{zyb-yike-utils → utils}/cookieExt.ts +0 -0
  68. /package/lib/{zyb-yike-utils → utils}/guid.ts +0 -0
  69. /package/lib/{zyb-yike-utils → utils}/sparkMD5.js +0 -0
  70. /package/lib/{zyb-yike-utils → utils}/urlExt.ts +0 -0
  71. /package/lib/{zyb-yike-utils → utils}/utils.ts +0 -0
@@ -1,11 +1,11 @@
1
1
  <template>
2
- <!-- <transition name="zyb-dialog-fade">
2
+ <!-- <transition name="qy-dialog-fade">
3
3
  <section
4
4
  :class="dialogWrapperCls"
5
5
  v-show="visible"
6
6
  > -->
7
7
  <transition
8
- :name="`zyb-dialog-slide__${position}`"
8
+ :name="`qy-dialog-slide__${position}`"
9
9
  @before-enter="dialogVisible = visible"
10
10
  @after-leave="dialogVisible = visible"
11
11
  >
@@ -21,19 +21,19 @@
21
21
  @touchmove.stop.prevent
22
22
  @click.self="handleWrapperClick"
23
23
  ref="mask"
24
- class="zyb-dialog__mask"
24
+ class="qy-dialog__mask"
25
25
  ></div>
26
26
  <div
27
- class="zyb-dialog__wrapper"
27
+ class="qy-dialog__wrapper"
28
28
  :style="dialogStyle"
29
29
  >
30
30
  <div
31
- class="zyb-dialog__header"
31
+ class="qy-dialog__header"
32
32
  v-if="title || $slots.header"
33
33
  >
34
34
  <slot name="title">
35
35
  <h2
36
- class="zyb-dialog__title"
36
+ class="qy-dialog__title"
37
37
  :style="titleStyle"
38
38
  >
39
39
  {{title}}
@@ -41,7 +41,7 @@
41
41
  </slot>
42
42
  <button
43
43
  type="button"
44
- class="zyb-dialog__headerbtn"
44
+ class="qy-dialog__headerbtn"
45
45
  aria-label="Close"
46
46
  v-if="showClose && (isTopClose || position === 'bottom')"
47
47
  @click="closeHandler"
@@ -52,7 +52,7 @@
52
52
  </button>
53
53
  </div>
54
54
  <div
55
- class="zyb-dialog__content"
55
+ class="qy-dialog__content"
56
56
  ref="dialog"
57
57
  >
58
58
  <div class="autoOff-wrapper" v-if="autoOff">
@@ -72,7 +72,7 @@
72
72
  </template>
73
73
  </template>
74
74
  <div
75
- class="zyb-dialog__loading"
75
+ class="qy-dialog__loading"
76
76
  v-show="loading"
77
77
  >
78
78
  <span class="loading-inner">
@@ -82,7 +82,7 @@
82
82
  </div>
83
83
  </div>
84
84
  <div
85
- class="zyb-dialog__footer"
85
+ class="qy-dialog__footer"
86
86
  ref="footer"
87
87
  v-if="$slots.footer && !loading"
88
88
  >
@@ -91,8 +91,8 @@
91
91
  </div>
92
92
  <button
93
93
  type="button"
94
- class="zyb-dialog__bottom-btn"
95
- :class="{'zyb-dialog__bottom-btn-landscape': isClient && landscapeScreen}"
94
+ class="qy-dialog__bottom-btn"
95
+ :class="{'qy-dialog__bottom-btn-landscape': isClient && landscapeScreen}"
96
96
  aria-label="Close"
97
97
  v-if="showClose && !isTopClose && position === 'center'"
98
98
  @click="closeHandler"
@@ -113,7 +113,7 @@ import { px2rem, platform } from '../../../lib/utils'
113
113
  import Bus from '../../../lib/bus'
114
114
  import Cookies from 'js-cookie'
115
115
  // @ts-ignore: Unreachable code error
116
- import urlExt from '../../../lib/zyb-yike-utils/urlExt'
116
+ import urlExt from '../../../lib/utils/urlExt'
117
117
  import { CSSProperties } from 'vue'
118
118
  export enum ITriggerEnum {
119
119
  // 立即调用
@@ -209,9 +209,9 @@ export default class QyDialog extends Vue {
209
209
 
210
210
  get dialogCls () {
211
211
  return {
212
- 'zyb-dialog': true,
213
- [`zyb-dialog--${this.position}`]: true,
214
- 'zyb-dialog--close': !this.visible,
212
+ 'qy-dialog': true,
213
+ [`qy-dialog--${this.position}`]: true,
214
+ 'qy-dialog--close': !this.visible,
215
215
  'pad': this.isClient,
216
216
  'landscapeScreen': this.isTopClose === false && this.landscapeScreen === true
217
217
  }
@@ -219,8 +219,8 @@ export default class QyDialog extends Vue {
219
219
 
220
220
  get dialogWrapperCls () {
221
221
  return {
222
- 'zyb-dialog__wrapper': true,
223
- 'zyb-dialog__wrapper--close': !this.visible
222
+ 'qy-dialog__wrapper': true,
223
+ 'qy-dialog__wrapper--close': !this.visible
224
224
  }
225
225
  }
226
226
 
@@ -321,7 +321,7 @@ export default class QyDialog extends Vue {
321
321
  if (urlExt.getQuery('live') && urlExt.getQuery('liveGiftId') && platform.isIOS) {
322
322
  return
323
323
  }
324
- body.classList.add('zyb-dialog--prevent')
324
+ body.classList.add('qy-dialog--prevent')
325
325
  this.defaultHeight = window.scrollY
326
326
  document.body.style.position = 'fixed'
327
327
  document.body.style.top = -this.defaultHeight + 'px'
@@ -333,7 +333,7 @@ export default class QyDialog extends Vue {
333
333
  if (!body || !this.isClient) {
334
334
  return false
335
335
  }
336
- body.classList.remove('zyb-dialog--prevent')
336
+ body.classList.remove('qy-dialog--prevent')
337
337
  document.body.style.position = ''
338
338
  document.body.style.top = ''
339
339
  window.scrollTo(0, this.defaultHeight)
@@ -399,7 +399,7 @@ export default class QyDialog extends Vue {
399
399
  this.$nextTick(() => {
400
400
  this.visible = true
401
401
  this.$emit('open', this.visible)
402
- Bus.uid('zybDialog').emit('open', this.visible)
402
+ Bus.uid('qyDialog').emit('open', this.visible)
403
403
  Bus.uid('outPayDialog').emit('outPayDialogClose')
404
404
  // this.handleDialogShowDot()
405
405
  this.$nextTick(() => {
@@ -440,7 +440,7 @@ export default class QyDialog extends Vue {
440
440
  this.openBodyScroll()
441
441
  this.visible = false
442
442
  this.$emit('close', this.visible)
443
- Bus.uid('zybDialog').emit('close', this.visible)
443
+ Bus.uid('qyDialog').emit('close', this.visible)
444
444
  // 清除缓存
445
445
  DialogMap[this.uid] && this.$delete(DialogMap, this.uid)
446
446
  }
@@ -729,7 +729,7 @@ export default class QyDialog extends Vue {
729
729
  }
730
730
  // visible ? this.open() : this.close()
731
731
  })
732
- Bus.uid('zybDialog').on('close', () => {
732
+ Bus.uid('qyDialog').on('close', () => {
733
733
  this.close();
734
734
  })
735
735
  this.calcMaxHeight()
@@ -767,7 +767,7 @@ export default class QyDialog extends Vue {
767
767
  <style lang="less" scoped>
768
768
  @import '../../../assets/ico-font/iconfont/iconfont.css';
769
769
  @iconColor: #666666;
770
- .zyb-dialog {
770
+ .qy-dialog {
771
771
  padding: 0 !important;
772
772
  position: fixed;
773
773
  left: 50%;
@@ -783,7 +783,7 @@ export default class QyDialog extends Vue {
783
783
  min-height: 2.08rem;
784
784
  display: flex;
785
785
  flex-direction: column;
786
- .zyb-dialog__bottom-btn-landscape {
786
+ .qy-dialog__bottom-btn-landscape {
787
787
  bottom: -0.65rem !important;
788
788
  z-index: 999;
789
789
  }
@@ -809,7 +809,7 @@ export default class QyDialog extends Vue {
809
809
  }
810
810
  &--center {
811
811
  width: 5.6rem;
812
- .zyb-dialog__wrapper {
812
+ .qy-dialog__wrapper {
813
813
  border-radius: 0.2rem;
814
814
  }
815
815
  @media (orientation: portrait) {
@@ -833,7 +833,7 @@ export default class QyDialog extends Vue {
833
833
  border-bottom-left-radius: 0;
834
834
  transform: translateY(0);
835
835
  max-height: 10.5rem;
836
- .zyb-dialog__wrapper {
836
+ .qy-dialog__wrapper {
837
837
  border-top-left-radius: 0.2rem;
838
838
  border-top-right-radius: 0.2rem;
839
839
  }
@@ -983,7 +983,7 @@ export default class QyDialog extends Vue {
983
983
  }
984
984
  }
985
985
 
986
- // .zyb-dialog-slide__center {
986
+ // .qy-dialog-slide__center {
987
987
  // &-enter-active,
988
988
  // &-leave-active {
989
989
  // transition: opacity .2s ease;
@@ -997,7 +997,7 @@ export default class QyDialog extends Vue {
997
997
  -webkit-overflow-scrolling: auto;
998
998
  }
999
999
 
1000
- .zyb-dialog-slide__bottom {
1000
+ .qy-dialog-slide__bottom {
1001
1001
  &-enter-active,
1002
1002
  &-leave-active {
1003
1003
  transition: transform 0.2s ease;
@@ -1015,7 +1015,7 @@ export default class QyDialog extends Vue {
1015
1015
  }
1016
1016
  </style>
1017
1017
  <style lang="less">
1018
- .zyb-dialog {
1018
+ .qy-dialog {
1019
1019
  &--prevent {
1020
1020
  width: 100%;
1021
1021
  overflow: hidden;
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <section class="zyb-hotarea">
2
+ <section class="qy-hotarea">
3
3
  </section>
4
4
  </template>
5
5
  <script lang='ts'>
@@ -13,7 +13,7 @@ export default class QyHotarea extends Vue {
13
13
  }
14
14
  </script>
15
15
  <style lang="less" scoped>
16
- .zyb-hotarea {
16
+ .qy-hotarea {
17
17
  position: absolute;
18
18
  width: 1rem;
19
19
  height: 1rem;
@@ -15,7 +15,7 @@
15
15
  <script lang="ts">
16
16
  import { Vue, Component, Prop, Watch } from 'vue-property-decorator'
17
17
  // @ts-ignore: Unreachable code error
18
- import urlExt from '../../../lib/zyb-yike-utils/urlExt'
18
+ import urlExt from '../../../lib/utils/urlExt'
19
19
  // import { urlExt } from 'yike-utils'
20
20
  import { toast } from '../../../lib/methods'
21
21
  import { service as RequestProxy } from '../../../lib/request-proxy'
@@ -1,6 +1,6 @@
1
1
  import { ComponentTypeEnum } from '../../../typings/enum/component-type'
2
2
  import { saleChannelConfig } from '../../../typings/enum/saleChannelConfig'
3
- const imgSize = 0.1 // 0.1M
3
+ const imgSize = 5 // 5M
4
4
  const textStyle = { // SetText组件样式
5
5
  lineHeight: 1
6
6
  }
@@ -74,8 +74,7 @@ export default {
74
74
  type: 'SetUploadImage',
75
75
  label: '图片',
76
76
  name: 'imageList',
77
- uploadTips: `支持png/jpg/jpeg/gif格式,尺寸限制为:720*120,大小不超过${imgSize *
78
- 1000}KB`,
77
+ uploadTips: `支持png/jpg/jpeg/gif格式,尺寸限制为:720*120,大小不超过5MB`,
79
78
  limitObj: {
80
79
  // width: 720,
81
80
  // height: 120,
@@ -144,7 +144,7 @@ export default class QyOutFormInput extends Vue {
144
144
  position: absolute;
145
145
  right: 0.32rem;
146
146
  top: 0.20rem;
147
- background: url('https://img.zuoyebang.cc/zyb_ed54c2aa3ff3899cb6af1a0827ca3347.jpg') no-repeat no-repeat;
147
+ background: none;
148
148
  background-size: 100%;
149
149
  transform: rotate(90deg);
150
150
  &.open {
@@ -181,7 +181,7 @@ export default class QyOutFormSelect extends Vue {
181
181
  position: absolute;
182
182
  right: 0.32rem;
183
183
  top: 0.20rem;
184
- background: url('https://img.zuoyebang.cc/zyb_ed54c2aa3ff3899cb6af1a0827ca3347.jpg') no-repeat no-repeat;
184
+ background: none;
185
185
  background-size: 100%;
186
186
  transform: rotate(90deg);
187
187
  &.open {
@@ -32,7 +32,7 @@
32
32
  import { Vue, Component, Prop, Watch, Mixins } from 'vue-property-decorator'
33
33
  import StickyMixin from '../../../lib/sticky-mixin'
34
34
  import bus from '../bus'
35
- import logParamHandle from '../../../lib/zyb-yike-utils/logParamHandle'
35
+ import logParamHandle from '../../../lib/utils/logParamHandle'
36
36
  import { toast } from '../../../lib/methods'
37
37
  import Bus from '../../../lib/bus'
38
38
  // 环境判断
@@ -112,11 +112,11 @@ export default class QyOutFormSubmitButton extends Mixins(StickyMixin) {
112
112
  }
113
113
  })
114
114
  readonly btnImageBorder!: any
115
- btnDefaultImage:string = 'https://cube-cdn.zuoyebang.com/uploadFile/zyb_c6b02960e862d984611cc4ed6ca74782.png'
115
+ btnDefaultImage:string = require('./static/default-btn.png')
116
116
  animationIndex = 0 // 当前执行动画序号
117
117
  startAnimation = false // 是否开始动画
118
118
  // 表单内容
119
- zybOutFormData: any = {}
119
+ qyOutFormData: any = {}
120
120
 
121
121
  // 外套容器背景色
122
122
  get marginShadow () {
@@ -351,7 +351,7 @@ export default class QyOutFormSubmitButton extends Mixins(StickyMixin) {
351
351
  }
352
352
  const { actionType, params, uid } = this.actions[0]
353
353
  if (actionType) {
354
- this.setFormToFlowPond()
354
+ this.setFormToTfExtData()
355
355
  this.$nextTick(() => {
356
356
  Bus.uid(uid || this.uid).emit(actionType, params, {})
357
357
  })
@@ -360,8 +360,8 @@ export default class QyOutFormSubmitButton extends Mixins(StickyMixin) {
360
360
  // 检查端外表单是否填写完成
361
361
  checkForm () {
362
362
  let flag = true
363
- Object.keys(this.zybOutFormData).forEach((item: any) => {
364
- const com: any = this.zybOutFormData[item]
363
+ Object.keys(this.qyOutFormData).forEach((item: any) => {
364
+ const com: any = this.qyOutFormData[item]
365
365
  if (com.required && !com.value) {
366
366
  flag = false
367
367
  }
@@ -369,33 +369,33 @@ export default class QyOutFormSubmitButton extends Mixins(StickyMixin) {
369
369
  return flag
370
370
  }
371
371
 
372
- // 存储端外表单数据到flowPond里面去
373
- setFormToFlowPond () {
372
+ // 存储端外表单数据到tfExtData里面去
373
+ setFormToTfExtData () {
374
374
  const form: any[] = []
375
- Object.keys(this.zybOutFormData).forEach((item: any) => {
375
+ Object.keys(this.qyOutFormData).forEach((item: any) => {
376
376
  form.push({
377
- key: this.zybOutFormData[item].key,
378
- value: this.zybOutFormData[item].value,
379
- type: this.zybOutFormData[item].type,
380
- required: this.zybOutFormData[item].required
377
+ key: this.qyOutFormData[item].key,
378
+ value: this.qyOutFormData[item].value,
379
+ type: this.qyOutFormData[item].type,
380
+ required: this.qyOutFormData[item].required
381
381
  })
382
382
  })
383
- console.log('setFormToFlowPond', form)
384
- logParamHandle.setFlowPond({ QyOutFormContent: JSON.stringify(form) })
383
+ console.log('setFormToTfExtData', form)
384
+ logParamHandle.setTfExtData({ QyOutFormContent: JSON.stringify(form) })
385
385
  }
386
386
 
387
387
  created () {
388
388
  bus.$on('QyOutFormItemInit', (res: { key: string, required: boolean, type: string, uniKey: string }) => {
389
389
  console.log('QyOutFormItemInit', res)
390
- this.zybOutFormData[res.uniKey] = {
390
+ this.qyOutFormData[res.uniKey] = {
391
391
  ...res,
392
392
  value: ''
393
393
  }
394
394
  })
395
395
  bus.$on('QyOutFormItemChange', (res: { uniKey: string, value: any }) => {
396
396
  console.log('QyOutFormItemChange', res)
397
- if (res && res.uniKey && this.zybOutFormData[res.uniKey]) {
398
- this.zybOutFormData[res.uniKey].value = res.value
397
+ if (res && res.uniKey && this.qyOutFormData[res.uniKey]) {
398
+ this.qyOutFormData[res.uniKey].value = res.value
399
399
  }
400
400
  })
401
401
  }