@bit-sun/business-component 1.1.27 → 1.1.28
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/dist/index.esm.js +34 -21
- package/dist/index.js +34 -21
- package/package.json +1 -1
- package/src/components/Functional/SearchSelect/index.tsx +2 -1
package/dist/index.esm.js
CHANGED
|
@@ -294,9 +294,10 @@ function ownKeys$1(object, enumerableOnly) {
|
|
|
294
294
|
|
|
295
295
|
if (Object.getOwnPropertySymbols) {
|
|
296
296
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
297
|
-
enumerableOnly
|
|
297
|
+
if (enumerableOnly) symbols = symbols.filter(function (sym) {
|
|
298
298
|
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
299
|
-
})
|
|
299
|
+
});
|
|
300
|
+
keys.push.apply(keys, symbols);
|
|
300
301
|
}
|
|
301
302
|
|
|
302
303
|
return keys;
|
|
@@ -304,12 +305,19 @@ function ownKeys$1(object, enumerableOnly) {
|
|
|
304
305
|
|
|
305
306
|
function _objectSpread2$1(target) {
|
|
306
307
|
for (var i = 1; i < arguments.length; i++) {
|
|
307
|
-
var source =
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
308
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
309
|
+
|
|
310
|
+
if (i % 2) {
|
|
311
|
+
ownKeys$1(Object(source), true).forEach(function (key) {
|
|
312
|
+
_defineProperty$1(target, key, source[key]);
|
|
313
|
+
});
|
|
314
|
+
} else if (Object.getOwnPropertyDescriptors) {
|
|
315
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
316
|
+
} else {
|
|
317
|
+
ownKeys$1(Object(source)).forEach(function (key) {
|
|
318
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
319
|
+
});
|
|
320
|
+
}
|
|
313
321
|
}
|
|
314
322
|
|
|
315
323
|
return target;
|
|
@@ -320,17 +328,14 @@ function _arrayWithHoles$1(arr) {
|
|
|
320
328
|
}
|
|
321
329
|
|
|
322
330
|
function _iterableToArrayLimit$1(arr, i) {
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
if (_i == null) return;
|
|
331
|
+
if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
|
|
326
332
|
var _arr = [];
|
|
327
333
|
var _n = true;
|
|
328
334
|
var _d = false;
|
|
329
|
-
|
|
330
|
-
var _s, _e;
|
|
335
|
+
var _e = undefined;
|
|
331
336
|
|
|
332
337
|
try {
|
|
333
|
-
for (_i =
|
|
338
|
+
for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
|
|
334
339
|
_arr.push(_s.value);
|
|
335
340
|
|
|
336
341
|
if (i && _arr.length === i) break;
|
|
@@ -413,11 +418,17 @@ function _objectWithoutProperties$1(source, excluded) {
|
|
|
413
418
|
function _typeof(obj) {
|
|
414
419
|
"@babel/helpers - typeof";
|
|
415
420
|
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
}
|
|
421
|
+
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
422
|
+
_typeof = function _typeof(obj) {
|
|
423
|
+
return typeof obj;
|
|
424
|
+
};
|
|
425
|
+
} else {
|
|
426
|
+
_typeof = function _typeof(obj) {
|
|
427
|
+
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
428
|
+
};
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
return _typeof(obj);
|
|
421
432
|
}
|
|
422
433
|
|
|
423
434
|
/**
|
|
@@ -2407,7 +2418,9 @@ var SearchSelect = function SearchSelect(props) {
|
|
|
2407
2418
|
ctx = props.ctx,
|
|
2408
2419
|
sourceName = props.sourceName,
|
|
2409
2420
|
_props$needModalTable = props.needModalTable,
|
|
2410
|
-
needModalTable = _props$needModalTable === void 0 ? true : _props$needModalTable
|
|
2421
|
+
needModalTable = _props$needModalTable === void 0 ? true : _props$needModalTable,
|
|
2422
|
+
_props$getPopupContai = props.getPopupContainer,
|
|
2423
|
+
_getPopupContainer = _props$getPopupContai === void 0 ? undefined : _props$getPopupContai;
|
|
2411
2424
|
|
|
2412
2425
|
var _ref = requestConfig || {},
|
|
2413
2426
|
url = _ref.url,
|
|
@@ -3150,7 +3163,7 @@ var SearchSelect = function SearchSelect(props) {
|
|
|
3150
3163
|
maxTagPlaceholder: maxTagPlaceholder
|
|
3151
3164
|
}, currentSelectProps), {}, {
|
|
3152
3165
|
getPopupContainer: function getPopupContainer() {
|
|
3153
|
-
return document.getElementById("search_select_div_".concat(uniqueValue));
|
|
3166
|
+
return _getPopupContainer && _getPopupContainer() || document.getElementById("search_select_div_".concat(uniqueValue));
|
|
3154
3167
|
}
|
|
3155
3168
|
}), items.map(function (item) {
|
|
3156
3169
|
return /*#__PURE__*/React.createElement(Option, {
|
package/dist/index.js
CHANGED
|
@@ -305,9 +305,10 @@ function ownKeys$1(object, enumerableOnly) {
|
|
|
305
305
|
|
|
306
306
|
if (Object.getOwnPropertySymbols) {
|
|
307
307
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
308
|
-
enumerableOnly
|
|
308
|
+
if (enumerableOnly) symbols = symbols.filter(function (sym) {
|
|
309
309
|
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
310
|
-
})
|
|
310
|
+
});
|
|
311
|
+
keys.push.apply(keys, symbols);
|
|
311
312
|
}
|
|
312
313
|
|
|
313
314
|
return keys;
|
|
@@ -315,12 +316,19 @@ function ownKeys$1(object, enumerableOnly) {
|
|
|
315
316
|
|
|
316
317
|
function _objectSpread2$1(target) {
|
|
317
318
|
for (var i = 1; i < arguments.length; i++) {
|
|
318
|
-
var source =
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
319
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
320
|
+
|
|
321
|
+
if (i % 2) {
|
|
322
|
+
ownKeys$1(Object(source), true).forEach(function (key) {
|
|
323
|
+
_defineProperty$1(target, key, source[key]);
|
|
324
|
+
});
|
|
325
|
+
} else if (Object.getOwnPropertyDescriptors) {
|
|
326
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
327
|
+
} else {
|
|
328
|
+
ownKeys$1(Object(source)).forEach(function (key) {
|
|
329
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
330
|
+
});
|
|
331
|
+
}
|
|
324
332
|
}
|
|
325
333
|
|
|
326
334
|
return target;
|
|
@@ -331,17 +339,14 @@ function _arrayWithHoles$1(arr) {
|
|
|
331
339
|
}
|
|
332
340
|
|
|
333
341
|
function _iterableToArrayLimit$1(arr, i) {
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
if (_i == null) return;
|
|
342
|
+
if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(arr))) return;
|
|
337
343
|
var _arr = [];
|
|
338
344
|
var _n = true;
|
|
339
345
|
var _d = false;
|
|
340
|
-
|
|
341
|
-
var _s, _e;
|
|
346
|
+
var _e = undefined;
|
|
342
347
|
|
|
343
348
|
try {
|
|
344
|
-
for (_i =
|
|
349
|
+
for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {
|
|
345
350
|
_arr.push(_s.value);
|
|
346
351
|
|
|
347
352
|
if (i && _arr.length === i) break;
|
|
@@ -424,11 +429,17 @@ function _objectWithoutProperties$1(source, excluded) {
|
|
|
424
429
|
function _typeof(obj) {
|
|
425
430
|
"@babel/helpers - typeof";
|
|
426
431
|
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
}
|
|
432
|
+
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
433
|
+
_typeof = function _typeof(obj) {
|
|
434
|
+
return typeof obj;
|
|
435
|
+
};
|
|
436
|
+
} else {
|
|
437
|
+
_typeof = function _typeof(obj) {
|
|
438
|
+
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
439
|
+
};
|
|
440
|
+
}
|
|
441
|
+
|
|
442
|
+
return _typeof(obj);
|
|
432
443
|
}
|
|
433
444
|
|
|
434
445
|
/**
|
|
@@ -2418,7 +2429,9 @@ var SearchSelect = function SearchSelect(props) {
|
|
|
2418
2429
|
ctx = props.ctx,
|
|
2419
2430
|
sourceName = props.sourceName,
|
|
2420
2431
|
_props$needModalTable = props.needModalTable,
|
|
2421
|
-
needModalTable = _props$needModalTable === void 0 ? true : _props$needModalTable
|
|
2432
|
+
needModalTable = _props$needModalTable === void 0 ? true : _props$needModalTable,
|
|
2433
|
+
_props$getPopupContai = props.getPopupContainer,
|
|
2434
|
+
_getPopupContainer = _props$getPopupContai === void 0 ? undefined : _props$getPopupContai;
|
|
2422
2435
|
|
|
2423
2436
|
var _ref = requestConfig || {},
|
|
2424
2437
|
url = _ref.url,
|
|
@@ -3161,7 +3174,7 @@ var SearchSelect = function SearchSelect(props) {
|
|
|
3161
3174
|
maxTagPlaceholder: maxTagPlaceholder
|
|
3162
3175
|
}, currentSelectProps), {}, {
|
|
3163
3176
|
getPopupContainer: function getPopupContainer() {
|
|
3164
|
-
return document.getElementById("search_select_div_".concat(uniqueValue));
|
|
3177
|
+
return _getPopupContainer && _getPopupContainer() || document.getElementById("search_select_div_".concat(uniqueValue));
|
|
3165
3178
|
}
|
|
3166
3179
|
}), items.map(function (item) {
|
|
3167
3180
|
return /*#__PURE__*/React__default['default'].createElement(Option, {
|
package/package.json
CHANGED
|
@@ -21,6 +21,7 @@ const SearchSelect = (props: any) => {
|
|
|
21
21
|
ctx,
|
|
22
22
|
sourceName,
|
|
23
23
|
needModalTable=true,
|
|
24
|
+
getPopupContainer=undefined
|
|
24
25
|
} = props;
|
|
25
26
|
const { url, otherParams, isMap, fixedparameter, fieldValToParam, mappingTextField='name', mappingTextShowKeyField,mappingValueField='code' } = requestConfig || {};
|
|
26
27
|
const resultSourceKey = sourceName || requestConfig?.sourceName || 'supplierCode'
|
|
@@ -565,7 +566,7 @@ const SearchSelect = (props: any) => {
|
|
|
565
566
|
placeholder="请选择"
|
|
566
567
|
maxTagPlaceholder={maxTagPlaceholder}
|
|
567
568
|
{...currentSelectProps}
|
|
568
|
-
getPopupContainer={() => document.getElementById(`search_select_div_${uniqueValue}`)}
|
|
569
|
+
getPopupContainer={() => (getPopupContainer && getPopupContainer()) || document.getElementById(`search_select_div_${uniqueValue}`)}
|
|
569
570
|
>
|
|
570
571
|
{items.map(item => (
|
|
571
572
|
<Option key={item.value} label={item.text}>
|