@beam3_dev/api_module 0.0.272 → 0.0.274
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 +30 -30
- package/dist/wb3Api.js.map +1 -1
- package/dist/wb3Api.umd.cjs +1 -1
- package/dist/wb3Api.umd.cjs.map +1 -1
- package/package.json +1 -1
package/dist/wb3Api.umd.cjs
CHANGED
|
@@ -75,7 +75,7 @@ function Je(e,t=void 0,s=void 0){const n={base:`${e.space}`,uri:"/resources/bps/
|
|
|
75
75
|
<tr><td><strong>Service études de prix</strong></td><td><br /></td></tr>
|
|
76
76
|
</tbody></table>
|
|
77
77
|
<p>
|
|
78
|
-
</p>`:e}function pt(e,t=void 0,s=void 0){const{tenant:n,_3DSwym:i,_3DSwym_token:r,community_id:o,idea_id:a}=e;if(n&&i&&r&&o&&a){const c=`${i}/api/idea/forward`;_(c,{method:"POST",headers:{"Content-type":"application/json;charset=UTF-8",Accept:"application/json","X-DS-SWYM-CSRFTOKEN":r},data:JSON.stringify({community_uri:`swym:prd:${n.toUpperCase()}:community:${o}`,content_uri:`swym:prd:${n.toUpperCase()}:idea:${a}`,timeout:3e4}),type:"json",onComplete(d){t&&t(d)},onFailure(d,u){const p=d;p.status=u.status,p.response=u.errormsg,s&&s(p)}})}else s&&s({status:"error",msg:"Credentials incomplet !",attend:"tenant, _3DSwym , _3DSwym_token, community_id, idea_id",credentials:e})}function ft(e,t=void 0,s=void 0){return new Promise((n,i)=>{try{let r;if(e._3DDashboard){const o=e._3DDashboard+"/api/users/current";console.log("_3DSwym_get_currentUser | url",o),_(o,{method:"GET",onComplete(a,c,d){let u={};const p=String(a).
|
|
78
|
+
</p>`:e}function pt(e,t=void 0,s=void 0){const{tenant:n,_3DSwym:i,_3DSwym_token:r,community_id:o,idea_id:a}=e;if(n&&i&&r&&o&&a){const c=`${i}/api/idea/forward`;_(c,{method:"POST",headers:{"Content-type":"application/json;charset=UTF-8",Accept:"application/json","X-DS-SWYM-CSRFTOKEN":r},data:JSON.stringify({community_uri:`swym:prd:${n.toUpperCase()}:community:${o}`,content_uri:`swym:prd:${n.toUpperCase()}:idea:${a}`,timeout:3e4}),type:"json",onComplete(d){t&&t(d)},onFailure(d,u){const p=d;p.status=u.status,p.response=u.errormsg,s&&s(p)}})}else s&&s({status:"error",msg:"Credentials incomplet !",attend:"tenant, _3DSwym , _3DSwym_token, community_id, idea_id",credentials:e})}function ft(e,t=void 0,s=void 0){return new Promise((n,i)=>{try{let r;if(e._3DDashboard){const o=e._3DDashboard+"/api/users/current";console.log("_3DSwym_get_currentUser | url",o),_(o,{method:"GET",onComplete(a,c,d){let u={};const p=new String(a);console.log("oResult",p),Object.keys(p).forEach(m=>{p[m]==="firstName"&&(u.first_name=p.firstName)}),u.first_name=u.firstName,u.last_name=u.lastName,console.log("_3DSwym_get_currentUser | info",u),r=u,n(u)},onFailure(a){i("ERROR | _3DSwym_get_currentUser => _3DDashboard + /api/users/current",a)}})}r?n(r):i("ERROR | _3DSwym_get_currentUser => CURRENT_USER is null")}catch(r){i("ERROR | _3DSwym_get_currentUser => ",r)}})}function mt(e,t,s=void 0,n=void 0){const i=e.space+"/api/user/find/login/"+t;T(e,r=>{_(i,{method:"GET",headers:{"X-DS-SWYM-CSRFTOKEN":r.result.ServerToken},onComplete(o,a,c){const d=JSON.parse(o);s&&s(d)},onFailure(o){n&&n(o)}})},n)}function _t(e,t=void 0,s=void 0){const{_3DSwym:n,_3DSwym_token:i,subjectUri:r,richMessage:o}=e,a=`${n}/commentproxy/subjects/${r}/comments`,d={method:"POST",headers:{"Content-type":"application/json;charset=UTF-8",Accept:"application/json","X-DS-SWYM-CSRFTOKEN":i},data:JSON.stringify({richMessage:o}),type:"json",onComplete(u,p,m){const f={response:typeof u=="string"?JSON.parse(u):u};f.status=m.status,t&&t(f)},onFailure(u){s&&s(u)}};_(a,d)}function gt(e,t=void 0,s=void 0){e.tenant&&A(e,n=>{const i=n.services.find(r=>r.id==="businessprocess")?.url+"/api/v2";return t&&t(i),i})}function ht(e,t=void 0,s=void 0){e.tenant&&A(e,n=>{const i=n.services.find(a=>a.id==="3dpassport")?.url,r=n.services.find(a=>a.id==="businessprocess")?.url+"/api/v2",o=`${i}/login/?service=${r}/auth/cas`;_(o,{async onComplete(a){const c=typeof a=="string"?JSON.parse(a)?.x3ds_service_redirect_url:a?.x3ds_service_redirect_url;await fetch(c,{method:"POST"}).then(d=>d.json()).then(async d=>{t&&t(d?.token)})},onFailure(a){s&&s(a)}})})}function St(e,t=void 0,s=void 0){if(e.tenant){const n=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${n}/iterop/jwtuser`,{method:"POST"}).then(i=>i.json()).then(i=>{t&&t(i)}).catch(i=>{s&&s(i)})}}async function yt(e,t,s=void 0,n=void 0){if(e.tenant){const i=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${i}/iterop/repository/data/tables?t=${t}`,{method:"GET"}).then(r=>r.json()).then(r=>{s&&s(r)}).catch(r=>{n&&n(r)})}}async function wt(e,t,s,n=void 0,i=void 0){if(e.tenant){const r=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${r}/iterop/businesstable/one/${s}?t=${t}`,{method:"POST"}).then(o=>o.json()).then(o=>{n&&n(o)}).catch(o=>{i&&i(o)})}}async function Tt(e,t,s,n=void 0,i=void 0){if(e.tenant){const r=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${r}/iterop/businesstable/rows/${s}/?t=${t}`,{method:"POST"}).then(o=>o.json()).then(o=>{n&&n(o)}).catch(o=>{i&&i(o)})}}async function Ct(e,t,s,n,i=void 0,r=void 0){if(e.tenant){const o=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${o}/iterop/businesstable/patch/rows/${s}/?t=${t}&b=${n}`,{method:"POST"}).then(a=>a.json()).then(a=>{i&&i(a)}).catch(a=>{r&&r(a,s,n)})}}async function bt(e,t,s,n,i,r=void 0,o=void 0){if(e.tenant){const a=`https://api.uixhome.fr/${e.tenant.toLowerCase()}/iterop/businesstable/search/rows/${s}?t=${t}&c=${encodeURIComponent(n)}&b=${encodeURIComponent(i)}`;fetch(a,{method:"POST"}).then(c=>c.json()).then(c=>{c.url=a,r&&r(c)}).catch(c=>{o&&o({error:c,tableId:s,columns:n,body:i})})}}async function Ot(e,t,s,n,i=void 0,r=void 0){if(e.tenant){const o=`https://api.uixhome.fr/${e.tenant.toLowerCase()}/iterop/businesstable/post/update/${s}?t=${t}&b=${encodeURIComponent(n)}`;fetch(o,{method:"POST"}).then(a=>a.json()).then(a=>{i&&i(a)}).catch(a=>{r&&r({error:a,url:o})})}}async function Dt(e,t,s,n=void 0,i=void 0){if(e.tenant){const r=`https://api.uixhome.fr/${e.tenant.toLowerCase()}/iterop/businesstable/post/create/?t=${t}&b=${encodeURIComponent(s)}`;fetch(r,{method:"POST"}).then(o=>o.json()).then(o=>{n&&n(o)}).catch(o=>{i&&i({error:o,url:r})})}}async function $t(e,t,s,n,i=void 0,r=void 0){if(e.tenant){const o=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${o}/iterop/runtime/processes/${s}?t=${t}&b=${n}`,{method:"POST"}).then(a=>a.json()).then(a=>{console.log("_Iterop_runProcess : OK"),i&&i(a)}).catch(a=>{r&&r(a)})}}async function It(e,t,s,n=void 0,i=void 0){if(console.log("_Iterop_GetOneDependencyTable | Run"),e.tenant){const r=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${r}/iterop/dependencytable/one/${s}/?t=${t}`,{method:"POST"}).then(o=>o.json()).then(o=>{n&&n(o)}).catch(o=>{i&&i(o)})}}async function Nt(e,t,s,n,i,r=void 0,o=void 0){if(e.tenant){const a=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${a}/iterop/dependencytable/patch/${s}/?t=${t}&cli=${n}&b=${i}`,{method:"POST"}).then(c=>c.json()).then(c=>{r&&r(c)}).catch(c=>{o&&o(c)})}}async function Ut(e,t,s,n,i=void 0,r=void 0){if(e.tenant){const o=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${o}/iterop/dependencytable/put/${s}/?t=${t}&b=${n}`,{method:"POST"}).then(a=>a.json()).then(a=>{i&&i(a)}).catch(a=>{r&&r(a)})}}//!SECTION
|
|
79
79
|
async function Rt(e,t,s,n=void 0,i=void 0){if(e.tenant){const r=e.tenant.toLowerCase();fetch(`https://api.uixhome.fr/${r}/iterop/list/one/${s}/?t=${t}`,{method:"POST"}).then(o=>o.json()).then(o=>{n&&n(o)}).catch(o=>{i&&i(o)})}}//!SECTION
|
|
80
80
|
function Ft(e){const t="Hello "+e;return console.log(t),t}function kt(e,t=void 0,s=void 0){return console.log("credentials",e),new Promise(n=>{if(e.token===""&&O(e),!e.space||e.space===""){const o=E();console.log("platformeInfo",o)}F(e,"Common space",["VPLMProjectLeader","VPLMCreator"],void 0,o=>e.ctx=o,o=>{console.log("onError =>",o)},!0);const i=$.DateTime.now().ts,r=`https://${e.tenant}-eu1-registry.3dexperience.3ds.com/api/v1/platform/service/instance?serviceId=3dsearch&platformId=${e.tenant}`;_(r,{onComplete(o){if(Array.isArray(JSON.parse(o))){const a=JSON.parse(o);console.log("serviceId=3dsearch",a);const c=`${a[0].services[0].url}/search?xrequestedwith=xmlhttprequest`;_(c,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},data:JSON.stringify({with_indexing_date:!0,with_nls:!1,label:`3DSearch-${i}`,locale:"en",select_predicate:["ds6w:label","ds6w:type","ds6w:description","ds6w:identifier","ds6w:responsible","ds6wg:fullname"],select_file:["icon","thumbnail_2d"],query:'([ds6w:type]:(Group) AND [ds6w:status]:(Public)) OR (flattenedtaxonomies:"types/Person" AND current:"active")',order_by:"desc",order_field:"relevance",nresults:1e3,start:"0",source:["3dspace","usersgroup"],tenant:e.tenant,login:{"3dspace":{SecurityContext:`ctx::${e.ctx}`}}}),type:"json",onComplete(d){t&&t(d)},onFailure(d){s&&s(d)}})}},onFailure(o){s&&s(o)}})})}l.UUID=J,l._3DSearch_usersGroup=kt,l._3DSpace_Create_Doc=Ne,l._3DSpace_Update_Doc=Ie,l._3DSpace_bookmark_addSubsciptions=Me,l._3DSpace_bookmark_newWorkspace=Le,l._3DSpace_csrf=O,l._3DSpace_download_doc=L,l._3DSpace_download_multidoc=W,l._3DSpace_file_update=P,l._3DSpace_file_update_csr=q,l._3DSpace_file_url_csr=De,l._3DSpace_get_csrf=R,l._3DSpace_get_docInfo=v,l._3DSpace_get_downloadTicket_multidoc=X,l._3DSpace_get_multiDocInfo=Oe,l._3DSpace_get_securityContexts=F,l._3DSpace_get_ticket=k,l._3DSpace_lifecycle_changeRevision=Pe,l._3DSpace_lifecycle_changeState=Ae,l._3DSpace_lifecycle_getGraph=je,l._3DSpace_lifecycle_getNextRevision=ve,l._3DSpace_lifecycle_getNextStates=ke,l._3DSpace_put_docInfo=$e,l._3DSwym_ForwardIdea=pt,l._3DSwym_addComment=_t,l._3DSwym_buildDirectMessage=st,l._3DSwym_deleteIdea=rt,l._3DSwym_editIdea=dt,l._3DSwym_findCommunityToInstantMSG=ee,l._3DSwym_getAllCommunities=tt,l._3DSwym_getAllListIdeas=ut,l._3DSwym_getAllNews=Ze,l._3DSwym_getFamiliarPeople=et,l._3DSwym_getIdeaStatusMaturity=nt,l._3DSwym_getMembersCommunity=Z,l._3DSwym_getOneIdea=ct,l._3DSwym_get_Token=T,l._3DSwym_get_currentUser=ft,l._3DSwym_get_findUser=mt,l._3DSwym_postIdea=ot,l._3DSwym_postIdeaTemplate=at,l._3DSwym_sendMessageData=M,l._AppMngt_get_info_user=fe,l._AppMngt_get_users=pe,l._Iterop_AddOrRemoveRows=Ct,l._Iterop_Auth_CAS=ht,l._Iterop_GetOneDependencyTable=It,l._Iterop_GetOneList=Rt,l._Iterop_PatchDependencyTable=Nt,l._Iterop_PutDependencyTable=Ut,l._Iterop_businessTableSearchInRows=bt,l._Iterop_createBusinessTable=Dt,l._Iterop_getAllBusinessTables=yt,l._Iterop_getOneBusinessTable=wt,l._Iterop_getOneBusinessTableRows=Tt,l._Iterop_jwtUser=St,l._Iterop_runProcess=$t,l._Iterop_updateBusinessTable=Ot,l._getPlateformInfos=E,l._getPlatformServices=de,l._getServiceUrl=A,l._getServiceUrl_3DPassport=ue,l._getServiceUrl_Iterop=gt,l._httpCallAuthenticated=_,l._setDraggable=oe,l._setDroppable=ce,l._setupTagger=re,l.addTagToDoc=Ye,l.chunkArray=x,l.compass_getListAdditionalApps=le,l.couleurs=G,l.createUserGroups=me,l.dataMixing=z,l.deleteUserGroups=he,l.findAdresse=ne,l.getAllContextSecurity=Je,l.getCSRFToken=K,l.getCommunes=te,l.getComplementUG=_e,l.getDataFrom3DSpace=Ge,l.getDataFromGouvFr=se,l.getDatasByTenant=Ke,l.getDatasFrom3DSpace=qe,l.getDownloadDocument=xe,l.getInfoDocTags=Qe,l.getUserGroupsList=ge,l.getUsersGroupRules=B,l.get_3DSpace_csrf=Be,l.patchUserGroups=Se,l.patchUserGroupsControl=ye,l.pushDataIn3DSpace=Ee,l.readUserGroupControl=we,l.removeTagToDoc=ze,l.sayHello=Ft,l.updateEvent=ae,Object.defineProperty(l,Symbol.toStringTag,{value:"Module"})});
|
|
81
81
|
//# sourceMappingURL=wb3Api.umd.cjs.map
|