jgy-public-component 0.0.31 → 0.0.33
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/components/JListSearchHeader/JListSearchHeader.d.ts +27 -0
- package/dist/components/JListSearchHeader/types.d.ts +6 -0
- package/dist/components/JRemoteSelect/JRemoteSelect.d.ts +138 -0
- package/dist/components/JRemoteSelect/debounce.d.ts +2 -0
- package/dist/components/JRemoteSelect/index.d.ts +2 -0
- package/dist/components/JRemoteSelect/types.d.ts +34 -0
- package/dist/components/JSearchHeader/JSearchHeader.d.ts +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +4992 -4730
- package/dist/index.js.map +1 -1
- package/dist/index.umd.cjs +2 -2
- package/dist/index.umd.cjs.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +75 -75
|
@@ -34,6 +34,18 @@ declare const __VLS_component: DefineComponent<ExtractPropTypes<{
|
|
|
34
34
|
type: PropType<boolean>;
|
|
35
35
|
default: boolean;
|
|
36
36
|
};
|
|
37
|
+
defaultVisible: {
|
|
38
|
+
type: PropType<number>;
|
|
39
|
+
default: number;
|
|
40
|
+
};
|
|
41
|
+
collapsible: {
|
|
42
|
+
type: PropType<boolean>;
|
|
43
|
+
default: boolean;
|
|
44
|
+
};
|
|
45
|
+
moreFilterActiveCount: {
|
|
46
|
+
type: PropType<number>;
|
|
47
|
+
default: number;
|
|
48
|
+
};
|
|
37
49
|
moreFilterPermission: {
|
|
38
50
|
type: PropType<BtnPermissionInput>;
|
|
39
51
|
};
|
|
@@ -86,6 +98,18 @@ declare const __VLS_component: DefineComponent<ExtractPropTypes<{
|
|
|
86
98
|
type: PropType<boolean>;
|
|
87
99
|
default: boolean;
|
|
88
100
|
};
|
|
101
|
+
defaultVisible: {
|
|
102
|
+
type: PropType<number>;
|
|
103
|
+
default: number;
|
|
104
|
+
};
|
|
105
|
+
collapsible: {
|
|
106
|
+
type: PropType<boolean>;
|
|
107
|
+
default: boolean;
|
|
108
|
+
};
|
|
109
|
+
moreFilterActiveCount: {
|
|
110
|
+
type: PropType<number>;
|
|
111
|
+
default: number;
|
|
112
|
+
};
|
|
89
113
|
moreFilterPermission: {
|
|
90
114
|
type: PropType<BtnPermissionInput>;
|
|
91
115
|
};
|
|
@@ -119,6 +143,9 @@ declare const __VLS_component: DefineComponent<ExtractPropTypes<{
|
|
|
119
143
|
showTabs: boolean;
|
|
120
144
|
showSearch: boolean;
|
|
121
145
|
showReset: boolean;
|
|
146
|
+
defaultVisible: number;
|
|
147
|
+
collapsible: boolean;
|
|
148
|
+
moreFilterActiveCount: number;
|
|
122
149
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
123
150
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
|
|
124
151
|
export default _default;
|
|
@@ -13,6 +13,12 @@ export interface JListSearchHeaderProps {
|
|
|
13
13
|
showSearch?: boolean;
|
|
14
14
|
/** 是否展示重置按钮 */
|
|
15
15
|
showReset?: boolean;
|
|
16
|
+
/** 默认可见筛选项个数(按 #filter 内 el-form-item 计),超出显示展开/收起 */
|
|
17
|
+
defaultVisible?: number;
|
|
18
|
+
/** 是否启用 #filter 折叠 */
|
|
19
|
+
collapsible?: boolean;
|
|
20
|
+
/** 更多筛选已生效条件数量,>0 时按钮显示「更多筛选 (N)」 */
|
|
21
|
+
moreFilterActiveCount?: number;
|
|
16
22
|
/** 更多筛选按钮权限码 */
|
|
17
23
|
moreFilterPermission?: BtnPermissionInput;
|
|
18
24
|
/** 查询按钮权限码(含更多筛选弹层内查询) */
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
import { RemoteSelectFetchApi, RemoteSelectModelValue } from './types';
|
|
2
|
+
import { DefineComponent, ExtractPropTypes, ComponentOptionsMixin, PublicProps, ComponentProvideOptions, PropType } from 'vue';
|
|
3
|
+
|
|
4
|
+
declare const _default: DefineComponent<ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
5
|
+
modelValue?: RemoteSelectModelValue;
|
|
6
|
+
fetchApi: RemoteSelectFetchApi;
|
|
7
|
+
labelField?: string;
|
|
8
|
+
valueField?: string;
|
|
9
|
+
searchField?: string;
|
|
10
|
+
params?: Record<string, unknown>;
|
|
11
|
+
searchable?: boolean;
|
|
12
|
+
localFilter?: boolean;
|
|
13
|
+
paginated?: boolean;
|
|
14
|
+
pageSize?: number;
|
|
15
|
+
multiple?: boolean;
|
|
16
|
+
clearable?: boolean;
|
|
17
|
+
disabled?: boolean;
|
|
18
|
+
placeholder?: string;
|
|
19
|
+
dependsPlaceholder?: string;
|
|
20
|
+
immediate?: boolean;
|
|
21
|
+
autoClearOnParamsChange?: boolean;
|
|
22
|
+
allowEmpty?: boolean;
|
|
23
|
+
requiredParams?: string[];
|
|
24
|
+
initialLabel?: string;
|
|
25
|
+
collapseTags?: boolean;
|
|
26
|
+
collapseTagsTooltip?: boolean;
|
|
27
|
+
maxCollapseTags?: number;
|
|
28
|
+
}>, {
|
|
29
|
+
labelField: string;
|
|
30
|
+
valueField: string;
|
|
31
|
+
searchField: string;
|
|
32
|
+
searchable: boolean;
|
|
33
|
+
localFilter: boolean;
|
|
34
|
+
paginated: boolean;
|
|
35
|
+
pageSize: number;
|
|
36
|
+
multiple: boolean;
|
|
37
|
+
clearable: boolean;
|
|
38
|
+
disabled: boolean;
|
|
39
|
+
placeholder: string;
|
|
40
|
+
dependsPlaceholder: string;
|
|
41
|
+
immediate: boolean;
|
|
42
|
+
autoClearOnParamsChange: boolean;
|
|
43
|
+
allowEmpty: boolean;
|
|
44
|
+
requiredParams: () => never[];
|
|
45
|
+
collapseTags: boolean;
|
|
46
|
+
collapseTagsTooltip: boolean;
|
|
47
|
+
maxCollapseTags: number;
|
|
48
|
+
}>>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
49
|
+
"update:modelValue": (value: RemoteSelectModelValue) => void;
|
|
50
|
+
change: (value: RemoteSelectModelValue, option: Record<string, unknown> | null) => void;
|
|
51
|
+
paramsChange: (params: Record<string, unknown>) => void;
|
|
52
|
+
}, string, PublicProps, Readonly< ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
53
|
+
modelValue?: RemoteSelectModelValue;
|
|
54
|
+
fetchApi: RemoteSelectFetchApi;
|
|
55
|
+
labelField?: string;
|
|
56
|
+
valueField?: string;
|
|
57
|
+
searchField?: string;
|
|
58
|
+
params?: Record<string, unknown>;
|
|
59
|
+
searchable?: boolean;
|
|
60
|
+
localFilter?: boolean;
|
|
61
|
+
paginated?: boolean;
|
|
62
|
+
pageSize?: number;
|
|
63
|
+
multiple?: boolean;
|
|
64
|
+
clearable?: boolean;
|
|
65
|
+
disabled?: boolean;
|
|
66
|
+
placeholder?: string;
|
|
67
|
+
dependsPlaceholder?: string;
|
|
68
|
+
immediate?: boolean;
|
|
69
|
+
autoClearOnParamsChange?: boolean;
|
|
70
|
+
allowEmpty?: boolean;
|
|
71
|
+
requiredParams?: string[];
|
|
72
|
+
initialLabel?: string;
|
|
73
|
+
collapseTags?: boolean;
|
|
74
|
+
collapseTagsTooltip?: boolean;
|
|
75
|
+
maxCollapseTags?: number;
|
|
76
|
+
}>, {
|
|
77
|
+
labelField: string;
|
|
78
|
+
valueField: string;
|
|
79
|
+
searchField: string;
|
|
80
|
+
searchable: boolean;
|
|
81
|
+
localFilter: boolean;
|
|
82
|
+
paginated: boolean;
|
|
83
|
+
pageSize: number;
|
|
84
|
+
multiple: boolean;
|
|
85
|
+
clearable: boolean;
|
|
86
|
+
disabled: boolean;
|
|
87
|
+
placeholder: string;
|
|
88
|
+
dependsPlaceholder: string;
|
|
89
|
+
immediate: boolean;
|
|
90
|
+
autoClearOnParamsChange: boolean;
|
|
91
|
+
allowEmpty: boolean;
|
|
92
|
+
requiredParams: () => never[];
|
|
93
|
+
collapseTags: boolean;
|
|
94
|
+
collapseTagsTooltip: boolean;
|
|
95
|
+
maxCollapseTags: number;
|
|
96
|
+
}>>> & Readonly<{
|
|
97
|
+
"onUpdate:modelValue"?: ((value: RemoteSelectModelValue) => any) | undefined;
|
|
98
|
+
onChange?: ((value: RemoteSelectModelValue, option: Record<string, unknown> | null) => any) | undefined;
|
|
99
|
+
onParamsChange?: ((params: Record<string, unknown>) => any) | undefined;
|
|
100
|
+
}>, {
|
|
101
|
+
disabled: boolean;
|
|
102
|
+
placeholder: string;
|
|
103
|
+
immediate: boolean;
|
|
104
|
+
pageSize: number;
|
|
105
|
+
clearable: boolean;
|
|
106
|
+
multiple: boolean;
|
|
107
|
+
labelField: string;
|
|
108
|
+
valueField: string;
|
|
109
|
+
searchField: string;
|
|
110
|
+
searchable: boolean;
|
|
111
|
+
localFilter: boolean;
|
|
112
|
+
paginated: boolean;
|
|
113
|
+
dependsPlaceholder: string;
|
|
114
|
+
autoClearOnParamsChange: boolean;
|
|
115
|
+
allowEmpty: boolean;
|
|
116
|
+
requiredParams: string[];
|
|
117
|
+
collapseTags: boolean;
|
|
118
|
+
collapseTagsTooltip: boolean;
|
|
119
|
+
maxCollapseTags: number;
|
|
120
|
+
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
121
|
+
export default _default;
|
|
122
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
123
|
+
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
124
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
125
|
+
type: PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
126
|
+
} : {
|
|
127
|
+
type: PropType<T[K]>;
|
|
128
|
+
required: true;
|
|
129
|
+
};
|
|
130
|
+
};
|
|
131
|
+
type __VLS_WithDefaults<P, D> = {
|
|
132
|
+
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
133
|
+
default: D[K];
|
|
134
|
+
}> : P[K];
|
|
135
|
+
};
|
|
136
|
+
type __VLS_Prettify<T> = {
|
|
137
|
+
[K in keyof T]: T[K];
|
|
138
|
+
} & {};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/** 远程下拉 fetchApi 返回结构(组件内会自动适配多种格式) */
|
|
2
|
+
export type RemoteSelectFetchApi = (params: Record<string, unknown>) => Promise<unknown>;
|
|
3
|
+
export type RemoteSelectModelValue = string | number | null | (string | number)[];
|
|
4
|
+
export interface JRemoteSelectProps {
|
|
5
|
+
/** API 请求函数 */
|
|
6
|
+
fetchApi: RemoteSelectFetchApi;
|
|
7
|
+
/** 选项 label 字段名 */
|
|
8
|
+
labelField?: string;
|
|
9
|
+
/** 选项 value 字段名 */
|
|
10
|
+
valueField?: string;
|
|
11
|
+
/** 远程搜索时传给接口的参数名 */
|
|
12
|
+
searchField?: string;
|
|
13
|
+
/** 额外请求参数(支持联动) */
|
|
14
|
+
params?: Record<string, unknown>;
|
|
15
|
+
searchable?: boolean;
|
|
16
|
+
/** true=本地过滤已加载选项;false=远程搜索 */
|
|
17
|
+
localFilter?: boolean;
|
|
18
|
+
paginated?: boolean;
|
|
19
|
+
pageSize?: number;
|
|
20
|
+
multiple?: boolean;
|
|
21
|
+
clearable?: boolean;
|
|
22
|
+
disabled?: boolean;
|
|
23
|
+
placeholder?: string;
|
|
24
|
+
dependsPlaceholder?: string;
|
|
25
|
+
immediate?: boolean;
|
|
26
|
+
autoClearOnParamsChange?: boolean;
|
|
27
|
+
allowEmpty?: boolean;
|
|
28
|
+
requiredParams?: string[];
|
|
29
|
+
/** 选项未加载时的回显 label */
|
|
30
|
+
initialLabel?: string;
|
|
31
|
+
collapseTags?: boolean;
|
|
32
|
+
collapseTagsTooltip?: boolean;
|
|
33
|
+
maxCollapseTags?: number;
|
|
34
|
+
}
|
|
@@ -60,9 +60,9 @@ declare const __VLS_component: DefineComponent<ExtractPropTypes<__VLS_WithDefaul
|
|
|
60
60
|
}>, {
|
|
61
61
|
showSearch: boolean;
|
|
62
62
|
showReset: boolean;
|
|
63
|
+
defaultVisible: number;
|
|
63
64
|
selectedCount: number;
|
|
64
65
|
addText: string;
|
|
65
|
-
defaultVisible: number;
|
|
66
66
|
showAdd: boolean;
|
|
67
67
|
showBatchDelete: boolean;
|
|
68
68
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
package/dist/index.d.ts
CHANGED
|
@@ -9,6 +9,7 @@ import { JSidebar, JSideMenuItem } from './components/JSidebar';
|
|
|
9
9
|
import { JAdminLayout } from './components/JAdminLayout';
|
|
10
10
|
import { JProductDetailDialog, JSkuLink, ProductDetailHost } from './components/JProductDetail';
|
|
11
11
|
import { JSearchInputDialog } from './components/JSearchInputDialog';
|
|
12
|
+
import { JRemoteSelect } from './components/JRemoteSelect';
|
|
12
13
|
import { DocNoLink, DocDetailHost } from './components/JDocDetail';
|
|
13
14
|
import { JRelatedDocs } from './components/JRelatedDocs';
|
|
14
15
|
|
|
@@ -16,7 +17,7 @@ declare const _default: {
|
|
|
16
17
|
install: (app: App) => void;
|
|
17
18
|
};
|
|
18
19
|
export default _default;
|
|
19
|
-
export { JButton, JUploadImg, JIconRender, JSearchHeader, JListSearchHeader, JImportExcel, JSidebar, JSideMenuItem, JAdminLayout, JProductDetailDialog, JSkuLink, ProductDetailHost, JSearchInputDialog, DocNoLink, DocDetailHost, JRelatedDocs, };
|
|
20
|
+
export { JButton, JUploadImg, JIconRender, JSearchHeader, JListSearchHeader, JImportExcel, JSidebar, JSideMenuItem, JAdminLayout, JProductDetailDialog, JSkuLink, ProductDetailHost, JSearchInputDialog, JRemoteSelect, DocNoLink, DocDetailHost, JRelatedDocs, };
|
|
20
21
|
export { useProductDetailDialog, useProductDetailStore, provideProductRequest, resolveProductRequest, useInjectedProductRequest, J_PRODUCT_REQUEST_KEY, } from './components/JProductDetail';
|
|
21
22
|
export { createDocDetail, registerDocDetail, getDocDetailAdapters, getDocDetailEntry, getDocDetailRegistry, isDocDetailInitialized, useDocDetailStore, wmsDocDetailComponents, ReceiptOrderDetailView, QcOrderDetailView, InboundOrderDetailView, PutawayOrderDetailView, DeliveryOrderDetailView, TransferOrderDetailView, WorkOrderDetailView, AbnormalOrderDetailView, PaymentRequestDetailView, ReturnOrderDetailView, CostExpenseDetailView, ReceiptVoucherDetailView, PurchaseOrderDetailView, PurchasePlanDetailView, PurchaseContractDetailView, DeliveryDocDetailView, } from './components/JDocDetail';
|
|
22
23
|
export { createRelatedDocs, registerRelatedDocs, getRelatedListAdapter, getRelatedTableComponent, getRelatedDocsTableComponents, isRelatedDocsInitialized, RelatedDocSubTabs, RelatedDocNoCopy, RelatedDocPanel, RelatedReceiptOrderTable, RelatedQcOrderTable, RelatedInboundOrderTable, RelatedPutawayOrderTable, flattenOrderItems, sumOrderItemField, useRelatedCollapseExpand, parseListResponse, } from './components/JRelatedDocs';
|
|
@@ -35,5 +36,6 @@ export type { SidebarMenuItem, JSidebarProps, JSideMenuItemProps } from './compo
|
|
|
35
36
|
export type { AdminLayoutMenuItem, JAdminLayoutProps } from './components/JAdminLayout';
|
|
36
37
|
export type { JProductDetailDialogProps, JSkuLinkProps, JProductRequestFn, JProductRequestConfig, } from './components/JProductDetail';
|
|
37
38
|
export type { JSearchInputDialogProps, SearchInputOption, SearchInputModel, } from './components/JSearchInputDialog';
|
|
39
|
+
export type { JRemoteSelectProps, RemoteSelectFetchApi, RemoteSelectModelValue, } from './components/JRemoteSelect';
|
|
38
40
|
export type { DocDetailType, DocDetailAdapters, DocDetailRegistryItem, DocDetailComponents, CreateDocDetailOptions, } from './components/JDocDetail';
|
|
39
41
|
export type { RelatedListAdapter, RelatedDocTypeItem, CreateRelatedDocsOptions, RelatedDocsContainerProps, } from './components/JRelatedDocs';
|