@asaleh37/ui-base 1.2.17 → 1.2.19
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/.env.development +1 -1
- package/dist/index.d.ts +27 -5
- package/dist/index.js +5 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +5 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/public/no_image.png +0 -0
- package/src/components/administration/admin/OrganizationApplicationModuleGrid.tsx +10 -34
- package/src/components/administration/admin/OrganizationGrid.tsx +4 -87
- package/src/components/administration/admin/OrganizationRankGrid.tsx +34 -16
- package/src/components/administration/admin/OrganizationUnitGrid.tsx +34 -30
- package/src/components/administration/admin/OrganizationUnitTypeGrid.tsx +3 -16
- package/src/components/administration/admin/PersonGrid.tsx +38 -1
- package/src/components/administration/admin/RoleAuthoritiesForm.tsx +2 -4
- package/src/components/administration/admin/SystemApplicationAuthorityGrid.tsx +2 -18
- package/src/components/administration/admin/SystemApplicationGrid.tsx +5 -83
- package/src/components/administration/admin/SystemApplicationModuleGrid.tsx +2 -15
- package/src/components/administration/admin/SystemApplicationRoleGrid.tsx +1 -15
- package/src/components/administration/dev/AttachmentConfigGrid.tsx +213 -0
- package/src/components/administration/dev/AttachmentGrid.tsx +172 -0
- package/src/components/administration/dev/LookupGrid.tsx +1 -12
- package/src/components/common/Home.tsx +24 -22
- package/src/components/templates/DataEntryTemplates/DataEntryTypes.ts +13 -1
- package/src/components/templates/DataEntryTemplates/DataEntryUtil.ts +6 -0
- package/src/components/templates/DataEntryTemplates/TemplateDataForm/FormElementField.tsx +1 -3
- package/src/components/templates/DataEntryTemplates/TemplateDataForm/FormFields/SystemLookupCombobox.tsx +1 -1
- package/src/components/templates/DataEntryTemplates/TemplateDataForm/TemplateForm.tsx +100 -8
- package/src/components/templates/DataEntryTemplates/TemplateDataGrid/TemplateGrid.tsx +113 -4
- package/src/components/templates/attachment/AttachmentCard.tsx +126 -0
- package/src/components/templates/attachment/AttachmentImageViewer.tsx +44 -0
- package/src/components/templates/attachment/AttachmentPanel.tsx +269 -0
- package/src/components/templates/workflow/WorkflowDocumentPanel.tsx +4 -4
- package/src/hooks/UseSession.tsx +20 -2
- package/src/hooks/useAxios.tsx +71 -11
- package/src/hooks/useLookupGridColumn.tsx +2 -2
- package/src/layout/MainContent.tsx +49 -46
- package/src/layout/TopBar.tsx +6 -1
- package/src/locales/arabic/devLocalsAr.json +13 -1
- package/src/locales/english/devLocalsEn.json +13 -1
- package/src/main.tsx +3 -3
- package/src/navigationItems/Administration/adminNavigationItems.tsx +77 -3
- package/src/redux/features/administration/AdministrationStoresMetaData.ts +14 -6
- package/src/routes/administration/adminRoutes.tsx +21 -0
- package/src/routes/administration/devRoutes.tsx +24 -0
- package/public/icons/LICENSE.md +0 -5
- package/public/icons/arrow-clockwise.svg +0 -4
- package/public/icons/arrow-counterclockwise.svg +0 -4
- package/public/icons/journal-text.svg +0 -5
- package/public/icons/justify.svg +0 -3
- package/public/icons/text-center.svg +0 -3
- package/public/icons/text-left.svg +0 -3
- package/public/icons/text-paragraph.svg +0 -3
- package/public/icons/text-right.svg +0 -3
- package/public/icons/type-bold.svg +0 -3
- package/public/icons/type-italic.svg +0 -3
- package/public/icons/type-strikethrough.svg +0 -3
- package/public/icons/type-underline.svg +0 -3
package/.env.development
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
VITE_API_URL=http://localhost:8080/
|
|
1
|
+
VITE_API_URL=http://localhost:8080/api-base
|
package/dist/index.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ import react__default from 'react';
|
|
|
11
11
|
import { GridColDef, GridRowSelectionModel, DataGridPremiumProps, GridToolbarProps, ToolbarPropsOverrides } from '@mui/x-data-grid-premium';
|
|
12
12
|
import { UseFormReturn } from 'react-hook-form';
|
|
13
13
|
export * from '@mui/x-tree-view/models';
|
|
14
|
+
import { ResponseType } from 'axios';
|
|
14
15
|
|
|
15
16
|
interface SystemRoute {
|
|
16
17
|
path: string;
|
|
@@ -238,7 +239,13 @@ type TemplateGridColDef = GridColDef & {
|
|
|
238
239
|
displayField?: string;
|
|
239
240
|
valueField?: string;
|
|
240
241
|
};
|
|
242
|
+
type TemplateGridAttachmentProps = {
|
|
243
|
+
attachmentCode: string;
|
|
244
|
+
enableAttachFn?: (record: any) => boolean;
|
|
245
|
+
};
|
|
241
246
|
type TemplateGridProps = {
|
|
247
|
+
workFlowDocumentCode?: string;
|
|
248
|
+
attachment?: TemplateGridAttachmentProps;
|
|
242
249
|
formElements: Array<FormElementProps>;
|
|
243
250
|
gridStateKey?: string;
|
|
244
251
|
data: Array<any>;
|
|
@@ -304,7 +311,7 @@ type FormElementSize = {
|
|
|
304
311
|
type RecordFieldProps = {
|
|
305
312
|
fieldName: string;
|
|
306
313
|
fieldLabel: string;
|
|
307
|
-
fieldType: "text" | "number" | "date" | "datetime" | "combobox" | "checkbox" | "html" | "lookup";
|
|
314
|
+
fieldType: "text" | "number" | "date" | "datetime" | "combobox" | "checkbox" | "html" | "lookup" | "custom";
|
|
308
315
|
lookupType?: string;
|
|
309
316
|
required?: boolean;
|
|
310
317
|
disabled?: boolean;
|
|
@@ -371,6 +378,9 @@ type FormActionProps = {
|
|
|
371
378
|
enableField: (fieldName: string) => void;
|
|
372
379
|
};
|
|
373
380
|
type TemplateFormProps = {
|
|
381
|
+
workFlowDocumentCode?: string;
|
|
382
|
+
attachment?: TemplateGridAttachmentProps;
|
|
383
|
+
keyColumnName?: any;
|
|
374
384
|
elements: Array<FormElementProps>;
|
|
375
385
|
findByIdParamName?: string;
|
|
376
386
|
recordIdToEdit?: any;
|
|
@@ -415,12 +425,24 @@ interface APIRequest {
|
|
|
415
425
|
loadingMessage?: string;
|
|
416
426
|
successCallBkFn?: Function;
|
|
417
427
|
failureCallBkFn?: Function;
|
|
428
|
+
headers?: any;
|
|
429
|
+
responseType?: ResponseType;
|
|
430
|
+
}
|
|
431
|
+
interface UploadAttachmentRequest {
|
|
432
|
+
endPointURI: string;
|
|
433
|
+
showMask?: Boolean;
|
|
434
|
+
parameters?: any;
|
|
435
|
+
loadingMessage?: string;
|
|
436
|
+
successCallBkFn?: Function;
|
|
437
|
+
failureCallBkFn?: Function;
|
|
438
|
+
files: FileList;
|
|
418
439
|
}
|
|
419
440
|
declare const useAxios: () => {
|
|
420
|
-
handleGetRequest: (props
|
|
421
|
-
handlePostRequest: (props
|
|
422
|
-
handleDeleteRequest: (props
|
|
441
|
+
handleGetRequest: (props: APIRequest) => Promise<any>;
|
|
442
|
+
handlePostRequest: (props: APIRequest) => Promise<any>;
|
|
443
|
+
handleDeleteRequest: (props: APIRequest) => Promise<any>;
|
|
423
444
|
HandleDownloadHTTPPostPDF: (props?: APIRequest) => Promise<any>;
|
|
445
|
+
handleUploadRequest: (props: UploadAttachmentRequest) => Promise<any>;
|
|
424
446
|
};
|
|
425
447
|
|
|
426
448
|
interface ConfirmationWindowProps {
|
|
@@ -479,4 +501,4 @@ declare const DARK_THEME_INITIAL_MAIN_COLOR = "#ea690e";
|
|
|
479
501
|
declare const DARK_THEME_INITIAL_SECANDARY_COLOR = "#74776B";
|
|
480
502
|
|
|
481
503
|
export { BaseApp, CheckBox, ComboBox, DARK_THEME_INITIAL_MAIN_COLOR, DARK_THEME_INITIAL_SECANDARY_COLOR, DATE_FORMAT, DATE_TIME_FORMAT, Datefield, DatetimeField, LIGHT_THEME_INITIAL_MAIN_COLOR, LIGHT_THEME_INITIAL_SECANDARY_COLOR, TemplateBarChart, TemplateDataCard, TemplateForm, TemplateGauge, TemplateGrid, TemplateLineChart, TemplateLineProgress, TemplatePieChart, TemplateTextField, TransferList, capitalizeFirstLetter, hasDigitsOnly, isNumber, isNumeric, isValidEmail, useApiActions, useAxios, useConfirmationWindow, useIsMobile, useLoadingMask, useSession, useWindow };
|
|
482
|
-
export type { EditDeleteAction, ExtendedTreeItemProps, FormActionProps, FormElementFieldProps, FormElementGroupProps, FormElementNodeProps, FormElementProps, FormElementSize, MakeOptional, ModalFormProps, RecordAction, RecordFieldProps, SystemRoute, TemplateFormProps, TemplateGridColDef, TemplateGridColumnProps, TemplateGridProps, TemplateGridTopBarProps, TransferListProps };
|
|
504
|
+
export type { EditDeleteAction, ExtendedTreeItemProps, FormActionProps, FormElementFieldProps, FormElementGroupProps, FormElementNodeProps, FormElementProps, FormElementSize, MakeOptional, ModalFormProps, RecordAction, RecordFieldProps, SystemRoute, TemplateFormProps, TemplateGridAttachmentProps, TemplateGridColDef, TemplateGridColumnProps, TemplateGridProps, TemplateGridTopBarProps, TransferListProps };
|