cabloy 5.1.122 → 5.1.124
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/.cabloy-version +1 -1
- package/.claude/skills/cabloy-frontend-scaffold/SKILL.md +13 -3
- package/.claude/skills/cabloy-workflow/SKILL.md +6 -0
- package/.claude/skills/cabloy-workflow/evals/evals.json +6 -0
- package/CHANGELOG.md +24 -0
- package/CLAUDE.md +1 -1
- package/cabloy-docs/.vitepress/config.mjs +4 -0
- package/cabloy-docs/frontend/form-layout-guide.md +29 -7
- package/cabloy-docs/fullstack/parallel-worktree-environment.md +87 -0
- package/e2e/scripts/e2e.ts +13 -1
- package/e2e/scripts/startE2eVona.ts +4 -1
- package/e2e/specs/a-commerce/commerce.spec.ts +129 -32
- package/package.json +2 -1
- package/playwright-report/data/24ac790ec112339c76cfb0c8e2c2539c2f953a0b.zip +0 -0
- package/playwright-report/data/2fddcabcdbd0b695061a565acfff243cb3a4f5e3.zip +0 -0
- package/playwright-report/data/4738038d9e861d63fd25937c9a3570934786a62f.zip +0 -0
- package/playwright-report/data/72f99c7da67c7f6ea53cab7d8681798b70d79a10.md +222 -0
- package/playwright-report/data/7b9684a7c793e9798b898f8ff50177b660a7a733.md +222 -0
- package/playwright-report/data/8b31595f5f1cc9d23863af51a592e6b90dcbc4ce.zip +0 -0
- package/playwright-report/data/95b578407a68806202dda917a61c50c750bd285b.md +222 -0
- package/playwright-report/data/ad960b3a58f224f5b4cad04a24067600064ffb7b.md +222 -0
- package/playwright-report/index.html +90 -0
- package/playwright-report/trace/assets/codeMirrorModule-LEHpjmcn.js +32 -0
- package/playwright-report/trace/assets/defaultSettingsView-BNmKHKpQ.js +264 -0
- package/playwright-report/trace/assets/urlMatch-BYQrIQwR.js +1 -0
- package/playwright-report/trace/codeMirrorModule.DYBRYzYX.css +1 -0
- package/playwright-report/trace/codicon.DCmgc-ay.ttf +0 -0
- package/playwright-report/trace/defaultSettingsView.CjdS-WJx.css +1 -0
- package/playwright-report/trace/index.CzXZzn5A.css +1 -0
- package/playwright-report/trace/index.DMMX1gXU.js +2 -0
- package/playwright-report/trace/index.html +44 -0
- package/playwright-report/trace/manifest.webmanifest +16 -0
- package/playwright-report/trace/playwright-logo.svg +9 -0
- package/playwright-report/trace/snapshot.html +10 -0
- package/playwright-report/trace/snapshot.v8KI4P3m.js +2 -0
- package/playwright-report/trace/sw.bundle.js +5 -0
- package/playwright-report/trace/uiMode.BZQ54Kgt.css +1 -0
- package/playwright-report/trace/uiMode.Ut8wwJNp.js +6 -0
- package/playwright-report/trace/uiMode.html +18 -0
- package/playwright-report/trace/xtermModule.DYP7pi_n.css +32 -0
- package/vona/env/.env +12 -0
- package/vona/env/.env.test +7 -0
- package/vona/packages-cli/cli/package.json +1 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudBasic/boilerplate/src/dto/{{resourceName}}Create.tsx_ +19 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudBasic/boilerplate/src/dto/{{resourceName}}Update.tsx_ +19 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudBasic/boilerplate/src/dto/{{resourceName}}View.tsx_ +19 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudBasic/snippets/3-en-us.ts +6 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudBasic/snippets/4-zh-cn.ts +6 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudStart/boilerplate/src/dto/{{resourceName}}Create.tsx_ +19 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudStart/boilerplate/src/dto/{{resourceName}}Update.tsx_ +19 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudStart/boilerplate/src/dto/{{resourceName}}View.tsx_ +19 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudStart/snippets/3-en-us.ts +6 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/crudStart/snippets/4-zh-cn.ts +6 -1
- package/vona/packages-cli/cli-set-api/package.json +1 -1
- package/vona/pnpm-lock.yaml +255 -12
- package/vona/pnpm-workspace.yaml +1 -1
- package/vona/src/suite/a-commerce/modules/commerce-payment/package.json +4 -1
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/.metadata/index.ts +45 -3
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/bean/meta.index.ts +1 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/bean/meta.version.ts +25 -1
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/bean/payScene.commerceOrder.ts +20 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/entity/paymentAttempt.tsx +9 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/entity/paymentAudit.tsx +5 -2
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/entity/refundAttempt.tsx +6 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/index.ts +2 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/lib/index.ts +1 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/service/commercePayScene.ts +54 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/service/paymentAttempt.ts +7 -1
- package/vona/src/suite/a-commerce/modules/commerce-payment/src/types/index.ts +1 -0
- package/vona/src/suite/a-commerce/modules/commerce-payment/test/paymentAttempt.test.ts +21 -0
- package/vona/src/suite/a-commerce/modules/commerce-promotion/src/.metadata/index.ts +30 -0
- package/vona/src/suite/a-commerce/modules/commerce-promotion/src/config/locale/en-us.ts +4 -0
- package/vona/src/suite/a-commerce/modules/commerce-promotion/src/config/locale/zh-cn.ts +4 -0
- package/vona/src/suite/a-commerce/modules/commerce-promotion/src/dto/couponTemplateCreate.tsx +88 -1
- package/vona/src/suite/a-commerce/modules/commerce-promotion/src/dto/couponTemplateUpdate.tsx +44 -1
- package/vona/src/suite/a-commerce/modules/commerce-promotion/src/dto/couponTemplateView.tsx +72 -1
- package/vona/src/suite/a-commerce/modules/commerce-promotion/test/couponTemplateFormLayout.test.ts +121 -0
- package/vona/src/suite/a-commerce/modules/commerce-siteweb/src/bean/ssrMenu.home.ts +4 -1
- package/vona/src/suite/a-commerce/modules/commerce-trade/package.json +4 -1
- package/vona/src/suite/a-commerce/modules/commerce-trade/src/.metadata/index.ts +0 -21
- package/vona/src/suite/a-commerce/modules/commerce-trade/src/dto/checkoutResult.tsx +3 -0
- package/vona/src/suite/a-commerce/modules/commerce-trade/src/service/order.ts +79 -0
- package/vona/src/suite/a-commerce/modules/commerce-trade/test/orderSnapshot.test.ts +227 -0
- package/vona/src/suite/a-commerce/modules/commerce-trade/test/paymentOutcome.test.ts +121 -13
- package/vona/src/suite/a-commerce/modules/commerce-trade/test/refundLifecycle.test.ts +312 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/package.json +76 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/.metadata/index.ts +842 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/.metadata/this.ts +2 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/bean/bean.payProvider.ts +92 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/bean/bean.payScene.ts +105 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/bean/meta.index.ts +28 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/bean/meta.redlock.ts +11 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/bean/meta.version.ts +113 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/bean/queue.outboxDispatch.ts +31 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/bean/schedule.outboxDispatch.ts +11 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/controller/paymentSession.ts +55 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/controller/webhook.ts +47 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/dto/paymentSessionStart.tsx +8 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/dto/paymentSessionView.tsx +69 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/dto/webhookReceipt.tsx +12 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/entity/outboxEvent.tsx +46 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/entity/paymentAudit.tsx +36 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/entity/paymentSession.tsx +72 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/entity/providerOperation.tsx +54 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/entity/refundOperation.tsx +37 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/entity/webhookInbox.tsx +59 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/index.ts +3 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/lib/index.ts +2 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/lib/payProvider.ts +7 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/lib/payScene.ts +7 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/model/outboxEvent.ts +10 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/model/paymentAudit.ts +10 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/model/paymentSession.ts +10 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/model/providerOperation.ts +10 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/model/refundOperation.ts +10 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/model/webhookInbox.ts +10 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/service/outbox.ts +156 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/service/paymentSession.ts +278 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/service/providerOperation.ts +5 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/service/webhook.ts +127 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/types/index.ts +3 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/types/payProvider.ts +74 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/types/payScene.ts +63 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/src/types/payment.ts +151 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/test/outbox.test.ts +209 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/test/paymentSession.test.ts +153 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/test/webhook.test.ts +278 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/tsconfig.build.json +11 -0
- package/vona/src/suite-vendor/a-pay/modules/a-pay/tsconfig.json +7 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/package.json +55 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/.metadata/index.ts +182 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/.metadata/this.ts +2 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/bean/payProvider.mock.ts +149 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/controller/mockPayment.ts +25 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/dto/mockPaymentComplete.tsx +13 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/dto/mockPaymentReceipt.tsx +16 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/index.ts +3 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/lib/index.ts +1 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/service/payMock.ts +78 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/src/types/index.ts +10 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/test/payMock.test.ts +141 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/tsconfig.build.json +11 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-mock/tsconfig.json +7 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/package.json +55 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/src/.metadata/index.ts +62 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/src/.metadata/this.ts +2 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/src/bean/payProvider.paypal.ts +91 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/src/index.ts +3 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/src/lib/index.ts +1 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/src/types/index.ts +9 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/tsconfig.build.json +11 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-paypal/tsconfig.json +7 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/package.json +55 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/src/.metadata/index.ts +62 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/src/.metadata/this.ts +2 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/src/bean/payProvider.stripe.ts +88 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/src/index.ts +2 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/src/types/index.ts +8 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/tsconfig.build.json +11 -0
- package/vona/src/suite-vendor/a-pay/modules/pay-stripe/tsconfig.json +7 -0
- package/vona/src/suite-vendor/a-pay/package.json +15 -0
- package/vona/src/suite-vendor/a-pay/tsconfig.base.json +4 -0
- package/vona/src/suite-vendor/a-pay/tsconfig.json +19 -0
- package/zova/env/.env +1 -0
- package/zova/openapi.config.ts +5 -1
- package/zova/package.original.json +1 -1
- package/zova/packages-cli/cli/package.json +2 -2
- package/zova/packages-cli/cli-set-front/cli/templates/openapi/config/boilerplate/project/openapi.config.ts +5 -1
- package/zova/packages-cli/cli-set-front/package.json +1 -1
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.openapi.generate.ts +8 -0
- package/zova/packages-cli/cli-set-front/src/lib/common/cliCreatePage.ts +7 -24
- package/zova/packages-cli/cli-set-front/src/lib/common/utils.ts +10 -1
- package/zova/packages-utils/zova-jsx/package.json +2 -2
- package/zova/packages-zova/zova/package.json +3 -3
- package/zova/packages-zova/zova-core/package.json +1 -1
- package/zova/packages-zova/zova-core/src/types/interface/component.ts +5 -0
- package/zova/pnpm-lock.yaml +96 -26
- package/zova/src/front/config/config/config.cabloyCommerce.ts +1 -1
- package/zova/src/suite/a-commerce/modules/commerce-promotion/src/api/openapi/schemas.ts +110 -12
- package/zova/src/suite/a-commerce/modules/commerce-promotion/src/api/openapi/types.ts +1292 -160
- package/zova/src/suite/a-commerce/modules/commerce-trade/cli/openapi.config.ts +0 -1
- package/zova/src/suite/a-commerce/modules/commerce-trade/package.json +4 -1
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/.metadata/index.ts +1 -47
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/api/openapi/schemas.ts +23 -8
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/api/openapi/types.ts +249 -62
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/page/checkout/controller.tsx +5 -1
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/page/payment/controller.tsx +152 -39
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/routes.ts +1 -1
- package/zova/src/suite-vendor/a-pay/modules/a-pay/cli/openapi.config.ts +9 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/package.json +53 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/.metadata/component/paymentNextAction.ts +31 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/.metadata/index.ts +217 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/.metadata/this.ts +2 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/api/openapi/baseURL.ts +5 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/api/openapi/index.ts +3 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/api/openapi/schemas.ts +584 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/api/openapi/types.ts +9324 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/api/paymentSession.ts +52 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/apiSchema/paymentSession.ts +20 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/component/paymentNextAction/controller.tsx +76 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/index.ts +3 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/lib/index.ts +1 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/model/paymentSession.ts +32 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/service/paymentCoordinator.ts +13 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/types/index.ts +1 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/src/types/payment.ts +25 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/tsconfig.build.json +13 -0
- package/zova/src/suite-vendor/a-pay/modules/a-pay/tsconfig.json +5 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/cli/openapi.config.ts +9 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/package.json +53 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/.metadata/index.ts +140 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/.metadata/this.ts +2 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/api/openapi/baseURL.ts +5 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/api/openapi/index.ts +3 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/api/openapi/schemas.ts +584 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/api/openapi/types.ts +9324 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/api/payMockPayment.ts +34 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/apiSchema/payMockPayment.ts +13 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/index.ts +1 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/src/model/payMockPayment.ts +20 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/tsconfig.build.json +13 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-mock/tsconfig.json +5 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-paypal/package.json +52 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-paypal/src/.metadata/index.ts +26 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-paypal/src/.metadata/this.ts +2 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-paypal/src/index.ts +1 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-paypal/tsconfig.build.json +13 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-paypal/tsconfig.json +5 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-stripe/package.json +52 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-stripe/src/.metadata/index.ts +26 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-stripe/src/.metadata/this.ts +2 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-stripe/src/index.ts +1 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-stripe/tsconfig.build.json +13 -0
- package/zova/src/suite-vendor/a-pay/modules/pay-stripe/tsconfig.json +5 -0
- package/zova/src/suite-vendor/a-pay/package.json +15 -0
- package/zova/src/suite-vendor/a-pay/tsconfig.base.json +4 -0
- package/zova/src/suite-vendor/a-pay/tsconfig.json +4 -0
- package/zova/src/suite-vendor/a-zova/modules/a-zova/package.json +2 -2
- package/zova/src/suite-vendor/a-zova/package.json +2 -2
- package/vona/src/suite/a-commerce/modules/commerce-trade/src/controller/payment.ts +0 -23
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/api/commerceTradePayment.ts +0 -36
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/apiSchema/commerceTradePayment.ts +0 -13
- package/zova/src/suite/a-commerce/modules/commerce-trade/src/model/payment.ts +0 -25
- /package/vona/patches/{zova-core@5.1.79.patch → zova-core@5.1.81.patch} +0 -0
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
// eslint-disable
|
|
2
|
+
/** payProvider: begin */
|
|
3
|
+
export * from '../bean/payProvider.stripe.ts';
|
|
4
|
+
import type { IPayProviderOptionsStripe } from '../bean/payProvider.stripe.ts';
|
|
5
|
+
import 'vona-module-a-pay';
|
|
6
|
+
declare module 'vona-module-a-pay' {
|
|
7
|
+
|
|
8
|
+
export interface IPayProviderRecord {
|
|
9
|
+
'pay-stripe:stripe': IPayProviderOptionsStripe;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
}
|
|
14
|
+
declare module 'vona-module-pay-stripe' {
|
|
15
|
+
|
|
16
|
+
export interface PayProviderStripe {
|
|
17
|
+
/** @internal */
|
|
18
|
+
get scope(): ScopeModulePayStripe;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface PayProviderStripe {
|
|
22
|
+
get $beanFullName(): 'pay-stripe.payProvider.stripe';
|
|
23
|
+
get $onionName(): 'pay-stripe:stripe';
|
|
24
|
+
get $onionOptions(): IPayProviderOptionsStripe;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
/** payProvider: end */
|
|
28
|
+
/** payProvider: begin */
|
|
29
|
+
import type { PayProviderStripe } from '../bean/payProvider.stripe.ts';
|
|
30
|
+
export interface IModulePayProvider {
|
|
31
|
+
'stripe': PayProviderStripe;
|
|
32
|
+
}
|
|
33
|
+
/** payProvider: end */
|
|
34
|
+
/** scope: begin */
|
|
35
|
+
import { BeanScopeBase, type BeanScopeUtil } from 'vona';
|
|
36
|
+
import { Scope } from 'vona-module-a-bean';
|
|
37
|
+
|
|
38
|
+
@Scope()
|
|
39
|
+
export class ScopeModulePayStripe extends BeanScopeBase {}
|
|
40
|
+
|
|
41
|
+
export interface ScopeModulePayStripe {
|
|
42
|
+
util: BeanScopeUtil;
|
|
43
|
+
payProvider: IModulePayProvider;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
import 'vona';
|
|
47
|
+
declare module 'vona' {
|
|
48
|
+
export interface IBeanScopeRecord {
|
|
49
|
+
'pay-stripe': ScopeModulePayStripe;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export interface IBeanScopeContainer {
|
|
53
|
+
payStripe: ScopeModulePayStripe;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
}
|
|
62
|
+
/** scope: end */
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
IDecoratorPayProviderOptions,
|
|
3
|
+
IPayProviderClientOptions,
|
|
4
|
+
IPayProviderClientRecord,
|
|
5
|
+
IPayProviderExecute,
|
|
6
|
+
IPayProviderPaymentInput,
|
|
7
|
+
IPayProviderPaymentSnapshot,
|
|
8
|
+
IPayProviderRefundInput,
|
|
9
|
+
IPayProviderRefundSnapshot,
|
|
10
|
+
IPayProviderVerifiedWebhook,
|
|
11
|
+
IPayProviderWebhookInput,
|
|
12
|
+
} from 'vona-module-a-pay';
|
|
13
|
+
|
|
14
|
+
import { BeanBase, useApp } from 'vona';
|
|
15
|
+
import { PayProvider } from 'vona-module-a-pay';
|
|
16
|
+
|
|
17
|
+
export interface IPayProviderStripeClientRecord extends IPayProviderClientRecord {}
|
|
18
|
+
|
|
19
|
+
export interface IPayProviderStripeClientOptions extends IPayProviderClientOptions {
|
|
20
|
+
secretCredential: string | undefined;
|
|
21
|
+
secretWebhook: string | undefined;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
const app = useApp();
|
|
25
|
+
|
|
26
|
+
export interface IPayProviderOptionsStripe extends IDecoratorPayProviderOptions<
|
|
27
|
+
IPayProviderStripeClientRecord,
|
|
28
|
+
IPayProviderStripeClientOptions
|
|
29
|
+
> {}
|
|
30
|
+
|
|
31
|
+
@PayProvider<IPayProviderOptionsStripe>({
|
|
32
|
+
base: {
|
|
33
|
+
capabilities: {
|
|
34
|
+
redirectCheckout: false,
|
|
35
|
+
embeddedCheckout: true,
|
|
36
|
+
automaticCapture: true,
|
|
37
|
+
manualCapture: false,
|
|
38
|
+
refunds: true,
|
|
39
|
+
partialRefunds: true,
|
|
40
|
+
webhooks: true,
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
clients: {
|
|
44
|
+
default: {
|
|
45
|
+
environment: 'sandbox',
|
|
46
|
+
secretCredential: app.meta.env.STRIPE_SECRET_KEY,
|
|
47
|
+
secretWebhook: app.meta.env.STRIPE_WEBHOOK_SECRET,
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
})
|
|
51
|
+
export class PayProviderStripe
|
|
52
|
+
extends BeanBase
|
|
53
|
+
implements IPayProviderExecute<IPayProviderStripeClientOptions>
|
|
54
|
+
{
|
|
55
|
+
async startPayment(
|
|
56
|
+
_input: IPayProviderPaymentInput,
|
|
57
|
+
_clientOptions: IPayProviderStripeClientOptions,
|
|
58
|
+
): Promise<IPayProviderPaymentSnapshot> {
|
|
59
|
+
this.app.throw(501, 'Stripe provider is not implemented');
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
async queryPayment(
|
|
63
|
+
_input: IPayProviderPaymentInput,
|
|
64
|
+
_clientOptions: IPayProviderStripeClientOptions,
|
|
65
|
+
): Promise<IPayProviderPaymentSnapshot> {
|
|
66
|
+
this.app.throw(501, 'Stripe provider is not implemented');
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
async createRefund(
|
|
70
|
+
_input: IPayProviderRefundInput,
|
|
71
|
+
_clientOptions: IPayProviderStripeClientOptions,
|
|
72
|
+
): Promise<IPayProviderRefundSnapshot> {
|
|
73
|
+
this.app.throw(501, 'Stripe provider is not implemented');
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
async verifyWebhook(
|
|
77
|
+
_input: IPayProviderWebhookInput,
|
|
78
|
+
_clientOptions: IPayProviderStripeClientOptions,
|
|
79
|
+
): Promise<IPayProviderVerifiedWebhook> {
|
|
80
|
+
this.app.throw(501, 'Stripe provider is not implemented');
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
declare module 'vona-module-a-pay' {
|
|
85
|
+
export interface IPayProviderRecord {
|
|
86
|
+
'pay-stripe:stripe': IPayProviderOptionsStripe;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "vona-suite-a-pay",
|
|
3
|
+
"version": "5.0.1",
|
|
4
|
+
"description": "",
|
|
5
|
+
"author": "",
|
|
6
|
+
"files": [],
|
|
7
|
+
"type": "module",
|
|
8
|
+
"dependencies": {
|
|
9
|
+
"vona-module-a-pay": "^5.0.1",
|
|
10
|
+
"vona-module-pay-mock": "^5.0.1",
|
|
11
|
+
"vona-module-pay-paypal": "^5.0.1",
|
|
12
|
+
"vona-module-pay-stripe": "^5.0.1"
|
|
13
|
+
},
|
|
14
|
+
"title": "a-pay"
|
|
15
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"extends": "./tsconfig.base",
|
|
3
|
+
"compilerOptions": {},
|
|
4
|
+
"references": [
|
|
5
|
+
{
|
|
6
|
+
"path": "modules/a-pay/tsconfig.build.json"
|
|
7
|
+
},
|
|
8
|
+
{
|
|
9
|
+
"path": "modules/pay-mock/tsconfig.build.json"
|
|
10
|
+
},
|
|
11
|
+
{
|
|
12
|
+
"path": "modules/pay-paypal/tsconfig.build.json"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"path": "modules/pay-stripe/tsconfig.build.json"
|
|
16
|
+
}
|
|
17
|
+
],
|
|
18
|
+
"exclude": ["modules"]
|
|
19
|
+
}
|
package/zova/env/.env
CHANGED
package/zova/openapi.config.ts
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import type { ZovaOpenapiConfig } from 'zova-openapi';
|
|
2
2
|
|
|
3
3
|
export default function (): ZovaOpenapiConfig {
|
|
4
|
+
const apiBaseURL = process.env.API_BASE_URL;
|
|
5
|
+
if (!apiBaseURL) {
|
|
6
|
+
throw new Error('Missing API_BASE_URL');
|
|
7
|
+
}
|
|
4
8
|
return {
|
|
5
9
|
default: {
|
|
6
|
-
source: '
|
|
10
|
+
source: `${apiBaseURL.replace(/\/$/, '')}/swagger/json?version=V31`,
|
|
7
11
|
},
|
|
8
12
|
modules: {},
|
|
9
13
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zova-cli",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.101",
|
|
4
4
|
"gitHead": "6f675a8cc46d596142c591c28a40cc4d82fcc6cc",
|
|
5
5
|
"description": "zova cli",
|
|
6
6
|
"keywords": [
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"@cabloy/process-helper": "^3.1.8",
|
|
45
45
|
"fs-extra": "^11.3.5",
|
|
46
46
|
"semver": "^7.6.2",
|
|
47
|
-
"zova-cli-set-front": "^1.2.
|
|
47
|
+
"zova-cli-set-front": "^1.2.99"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"clean-package": "^2.2.0",
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import type { ZovaOpenapiConfig } from 'zova-openapi';
|
|
2
2
|
|
|
3
3
|
export default function (): ZovaOpenapiConfig {
|
|
4
|
+
const apiBaseURL = process.env.API_BASE_URL;
|
|
5
|
+
if (!apiBaseURL) {
|
|
6
|
+
throw new Error('Missing API_BASE_URL');
|
|
7
|
+
}
|
|
4
8
|
return {
|
|
5
9
|
default: {
|
|
6
|
-
source: '
|
|
10
|
+
source: `${apiBaseURL.replace(/\/$/, '')}/swagger/json?version=V31`,
|
|
7
11
|
},
|
|
8
12
|
modules: {},
|
|
9
13
|
};
|
|
@@ -19,6 +19,8 @@ import path from 'node:path';
|
|
|
19
19
|
import { rimraf } from 'rimraf';
|
|
20
20
|
import ts from 'typescript';
|
|
21
21
|
|
|
22
|
+
import { loadZovaEnvs } from '../common/utils.ts';
|
|
23
|
+
|
|
22
24
|
declare module '@cabloy/cli' {
|
|
23
25
|
interface ICommandArgv {}
|
|
24
26
|
}
|
|
@@ -49,6 +51,12 @@ export class CliOpenapiGenerate extends BeanCliBase {
|
|
|
49
51
|
const { argv } = this.context;
|
|
50
52
|
// super
|
|
51
53
|
await super.execute();
|
|
54
|
+
// env
|
|
55
|
+
loadZovaEnvs(argv.projectPath, {
|
|
56
|
+
flavor: 'admin',
|
|
57
|
+
mode: 'development',
|
|
58
|
+
appMode: 'spa',
|
|
59
|
+
});
|
|
52
60
|
// config file
|
|
53
61
|
const configFile = path.join(argv.projectPath, 'openapi.config.ts');
|
|
54
62
|
if (!fse.existsSync(configFile)) {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import type { CmdOptions, NameMeta } from '@cabloy/cli';
|
|
2
|
-
import type { IModuleInfo
|
|
2
|
+
import type { IModuleInfo } from '@cabloy/module-info';
|
|
3
3
|
|
|
4
4
|
import { BeanCliBase } from '@cabloy/cli';
|
|
5
5
|
import fs from 'node:fs';
|
|
6
6
|
import path from 'node:path';
|
|
7
|
-
import { createConfigUtils } from 'zova-vite';
|
|
8
7
|
|
|
9
8
|
import { __ThisSetName__ } from '../this.ts';
|
|
9
|
+
import { loadZovaEnvs } from './utils.ts';
|
|
10
10
|
|
|
11
11
|
declare module '@cabloy/cli' {
|
|
12
12
|
interface ICommandArgv {
|
|
@@ -69,7 +69,11 @@ export class CliCreatePageBase extends BeanCliBase {
|
|
|
69
69
|
}
|
|
70
70
|
|
|
71
71
|
async logUrl(argv) {
|
|
72
|
-
const env =
|
|
72
|
+
const env = loadZovaEnvs(argv.projectPath, {
|
|
73
|
+
flavor: 'admin',
|
|
74
|
+
mode: 'development',
|
|
75
|
+
appMode: 'spa',
|
|
76
|
+
});
|
|
73
77
|
const host =
|
|
74
78
|
!env.DEV_SERVER_HOSTNAME || env.DEV_SERVER_HOSTNAME === 'true'
|
|
75
79
|
? 'localhost'
|
|
@@ -79,25 +83,4 @@ export class CliCreatePageBase extends BeanCliBase {
|
|
|
79
83
|
const message = `Page URL: ${url}`;
|
|
80
84
|
await this.console.log(message);
|
|
81
85
|
}
|
|
82
|
-
|
|
83
|
-
async loadEnvs() {
|
|
84
|
-
const configMeta: ZovaConfigMeta = {
|
|
85
|
-
flavor: 'admin',
|
|
86
|
-
mode: 'development',
|
|
87
|
-
appMode: 'spa',
|
|
88
|
-
};
|
|
89
|
-
const configOptions = {
|
|
90
|
-
appDir: process.cwd(),
|
|
91
|
-
runtimeDir: '.zova',
|
|
92
|
-
zovaManualChunk: {
|
|
93
|
-
debug: false,
|
|
94
|
-
vendors: [],
|
|
95
|
-
},
|
|
96
|
-
};
|
|
97
|
-
// config utils
|
|
98
|
-
const configUtils = createConfigUtils(configMeta, configOptions);
|
|
99
|
-
// env
|
|
100
|
-
const env = configUtils.loadEnvs();
|
|
101
|
-
return env;
|
|
102
|
-
}
|
|
103
86
|
}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import type { IModule } from '@cabloy/module-info';
|
|
1
|
+
import type { IModule, ZovaConfigMeta } from '@cabloy/module-info';
|
|
2
2
|
|
|
3
3
|
import fse from 'fs-extra';
|
|
4
4
|
import fs from 'node:fs';
|
|
5
5
|
import path from 'node:path';
|
|
6
6
|
import { pathToFileURL } from 'node:url';
|
|
7
|
+
import { createConfigUtils } from 'zova-vite';
|
|
7
8
|
|
|
8
9
|
export function getControllerFileName(module: IModule, type: 'page' | 'component', beanName) {
|
|
9
10
|
const controllerFile = path.join(module.root, `src/${type}/${beanName}/controller.ts`);
|
|
@@ -23,6 +24,14 @@ export function pathToHref(fileName: string): string {
|
|
|
23
24
|
return pathToFileURL(fileName).href;
|
|
24
25
|
}
|
|
25
26
|
|
|
27
|
+
export function loadZovaEnvs(appDir: string, configMeta: ZovaConfigMeta) {
|
|
28
|
+
const configUtils = createConfigUtils(configMeta, {
|
|
29
|
+
appDir,
|
|
30
|
+
runtimeDir: '.zova',
|
|
31
|
+
});
|
|
32
|
+
return configUtils.loadEnvs();
|
|
33
|
+
}
|
|
34
|
+
|
|
26
35
|
export async function loadJSONFile(fileName: string) {
|
|
27
36
|
const pkgContent = (await fse.readFile(fileName)).toString();
|
|
28
37
|
return JSON.parse(pkgContent);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zova-jsx",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.81",
|
|
4
4
|
"gitHead": "2c5c19284bab738e492856189acb6fad74b8a7b7",
|
|
5
5
|
"description": "Zova JSX",
|
|
6
6
|
"keywords": [
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"@cabloy/word-utils": "^2.1.14",
|
|
51
51
|
"typestyle": "^2.4.0",
|
|
52
52
|
"vue": "^3.5.38",
|
|
53
|
-
"zova-core": "^5.1.
|
|
53
|
+
"zova-core": "^5.1.81"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"clean-package": "^2.2.0",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zova",
|
|
3
|
-
"version": "5.1.
|
|
3
|
+
"version": "5.1.144",
|
|
4
4
|
"gitHead": "2c5c19284bab738e492856189acb6fad74b8a7b7",
|
|
5
5
|
"description": "A vue3 framework with ioc",
|
|
6
6
|
"keywords": [
|
|
@@ -45,8 +45,8 @@
|
|
|
45
45
|
"postpack": "clean-package restore"
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"zova-core": "^5.1.
|
|
49
|
-
"zova-suite-a-zova": "^5.1.
|
|
48
|
+
"zova-core": "^5.1.81",
|
|
49
|
+
"zova-suite-a-zova": "^5.1.143"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"clean-package": "^2.2.0",
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import 'vue';
|
|
2
2
|
import 'vue/jsx-runtime';
|
|
3
3
|
import '@vue/runtime-dom';
|
|
4
|
+
import type { VNode } from '@vue/runtime-dom';
|
|
4
5
|
|
|
5
6
|
declare module 'vue' {
|
|
6
7
|
export interface ComponentCustomOptions {
|
|
@@ -45,6 +46,10 @@ declare module 'vue/jsx-runtime' {
|
|
|
45
46
|
}
|
|
46
47
|
|
|
47
48
|
declare module '@vue/runtime-dom' {
|
|
49
|
+
export interface HTMLAttributes {
|
|
50
|
+
onVnodeMounted?: (vnode: VNode) => void;
|
|
51
|
+
}
|
|
52
|
+
|
|
48
53
|
export interface LabelHTMLAttributes {
|
|
49
54
|
htmlFor?: string;
|
|
50
55
|
}
|