Built files from Bizgaze WebServer
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

accountmanager.min.js 11KB

1
  1. var __awaiter=this&&this.__awaiter||function(n,t,i,r){function u(n){return n instanceof i?n:new i(function(t){t(n)})}return new(i||(i=Promise))(function(i,f){function o(n){try{e(r.next(n))}catch(t){f(t)}}function s(n){try{e(r["throw"](n))}catch(t){f(t)}}function e(n){n.done?i(n.value):u(n.value).then(o,s)}e((r=r.apply(n,t||[])).next())})},Unibase;(function(n){let t;(function(t){let i;(function(i){let r;(function(r){class u extends t.Core.BaseManager{validateLogin(n){return __awaiter(this,void 0,void 0,function*(){const t=_appsettings.authentication_url()+"account/login";return yield this.dataHelper().postAsync(t,n).then(function(n){return n})})}changePassword(){var n=i.Infos.Identity.getCurrentUser();n.userId}getIdentity(){i.Infos.Identity.setCurrentUser(null)}getIndustries(){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().getAsync("account/getindustries").then(function(n){return n}).fail(function(){})})}anonymousLogin(){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/anonymouslogin",null).then(function(n){return n})})}parentanonymouslogin(){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/parentanonymouslogin",null).then(function(n){return n})})}getUser(n,t){return __awaiter(this,void 0,void 0,function*(){const i="account/getuserbyphoneormail/"+n+"/"+t;return yield this.dataHelper().getAsync(i).then(function(n){return n}).fail(function(){})})}sendOtp(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/sendotp",n).then(function(n){return n}).fail(function(){})})}verifyOtp(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/verifyotp",n).then(function(n){return n}).fail(function(){})})}signUp_Old(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/registertenant",n).then(function(n){return n}).fail(function(){})})}signUp(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/AllocateEmptyTenantAsync",n).then(function(n){return n}).fail(function(){})})}getTenants(){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().getAsync("account/gettenants").then(function(n){return n}).fail(function(){})})}getUserTenants(n){return __awaiter(this,void 0,void 0,function*(){const t="account/gettenants/"+n;return yield this.dataHelper().getAsync(t).then(function(n){return n}).fail(function(){})})}registerUser(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/registeruser",n).then(function(n){return n}).fail(function(){})})}getContact(n,t){return __awaiter(this,void 0,void 0,function*(){const i="account/getcontactbyphoneormail/"+n+"/"+t;return yield this.dataHelper().getAsync(i).then(function(n){return n}).fail(function(){})})}updatePassword(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/updatepassword",n).then(function(n){return n}).fail(function(){})})}getfollowerbyfollowid(n,t){return __awaiter(this,void 0,void 0,function*(){const i="apis/v4/unibase/platform/followers/getfollowerbyfollowid/userid/"+n+"/followid/"+t;return yield this.dataHelper().getAsync(i).then(function(n){return n.result!==null&&n.result!==""&&(n.result=JSON.parse(n.result)),n}).fail(function(){})})}getfollowermanagers(n){return __awaiter(this,void 0,void 0,function*(){const t="apis/v4/unibase/platform/followers/getmanagerfollowersbyuserid/userid/"+n;return yield this.dataHelper().getAsync(t).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n}).fail(function(){})})}deleteManagerFollower(n,t){return __awaiter(this,void 0,void 0,function*(){const i="apis/v4/unibase/platform/followers/deletemanagerfollower/managerfollowerid/"+n+"/contactid/"+t;return yield this.dataHelper().postAsync(i,null).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n})})}savemanager(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("apis/v4/unibase/platform/followers/savemanager",n).then(function(n){return n.result!=null&&(n.result=JSON.parse(n.result)),n})})}deleteFollower(n,t){return __awaiter(this,void 0,void 0,function*(){const i="apis/v4/unibase/platform/followers/deletefollower/followerid/"+n+"/contactid/"+t;return yield this.dataHelper().postAsync(i,null).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n})})}savefollower(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("apis/v4/unibase/platform/followers/savefollower",n).then(function(n){return n.result!=null&&(n.result=JSON.parse(n.result)),n})})}lobs(n){return __awaiter(this,void 0,void 0,function*(){const t="account/getlobs/"+n+"";return yield this.dataHelper().getAsync(t).then(function(n){return n}).fail(function(){})})}getchildtags(n){return __awaiter(this,void 0,void 0,function*(){const t="account/getchildtags/"+n+"";return yield this.dataHelper().getAsync(t).then(function(n){return n}).fail(function(){})})}registercontact(n,t,i,r,u,f,e){return __awaiter(this,void 0,void 0,function*(){const o="account/registercontact/"+n+"/"+t+"/"+i+"/"+r+"/"+u+"/"+f+"/"+e+"";return yield this.dataHelper().getAsync(o).then(function(n){return n}).fail(function(){})})}childlobs(n,t){return __awaiter(this,void 0,void 0,function*(){const i="account/getchildlobs/"+n+"/"+t;return yield this.dataHelper().getAsync(i).then(function(n){return n}).fail(function(){})})}registercmnUser(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/register",n).then(function(n){return n}).fail(function(){})})}register(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("account/contactregister",n).then(function(n){return n}).fail(function(){})})}userLogin(n){return __awaiter(this,void 0,void 0,function*(){const t="Account/UserLogin/UserName/"+n;return yield this.dataHelper().postAsync(t,null).then(function(n){return n})})}userLogoff(n){return __awaiter(this,void 0,void 0,function*(){const t="Account/UserLogOff/Session/"+n;return yield this.dataHelper().postAsync(t,null).then(function(n){return n})})}deleteUserDevices(n){return __awaiter(this,void 0,void 0,function*(){const t="apis/v4/unibase/platform/common/deleteuserdevices/unibaseid/"+n;return yield this.dataHelper().postAsync(t,null).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n})})}updateUserDeviceStatus(n,t){return __awaiter(this,void 0,void 0,function*(){const i="apis/v4/unibase/platform/common/updateuserdevicestatus/deviceuniqueid/"+n+"/status/"+t;return yield this.dataHelper().postAsync(i,null).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n})})}generatesession(n){return __awaiter(this,void 0,void 0,function*(){const t="Account/GenerateSession/Token/"+n;return yield this.dataHelper().postAsync(t,null).then(function(n){return n})})}generatesessionbytenantid(n,t){return __awaiter(this,void 0,void 0,function*(){const i="Account/GenerateSession/Token/"+n+"/tid/"+t;return yield this.dataHelper().getAsync(i).then(function(n){return n})})}setTenantAsDefault(n,t){return __awaiter(this,void 0,void 0,function*(){const i="Account/SetTenantAsDefault/TenantId/"+n+"/UserName/"+t;return yield this.dataHelper().postAsync(i,null).then(function(n){return n})})}savesupportusers(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("Account/SaveSupportUser",n).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n}).fail(function(){})})}GetSupportUserSession(n){return __awaiter(this,void 0,void 0,function*(){const t="Account/GetSupportUserSession/SessionId/"+n;return yield this.dataHelper().getAsync(t).then(function(n){return n})})}getuserbyuserid(n){return __awaiter(this,void 0,void 0,function*(){const t="Account/GetUser/"+n;return yield this.dataHelper().getAsync(t).then(function(n){return n}).fail(function(){})})}getdomainloadjs(){return __awaiter(this,void 0,void 0,function*(){const n=_appsettings.authentication_url()+"Account/Domain";return yield this.dataHelper().getAsync(n).then(function(n){return n}).fail(function(){})})}getSharedTenants(){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().getAsync("Account/Tenants/GetSharedTenants").then(function(n){return n}).fail(function(){})})}switchtosecondary(t){return __awaiter(this,void 0,void 0,function*(){const i="Account/SwitchtoSecondary/Enable/"+t;return yield this.dataHelper().getAsync(i).then(function(t){t.result!==null&&(n.Platform.Membership.Infos.Identity.setCurrentUser(t.result),window.location.reload())}).fail(function(){})})}switchtotenant(t){return __awaiter(this,void 0,void 0,function*(){const i="Account/SwitchtoTenant/"+t;return yield this.dataHelper().getAsync(i).then(function(t){t.result!==null&&(n.Platform.Membership.Infos.Identity.setCurrentUser(t.result),window.location.reload())}).fail(function(){})})}getconnectedtenant(n,t){return __awaiter(this,void 0,void 0,function*(){const i="account/gettenant/"+n+"/"+t;return yield this.dataHelper().getAsync(i).then(function(n){return n}).fail(function(){})})}IsValidSession(){return __awaiter(this,void 0,void 0,function*(){const n=_appsettings.authentication_url()+"account/session/validate";return yield this.dataHelper().getAsync(n).then(function(n){return n}).fail(function(){})})}MapUser(n,t){return __awaiter(this,void 0,void 0,function*(){const i="apis/v4/bizgaze/crm/organization/usermaping/orgcontactid/"+n+"/assaignedtenantid/"+t;return yield this.dataHelper().getAsync(i).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n})})}updateUserDetails(n){return __awaiter(this,void 0,void 0,function*(){return yield this.dataHelper().postAsync("apis/v4/unibase/platform/membership/updateuserdetails",n).then(function(n){return n.result!=null&&(n.result=JSON.parse(n.result)),n})})}ChangeUsersLockStatus(n,t){return __awaiter(this,void 0,void 0,function*(){const i="account/Status/"+n+"/TenantId/"+t+"/ChangeUsersLockStatus";return yield this.dataHelper().postAsync(i,null).then(function(n){return n})})}ValidateUsersLockStatus(n){return __awaiter(this,void 0,void 0,function*(){const t="account/ValidateUsersLockStatus/TenantId/"+n;return yield this.dataHelper().postAsync(t,null).then(function(n){return n})})}getTenantUserByUserId(n){return __awaiter(this,void 0,void 0,function*(){const t="apis/v4/unibase/platform/users/getuserbyuserid/"+n;return yield this.dataHelper().getAsync(t).then(function(n){return n.result!==null&&(n.result=JSON.parse(n.result)),n})})}static Instance(){return new u}}r.AccountManager=u})(r=i.Managers||(i.Managers={}))})(i=t.Membership||(t.Membership={}))})(t=n.Platform||(n.Platform={}))})(Unibase||(Unibase={}));