tsv2-library 0.2.63 → 0.2.65

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.
@@ -1,17 +1,20 @@
1
- import type { App } from 'vue';
1
+ import type { App, MaybeRef, MaybeRefOrGetter } from 'vue';
2
2
  import LibConfig from '../node_modules/primevue/config';
3
3
  import TSToastService from '../node_modules/primevue/toastservice';
4
4
  import AssetsServices from './services/assets.service';
5
+ import AssetNameService from './services/assetName.service';
6
+ import AssetBrandService from './services/assetBrand.service';
5
7
  import DisposalServices, { API as DisposalAPI } from './services/disposal.service';
6
8
  import { FilterMatchMode } from '../node_modules/primevue/api';
7
9
  import { API as TreeAPI } from './services/tree.service';
8
10
  import RoutineServices, { API as RoutineAPI } from './services/routine.service';
9
- import { FormContext } from 'vee-validate';
11
+ import { FormContext, FieldContext, RuleExpression, FieldOptions } from 'vee-validate';
10
12
  interface TSFormContext<T> {
11
13
  values: T;
12
14
  handleSubmit: FormContext['handleSubmit'];
13
15
  }
14
16
  declare const useForm: <T>() => TSFormContext<T>;
17
+ declare const useField: <T>(path: MaybeRefOrGetter<string>, rules?: MaybeRef<RuleExpression<T>>, opts?: Partial<FieldOptions<T>> | undefined) => FieldContext<T>;
15
18
  import { handleTokenExpiration, exportToExcel, formatDate, formatDateReadable, formatUserName, formatVowelSoundLabel, getImageURL, isObjectEmpty, useToast, listenSidebarChanges, unListenSidebarChanges, getCurrency, formatCurrency, getHostName, getBaseURL, useI18n, getNestedProperyValue, getSeverityByAssetStatus, clearStorage, forceLogout, reLogin, getTransactionRole, getSystemRole, hasSystemRole, hasTransactionRole, checkRouteAccess, hasApprovalRole, hasManagerRole, hasAnyManagerRole, hasMonitoringReportRole, hasAnyMonitoringReportRole, hasStaffRole } from './utils';
16
19
  import { flattenTreeNodeChildren, parseNodeKeys, filterNodeKeys } from './components/v2/Tree/helpers';
17
20
  import useLoadingStore from './components/v2/Loading/store/loading.store';
@@ -2849,4 +2852,4 @@ declare const _default: {
2849
2852
  install: (app: App) => void;
2850
2853
  };
2851
2854
  export default _default;
2852
- export { LibConfig, TSToastService, TSi18n, VueHtmlToPaper, Tooltip, Focus, TSAssetInfo, TSApproverInfo, TSBadge, TSBadgeGroup, TSBreadcrumb, TSButton, TSButtonAddByScan, TSButtonBulkAction, TSButtonCopy, TSButtonDownload, TSButtonFilter, TSButtonLogHistory, TSButtonRadio, TSButtonViewLog, TSButtonScan, TSButtonSearch, TSButtonSearchByScan, TSButtonSelectTree, TSButtonSelectUser, TSButtonSync, TSButtonToggle, TSCalendar, TSCard, TSCarousel, TSCheckbox, TSCustomColumn, TSDatePicker, TSDataTable, TSDayPicker, TSDialog, TSDialogApprovalList, TSDialogAssetNameDetail, TSDialogConfirm, TSDialogForm, TSDialogLinkedAsset, TSDialogPrintQR, TSDialogReportDamage, TSDialogReportMissing, TSDialogReportTag, TSDialogSelectTree, TSDialogSelectAsset, TSDialogSelectUser, TSDisposalReport, TSDropdown, TSFilterContainer, TSFileUpload, TSForm, TSIcon, TSImage, TSImageCompressor, TSInlineMessage, TSInputBadge, TSInputCurrency, TSInputEmail, TSInputNumber, TSInputOTP, TSInputPassword, TSInputPhoneNumber, TSInputRangeNumber, TSInputText, TSInputSearch, TSInputURL, TSLoading, TSMenu, TSMultiSelect, TSOverlayPanel, TSPaginator, TSProgressBar, TSSteps, TSTabMenu, TSTagType, TSTextarea, TSTimeline, TSToast, TSTransactionRoles, TSTree, TSTreeSearchInput, TSUserWithIcon, TSValidatorMessage, handleTokenExpiration, exportToExcel, formatDate, formatDateReadable, formatUserName, formatVowelSoundLabel, getImageURL, isObjectEmpty, useToast, listenSidebarChanges, unListenSidebarChanges, getCurrency, formatCurrency, getHostName, getBaseURL, useI18n, useForm, getNestedProperyValue, getSeverityByAssetStatus, clearStorage, forceLogout, reLogin, getTransactionRole, getSystemRole, hasSystemRole, hasTransactionRole, checkRouteAccess, hasApprovalRole, hasManagerRole, hasAnyManagerRole, hasMonitoringReportRole, hasAnyMonitoringReportRole, hasStaffRole, flattenTreeNodeChildren, parseNodeKeys, filterNodeKeys, TreeAPI, RoutineAPI, DisposalAPI, RoutineServices, AssetsServices, DisposalServices, FilterMatchMode, useLoadingStore, };
2855
+ export { LibConfig, TSToastService, TSi18n, VueHtmlToPaper, Tooltip, Focus, TSAssetInfo, TSApproverInfo, TSBadge, TSBadgeGroup, TSBreadcrumb, TSButton, TSButtonAddByScan, TSButtonBulkAction, TSButtonCopy, TSButtonDownload, TSButtonFilter, TSButtonLogHistory, TSButtonRadio, TSButtonViewLog, TSButtonScan, TSButtonSearch, TSButtonSearchByScan, TSButtonSelectTree, TSButtonSelectUser, TSButtonSync, TSButtonToggle, TSCalendar, TSCard, TSCarousel, TSCheckbox, TSCustomColumn, TSDatePicker, TSDataTable, TSDayPicker, TSDialog, TSDialogApprovalList, TSDialogAssetNameDetail, TSDialogConfirm, TSDialogForm, TSDialogLinkedAsset, TSDialogPrintQR, TSDialogReportDamage, TSDialogReportMissing, TSDialogReportTag, TSDialogSelectTree, TSDialogSelectAsset, TSDialogSelectUser, TSDisposalReport, TSDropdown, TSFilterContainer, TSFileUpload, TSForm, TSIcon, TSImage, TSImageCompressor, TSInlineMessage, TSInputBadge, TSInputCurrency, TSInputEmail, TSInputNumber, TSInputOTP, TSInputPassword, TSInputPhoneNumber, TSInputRangeNumber, TSInputText, TSInputSearch, TSInputURL, TSLoading, TSMenu, TSMultiSelect, TSOverlayPanel, TSPaginator, TSProgressBar, TSSteps, TSTabMenu, TSTagType, TSTextarea, TSTimeline, TSToast, TSTransactionRoles, TSTree, TSTreeSearchInput, TSUserWithIcon, TSValidatorMessage, handleTokenExpiration, exportToExcel, formatDate, formatDateReadable, formatUserName, formatVowelSoundLabel, getImageURL, isObjectEmpty, useToast, listenSidebarChanges, unListenSidebarChanges, getCurrency, formatCurrency, getHostName, getBaseURL, useI18n, useForm, useField, getNestedProperyValue, getSeverityByAssetStatus, clearStorage, forceLogout, reLogin, getTransactionRole, getSystemRole, hasSystemRole, hasTransactionRole, checkRouteAccess, hasApprovalRole, hasManagerRole, hasAnyManagerRole, hasMonitoringReportRole, hasAnyMonitoringReportRole, hasStaffRole, flattenTreeNodeChildren, parseNodeKeys, filterNodeKeys, TreeAPI, RoutineAPI, DisposalAPI, RoutineServices, AssetsServices, AssetNameService, AssetBrandService, DisposalServices, FilterMatchMode, useLoadingStore, };
@@ -0,0 +1,18 @@
1
+ import { AxiosInstance, AxiosResponse } from 'axios';
2
+ export interface ServiceOptions {
3
+ headers?: Record<string, unknown>;
4
+ params?: Record<string, unknown>;
5
+ }
6
+ export interface AssetBrandDropdownOption {
7
+ _id: string;
8
+ key: number;
9
+ name: string;
10
+ }
11
+ export interface GetAssetBrandDropdownResponse {
12
+ data: AssetBrandDropdownOption[];
13
+ }
14
+ export declare const API: ({ headers, params, }?: ServiceOptions) => AxiosInstance;
15
+ declare const AssetBrandService: {
16
+ getAssetBrandDropdown: () => Promise<AxiosResponse<GetAssetBrandDropdownResponse>>;
17
+ };
18
+ export default AssetBrandService;
@@ -12,12 +12,27 @@ export type GetAssetNameListQueryParams = {
12
12
  assetName?: string;
13
13
  tagType?: string;
14
14
  };
15
+ export interface AssetNameDropdownOption {
16
+ _id: string;
17
+ key: number;
18
+ name: string;
19
+ category: {
20
+ _id: string;
21
+ name: string;
22
+ key: number;
23
+ };
24
+ tagType: string;
25
+ }
26
+ export interface GetAssetNameDropdownResponse {
27
+ data: AssetNameDropdownOption[];
28
+ }
15
29
  export declare const API: ({ headers, params, }?: ServiceOptions) => AxiosInstance;
16
30
  declare const _default: {
17
31
  getAssetNameDetail: (id: string) => Promise<AxiosResponse<any, any>>;
18
32
  getAssetNameList: (params: GetAssetNameListQueryParams) => Promise<AxiosResponse<any, any>>;
19
33
  getAssetsByAssetName: (id: string, params?: DataTableParams | undefined) => Promise<AxiosResponse<any, any>>;
20
34
  getUnpairedAssetName: (params: GetAssetNameListQueryParams) => Promise<AxiosResponse<any, any>>;
35
+ getAssetNameDropdown: () => Promise<AxiosResponse<GetAssetNameDropdownResponse, any>>;
21
36
  getOptions: (params: AssetNameOptionsQueryParams) => Promise<AxiosResponse<any, any>>;
22
37
  };
23
38
  export default _default;