@beam3_dev/api_module 0.0.134 → 0.0.136
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 +33 -30
- package/dist/wb3Api.js.map +1 -1
- package/dist/wb3Api.umd.cjs +3 -3
- package/dist/wb3Api.umd.cjs.map +1 -1
- package/package.json +1 -1
package/dist/wb3Api.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { v4 as L } from "uuid";
|
|
2
2
|
import { DateTime as N } from "luxon";
|
|
3
|
-
import { requirejs as O, widget as
|
|
3
|
+
import { requirejs as O, widget as U } from "@widget-lab/3ddashboard-utils";
|
|
4
4
|
function j() {
|
|
5
5
|
return L();
|
|
6
6
|
}
|
|
@@ -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: U.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 = U.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 F(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, {
|
|
@@ -250,7 +250,7 @@ function ye(e, t, n = void 0, s = void 0) {
|
|
|
250
250
|
}
|
|
251
251
|
});
|
|
252
252
|
}
|
|
253
|
-
const
|
|
253
|
+
const A = {
|
|
254
254
|
"Content-Type": "application/json",
|
|
255
255
|
Accept: "application/json,text/javascript,*/*"
|
|
256
256
|
};
|
|
@@ -271,7 +271,7 @@ function we(e, t, n = void 0, s = void 0) {
|
|
|
271
271
|
};
|
|
272
272
|
f(a, {
|
|
273
273
|
method: "POST",
|
|
274
|
-
headers:
|
|
274
|
+
headers: A,
|
|
275
275
|
data: JSON.stringify(c),
|
|
276
276
|
onComplete(d) {
|
|
277
277
|
n && n(JSON.parse(d));
|
|
@@ -366,7 +366,7 @@ function be(e, t, n, s = void 0, i = void 0) {
|
|
|
366
366
|
OPTsTenant: `tenant=dstenant:${o}`
|
|
367
367
|
}, c = n, d = `${r}${a.URIUGr}/${t}`, l = JSON.stringify(c);
|
|
368
368
|
f(d, {
|
|
369
|
-
headers:
|
|
369
|
+
headers: A,
|
|
370
370
|
method: "PATCH",
|
|
371
371
|
data: l,
|
|
372
372
|
type: "json",
|
|
@@ -382,7 +382,7 @@ function Ne(e, t, n, s = void 0, i = void 0) {
|
|
|
382
382
|
const { space: r } = e, a = `${r}/3drdfpersist/resources/v1/usersgroup/${t}/sharing`;
|
|
383
383
|
f(a, {
|
|
384
384
|
method: "PATCH",
|
|
385
|
-
headers:
|
|
385
|
+
headers: A,
|
|
386
386
|
data: JSON.stringify(n),
|
|
387
387
|
type: "json",
|
|
388
388
|
onComplete(d) {
|
|
@@ -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 Fe(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 = {
|
|
@@ -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 Ae(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`;
|
|
@@ -958,7 +958,7 @@ function De(e, t, n = void 0, s = void 0) {
|
|
|
958
958
|
}
|
|
959
959
|
});
|
|
960
960
|
}
|
|
961
|
-
function
|
|
961
|
+
function Ie(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}`;
|
|
@@ -1003,7 +1003,7 @@ function Ue(e, t, n = void 0, s = void 0) {
|
|
|
1003
1003
|
}
|
|
1004
1004
|
});
|
|
1005
1005
|
}
|
|
1006
|
-
function
|
|
1006
|
+
function Ue(e, t, n, s = void 0, i = void 0) {
|
|
1007
1007
|
return new Promise((r) => {
|
|
1008
1008
|
if (e.token === "" && T(e), t !== void 0 && t !== "" && t !== null) {
|
|
1009
1009
|
const o = `${e.space}/resources/lifecycle/revise/major?tenant=${e.tenant}`;
|
|
@@ -1608,7 +1608,7 @@ function qe(e, t, n = void 0, s = void 0) {
|
|
|
1608
1608
|
te(
|
|
1609
1609
|
a.users,
|
|
1610
1610
|
(l) => {
|
|
1611
|
-
l !== void 0 && (c.id_msg = l.id, d = !0,
|
|
1611
|
+
l !== void 0 && (c.id_msg = l.id, d = !0, I(e, c));
|
|
1612
1612
|
},
|
|
1613
1613
|
(l) => {
|
|
1614
1614
|
d = !1, console.log("_3dSwym_findCommunityToInstantMSG callback", l), s && s(l), c.id_msg = "";
|
|
@@ -1626,7 +1626,7 @@ function qe(e, t, n = void 0, s = void 0) {
|
|
|
1626
1626
|
type: "json",
|
|
1627
1627
|
onComplete(p, u, m) {
|
|
1628
1628
|
const g = p;
|
|
1629
|
-
g.reponse = JSON.parse(m.response), g.status = m.status, n && n(g), c.id_msg = g.result.id,
|
|
1629
|
+
g.reponse = JSON.parse(m.response), g.status = m.status, n && n(g), c.id_msg = g.result.id, I(e, c);
|
|
1630
1630
|
},
|
|
1631
1631
|
onFailure(p, u, m) {
|
|
1632
1632
|
const g = p;
|
|
@@ -1665,7 +1665,7 @@ function te(e, t, n, s) {
|
|
|
1665
1665
|
});
|
|
1666
1666
|
});
|
|
1667
1667
|
}
|
|
1668
|
-
function
|
|
1668
|
+
function I(e, t, n = void 0, s = void 0) {
|
|
1669
1669
|
const i = {
|
|
1670
1670
|
base: e.space,
|
|
1671
1671
|
uri: "/api/community",
|
|
@@ -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 && F(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 && F(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,17 +1979,20 @@ function st(e, t = void 0, n = void 0) {
|
|
|
1979
1979
|
});
|
|
1980
1980
|
}
|
|
1981
1981
|
async function at(e, t) {
|
|
1982
|
-
|
|
1982
|
+
e.tenant && F(e, (n) => {
|
|
1983
1983
|
console.log("serviceUrls", n);
|
|
1984
|
-
const s = n.services.find((
|
|
1985
|
-
|
|
1986
|
-
method: "GET",
|
|
1984
|
+
const s = n.services.find((o) => o.id === "3ddashboard")?.url, i = n.services.find((o) => o.id === "businessprocess")?.url + "/api/v2", r = `${s}/login/?service=${i}/identity/users`;
|
|
1985
|
+
f(r, {
|
|
1987
1986
|
headers: {
|
|
1988
1987
|
Authorization: `Bearer ${t}`
|
|
1988
|
+
},
|
|
1989
|
+
async onComplete(o) {
|
|
1990
|
+
console.log("response", o), onDone && onDone(data?.token);
|
|
1991
|
+
},
|
|
1992
|
+
onFailure(o) {
|
|
1993
|
+
onError && onError(o);
|
|
1989
1994
|
}
|
|
1990
|
-
})
|
|
1991
|
-
console.log(i), onDone && onDone(i?.token);
|
|
1992
|
-
}).catch((i) => console.log(i));
|
|
1995
|
+
});
|
|
1993
1996
|
});
|
|
1994
1997
|
}
|
|
1995
1998
|
function it(e) {
|
|
@@ -2078,7 +2081,7 @@ function ot(e, t = void 0, n = void 0) {
|
|
|
2078
2081
|
export {
|
|
2079
2082
|
j as UUID,
|
|
2080
2083
|
ot as _3DSearch_usersGroup,
|
|
2081
|
-
|
|
2084
|
+
Fe as _3DSpace_Create_Doc,
|
|
2082
2085
|
je as _3DSpace_bookmark_addSubsciptions,
|
|
2083
2086
|
T as _3DSpace_csrf,
|
|
2084
2087
|
R as _3DSpace_download_doc,
|
|
@@ -2091,11 +2094,11 @@ export {
|
|
|
2091
2094
|
Y as _3DSpace_get_downloadTicket_multidoc,
|
|
2092
2095
|
b as _3DSpace_get_securityContexts,
|
|
2093
2096
|
$ as _3DSpace_get_ticket,
|
|
2094
|
-
|
|
2097
|
+
Ue as _3DSpace_lifecycle_changeRevision,
|
|
2095
2098
|
$e as _3DSpace_lifecycle_changeState,
|
|
2096
2099
|
De as _3DSpace_lifecycle_getGraph,
|
|
2097
|
-
|
|
2098
|
-
|
|
2100
|
+
Ie as _3DSpace_lifecycle_getNextRevision,
|
|
2101
|
+
Ae as _3DSpace_lifecycle_getNextStates,
|
|
2099
2102
|
qe as _3DSwym_buildDirectMessage,
|
|
2100
2103
|
ze as _3DSwym_deleteIdea,
|
|
2101
2104
|
te as _3DSwym_findCommunityToInstantMSG,
|
|
@@ -2110,14 +2113,14 @@ export {
|
|
|
2110
2113
|
tt as _3DSwym_get_findUser,
|
|
2111
2114
|
w as _3DSwym_get_version,
|
|
2112
2115
|
He as _3DSwym_postIdea,
|
|
2113
|
-
|
|
2116
|
+
I as _3DSwym_sendMessageData,
|
|
2114
2117
|
ye as _AppMngt_get_info_user,
|
|
2115
2118
|
_e as _AppMngt_get_users,
|
|
2116
2119
|
st as _Iterop_Auth_CAS,
|
|
2117
2120
|
at as _Iterop_ListUsers,
|
|
2118
2121
|
E as _getPlateformInfos,
|
|
2119
2122
|
ge as _getPlatformServices,
|
|
2120
|
-
|
|
2123
|
+
F as _getServiceUrl,
|
|
2121
2124
|
he as _getServiceUrl_3DPassport,
|
|
2122
2125
|
nt as _getServiceUrl_Iterop,
|
|
2123
2126
|
f as _httpCallAuthenticated,
|