@tagsamurai/fats-api-services 1.0.3-alpha.1 → 1.0.3-alpha.10
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/api-services.es.js +30 -3
- package/api-services.system.js +32 -5
- package/main.d.ts +1 -0
- package/package.json +1 -1
- package/src/dto/reader.dto.d.ts +20 -0
- package/src/services/log.service.d.ts +4 -4
- package/src/services/oldReader.service.d.ts +14 -3
- package/src/types/log.type.d.ts +9 -0
- package/src/types/reader.type.d.ts +36 -19
package/api-services.es.js
CHANGED
|
@@ -98,14 +98,16 @@ const ChangelogServices$1 = {
|
|
|
98
98
|
getActionLog: (params) => {
|
|
99
99
|
return API$K.get("/change-log", { params });
|
|
100
100
|
},
|
|
101
|
-
getActionLogOption: (
|
|
102
|
-
return API$K.get("/change-log/options"
|
|
101
|
+
getActionLogOption: () => {
|
|
102
|
+
return API$K.get("/change-log/options");
|
|
103
103
|
},
|
|
104
104
|
getSessionLogList: (params) => {
|
|
105
105
|
return API$K.get("/session-log", { params });
|
|
106
106
|
},
|
|
107
107
|
getSessionLogListOptions: (params) => {
|
|
108
|
-
return API$K.get("/session-log/options", {
|
|
108
|
+
return API$K.get("/session-log/options", {
|
|
109
|
+
params
|
|
110
|
+
});
|
|
109
111
|
},
|
|
110
112
|
getTransactionLog: (params) => {
|
|
111
113
|
return API$K.get("/transaction-log", { params });
|
|
@@ -1907,6 +1909,30 @@ const ReaderServices = {
|
|
|
1907
1909
|
setIOTAliasName: (body) => {
|
|
1908
1910
|
return API$b.put("/set-alias-name", body);
|
|
1909
1911
|
},
|
|
1912
|
+
pingIOTSingle: (id) => {
|
|
1913
|
+
return API$b.put(`/${id}/ping`);
|
|
1914
|
+
},
|
|
1915
|
+
//https://dev-api.tagsamurai.com/fam/iot/v2/iot/reader/:id/set-antenna-power
|
|
1916
|
+
setIOTAntennaPowerBulk: (id, body) => {
|
|
1917
|
+
return API$b.put(`/${id}/set-antenna-power`, body);
|
|
1918
|
+
},
|
|
1919
|
+
//https://dev-api.tagsamurai.com/fam/iot/v2/iot/reader/:id/ports
|
|
1920
|
+
getIOTPortList: (id, params) => {
|
|
1921
|
+
return API$b.get(`/${id}/ports`, { params });
|
|
1922
|
+
},
|
|
1923
|
+
getIOTDetail: (id) => {
|
|
1924
|
+
return API$b.get(`/${id}`);
|
|
1925
|
+
},
|
|
1926
|
+
//https://dev-api.tagsamurai.com/fam/iot/v2/iot/reader/check-manager
|
|
1927
|
+
getIOTCheckManager: () => {
|
|
1928
|
+
return API$b.get("/check-manager");
|
|
1929
|
+
},
|
|
1930
|
+
setIOTPortGroup: (id, body) => {
|
|
1931
|
+
return API$b.put(`/${id}/set-port-group`, body);
|
|
1932
|
+
},
|
|
1933
|
+
setGroupIOT: (body) => {
|
|
1934
|
+
return API$b.put("/set-group", body);
|
|
1935
|
+
},
|
|
1910
1936
|
getActivityLogData: (params) => {
|
|
1911
1937
|
return API$b.get("/activity-log", { params });
|
|
1912
1938
|
},
|
|
@@ -2593,6 +2619,7 @@ export {
|
|
|
2593
2619
|
MissingServices,
|
|
2594
2620
|
ModelTypeServices,
|
|
2595
2621
|
MyAssetServices,
|
|
2622
|
+
ChangelogServices$1 as NewChangelogServices,
|
|
2596
2623
|
NotificationApprovalServices,
|
|
2597
2624
|
NotificationServices,
|
|
2598
2625
|
DisposalServices as OldDisposalServices,
|
package/api-services.system.js
CHANGED
|
@@ -101,18 +101,20 @@ System.register(["axios"], function(exports, module) {
|
|
|
101
101
|
const API$K = createAxiosInstance({
|
|
102
102
|
prefix: "/utility/v2"
|
|
103
103
|
});
|
|
104
|
-
const ChangelogServices$1 =
|
|
104
|
+
const ChangelogServices$1 = {
|
|
105
105
|
getActionLog: (params) => {
|
|
106
106
|
return API$K.get("/change-log", { params });
|
|
107
107
|
},
|
|
108
|
-
getActionLogOption: (
|
|
109
|
-
return API$K.get("/change-log/options"
|
|
108
|
+
getActionLogOption: () => {
|
|
109
|
+
return API$K.get("/change-log/options");
|
|
110
110
|
},
|
|
111
111
|
getSessionLogList: (params) => {
|
|
112
112
|
return API$K.get("/session-log", { params });
|
|
113
113
|
},
|
|
114
114
|
getSessionLogListOptions: (params) => {
|
|
115
|
-
return API$K.get("/session-log/options", {
|
|
115
|
+
return API$K.get("/session-log/options", {
|
|
116
|
+
params
|
|
117
|
+
});
|
|
116
118
|
},
|
|
117
119
|
getTransactionLog: (params) => {
|
|
118
120
|
return API$K.get("/transaction-log", { params });
|
|
@@ -142,7 +144,8 @@ System.register(["axios"], function(exports, module) {
|
|
|
142
144
|
getUserDetailUserLogAssignmentOption: (userId, params) => {
|
|
143
145
|
return API$K.get(`/assignment-log/${userId}/options`, { params });
|
|
144
146
|
}
|
|
145
|
-
}
|
|
147
|
+
};
|
|
148
|
+
exports({ LogServices: ChangelogServices$1, NewChangelogServices: ChangelogServices$1 });
|
|
146
149
|
const AssetsAPIs = createAxiosInstance({
|
|
147
150
|
prefix: "/assets/v2/assets"
|
|
148
151
|
});
|
|
@@ -1914,6 +1917,30 @@ System.register(["axios"], function(exports, module) {
|
|
|
1914
1917
|
setIOTAliasName: (body) => {
|
|
1915
1918
|
return API$b.put("/set-alias-name", body);
|
|
1916
1919
|
},
|
|
1920
|
+
pingIOTSingle: (id) => {
|
|
1921
|
+
return API$b.put(`/${id}/ping`);
|
|
1922
|
+
},
|
|
1923
|
+
//https://dev-api.tagsamurai.com/fam/iot/v2/iot/reader/:id/set-antenna-power
|
|
1924
|
+
setIOTAntennaPowerBulk: (id, body) => {
|
|
1925
|
+
return API$b.put(`/${id}/set-antenna-power`, body);
|
|
1926
|
+
},
|
|
1927
|
+
//https://dev-api.tagsamurai.com/fam/iot/v2/iot/reader/:id/ports
|
|
1928
|
+
getIOTPortList: (id, params) => {
|
|
1929
|
+
return API$b.get(`/${id}/ports`, { params });
|
|
1930
|
+
},
|
|
1931
|
+
getIOTDetail: (id) => {
|
|
1932
|
+
return API$b.get(`/${id}`);
|
|
1933
|
+
},
|
|
1934
|
+
//https://dev-api.tagsamurai.com/fam/iot/v2/iot/reader/check-manager
|
|
1935
|
+
getIOTCheckManager: () => {
|
|
1936
|
+
return API$b.get("/check-manager");
|
|
1937
|
+
},
|
|
1938
|
+
setIOTPortGroup: (id, body) => {
|
|
1939
|
+
return API$b.put(`/${id}/set-port-group`, body);
|
|
1940
|
+
},
|
|
1941
|
+
setGroupIOT: (body) => {
|
|
1942
|
+
return API$b.put("/set-group", body);
|
|
1943
|
+
},
|
|
1917
1944
|
getActivityLogData: (params) => {
|
|
1918
1945
|
return API$b.get("/activity-log", { params });
|
|
1919
1946
|
},
|
package/main.d.ts
CHANGED
|
@@ -28,6 +28,7 @@ export { default as AssetNameServices } from './src/services/oldAssetName.servic
|
|
|
28
28
|
export { default as AuditServices } from './src/services/oldAudit.service';
|
|
29
29
|
export { default as BrandServices } from './src/services/oldBrand.service';
|
|
30
30
|
export { default as ChangelogServices } from './src/services/oldLog.service';
|
|
31
|
+
export { default as NewChangelogServices } from './src/services/log.service';
|
|
31
32
|
export { default as CountryStateServices } from './src/services/countryState.service';
|
|
32
33
|
export { default as DashboardServices } from './src/services/oldDashboard.service';
|
|
33
34
|
export { default as GlobalAuthServices } from './src/services/globalAuth.service';
|
package/package.json
CHANGED
package/src/dto/reader.dto.d.ts
CHANGED
|
@@ -13,6 +13,11 @@ export interface GetIOTReaderListQueryParams extends BaseFilterQueryParams {
|
|
|
13
13
|
antennaGroup?: number[];
|
|
14
14
|
assetControl?: string;
|
|
15
15
|
}
|
|
16
|
+
export interface GetIOTPortListQueryParams extends BaseFilterQueryParams {
|
|
17
|
+
group?: number[];
|
|
18
|
+
networkStatus?: string[];
|
|
19
|
+
activeStatus?: string[];
|
|
20
|
+
}
|
|
16
21
|
export interface GetIOTReaderListOptionsQueryParams {
|
|
17
22
|
deviceNameOptions?: boolean;
|
|
18
23
|
groupOptions?: boolean;
|
|
@@ -25,3 +30,18 @@ export interface SetIOTAliasNameBody {
|
|
|
25
30
|
aliasName: string;
|
|
26
31
|
id: string[];
|
|
27
32
|
}
|
|
33
|
+
export interface SetIOTPortGroupBody {
|
|
34
|
+
group: string[];
|
|
35
|
+
}
|
|
36
|
+
export interface SetGroupIOTBody {
|
|
37
|
+
reader: string[];
|
|
38
|
+
group: string;
|
|
39
|
+
}
|
|
40
|
+
export type ActivityLogOptionParams = {
|
|
41
|
+
deviceNameOptions?: boolean;
|
|
42
|
+
groupOptions?: boolean;
|
|
43
|
+
nameOptions?: boolean;
|
|
44
|
+
activityOptions?: boolean;
|
|
45
|
+
managerOptions?: boolean;
|
|
46
|
+
portOptions?: boolean;
|
|
47
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AxiosResponse } from 'axios';
|
|
2
|
-
import { FetchListResponse, FetchOptionResponse } from '../types/fetchResponse.type';
|
|
3
|
-
import { ActionLogFilterParams,
|
|
4
|
-
import { ActionLogType } from '../types/log.type';
|
|
2
|
+
import { FetchDetailResponse, FetchListResponse, FetchOptionResponse } from '../types/fetchResponse.type';
|
|
3
|
+
import { ActionLogFilterParams, GetSessionLogListResponse, GetUserSystemLogListResponse, GetUserSystemLogOptionsResponse, SessionLogFetchParams, SessionOptionsQueryParams, SystemLogFetchParams, SystemLogLoadingFilters } from '../dto/log.dto';
|
|
4
|
+
import { ActionLogType, ChangelogListOptions } from '../types/log.type';
|
|
5
5
|
import { GetUserLogAssignmentOptionsResponse, GetUserLogBorrowingOptionsResponse, UserLogAssignmentFetchParams, UserLogAssignmentLoadingFilters, UserLogBorrowingFetchParams, UserLogBorrowingLoadingFilters } from '../dto/user.dto';
|
|
6
6
|
import { UserLogAssignment, UserLogBorrowing } from '../types/userLog.type';
|
|
7
7
|
import { TransactionLogFilterParams } from '../dto/transactionLog.dto';
|
|
@@ -10,7 +10,7 @@ import { TransactionDataType } from '../types/assetDetail.type';
|
|
|
10
10
|
import { FetchOptionFn } from '@fewangsit/wangsvue-fats/components/filtercontainer/FilterContainer.vue';
|
|
11
11
|
declare const ChangelogServices: {
|
|
12
12
|
getActionLog: (params?: ActionLogFilterParams) => Promise<AxiosResponse<FetchListResponse<ActionLogType>>>;
|
|
13
|
-
getActionLogOption: (
|
|
13
|
+
getActionLogOption: () => Promise<AxiosResponse<FetchDetailResponse<ChangelogListOptions>>>;
|
|
14
14
|
getSessionLogList: (params: SessionLogFetchParams) => Promise<AxiosResponse<GetSessionLogListResponse>>;
|
|
15
15
|
getSessionLogListOptions: <T = SessionOptionsQueryParams>(params: T) => FetchOptionFn<T>;
|
|
16
16
|
getTransactionLog: (params?: TransactionLogFilterParams) => Promise<AxiosResponse<FetchListResponse<TransactionDataType>>>;
|
|
@@ -1,13 +1,24 @@
|
|
|
1
1
|
import { AxiosResponse } from 'axios';
|
|
2
|
-
import {
|
|
2
|
+
import { ActivityLogOptions, ChangeLogOptionParams, ChangeLogParams, IOTCheckManager, IOTDetail, IOTPortList, IOTReaderList, IOTReaderListOptions, QueryParams } from '../types/reader.type';
|
|
3
3
|
import { FetchDetailResponse, FetchListResponse, FetchResponse } from '../types/fetchResponse.type';
|
|
4
|
-
import { GetIOTReaderListOptionsQueryParams, GetIOTReaderListQueryParams, SetIOTAliasNameBody } from '../dto/reader.dto';
|
|
4
|
+
import { ActivityLogOptionParams, GetIOTPortListQueryParams, GetIOTReaderListOptionsQueryParams, GetIOTReaderListQueryParams, SetGroupIOTBody, SetIOTAliasNameBody, SetIOTPortGroupBody } from '../dto/reader.dto';
|
|
5
5
|
declare const ReaderServices: {
|
|
6
6
|
getIOTReaderList: (params: GetIOTReaderListQueryParams) => Promise<AxiosResponse<FetchListResponse<IOTReaderList>>>;
|
|
7
7
|
getIOTReaderListOptions: (params: GetIOTReaderListOptionsQueryParams) => Promise<AxiosResponse<FetchDetailResponse<IOTReaderListOptions>>>;
|
|
8
8
|
setIOTAliasName: (body: SetIOTAliasNameBody) => Promise<AxiosResponse<FetchResponse>>;
|
|
9
|
+
pingIOTSingle: (id: string) => Promise<AxiosResponse<FetchDetailResponse<{
|
|
10
|
+
status: string;
|
|
11
|
+
}>>>;
|
|
12
|
+
setIOTAntennaPowerBulk: (id: string, body: {
|
|
13
|
+
power: number[];
|
|
14
|
+
}) => Promise<FetchResponse>;
|
|
15
|
+
getIOTPortList: (id: string, params?: GetIOTPortListQueryParams) => Promise<AxiosResponse<FetchListResponse<IOTPortList>>>;
|
|
16
|
+
getIOTDetail: (id: string) => Promise<AxiosResponse<FetchDetailResponse<IOTDetail>>>;
|
|
17
|
+
getIOTCheckManager: () => Promise<AxiosResponse<FetchDetailResponse<IOTCheckManager>>>;
|
|
18
|
+
setIOTPortGroup: (id: string, body: SetIOTPortGroupBody) => Promise<AxiosResponse<FetchResponse>>;
|
|
19
|
+
setGroupIOT: (body: SetGroupIOTBody) => Promise<AxiosResponse<FetchResponse>>;
|
|
9
20
|
getActivityLogData: (params: QueryParams) => Promise<AxiosResponse>;
|
|
10
|
-
getActivityLogOptions: (params: ActivityLogOptionParams) => Promise<AxiosResponse
|
|
21
|
+
getActivityLogOptions: (params: ActivityLogOptionParams) => Promise<AxiosResponse<FetchDetailResponse<ActivityLogOptions>>>;
|
|
11
22
|
getDataById: (id: string) => Promise<AxiosResponse>;
|
|
12
23
|
getChangeLog: (params: ChangeLogParams) => Promise<AxiosResponse>;
|
|
13
24
|
getChangeLogOptions: (params: ChangeLogOptionParams) => Promise<AxiosResponse>;
|
package/src/types/log.type.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Ref } from 'vue';
|
|
2
|
+
import { Option } from './options.type';
|
|
2
3
|
export type ActionLogType = {
|
|
3
4
|
_id: string;
|
|
4
5
|
action: string;
|
|
@@ -14,6 +15,14 @@ export type ActionLogType = {
|
|
|
14
15
|
createdAt: string;
|
|
15
16
|
updatedAt: string;
|
|
16
17
|
};
|
|
18
|
+
export interface ChangelogListOptions {
|
|
19
|
+
actionOptions: Option[];
|
|
20
|
+
fieldOptions: Option[];
|
|
21
|
+
modifiedByOptions: Option[];
|
|
22
|
+
assetNameOptions: Option[];
|
|
23
|
+
nameOptions: Option[];
|
|
24
|
+
objectNameOptions: Option[];
|
|
25
|
+
}
|
|
17
26
|
export type LogDialogType = {
|
|
18
27
|
type: string;
|
|
19
28
|
header: string;
|
|
@@ -32,8 +32,8 @@ interface ManagerEntity {
|
|
|
32
32
|
interface AssetControl {
|
|
33
33
|
active: boolean;
|
|
34
34
|
roleRestricted: boolean;
|
|
35
|
-
inFrom:
|
|
36
|
-
outTo:
|
|
35
|
+
inFrom: BaseEntity[] | null;
|
|
36
|
+
outTo: BaseEntity[] | null;
|
|
37
37
|
}
|
|
38
38
|
interface CRUDPermissions {
|
|
39
39
|
create: boolean;
|
|
@@ -71,23 +71,6 @@ export interface IOTReaderList {
|
|
|
71
71
|
antennaGroups: BaseEntity[];
|
|
72
72
|
connectedAntenna: string;
|
|
73
73
|
}
|
|
74
|
-
export type ActivityLogOptionParams = {
|
|
75
|
-
foundGroupOptions?: string;
|
|
76
|
-
groupOptions?: string;
|
|
77
|
-
deviceNameOptions?: string;
|
|
78
|
-
activityOptions?: string;
|
|
79
|
-
managerOptions?: string;
|
|
80
|
-
assetNameOptions?: string;
|
|
81
|
-
borrowerOptions?: string;
|
|
82
|
-
conditionOptions?: string;
|
|
83
|
-
auditTypeOptions?: string;
|
|
84
|
-
assignedToOptions?: string;
|
|
85
|
-
originGroupOptions?: string;
|
|
86
|
-
destinationGroupOptions?: string;
|
|
87
|
-
type?: string;
|
|
88
|
-
readerId?: string;
|
|
89
|
-
activity?: string;
|
|
90
|
-
};
|
|
91
74
|
export type ChangeLogParams = {
|
|
92
75
|
id: string;
|
|
93
76
|
manager?: string[];
|
|
@@ -111,4 +94,38 @@ export interface IOTReaderListOptions {
|
|
|
111
94
|
managerOptions: Option[];
|
|
112
95
|
antennaGroupOptions: Option[];
|
|
113
96
|
}
|
|
97
|
+
export interface IOTPortList {
|
|
98
|
+
networkStatus: string;
|
|
99
|
+
_id: number;
|
|
100
|
+
isActive: boolean;
|
|
101
|
+
port: string;
|
|
102
|
+
group: BaseEntity;
|
|
103
|
+
antennaPower: string;
|
|
104
|
+
hasEditAccess: boolean;
|
|
105
|
+
}
|
|
106
|
+
export interface IOTCheckManager {
|
|
107
|
+
hasTaggedManager: boolean;
|
|
108
|
+
oneOfUser: string;
|
|
109
|
+
}
|
|
110
|
+
export interface IOTDetail {
|
|
111
|
+
_id: string;
|
|
112
|
+
imageSmall: string | null;
|
|
113
|
+
imageMedium: string | null;
|
|
114
|
+
imageBig: string | null;
|
|
115
|
+
name: NameEntity;
|
|
116
|
+
totalPort: number;
|
|
117
|
+
group: BaseEntity;
|
|
118
|
+
brand: BaseEntity;
|
|
119
|
+
model: BaseEntity;
|
|
120
|
+
networkStatus: string;
|
|
121
|
+
assetControl: AssetControl;
|
|
122
|
+
}
|
|
123
|
+
export interface ActivityLogOptions {
|
|
124
|
+
deviceNameOptions: Option[];
|
|
125
|
+
groupOptions: Option[];
|
|
126
|
+
nameOptions: Option[];
|
|
127
|
+
activityOptions: Option[];
|
|
128
|
+
managerOptions: Option[];
|
|
129
|
+
portOptions: Option[];
|
|
130
|
+
}
|
|
114
131
|
export {};
|