@tagsamurai/gsts-api-services 1.0.1-alpha.13 → 1.0.1-alpha.14
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
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import v from "axios";
|
|
2
|
-
const
|
|
2
|
+
const T = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1, VITE_APP_GLOBAL_SETTINGS_API: "https://dev-api.global-settings.tagsamurai.com", VITE_APP_LOGS_NOTIFICATION_API: "https://dev-api-logs-notification.tagsamurai.com", VITE_APP_TAGSAMURAI_API: "https://dev-api.tagsamurai.com" }, l = (t = "APP_TAGSAMURAI_API") => T["VITE_" + t], o = (t = {}, e = !1) => {
|
|
3
3
|
const {
|
|
4
4
|
env: r = "APP_GLOBAL_SETTINGS_API",
|
|
5
5
|
prefix: u = "",
|
|
6
6
|
headers: c = {},
|
|
7
7
|
...I
|
|
8
|
-
} = t,
|
|
8
|
+
} = t, $ = `${l(r)}${u}`, A = JSON.parse(localStorage.getItem("user") ?? "{}"), S = A.jwt ?? A.token ?? "";
|
|
9
9
|
return v.create({
|
|
10
10
|
...I,
|
|
11
|
-
baseURL:
|
|
11
|
+
baseURL: $,
|
|
12
12
|
headers: e ? c : {
|
|
13
13
|
"Content-Type": "application/json",
|
|
14
|
-
Authorization: `Bearer ${
|
|
14
|
+
Authorization: `Bearer ${S}`,
|
|
15
15
|
...c
|
|
16
16
|
}
|
|
17
17
|
});
|
|
@@ -32,29 +32,33 @@ const _ = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1, VITE_
|
|
|
32
32
|
}), e;
|
|
33
33
|
}, d = o({
|
|
34
34
|
prefix: "/v1/global-settings/change-log"
|
|
35
|
-
}),
|
|
35
|
+
}), G = {
|
|
36
36
|
getChangelogs: (t) => d.get("", { params: t }),
|
|
37
37
|
getChangelogOptions: (t) => d.get("/options", { params: t })
|
|
38
|
-
},
|
|
38
|
+
}, a = o({
|
|
39
39
|
prefix: "/v1/global-settings/division"
|
|
40
|
-
}),
|
|
41
|
-
getDivisions: (t) =>
|
|
42
|
-
getDivisionDetail: (t) =>
|
|
43
|
-
postCreateDivision: (t) =>
|
|
44
|
-
putEditDivision: (t, e) =>
|
|
40
|
+
}), E = {
|
|
41
|
+
getDivisions: (t) => a.get("", { params: t }),
|
|
42
|
+
getDivisionDetail: (t) => a.get(`/${t}`),
|
|
43
|
+
postCreateDivision: (t) => a.post("/", t),
|
|
44
|
+
putEditDivision: (t, e) => a.put(`/${t}`, e),
|
|
45
45
|
deleteDivisions: (t) => {
|
|
46
46
|
const e = { id: JSON.stringify(t) };
|
|
47
|
-
return
|
|
47
|
+
return a.delete("", { params: e });
|
|
48
48
|
}
|
|
49
|
-
},
|
|
49
|
+
}, i = o({
|
|
50
50
|
env: "APP_TAGSAMURAI_API",
|
|
51
51
|
prefix: "/v1/global-settings"
|
|
52
|
-
}),
|
|
53
|
-
getTAGAllPaired: (t, e) =>
|
|
54
|
-
getTAGAllPairedOptions: (t, e) =>
|
|
55
|
-
getTAGNotPaired: (t, e) =>
|
|
56
|
-
getTAGNotPairedOptions: (t, e) =>
|
|
57
|
-
|
|
52
|
+
}), y = {
|
|
53
|
+
getTAGAllPaired: (t, e) => i.get(`/${t}`, { params: e }),
|
|
54
|
+
getTAGAllPairedOptions: (t, e) => i.get(`/${t}/options`, { params: e }),
|
|
55
|
+
getTAGNotPaired: (t, e) => i.get(`/${t}/not-paired`, { params: e }),
|
|
56
|
+
getTAGNotPairedOptions: (t, e) => i.get(`/${t}/not-paired/options`, { params: e }),
|
|
57
|
+
getScanTAG: (t, e) => i.get(`/${t}/scan`, { params: e }),
|
|
58
|
+
putDetailAuditTAG: (t, e) => i.put(`/${t}/audit-detail`, e),
|
|
59
|
+
putAuditTAG: (t, e) => i.put(`/${t}/audit`, e),
|
|
60
|
+
putAllocateTAG: (t, e) => i.put(`/${t}/allocate`, e)
|
|
61
|
+
}, n = ({ headers: t = {}, params: e = {} } = {}) => {
|
|
58
62
|
const r = l("APP_GLOBAL_SETTINGS_API"), u = JSON.parse(localStorage.getItem("user") ?? "{}");
|
|
59
63
|
return v.create({
|
|
60
64
|
baseURL: `${r}/v1/global-settings`,
|
|
@@ -66,52 +70,52 @@ const _ = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1, VITE_
|
|
|
66
70
|
params: e
|
|
67
71
|
});
|
|
68
72
|
}, L = {
|
|
69
|
-
getHandheldReader: (t) =>
|
|
70
|
-
getHandheldReaderDetail: (t) =>
|
|
71
|
-
getHandheldReaderOptions: (t) =>
|
|
72
|
-
putMarkHandheldStatus: (t) =>
|
|
73
|
-
putPingReaders: (t) =>
|
|
74
|
-
putMarkIOTStatus: (t, e) =>
|
|
75
|
-
putEditReaderGroup: (t, e, r) =>
|
|
73
|
+
getHandheldReader: (t) => n({ params: t }).get("/reader"),
|
|
74
|
+
getHandheldReaderDetail: (t) => n().get(`/reader/${t}`),
|
|
75
|
+
getHandheldReaderOptions: (t) => n({ params: t }).get("/reader/options"),
|
|
76
|
+
putMarkHandheldStatus: (t) => n().put("/reader/mark-status", t),
|
|
77
|
+
putPingReaders: (t) => n().put("/iot-reader/ping", t),
|
|
78
|
+
putMarkIOTStatus: (t, e) => n().put(`/${e}/mark-status`, t),
|
|
79
|
+
putEditReaderGroup: (t, e, r) => n().put(
|
|
76
80
|
`/${t === "iot" ? "iot-" : ""}reader/${r}/set-group`,
|
|
77
81
|
e
|
|
78
82
|
),
|
|
79
|
-
putEditAntennaGroup: (t, e) =>
|
|
80
|
-
putEditPortStatus: (t, e) =>
|
|
81
|
-
putEditAliasName: (t, e, r) =>
|
|
83
|
+
putEditAntennaGroup: (t, e) => n().put(`/iot-reader/${e}/set-port-group`, t),
|
|
84
|
+
putEditPortStatus: (t, e) => n().put(`/iot-reader/${e}/set-port-status`, t),
|
|
85
|
+
putEditAliasName: (t, e, r) => n().put(
|
|
82
86
|
`/${t === "iot" ? "iot-" : ""}reader/${r}/set-alias-name`,
|
|
83
87
|
e
|
|
84
88
|
),
|
|
85
|
-
putAntennaPower: (t, e) =>
|
|
86
|
-
getIOTReaderOrAntenna: (t, e) =>
|
|
87
|
-
getIOTReaderDetail: (t) =>
|
|
88
|
-
getIOTReaderOrAntennaOptions: (t, e) =>
|
|
89
|
-
getActivityLog: (t) =>
|
|
90
|
-
getActivityLogOptions: (t) =>
|
|
91
|
-
getDetailActivityLog: (t) =>
|
|
92
|
-
getDetailActivityLogOptions: (t) =>
|
|
93
|
-
getExistingAliasNames: () =>
|
|
94
|
-
getIotReaderPort: (t, e) =>
|
|
95
|
-
},
|
|
89
|
+
putAntennaPower: (t, e) => n().put(`/iot-reader/${e}/set-antenna-power`, t),
|
|
90
|
+
getIOTReaderOrAntenna: (t, e) => n({ params: e }).get(`/${t}`),
|
|
91
|
+
getIOTReaderDetail: (t) => n().get(`/iot-reader/${t}`),
|
|
92
|
+
getIOTReaderOrAntennaOptions: (t, e) => n({ params: e }).get(`/${t}/options`),
|
|
93
|
+
getActivityLog: (t) => n({ params: t }).get("/activity-log"),
|
|
94
|
+
getActivityLogOptions: (t) => n({ params: t }).get("/activity-log/options"),
|
|
95
|
+
getDetailActivityLog: (t) => n({ params: t }).get("/activity-log"),
|
|
96
|
+
getDetailActivityLogOptions: (t) => n({ params: t }).get("/activity-log/options"),
|
|
97
|
+
getExistingAliasNames: () => n().get("/reader/alias-names"),
|
|
98
|
+
getIotReaderPort: (t, e) => n({ params: e }).get(`/iot-reader/${t}/ports`)
|
|
99
|
+
}, _ = o({
|
|
96
100
|
env: "APP_LOGS_NOTIFICATION_API",
|
|
97
101
|
prefix: "/v2"
|
|
98
102
|
}), R = {
|
|
99
|
-
getSessionLogList: (t) =>
|
|
103
|
+
getSessionLogList: (t) => _.get("/session-log", { params: t })
|
|
100
104
|
}, P = o({
|
|
101
105
|
prefix: "/v1/global-settings/option"
|
|
102
106
|
}), U = {
|
|
103
107
|
getPositions: () => P.get("/position"),
|
|
104
108
|
getDivisions: () => P.get("/division")
|
|
105
|
-
},
|
|
109
|
+
}, g = o({
|
|
106
110
|
prefix: "/v1/global-settings/position"
|
|
107
111
|
}), D = {
|
|
108
|
-
getPositions: (t) =>
|
|
109
|
-
getPositionDetail: (t) =>
|
|
110
|
-
postCreatePosition: (t) =>
|
|
111
|
-
putEditPosition: (t, e) =>
|
|
112
|
+
getPositions: (t) => g.get("", { params: t }),
|
|
113
|
+
getPositionDetail: (t) => g.get(`/${t}`),
|
|
114
|
+
postCreatePosition: (t) => g.post("/", t),
|
|
115
|
+
putEditPosition: (t, e) => g.put(`/${t}`, e),
|
|
112
116
|
deletePositions: (t) => {
|
|
113
117
|
const e = { id: JSON.stringify(t) };
|
|
114
|
-
return
|
|
118
|
+
return g.delete("", { params: e });
|
|
115
119
|
}
|
|
116
120
|
}, O = o({
|
|
117
121
|
env: "APP_TAGSAMURAI_API",
|
|
@@ -124,41 +128,41 @@ const _ = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1, VITE_
|
|
|
124
128
|
getTAGEventlog: (t) => p.get("/tag-event-log", { params: t }),
|
|
125
129
|
getTAGEventlogOptions: (t) => p.get("/tag-event-log/options", { params: t }),
|
|
126
130
|
getDetailTAGEventlog: (t) => p.get(`/tag-event-log/${t}`)
|
|
127
|
-
},
|
|
131
|
+
}, s = o({
|
|
128
132
|
prefix: "/v1/global-settings/user"
|
|
129
133
|
}), C = {
|
|
130
|
-
getUsers: (t) =>
|
|
131
|
-
getUserDetail: (t) =>
|
|
132
|
-
getUserSystemLogs: (t, e) =>
|
|
134
|
+
getUsers: (t) => s.get("", { params: t }),
|
|
135
|
+
getUserDetail: (t) => s.get(`/${t}`),
|
|
136
|
+
getUserSystemLogs: (t, e) => s.get(`/${t}/system-logs`, { params: e }),
|
|
133
137
|
getUserSystemLogOptions: (t, e) => {
|
|
134
138
|
const r = {};
|
|
135
|
-
return r[e] = !0,
|
|
139
|
+
return r[e] = !0, s.get(`/${t}/system-logs/options`, { params: r });
|
|
136
140
|
},
|
|
137
141
|
postCreateUser: (t) => {
|
|
138
142
|
const e = { "Content-Type": "multipart/form-data" };
|
|
139
|
-
return
|
|
143
|
+
return s.post("", t, { headers: e });
|
|
140
144
|
},
|
|
141
145
|
putEditUser: (t, e) => {
|
|
142
146
|
const r = { "Content-Type": "multipart/form-data" };
|
|
143
|
-
return
|
|
147
|
+
return s.put(`/${t}`, e, { headers: r });
|
|
144
148
|
},
|
|
145
149
|
deleteUsers: (t) => {
|
|
146
150
|
const e = { id: JSON.stringify(t) };
|
|
147
|
-
return
|
|
151
|
+
return s.delete("", { params: e });
|
|
148
152
|
},
|
|
149
|
-
putToggleStatusUsers: (t) =>
|
|
153
|
+
putToggleStatusUsers: (t) => s.put("/active-status", t),
|
|
150
154
|
getUserOptions: (t) => {
|
|
151
155
|
const e = {};
|
|
152
|
-
return e[t] = !0,
|
|
156
|
+
return e[t] = !0, s.get("/options", { params: e });
|
|
153
157
|
},
|
|
154
|
-
deleteCancelEmailChange: (t) =>
|
|
155
|
-
postResendEmail: (t) =>
|
|
156
|
-
putChangePassword: (t, e) =>
|
|
158
|
+
deleteCancelEmailChange: (t) => s.delete(`/cancel-email-change/${t}`),
|
|
159
|
+
postResendEmail: (t) => s.post("/resend-email", t),
|
|
160
|
+
putChangePassword: (t, e) => s.put(`/change-password/${t}`, e)
|
|
157
161
|
};
|
|
158
162
|
export {
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
163
|
+
G as ChangelogServices,
|
|
164
|
+
E as DivisionServices,
|
|
165
|
+
y as GlobalTagServices,
|
|
162
166
|
L as HardwareServices,
|
|
163
167
|
R as LogServices,
|
|
164
168
|
U as OptionServices,
|
package/api-services.system.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
System.register(["axios"],function(s,m){"use strict";var l;return{setters:[c=>{l=c.default}],execute:function(){const c={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1,VITE_APP_GLOBAL_SETTINGS_API:"https://dev-api.global-settings.tagsamurai.com",VITE_APP_LOGS_NOTIFICATION_API:"https://dev-api-logs-notification.tagsamurai.com",VITE_APP_TAGSAMURAI_API:"https://dev-api.tagsamurai.com"},p=s("getBaseURL",(t="APP_TAGSAMURAI_API")=>c["VITE_"+t]),o=(t={},e=!1)=>{const{env:r="APP_GLOBAL_SETTINGS_API",prefix:d="",headers:S={},...f}=t,_=`${p(r)}${d}`,I=JSON.parse(localStorage.getItem("user")??"{}"),O=I.jwt??I.token??"";return l.create({...f,baseURL:_,headers:e?S:{"Content-Type":"application/json",Authorization:`Bearer ${O}`,...S}})},h=s("getImageURL",t=>{if(!t)return;const e=p("APP_TAGSAMURAI_API");return t.startsWith("http")?t:`${e}/file-manager/v2/files/${t}`}),y=s("queryParamsStringfy",t=>{if(!t||typeof t=="string")return;const e={};return Object.keys(t).forEach(r=>{Array.isArray(t[r])?t[r].length>0&&Object.assign(e,{[r]:JSON.stringify(t[r])}):t[r]!==void 0&&Object.assign(e,{[r]:t[r]})}),e}),v=o({prefix:"/v1/global-settings/change-log"}),
|
|
1
|
+
System.register(["axios"],function(s,m){"use strict";var l;return{setters:[c=>{l=c.default}],execute:function(){const c={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1,VITE_APP_GLOBAL_SETTINGS_API:"https://dev-api.global-settings.tagsamurai.com",VITE_APP_LOGS_NOTIFICATION_API:"https://dev-api-logs-notification.tagsamurai.com",VITE_APP_TAGSAMURAI_API:"https://dev-api.tagsamurai.com"},p=s("getBaseURL",(t="APP_TAGSAMURAI_API")=>c["VITE_"+t]),o=(t={},e=!1)=>{const{env:r="APP_GLOBAL_SETTINGS_API",prefix:d="",headers:S={},...f}=t,_=`${p(r)}${d}`,I=JSON.parse(localStorage.getItem("user")??"{}"),O=I.jwt??I.token??"";return l.create({...f,baseURL:_,headers:e?S:{"Content-Type":"application/json",Authorization:`Bearer ${O}`,...S}})},h=s("getImageURL",t=>{if(!t)return;const e=p("APP_TAGSAMURAI_API");return t.startsWith("http")?t:`${e}/file-manager/v2/files/${t}`}),y=s("queryParamsStringfy",t=>{if(!t||typeof t=="string")return;const e={};return Object.keys(t).forEach(r=>{Array.isArray(t[r])?t[r].length>0&&Object.assign(e,{[r]:JSON.stringify(t[r])}):t[r]!==void 0&&Object.assign(e,{[r]:t[r]})}),e}),v=o({prefix:"/v1/global-settings/change-log"}),G=s("ChangelogServices",{getChangelogs:t=>v.get("",{params:t}),getChangelogOptions:t=>v.get("/options",{params:t})}),g=o({prefix:"/v1/global-settings/division"}),E=s("DivisionServices",{getDivisions:t=>g.get("",{params:t}),getDivisionDetail:t=>g.get(`/${t}`),postCreateDivision:t=>g.post("/",t),putEditDivision:(t,e)=>g.put(`/${t}`,e),deleteDivisions:t=>{const e={id:JSON.stringify(t)};return g.delete("",{params:e})}}),a=o({env:"APP_TAGSAMURAI_API",prefix:"/v1/global-settings"}),L=s("GlobalTagServices",{getTAGAllPaired:(t,e)=>a.get(`/${t}`,{params:e}),getTAGAllPairedOptions:(t,e)=>a.get(`/${t}/options`,{params:e}),getTAGNotPaired:(t,e)=>a.get(`/${t}/not-paired`,{params:e}),getTAGNotPairedOptions:(t,e)=>a.get(`/${t}/not-paired/options`,{params:e}),getScanTAG:(t,e)=>a.get(`/${t}/scan`,{params:e}),putDetailAuditTAG:(t,e)=>a.put(`/${t}/audit-detail`,e),putAuditTAG:(t,e)=>a.put(`/${t}/audit`,e),putAllocateTAG:(t,e)=>a.put(`/${t}/allocate`,e)}),n=({headers:t={},params:e={}}={})=>{const r=p("APP_GLOBAL_SETTINGS_API"),d=JSON.parse(localStorage.getItem("user")??"{}");return l.create({baseURL:`${r}/v1/global-settings`,headers:{"Content-type":"application/json",Authorization:`Bearer ${d.token}`,...t},params:e})},R=s("HardwareServices",{getHandheldReader:t=>n({params:t}).get("/reader"),getHandheldReaderDetail:t=>n().get(`/reader/${t}`),getHandheldReaderOptions:t=>n({params:t}).get("/reader/options"),putMarkHandheldStatus:t=>n().put("/reader/mark-status",t),putPingReaders:t=>n().put("/iot-reader/ping",t),putMarkIOTStatus:(t,e)=>n().put(`/${e}/mark-status`,t),putEditReaderGroup:(t,e,r)=>n().put(`/${t==="iot"?"iot-":""}reader/${r}/set-group`,e),putEditAntennaGroup:(t,e)=>n().put(`/iot-reader/${e}/set-port-group`,t),putEditPortStatus:(t,e)=>n().put(`/iot-reader/${e}/set-port-status`,t),putEditAliasName:(t,e,r)=>n().put(`/${t==="iot"?"iot-":""}reader/${r}/set-alias-name`,e),putAntennaPower:(t,e)=>n().put(`/iot-reader/${e}/set-antenna-power`,t),getIOTReaderOrAntenna:(t,e)=>n({params:e}).get(`/${t}`),getIOTReaderDetail:t=>n().get(`/iot-reader/${t}`),getIOTReaderOrAntennaOptions:(t,e)=>n({params:e}).get(`/${t}/options`),getActivityLog:t=>n({params:t}).get("/activity-log"),getActivityLogOptions:t=>n({params:t}).get("/activity-log/options"),getDetailActivityLog:t=>n({params:t}).get("/activity-log"),getDetailActivityLogOptions:t=>n({params:t}).get("/activity-log/options"),getExistingAliasNames:()=>n().get("/reader/alias-names"),getIotReaderPort:(t,e)=>n({params:e}).get(`/iot-reader/${t}/ports`)}),$=o({env:"APP_LOGS_NOTIFICATION_API",prefix:"/v2"}),U=s("LogServices",{getSessionLogList:t=>$.get("/session-log",{params:t})}),P=o({prefix:"/v1/global-settings/option"}),D=s("OptionServices",{getPositions:()=>P.get("/position"),getDivisions:()=>P.get("/division")}),u=o({prefix:"/v1/global-settings/position"}),b=s("PositionServices",{getPositions:t=>u.get("",{params:t}),getPositionDetail:t=>u.get(`/${t}`),postCreatePosition:t=>u.post("/",t),putEditPosition:(t,e)=>u.put(`/${t}`,e),deletePositions:t=>{const e={id:JSON.stringify(t)};return u.delete("",{params:e})}}),T=o({env:"APP_TAGSAMURAI_API",prefix:"/tag/v2"}),C=s("TagServices",{getTagInfo:t=>T.get("/rfid-qr/scan",{params:t})}),A=o({prefix:"/v1/global-settings/change-log"}),N=s("TagEventlogServices",{getTAGEventlog:t=>A.get("/tag-event-log",{params:t}),getTAGEventlogOptions:t=>A.get("/tag-event-log/options",{params:t}),getDetailTAGEventlog:t=>A.get(`/tag-event-log/${t}`)}),i=o({prefix:"/v1/global-settings/user"}),B=s("UserServices",{getUsers:t=>i.get("",{params:t}),getUserDetail:t=>i.get(`/${t}`),getUserSystemLogs:(t,e)=>i.get(`/${t}/system-logs`,{params:e}),getUserSystemLogOptions:(t,e)=>{const r={};return r[e]=!0,i.get(`/${t}/system-logs/options`,{params:r})},postCreateUser:t=>{const e={"Content-Type":"multipart/form-data"};return i.post("",t,{headers:e})},putEditUser:(t,e)=>{const r={"Content-Type":"multipart/form-data"};return i.put(`/${t}`,e,{headers:r})},deleteUsers:t=>{const e={id:JSON.stringify(t)};return i.delete("",{params:e})},putToggleStatusUsers:t=>i.put("/active-status",t),getUserOptions:t=>{const e={};return e[t]=!0,i.get("/options",{params:e})},deleteCancelEmailChange:t=>i.delete(`/cancel-email-change/${t}`),postResendEmail:t=>i.post("/resend-email",t),putChangePassword:(t,e)=>i.put(`/change-password/${t}`,e)})}}});
|
package/package.json
CHANGED
package/src/dto/tag.dto.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { MultiSelectOption } from '../types/options.type';
|
|
2
|
-
import { TAGCountType, TAGDataType } from '../types/tag.type';
|
|
2
|
+
import { ApplicationModule, TAGCountType, TAGDataType } from '../types/tag.type';
|
|
3
|
+
import { TAGDetailCount } from '../types/tagEventlog.type';
|
|
3
4
|
export interface TAGFetchResponse<T = TAGDataType> {
|
|
4
5
|
message: string;
|
|
5
6
|
status: number;
|
|
@@ -9,6 +10,13 @@ export interface TAGFetchResponse<T = TAGDataType> {
|
|
|
9
10
|
} & TAGCountType;
|
|
10
11
|
}
|
|
11
12
|
export type TAGFetchOptionResponse<Opt = Record<string, boolean>> = Record<keyof Opt, MultiSelectOption[]>;
|
|
13
|
+
export type TAGDetailAuditResponse = {
|
|
14
|
+
status: number;
|
|
15
|
+
message: string;
|
|
16
|
+
data: {
|
|
17
|
+
detail: TAGDetailCount[];
|
|
18
|
+
};
|
|
19
|
+
};
|
|
12
20
|
export interface TAGFilterRaw {
|
|
13
21
|
rfidCode?: ('Yes' | 'No')[];
|
|
14
22
|
qrCode?: ('Yes' | 'No')[];
|
|
@@ -22,3 +30,14 @@ export interface TAGFilterRaw {
|
|
|
22
30
|
tag?: string[];
|
|
23
31
|
}
|
|
24
32
|
export type TAGFilterQuery = Partial<Record<keyof TAGFilterRaw, string>>;
|
|
33
|
+
export interface PUTAuditTAGBody {
|
|
34
|
+
ids: string[];
|
|
35
|
+
markNotFoundAsDamagedMissing: boolean;
|
|
36
|
+
moveFoundFixedAssetToPortal: boolean;
|
|
37
|
+
moveFoundSupplyAssetToPortal: boolean;
|
|
38
|
+
}
|
|
39
|
+
export interface PUTAllocateTAGBody {
|
|
40
|
+
ids: string[];
|
|
41
|
+
group: number;
|
|
42
|
+
module: ApplicationModule;
|
|
43
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FetchListResponse, FetchOptionResponse } from '../types/fetchResponse.type';
|
|
2
2
|
import { MultiSelectOption } from '../types/options.type';
|
|
3
3
|
import { ApplicationModule, TAGType } from '../types/tag.type';
|
|
4
|
-
import {
|
|
4
|
+
import { TAGDetailCount, TAGEventlogData } from '../types/tagEventlog.type';
|
|
5
5
|
export interface TAGEventlogFilterQuery {
|
|
6
6
|
status?: string[];
|
|
7
7
|
modifiedBy?: number[];
|
|
@@ -17,6 +17,6 @@ export type TAGEventlogDetailResponse = {
|
|
|
17
17
|
data: {
|
|
18
18
|
type: 'Audit' | 'Allocation';
|
|
19
19
|
module?: ApplicationModule;
|
|
20
|
-
detail:
|
|
20
|
+
detail: TAGDetailCount[];
|
|
21
21
|
};
|
|
22
22
|
};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { AxiosResponse } from 'axios';
|
|
2
2
|
import { BooleanOptions } from '../dto/dataTable.dto';
|
|
3
3
|
import { HardwareFilterQuery } from '../dto/hardware.dto';
|
|
4
|
-
import { TAGFetchOptionResponse, TAGFetchResponse } from '../dto/tag.dto';
|
|
4
|
+
import { PUTAllocateTAGBody, PUTAuditTAGBody, TAGDetailAuditResponse, TAGFetchOptionResponse, TAGFetchResponse } from '../dto/tag.dto';
|
|
5
|
+
import { FetchResponse } from '../types/fetchResponse.type';
|
|
5
6
|
import { TAGType } from '../types/tag.type';
|
|
6
7
|
declare const GlobalTagServices: {
|
|
7
8
|
getTAGAllPaired: (tagType: TAGType, params?: HardwareFilterQuery) => Promise<AxiosResponse<TAGFetchResponse>>;
|
|
@@ -12,5 +13,13 @@ declare const GlobalTagServices: {
|
|
|
12
13
|
getTAGNotPairedOptions: (tagType: TAGType, params?: BooleanOptions) => Promise<AxiosResponse<{
|
|
13
14
|
data: TAGFetchOptionResponse;
|
|
14
15
|
}>>;
|
|
16
|
+
getScanTAG: (tagType: TAGType, params?: {
|
|
17
|
+
tag: string;
|
|
18
|
+
}) => Promise<AxiosResponse>;
|
|
19
|
+
putDetailAuditTAG: (tagType: TAGType, body: {
|
|
20
|
+
ids: string[];
|
|
21
|
+
}) => Promise<AxiosResponse<TAGDetailAuditResponse>>;
|
|
22
|
+
putAuditTAG: (tagType: TAGType, body: PUTAuditTAGBody) => Promise<AxiosResponse<FetchResponse>>;
|
|
23
|
+
putAllocateTAG: (tagType: TAGType, body: PUTAllocateTAGBody) => Promise<AxiosResponse<FetchResponse>>;
|
|
15
24
|
};
|
|
16
25
|
export default GlobalTagServices;
|
|
@@ -6,7 +6,7 @@ export interface TAGEventlogData {
|
|
|
6
6
|
modifiedBy?: string;
|
|
7
7
|
createdAt: string;
|
|
8
8
|
}
|
|
9
|
-
export interface
|
|
9
|
+
export interface TAGDetailCount {
|
|
10
10
|
type: 'availableFound' | 'damagedMissingFound' | 'availableMarkDamagedMissing' | 'fixedAssetMoveToPortal' | 'supplyAssetMoveToPortal' | 'allocated';
|
|
11
11
|
isChecked?: boolean;
|
|
12
12
|
groupName?: string;
|