@beam3_dev/api_module 0.0.132 → 0.0.134
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/dist/wb3Api.js +54 -52
- package/dist/wb3Api.js.map +1 -1
- package/dist/wb3Api.umd.cjs +5 -5
- package/dist/wb3Api.umd.cjs.map +1 -1
- package/package.json +1 -1
package/dist/wb3Api.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { v4 as L } from "uuid";
|
|
2
2
|
import { DateTime as N } from "luxon";
|
|
3
|
-
import { requirejs as O, widget as
|
|
4
|
-
function
|
|
3
|
+
import { requirejs as O, widget as I } from "@widget-lab/3ddashboard-utils";
|
|
4
|
+
function j() {
|
|
5
5
|
return L();
|
|
6
6
|
}
|
|
7
7
|
const J = {
|
|
@@ -121,7 +121,7 @@ function fe(e, t = void 0) {
|
|
|
121
121
|
O(["DS/TagNavigatorProxy/TagNavigatorProxy"], (n) => {
|
|
122
122
|
let s;
|
|
123
123
|
s === void 0 && (s = n.createProxy({
|
|
124
|
-
widgetId:
|
|
124
|
+
widgetId: I.id,
|
|
125
125
|
filteringMode: "WithFilteringServices"
|
|
126
126
|
}), t !== void 0 && s.addEvent("onFilterSubjectsChange", t)), s.setSubjectsTags(e);
|
|
127
127
|
});
|
|
@@ -137,7 +137,7 @@ async function ge(e, t = void 0, n = void 0) {
|
|
|
137
137
|
await O(
|
|
138
138
|
["DS/i3DXCompassServices/i3DXCompassServices"],
|
|
139
139
|
(s) => {
|
|
140
|
-
(!e || e === "") && (e =
|
|
140
|
+
(!e || e === "") && (e = I.getValue("PlatFormInstanceId")), (!e || e === "") && (e = void 0), t && t(
|
|
141
141
|
s.getPlatformServices({
|
|
142
142
|
platformId: e,
|
|
143
143
|
onComplete: t,
|
|
@@ -161,7 +161,7 @@ function E() {
|
|
|
161
161
|
};
|
|
162
162
|
}), console.log("%cRETOUR API :", "color:blue", e), e;
|
|
163
163
|
}
|
|
164
|
-
function
|
|
164
|
+
function A(e, t = void 0, n = void 0) {
|
|
165
165
|
if (e.tenant) {
|
|
166
166
|
const s = `https://${e.tenant}-eu1-apps.3dexperience.3ds.com/enovia/resources/AppsMngt/api/v1/services?tenant=${e.tenant}&cors=true&xrequestedwith=xmlhttprequest`;
|
|
167
167
|
f(s, {
|
|
@@ -424,7 +424,7 @@ async function K(e, t, n) {
|
|
|
424
424
|
});
|
|
425
425
|
}
|
|
426
426
|
}
|
|
427
|
-
async function
|
|
427
|
+
async function V(e, t = void 0, n = void 0, s = void 0) {
|
|
428
428
|
const i = e.space;
|
|
429
429
|
if (t === void 0) {
|
|
430
430
|
console.log("Le paramètre docid est obligatoire");
|
|
@@ -483,7 +483,7 @@ function T(e, t = void 0, n = void 0) {
|
|
|
483
483
|
} else
|
|
484
484
|
n && n("ERROR : url du 3DSpace non défini.");
|
|
485
485
|
}
|
|
486
|
-
function
|
|
486
|
+
function $(e, t = void 0, n = void 0) {
|
|
487
487
|
let s = e.space + `/resources/v1/modeler/documents/${e.objID}/files/DownloadTicket`;
|
|
488
488
|
v(
|
|
489
489
|
e,
|
|
@@ -529,7 +529,7 @@ function ke(e, t, n, s = void 0, i = void 0) {
|
|
|
529
529
|
}
|
|
530
530
|
});
|
|
531
531
|
}
|
|
532
|
-
function
|
|
532
|
+
function X(e, t, n, s, i, r = void 0, o = void 0) {
|
|
533
533
|
v(
|
|
534
534
|
e,
|
|
535
535
|
t,
|
|
@@ -598,7 +598,7 @@ function W(e, t, n, s, i, r, o = void 0, a = void 0) {
|
|
|
598
598
|
}
|
|
599
599
|
});
|
|
600
600
|
}
|
|
601
|
-
async function
|
|
601
|
+
async function Ae(e, t, n, s, i = void 0, r = void 0) {
|
|
602
602
|
const o = e.space, a = e.token, c = e.ctx, d = new FormData(), l = new Blob([JSON.stringify(t)], {
|
|
603
603
|
type: "text/plain"
|
|
604
604
|
}), p = {
|
|
@@ -645,7 +645,7 @@ async function Fe(e, t, n, s, i = void 0, r = void 0) {
|
|
|
645
645
|
}
|
|
646
646
|
}]
|
|
647
647
|
},
|
|
648
|
-
tempId:
|
|
648
|
+
tempId: j()
|
|
649
649
|
}]
|
|
650
650
|
}),
|
|
651
651
|
type: "json",
|
|
@@ -735,7 +735,7 @@ async function R(e, t = void 0, n = void 0) {
|
|
|
735
735
|
), console.warn(
|
|
736
736
|
"_3DSpace_download_doc() / Le paramètre token est obligatoire"
|
|
737
737
|
)), new Promise((s, i) => {
|
|
738
|
-
|
|
738
|
+
$(
|
|
739
739
|
e,
|
|
740
740
|
(r) => {
|
|
741
741
|
f(r, {
|
|
@@ -840,7 +840,7 @@ function Y(e, t, n = void 0, s = void 0, i = void 0) {
|
|
|
840
840
|
}
|
|
841
841
|
});
|
|
842
842
|
}
|
|
843
|
-
function
|
|
843
|
+
function Fe(e, t, n = void 0, s = void 0) {
|
|
844
844
|
return new Promise((i) => {
|
|
845
845
|
if (e.token === "" && T(e), t !== void 0 && t !== "" && t !== null) {
|
|
846
846
|
const r = `${e.space}/resources/v1/modeler/dslc/maturity/getNextStates`;
|
|
@@ -919,7 +919,7 @@ function $e(e, t, n, s = void 0, i = void 0) {
|
|
|
919
919
|
}
|
|
920
920
|
});
|
|
921
921
|
}
|
|
922
|
-
function
|
|
922
|
+
function De(e, t, n = void 0, s = void 0) {
|
|
923
923
|
return new Promise((i) => {
|
|
924
924
|
if (e.token === "" && T(e), t !== void 0 && t !== "" && t !== null) {
|
|
925
925
|
const r = `${e.space}/resources/v1/dslc/versiongraph?withThumbnail=0&withIsLastVersion=0&withAttributes=0&withCopyFrom=0&tenant=${e.tenant}`;
|
|
@@ -958,7 +958,7 @@ function Ue(e, t, n = void 0, s = void 0) {
|
|
|
958
958
|
}
|
|
959
959
|
});
|
|
960
960
|
}
|
|
961
|
-
function
|
|
961
|
+
function Ue(e, t, n = void 0, s = void 0) {
|
|
962
962
|
return new Promise((i) => {
|
|
963
963
|
if (e.token === "" && T(e), t !== void 0 && t !== "" && t !== null) {
|
|
964
964
|
const r = `${e.space}/resources/lifecycle/revise/prepare_revise_maskattributes?tenant=${e.tenant}`;
|
|
@@ -1091,8 +1091,8 @@ function Re(e, t = void 0, n = void 0) {
|
|
|
1091
1091
|
}
|
|
1092
1092
|
});
|
|
1093
1093
|
}
|
|
1094
|
-
function
|
|
1095
|
-
|
|
1094
|
+
function Pe(e, t, n, s) {
|
|
1095
|
+
$(
|
|
1096
1096
|
e.space,
|
|
1097
1097
|
t,
|
|
1098
1098
|
(i) => {
|
|
@@ -1108,9 +1108,9 @@ function xe(e, t, n, s) {
|
|
|
1108
1108
|
}
|
|
1109
1109
|
);
|
|
1110
1110
|
}
|
|
1111
|
-
async function
|
|
1111
|
+
async function xe(e, t, n = void 0, s = void 0) {
|
|
1112
1112
|
return new Promise((i) => {
|
|
1113
|
-
|
|
1113
|
+
$(e, t, (r) => {
|
|
1114
1114
|
f(r, {
|
|
1115
1115
|
onComplete: (o, a, c) => (i(JSON.parse(o)), n && n(JSON.parse(o), a, c), i),
|
|
1116
1116
|
onFailure: (o, a, c) => {
|
|
@@ -1127,7 +1127,7 @@ function Me(e, t, n, s = void 0, i = void 0) {
|
|
|
1127
1127
|
n,
|
|
1128
1128
|
(o) => {
|
|
1129
1129
|
const a = o.data[0].relateddata.files[0].id, c = o.data[0].dataelements.secondaryTitle !== "" ? o.data[0].dataelements.secondaryTitle : o.data[0].dataelements.title;
|
|
1130
|
-
|
|
1130
|
+
X(
|
|
1131
1131
|
e,
|
|
1132
1132
|
n,
|
|
1133
1133
|
a,
|
|
@@ -1143,8 +1143,8 @@ function Me(e, t, n, s = void 0, i = void 0) {
|
|
|
1143
1143
|
}
|
|
1144
1144
|
);
|
|
1145
1145
|
}
|
|
1146
|
-
let
|
|
1147
|
-
const
|
|
1146
|
+
let P, x;
|
|
1147
|
+
const D = [];
|
|
1148
1148
|
async function Le(e, t = void 0, n = void 0) {
|
|
1149
1149
|
e.objID && e.objID !== "" ? v(
|
|
1150
1150
|
e,
|
|
@@ -1187,7 +1187,7 @@ function Ee(e, t = void 0, n = void 0) {
|
|
|
1187
1187
|
e,
|
|
1188
1188
|
i.objID,
|
|
1189
1189
|
(o) => {
|
|
1190
|
-
s.push({ [i.name]: o }), i.name === "dbProjets" && (
|
|
1190
|
+
s.push({ [i.name]: o }), i.name === "dbProjets" && (P = o.affaires.map((a) => a.objectID), q(e, x)), r === e.objIds.length - 1 && (t && t(s), delete e.objIds, delete e.datas);
|
|
1191
1191
|
}
|
|
1192
1192
|
);
|
|
1193
1193
|
});
|
|
@@ -1195,10 +1195,10 @@ function Ee(e, t = void 0, n = void 0) {
|
|
|
1195
1195
|
function q(e, t, n = void 0, s = void 0) {
|
|
1196
1196
|
B(
|
|
1197
1197
|
e,
|
|
1198
|
-
|
|
1198
|
+
P,
|
|
1199
1199
|
(i) => {
|
|
1200
1200
|
const r = [...t];
|
|
1201
|
-
r.find((o) => o.objectID === i.objectId).data = i.data,
|
|
1201
|
+
r.find((o) => o.objectID === i.objectId).data = i.data, x = r, D.push(i.data), n && n(D);
|
|
1202
1202
|
},
|
|
1203
1203
|
(i) => {
|
|
1204
1204
|
s && (s(i), console.log(i));
|
|
@@ -1256,7 +1256,7 @@ function Ge(e, t, n = void 0, s = void 0) {
|
|
|
1256
1256
|
JSON.parse(u);
|
|
1257
1257
|
const m = {};
|
|
1258
1258
|
setTimeout(() => {
|
|
1259
|
-
|
|
1259
|
+
V(
|
|
1260
1260
|
e,
|
|
1261
1261
|
o,
|
|
1262
1262
|
(g) => {
|
|
@@ -1293,7 +1293,7 @@ function Z(e, t, n = void 0, s = void 0) {
|
|
|
1293
1293
|
}, o = `${r.baseUrl}${r.uri}`, a = {
|
|
1294
1294
|
"Content-Type": "application/json",
|
|
1295
1295
|
Accept: "application/json,text/javascript,*/*"
|
|
1296
|
-
}, c =
|
|
1296
|
+
}, c = j(), d = {
|
|
1297
1297
|
with_indexing_date: !0,
|
|
1298
1298
|
with_synthesis: !0,
|
|
1299
1299
|
with_nls: !1,
|
|
@@ -1404,7 +1404,7 @@ function Ke(e, t, n = void 0, s = void 0) {
|
|
|
1404
1404
|
}
|
|
1405
1405
|
});
|
|
1406
1406
|
}
|
|
1407
|
-
function
|
|
1407
|
+
function Ve(e, t = "", n = void 0, s = void 0) {
|
|
1408
1408
|
const { space: i } = e;
|
|
1409
1409
|
if (t === "")
|
|
1410
1410
|
return;
|
|
@@ -1440,7 +1440,7 @@ async function w(e, t = void 0, n = void 0) {
|
|
|
1440
1440
|
}
|
|
1441
1441
|
});
|
|
1442
1442
|
}
|
|
1443
|
-
function
|
|
1443
|
+
function Xe(e, t = void 0, n = void 0) {
|
|
1444
1444
|
const s = `${e.space}/api/exalead/whatsnew`, i = {
|
|
1445
1445
|
params: {
|
|
1446
1446
|
community_id: null,
|
|
@@ -1952,14 +1952,14 @@ function tt(e, t, n = void 0, s = void 0) {
|
|
|
1952
1952
|
);
|
|
1953
1953
|
}
|
|
1954
1954
|
function nt(e, t = void 0, n = void 0) {
|
|
1955
|
-
e.tenant &&
|
|
1955
|
+
e.tenant && A(e, (s) => {
|
|
1956
1956
|
console.log("serviceUrls", s);
|
|
1957
1957
|
const i = s.services.find((r) => r.id === "businessprocess")?.url + "/api/v2";
|
|
1958
1958
|
t && t(i);
|
|
1959
1959
|
});
|
|
1960
1960
|
}
|
|
1961
1961
|
function st(e, t = void 0, n = void 0) {
|
|
1962
|
-
e.tenant &&
|
|
1962
|
+
e.tenant && A(e, (s) => {
|
|
1963
1963
|
console.log("serviceUrls", s);
|
|
1964
1964
|
const i = s.services.find((a) => a.id === "3dpassport")?.url, r = s.services.find((a) => a.id === "businessprocess")?.url + "/api/v2", o = `${i}/login/?service=${r}/auth/cas`;
|
|
1965
1965
|
f(o, {
|
|
@@ -1979,15 +1979,17 @@ function st(e, t = void 0, n = void 0) {
|
|
|
1979
1979
|
});
|
|
1980
1980
|
}
|
|
1981
1981
|
async function at(e, t) {
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
}
|
|
1982
|
+
A(e, async (n) => {
|
|
1983
|
+
console.log("serviceUrls", n);
|
|
1984
|
+
const s = n.services.find((i) => i.id === "businessprocess")?.url + "/api/v2/identity/users";
|
|
1985
|
+
await fetch(s, {
|
|
1986
|
+
method: "GET",
|
|
1987
|
+
headers: {
|
|
1988
|
+
Authorization: `Bearer ${t}`
|
|
1989
|
+
}
|
|
1990
|
+
}).then((i) => i.json()).then((i) => {
|
|
1991
|
+
console.log(i), onDone && onDone(i?.token);
|
|
1992
|
+
}).catch((i) => console.log(i));
|
|
1991
1993
|
});
|
|
1992
1994
|
}
|
|
1993
1995
|
function it(e) {
|
|
@@ -2074,31 +2076,31 @@ function ot(e, t = void 0, n = void 0) {
|
|
|
2074
2076
|
});
|
|
2075
2077
|
}
|
|
2076
2078
|
export {
|
|
2077
|
-
|
|
2079
|
+
j as UUID,
|
|
2078
2080
|
ot as _3DSearch_usersGroup,
|
|
2079
|
-
|
|
2081
|
+
Ae as _3DSpace_Create_Doc,
|
|
2080
2082
|
je as _3DSpace_bookmark_addSubsciptions,
|
|
2081
2083
|
T as _3DSpace_csrf,
|
|
2082
2084
|
R as _3DSpace_download_doc,
|
|
2083
2085
|
B as _3DSpace_download_multidoc,
|
|
2084
|
-
|
|
2086
|
+
X as _3DSpace_file_update,
|
|
2085
2087
|
W as _3DSpace_file_update_csr,
|
|
2086
2088
|
ke as _3DSpace_file_url_csr,
|
|
2087
2089
|
v as _3DSpace_get_csrf,
|
|
2088
|
-
|
|
2090
|
+
V as _3DSpace_get_docInfo,
|
|
2089
2091
|
Y as _3DSpace_get_downloadTicket_multidoc,
|
|
2090
2092
|
b as _3DSpace_get_securityContexts,
|
|
2091
|
-
|
|
2093
|
+
$ as _3DSpace_get_ticket,
|
|
2092
2094
|
Ie as _3DSpace_lifecycle_changeRevision,
|
|
2093
2095
|
$e as _3DSpace_lifecycle_changeState,
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2096
|
+
De as _3DSpace_lifecycle_getGraph,
|
|
2097
|
+
Ue as _3DSpace_lifecycle_getNextRevision,
|
|
2098
|
+
Fe as _3DSpace_lifecycle_getNextStates,
|
|
2097
2099
|
qe as _3DSwym_buildDirectMessage,
|
|
2098
2100
|
ze as _3DSwym_deleteIdea,
|
|
2099
2101
|
te as _3DSwym_findCommunityToInstantMSG,
|
|
2100
2102
|
Be as _3DSwym_getAllCommunities,
|
|
2101
|
-
|
|
2103
|
+
Xe as _3DSwym_getAllNews,
|
|
2102
2104
|
We as _3DSwym_getFamiliarPeople,
|
|
2103
2105
|
Ye as _3DSwym_getIdeaStatusMaturity,
|
|
2104
2106
|
ee as _3DSwym_getMembersCommunity,
|
|
@@ -2115,7 +2117,7 @@ export {
|
|
|
2115
2117
|
at as _Iterop_ListUsers,
|
|
2116
2118
|
E as _getPlateformInfos,
|
|
2117
2119
|
ge as _getPlatformServices,
|
|
2118
|
-
|
|
2120
|
+
A as _getServiceUrl,
|
|
2119
2121
|
he as _getServiceUrl_3DPassport,
|
|
2120
2122
|
nt as _getServiceUrl_Iterop,
|
|
2121
2123
|
f as _httpCallAuthenticated,
|
|
@@ -2133,12 +2135,12 @@ export {
|
|
|
2133
2135
|
K as getCSRFToken,
|
|
2134
2136
|
ce as getCommunes,
|
|
2135
2137
|
Ce as getComplementUG,
|
|
2136
|
-
|
|
2138
|
+
Pe as getDataFrom3DSpace,
|
|
2137
2139
|
le as getDataFromGouvFr,
|
|
2138
2140
|
Je as getDatasByTenant,
|
|
2139
2141
|
Ee as getDatasFrom3DSpace,
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
+
xe as getDownloadDocument,
|
|
2143
|
+
Ve as getInfoDocTags,
|
|
2142
2144
|
Te as getUserGroupsList,
|
|
2143
2145
|
G as getUsersGroupRules,
|
|
2144
2146
|
Le as get_3DSpace_csrf,
|