ods-component-lib 1.18.213 → 1.18.215

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.
@@ -12,6 +12,7 @@ declare const _default: {
12
12
  export default _default;
13
13
  export declare const Default: any;
14
14
  export declare const DefaultByCode: any;
15
+ export declare const DefaultByCurrencyId: any;
15
16
  export declare const EnLocale: any;
16
17
  export declare const FixedCurrencyWithDefaultCurrencyId: any;
17
18
  export declare const FixedCurrencyDefaultCurrencyCode: any;
@@ -1,15 +1,11 @@
1
1
  import { InputNumberProps, SelectProps } from "antd";
2
2
  export declare type OdsCurrencyInputProps = InputNumberProps & {
3
- onChange?: (result: OdsCurrencyInputResultType) => void;
3
+ onChange?: (result: number) => void;
4
4
  locale?: string;
5
5
  dontFormatValue?: boolean;
6
6
  disableNegative?: boolean;
7
7
  defaultValue?: number;
8
- currencySelectProps: Omit<CurrencySelectProps, 'onSelect'>;
9
- };
10
- export declare type OdsCurrencyInputResultType = {
11
- value?: number | string;
12
- currency: CurrencyOptionType;
8
+ currencySelectProps: CurrencySelectProps;
13
9
  };
14
10
  export declare type CurrencyOptionType = {
15
11
  id: number;
@@ -19,7 +15,8 @@ export declare type CurrencyOptionType = {
19
15
  };
20
16
  export declare type CurrencySelectProps = SelectProps & {
21
17
  currencyOptions: CurrencyOptionType[];
22
- onSelect: (selectedObject?: CurrencyOptionType) => void;
18
+ onSelect?: (selectedId: number | null | undefined) => void;
19
+ value?: number;
23
20
  defaultCurrencyId?: number;
24
21
  defaultCurrencyCode?: string;
25
22
  fixedCurrency?: boolean;
@@ -0,0 +1,52 @@
1
+ import type { UploadProps } from "antd";
2
+ import React from "react";
3
+ declare enum FileType {
4
+ Images = 1,
5
+ Icons = 2,
6
+ Docs = 3
7
+ }
8
+ declare enum ModuleType {
9
+ Accounting = 1,
10
+ Agency = 2,
11
+ ExtraService = 3,
12
+ Flight = 4,
13
+ HandlingFee = 5,
14
+ Insurance = 6,
15
+ MasterData = 7,
16
+ Tour = 8,
17
+ Visa = 9,
18
+ Transfer = 10
19
+ }
20
+ interface IValidationMessageOptions {
21
+ sizeValidationFailMessage?: string;
22
+ typeValidationFailMessage?: string;
23
+ }
24
+ interface IUploadRequestModel {
25
+ uid: string;
26
+ file: any;
27
+ fileName: string;
28
+ fileType: FileType;
29
+ moduleType: ModuleType;
30
+ operatorId: number;
31
+ }
32
+ declare type FileUploadProps = {
33
+ image: any | null;
34
+ title: string;
35
+ uploadTitle?: string;
36
+ defaultFileList?: UploadProps["defaultFileList"];
37
+ showUploadList?: UploadProps["showUploadList"];
38
+ allowDocumentUpload?: boolean;
39
+ isMultipleDoc?: boolean;
40
+ removeFile?: (file: any) => void;
41
+ customValidationMessages: IValidationMessageOptions;
42
+ removeTitle?: string;
43
+ removeOkText?: string;
44
+ removeCancelText?: string;
45
+ skipSizeValidation?: boolean;
46
+ maxFileSizeMB?: number;
47
+ moduleType?: number;
48
+ operatorId?: number;
49
+ uploadFile?: (request: IUploadRequestModel) => void;
50
+ };
51
+ declare function OdsFileUploadv2(props: FileUploadProps): React.JSX.Element;
52
+ export default OdsFileUploadv2;
@@ -15,7 +15,7 @@ interface IPagerProps {
15
15
  visible?: boolean;
16
16
  showPageSizeSelector?: boolean;
17
17
  showInfo?: boolean;
18
- displayMode?: 'full' | 'compact';
18
+ displayMode?: "full" | "compact";
19
19
  infoText?: string;
20
20
  }
21
21
  interface IExportProps {
@@ -62,13 +62,17 @@ export interface ISummaryRowOptions {
62
62
  summaryCountLabel?: string;
63
63
  }
64
64
  export declare type IActionButtonsTooltipType = "raw" | "styled";
65
+ export interface IActionButtonGroup extends Partial<IButtonGroup> {
66
+ elementType?: "button" | "element";
67
+ element?: JSX.Element;
68
+ }
65
69
  export interface IVirtualDataGridProps extends IDataGridOptions {
66
70
  columns: IColumnConfig[];
67
71
  sortingProps?: any;
68
72
  pagerProps?: IPagerProps;
69
73
  exportProps?: IExportProps;
70
74
  customSummary?: ISummaryRowOptions;
71
- actionButtonGroup?: IButtonGroup[];
75
+ actionButtonGroup?: IActionButtonGroup[];
72
76
  actionColumnEnable?: boolean;
73
77
  pageTitle?: string;
74
78
  language?: string;
@@ -79,7 +83,7 @@ export interface IVirtualDataGridProps extends IDataGridOptions {
79
83
  columnChooserPositionDisabled?: boolean;
80
84
  dataGridPageName?: string;
81
85
  totalRecordCount: number;
82
- columnResizingMode?: 'nextColumn' | 'widget';
86
+ columnResizingMode?: "nextColumn" | "widget";
83
87
  dataGridRef: any;
84
88
  applyCellRenderToHeaderFilter?: boolean;
85
89
  actionButtonsTooltipType?: IActionButtonsTooltipType;
package/dist/index.d.ts CHANGED
@@ -57,6 +57,7 @@ import OdsInlineEditDataGrid from "./components/devextreme/OdsInlineEditDataGrid
57
57
  import OdsMasterDetailDataGrid from "./components/devextreme/OdsMasterDetailDataGrid/OdsMasterDetailDataGrid";
58
58
  import OdsChange from "./components/antd/change/OdsChange";
59
59
  import OdsProgress from "./components/antd/progress/OdsProgress";
60
+ import OdsFileUploadv2 from "./components/antd/fileUpload/OdsFileUploadv2";
60
61
  export { default as OdsTreeSelect } from "./components/antd/treeSelect/OdsTreeSelect";
61
62
  export { default as OdsCurrencyInput } from "./components/antd/currencyInput/OdsCurrencyInput";
62
63
  export { OdsButton };
@@ -119,3 +120,4 @@ export { OdsChange };
119
120
  export { OdsServerSideDatagrid };
120
121
  export { OdsInlineEditDataGrid };
121
122
  export { OdsProgress };
123
+ export { OdsFileUploadv2 };