@beam3_dev/api_module 0.0.136 → 0.0.138
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 +64 -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
|
@@ -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, {
|
|
@@ -250,7 +250,7 @@ function ye(e, t, n = void 0, s = void 0) {
|
|
|
250
250
|
}
|
|
251
251
|
});
|
|
252
252
|
}
|
|
253
|
-
const
|
|
253
|
+
const $ = {
|
|
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: $,
|
|
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: $,
|
|
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: $,
|
|
386
386
|
data: JSON.stringify(n),
|
|
387
387
|
type: "json",
|
|
388
388
|
onComplete(d) {
|
|
@@ -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 F(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,
|
|
@@ -534,7 +534,7 @@ function X(e, t, n, s, i, r = void 0, o = void 0) {
|
|
|
534
534
|
e,
|
|
535
535
|
t,
|
|
536
536
|
(a) => {
|
|
537
|
-
|
|
537
|
+
B(
|
|
538
538
|
e,
|
|
539
539
|
t,
|
|
540
540
|
n,
|
|
@@ -547,7 +547,7 @@ function X(e, t, n, s, i, r = void 0, o = void 0) {
|
|
|
547
547
|
}
|
|
548
548
|
);
|
|
549
549
|
}
|
|
550
|
-
function
|
|
550
|
+
function B(e, t, n, s, i, r, o = void 0, a = void 0) {
|
|
551
551
|
const c = e.space + `/resources/v1/modeler/documents/${t}/files/CheckinTicket`;
|
|
552
552
|
f(c, {
|
|
553
553
|
method: "PUT",
|
|
@@ -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 = {
|
|
@@ -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
|
+
F(
|
|
739
739
|
e,
|
|
740
740
|
(r) => {
|
|
741
741
|
f(r, {
|
|
@@ -771,7 +771,7 @@ async function R(e, t = void 0, n = void 0) {
|
|
|
771
771
|
);
|
|
772
772
|
});
|
|
773
773
|
}
|
|
774
|
-
async function
|
|
774
|
+
async function W(e, t, n = void 0, s = void 0) {
|
|
775
775
|
let i = [];
|
|
776
776
|
if (typeof t < "u" && Array.isArray(t) && t?.length > 0) {
|
|
777
777
|
for (let a = 0; a < t.length; a += 80) {
|
|
@@ -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 $e(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`;
|
|
@@ -879,7 +879,7 @@ function Ae(e, t, n = void 0, s = void 0) {
|
|
|
879
879
|
}
|
|
880
880
|
});
|
|
881
881
|
}
|
|
882
|
-
function
|
|
882
|
+
function Fe(e, t, n, s = void 0, i = void 0) {
|
|
883
883
|
return new Promise((r) => {
|
|
884
884
|
if (e.token === "" && T(e), t !== void 0 && t !== "" && t !== null) {
|
|
885
885
|
const o = `${e.space}/resources/v1/modeler/dslc/maturity/changeState`;
|
|
@@ -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 Ie(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 De(e, t, n = void 0, s = void 0) {
|
|
|
958
958
|
}
|
|
959
959
|
});
|
|
960
960
|
}
|
|
961
|
-
function
|
|
961
|
+
function De(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}`;
|
|
@@ -1092,7 +1092,7 @@ function Re(e, t = void 0, n = void 0) {
|
|
|
1092
1092
|
});
|
|
1093
1093
|
}
|
|
1094
1094
|
function Pe(e, t, n, s) {
|
|
1095
|
-
|
|
1095
|
+
F(
|
|
1096
1096
|
e.space,
|
|
1097
1097
|
t,
|
|
1098
1098
|
(i) => {
|
|
@@ -1110,7 +1110,7 @@ function Pe(e, t, n, s) {
|
|
|
1110
1110
|
}
|
|
1111
1111
|
async function xe(e, t, n = void 0, s = void 0) {
|
|
1112
1112
|
return new Promise((i) => {
|
|
1113
|
-
|
|
1113
|
+
F(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) => {
|
|
@@ -1144,7 +1144,7 @@ function Me(e, t, n, s = void 0, i = void 0) {
|
|
|
1144
1144
|
);
|
|
1145
1145
|
}
|
|
1146
1146
|
let P, x;
|
|
1147
|
-
const
|
|
1147
|
+
const I = [];
|
|
1148
1148
|
async function Le(e, t = void 0, n = void 0) {
|
|
1149
1149
|
e.objID && e.objID !== "" ? v(
|
|
1150
1150
|
e,
|
|
@@ -1193,19 +1193,19 @@ function Ee(e, t = void 0, n = void 0) {
|
|
|
1193
1193
|
});
|
|
1194
1194
|
}
|
|
1195
1195
|
function q(e, t, n = void 0, s = void 0) {
|
|
1196
|
-
|
|
1196
|
+
W(
|
|
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, x = r,
|
|
1201
|
+
r.find((o) => o.objectID === i.objectId).data = i.data, x = r, I.push(i.data), n && n(I);
|
|
1202
1202
|
},
|
|
1203
1203
|
(i) => {
|
|
1204
1204
|
s && (s(i), console.log(i));
|
|
1205
1205
|
}
|
|
1206
1206
|
);
|
|
1207
1207
|
}
|
|
1208
|
-
const
|
|
1208
|
+
const z = "FA35FB9B177A280065800EA0000F599C", H = [
|
|
1209
1209
|
"swym",
|
|
1210
1210
|
"3dspace",
|
|
1211
1211
|
"drive",
|
|
@@ -1220,7 +1220,7 @@ const H = "FA35FB9B177A280065800EA0000F599C", z = [
|
|
|
1220
1220
|
who: "ds6w:who",
|
|
1221
1221
|
why: "ds6w:why"
|
|
1222
1222
|
}, Q = {
|
|
1223
|
-
objId:
|
|
1223
|
+
objId: z,
|
|
1224
1224
|
pred: "who",
|
|
1225
1225
|
order_by: "desc",
|
|
1226
1226
|
tag: "testTag"
|
|
@@ -1346,7 +1346,7 @@ function Z(e, t, n = void 0, s = void 0) {
|
|
|
1346
1346
|
],
|
|
1347
1347
|
nresults: 40,
|
|
1348
1348
|
start: "0",
|
|
1349
|
-
source:
|
|
1349
|
+
source: H,
|
|
1350
1350
|
tenant: e.tenant,
|
|
1351
1351
|
login: {
|
|
1352
1352
|
"3dspace": {
|
|
@@ -1470,7 +1470,7 @@ function Xe(e, t = void 0, n = void 0) {
|
|
|
1470
1470
|
});
|
|
1471
1471
|
});
|
|
1472
1472
|
}
|
|
1473
|
-
function
|
|
1473
|
+
function Be(e, t = void 0, n = void 0) {
|
|
1474
1474
|
const s = `${e.space}/api/Recommendation/getpeoplefamiliartocurrentuser`, i = {
|
|
1475
1475
|
params: {
|
|
1476
1476
|
idsToFilterArr: [],
|
|
@@ -1500,7 +1500,7 @@ function We(e, t = void 0, n = void 0) {
|
|
|
1500
1500
|
});
|
|
1501
1501
|
});
|
|
1502
1502
|
}
|
|
1503
|
-
function
|
|
1503
|
+
function We(e, t = void 0, n = void 0) {
|
|
1504
1504
|
const s = {
|
|
1505
1505
|
base: e.space,
|
|
1506
1506
|
uri: "/api/community/listmycommunities",
|
|
@@ -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, D(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, D(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 D(e, t, n = void 0, s = void 0) {
|
|
1669
1669
|
const i = {
|
|
1670
1670
|
base: e.space,
|
|
1671
1671
|
uri: "/api/community",
|
|
@@ -1719,7 +1719,7 @@ const se = {
|
|
|
1719
1719
|
idee_id: "THhRI8rlQNWKRxpv3Xqqug"
|
|
1720
1720
|
// id de l'idee qui est créer au post (_3dSwym_postIdea)
|
|
1721
1721
|
};
|
|
1722
|
-
function
|
|
1722
|
+
function ze(e, t, n = void 0, s = void 0) {
|
|
1723
1723
|
const i = `${e.space}/api/idea/add`, r = e.swymCommunities.find(
|
|
1724
1724
|
(c) => c.id === t.community_id
|
|
1725
1725
|
), o = e.swymCommunities.find(
|
|
@@ -1758,7 +1758,7 @@ function He(e, t, n = void 0, s = void 0) {
|
|
|
1758
1758
|
});
|
|
1759
1759
|
});
|
|
1760
1760
|
}
|
|
1761
|
-
function
|
|
1761
|
+
function He(e, t, n = void 0, s = void 0) {
|
|
1762
1762
|
const i = `${e.space}/api/idea/delete`, r = {
|
|
1763
1763
|
params: {
|
|
1764
1764
|
community_id: t.community_id,
|
|
@@ -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, {
|
|
@@ -1968,8 +1968,14 @@ function st(e, t = void 0, n = void 0) {
|
|
|
1968
1968
|
const c = typeof a == "string" ? JSON.parse(a)?.x3ds_service_redirect_url : a?.x3ds_service_redirect_url;
|
|
1969
1969
|
await fetch(c, {
|
|
1970
1970
|
method: "POST"
|
|
1971
|
-
}).then((d) => d.json()).then((d) => {
|
|
1972
|
-
|
|
1971
|
+
}).then((d) => d.json()).then(async (d) => {
|
|
1972
|
+
await fetch(r, {
|
|
1973
|
+
headers: {
|
|
1974
|
+
Authorization: `Bearer ${d?.token}`
|
|
1975
|
+
}
|
|
1976
|
+
}).then((l) => l.json()).then((l) => {
|
|
1977
|
+
console.log(l);
|
|
1978
|
+
}).catch((l) => console.log(l)), t && t(d?.token);
|
|
1973
1979
|
});
|
|
1974
1980
|
},
|
|
1975
1981
|
onFailure(a) {
|
|
@@ -1979,21 +1985,27 @@ function st(e, t = void 0, n = void 0) {
|
|
|
1979
1985
|
});
|
|
1980
1986
|
}
|
|
1981
1987
|
async function at(e, t) {
|
|
1982
|
-
e.tenant &&
|
|
1988
|
+
e.tenant && A(e, (n) => {
|
|
1983
1989
|
console.log("serviceUrls", n);
|
|
1984
|
-
const s = n.services.find((o) => o.id === "
|
|
1990
|
+
const s = n.services.find((o) => o.id === "3dpassport")?.url, i = n.services.find((o) => o.id === "businessprocess")?.url + "/api/v2", r = `${s}/login/?service=${i}/identity/users`;
|
|
1985
1991
|
f(r, {
|
|
1986
1992
|
headers: {
|
|
1987
1993
|
Authorization: `Bearer ${t}`
|
|
1988
1994
|
},
|
|
1989
1995
|
async onComplete(o) {
|
|
1990
|
-
console.log("response", o)
|
|
1996
|
+
console.log("response", o);
|
|
1991
1997
|
},
|
|
1992
1998
|
onFailure(o) {
|
|
1993
1999
|
onError && onError(o);
|
|
1994
2000
|
}
|
|
1995
2001
|
});
|
|
1996
|
-
})
|
|
2002
|
+
}), await fetch(urlAPIV2Iterop, {
|
|
2003
|
+
headers: {
|
|
2004
|
+
Authorization: `Bearer ${t}`
|
|
2005
|
+
}
|
|
2006
|
+
}).then((n) => n.json()).then((n) => {
|
|
2007
|
+
console.log(n);
|
|
2008
|
+
}).catch((n) => console.log(n));
|
|
1997
2009
|
}
|
|
1998
2010
|
function it(e) {
|
|
1999
2011
|
const t = "Hello " + e;
|
|
@@ -2081,30 +2093,30 @@ function ot(e, t = void 0, n = void 0) {
|
|
|
2081
2093
|
export {
|
|
2082
2094
|
j as UUID,
|
|
2083
2095
|
ot as _3DSearch_usersGroup,
|
|
2084
|
-
|
|
2096
|
+
Ae as _3DSpace_Create_Doc,
|
|
2085
2097
|
je as _3DSpace_bookmark_addSubsciptions,
|
|
2086
2098
|
T as _3DSpace_csrf,
|
|
2087
2099
|
R as _3DSpace_download_doc,
|
|
2088
|
-
|
|
2100
|
+
W as _3DSpace_download_multidoc,
|
|
2089
2101
|
X as _3DSpace_file_update,
|
|
2090
|
-
|
|
2102
|
+
B as _3DSpace_file_update_csr,
|
|
2091
2103
|
ke as _3DSpace_file_url_csr,
|
|
2092
2104
|
v as _3DSpace_get_csrf,
|
|
2093
2105
|
V as _3DSpace_get_docInfo,
|
|
2094
2106
|
Y as _3DSpace_get_downloadTicket_multidoc,
|
|
2095
2107
|
b as _3DSpace_get_securityContexts,
|
|
2096
|
-
|
|
2108
|
+
F as _3DSpace_get_ticket,
|
|
2097
2109
|
Ue as _3DSpace_lifecycle_changeRevision,
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2110
|
+
Fe as _3DSpace_lifecycle_changeState,
|
|
2111
|
+
Ie as _3DSpace_lifecycle_getGraph,
|
|
2112
|
+
De as _3DSpace_lifecycle_getNextRevision,
|
|
2113
|
+
$e as _3DSpace_lifecycle_getNextStates,
|
|
2102
2114
|
qe as _3DSwym_buildDirectMessage,
|
|
2103
|
-
|
|
2115
|
+
He as _3DSwym_deleteIdea,
|
|
2104
2116
|
te as _3DSwym_findCommunityToInstantMSG,
|
|
2105
|
-
|
|
2117
|
+
We as _3DSwym_getAllCommunities,
|
|
2106
2118
|
Xe as _3DSwym_getAllNews,
|
|
2107
|
-
|
|
2119
|
+
Be as _3DSwym_getFamiliarPeople,
|
|
2108
2120
|
Ye as _3DSwym_getIdeaStatusMaturity,
|
|
2109
2121
|
ee as _3DSwym_getMembersCommunity,
|
|
2110
2122
|
Qe as _3DSwym_getSWYMIdea,
|
|
@@ -2112,15 +2124,15 @@ export {
|
|
|
2112
2124
|
et as _3DSwym_get_currentUser,
|
|
2113
2125
|
tt as _3DSwym_get_findUser,
|
|
2114
2126
|
w as _3DSwym_get_version,
|
|
2115
|
-
|
|
2116
|
-
|
|
2127
|
+
ze as _3DSwym_postIdea,
|
|
2128
|
+
D as _3DSwym_sendMessageData,
|
|
2117
2129
|
ye as _AppMngt_get_info_user,
|
|
2118
2130
|
_e as _AppMngt_get_users,
|
|
2119
2131
|
st as _Iterop_Auth_CAS,
|
|
2120
2132
|
at as _Iterop_ListUsers,
|
|
2121
2133
|
E as _getPlateformInfos,
|
|
2122
2134
|
ge as _getPlatformServices,
|
|
2123
|
-
|
|
2135
|
+
A as _getServiceUrl,
|
|
2124
2136
|
he as _getServiceUrl_3DPassport,
|
|
2125
2137
|
nt as _getServiceUrl_Iterop,
|
|
2126
2138
|
f as _httpCallAuthenticated,
|