@tplc/business 0.7.68 → 0.7.69

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.7.69](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/compare/v0.7.68...v0.7.69) (2026-01-14)
6
+
5
7
  ### [0.7.68](https://gitlab888.30jia.com.cn/tourism-front/zero-code-pro/compare/v1.0.27...v0.7.68) (2026-01-14)
6
8
 
7
9
 
@@ -12,7 +12,7 @@
12
12
  <lcb-order-payment
13
13
  v-model="form.payType"
14
14
  v-model:payCardId="form.payCardId"
15
- v-model:paymentInfoItems="form.paymentInfoItems"
15
+ v-model:paymentInfoJson="form.paymentInfoJson"
16
16
  :data="dataInfo?.commitPagePaymentMethod"
17
17
  @onWalletPriceChange="onWalletPriceChange"
18
18
  v-if="dataInfo?.commitPagePaymentMethod"
@@ -44,7 +44,7 @@ const form = ref({
44
44
  payCardId: '',
45
45
  toStoreFlag: false,
46
46
  walletAccountId: '' as string | undefined,
47
- paymentInfoItems: [] as any[],
47
+ paymentInfoJson: {} as Record<string, any>,
48
48
  })
49
49
 
50
50
  const [pay] = usePay(() =>
@@ -24,14 +24,14 @@
24
24
  </view>
25
25
  </view>
26
26
  </wd-radio>
27
- <lcb-form
28
- custom-class="ml-56rpx"
29
- v-if="payType === item.type && item.items"
30
- :fields="item.items"
31
- :bottomFixed="false"
32
- submitText=""
33
- v-model="insteadForm"
34
- />
27
+ <view class="ml-56rpx" v-if="payType === item.type && item.items">
28
+ <lcb-form
29
+ :fields="item.items"
30
+ :bottomFixed="false"
31
+ submitText=""
32
+ v-model="insteadForm"
33
+ />
34
+ </view>
35
35
  </view>
36
36
 
37
37
  <wd-radio :value="item.type" shape="dot" cell v-else-if="!(item.content || item.items)">
@@ -126,8 +126,8 @@ const props = defineProps<LcbOrderPaymentProps>()
126
126
  const emits = defineEmits(['onWalletPriceChange'])
127
127
  const payType = defineModel<string>()
128
128
  const payCardId = defineModel<string>('payCardId')
129
- // 代下单(instead)表单数据:提交到父级 form.paymentInfoItems
130
- const paymentInfoItems = defineModel<any[]>('paymentInfoItems')
129
+ // 代下单(instead)表单数据:提交到父级 form.paymentInfoJson
130
+ const paymentInfoJson = defineModel<Record<string, any>>('paymentInfoJson')
131
131
  const insteadForm = ref<Record<string, any>>({})
132
132
  const getGroupValue = (payType: string, payCardId: string) => {
133
133
  return payType ? `${payType}${payCardId ? '-' + payCardId : ''}` : undefined
@@ -140,28 +140,17 @@ watch([payType, payCardId], ([newPayType, newPayCardId]) => {
140
140
  })
141
141
 
142
142
  const syncInsteadPaymentInfo = () => {
143
- if (!paymentInfoItems.value) return
143
+ if (!paymentInfoJson.value) return
144
144
  if (payType.value !== 'instead') {
145
- paymentInfoItems.value = []
145
+ paymentInfoJson.value = {}
146
146
  return
147
147
  }
148
148
  const selected = props.data?.find((d) => d.type === 'instead')
149
149
  if (!selected) {
150
- paymentInfoItems.value = []
150
+ paymentInfoJson.value = {}
151
151
  return
152
152
  }
153
- const rawItems: any[] = (selected as any).items || []
154
- paymentInfoItems.value = [
155
- {
156
- ...(selected as any),
157
- // 保留原始 items(字段定义),同时补上用户输入值,方便后端直接取用
158
- items: rawItems.map((f: any) => ({
159
- ...f,
160
- value: f?.field ? insteadForm.value?.[f.field] : undefined,
161
- })),
162
- form: { ...insteadForm.value },
163
- },
164
- ]
153
+ paymentInfoJson.value = insteadForm.value
165
154
  }
166
155
 
167
156
  watch(payType, () => {
@@ -274,10 +263,8 @@ const onModifyPrice = (price: number, max: number) => {
274
263
  }
275
264
 
276
265
  :deep(.lcb-form) {
277
- :deep(.wd-cell) {
278
- .wd-cell__wrapper {
279
- padding: 24rpx 0rpx !important;
280
- }
266
+ .wd-cell__wrapper {
267
+ padding: 16rpx 0rpx !important;
281
268
  }
282
269
  }
283
270
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tplc/business",
3
- "version": "0.7.68",
3
+ "version": "0.7.69",
4
4
  "keywords": [
5
5
  "业务组件"
6
6
  ],
@@ -3,7 +3,7 @@ declare let __VLS_typeProps: LcbOrderPaymentProps
3
3
  type __VLS_PublicProps = {
4
4
  modelValue?: string
5
5
  payCardId?: string
6
- paymentInfoItems?: any[]
6
+ paymentInfoJson?: Record<string, any>
7
7
  } & typeof __VLS_typeProps
8
8
  declare const _default: import('vue').DefineComponent<
9
9
  __VLS_TypePropsToOption<__VLS_PublicProps>,
@@ -16,7 +16,7 @@ declare const _default: import('vue').DefineComponent<
16
16
  {
17
17
  'update:modelValue': (modelValue: string) => void
18
18
  'update:payCardId': (payCardId: string) => void
19
- 'update:paymentInfoItems': (paymentInfoItems: any[]) => void
19
+ 'update:paymentInfoJson': (paymentInfoJson: Record<string, any>) => void
20
20
  onWalletPriceChange: (...args: any[]) => void
21
21
  },
22
22
  string,
@@ -25,7 +25,7 @@ declare const _default: import('vue').DefineComponent<
25
25
  'onUpdate:modelValue'?: ((modelValue: string) => any) | undefined
26
26
  onOnWalletPriceChange?: ((...args: any[]) => any) | undefined
27
27
  'onUpdate:payCardId'?: ((payCardId: string) => any) | undefined
28
- 'onUpdate:paymentInfoItems'?: ((paymentInfoItems: any[]) => any) | undefined
28
+ 'onUpdate:paymentInfoJson'?: ((paymentInfoJson: Record<string, any>) => any) | undefined
29
29
  },
30
30
  {},
31
31
  {}