cnhis-design-vue 3.1.34-beta.4 → 3.1.34-beta.6
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/es/components/big-table/src/components/edit-form/edit-input.js +2 -1
- package/es/components/fabric-chart/src/hooks/useCenter.js +2 -1
- package/es/components/iho-table/index.d.ts +4 -0
- package/es/components/iho-table/src/IhoTable.vue.d.ts +4 -0
- package/es/components/iho-table/src/components/IhoTableColumn.js +1 -1
- package/es/components/iho-table/src/plugins/defaultConfigPlugin/index.js +9 -4
- package/es/components/iho-table/src/plugins/filterPlugin/index.js +1 -0
- package/es/components/iho-table/src/plugins/lowCodeFieldAdaptorPlugin/index.js +6 -4
- package/es/components/iho-table/src/types/index.d.ts +3 -0
- package/package.json +2 -2
|
@@ -32,10 +32,11 @@ var EditInput = defineComponent({
|
|
|
32
32
|
attrs,
|
|
33
33
|
emit
|
|
34
34
|
}) {
|
|
35
|
+
var _a;
|
|
35
36
|
const {
|
|
36
37
|
formRef
|
|
37
38
|
} = useCommon(props, attrs);
|
|
38
|
-
const __value = ref(props.type === "number" ? attrs.value
|
|
39
|
+
const __value = ref(props.type === "number" ? (_a = attrs.value) != null ? _a : void 0 : attrs.value);
|
|
39
40
|
const commData = {
|
|
40
41
|
row: props.row,
|
|
41
42
|
column: props.col,
|
|
@@ -230,6 +230,7 @@ function useCenter(canvas, propItems, emits, cumputedX, cumputedY, getXValue, ge
|
|
|
230
230
|
pacemaker = {},
|
|
231
231
|
upArrowStyle = {},
|
|
232
232
|
limitValueStyle = {},
|
|
233
|
+
nonePainPointStyle = {},
|
|
233
234
|
dataList = []
|
|
234
235
|
} = scaleValue;
|
|
235
236
|
const pointList = [];
|
|
@@ -444,7 +445,7 @@ function useCenter(canvas, propItems, emits, cumputedX, cumputedY, getXValue, ge
|
|
|
444
445
|
lockMovementX: true,
|
|
445
446
|
...v.pacemakerShow && type == "pulse" ? pacemaker.style : pointAttr,
|
|
446
447
|
...propItems.event,
|
|
447
|
-
...isNonePain ? { selectable: false, evented: false } : {}
|
|
448
|
+
...isNonePain ? { selectable: false, evented: false, ...nonePainPointStyle } : {}
|
|
448
449
|
};
|
|
449
450
|
if (previousLine) {
|
|
450
451
|
const y = previousLine.get("y2");
|
|
@@ -2077,6 +2077,8 @@ declare const IhoTable: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
2077
2077
|
onActiveCellChangeEnd?: ((params: import("vxe-table").VxeTableProDefines.ActiveCellChangeEndEventParams) => void) | undefined;
|
|
2078
2078
|
uuid?: string | undefined;
|
|
2079
2079
|
isTree?: 0 | 2 | 1 | 3 | undefined;
|
|
2080
|
+
isSort?: 0 | 1 | undefined;
|
|
2081
|
+
isBatchSelect?: 0 | 1 | undefined;
|
|
2080
2082
|
showSeq?: boolean | undefined;
|
|
2081
2083
|
selectType?: "checkbox" | "radio" | null | undefined;
|
|
2082
2084
|
rowGroupSetting?: {
|
|
@@ -4466,6 +4468,8 @@ declare const IhoTable: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
4466
4468
|
params?: any;
|
|
4467
4469
|
uuid?: string | undefined;
|
|
4468
4470
|
isTree?: 0 | 2 | 1 | 3 | undefined;
|
|
4471
|
+
isSort?: 0 | 1 | undefined;
|
|
4472
|
+
isBatchSelect?: 0 | 1 | undefined;
|
|
4469
4473
|
showSeq?: boolean | undefined;
|
|
4470
4474
|
selectType?: "checkbox" | "radio" | null | undefined;
|
|
4471
4475
|
rowGroupSetting?: {
|
|
@@ -2076,6 +2076,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
2076
2076
|
onActiveCellChangeEnd?: ((params: import("vxe-table").VxeTableProDefines.ActiveCellChangeEndEventParams) => void) | undefined;
|
|
2077
2077
|
uuid?: string | undefined;
|
|
2078
2078
|
isTree?: 0 | 2 | 1 | 3 | undefined;
|
|
2079
|
+
isSort?: 0 | 1 | undefined;
|
|
2080
|
+
isBatchSelect?: 0 | 1 | undefined;
|
|
2079
2081
|
showSeq?: boolean | undefined;
|
|
2080
2082
|
selectType?: "checkbox" | "radio" | null | undefined;
|
|
2081
2083
|
rowGroupSetting?: {
|
|
@@ -4465,6 +4467,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
4465
4467
|
params?: any;
|
|
4466
4468
|
uuid?: string | undefined;
|
|
4467
4469
|
isTree?: 0 | 2 | 1 | 3 | undefined;
|
|
4470
|
+
isSort?: 0 | 1 | undefined;
|
|
4471
|
+
isBatchSelect?: 0 | 1 | undefined;
|
|
4468
4472
|
showSeq?: boolean | undefined;
|
|
4469
4473
|
selectType?: "checkbox" | "radio" | null | undefined;
|
|
4470
4474
|
rowGroupSetting?: {
|
|
@@ -27,7 +27,7 @@ const ColumnComponent = defineComponent({
|
|
|
27
27
|
"class": "iho-table__headerWrapper"
|
|
28
28
|
}, [createVNode("section", {
|
|
29
29
|
"style": {
|
|
30
|
-
width: widthAppend(payload.column.renderWidth - (hasAnnotation ? 36 : 20))
|
|
30
|
+
width: widthAppend(payload.column.renderWidth - (hasAnnotation ? 36 : 20) - (props.field.sortable ? 24 : 0))
|
|
31
31
|
}
|
|
32
32
|
}, [[...arrayed(customHeader != null ? customHeader : createVNode(NEllipsis, {
|
|
33
33
|
"style": {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { mergeWith } from 'lodash-es';
|
|
2
|
-
import { HIGHEST_PRIORITY, IHO_TABLE_TREE_TYPE } from '../../constants/index.js';
|
|
1
|
+
import { mergeWith, isObject } from 'lodash-es';
|
|
2
|
+
import { HIGHEST_PRIORITY, IHO_TABLE_TREE_TYPE, IHO_TABLE_NUMBER_STATUS } from '../../constants/index.js';
|
|
3
3
|
import { defineTablePlugin } from '../../hooks/useTablePlugin.js';
|
|
4
4
|
|
|
5
5
|
function defaultConfigPlugin() {
|
|
@@ -13,7 +13,6 @@ function defaultConfigPlugin() {
|
|
|
13
13
|
height: "100%",
|
|
14
14
|
border: true,
|
|
15
15
|
showSeq: true,
|
|
16
|
-
selectType: "checkbox",
|
|
17
16
|
columnConfig: { resizable: true },
|
|
18
17
|
rowConfig: { height: 36, isHover: true, isCurrent: true, keyField: "theUniqueKey" },
|
|
19
18
|
mouseConfig: { selected: true },
|
|
@@ -29,7 +28,13 @@ function defaultConfigPlugin() {
|
|
|
29
28
|
config
|
|
30
29
|
);
|
|
31
30
|
if (config.isTree === IHO_TABLE_TREE_TYPE.TRANSFORM_TREE_TYPE) {
|
|
32
|
-
result.treeConfig = {
|
|
31
|
+
result.treeConfig = Object.assign({}, { transform: true }, result.treeConfig);
|
|
32
|
+
}
|
|
33
|
+
if (config.isBatchSelect === IHO_TABLE_NUMBER_STATUS.POSITIVE || config.selectType) {
|
|
34
|
+
result.selectType = config.selectType || "checkbox";
|
|
35
|
+
}
|
|
36
|
+
if (isObject(config.keyboardConfig)) {
|
|
37
|
+
result.mouseConfig = Object.assign({}, { selected: config.keyboardConfig.isEdit }, result.mouseConfig);
|
|
33
38
|
}
|
|
34
39
|
return result;
|
|
35
40
|
});
|
|
@@ -125,6 +125,7 @@ function filterPlugin() {
|
|
|
125
125
|
const fieldSetting = jsonParse(lowCodeField.fieldSetting || "");
|
|
126
126
|
if (!isFieldSetting(fieldSetting) || !showFilter(fieldSetting))
|
|
127
127
|
return;
|
|
128
|
+
fieldItem.sortable = false;
|
|
128
129
|
let options = (_d = (_c = (_b = fieldSetting.mapping) == null ? void 0 : _b.mappingFiled) == null ? void 0 : _c.map((item) => item.value[0])) != null ? _d : [];
|
|
129
130
|
if (isCompatibleColumn(lowCodeField)) {
|
|
130
131
|
options = (_f = (_e = lowCodeField.options) == null ? void 0 : _e.map((option) => ({
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { pick, cloneDeep } from 'lodash-es';
|
|
1
|
+
import { pick, cloneDeep, isObject } from 'lodash-es';
|
|
2
2
|
import { toRaw } from 'vue';
|
|
3
3
|
import { HIGHEST_PRIORITY, IHO_TABLE_NUMBER_STATUS, WIDGET_TYPE, IHO_TABLE_STRING_STATUS } from '../../constants/index.js';
|
|
4
4
|
import { defineTablePlugin } from '../../hooks/useTablePlugin.js';
|
|
@@ -17,6 +17,7 @@ function lowCodeFieldAdaptorPlugin() {
|
|
|
17
17
|
showOverflow: Reflect.has(_field, "showOverflow") ? _field.showOverflow : "tooltip",
|
|
18
18
|
visible: _field.isShow !== IHO_TABLE_NUMBER_STATUS.NEGATIVE,
|
|
19
19
|
minWidth: _field.colWidth,
|
|
20
|
+
sortable: _field.isSort === IHO_TABLE_NUMBER_STATUS.POSITIVE,
|
|
20
21
|
slots: { ..._field.slots, default: _field.slotFn, header: _field.headerSlotFn },
|
|
21
22
|
...pick(_field, ["title", "treeNode", "resizable"])
|
|
22
23
|
};
|
|
@@ -27,7 +28,6 @@ function lowCodeFieldAdaptorPlugin() {
|
|
|
27
28
|
});
|
|
28
29
|
}
|
|
29
30
|
function settingObjAdaptor(fieldItem, lowCodeField, config) {
|
|
30
|
-
var _a;
|
|
31
31
|
const props = cloneDeep(toRaw(lowCodeField));
|
|
32
32
|
props.componentProps = { size: config.size === "mini" ? "small" : config.size, ...props.componentProps };
|
|
33
33
|
fieldItem.editRender = {
|
|
@@ -36,9 +36,11 @@ function settingObjAdaptor(fieldItem, lowCodeField, config) {
|
|
|
36
36
|
props
|
|
37
37
|
};
|
|
38
38
|
fieldItem.editRender.enabled = !Reflect.get(WIDGET_TYPE, fieldItem.editRender.name);
|
|
39
|
-
if (!lowCodeField.settingObj)
|
|
39
|
+
if (!isObject(lowCodeField.settingObj))
|
|
40
40
|
return;
|
|
41
|
-
|
|
41
|
+
if (Reflect.has(lowCodeField.settingObj, "isHide")) {
|
|
42
|
+
fieldItem.visible = fieldItem.visible && lowCodeField.settingObj.isHide !== IHO_TABLE_STRING_STATUS.POSITIVE;
|
|
43
|
+
}
|
|
42
44
|
}
|
|
43
45
|
|
|
44
46
|
export { lowCodeFieldAdaptorPlugin };
|
|
@@ -14,6 +14,8 @@ export declare type IhoTableConfig = VxeTableProps & Partial<{
|
|
|
14
14
|
}> & Partial<{
|
|
15
15
|
uuid: string;
|
|
16
16
|
isTree: 0 | 1 | 2 | 3;
|
|
17
|
+
isSort: 0 | 1;
|
|
18
|
+
isBatchSelect: 0 | 1;
|
|
17
19
|
showSeq: boolean;
|
|
18
20
|
selectType: Exclude<VxeTableDefines.ColumnInfo['type'], 'seq' | 'expand' | 'html'>;
|
|
19
21
|
rowGroupSetting: Partial<Record<TupleToUnion<typeof IhoTableRowGroupSequence>, IhoTableRowGroupItem[]>>;
|
|
@@ -56,6 +58,7 @@ export declare type LowCodeTableFieldItem = {
|
|
|
56
58
|
settingObj: IhoTableLowCodeField.SettingObj;
|
|
57
59
|
treeNode: boolean;
|
|
58
60
|
isShow: 0 | 1;
|
|
61
|
+
isSort: 0 | 1;
|
|
59
62
|
formType: string;
|
|
60
63
|
fieldSetting: string;
|
|
61
64
|
componentProps: AnyObject;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cnhis-design-vue",
|
|
3
|
-
"version": "3.1.34-beta.
|
|
3
|
+
"version": "3.1.34-beta.6",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"module": "./es/components/index.js",
|
|
6
6
|
"main": "./es/components/index.js",
|
|
@@ -61,5 +61,5 @@
|
|
|
61
61
|
"iOS 7",
|
|
62
62
|
"last 3 iOS versions"
|
|
63
63
|
],
|
|
64
|
-
"gitHead": "
|
|
64
|
+
"gitHead": "67795a79ebf11c9ca6a3f6f511d012786eb2199a"
|
|
65
65
|
}
|