@next-libs/cmdb-instances 7.8.0 → 7.9.0
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/cjs/instance-list/InstanceList.js +192 -34
- package/dist/cjs/instance-list/InstanceList.js.map +1 -1
- package/dist/cjs/instance-list-modal/InstanceListModal.js +2 -1
- package/dist/cjs/instance-list-modal/InstanceListModal.js.map +1 -1
- package/dist/esm/instance-list/InstanceList.js +250 -74
- package/dist/esm/instance-list/InstanceList.js.map +1 -1
- package/dist/esm/instance-list-modal/InstanceListModal.js +2 -1
- package/dist/esm/instance-list-modal/InstanceListModal.js.map +1 -1
- package/dist/types/instance-list/InstanceList.d.ts +10 -0
- package/dist/types/instance-list-modal/InstanceListModal.d.ts +1 -0
- package/package.json +2 -2
|
@@ -10,8 +10,10 @@ exports.LegacyInstanceList = LegacyInstanceList;
|
|
|
10
10
|
exports.getQuery = getQuery;
|
|
11
11
|
exports.isValueEqualFn = exports.isSpecialFn = exports.initAqToShow = void 0;
|
|
12
12
|
exports.joinRelationFieldAndShowkey = joinRelationFieldAndShowkey;
|
|
13
|
+
exports.mergeFields = mergeFields;
|
|
13
14
|
exports.specialQueryHandler = void 0;
|
|
14
15
|
exports.translateConditions = translateConditions;
|
|
16
|
+
exports.updateSortFields = updateSortFields;
|
|
15
17
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
16
18
|
var _react = _interopRequireWildcard(require("react"));
|
|
17
19
|
var _lodash = require("lodash");
|
|
@@ -110,6 +112,31 @@ const isValueEqualFn = (query, attrId, valuesStr) => {
|
|
|
110
112
|
: false;
|
|
111
113
|
};
|
|
112
114
|
exports.isValueEqualFn = isValueEqualFn;
|
|
115
|
+
function mergeFields(oldFields, newFieldIds) {
|
|
116
|
+
return newFieldIds.map(field => {
|
|
117
|
+
const existField = oldFields.find(f => f.field === field);
|
|
118
|
+
const order = existField ? existField.order : 0;
|
|
119
|
+
return {
|
|
120
|
+
field,
|
|
121
|
+
order
|
|
122
|
+
};
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
function updateSortFields(oldFields, sortInfo, sortType) {
|
|
126
|
+
const {
|
|
127
|
+
asc,
|
|
128
|
+
sort
|
|
129
|
+
} = sortInfo;
|
|
130
|
+
const order = ["series-number", "auto-increment-id"].includes(sortType) ? asc ? 2 : -2 : asc ? 1 : -1;
|
|
131
|
+
return oldFields.map(item => {
|
|
132
|
+
if (item.field === sort) {
|
|
133
|
+
item.order = order;
|
|
134
|
+
} else {
|
|
135
|
+
item.order = 0;
|
|
136
|
+
}
|
|
137
|
+
return item;
|
|
138
|
+
});
|
|
139
|
+
}
|
|
113
140
|
function translateConditions(aq, idObjectMap, modelData, t) {
|
|
114
141
|
const conditions = [];
|
|
115
142
|
const relations = [];
|
|
@@ -296,6 +323,14 @@ function LegacyInstanceList(props) {
|
|
|
296
323
|
const ignorePermissionProvider = (0, _brickKit.useProvider)("easyops.api.cmdb.instance@PostSearchV3WithAdmin:1.0.0", {
|
|
297
324
|
cache: false
|
|
298
325
|
});
|
|
326
|
+
// istanbul ignore next
|
|
327
|
+
|
|
328
|
+
const fieldsProvider = (0, _brickKit.useProvider)("easyops.api.cmdb.instance@GetListDisplayView:1.0.1", {
|
|
329
|
+
cache: false
|
|
330
|
+
});
|
|
331
|
+
const updateFieldsProvider = (0, _brickKit.useProvider)("easyops.api.cmdb.instance@UpdateListDisplayView:1.0.0", {
|
|
332
|
+
cache: false
|
|
333
|
+
});
|
|
299
334
|
const {
|
|
300
335
|
modelData,
|
|
301
336
|
idObjectMap
|
|
@@ -368,10 +403,60 @@ function LegacyInstanceList(props) {
|
|
|
368
403
|
});
|
|
369
404
|
return [...frontFields, ...restFields];
|
|
370
405
|
};
|
|
371
|
-
|
|
372
|
-
|
|
406
|
+
// istanbul ignore next
|
|
407
|
+
|
|
408
|
+
const getFieldsAsync = async () => {
|
|
409
|
+
var _props$presetConfigs3, _modelData$attrList, _modelData$attrList$f2, _modelData$attrList$f3, _props$extraFixedFiel;
|
|
410
|
+
let sort = props.sort;
|
|
373
411
|
let fieldIds = (_props$presetConfigs3 = props.presetConfigs) === null || _props$presetConfigs3 === void 0 ? void 0 : _props$presetConfigs3.fieldIds;
|
|
412
|
+
const sortType = modelData === null || modelData === void 0 ? void 0 : (_modelData$attrList = modelData.attrList) === null || _modelData$attrList === void 0 ? void 0 : (_modelData$attrList$f2 = _modelData$attrList.find(attr => attr.id === sort)) === null || _modelData$attrList$f2 === void 0 ? void 0 : (_modelData$attrList$f3 = _modelData$attrList$f2.value) === null || _modelData$attrList$f3 === void 0 ? void 0 : _modelData$attrList$f3.default_type;
|
|
413
|
+
let asc;
|
|
414
|
+
if (props.asc === true) {
|
|
415
|
+
asc = ["series-number", "auto-increment-id"].includes(sortType) ? 2 : 1;
|
|
416
|
+
} else {
|
|
417
|
+
asc = ["series-number", "auto-increment-id"].includes(sortType) ? -2 : -1;
|
|
418
|
+
}
|
|
419
|
+
let sortFields;
|
|
420
|
+
if (props.saveFieldsBackend) {
|
|
421
|
+
sortFields = (await fieldsProvider.query([props.objectId])).sortFields;
|
|
422
|
+
}
|
|
374
423
|
const extraFixedFieldIds = (_props$extraFixedFiel = props.extraFixedFields) !== null && _props$extraFixedFiel !== void 0 ? _props$extraFixedFiel : [];
|
|
424
|
+
if ((0, _lodash.isEmpty)(fieldIds)) {
|
|
425
|
+
if (props.saveFieldsBackend) {
|
|
426
|
+
fieldIds = sortFields.map(item => item.field);
|
|
427
|
+
if ((0, _lodash.isEmpty)(sort) || (0, _lodash.isEmpty)(asc)) {
|
|
428
|
+
const orderField = sortFields.find(item => item.order !== 0);
|
|
429
|
+
if (orderField) {
|
|
430
|
+
sort = orderField.field;
|
|
431
|
+
asc = orderField.order;
|
|
432
|
+
}
|
|
433
|
+
}
|
|
434
|
+
} else {
|
|
435
|
+
fieldIds = jsonLocalStorage.getItem(`${modelData.objectId}-selectAttrIds`);
|
|
436
|
+
}
|
|
437
|
+
}
|
|
438
|
+
if ((0, _lodash.isEmpty)(fieldIds)) {
|
|
439
|
+
fieldIds = computeDefaultFields().fieldIds;
|
|
440
|
+
}
|
|
441
|
+
if (!(0, _lodash.isEmpty)(extraFixedFieldIds)) {
|
|
442
|
+
fieldIds = (0, _lodash.uniq)([...fieldIds, ...extraFixedFieldIds]);
|
|
443
|
+
}
|
|
444
|
+
fieldIds = props.extraDisabledField ? (0, _lodash.uniq)([...fieldIds, props.extraDisabledField]) : fieldIds;
|
|
445
|
+
fieldIds = _sortFieldIds(fieldIds);
|
|
446
|
+
const hideModelData = modelData.view.hide_columns || [];
|
|
447
|
+
fieldIds = fieldIds.filter(field => !hideModelData.includes(field));
|
|
448
|
+
modelData.isAbstract && fieldIds.push("_object_id");
|
|
449
|
+
return {
|
|
450
|
+
fieldIds,
|
|
451
|
+
sort,
|
|
452
|
+
asc,
|
|
453
|
+
sortFields
|
|
454
|
+
};
|
|
455
|
+
};
|
|
456
|
+
const getFields = () => {
|
|
457
|
+
var _props$presetConfigs4, _props$extraFixedFiel2;
|
|
458
|
+
let fieldIds = (_props$presetConfigs4 = props.presetConfigs) === null || _props$presetConfigs4 === void 0 ? void 0 : _props$presetConfigs4.fieldIds;
|
|
459
|
+
const extraFixedFieldIds = (_props$extraFixedFiel2 = props.extraFixedFields) !== null && _props$extraFixedFiel2 !== void 0 ? _props$extraFixedFiel2 : [];
|
|
375
460
|
if ((0, _lodash.isEmpty)(fieldIds)) {
|
|
376
461
|
fieldIds = jsonLocalStorage.getItem(`${modelData.objectId}-selectAttrIds`);
|
|
377
462
|
}
|
|
@@ -390,11 +475,12 @@ function LegacyInstanceList(props) {
|
|
|
390
475
|
};
|
|
391
476
|
const [q, setQ] = (0, _react.useState)(props.q);
|
|
392
477
|
const [state, setState] = (0, _react.useReducer)(reducer, undefined, () => {
|
|
393
|
-
var _ref, _props$dataSource$pag, _props$dataSource, _ref2, _props$dataSource$pag2, _props$dataSource2, _props$
|
|
478
|
+
var _ref, _props$dataSource$pag, _props$dataSource, _ref2, _props$dataSource$pag2, _props$dataSource2, _props$presetConfigs5;
|
|
394
479
|
return {
|
|
395
480
|
objectId: props.objectId,
|
|
396
481
|
q: props.q,
|
|
397
482
|
aq: initAqToShow(props.aq, modelData, false),
|
|
483
|
+
sortFields: [],
|
|
398
484
|
aqToShow: props.aqToShow || initAqToShow(props.aq, modelData),
|
|
399
485
|
instanceSourceQuery: props.instanceSourceQuery,
|
|
400
486
|
asc: props.asc,
|
|
@@ -410,8 +496,8 @@ function LegacyInstanceList(props) {
|
|
|
410
496
|
loading: false,
|
|
411
497
|
failed: false,
|
|
412
498
|
isAdvancedSearchVisible: false,
|
|
413
|
-
fieldIds: getFields(),
|
|
414
|
-
presetConfigsQuery: (_props$
|
|
499
|
+
fieldIds: props.saveFieldsBackend ? [] : getFields(),
|
|
500
|
+
presetConfigsQuery: (_props$presetConfigs5 = props.presetConfigs) === null || _props$presetConfigs5 === void 0 ? void 0 : _props$presetConfigs5.query,
|
|
415
501
|
autoBreakLine: false,
|
|
416
502
|
appSearchInstanceId: "",
|
|
417
503
|
currentChangeSelect: "App",
|
|
@@ -429,7 +515,7 @@ function LegacyInstanceList(props) {
|
|
|
429
515
|
const cache = (0, _react.useRef)(new Map());
|
|
430
516
|
const isFirstRunRef = (0, _react.useRef)(true);
|
|
431
517
|
const getInstanceListData = async (sort, asc, page) => {
|
|
432
|
-
var _modelData$
|
|
518
|
+
var _modelData$attrList2, _modelData$attrList2$, _modelData$attrList2$2, _props$onSearchExecut;
|
|
433
519
|
const data = {};
|
|
434
520
|
const v3Data = {
|
|
435
521
|
fields: props !== null && props !== void 0 && props.extraFixedFields ? (0, _lodash.uniq)(["instanceId"].concat(props === null || props === void 0 ? void 0 : props.extraFixedFields)) : ["instanceId"]
|
|
@@ -441,7 +527,7 @@ function LegacyInstanceList(props) {
|
|
|
441
527
|
let query = {};
|
|
442
528
|
v3Data.page = data.page = archiveData.page = page;
|
|
443
529
|
v3Data["page_size"] = data["page_size"] = archiveData["page_size"] = state.pageSize;
|
|
444
|
-
const sortType = modelData === null || modelData === void 0 ? void 0 : (_modelData$
|
|
530
|
+
const sortType = modelData === null || modelData === void 0 ? void 0 : (_modelData$attrList2 = modelData.attrList) === null || _modelData$attrList2 === void 0 ? void 0 : (_modelData$attrList2$ = _modelData$attrList2.find(attr => attr.id === sort)) === null || _modelData$attrList2$ === void 0 ? void 0 : (_modelData$attrList2$2 = _modelData$attrList2$.value) === null || _modelData$attrList2$2 === void 0 ? void 0 : _modelData$attrList2$2.default_type;
|
|
445
531
|
const order = ["series-number", "auto-increment-id"].includes(sortType) ? asc ? 2 : -2 : asc ? 1 : -1;
|
|
446
532
|
if (sort) {
|
|
447
533
|
data.sort = {
|
|
@@ -512,8 +598,8 @@ function LegacyInstanceList(props) {
|
|
|
512
598
|
//按应用筛选
|
|
513
599
|
// istanbul ignore next (state is not updated)
|
|
514
600
|
if (state.searchByApp) {
|
|
515
|
-
var _props$
|
|
516
|
-
const hostRange = (_props$
|
|
601
|
+
var _props$presetConfigs6, _props$presetConfigs7, _props$presetConfigs8, _props$presetConfigs9, _props$presetConfigs10;
|
|
602
|
+
const hostRange = (_props$presetConfigs6 = props.presetConfigs) === null || _props$presetConfigs6 === void 0 ? void 0 : (_props$presetConfigs7 = _props$presetConfigs6.query) === null || _props$presetConfigs7 === void 0 ? void 0 : (_props$presetConfigs8 = _props$presetConfigs7["$and"]) === null || _props$presetConfigs8 === void 0 ? void 0 : (_props$presetConfigs9 = _props$presetConfigs8.find(i => i.instanceId)) === null || _props$presetConfigs9 === void 0 ? void 0 : (_props$presetConfigs10 = _props$presetConfigs9.instanceId) === null || _props$presetConfigs10 === void 0 ? void 0 : _props$presetConfigs10["$in"];
|
|
517
603
|
v3Data.query = {
|
|
518
604
|
[state.currentChangeSelect === "App" || state.currentChangeSelect === "Cluster" && state.clusterValue === "all" ? "_deviceList_CLUSTER.appId.instanceId" : "_deviceList_CLUSTER.instanceId"]: state.appSearchInstanceId,
|
|
519
605
|
...(!(0, _lodash.isEmpty)(hostRange) && props.limitInstanceRange ? {
|
|
@@ -570,17 +656,42 @@ function LegacyInstanceList(props) {
|
|
|
570
656
|
});
|
|
571
657
|
}
|
|
572
658
|
};
|
|
659
|
+
// const [fieldIds,setFieldIds] = useState([]);
|
|
660
|
+
// istanbul ignore next
|
|
573
661
|
(0, _react.useEffect)(() => {
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
662
|
+
if (props.saveFieldsBackend) {
|
|
663
|
+
const getFieldIds = async () => {
|
|
664
|
+
var _props$presetConfigs11, _props$presetConfigs12;
|
|
665
|
+
const fieldConfig = await getFieldsAsync();
|
|
666
|
+
const {
|
|
667
|
+
fieldIds,
|
|
668
|
+
sort,
|
|
669
|
+
asc,
|
|
670
|
+
sortFields
|
|
671
|
+
} = fieldConfig;
|
|
672
|
+
if (
|
|
673
|
+
// 当 props.objectId 改变时,总是更新 state.fieldIds
|
|
674
|
+
props.objectId !== state.objectId || !(0, _lodash.isEqual)(fieldIds, state.fieldIds) || !(0, _lodash.isEqual)((_props$presetConfigs11 = props.presetConfigs) === null || _props$presetConfigs11 === void 0 ? void 0 : _props$presetConfigs11.query, state.presetConfigsQuery)) setState({
|
|
675
|
+
fieldIds,
|
|
676
|
+
presetConfigsQuery: (_props$presetConfigs12 = props.presetConfigs) === null || _props$presetConfigs12 === void 0 ? void 0 : _props$presetConfigs12.query,
|
|
677
|
+
sort,
|
|
678
|
+
asc: [1, 2].includes(asc) ? true : false,
|
|
679
|
+
sortFields
|
|
680
|
+
});
|
|
681
|
+
};
|
|
682
|
+
getFieldIds();
|
|
683
|
+
} else {
|
|
684
|
+
var _props$presetConfigs13;
|
|
685
|
+
const fieldIds = getFields();
|
|
686
|
+
if (
|
|
687
|
+
// 当 props.objectId 改变时,总是更新 state.fieldIds
|
|
688
|
+
props.objectId !== state.objectId || !(0, _lodash.isEqual)(fieldIds, state.fieldIds) || !(0, _lodash.isEqual)((_props$presetConfigs13 = props.presetConfigs) === null || _props$presetConfigs13 === void 0 ? void 0 : _props$presetConfigs13.query, state.presetConfigsQuery)) {
|
|
689
|
+
var _props$presetConfigs14;
|
|
690
|
+
setState({
|
|
691
|
+
fieldIds,
|
|
692
|
+
presetConfigsQuery: (_props$presetConfigs14 = props.presetConfigs) === null || _props$presetConfigs14 === void 0 ? void 0 : _props$presetConfigs14.query
|
|
693
|
+
});
|
|
694
|
+
}
|
|
584
695
|
}
|
|
585
696
|
}, [props.objectId, props.presetConfigs]);
|
|
586
697
|
(0, _react.useEffect)(() => {
|
|
@@ -690,7 +801,7 @@ function LegacyInstanceList(props) {
|
|
|
690
801
|
});
|
|
691
802
|
(_props$onAdvancedSear = props.onAdvancedSearch) === null || _props$onAdvancedSear === void 0 ? void 0 : _props$onAdvancedSear.call(props, queries);
|
|
692
803
|
};
|
|
693
|
-
const onSortingChange = (0, _react.useCallback)(info => {
|
|
804
|
+
const onSortingChange = (0, _react.useCallback)(async (info, sortFields) => {
|
|
694
805
|
var _props$onSortingChang;
|
|
695
806
|
let asc;
|
|
696
807
|
let sort;
|
|
@@ -710,6 +821,24 @@ function LegacyInstanceList(props) {
|
|
|
710
821
|
asc = info.asc;
|
|
711
822
|
sort = info.sort;
|
|
712
823
|
}
|
|
824
|
+
// istanbul ignore next
|
|
825
|
+
if (props.saveFieldsBackend) {
|
|
826
|
+
try {
|
|
827
|
+
var _modelData$attrList3, _modelData$attrList3$, _modelData$attrList3$2;
|
|
828
|
+
const oldsortFields = sortFields;
|
|
829
|
+
const sortType = modelData === null || modelData === void 0 ? void 0 : (_modelData$attrList3 = modelData.attrList) === null || _modelData$attrList3 === void 0 ? void 0 : (_modelData$attrList3$ = _modelData$attrList3.find(attr => attr.id === sort)) === null || _modelData$attrList3$ === void 0 ? void 0 : (_modelData$attrList3$2 = _modelData$attrList3$.value) === null || _modelData$attrList3$2 === void 0 ? void 0 : _modelData$attrList3$2.default_type;
|
|
830
|
+
const newSortFields = updateSortFields(oldsortFields, info, sortType);
|
|
831
|
+
setState({
|
|
832
|
+
sortFields: newSortFields
|
|
833
|
+
});
|
|
834
|
+
await updateFieldsProvider.query([props.objectId, {
|
|
835
|
+
sortFields: newSortFields
|
|
836
|
+
}]);
|
|
837
|
+
} catch (e) {
|
|
838
|
+
_brickKit.handleHttpError;
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
// istanbul ignore next
|
|
713
842
|
(_props$onSortingChang = props.onSortingChange) === null || _props$onSortingChang === void 0 ? void 0 : _props$onSortingChang.call(props, info);
|
|
714
843
|
}, [state.sort]);
|
|
715
844
|
const onPaginationChange = (0, _react.useCallback)(pagination => {
|
|
@@ -794,10 +923,10 @@ function LegacyInstanceList(props) {
|
|
|
794
923
|
});
|
|
795
924
|
};
|
|
796
925
|
const defaultFields = (0, _react.useMemo)(() => {
|
|
797
|
-
var _props$
|
|
926
|
+
var _props$presetConfigs15, _props$extraFixedFiel3;
|
|
798
927
|
let defaultFields;
|
|
799
|
-
const fieldIds = (_props$
|
|
800
|
-
extraFixedFieldIds = (_props$
|
|
928
|
+
const fieldIds = (_props$presetConfigs15 = props.presetConfigs) === null || _props$presetConfigs15 === void 0 ? void 0 : _props$presetConfigs15.fieldIds,
|
|
929
|
+
extraFixedFieldIds = (_props$extraFixedFiel3 = props.extraFixedFields) !== null && _props$extraFixedFiel3 !== void 0 ? _props$extraFixedFiel3 : [];
|
|
801
930
|
if (!(0, _lodash.isEmpty)(fieldIds)) {
|
|
802
931
|
defaultFields = props.presetConfigs.fieldIds;
|
|
803
932
|
} else {
|
|
@@ -810,23 +939,50 @@ function LegacyInstanceList(props) {
|
|
|
810
939
|
}, [props.presetConfigs, modelData]);
|
|
811
940
|
|
|
812
941
|
// istanbul ignore next
|
|
813
|
-
const handleConfirm = ({
|
|
942
|
+
const handleConfirm = async ({
|
|
814
943
|
fields,
|
|
815
944
|
isReset
|
|
816
945
|
}) => {
|
|
817
946
|
if (isReset) {
|
|
818
947
|
const fieldIds = defaultFields;
|
|
819
948
|
modelData.isAbstract && fieldIds.push("_object_id");
|
|
820
|
-
|
|
821
|
-
fieldIds
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
949
|
+
if (props.saveFieldsBackend) {
|
|
950
|
+
const sortFields = mergeFields(state.sortFields, fieldIds);
|
|
951
|
+
await updateFieldsProvider.query([props.objectId, {
|
|
952
|
+
sortFields
|
|
953
|
+
}]);
|
|
954
|
+
setState({
|
|
955
|
+
fieldIds,
|
|
956
|
+
sortFields
|
|
957
|
+
});
|
|
958
|
+
props.onFieldsModalConfirm(fieldIds);
|
|
959
|
+
} else {
|
|
960
|
+
jsonLocalStorage.removeItem(`${modelData.objectId}-selectAttrIds`);
|
|
961
|
+
setState({
|
|
962
|
+
fieldIds
|
|
963
|
+
});
|
|
964
|
+
props.onFieldsModalConfirm(fieldIds);
|
|
965
|
+
}
|
|
825
966
|
} else {
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
967
|
+
if (props.saveFieldsBackend) {
|
|
968
|
+
try {
|
|
969
|
+
const sortFields = mergeFields(state.sortFields, fields);
|
|
970
|
+
await updateFieldsProvider.query([props.objectId, {
|
|
971
|
+
sortFields
|
|
972
|
+
}]);
|
|
973
|
+
setState({
|
|
974
|
+
fieldIds: _sortFieldIds(fields),
|
|
975
|
+
sortFields
|
|
976
|
+
});
|
|
977
|
+
} catch (e) {
|
|
978
|
+
(0, _brickKit.handleHttpError)(e);
|
|
979
|
+
}
|
|
980
|
+
} else {
|
|
981
|
+
setState({
|
|
982
|
+
fieldIds: _sortFieldIds(fields)
|
|
983
|
+
});
|
|
984
|
+
jsonLocalStorage.setItem(`${modelData.objectId}-selectAttrIds`, fields);
|
|
985
|
+
}
|
|
830
986
|
props.onFieldsModalConfirm(fields);
|
|
831
987
|
}
|
|
832
988
|
};
|
|
@@ -1126,7 +1282,9 @@ function LegacyInstanceList(props) {
|
|
|
1126
1282
|
onClickItem: props.onClickItem,
|
|
1127
1283
|
onClickItemV2: props.onClickItemV2,
|
|
1128
1284
|
onPaginationChange: onPaginationChange,
|
|
1129
|
-
onSortingChange:
|
|
1285
|
+
onSortingChange: info => {
|
|
1286
|
+
onSortingChange(info, state.sortFields);
|
|
1287
|
+
},
|
|
1130
1288
|
onSelectionChange: onSelectionChange,
|
|
1131
1289
|
onInstanceSourceChange: onInstanceSourceChange,
|
|
1132
1290
|
instanceSourceQuery: state.instanceSourceQuery,
|