@gandalan/weblibs 1.5.17 → 1.5.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/JSDOC.md +661 -0
- package/README.md +106 -17
- package/api/business/ablageApi.js +106 -0
- package/api/business/anpassungApi.js +74 -0
- package/api/business/artikelApi.js +242 -0
- package/api/business/authApi.js +63 -0
- package/api/business/avApi.js +458 -0
- package/api/business/belegApi.js +365 -0
- package/api/business/belegPositionenApi.js +52 -0
- package/api/business/benutzerApi.js +96 -0
- package/api/business/fakturaApi.js +88 -0
- package/api/business/farbeApi.js +129 -0
- package/api/business/fileApi.js +72 -0
- package/api/business/historieApi.js +144 -0
- package/api/business/index.js +63 -0
- package/api/business/kontaktApi.js +70 -0
- package/api/business/lagerApi.js +162 -0
- package/api/business/lieferungApi.js +127 -0
- package/api/business/mailApi.js +41 -0
- package/api/business/mandantApi.js +137 -0
- package/api/business/materialApi.js +37 -0
- package/api/business/printApi.js +49 -0
- package/api/business/produktionApi.js +141 -0
- package/api/business/rechnungApi.js +155 -0
- package/api/business/serienApi.js +375 -0
- package/api/business/settingsApi.js +168 -0
- package/api/business/systemApi.js +209 -0
- package/api/business/uiApi.js +256 -0
- package/api/business/utilityApi.js +288 -0
- package/api/business/vorgangApi.js +128 -0
- package/api/dtos/allgemein.js +107 -0
- package/api/dtos/artikel.js +46 -0
- package/api/dtos/av.js +171 -0
- package/api/dtos/belege.js +614 -0
- package/api/dtos/benutzer.js +101 -0
- package/api/dtos/druck.js +50 -0
- package/api/dtos/faktura.js +128 -0
- package/api/dtos/farben.js +93 -0
- package/api/dtos/index.js +501 -0
- package/api/dtos/kunden.js +217 -0
- package/api/dtos/lager.js +66 -0
- package/api/dtos/mail.js +30 -0
- package/api/dtos/mandanten.js +60 -0
- package/api/dtos/nachrichten.js +18 -0
- package/api/dtos/produktGruppen.js +18 -0
- package/api/dtos/produktion.js +564 -0
- package/api/dtos/settings.js +172 -0
- package/api/dtos/technik.js +163 -0
- package/api/dtos/ui.js +496 -0
- package/api/dtos/webjob.js +12 -0
- package/api/fluentApi.js +10 -8
- package/api/fluentAuthManager.js +22 -14
- package/api/fluentRestClient.js +7 -7
- package/api/idasFluentApi.js +458 -0
- package/index.js +53 -6
- package/package.json +1 -1
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @typedef {import('../fluentApi.js').FluentApi} FluentApi
|
|
3
|
+
* @typedef {import('../dtos/index.js').ChangeDTO} ChangeDTO
|
|
4
|
+
* @typedef {import('../dtos/index.js').TagInfoDTO} TagInfoDTO
|
|
5
|
+
* @typedef {import('../dtos/index.js').TagVorlageDTO} TagVorlageDTO
|
|
6
|
+
* @typedef {import('../dtos/index.js').FilterItemDTO} FilterItemDTO
|
|
7
|
+
* @typedef {import('../dtos/index.js').ChangeInfoDTO} ChangeInfoDTO
|
|
8
|
+
* @typedef {import('../dtos/index.js').UpdateInfoDTO} UpdateInfoDTO
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* System API - System administration and configuration
|
|
13
|
+
* @param {FluentApi} fluentApi
|
|
14
|
+
*/
|
|
15
|
+
export function createSystemApi(fluentApi) {
|
|
16
|
+
return {
|
|
17
|
+
// ChangeWebRoutinen
|
|
18
|
+
/**
|
|
19
|
+
* Get changes for type
|
|
20
|
+
* @param {string} typeName
|
|
21
|
+
* @param {Date} changedSince
|
|
22
|
+
* @returns {Promise<ChangeDTO[]>}
|
|
23
|
+
*/
|
|
24
|
+
getChanges: (typeName, changedSince) =>
|
|
25
|
+
fluentApi.get(`Change/?typeName=${typeName}&changedSince=${changedSince.toISOString()}`),
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Delete old changes
|
|
29
|
+
* @returns {Promise<void>}
|
|
30
|
+
*/
|
|
31
|
+
deleteOldChanges: () => fluentApi.delete("Change"),
|
|
32
|
+
|
|
33
|
+
// TagInfoWebRoutinen
|
|
34
|
+
tagInfo: {
|
|
35
|
+
/**
|
|
36
|
+
* Get all tag info
|
|
37
|
+
* @param {Date} [changedSince]
|
|
38
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
39
|
+
*/
|
|
40
|
+
getAll: (changedSince) => {
|
|
41
|
+
if (changedSince) {
|
|
42
|
+
return fluentApi.get(`GetAllTagInfo?changedSince=${changedSince.toISOString()}`);
|
|
43
|
+
}
|
|
44
|
+
return fluentApi.get("GetAllTagInfo");
|
|
45
|
+
},
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Get tag info suggestions
|
|
49
|
+
* @param {Date} [changedSince]
|
|
50
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
51
|
+
*/
|
|
52
|
+
getSuggestions: (changedSince) => {
|
|
53
|
+
if (changedSince) {
|
|
54
|
+
return fluentApi.get(`GetTagInfoSuggestions?changedSince=${changedSince.toISOString()}`);
|
|
55
|
+
}
|
|
56
|
+
return fluentApi.get("GetTagInfoSuggestions");
|
|
57
|
+
},
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Get tag info by object GUID
|
|
61
|
+
* @param {string} objectGuid
|
|
62
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
63
|
+
*/
|
|
64
|
+
get: (objectGuid) => fluentApi.get(`GetTagInfo?objectGuid=${objectGuid}`),
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Get tag info for GUID list
|
|
68
|
+
* @param {string[]} guidList
|
|
69
|
+
* @returns {Promise<Record<string, TagInfoDTO[]>>}
|
|
70
|
+
*/
|
|
71
|
+
getForGuidList: (guidList) =>
|
|
72
|
+
fluentApi.put("GetTagInfoForGuidList", guidList),
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* Get tag info for external production GUID list
|
|
76
|
+
* @param {string[]} guidList
|
|
77
|
+
* @returns {Promise<Record<string, TagInfoDTO[]>>}
|
|
78
|
+
*/
|
|
79
|
+
getForFremdfertigungGuidList: (guidList) =>
|
|
80
|
+
fluentApi.put("GetTagInfoForFremdfertigungGuidList", guidList),
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* Add or update tag info
|
|
84
|
+
* @param {TagInfoDTO} dto
|
|
85
|
+
* @returns {Promise<void>}
|
|
86
|
+
*/
|
|
87
|
+
addOrUpdate: (dto) => fluentApi.post("TagInfo", dto),
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* Delete tag info
|
|
91
|
+
* @param {TagInfoDTO} dto
|
|
92
|
+
* @returns {Promise<void>}
|
|
93
|
+
*/
|
|
94
|
+
delete: (dto) => fluentApi.delete("TagInfo", dto),
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Get tag templates
|
|
98
|
+
* @returns {Promise<TagVorlageDTO[]>}
|
|
99
|
+
*/
|
|
100
|
+
getVorlagen: () => fluentApi.get("TagVorlagen/GetTagVorlagen"),
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Add or update tag template
|
|
104
|
+
* @param {TagVorlageDTO} dto
|
|
105
|
+
* @returns {Promise<void>}
|
|
106
|
+
*/
|
|
107
|
+
addOrUpdateVorlage: (dto) =>
|
|
108
|
+
fluentApi.post("TagVorlagen/AddOrUpdateTagVorlagen", dto),
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* Delete tag template
|
|
112
|
+
* @param {string} tagVorlageGuid
|
|
113
|
+
* @returns {Promise<void>}
|
|
114
|
+
*/
|
|
115
|
+
deleteVorlage: (tagVorlageGuid) =>
|
|
116
|
+
fluentApi.delete(`TagVorlagen/DeleteTagVorlage?tagVorlageGuid=${tagVorlageGuid}`),
|
|
117
|
+
|
|
118
|
+
/**
|
|
119
|
+
* Get tag info for function
|
|
120
|
+
* @param {string} objectGuid
|
|
121
|
+
* @param {number} mandantID
|
|
122
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
123
|
+
*/
|
|
124
|
+
getForFunction: (objectGuid, mandantID) =>
|
|
125
|
+
fluentApi.get(`GetTagInfoForFunction?objectGuid=${objectGuid}&mandantID=${mandantID}`),
|
|
126
|
+
|
|
127
|
+
/**
|
|
128
|
+
* Get tag info list for function
|
|
129
|
+
* @param {string[]} guidList
|
|
130
|
+
* @param {number} mandantID
|
|
131
|
+
* @returns {Promise<Record<string, TagInfoDTO[]>>}
|
|
132
|
+
*/
|
|
133
|
+
getListForFunction: (guidList, mandantID) =>
|
|
134
|
+
fluentApi.put(`GetTagInfoListForFunction?mandantID=${mandantID}`, guidList),
|
|
135
|
+
|
|
136
|
+
/**
|
|
137
|
+
* Add tag info for function
|
|
138
|
+
* @param {TagInfoDTO} dto
|
|
139
|
+
* @param {number} mandantID
|
|
140
|
+
* @returns {Promise<void>}
|
|
141
|
+
*/
|
|
142
|
+
addForFunction: (dto, mandantID) =>
|
|
143
|
+
fluentApi.post(`AddTagInfoForFunction?mandantID=${mandantID}`, dto),
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* Delete tag info for function
|
|
147
|
+
* @param {TagInfoDTO} dto
|
|
148
|
+
* @param {number} mandantID
|
|
149
|
+
* @returns {Promise<void>}
|
|
150
|
+
*/
|
|
151
|
+
deleteForFunction: (dto, mandantID) =>
|
|
152
|
+
fluentApi.delete(`DeleteTagInfoForFunction?mandantID=${mandantID}`, dto),
|
|
153
|
+
|
|
154
|
+
/**
|
|
155
|
+
* Clean up tag infos
|
|
156
|
+
* @returns {Promise<void>}
|
|
157
|
+
*/
|
|
158
|
+
cleanUp: () => fluentApi.delete("CleanUpTagInfos"),
|
|
159
|
+
},
|
|
160
|
+
|
|
161
|
+
// FilterWebRoutinen
|
|
162
|
+
filter: {
|
|
163
|
+
/**
|
|
164
|
+
* Get all filters
|
|
165
|
+
* @returns {Promise<FilterItemDTO[]>}
|
|
166
|
+
*/
|
|
167
|
+
getAll: () => fluentApi.get("Filter"),
|
|
168
|
+
|
|
169
|
+
/**
|
|
170
|
+
* Get filter by ID
|
|
171
|
+
* @param {string} id
|
|
172
|
+
* @returns {Promise<FilterItemDTO>}
|
|
173
|
+
*/
|
|
174
|
+
get: (id) => fluentApi.get(`Filter?id=${id}`),
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* Get filters by context
|
|
178
|
+
* @param {string} context
|
|
179
|
+
* @returns {Promise<FilterItemDTO[]>}
|
|
180
|
+
*/
|
|
181
|
+
getByContext: (context) => fluentApi.get(`Filter?context=${context}`),
|
|
182
|
+
|
|
183
|
+
/**
|
|
184
|
+
* Save filter
|
|
185
|
+
* @param {FilterItemDTO} dto
|
|
186
|
+
* @returns {Promise<void>}
|
|
187
|
+
*/
|
|
188
|
+
save: (dto) => fluentApi.put("Filter", dto),
|
|
189
|
+
},
|
|
190
|
+
|
|
191
|
+
// ChangeInfoWebRoutinen
|
|
192
|
+
/**
|
|
193
|
+
* Get change info
|
|
194
|
+
* @returns {Promise<ChangeInfoDTO>}
|
|
195
|
+
*/
|
|
196
|
+
getChangeInfo: () => fluentApi.get("ChangeInfo"),
|
|
197
|
+
|
|
198
|
+
// UpdateInfoWebRoutinen
|
|
199
|
+
/**
|
|
200
|
+
* Get update info
|
|
201
|
+
* @returns {Promise<UpdateInfoDTO>}
|
|
202
|
+
*/
|
|
203
|
+
getUpdateInfo: () => fluentApi.get("UpdateInfo"),
|
|
204
|
+
};
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
/**
|
|
208
|
+
* @typedef {ReturnType<typeof createSystemApi>} SystemApi
|
|
209
|
+
*/
|
|
@@ -0,0 +1,256 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @typedef {import('../fluentApi.js').FluentApi} FluentApi
|
|
3
|
+
* @typedef {import('../dtos/index.js').UIDefinitionDTO} UIDefinitionDTO
|
|
4
|
+
* @typedef {import('../dtos/index.js').UIScriptDTO} UIScriptDTO
|
|
5
|
+
* @typedef {import('../dtos/index.js').UIEingabeFeldInfoDTO} UIEingabeFeldInfoDTO
|
|
6
|
+
* @typedef {import('../dtos/index.js').TagInfoDTO} TagInfoDTO
|
|
7
|
+
* @typedef {import('../dtos/index.js').TagVorlageDTO} TagVorlageDTO
|
|
8
|
+
* @typedef {import('../dtos/index.js').FilterItemDTO} FilterItemDTO
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* UI API - User interface definitions and scripts
|
|
13
|
+
* @param {FluentApi} fluentApi
|
|
14
|
+
*/
|
|
15
|
+
export function createUiApi(fluentApi) {
|
|
16
|
+
return {
|
|
17
|
+
// UIWebRoutinen
|
|
18
|
+
/**
|
|
19
|
+
* Get all UI definitions
|
|
20
|
+
* @returns {Promise<UIDefinitionDTO[]>}
|
|
21
|
+
*/
|
|
22
|
+
getAllUiDefinitions: () => fluentApi.get("UIDefinition?maxlevel=99"),
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Get UI definition by GUID
|
|
26
|
+
* @param {string} guid
|
|
27
|
+
* @returns {Promise<UIDefinitionDTO>}
|
|
28
|
+
*/
|
|
29
|
+
getUiDefinition: (guid) => fluentApi.get(`UIDefinition/Get?guid=${guid}&maxlevel=99`),
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Save UI definition
|
|
33
|
+
* @param {UIDefinitionDTO} uiDefinition
|
|
34
|
+
* @returns {Promise<UIDefinitionDTO>}
|
|
35
|
+
*/
|
|
36
|
+
saveUiDefinition: (uiDefinition) =>
|
|
37
|
+
fluentApi.put(`UIDefinition/${uiDefinition.uiDefinitionGuid}`, uiDefinition),
|
|
38
|
+
|
|
39
|
+
// UIScriptWebRoutinen
|
|
40
|
+
/**
|
|
41
|
+
* Get all UI scripts
|
|
42
|
+
* @returns {Promise<UIScriptDTO[]>}
|
|
43
|
+
*/
|
|
44
|
+
getAllUiScripts: () => fluentApi.get("UIScript/"),
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Get UI script by name
|
|
48
|
+
* @param {string} name
|
|
49
|
+
* @returns {Promise<UIScriptDTO>}
|
|
50
|
+
*/
|
|
51
|
+
getUiScript: (name) => fluentApi.get(`UIScript?name=${name}`),
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Get UI script for function by name
|
|
55
|
+
* @param {string} name
|
|
56
|
+
* @returns {Promise<UIScriptDTO>}
|
|
57
|
+
*/
|
|
58
|
+
getUiScriptForFunction: (name) => fluentApi.get(`UIScript/ForFunction?name=${name}`),
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* Save UI script
|
|
62
|
+
* @param {UIScriptDTO} dto
|
|
63
|
+
* @returns {Promise<void>}
|
|
64
|
+
*/
|
|
65
|
+
saveUiScript: (dto) => fluentApi.put("UIScript/", dto),
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Delete UI script
|
|
69
|
+
* @param {string} guid
|
|
70
|
+
* @returns {Promise<void>}
|
|
71
|
+
*/
|
|
72
|
+
deleteUiScript: (guid) => fluentApi.delete(`UIScript?guid=${guid}`),
|
|
73
|
+
|
|
74
|
+
// UIFeldInfoWebRoutinen
|
|
75
|
+
/**
|
|
76
|
+
* Get all UI field info
|
|
77
|
+
* @returns {Promise<UIEingabeFeldInfoDTO[]>}
|
|
78
|
+
*/
|
|
79
|
+
getAllUiFeldInfo: () => fluentApi.get("UIEingabeFeldInfo"),
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* Save UI field info
|
|
83
|
+
* @param {UIEingabeFeldInfoDTO} uiEingabeFeldInfo
|
|
84
|
+
* @returns {Promise<UIEingabeFeldInfoDTO>}
|
|
85
|
+
*/
|
|
86
|
+
saveUiEingabeFeldInfo: (uiEingabeFeldInfo) =>
|
|
87
|
+
fluentApi.put(`UIEingabeFeldInfo/${uiEingabeFeldInfo.uiEingabeFeldGuid}`, uiEingabeFeldInfo),
|
|
88
|
+
|
|
89
|
+
// TagInfoWebRoutinen
|
|
90
|
+
/**
|
|
91
|
+
* Get all tag info
|
|
92
|
+
* @param {Date} [changedSince]
|
|
93
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
94
|
+
*/
|
|
95
|
+
getAllTagInfo: (changedSince) => {
|
|
96
|
+
if (changedSince) {
|
|
97
|
+
return fluentApi.get(`GetAllTagInfo?changedSince=${changedSince.toISOString()}`);
|
|
98
|
+
}
|
|
99
|
+
return fluentApi.get("GetAllTagInfo");
|
|
100
|
+
},
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Get tag info suggestions
|
|
104
|
+
* @param {Date} [changedSince]
|
|
105
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
106
|
+
*/
|
|
107
|
+
getTagInfoSuggestions: (changedSince) => {
|
|
108
|
+
if (changedSince) {
|
|
109
|
+
return fluentApi.get(`GetTagInfoSuggestions?changedSince=${changedSince.toISOString()}`);
|
|
110
|
+
}
|
|
111
|
+
return fluentApi.get("GetTagInfoSuggestions");
|
|
112
|
+
},
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* Get tag info by object GUID
|
|
116
|
+
* @param {string} objectGuid
|
|
117
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
118
|
+
*/
|
|
119
|
+
getTagInfo: (objectGuid) => fluentApi.get(`GetTagInfo?objectGuid=${objectGuid}`),
|
|
120
|
+
|
|
121
|
+
/**
|
|
122
|
+
* Get tag info for GUID list
|
|
123
|
+
* @param {string[]} guidList
|
|
124
|
+
* @returns {Promise<Record<string, TagInfoDTO[]>>}
|
|
125
|
+
*/
|
|
126
|
+
getTagInfoForGuidList: (guidList) =>
|
|
127
|
+
fluentApi.put("GetTagInfoForGuidList", guidList),
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* Get tag info for external production GUID list
|
|
131
|
+
* @param {string[]} guidList
|
|
132
|
+
* @returns {Promise<Record<string, TagInfoDTO[]>>}
|
|
133
|
+
*/
|
|
134
|
+
getTagInfoForFremdfertigungGuidList: (guidList) =>
|
|
135
|
+
fluentApi.put("GetTagInfoForFremdfertigungGuidList", guidList),
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* Add or update tag info
|
|
139
|
+
* @param {TagInfoDTO} dto
|
|
140
|
+
* @returns {Promise<void>}
|
|
141
|
+
*/
|
|
142
|
+
addOrUpdateTagInfo: (dto) => fluentApi.post("TagInfo", dto),
|
|
143
|
+
|
|
144
|
+
/**
|
|
145
|
+
* Delete tag info
|
|
146
|
+
* @param {TagInfoDTO} dto
|
|
147
|
+
* @returns {Promise<void>}
|
|
148
|
+
*/
|
|
149
|
+
deleteTagInfo: (dto) => fluentApi.delete("TagInfo", dto),
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* Get tag templates
|
|
153
|
+
* @returns {Promise<TagVorlageDTO[]>}
|
|
154
|
+
*/
|
|
155
|
+
getTagVorlagen: () => fluentApi.get("TagVorlagen/GetTagVorlagen"),
|
|
156
|
+
|
|
157
|
+
/**
|
|
158
|
+
* Add or update tag template
|
|
159
|
+
* @param {TagVorlageDTO} dto
|
|
160
|
+
* @returns {Promise<void>}
|
|
161
|
+
*/
|
|
162
|
+
addOrUpdateTagVorlage: (dto) =>
|
|
163
|
+
fluentApi.post("TagVorlagen/AddOrUpdateTagVorlagen", dto),
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* Delete tag template
|
|
167
|
+
* @param {string} tagVorlageGuid
|
|
168
|
+
* @returns {Promise<void>}
|
|
169
|
+
*/
|
|
170
|
+
deleteTagVorlage: (tagVorlageGuid) =>
|
|
171
|
+
fluentApi.delete(`TagVorlagen/DeleteTagVorlage?tagVorlageGuid=${tagVorlageGuid}`),
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* Get tag info for function
|
|
175
|
+
* @param {string} objectGuid
|
|
176
|
+
* @param {number} mandantID
|
|
177
|
+
* @returns {Promise<TagInfoDTO[]>}
|
|
178
|
+
*/
|
|
179
|
+
getTagInfoForFunction: (objectGuid, mandantID) =>
|
|
180
|
+
fluentApi.get(`GetTagInfoForFunction?objectGuid=${objectGuid}&mandantID=${mandantID}`),
|
|
181
|
+
|
|
182
|
+
/**
|
|
183
|
+
* Get tag info list for function
|
|
184
|
+
* @param {string[]} guidList
|
|
185
|
+
* @param {number} mandantID
|
|
186
|
+
* @returns {Promise<Record<string, TagInfoDTO[]>>}
|
|
187
|
+
*/
|
|
188
|
+
getTagInfoListForFunction: (guidList, mandantID) =>
|
|
189
|
+
fluentApi.put(`GetTagInfoListForFunction?mandantID=${mandantID}`, guidList),
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* Add tag info for function
|
|
193
|
+
* @param {TagInfoDTO} dto
|
|
194
|
+
* @param {number} mandantID
|
|
195
|
+
* @returns {Promise<void>}
|
|
196
|
+
*/
|
|
197
|
+
addTagInfoForFunction: (dto, mandantID) =>
|
|
198
|
+
fluentApi.post(`AddTagInfoForFunction?mandantID=${mandantID}`, dto),
|
|
199
|
+
|
|
200
|
+
/**
|
|
201
|
+
* Delete tag info for function
|
|
202
|
+
* @param {TagInfoDTO} dto
|
|
203
|
+
* @param {number} mandantID
|
|
204
|
+
* @returns {Promise<void>}
|
|
205
|
+
*/
|
|
206
|
+
deleteTagInfoForFunction: (dto, mandantID) =>
|
|
207
|
+
fluentApi.delete(`DeleteTagInfoForFunction?mandantID=${mandantID}`, dto),
|
|
208
|
+
|
|
209
|
+
/**
|
|
210
|
+
* Clean up tag infos
|
|
211
|
+
* @returns {Promise<void>}
|
|
212
|
+
*/
|
|
213
|
+
cleanUpTagInfos: () => fluentApi.delete("CleanUpTagInfos"),
|
|
214
|
+
|
|
215
|
+
// FilterWebRoutinen
|
|
216
|
+
/**
|
|
217
|
+
* Get all filters
|
|
218
|
+
* @returns {Promise<FilterItemDTO[]>}
|
|
219
|
+
*/
|
|
220
|
+
getAllFilters: () => fluentApi.get("Filter"),
|
|
221
|
+
|
|
222
|
+
/**
|
|
223
|
+
* Get filter by ID
|
|
224
|
+
* @param {string} id
|
|
225
|
+
* @returns {Promise<FilterItemDTO>}
|
|
226
|
+
*/
|
|
227
|
+
getFilter: (id) => fluentApi.get(`Filter?id=${id}`),
|
|
228
|
+
|
|
229
|
+
/**
|
|
230
|
+
* Get filters by context
|
|
231
|
+
* @param {string} context
|
|
232
|
+
* @returns {Promise<FilterItemDTO[]>}
|
|
233
|
+
*/
|
|
234
|
+
getFiltersByContext: (context) => fluentApi.get(`Filter?context=${context}`),
|
|
235
|
+
|
|
236
|
+
/**
|
|
237
|
+
* Save filter
|
|
238
|
+
* @param {FilterItemDTO} dto
|
|
239
|
+
* @returns {Promise<void>}
|
|
240
|
+
*/
|
|
241
|
+
saveFilter: (dto) => fluentApi.put("Filter", dto),
|
|
242
|
+
|
|
243
|
+
// TranslateWebRoutinen
|
|
244
|
+
/**
|
|
245
|
+
* Translate text
|
|
246
|
+
* @param {string} language
|
|
247
|
+
* @param {string} text
|
|
248
|
+
* @returns {Promise<string | null>}
|
|
249
|
+
*/
|
|
250
|
+
translate: (language, text) => fluentApi.post(`translate?lang=${language}`, text),
|
|
251
|
+
};
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* @typedef {ReturnType<typeof createUiApi>} UiApi
|
|
256
|
+
*/
|