@pisell/private-materials 6.12.337 → 6.12.342
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/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/preview.js +1 -1
- package/build/lowcode/render/default/view.js +3 -3
- package/build/lowcode/view.js +3 -3
- package/es/components/bigSale/components/BookingFloatingPanel/useBookingPanelController.js +0 -1
- package/es/components/bigSale/components/ProductList/index.js +49 -30
- package/es/components/bigSale/components/TimeBar/index.js +0 -1
- package/es/components/bigSale/dialog.js +0 -1
- package/es/components/bigSale/hooks/useBigSaleContext.js +0 -1
- package/es/components/bigSale/hooks/useSelectFloorMapResourceForBigSale.js +0 -1
- package/es/components/bigSale/index.js +0 -1
- package/es/components/bigSale/templates/Kiosk/index.js +0 -1
- package/es/components/list/List.js +17 -13
- package/es/components/list/types.d.ts +10 -0
- package/es/components/sharedSecondaryBigSale/SharedSecondaryBigSaleReceiver.js +0 -1
- package/es/components/shoppingCart/hooks/usePromotionModal.js +10 -5
- package/es/components/shoppingCart/hooks/useSkuModal.js +5 -2
- package/es/components/shoppingCart/server.js +6 -4
- package/es/index.js +0 -2
- package/es/plus/multiCurrencySettlement/index.js +1 -1
- package/es/plus/pisellReservation/data/bookingToReservationTables.js +1 -1
- package/es/plus/pisellReservation/floorMap/floorPlanApi.js +1 -1
- package/es/plus/pisellReservation/floorMap/reservationMock.js +1 -1
- package/es/plus/saasDevice/devicePasscodes/model.js +4 -4
- package/es/plus/saleDetail/Base.js +0 -1
- package/es/plus/saleDetail/components/Client/hooks/useClientSelectorProps.js +0 -1
- package/es/plus/saleDetail/components/DetailActions/PrintAction.js +0 -1
- package/es/plus/saleDetail/components/DetailActions/index.js +0 -1
- package/es/plus/saleDetail/components/SummaryFinancialSections/index.js +0 -1
- package/es/plus/saleDetail/index.js +0 -1
- package/es/plus/saleDetail/tmpl/B/components/Dish/index.js +0 -1
- package/es/plus/saleDetail/tmpl/B/components/Forms/index.less +51 -0
- package/es/plus/saleDetail/tmpl/B/index.js +0 -1
- package/es/plus/salesSdk/context/SalesSdkCartContext.js +2 -2
- package/es/plus/salesSdk/context/SalesSdkProvider.js +7 -2
- package/es/plus/salesSdk/giftSelect/buildGiftOrderProducts.js +6 -5
- package/es/plus/salesSdk/giftSelect/createOpenGiftSelectHost.js +5 -3
- package/es/plus/salesSdk/utils/addProductWithFlowDebounced.js +1 -1
- package/es/plus/salesSdk/utils/bookingDate.js +1 -1
- package/es/plus/salesSdk/utils/enrichCartLineHolderDisplay.js +1 -1
- package/es/plus/walletPassGallery/components/timelineSection/index.js +4 -4
- package/es/private-materials/lowcode/authmodal/meta.d.ts +1 -0
- package/es/pro/Login2.0/AuthModal.d.ts +1 -1
- package/es/pro/Login2.0/index.d.ts +2 -2
- package/es/pro/Login2.0/shared/types.d.ts +1 -1
- package/lib/components/bigSale/components/ProductList/index.js +49 -29
- package/lib/components/list/List.js +17 -13
- package/lib/components/list/types.d.ts +10 -0
- package/lib/components/shoppingCart/hooks/usePromotionModal.js +10 -5
- package/lib/components/shoppingCart/hooks/useSkuModal.js +5 -2
- package/lib/components/shoppingCart/server.js +6 -4
- package/lib/plus/saleDetail/tmpl/B/components/Forms/index.less +51 -0
- package/lib/plus/salesSdk/context/SalesSdkCartContext.js +2 -2
- package/lib/plus/salesSdk/context/SalesSdkProvider.js +7 -2
- package/lib/plus/salesSdk/giftSelect/buildGiftOrderProducts.js +6 -5
- package/lib/plus/salesSdk/giftSelect/createOpenGiftSelectHost.js +5 -3
- package/lowcode/allergy-selection-modal/meta.ts +451 -0
- package/lowcode/huifu-kiosk-panel/meta.ts +351 -0
- package/lowcode/pos-permission/meta.ts +233 -0
- package/package.json +3 -3
- package/es/plus/pisellReservation/index.js +0 -17
- package/es/plus/salesSdk/index.js +0 -54
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
@forms-prefix: pisell-sale-detail-forms;
|
|
2
|
+
|
|
3
|
+
.pisell-sale-detail-forms-main {
|
|
4
|
+
padding: 8px 10px;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.@{forms-prefix} {
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-direction: column;
|
|
10
|
+
gap: 8px;
|
|
11
|
+
width: 100%;
|
|
12
|
+
min-height: 0;
|
|
13
|
+
overflow: auto;
|
|
14
|
+
|
|
15
|
+
&__card {
|
|
16
|
+
padding: 12px;
|
|
17
|
+
border: 1px solid rgba(93, 112, 157, 0.72);
|
|
18
|
+
border-radius: 8px;
|
|
19
|
+
background: #080d18;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
&__header {
|
|
23
|
+
display: flex;
|
|
24
|
+
align-items: center;
|
|
25
|
+
gap: 8px;
|
|
26
|
+
min-width: 0;
|
|
27
|
+
margin-bottom: 10px;
|
|
28
|
+
color: #f5f7ff;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
&__booking-id {
|
|
32
|
+
flex: none;
|
|
33
|
+
font-size: 14px;
|
|
34
|
+
font-weight: 800;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
&__resource {
|
|
38
|
+
overflow: hidden;
|
|
39
|
+
color: rgba(234, 240, 255, 0.72);
|
|
40
|
+
font-size: 13px;
|
|
41
|
+
text-overflow: ellipsis;
|
|
42
|
+
white-space: nowrap;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
&__empty {
|
|
46
|
+
display: flex;
|
|
47
|
+
align-items: center;
|
|
48
|
+
justify-content: center;
|
|
49
|
+
min-height: 220px;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
@@ -1961,7 +1961,7 @@ const SalesSdkCartProvider = ({ children, normalProductDetailConfig, deferHolder
|
|
|
1961
1961
|
*/
|
|
1962
1962
|
const selectGiftForItem = (0, ahooks.useMemoizedFn)(function() {
|
|
1963
1963
|
var _ref43 = require_asyncToGenerator._asyncToGenerator(function* (target) {
|
|
1964
|
-
var _mainItem$metadata, _mainItem$metadata2, _giftInfo$giftOptions, _promotion$strategyMe, _mainItem$giftData, _mainItem$giftData2;
|
|
1964
|
+
var _mainItem$metadata, _mainItem$metadata2, _giftInfo$giftOptions, _promotion$strategyMe, _mainItem$giftData, _mainItem$giftData2, _engineContext$appHel;
|
|
1965
1965
|
if (!bookingTicket) throw new Error("[SalesSdk] Cart: bookingTicket 未初始化");
|
|
1966
1966
|
const mainItem = require_editCartLine.resolveEditCartLineTarget(target, snapshot.items);
|
|
1967
1967
|
const promotion = (_mainItem$metadata = mainItem.metadata) === null || _mainItem$metadata === void 0 ? void 0 : _mainItem$metadata._promotion;
|
|
@@ -1984,7 +1984,7 @@ const SalesSdkCartProvider = ({ children, normalProductDetailConfig, deferHolder
|
|
|
1984
1984
|
};
|
|
1985
1985
|
const choices = yield hostBridges.giftSelect.request(ctx);
|
|
1986
1986
|
if (!(choices === null || choices === void 0 ? void 0 : choices.length)) return;
|
|
1987
|
-
yield require_createOpenGiftSelectHost.replaceStrategyGiftsForMainItem(bookingTicket, mainItem, choices);
|
|
1987
|
+
yield require_createOpenGiftSelectHost.replaceStrategyGiftsForMainItem(bookingTicket, mainItem, choices, engineContext === null || engineContext === void 0 || (_engineContext$appHel = engineContext.appHelper) === null || _engineContext$appHel === void 0 || (_engineContext$appHel = _engineContext$appHel.constants) === null || _engineContext$appHel === void 0 ? void 0 : _engineContext$appHel.apiPrefix);
|
|
1988
1988
|
yield syncCartAfterMutation();
|
|
1989
1989
|
});
|
|
1990
1990
|
return function(_x41) {
|
|
@@ -246,7 +246,7 @@ function SalesSdkBootstrap({ bootstrapKey, onSettled, autoRestoreOnInit, autoBoo
|
|
|
246
246
|
return null;
|
|
247
247
|
}
|
|
248
248
|
const SalesSdkProvider = ({ osKey, enableMultiCurrencySettlement = false, solution = "bookingTicket", moduleAccess = "ensure", lifecycleOwner = "provider", businessCode, bookingConfigParams, autoInitBookingContext = true, otherParams, deferHolderAuthOnClose = false, enableCustomerAuthHost = false, shouldMergeProductLines, rulesHooks, orderId, preloadedSalesDetail, autoBootstrap = true, autoRestoreOnInit = true, restoreOrderAfterPaidCheckout = true, destroyOnUnmount = true, uiHosts, awaitAllergyConfirmation, normalProductDetailConfig, mergeBookingLinesForDisplay = true, legacyOpenProductDetail, enableTempOrderSync = false, enableTempOrderPersist = false, syncDetailOnOrderChange = false, isActive = true, preserveProductCatalogOnInactiveCustomerClear = false, enableGlobalScanListener = false, suppressCartIneligibleScanToast = false, promotionScanSuccessMessageKey, promotionItemIncreaseMessageKey, defaultProductLoadParams, children }) => {
|
|
249
|
-
var _context$appHelper, _osKey$replace;
|
|
249
|
+
var _context$appHelper, _osKey$replace, _context$appHelper3;
|
|
250
250
|
const context = require_useEngineContext.default();
|
|
251
251
|
const utils = (context === null || context === void 0 || (_context$appHelper = context.appHelper) === null || _context$appHelper === void 0 ? void 0 : _context$appHelper.utils) || {};
|
|
252
252
|
const Toast = (0, _pisell_materials.useToast)();
|
|
@@ -1475,7 +1475,11 @@ const SalesSdkProvider = ({ osKey, enableMultiCurrencySettlement = false, soluti
|
|
|
1475
1475
|
bookingTicket.setPromotionEvaluator((_utils$promotionEvalu = utils === null || utils === void 0 ? void 0 : utils.promotionEvaluator) !== null && _utils$promotionEvalu !== void 0 ? _utils$promotionEvalu : null);
|
|
1476
1476
|
}
|
|
1477
1477
|
if (typeof bookingTicket.setGiftSelectResolver === "function") {
|
|
1478
|
-
|
|
1478
|
+
var _context$appHelper2;
|
|
1479
|
+
const resolver = require_createOpenGiftSelectHost.createOpenGiftSelectHost(hostBridges.giftSelect, () => bookingTicketRef.current, {
|
|
1480
|
+
getUiHosts: () => uiHostsValue,
|
|
1481
|
+
apiPrefix: context === null || context === void 0 || (_context$appHelper2 = context.appHelper) === null || _context$appHelper2 === void 0 || (_context$appHelper2 = _context$appHelper2.constants) === null || _context$appHelper2 === void 0 ? void 0 : _context$appHelper2.apiPrefix
|
|
1482
|
+
});
|
|
1479
1483
|
bookingTicket.setGiftSelectResolver(resolver);
|
|
1480
1484
|
}
|
|
1481
1485
|
return () => {
|
|
@@ -1485,6 +1489,7 @@ const SalesSdkProvider = ({ osKey, enableMultiCurrencySettlement = false, soluti
|
|
|
1485
1489
|
}, [
|
|
1486
1490
|
bookingTicket,
|
|
1487
1491
|
utils === null || utils === void 0 ? void 0 : utils.promotionEvaluator,
|
|
1492
|
+
context === null || context === void 0 || (_context$appHelper3 = context.appHelper) === null || _context$appHelper3 === void 0 || (_context$appHelper3 = _context$appHelper3.constants) === null || _context$appHelper3 === void 0 ? void 0 : _context$appHelper3.apiPrefix,
|
|
1488
1493
|
hostBridges.giftSelect,
|
|
1489
1494
|
uiHostsValue
|
|
1490
1495
|
]);
|
|
@@ -239,11 +239,11 @@ function collectMissingProductIds(choices, productMap) {
|
|
|
239
239
|
* @example
|
|
240
240
|
* const map = await fetchGiftProductMap([{ product_id: 1, product_variant_id: 0, quantity: 1 }]);
|
|
241
241
|
*/
|
|
242
|
-
function fetchGiftProductMap(_x) {
|
|
242
|
+
function fetchGiftProductMap(_x, _x2) {
|
|
243
243
|
return _fetchGiftProductMap.apply(this, arguments);
|
|
244
244
|
}
|
|
245
245
|
function _fetchGiftProductMap() {
|
|
246
|
-
_fetchGiftProductMap = require_asyncToGenerator._asyncToGenerator(function* (productIds) {
|
|
246
|
+
_fetchGiftProductMap = require_asyncToGenerator._asyncToGenerator(function* (productIds, apiPrefix) {
|
|
247
247
|
const ids = Array.from(new Set(productIds.filter((id) => Number.isFinite(id) && id > 0)));
|
|
248
248
|
if (!ids.length) return /* @__PURE__ */ new Map();
|
|
249
249
|
const map = /* @__PURE__ */ new Map();
|
|
@@ -256,7 +256,8 @@ function _fetchGiftProductMap() {
|
|
|
256
256
|
if (!missingIds.length) return map;
|
|
257
257
|
((yield require_server.getProducts({
|
|
258
258
|
ids: missingIds,
|
|
259
|
-
isGift: true
|
|
259
|
+
isGift: true,
|
|
260
|
+
apiPrefix
|
|
260
261
|
})) || []).forEach((p) => {
|
|
261
262
|
const id = resolveProductId(p);
|
|
262
263
|
if (!id) return;
|
|
@@ -274,7 +275,7 @@ function _fetchGiftProductMap() {
|
|
|
274
275
|
* @example
|
|
275
276
|
* const lines = await buildGiftOrderProductsFromChoices(choices, ctx, (ids) => ticket.getProductByIds(ids));
|
|
276
277
|
*/
|
|
277
|
-
function buildGiftOrderProductsFromChoices(
|
|
278
|
+
function buildGiftOrderProductsFromChoices(_x3, _x4, _x5) {
|
|
278
279
|
return _buildGiftOrderProductsFromChoices.apply(this, arguments);
|
|
279
280
|
}
|
|
280
281
|
function _buildGiftOrderProductsFromChoices() {
|
|
@@ -296,7 +297,7 @@ function _buildGiftOrderProductsFromChoices() {
|
|
|
296
297
|
}
|
|
297
298
|
missingIds = collectMissingProductIds(choices, productMap);
|
|
298
299
|
if (missingIds.length) try {
|
|
299
|
-
(yield fetchGiftProductMap(missingIds)).forEach((product, id) => {
|
|
300
|
+
(yield fetchGiftProductMap(missingIds, options === null || options === void 0 ? void 0 : options.apiPrefix)).forEach((product, id) => {
|
|
300
301
|
if (!productMap.has(id)) productMap.set(id, product);
|
|
301
302
|
});
|
|
302
303
|
} catch (error) {
|
|
@@ -91,7 +91,7 @@ function createOpenGiftSelectHost(bridge, getBookingTicket, options) {
|
|
|
91
91
|
const option = ctx.giftOptions[0];
|
|
92
92
|
const products = yield (_bookingTicket$getPro = bookingTicket.getProductByIds) === null || _bookingTicket$getPro === void 0 ? void 0 : _bookingTicket$getPro.call(bookingTicket, [Number(option.product_id)]);
|
|
93
93
|
let product = products === null || products === void 0 ? void 0 : products[0];
|
|
94
|
-
if (!product) product = (yield require_buildGiftOrderProducts.fetchGiftProductMap([Number(option.product_id)])).get(Number(option.product_id));
|
|
94
|
+
if (!product) product = (yield require_buildGiftOrderProducts.fetchGiftProductMap([Number(option.product_id)], options === null || options === void 0 ? void 0 : options.apiPrefix)).get(Number(option.product_id));
|
|
95
95
|
if (isBookingGiftCandidate(product)) {
|
|
96
96
|
var _options$getUiHosts;
|
|
97
97
|
const choice = yield resolveSingleBookingGiftChoice(product, option, ctx, bookingTicket, options === null || options === void 0 || (_options$getUiHosts = options.getUiHosts) === null || _options$getUiHosts === void 0 ? void 0 : _options$getUiHosts.call(options));
|
|
@@ -114,6 +114,7 @@ function createOpenGiftSelectHost(bridge, getBookingTicket, options) {
|
|
|
114
114
|
if (!choices) return null;
|
|
115
115
|
return require_buildGiftOrderProducts.buildGiftOrderProductsFromChoices(choices, ctx, {
|
|
116
116
|
bookingTicket,
|
|
117
|
+
apiPrefix: options === null || options === void 0 ? void 0 : options.apiPrefix,
|
|
117
118
|
fallbackFetcher: (ids) => {
|
|
118
119
|
var _bookingTicket$getPro2, _bookingTicket$getPro3;
|
|
119
120
|
return (_bookingTicket$getPro2 = (_bookingTicket$getPro3 = bookingTicket.getProductByIds) === null || _bookingTicket$getPro3 === void 0 ? void 0 : _bookingTicket$getPro3.call(bookingTicket, ids)) !== null && _bookingTicket$getPro2 !== void 0 ? _bookingTicket$getPro2 : Promise.resolve([]);
|
|
@@ -132,11 +133,11 @@ function createOpenGiftSelectHost(bridge, getBookingTicket, options) {
|
|
|
132
133
|
* @example
|
|
133
134
|
* await replaceStrategyGiftsForMainItem(bookingTicket, mainItem, choices);
|
|
134
135
|
*/
|
|
135
|
-
function replaceStrategyGiftsForMainItem(_x7, _x8, _x9) {
|
|
136
|
+
function replaceStrategyGiftsForMainItem(_x7, _x8, _x9, _x10) {
|
|
136
137
|
return _replaceStrategyGiftsForMainItem.apply(this, arguments);
|
|
137
138
|
}
|
|
138
139
|
function _replaceStrategyGiftsForMainItem() {
|
|
139
|
-
_replaceStrategyGiftsForMainItem = require_asyncToGenerator._asyncToGenerator(function* (bookingTicket, mainItem, choices) {
|
|
140
|
+
_replaceStrategyGiftsForMainItem = require_asyncToGenerator._asyncToGenerator(function* (bookingTicket, mainItem, choices, apiPrefix) {
|
|
140
141
|
var _mainItem$metadata, _mainItem$metadata2, _giftInfo$giftOptions, _promotion$strategyMe, _bookingTicket$getTem3;
|
|
141
142
|
const sourceUid = (_mainItem$metadata = mainItem.metadata) === null || _mainItem$metadata === void 0 ? void 0 : _mainItem$metadata.unique_identification_number;
|
|
142
143
|
const promotion = (_mainItem$metadata2 = mainItem.metadata) === null || _mainItem$metadata2 === void 0 ? void 0 : _mainItem$metadata2._promotion;
|
|
@@ -162,6 +163,7 @@ function _replaceStrategyGiftsForMainItem() {
|
|
|
162
163
|
});
|
|
163
164
|
const newGifts = yield require_buildGiftOrderProducts.buildGiftOrderProductsFromChoices(choices, ctx, {
|
|
164
165
|
bookingTicket,
|
|
166
|
+
apiPrefix,
|
|
165
167
|
fallbackFetcher: (ids) => {
|
|
166
168
|
var _bookingTicket$getPro4, _bookingTicket$getPro5;
|
|
167
169
|
return (_bookingTicket$getPro4 = (_bookingTicket$getPro5 = bookingTicket.getProductByIds) === null || _bookingTicket$getPro5 === void 0 ? void 0 : _bookingTicket$getPro5.call(bookingTicket, ids)) !== null && _bookingTicket$getPro4 !== void 0 ? _bookingTicket$getPro4 : Promise.resolve([]);
|
|
@@ -0,0 +1,451 @@
|
|
|
1
|
+
|
|
2
|
+
import { ComponentMetadata, Snippet } from '@alilc/lowcode-types';
|
|
3
|
+
|
|
4
|
+
const AllergySelectionModalMeta: ComponentMetadata = {
|
|
5
|
+
"componentName": "AllergySelectionModal",
|
|
6
|
+
"title": "AllergySelectionModal",
|
|
7
|
+
"docUrl": "",
|
|
8
|
+
"screenshot": "",
|
|
9
|
+
"devMode": "proCode",
|
|
10
|
+
"npm": {
|
|
11
|
+
"package": "@pisell/private-materials",
|
|
12
|
+
"version": "1.10.81",
|
|
13
|
+
"exportName": "AllergySelectionModal",
|
|
14
|
+
"main": "src/index.ts",
|
|
15
|
+
"destructuring": true,
|
|
16
|
+
"subName": ""
|
|
17
|
+
},
|
|
18
|
+
"configure": {
|
|
19
|
+
"props": [
|
|
20
|
+
{
|
|
21
|
+
"title": {
|
|
22
|
+
"label": {
|
|
23
|
+
"type": "i18n",
|
|
24
|
+
"en-US": "requirement",
|
|
25
|
+
"zh-CN": "requirement"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"name": "requirement",
|
|
29
|
+
"setter": {
|
|
30
|
+
"componentName": "ObjectSetter",
|
|
31
|
+
"props": {
|
|
32
|
+
"config": {
|
|
33
|
+
"items": [
|
|
34
|
+
{
|
|
35
|
+
"title": {
|
|
36
|
+
"label": {
|
|
37
|
+
"type": "i18n",
|
|
38
|
+
"en-US": "strategyId",
|
|
39
|
+
"zh-CN": "strategyId"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"name": "strategyId",
|
|
43
|
+
"setter": {
|
|
44
|
+
"componentName": "StringSetter",
|
|
45
|
+
"isRequired": true,
|
|
46
|
+
"initialValue": ""
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"title": {
|
|
51
|
+
"label": {
|
|
52
|
+
"type": "i18n",
|
|
53
|
+
"en-US": "ruleId",
|
|
54
|
+
"zh-CN": "ruleId"
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
"name": "ruleId",
|
|
58
|
+
"setter": {
|
|
59
|
+
"componentName": "StringSetter",
|
|
60
|
+
"isRequired": true,
|
|
61
|
+
"initialValue": ""
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"title": {
|
|
66
|
+
"label": {
|
|
67
|
+
"type": "i18n",
|
|
68
|
+
"en-US": "priority",
|
|
69
|
+
"zh-CN": "priority"
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"name": "priority",
|
|
73
|
+
"setter": {
|
|
74
|
+
"componentName": "NumberSetter",
|
|
75
|
+
"isRequired": true,
|
|
76
|
+
"initialValue": 0
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
"title": {
|
|
81
|
+
"label": {
|
|
82
|
+
"type": "i18n",
|
|
83
|
+
"en-US": "targetType",
|
|
84
|
+
"zh-CN": "targetType"
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
"name": "targetType",
|
|
88
|
+
"setter": {
|
|
89
|
+
"componentName": "RadioGroupSetter",
|
|
90
|
+
"props": {
|
|
91
|
+
"dataSource": [
|
|
92
|
+
{
|
|
93
|
+
"label": "product",
|
|
94
|
+
"value": "product"
|
|
95
|
+
}
|
|
96
|
+
],
|
|
97
|
+
"options": [
|
|
98
|
+
{
|
|
99
|
+
"label": "product",
|
|
100
|
+
"value": "product"
|
|
101
|
+
}
|
|
102
|
+
]
|
|
103
|
+
},
|
|
104
|
+
"isRequired": true,
|
|
105
|
+
"initialValue": "product"
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
"title": {
|
|
110
|
+
"label": {
|
|
111
|
+
"type": "i18n",
|
|
112
|
+
"en-US": "product_id",
|
|
113
|
+
"zh-CN": "product_id"
|
|
114
|
+
}
|
|
115
|
+
},
|
|
116
|
+
"name": "product_id",
|
|
117
|
+
"setter": {
|
|
118
|
+
"componentName": "NumberSetter",
|
|
119
|
+
"isRequired": true,
|
|
120
|
+
"initialValue": 0
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
"title": {
|
|
125
|
+
"label": {
|
|
126
|
+
"type": "i18n",
|
|
127
|
+
"en-US": "product_variant_id",
|
|
128
|
+
"zh-CN": "product_variant_id"
|
|
129
|
+
}
|
|
130
|
+
},
|
|
131
|
+
"name": "product_variant_id",
|
|
132
|
+
"setter": {
|
|
133
|
+
"componentName": "MixedSetter",
|
|
134
|
+
"props": {
|
|
135
|
+
"setters": [
|
|
136
|
+
{
|
|
137
|
+
"componentName": "ObjectSetter",
|
|
138
|
+
"props": {
|
|
139
|
+
"config": {
|
|
140
|
+
"extraSetter": {
|
|
141
|
+
"componentName": "MixedSetter",
|
|
142
|
+
"isRequired": false,
|
|
143
|
+
"props": {}
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"isRequired": false,
|
|
148
|
+
"initialValue": {}
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
"componentName": "NumberSetter",
|
|
152
|
+
"isRequired": false,
|
|
153
|
+
"initialValue": 0
|
|
154
|
+
}
|
|
155
|
+
]
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
"title": {
|
|
161
|
+
"label": {
|
|
162
|
+
"type": "i18n",
|
|
163
|
+
"en-US": "dataSource",
|
|
164
|
+
"zh-CN": "dataSource"
|
|
165
|
+
}
|
|
166
|
+
},
|
|
167
|
+
"name": "dataSource",
|
|
168
|
+
"setter": {
|
|
169
|
+
"componentName": "ObjectSetter",
|
|
170
|
+
"props": {
|
|
171
|
+
"config": {
|
|
172
|
+
"items": [
|
|
173
|
+
{
|
|
174
|
+
"title": {
|
|
175
|
+
"label": {
|
|
176
|
+
"type": "i18n",
|
|
177
|
+
"en-US": "type",
|
|
178
|
+
"zh-CN": "type"
|
|
179
|
+
}
|
|
180
|
+
},
|
|
181
|
+
"name": "type",
|
|
182
|
+
"setter": {
|
|
183
|
+
"componentName": "RadioGroupSetter",
|
|
184
|
+
"props": {
|
|
185
|
+
"dataSource": [
|
|
186
|
+
{
|
|
187
|
+
"label": "inline",
|
|
188
|
+
"value": "inline"
|
|
189
|
+
}
|
|
190
|
+
],
|
|
191
|
+
"options": [
|
|
192
|
+
{
|
|
193
|
+
"label": "inline",
|
|
194
|
+
"value": "inline"
|
|
195
|
+
}
|
|
196
|
+
]
|
|
197
|
+
},
|
|
198
|
+
"isRequired": true,
|
|
199
|
+
"initialValue": "inline"
|
|
200
|
+
}
|
|
201
|
+
},
|
|
202
|
+
{
|
|
203
|
+
"title": {
|
|
204
|
+
"label": {
|
|
205
|
+
"type": "i18n",
|
|
206
|
+
"en-US": "items",
|
|
207
|
+
"zh-CN": "items"
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
"name": "items",
|
|
211
|
+
"setter": {
|
|
212
|
+
"componentName": "ArraySetter",
|
|
213
|
+
"props": {
|
|
214
|
+
"itemSetter": {
|
|
215
|
+
"componentName": "ObjectSetter",
|
|
216
|
+
"props": {
|
|
217
|
+
"config": {
|
|
218
|
+
"items": [
|
|
219
|
+
{
|
|
220
|
+
"title": {
|
|
221
|
+
"label": {
|
|
222
|
+
"type": "i18n",
|
|
223
|
+
"en-US": "id",
|
|
224
|
+
"zh-CN": "id"
|
|
225
|
+
}
|
|
226
|
+
},
|
|
227
|
+
"name": "id",
|
|
228
|
+
"setter": {
|
|
229
|
+
"componentName": "StringSetter",
|
|
230
|
+
"isRequired": true,
|
|
231
|
+
"initialValue": ""
|
|
232
|
+
}
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
"title": {
|
|
236
|
+
"label": {
|
|
237
|
+
"type": "i18n",
|
|
238
|
+
"en-US": "label",
|
|
239
|
+
"zh-CN": "label"
|
|
240
|
+
}
|
|
241
|
+
},
|
|
242
|
+
"name": "label",
|
|
243
|
+
"setter": {
|
|
244
|
+
"componentName": "MixedSetter",
|
|
245
|
+
"props": {
|
|
246
|
+
"setters": [
|
|
247
|
+
{
|
|
248
|
+
"componentName": "StringSetter",
|
|
249
|
+
"isRequired": false,
|
|
250
|
+
"initialValue": ""
|
|
251
|
+
},
|
|
252
|
+
{
|
|
253
|
+
"componentName": "ObjectSetter",
|
|
254
|
+
"props": {
|
|
255
|
+
"config": {
|
|
256
|
+
"extraSetter": {
|
|
257
|
+
"componentName": "StringSetter",
|
|
258
|
+
"isRequired": false,
|
|
259
|
+
"initialValue": ""
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
},
|
|
263
|
+
"initialValue": {}
|
|
264
|
+
}
|
|
265
|
+
]
|
|
266
|
+
},
|
|
267
|
+
"isRequired": true
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
],
|
|
271
|
+
"extraSetter": {
|
|
272
|
+
"componentName": "MixedSetter",
|
|
273
|
+
"isRequired": false,
|
|
274
|
+
"props": {}
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
},
|
|
280
|
+
"isRequired": true,
|
|
281
|
+
"initialValue": []
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
],
|
|
285
|
+
"extraSetter": {
|
|
286
|
+
"componentName": "MixedSetter",
|
|
287
|
+
"isRequired": false,
|
|
288
|
+
"props": {}
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
},
|
|
292
|
+
"isRequired": true
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
"title": {
|
|
297
|
+
"label": {
|
|
298
|
+
"type": "i18n",
|
|
299
|
+
"en-US": "promptScope",
|
|
300
|
+
"zh-CN": "promptScope"
|
|
301
|
+
}
|
|
302
|
+
},
|
|
303
|
+
"name": "promptScope",
|
|
304
|
+
"setter": {
|
|
305
|
+
"componentName": "RadioGroupSetter",
|
|
306
|
+
"props": {
|
|
307
|
+
"dataSource": [
|
|
308
|
+
{
|
|
309
|
+
"label": "once_per_order_product",
|
|
310
|
+
"value": "once_per_order_product"
|
|
311
|
+
}
|
|
312
|
+
],
|
|
313
|
+
"options": [
|
|
314
|
+
{
|
|
315
|
+
"label": "once_per_order_product",
|
|
316
|
+
"value": "once_per_order_product"
|
|
317
|
+
}
|
|
318
|
+
]
|
|
319
|
+
},
|
|
320
|
+
"isRequired": true,
|
|
321
|
+
"initialValue": "once_per_order_product"
|
|
322
|
+
}
|
|
323
|
+
},
|
|
324
|
+
{
|
|
325
|
+
"title": {
|
|
326
|
+
"label": {
|
|
327
|
+
"type": "i18n",
|
|
328
|
+
"en-US": "allowNote",
|
|
329
|
+
"zh-CN": "allowNote"
|
|
330
|
+
}
|
|
331
|
+
},
|
|
332
|
+
"name": "allowNote",
|
|
333
|
+
"setter": {
|
|
334
|
+
"componentName": "BoolSetter",
|
|
335
|
+
"isRequired": true,
|
|
336
|
+
"initialValue": false
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
],
|
|
340
|
+
"extraSetter": {
|
|
341
|
+
"componentName": "MixedSetter",
|
|
342
|
+
"isRequired": false,
|
|
343
|
+
"props": {}
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
},
|
|
347
|
+
"isRequired": true
|
|
348
|
+
}
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
"title": {
|
|
352
|
+
"label": {
|
|
353
|
+
"type": "i18n",
|
|
354
|
+
"en-US": "locale",
|
|
355
|
+
"zh-CN": "locale"
|
|
356
|
+
}
|
|
357
|
+
},
|
|
358
|
+
"name": "locale",
|
|
359
|
+
"setter": {
|
|
360
|
+
"componentName": "StringSetter",
|
|
361
|
+
"isRequired": true,
|
|
362
|
+
"initialValue": ""
|
|
363
|
+
}
|
|
364
|
+
},
|
|
365
|
+
{
|
|
366
|
+
"title": {
|
|
367
|
+
"label": {
|
|
368
|
+
"type": "i18n",
|
|
369
|
+
"en-US": "pending",
|
|
370
|
+
"zh-CN": "pending"
|
|
371
|
+
}
|
|
372
|
+
},
|
|
373
|
+
"name": "pending",
|
|
374
|
+
"setter": {
|
|
375
|
+
"componentName": "BoolSetter",
|
|
376
|
+
"isRequired": true,
|
|
377
|
+
"initialValue": false
|
|
378
|
+
}
|
|
379
|
+
},
|
|
380
|
+
{
|
|
381
|
+
"title": {
|
|
382
|
+
"label": {
|
|
383
|
+
"type": "i18n",
|
|
384
|
+
"en-US": "error",
|
|
385
|
+
"zh-CN": "error"
|
|
386
|
+
}
|
|
387
|
+
},
|
|
388
|
+
"name": "error",
|
|
389
|
+
"setter": {
|
|
390
|
+
"componentName": "MixedSetter",
|
|
391
|
+
"props": {
|
|
392
|
+
"setters": [
|
|
393
|
+
{
|
|
394
|
+
"componentName": "ObjectSetter",
|
|
395
|
+
"props": {
|
|
396
|
+
"config": {
|
|
397
|
+
"extraSetter": {
|
|
398
|
+
"componentName": "MixedSetter",
|
|
399
|
+
"isRequired": false,
|
|
400
|
+
"props": {}
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
},
|
|
404
|
+
"isRequired": false,
|
|
405
|
+
"initialValue": {}
|
|
406
|
+
},
|
|
407
|
+
{
|
|
408
|
+
"componentName": "StringSetter",
|
|
409
|
+
"isRequired": false,
|
|
410
|
+
"initialValue": ""
|
|
411
|
+
}
|
|
412
|
+
]
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
},
|
|
416
|
+
{
|
|
417
|
+
"title": {
|
|
418
|
+
"label": {
|
|
419
|
+
"type": "i18n",
|
|
420
|
+
"en-US": "onSubmit",
|
|
421
|
+
"zh-CN": "onSubmit"
|
|
422
|
+
}
|
|
423
|
+
},
|
|
424
|
+
"name": "onSubmit",
|
|
425
|
+
"setter": {
|
|
426
|
+
"componentName": "FunctionSetter",
|
|
427
|
+
"isRequired": true
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
],
|
|
431
|
+
"supports": {
|
|
432
|
+
"style": true
|
|
433
|
+
},
|
|
434
|
+
"component": {}
|
|
435
|
+
}
|
|
436
|
+
};
|
|
437
|
+
const snippets: Snippet[] = [
|
|
438
|
+
{
|
|
439
|
+
"title": "AllergySelectionModal",
|
|
440
|
+
"screenshot": "",
|
|
441
|
+
"schema": {
|
|
442
|
+
"componentName": "AllergySelectionModal",
|
|
443
|
+
"props": {}
|
|
444
|
+
}
|
|
445
|
+
}
|
|
446
|
+
];
|
|
447
|
+
|
|
448
|
+
export default {
|
|
449
|
+
...AllergySelectionModalMeta,
|
|
450
|
+
snippets
|
|
451
|
+
};
|