@beam3_dev/api_module 0.0.156 → 0.0.157

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  import { v4 as E } from "uuid";
2
2
  import { DateTime as v } from "luxon";
3
- import { requirejs as O, widget as D } from "@widget-lab/3ddashboard-utils";
4
- function P() {
3
+ import { requirejs as O, widget as R } from "@widget-lab/3ddashboard-utils";
4
+ function D() {
5
5
  return E();
6
6
  }
7
7
  const G = {
@@ -121,7 +121,7 @@ function ye(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: D.id,
124
+ widgetId: R.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 we(e, t = void 0, n = void 0) {
137
137
  await O(
138
138
  ["DS/i3DXCompassServices/i3DXCompassServices"],
139
139
  (s) => {
140
- (!e || e === "") && (e = D.getValue("PlatFormInstanceId")), (!e || e === "") && (e = void 0), t && t(
140
+ (!e || e === "") && (e = R.getValue("PlatFormInstanceId")), (!e || e === "") && (e = void 0), t && t(
141
141
  s.getPlatformServices({
142
142
  platformId: e,
143
143
  onComplete: t,
@@ -250,7 +250,7 @@ function be(e, t, n = void 0, s = void 0) {
250
250
  }
251
251
  });
252
252
  }
253
- const U = {
253
+ const F = {
254
254
  "Content-Type": "application/json",
255
255
  Accept: "application/json,text/javascript,*/*"
256
256
  };
@@ -271,7 +271,7 @@ function Ne(e, t, n = void 0, s = void 0) {
271
271
  };
272
272
  m(i, {
273
273
  method: "POST",
274
- headers: U,
274
+ headers: F,
275
275
  data: JSON.stringify(c),
276
276
  onComplete(d) {
277
277
  n && n(JSON.parse(d));
@@ -366,7 +366,7 @@ function Ae(e, t, n, s = void 0, a = void 0) {
366
366
  OPTsTenant: `tenant=dstenant:${o}`
367
367
  }, c = n, d = `${r}${i.URIUGr}/${t}`, l = JSON.stringify(c);
368
368
  m(d, {
369
- headers: U,
369
+ headers: F,
370
370
  method: "PATCH",
371
371
  data: l,
372
372
  type: "json",
@@ -382,7 +382,7 @@ function ke(e, t, n, s = void 0, a = void 0) {
382
382
  const { space: r } = e, i = `${r}/3drdfpersist/resources/v1/usersgroup/${t}/sharing`;
383
383
  m(i, {
384
384
  method: "PATCH",
385
- headers: U,
385
+ headers: F,
386
386
  data: JSON.stringify(n),
387
387
  type: "json",
388
388
  onComplete(d) {
@@ -393,7 +393,7 @@ function ke(e, t, n, s = void 0, a = void 0) {
393
393
  }
394
394
  });
395
395
  }
396
- function Ue(e, t, n = void 0, s = void 0) {
396
+ function Fe(e, t, n = void 0, s = void 0) {
397
397
  const { space: a } = e, o = `${a}/3drdfpersist/resources/v1/usersgroup/${t}/sharing`;
398
398
  m(o, {
399
399
  opts: {
@@ -482,7 +482,7 @@ async function H(e, t = void 0, n = void 0, s = void 0) {
482
482
  }
483
483
  });
484
484
  }
485
- async function Fe(e, t = void 0, n = void 0, s = void 0) {
485
+ async function Ue(e, t = void 0, n = void 0, s = void 0) {
486
486
  const a = e.space;
487
487
  if (t === void 0) {
488
488
  console.log("Le paramètre docids est obligatoire");
@@ -548,7 +548,7 @@ function T(e, t = void 0, n = void 0) {
548
548
  } else
549
549
  n && n("ERROR : url du 3DSpace non défini.");
550
550
  }
551
- function F(e, t = void 0, n = void 0) {
551
+ function U(e, t = void 0, n = void 0) {
552
552
  let s = e.space + `/resources/v1/modeler/documents/${e.objID}/files/DownloadTicket`;
553
553
  A(
554
554
  e,
@@ -664,7 +664,7 @@ function q(e, t, n, s, a, r, o = void 0, i = void 0) {
664
664
  }
665
665
  });
666
666
  }
667
- async function Re(e, t, n, s, a = void 0, r = void 0) {
667
+ async function Pe(e, t, n, s, a = void 0, r = void 0) {
668
668
  const o = e.space, i = e.token, c = e.ctx, d = new FormData(), l = new Blob([JSON.stringify(t)], {
669
669
  type: "text/plain"
670
670
  }), p = {
@@ -711,7 +711,7 @@ async function Re(e, t, n, s, a = void 0, r = void 0) {
711
711
  }
712
712
  }]
713
713
  },
714
- tempId: P()
714
+ tempId: D()
715
715
  }]
716
716
  }),
717
717
  type: "json",
@@ -799,10 +799,12 @@ async function x(e, t = void 0, n = void 0) {
799
799
  console.log("☠️ error => ", s);
800
800
  }
801
801
  ), new Promise((s, a) => {
802
- F(
802
+ U(
803
803
  e,
804
804
  (r) => {
805
- m(r, {
805
+ e?.returnType === "blob" ? fetch(r).then((o) => o.blob()).then((o) => {
806
+ t && t(o);
807
+ }) : m(r, {
806
808
  onComplete(o) {
807
809
  let i;
808
810
  try {
@@ -911,7 +913,7 @@ function Z(e, t, n = void 0, s = void 0, a = void 0) {
911
913
  }
912
914
  });
913
915
  }
914
- function De(e, t, n = void 0, s = void 0) {
916
+ function Re(e, t, n = void 0, s = void 0) {
915
917
  return new Promise((a) => {
916
918
  if (e.token === "" && T(e), t !== void 0 && t !== "" && t !== null) {
917
919
  const r = `${e.space}/resources/v1/modeler/dslc/maturity/getNextStates`;
@@ -950,7 +952,7 @@ function De(e, t, n = void 0, s = void 0) {
950
952
  }
951
953
  });
952
954
  }
953
- function Pe(e, t, n, s = void 0, a = void 0) {
955
+ function De(e, t, n, s = void 0, a = void 0) {
954
956
  return new Promise((r) => {
955
957
  if (e.token === "" && T(e), t !== void 0 && t !== "" && t !== null) {
956
958
  const o = `${e.space}/resources/v1/modeler/dslc/maturity/changeState`;
@@ -1196,7 +1198,7 @@ function Ge(e, t = void 0, n = void 0) {
1196
1198
  });
1197
1199
  }
1198
1200
  function Ke(e, t, n, s) {
1199
- F(
1201
+ U(
1200
1202
  e.space,
1201
1203
  t,
1202
1204
  (a) => {
@@ -1214,7 +1216,7 @@ function Ke(e, t, n, s) {
1214
1216
  }
1215
1217
  async function Ve(e, t, n = void 0, s = void 0) {
1216
1218
  return new Promise((a) => {
1217
- F(e, t, (r) => {
1219
+ U(e, t, (r) => {
1218
1220
  m(r, {
1219
1221
  onComplete: (o, i, c) => (a(JSON.parse(o)), n && n(JSON.parse(o), i, c), a),
1220
1222
  onFailure: (o, i, c) => {
@@ -1397,7 +1399,7 @@ function ie(e, t, n = void 0, s = void 0) {
1397
1399
  }, o = `${r.baseUrl}${r.uri}`, i = {
1398
1400
  "Content-Type": "application/json",
1399
1401
  Accept: "application/json,text/javascript,*/*"
1400
- }, c = P(), d = {
1402
+ }, c = D(), d = {
1401
1403
  with_indexing_date: !0,
1402
1404
  with_synthesis: !0,
1403
1405
  with_nls: !1,
@@ -1712,7 +1714,7 @@ function nt(e, t, n = void 0, s = void 0) {
1712
1714
  oe(
1713
1715
  i.users,
1714
1716
  (l) => {
1715
- l !== void 0 && (c.id_msg = l.id, d = !0, R(e, c));
1717
+ l !== void 0 && (c.id_msg = l.id, d = !0, P(e, c));
1716
1718
  },
1717
1719
  (l) => {
1718
1720
  d = !1, console.log("_3dSwym_findCommunityToInstantMSG callback", l), s && s(l), c.id_msg = "";
@@ -1730,7 +1732,7 @@ function nt(e, t, n = void 0, s = void 0) {
1730
1732
  type: "json",
1731
1733
  onComplete(p, f, u) {
1732
1734
  const g = p;
1733
- g.reponse = JSON.parse(u.response), g.status = u.status, n && n(g), c.id_msg = g.result.id, R(e, c);
1735
+ g.reponse = JSON.parse(u.response), g.status = u.status, n && n(g), c.id_msg = g.result.id, P(e, c);
1734
1736
  },
1735
1737
  onFailure(p, f, u) {
1736
1738
  const g = p;
@@ -1769,7 +1771,7 @@ function oe(e, t, n, s) {
1769
1771
  });
1770
1772
  });
1771
1773
  }
1772
- function R(e, t, n = void 0, s = void 0) {
1774
+ function P(e, t, n = void 0, s = void 0) {
1773
1775
  const a = {
1774
1776
  base: e.space,
1775
1777
  uri: "/api/community",
@@ -2205,9 +2207,9 @@ function gt(e, t = void 0, n = void 0) {
2205
2207
  });
2206
2208
  }
2207
2209
  export {
2208
- P as UUID,
2210
+ D as UUID,
2209
2211
  gt as _3DSearch_usersGroup,
2210
- Re as _3DSpace_Create_Doc,
2212
+ Pe as _3DSpace_Create_Doc,
2211
2213
  Ee as _3DSpace_bookmark_addSubsciptions,
2212
2214
  Je as _3DSpace_bookmark_newWorkspace,
2213
2215
  T as _3DSpace_csrf,
@@ -2219,14 +2221,14 @@ export {
2219
2221
  A as _3DSpace_get_csrf,
2220
2222
  H as _3DSpace_get_docInfo,
2221
2223
  Z as _3DSpace_get_downloadTicket_multidoc,
2222
- Fe as _3DSpace_get_multiDocInfo,
2224
+ Ue as _3DSpace_get_multiDocInfo,
2223
2225
  b as _3DSpace_get_securityContexts,
2224
- F as _3DSpace_get_ticket,
2226
+ U as _3DSpace_get_ticket,
2225
2227
  Le as _3DSpace_lifecycle_changeRevision,
2226
- Pe as _3DSpace_lifecycle_changeState,
2228
+ De as _3DSpace_lifecycle_changeState,
2227
2229
  xe as _3DSpace_lifecycle_getGraph,
2228
2230
  Me as _3DSpace_lifecycle_getNextRevision,
2229
- De as _3DSpace_lifecycle_getNextStates,
2231
+ Re as _3DSpace_lifecycle_getNextStates,
2230
2232
  nt as _3DSwym_buildDirectMessage,
2231
2233
  it as _3DSwym_deleteIdea,
2232
2234
  oe as _3DSwym_findCommunityToInstantMSG,
@@ -2241,7 +2243,7 @@ export {
2241
2243
  ct as _3DSwym_get_findUser,
2242
2244
  w as _3DSwym_get_version,
2243
2245
  st as _3DSwym_postIdea,
2244
- R as _3DSwym_sendMessageData,
2246
+ P as _3DSwym_sendMessageData,
2245
2247
  be as _AppMngt_get_info_user,
2246
2248
  Oe as _AppMngt_get_users,
2247
2249
  lt as _Iterop_Auth_CAS,
@@ -2280,7 +2282,7 @@ export {
2280
2282
  Ae as patchUserGroups,
2281
2283
  ke as patchUserGroupsControl,
2282
2284
  We as pushDataIn3DSpace,
2283
- Ue as readUserGroupControl,
2285
+ Fe as readUserGroupControl,
2284
2286
  ze as removeTagToDoc,
2285
2287
  mt as sayHello,
2286
2288
  he as updateEvent