@beam3_dev/api_module 0.0.228 → 0.0.230
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 +72 -72
- 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
|
@@ -363,8 +363,8 @@ function xe(e, t = void 0, n = void 0) {
|
|
|
363
363
|
onComplete(u) {
|
|
364
364
|
const p = JSON.parse(u), f = {}, l = p.groups.filter((g) => g.uri.startsWith("uuid:"));
|
|
365
365
|
if (i && Object.keys(i).length > 0) {
|
|
366
|
-
const g = l.filter((S) => S.owner === i.email),
|
|
367
|
-
f.iam =
|
|
366
|
+
const g = l.filter((S) => S.owner === i.email), h = l.filter((S) => S.members.includes(i.email)), y = g.concat(h);
|
|
367
|
+
f.iam = y, f.UG = l, f.iamMember = h, Y(
|
|
368
368
|
e,
|
|
369
369
|
(S) => {
|
|
370
370
|
f.rules = S, t && t(f);
|
|
@@ -656,12 +656,12 @@ function ee(e, t, n, s, i, r, o = void 0, a = void 0) {
|
|
|
656
656
|
},
|
|
657
657
|
onComplete(d, u, p) {
|
|
658
658
|
const f = JSON.parse(d).csrf, l = JSON.parse(d).data[0].dataelements, g = new FormData();
|
|
659
|
-
let
|
|
660
|
-
s instanceof Blob ?
|
|
659
|
+
let h;
|
|
660
|
+
s instanceof Blob ? h = s : h = new Blob([s], {
|
|
661
661
|
type: "text/plain"
|
|
662
|
-
}), g.append("__fcs__jobTicket", l.ticket), g.append("file_0",
|
|
663
|
-
const
|
|
664
|
-
|
|
662
|
+
}), g.append("__fcs__jobTicket", l.ticket), g.append("file_0", h, i);
|
|
663
|
+
const y = {};
|
|
664
|
+
y.method = "POST", y.data = g, y.onComplete = function(S) {
|
|
665
665
|
let _ = {
|
|
666
666
|
method: "PUT",
|
|
667
667
|
headers: {
|
|
@@ -699,9 +699,9 @@ function ee(e, t, n, s, i, r, o = void 0, a = void 0) {
|
|
|
699
699
|
e.space + `/resources/v1/modeler/documents/?$include=versions&tenant=${C}&e6w-lang=en&e6w-timezone=-120&xrequestedwith=xmlhttprequest`,
|
|
700
700
|
_
|
|
701
701
|
);
|
|
702
|
-
},
|
|
702
|
+
}, y.onFailure = function(S) {
|
|
703
703
|
a && a(S);
|
|
704
|
-
},
|
|
704
|
+
}, y.timeout = 0, m(l.ticketURL, y);
|
|
705
705
|
}
|
|
706
706
|
});
|
|
707
707
|
}
|
|
@@ -855,30 +855,30 @@ function A(e, t = void 0, n = void 0, s = void 0, i = void 0, r = void 0, o = !1
|
|
|
855
855
|
const d = JSON.parse(c);
|
|
856
856
|
let u = "", p, f, l;
|
|
857
857
|
if (t) {
|
|
858
|
-
let g = d.collabspaces.find((
|
|
858
|
+
let g = d.collabspaces.find((h) => h.title === t);
|
|
859
859
|
if (g) {
|
|
860
860
|
p = t;
|
|
861
|
-
let
|
|
862
|
-
|
|
863
|
-
(
|
|
864
|
-
(C) => C.organization.pid ===
|
|
861
|
+
let h = g.couples;
|
|
862
|
+
h = h.filter(
|
|
863
|
+
(y, S, _) => S === _.findIndex(
|
|
864
|
+
(C) => C.organization.pid === y.organization.pid && C.role.pid === y.role.pid
|
|
865
865
|
)
|
|
866
|
-
), n && (Array.isArray(n) ? n.forEach((
|
|
867
|
-
l ||
|
|
868
|
-
if (
|
|
869
|
-
l =
|
|
870
|
-
else if (
|
|
871
|
-
let _ =
|
|
872
|
-
(C) => C.role.name ===
|
|
866
|
+
), n && (Array.isArray(n) ? n.forEach((y) => {
|
|
867
|
+
l || h.forEach((S) => {
|
|
868
|
+
if (y === S.role.name && s === S.organization.title)
|
|
869
|
+
l = y, f = s;
|
|
870
|
+
else if (y === S.role.name) {
|
|
871
|
+
let _ = h.filter(
|
|
872
|
+
(C) => C.role.name === y
|
|
873
873
|
);
|
|
874
874
|
_.length === 1 ? (l = _[0].role.name, f = _[0].organization.title) : r(_);
|
|
875
875
|
}
|
|
876
876
|
});
|
|
877
|
-
}) :
|
|
878
|
-
if (n ===
|
|
877
|
+
}) : h.forEach((y) => {
|
|
878
|
+
if (n === y.role.name && s === y.organization.title)
|
|
879
879
|
l = n, f = s;
|
|
880
|
-
else if (n ===
|
|
881
|
-
let S =
|
|
880
|
+
else if (n === y.role.name) {
|
|
881
|
+
let S = h.filter(
|
|
882
882
|
(_) => _.role.name === n
|
|
883
883
|
);
|
|
884
884
|
S.length === 1 ? (l = S[0].role.name, f = S[0].organization.title) : r(S);
|
|
@@ -988,17 +988,17 @@ function ae(e, t, n = void 0, s = void 0, i = void 0) {
|
|
|
988
988
|
const p = u.dataelements.fileName, f = u.dataelements.ticketURL;
|
|
989
989
|
m(f, {
|
|
990
990
|
onComplete: (l, g) => {
|
|
991
|
-
let
|
|
991
|
+
let h;
|
|
992
992
|
try {
|
|
993
|
-
|
|
993
|
+
h = JSON.parse(l);
|
|
994
994
|
} catch {
|
|
995
|
-
|
|
995
|
+
h = l.blob();
|
|
996
996
|
}
|
|
997
997
|
s && s({
|
|
998
998
|
objectId: u.id,
|
|
999
999
|
headers: g,
|
|
1000
1000
|
fileName: p,
|
|
1001
|
-
data:
|
|
1001
|
+
data: h
|
|
1002
1002
|
});
|
|
1003
1003
|
},
|
|
1004
1004
|
onFailure: (l) => {
|
|
@@ -1460,8 +1460,8 @@ function tt(e, t, n = void 0, s = void 0) {
|
|
|
1460
1460
|
e,
|
|
1461
1461
|
o,
|
|
1462
1462
|
(g) => {
|
|
1463
|
-
const
|
|
1464
|
-
l.name =
|
|
1463
|
+
const h = g.data[0].dataelements.title, y = g.data[0].dataelements.fileExtension !== void 0 ? g.data[0].dataelements.fileExtension : "", S = g.data[0].relateddata.ownerInfo[0].dataelements.name;
|
|
1464
|
+
l.name = h, l.ext = y, l.createBy = S, t.info = { ...l }, ue(
|
|
1465
1465
|
e,
|
|
1466
1466
|
t,
|
|
1467
1467
|
(_) => {
|
|
@@ -1472,9 +1472,9 @@ function tt(e, t, n = void 0, s = void 0) {
|
|
|
1472
1472
|
}
|
|
1473
1473
|
);
|
|
1474
1474
|
},
|
|
1475
|
-
(g,
|
|
1476
|
-
const
|
|
1477
|
-
|
|
1475
|
+
(g, h) => {
|
|
1476
|
+
const y = g;
|
|
1477
|
+
y.msg = h.errormsg, y.errCode = h.errorcode, console.log("❌ sendDirectMessage => ", y), s && s(y);
|
|
1478
1478
|
}
|
|
1479
1479
|
);
|
|
1480
1480
|
}, 2e3);
|
|
@@ -1628,7 +1628,7 @@ function st(e, t = "", n = void 0, s = void 0) {
|
|
|
1628
1628
|
});
|
|
1629
1629
|
}
|
|
1630
1630
|
async function w(e, t = void 0, n = void 0) {
|
|
1631
|
-
const s = e.
|
|
1631
|
+
const s = e._3DSwym + "/api/index/tk";
|
|
1632
1632
|
return m(s, {
|
|
1633
1633
|
onComplete(i, r, o) {
|
|
1634
1634
|
const a = JSON.parse(i);
|
|
@@ -1641,7 +1641,7 @@ async function w(e, t = void 0, n = void 0) {
|
|
|
1641
1641
|
});
|
|
1642
1642
|
}
|
|
1643
1643
|
function it(e, t = void 0, n = void 0) {
|
|
1644
|
-
const s = `${e.
|
|
1644
|
+
const s = `${e._3DSwym}/api/exalead/whatsnew`, i = {
|
|
1645
1645
|
params: {
|
|
1646
1646
|
community_id: null,
|
|
1647
1647
|
hash_key: null,
|
|
@@ -1671,7 +1671,7 @@ function it(e, t = void 0, n = void 0) {
|
|
|
1671
1671
|
});
|
|
1672
1672
|
}
|
|
1673
1673
|
function at(e, t = void 0, n = void 0) {
|
|
1674
|
-
const s = `${e.
|
|
1674
|
+
const s = `${e._3DSwym}/api/Recommendation/getpeoplefamiliartocurrentuser`, i = {
|
|
1675
1675
|
params: {
|
|
1676
1676
|
idsToFilterArr: [],
|
|
1677
1677
|
mode: "offline",
|
|
@@ -1702,7 +1702,7 @@ function at(e, t = void 0, n = void 0) {
|
|
|
1702
1702
|
}
|
|
1703
1703
|
function ot(e, t = void 0, n = void 0) {
|
|
1704
1704
|
const s = {
|
|
1705
|
-
base: e.
|
|
1705
|
+
base: e._3DSwym,
|
|
1706
1706
|
uri: "/api/community/listmycommunities",
|
|
1707
1707
|
limit: `/limit/${e.limit ? e.limit : 500}`,
|
|
1708
1708
|
page: `/page/${e.page ? e.page : "1"}`
|
|
@@ -1728,10 +1728,10 @@ function ot(e, t = void 0, n = void 0) {
|
|
|
1728
1728
|
pe(
|
|
1729
1729
|
e,
|
|
1730
1730
|
l.id,
|
|
1731
|
-
(
|
|
1732
|
-
f++, g.members =
|
|
1731
|
+
(h) => {
|
|
1732
|
+
f++, g.members = h, r.push(g), f === p.length && t && t(r);
|
|
1733
1733
|
},
|
|
1734
|
-
(
|
|
1734
|
+
(h) => n(h)
|
|
1735
1735
|
);
|
|
1736
1736
|
});
|
|
1737
1737
|
},
|
|
@@ -1743,7 +1743,7 @@ function ot(e, t = void 0, n = void 0) {
|
|
|
1743
1743
|
});
|
|
1744
1744
|
}
|
|
1745
1745
|
function pe(e, t, n, s) {
|
|
1746
|
-
const i = `${e.
|
|
1746
|
+
const i = `${e._3DSwym}/api/community/listmembers`, r = {
|
|
1747
1747
|
params: {
|
|
1748
1748
|
page: e.page ? e.page : 1,
|
|
1749
1749
|
limit: e.limit ? e.limit : 50,
|
|
@@ -1773,7 +1773,7 @@ function pe(e, t, n, s) {
|
|
|
1773
1773
|
function rt(e, t = void 0, n = void 0) {
|
|
1774
1774
|
const s = "YXdA5x4DSUKtlAi2wmnyTA";
|
|
1775
1775
|
e.commu_id || (e.commu_id = s);
|
|
1776
|
-
const i = `${e.
|
|
1776
|
+
const i = `${e._3DSwym}/api/v2/communities/${e.commu_id}/ideas/statuses`;
|
|
1777
1777
|
w(e, (r) => {
|
|
1778
1778
|
m(i, {
|
|
1779
1779
|
method: "GET",
|
|
@@ -1794,50 +1794,50 @@ function rt(e, t = void 0, n = void 0) {
|
|
|
1794
1794
|
});
|
|
1795
1795
|
}
|
|
1796
1796
|
function ct(e, t, n = void 0, s = void 0) {
|
|
1797
|
-
const { listAllContacts: i, currentUser: r } = e;
|
|
1797
|
+
const { listAllContacts: i, currentUser: r, _3DSwym: o } = e;
|
|
1798
1798
|
console.log("__listAllContacts", i.hits);
|
|
1799
|
-
const
|
|
1799
|
+
const a = `${o}/api/directmessages`, c = {
|
|
1800
1800
|
users: [r.login].concat(t.receipt)
|
|
1801
|
-
},
|
|
1801
|
+
}, d = {
|
|
1802
1802
|
id_msg: "",
|
|
1803
1803
|
senderId: e.currentUser.login,
|
|
1804
1804
|
senderName: `${e.currentUser.first_name} ${e.currentUser.last_name}`,
|
|
1805
1805
|
msg: fe(t.msg)
|
|
1806
1806
|
};
|
|
1807
|
-
let
|
|
1807
|
+
let u = !1;
|
|
1808
1808
|
le(
|
|
1809
|
-
|
|
1810
|
-
(
|
|
1811
|
-
|
|
1809
|
+
c.users,
|
|
1810
|
+
(p) => {
|
|
1811
|
+
p !== void 0 && (d.id_msg = p.id, u = !0, j(e, d));
|
|
1812
1812
|
},
|
|
1813
|
-
(
|
|
1814
|
-
|
|
1813
|
+
(p) => {
|
|
1814
|
+
u = !1, console.log("_3dSwym_findCommunityToInstantMSG callback", p), s && s(p), d.id_msg = "";
|
|
1815
1815
|
}
|
|
1816
|
-
),
|
|
1817
|
-
|
|
1818
|
-
m(
|
|
1816
|
+
), u === !1 && setTimeout(() => {
|
|
1817
|
+
u === !1 && w(e, (p) => {
|
|
1818
|
+
m(a, {
|
|
1819
1819
|
method: "POST",
|
|
1820
1820
|
headers: {
|
|
1821
1821
|
"Content-Type": "application/json",
|
|
1822
1822
|
Accept: "application/json",
|
|
1823
|
-
"X-DS-SWYM-CSRFTOKEN":
|
|
1823
|
+
"X-DS-SWYM-CSRFTOKEN": p.result.ServerToken
|
|
1824
1824
|
},
|
|
1825
|
-
data: JSON.stringify(
|
|
1825
|
+
data: JSON.stringify(c),
|
|
1826
1826
|
type: "json",
|
|
1827
|
-
onComplete(
|
|
1828
|
-
const
|
|
1829
|
-
|
|
1827
|
+
onComplete(f, l, g) {
|
|
1828
|
+
const h = f;
|
|
1829
|
+
h.reponse = JSON.parse(g.response), h.status = g.status, n && n(h), d.id_msg = h.result.id, j(e, d);
|
|
1830
1830
|
},
|
|
1831
|
-
onFailure(
|
|
1832
|
-
const
|
|
1833
|
-
|
|
1831
|
+
onFailure(f, l, g) {
|
|
1832
|
+
const h = f;
|
|
1833
|
+
h.msg = l.errormsg, h.status = l.status, s && s(h);
|
|
1834
1834
|
}
|
|
1835
1835
|
});
|
|
1836
1836
|
});
|
|
1837
1837
|
}, 500);
|
|
1838
1838
|
}
|
|
1839
1839
|
function le(e, t, n, s) {
|
|
1840
|
-
const i = `${e.
|
|
1840
|
+
const i = `${e._3DSwym}/api/directmessages/lite?with_favorites=false`;
|
|
1841
1841
|
w(e, (r) => {
|
|
1842
1842
|
m(i, {
|
|
1843
1843
|
method: "GET",
|
|
@@ -1867,7 +1867,7 @@ function le(e, t, n, s) {
|
|
|
1867
1867
|
}
|
|
1868
1868
|
function j(e, t, n = void 0, s = void 0) {
|
|
1869
1869
|
const i = {
|
|
1870
|
-
base: e.
|
|
1870
|
+
base: e._3DSwym,
|
|
1871
1871
|
uri: "/api/community",
|
|
1872
1872
|
id_msg: `${t.id_msg}`,
|
|
1873
1873
|
endUri: "/instantmessages"
|
|
@@ -2116,7 +2116,7 @@ function ft(e, t, n) {
|
|
|
2116
2116
|
});
|
|
2117
2117
|
}
|
|
2118
2118
|
function mt(e, t, n = void 0, s = void 0) {
|
|
2119
|
-
const {
|
|
2119
|
+
const { _3DSwym: i } = e;
|
|
2120
2120
|
let { community_id: r, limit: o, page: a, search: c } = t;
|
|
2121
2121
|
const d = [], u = 1;
|
|
2122
2122
|
let p = !1, f = 2;
|
|
@@ -2128,12 +2128,12 @@ function mt(e, t, n = void 0, s = void 0) {
|
|
|
2128
2128
|
page: `/page/${a}`
|
|
2129
2129
|
};
|
|
2130
2130
|
let g = `${i}${l.uri}${l.comId}${l.limit}${l.page}`;
|
|
2131
|
-
w(e, (
|
|
2132
|
-
const
|
|
2131
|
+
w(e, (h) => {
|
|
2132
|
+
const y = (S) => {
|
|
2133
2133
|
m(S, {
|
|
2134
2134
|
method: "GET",
|
|
2135
2135
|
headers: {
|
|
2136
|
-
"X-DS-SWYM-CSRFTOKEN":
|
|
2136
|
+
"X-DS-SWYM-CSRFTOKEN": h.result.ServerToken
|
|
2137
2137
|
},
|
|
2138
2138
|
onComplete(_) {
|
|
2139
2139
|
const C = { response: JSON.parse(_) };
|
|
@@ -2153,7 +2153,7 @@ function mt(e, t, n = void 0, s = void 0) {
|
|
|
2153
2153
|
p = !0, n(d);
|
|
2154
2154
|
return;
|
|
2155
2155
|
}
|
|
2156
|
-
|
|
2156
|
+
y(S);
|
|
2157
2157
|
}
|
|
2158
2158
|
},
|
|
2159
2159
|
onFailure(_, C) {
|
|
@@ -2162,7 +2162,7 @@ function mt(e, t, n = void 0, s = void 0) {
|
|
|
2162
2162
|
}
|
|
2163
2163
|
});
|
|
2164
2164
|
};
|
|
2165
|
-
p ||
|
|
2165
|
+
p || y(g);
|
|
2166
2166
|
});
|
|
2167
2167
|
}
|
|
2168
2168
|
function me(e) {
|
|
@@ -2241,7 +2241,7 @@ function me(e) {
|
|
|
2241
2241
|
</p>` : e;
|
|
2242
2242
|
}
|
|
2243
2243
|
function gt(e, t = void 0, n = void 0) {
|
|
2244
|
-
const s = e.
|
|
2244
|
+
const s = e._3DSwym + "/api/user/getcurrent/";
|
|
2245
2245
|
w(e, (i) => {
|
|
2246
2246
|
m(s, {
|
|
2247
2247
|
method: "GET",
|