shared-ritm 1.2.75 → 1.2.76

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.
@@ -15805,7 +15805,7 @@ class y3 extends or {
15805
15805
  return await this.post("/check_branch_before_close_task", n);
15806
15806
  }
15807
15807
  }
15808
- let el;
15808
+ let el = null;
15809
15809
  function VA() {
15810
15810
  return el || (el = new y3()), el;
15811
15811
  }
@@ -4,7 +4,7 @@
4
4
  `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(g){return g instanceof this?g:new this(g)}static concat(g,...B){const Q=new this(g);return B.forEach(w=>Q.set(w)),Q}static accessor(g){const Q=(this[cM]=this[cM]={accessors:{}}).accessors,w=this.prototype;function C(E){const e=lC(E);Q[e]||(Sl(w,E),Q[e]=!0)}return q.isArray(g)?g.forEach(C):C(g),this}};Yg.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),q.reduceDescriptors(Yg.prototype,({value:A},g)=>{let B=g[0].toUpperCase()+g.slice(1);return{get:()=>A,set(Q){this[B]=Q}}}),q.freezeMethods(Yg);function Do(A,g){const B=this||hC,Q=g||B,w=Yg.from(Q.headers);let C=Q.data;return q.forEach(A,function(e){C=e.call(B,C,w.normalize(),g?g.status:void 0)}),w.normalize(),C}function DM(A){return!!(A&&A.__CANCEL__)}function vw(A,g,B){LA.call(this,A??"canceled",LA.ERR_CANCELED,g,B),this.name="CanceledError"}q.inherits(vw,LA,{__CANCEL__:!0});function rM(A,g,B){const Q=B.config.validateStatus;!B.status||!Q||Q(B.status)?A(B):g(new LA("Request failed with status code "+B.status,[LA.ERR_BAD_REQUEST,LA.ERR_BAD_RESPONSE][Math.floor(B.status/100)-4],B.config,B.request,B))}function Ll(A){const g=/^([-+\w]{1,25})(:?\/\/|:)/.exec(A);return g&&g[1]||""}function bl(A,g){A=A||10;const B=new Array(A),Q=new Array(A);let w=0,C=0,E;return g=g!==void 0?g:1e3,function(I){const o=Date.now(),n=Q[C];E||(E=o),B[w]=I,Q[w]=o;let i=C,Y=0;for(;i!==w;)Y+=B[i++],i=i%A;if(w=(w+1)%A,w===C&&(C=(C+1)%A),o-E<g)return;const M=n&&o-n;return M?Math.round(Y*1e3/M):void 0}}function Kl(A,g){let B=0,Q=1e3/g,w,C;const E=(o,n=Date.now())=>{B=n,w=null,C&&(clearTimeout(C),C=null),A.apply(null,o)};return[(...o)=>{const n=Date.now(),i=n-B;i>=Q?E(o,n):(w=o,C||(C=setTimeout(()=>{C=null,E(w)},Q-i)))},()=>w&&E(w)]}const WE=(A,g,B=3)=>{let Q=0;const w=bl(50,250);return Kl(C=>{const E=C.loaded,e=C.lengthComputable?C.total:void 0,I=E-Q,o=w(I),n=E<=e;Q=E;const i={loaded:E,total:e,progress:e?E/e:void 0,bytes:I,rate:o||void 0,estimated:o&&e&&n?(e-E)/o:void 0,event:C,lengthComputable:e!=null,[g?"download":"upload"]:!0};A(i)},B)},FM=(A,g)=>{const B=A!=null;return[Q=>g[0]({lengthComputable:B,total:A,loaded:Q}),g[1]]},aM=A=>(...g)=>q.asap(()=>A(...g)),Vl=Bg.hasStandardBrowserEnv?((A,g)=>B=>(B=new URL(B,Bg.origin),A.protocol===B.protocol&&A.host===B.host&&(g||A.port===B.port)))(new URL(Bg.origin),Bg.navigator&&/(msie|trident)/i.test(Bg.navigator.userAgent)):()=>!0,xl=Bg.hasStandardBrowserEnv?{write(A,g,B,Q,w,C){const E=[A+"="+encodeURIComponent(g)];q.isNumber(B)&&E.push("expires="+new Date(B).toGMTString()),q.isString(Q)&&E.push("path="+Q),q.isString(w)&&E.push("domain="+w),C===!0&&E.push("secure"),document.cookie=E.join("; ")},read(A){const g=document.cookie.match(new RegExp("(^|;\\s*)("+A+")=([^;]*)"));return g?decodeURIComponent(g[3]):null},remove(A){this.write(A,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function Xl(A){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(A)}function Ol(A,g){return g?A.replace(/\/?\/$/,"")+"/"+g.replace(/^\/+/,""):A}function sM(A,g,B){let Q=!Xl(g);return A&&(Q||B==!1)?Ol(A,g):g}const uM=A=>A instanceof Yg?{...A}:A;function _Q(A,g){g=g||{};const B={};function Q(o,n,i,Y){return q.isPlainObject(o)&&q.isPlainObject(n)?q.merge.call({caseless:Y},o,n):q.isPlainObject(n)?q.merge({},n):q.isArray(n)?n.slice():n}function w(o,n,i,Y){if(q.isUndefined(n)){if(!q.isUndefined(o))return Q(void 0,o,i,Y)}else return Q(o,n,i,Y)}function C(o,n){if(!q.isUndefined(n))return Q(void 0,n)}function E(o,n){if(q.isUndefined(n)){if(!q.isUndefined(o))return Q(void 0,o)}else return Q(void 0,n)}function e(o,n,i){if(i in g)return Q(o,n);if(i in A)return Q(void 0,o)}const I={url:C,method:C,data:C,baseURL:E,transformRequest:E,transformResponse:E,paramsSerializer:E,timeout:E,timeoutMessage:E,withCredentials:E,withXSRFToken:E,adapter:E,responseType:E,xsrfCookieName:E,xsrfHeaderName:E,onUploadProgress:E,onDownloadProgress:E,decompress:E,maxContentLength:E,maxBodyLength:E,beforeRedirect:E,transport:E,httpAgent:E,httpsAgent:E,cancelToken:E,socketPath:E,responseEncoding:E,validateStatus:e,headers:(o,n,i)=>w(uM(o),uM(n),i,!0)};return q.forEach(Object.keys(Object.assign({},A,g)),function(n){const i=I[n]||w,Y=i(A[n],g[n],n);q.isUndefined(Y)&&i!==e||(B[n]=Y)}),B}const UM=A=>{const g=_Q({},A);let{data:B,withXSRFToken:Q,xsrfHeaderName:w,xsrfCookieName:C,headers:E,auth:e}=g;g.headers=E=Yg.from(E),g.url=nM(sM(g.baseURL,g.url,g.allowAbsoluteUrls),A.params,A.paramsSerializer),e&&E.set("Authorization","Basic "+btoa((e.username||"")+":"+(e.password?unescape(encodeURIComponent(e.password)):"")));let I;if(q.isFormData(B)){if(Bg.hasStandardBrowserEnv||Bg.hasStandardBrowserWebWorkerEnv)E.setContentType(void 0);else if((I=E.getContentType())!==!1){const[o,...n]=I?I.split(";").map(i=>i.trim()).filter(Boolean):[];E.setContentType([o||"multipart/form-data",...n].join("; "))}}if(Bg.hasStandardBrowserEnv&&(Q&&q.isFunction(Q)&&(Q=Q(g)),Q||Q!==!1&&Vl(g.url))){const o=w&&C&&xl.read(C);o&&E.set(w,o)}return g},Zl=typeof XMLHttpRequest<"u"&&function(A){return new Promise(function(B,Q){const w=UM(A);let C=w.data;const E=Yg.from(w.headers).normalize();let{responseType:e,onUploadProgress:I,onDownloadProgress:o}=w,n,i,Y,M,c;function D(){M&&M(),c&&c(),w.cancelToken&&w.cancelToken.unsubscribe(n),w.signal&&w.signal.removeEventListener("abort",n)}let r=new XMLHttpRequest;r.open(w.method.toUpperCase(),w.url,!0),r.timeout=w.timeout;function F(){if(!r)return;const u=Yg.from("getAllResponseHeaders"in r&&r.getAllResponseHeaders()),U={data:!e||e==="text"||e==="json"?r.responseText:r.response,status:r.status,statusText:r.statusText,headers:u,config:A,request:r};rM(function(d){B(d),D()},function(d){Q(d),D()},U),r=null}"onloadend"in r?r.onloadend=F:r.onreadystatechange=function(){!r||r.readyState!==4||r.status===0&&!(r.responseURL&&r.responseURL.indexOf("file:")===0)||setTimeout(F)},r.onabort=function(){r&&(Q(new LA("Request aborted",LA.ECONNABORTED,A,r)),r=null)},r.onerror=function(){Q(new LA("Network Error",LA.ERR_NETWORK,A,r)),r=null},r.ontimeout=function(){let a=w.timeout?"timeout of "+w.timeout+"ms exceeded":"timeout exceeded";const U=w.transitional||YM;w.timeoutErrorMessage&&(a=w.timeoutErrorMessage),Q(new LA(a,U.clarifyTimeoutError?LA.ETIMEDOUT:LA.ECONNABORTED,A,r)),r=null},C===void 0&&E.setContentType(null),"setRequestHeader"in r&&q.forEach(E.toJSON(),function(a,U){r.setRequestHeader(U,a)}),q.isUndefined(w.withCredentials)||(r.withCredentials=!!w.withCredentials),e&&e!=="json"&&(r.responseType=w.responseType),o&&([Y,c]=WE(o,!0),r.addEventListener("progress",Y)),I&&r.upload&&([i,M]=WE(I),r.upload.addEventListener("progress",i),r.upload.addEventListener("loadend",M)),(w.cancelToken||w.signal)&&(n=u=>{r&&(Q(!u||u.type?new vw(null,A,r):u),r.abort(),r=null)},w.cancelToken&&w.cancelToken.subscribe(n),w.signal&&(w.signal.aborted?n():w.signal.addEventListener("abort",n)));const s=Ll(w.url);if(s&&Bg.protocols.indexOf(s)===-1){Q(new LA("Unsupported protocol "+s+":",LA.ERR_BAD_REQUEST,A));return}r.send(C||null)})},ql=(A,g)=>{const{length:B}=A=A?A.filter(Boolean):[];if(g||B){let Q=new AbortController,w;const C=function(o){if(!w){w=!0,e();const n=o instanceof Error?o:this.reason;Q.abort(n instanceof LA?n:new vw(n instanceof Error?n.message:n))}};let E=g&&setTimeout(()=>{E=null,C(new LA(`timeout ${g} of ms exceeded`,LA.ETIMEDOUT))},g);const e=()=>{A&&(E&&clearTimeout(E),E=null,A.forEach(o=>{o.unsubscribe?o.unsubscribe(C):o.removeEventListener("abort",C)}),A=null)};A.forEach(o=>o.addEventListener("abort",C));const{signal:I}=Q;return I.unsubscribe=()=>q.asap(e),I}},_l=function*(A,g){let B=A.byteLength;if(B<g){yield A;return}let Q=0,w;for(;Q<B;)w=Q+g,yield A.slice(Q,w),Q=w},$l=async function*(A,g){for await(const B of Ad(A))yield*_l(B,g)},Ad=async function*(A){if(A[Symbol.asyncIterator]){yield*A;return}const g=A.getReader();try{for(;;){const{done:B,value:Q}=await g.read();if(B)break;yield Q}}finally{await g.cancel()}},GM=(A,g,B,Q)=>{const w=$l(A,g);let C=0,E,e=I=>{E||(E=!0,Q&&Q(I))};return new ReadableStream({async pull(I){try{const{done:o,value:n}=await w.next();if(o){e(),I.close();return}let i=n.byteLength;if(B){let Y=C+=i;B(Y)}I.enqueue(new Uint8Array(n))}catch(o){throw e(o),o}},cancel(I){return e(I),w.return()}},{highWaterMark:2})},SE=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",hM=SE&&typeof ReadableStream=="function",Bd=SE&&(typeof TextEncoder=="function"?(A=>g=>A.encode(g))(new TextEncoder):async A=>new Uint8Array(await new Response(A).arrayBuffer())),lM=(A,...g)=>{try{return!!A(...g)}catch{return!1}},gd=hM&&lM(()=>{let A=!1;const g=new Request(Bg.origin,{body:new ReadableStream,method:"POST",get duplex(){return A=!0,"half"}}).headers.has("Content-Type");return A&&!g}),dM=64*1024,ro=hM&&lM(()=>q.isReadableStream(new Response("").body)),LE={stream:ro&&(A=>A.body)};SE&&(A=>{["text","arrayBuffer","blob","formData","stream"].forEach(g=>{!LE[g]&&(LE[g]=q.isFunction(A[g])?B=>B[g]():(B,Q)=>{throw new LA(`Response type '${g}' is not supported`,LA.ERR_NOT_SUPPORT,Q)})})})(new Response);const Qd=async A=>{if(A==null)return 0;if(q.isBlob(A))return A.size;if(q.isSpecCompliantForm(A))return(await new Request(Bg.origin,{method:"POST",body:A}).arrayBuffer()).byteLength;if(q.isArrayBufferView(A)||q.isArrayBuffer(A))return A.byteLength;if(q.isURLSearchParams(A)&&(A=A+""),q.isString(A))return(await Bd(A)).byteLength},wd=async(A,g)=>{const B=q.toFiniteNumber(A.getContentLength());return B??Qd(g)},Fo={http:ll,xhr:Zl,fetch:SE&&(async A=>{let{url:g,method:B,data:Q,signal:w,cancelToken:C,timeout:E,onDownloadProgress:e,onUploadProgress:I,responseType:o,headers:n,withCredentials:i="same-origin",fetchOptions:Y}=UM(A);o=o?(o+"").toLowerCase():"text";let M=ql([w,C&&C.toAbortSignal()],E),c;const D=M&&M.unsubscribe&&(()=>{M.unsubscribe()});let r;try{if(I&&gd&&B!=="get"&&B!=="head"&&(r=await wd(n,Q))!==0){let U=new Request(g,{method:"POST",body:Q,duplex:"half"}),G;if(q.isFormData(Q)&&(G=U.headers.get("content-type"))&&n.setContentType(G),U.body){const[d,H]=FM(r,WE(aM(I)));Q=GM(U.body,dM,d,H)}}q.isString(i)||(i=i?"include":"omit");const F="credentials"in Request.prototype;c=new Request(g,{...Y,signal:M,method:B.toUpperCase(),headers:n.normalize().toJSON(),body:Q,duplex:"half",credentials:F?i:void 0});let s=await fetch(c);const u=ro&&(o==="stream"||o==="response");if(ro&&(e||u&&D)){const U={};["status","statusText","headers"].forEach(h=>{U[h]=s[h]});const G=q.toFiniteNumber(s.headers.get("content-length")),[d,H]=e&&FM(G,WE(aM(e),!0))||[];s=new Response(GM(s.body,dM,d,()=>{H&&H(),D&&D()}),U)}o=o||"text";let a=await LE[q.findKey(LE,o)||"text"](s,A);return!u&&D&&D(),await new Promise((U,G)=>{rM(U,G,{data:a,headers:Yg.from(s.headers),status:s.status,statusText:s.statusText,config:A,request:c})})}catch(F){throw D&&D(),F&&F.name==="TypeError"&&/Load failed|fetch/i.test(F.message)?Object.assign(new LA("Network Error",LA.ERR_NETWORK,A,c),{cause:F.cause||F}):LA.from(F,F&&F.code,A,c)}})};q.forEach(Fo,(A,g)=>{if(A){try{Object.defineProperty(A,"name",{value:g})}catch{}Object.defineProperty(A,"adapterName",{value:g})}});const HM=A=>`- ${A}`,Cd=A=>q.isFunction(A)||A===null||A===!1,fM={getAdapter:A=>{A=q.isArray(A)?A:[A];const{length:g}=A;let B,Q;const w={};for(let C=0;C<g;C++){B=A[C];let E;if(Q=B,!Cd(B)&&(Q=Fo[(E=String(B)).toLowerCase()],Q===void 0))throw new LA(`Unknown adapter '${E}'`);if(Q)break;w[E||"#"+C]=Q}if(!Q){const C=Object.entries(w).map(([e,I])=>`adapter ${e} `+(I===!1?"is not supported by the environment":"is not available in the build"));let E=g?C.length>1?`since :
5
5
  `+C.map(HM).join(`
6
6
  `):" "+HM(C[0]):"as no adapter specified";throw new LA("There is no suitable adapter to dispatch the request "+E,"ERR_NOT_SUPPORT")}return Q},adapters:Fo};function ao(A){if(A.cancelToken&&A.cancelToken.throwIfRequested(),A.signal&&A.signal.aborted)throw new vw(null,A)}function JM(A){return ao(A),A.headers=Yg.from(A.headers),A.data=Do.call(A,A.transformRequest),["post","put","patch"].indexOf(A.method)!==-1&&A.headers.setContentType("application/x-www-form-urlencoded",!1),fM.getAdapter(A.adapter||hC.adapter)(A).then(function(Q){return ao(A),Q.data=Do.call(A,A.transformResponse,Q),Q.headers=Yg.from(Q.headers),Q},function(Q){return DM(Q)||(ao(A),Q&&Q.response&&(Q.response.data=Do.call(A,A.transformResponse,Q.response),Q.response.headers=Yg.from(Q.response.headers))),Promise.reject(Q)})}const NM="1.9.0",bE={};["object","boolean","number","function","string","symbol"].forEach((A,g)=>{bE[A]=function(Q){return typeof Q===A||"a"+(g<1?"n ":" ")+A}});const mM={};bE.transitional=function(g,B,Q){function w(C,E){return"[Axios v"+NM+"] Transitional option '"+C+"'"+E+(Q?". "+Q:"")}return(C,E,e)=>{if(g===!1)throw new LA(w(E," has been removed"+(B?" in "+B:"")),LA.ERR_DEPRECATED);return B&&!mM[E]&&(mM[E]=!0,console.warn(w(E," has been deprecated since v"+B+" and will be removed in the near future"))),g?g(C,E,e):!0}},bE.spelling=function(g){return(B,Q)=>(console.warn(`${Q} is likely a misspelling of ${g}`),!0)};function Ed(A,g,B){if(typeof A!="object")throw new LA("options must be an object",LA.ERR_BAD_OPTION_VALUE);const Q=Object.keys(A);let w=Q.length;for(;w-- >0;){const C=Q[w],E=g[C];if(E){const e=A[C],I=e===void 0||E(e,C,A);if(I!==!0)throw new LA("option "+C+" must be "+I,LA.ERR_BAD_OPTION_VALUE);continue}if(B!==!0)throw new LA("Unknown option "+C,LA.ERR_BAD_OPTION)}}const KE={assertOptions:Ed,validators:bE},xg=KE.validators;let $Q=class{constructor(g){this.defaults=g||{},this.interceptors={request:new iM,response:new iM}}async request(g,B){try{return await this._request(g,B)}catch(Q){if(Q instanceof Error){let w={};Error.captureStackTrace?Error.captureStackTrace(w):w=new Error;const C=w.stack?w.stack.replace(/^.+\n/,""):"";try{Q.stack?C&&!String(Q.stack).endsWith(C.replace(/^.+\n.+\n/,""))&&(Q.stack+=`
7
- `+C):Q.stack=C}catch{}}throw Q}}_request(g,B){typeof g=="string"?(B=B||{},B.url=g):B=g||{},B=_Q(this.defaults,B);const{transitional:Q,paramsSerializer:w,headers:C}=B;Q!==void 0&&KE.assertOptions(Q,{silentJSONParsing:xg.transitional(xg.boolean),forcedJSONParsing:xg.transitional(xg.boolean),clarifyTimeoutError:xg.transitional(xg.boolean)},!1),w!=null&&(q.isFunction(w)?B.paramsSerializer={serialize:w}:KE.assertOptions(w,{encode:xg.function,serialize:xg.function},!0)),B.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?B.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:B.allowAbsoluteUrls=!0),KE.assertOptions(B,{baseUrl:xg.spelling("baseURL"),withXsrfToken:xg.spelling("withXSRFToken")},!0),B.method=(B.method||this.defaults.method||"get").toLowerCase();let E=C&&q.merge(C.common,C[B.method]);C&&q.forEach(["delete","get","head","post","put","patch","common"],c=>{delete C[c]}),B.headers=Yg.concat(E,C);const e=[];let I=!0;this.interceptors.request.forEach(function(D){typeof D.runWhen=="function"&&D.runWhen(B)===!1||(I=I&&D.synchronous,e.unshift(D.fulfilled,D.rejected))});const o=[];this.interceptors.response.forEach(function(D){o.push(D.fulfilled,D.rejected)});let n,i=0,Y;if(!I){const c=[JM.bind(this),void 0];for(c.unshift.apply(c,e),c.push.apply(c,o),Y=c.length,n=Promise.resolve(B);i<Y;)n=n.then(c[i++],c[i++]);return n}Y=e.length;let M=B;for(i=0;i<Y;){const c=e[i++],D=e[i++];try{M=c(M)}catch(r){D.call(this,r);break}}try{n=JM.call(this,M)}catch(c){return Promise.reject(c)}for(i=0,Y=o.length;i<Y;)n=n.then(o[i++],o[i++]);return n}getUri(g){g=_Q(this.defaults,g);const B=sM(g.baseURL,g.url,g.allowAbsoluteUrls);return nM(B,g.params,g.paramsSerializer)}};q.forEach(["delete","get","head","options"],function(g){$Q.prototype[g]=function(B,Q){return this.request(_Q(Q||{},{method:g,url:B,data:(Q||{}).data}))}}),q.forEach(["post","put","patch"],function(g){function B(Q){return function(C,E,e){return this.request(_Q(e||{},{method:g,headers:Q?{"Content-Type":"multipart/form-data"}:{},url:C,data:E}))}}$Q.prototype[g]=B(),$Q.prototype[g+"Form"]=B(!0)});let ed=class wF{constructor(g){if(typeof g!="function")throw new TypeError("executor must be a function.");let B;this.promise=new Promise(function(C){B=C});const Q=this;this.promise.then(w=>{if(!Q._listeners)return;let C=Q._listeners.length;for(;C-- >0;)Q._listeners[C](w);Q._listeners=null}),this.promise.then=w=>{let C;const E=new Promise(e=>{Q.subscribe(e),C=e}).then(w);return E.cancel=function(){Q.unsubscribe(C)},E},g(function(C,E,e){Q.reason||(Q.reason=new vw(C,E,e),B(Q.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(g){if(this.reason){g(this.reason);return}this._listeners?this._listeners.push(g):this._listeners=[g]}unsubscribe(g){if(!this._listeners)return;const B=this._listeners.indexOf(g);B!==-1&&this._listeners.splice(B,1)}toAbortSignal(){const g=new AbortController,B=Q=>{g.abort(Q)};return this.subscribe(B),g.signal.unsubscribe=()=>this.unsubscribe(B),g.signal}static source(){let g;return{token:new wF(function(w){g=w}),cancel:g}}};function Id(A){return function(B){return A.apply(null,B)}}function od(A){return q.isObject(A)&&A.isAxiosError===!0}const so={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(so).forEach(([A,g])=>{so[g]=A});function RM(A){const g=new $Q(A),B=ZY($Q.prototype.request,g);return q.extend(B,$Q.prototype,g,{allOwnKeys:!0}),q.extend(B,g,null,{allOwnKeys:!0}),B.create=function(w){return RM(_Q(A,w))},B}const fB=RM(hC);fB.Axios=$Q,fB.CanceledError=vw,fB.CancelToken=ed,fB.isCancel=DM,fB.VERSION=NM,fB.toFormData=yE,fB.AxiosError=LA,fB.Cancel=fB.CanceledError,fB.all=function(g){return Promise.all(g)},fB.spread=Id,fB.isAxiosError=od,fB.mergeConfig=_Q,fB.AxiosHeaders=Yg,fB.formToJSON=A=>MM(q.isHTMLForm(A)?new FormData(A):A),fB.getAdapter=fM.getAdapter,fB.HttpStatusCode=so,fB.default=fB;const{Axios:T4,AxiosError:j4,CanceledError:p4,isCancel:y4,CancelToken:z4,VERSION:W4,all:S4,Cancel:L4,isAxiosError:b4,spread:K4,toFormData:V4,AxiosHeaders:x4,HttpStatusCode:X4,formToJSON:O4,getAdapter:Z4,mergeConfig:q4}=fB;class Gg{constructor(){QF(this,"axiosInstance");this.axiosInstance=fB.create({baseURL:process.env.VUE_APP_BACKEND,headers:{"Content-Type":"application/json",Accept:"application/json"}}),this.axiosInstance.interceptors.request.use(g=>{const B=this.getToken();return B&&g.headers&&(g.headers.Authorization=`Bearer ${B}`),g},g=>Promise.reject(g)),this.axiosInstance.interceptors.response.use(g=>g.data,g=>{var B,Q;return(((B=g.response)==null?void 0:B.status)===401||((Q=g.response)==null?void 0:Q.status)===403)&&this.logout(),Promise.reject(g)})}getToken(){return localStorage.getItem("token")}removeToken(){localStorage.removeItem("token")}logout(){this.removeToken(),window.location.href="/sign-in"}handleError(g){g.response?console.error("API Error:",g.response.status,g.response.data):g.request?console.error("No response received:",g.request):console.error("Error during request setup:",g.message)}async get(g,B){try{const Q=await this.axiosInstance.get(g,B);return(Q==null?void 0:Q.data)===!1?!1:(Q==null?void 0:Q.data)??Q}catch(Q){const w=Q;throw this.handleError(w),Q}}async delete(g,B){try{return await this.axiosInstance.delete(g,B)}catch(Q){const w=Q;throw this.handleError(w),Q}}async post(g,B,Q){try{const w=await this.axiosInstance.post(g,B,Q);return(w==null?void 0:w.data)===!1?!1:(w==null?void 0:w.data)||w}catch(w){const C=w;throw this.handleError(C),w}}async put(g,B,Q){try{return(await this.axiosInstance.put(g,B,Q)).data}catch(w){const C=w;throw this.handleError(C),w}}}class td extends Gg{async fetchCriticalPathTasks(g){return await this.get(`gantt/get_list_task_on_critical_path?${g}`)}async fetchGanttList(g){return await this.get(`/list/tasks/search?${g}&gantt=1`)}}let uo;function nd(){return uo||(uo=new td),uo}class id extends Gg{async fetchPieProjects(g){return await this.get("repairs/pie/projects?"+g)}async fetchPieTasks(g){return await this.get("repairs/pie/tasks?"+g)}async fetchPiePersonnel(g){return await this.get("repairs/metrics/get_list_position?"+g)}async fetchPersonnelData(g){return await this.get("repairs/metrics/list_position_intersection_group_by_status?"+g)}async fetchPersonnelInfo(g){return await this.get(`repairs/metrics/list_position_intersection_details?${g}`)}async fetchPiePersonnelInfo(g){return await this.get(`repairs/metrics/get_list_user_by_position?${g}`)}async fetchPieCriticalPath(g){return await this.get("repairs/metrics/get_critical_path_group_by_status?"+g)}async fetchPieCriticalPathInfo(g){return await this.get(`repairs/metrics/get_list_task_critical_path_by_status?${g}`)}async fetchPieTmc(g){return await this.get("repairs/metrics/get_list_instrument_type?"+g)}async fetchPieTmcInfo(g){return await this.get(`repairs/metrics/get_list_warehouse_by_instrument_type?${g}`)}async fetchPieUntimelyClosedTask(g){return await this.get("repairs/metrics/get_list_comment_type?"+g)}async fetchPieUntimelyClosedTaskInfo(g){return await this.get(`repairs/metrics/get_list_task_by_comment_type?${g}`)}async fetchPieAdditionalTasks(g){return await this.get("repairs/metrics/get_list_task_after_plan_fixate_group_by_status?"+g)}async fetchPieAdditionalTasksInfo(g){return await this.get(`repairs/metrics/get_list_task_after_plan_fixate_by_status?${g}`)}async fetchPersonnel(g){return await this.get("repairs/statistic/personnel?"+g)}async fetchPieExpired(g){return await this.get("repairs/metrics/get_list_task_expired_group_by_status?"+g)}async fetchPieExpiredInfo(g){return await this.get(`repairs/metrics/get_list_task_expired?${g}`)}async fetchEconomicsPerformance(g){return await this.get(`repairs/metrics/get_economic_performance?${g}`)}async fetchEconomicsInfo(g){return await this.get(`repairs/metrics/get_list_task_economic_performance?${g}`)}async fetchQualityMetrics(g){return await this.get(`repairs/metrics/get_quality_metrics?${g}`)}async fetchQualityInfo(g){return await this.get(`repairs/metrics/get_list_task_by_quality?${g}`)}async fetchPieWorkZone(g){return await this.get("repairs/metrics/get_list_work_zone_instrument?"+g)}async fetchWorkZoneInfo(g){return await this.get("repairs/metrics/get_list_work_zone_instrument_by_status?"+g)}async fetchPieAllTasks(g){return await this.get("repairs/metrics/get_list_task_group_by_status?"+g)}async fetchPieAllTasksInfo(g){return await this.get("repairs/metrics/get_list_task_by_status?"+g)}}let Uo;function Yd(){return Uo||(Uo=new id),Uo}class Md extends Gg{async fetchProjectById(g){return this.get(`/projects/${g}`)}createProject(g){return this.post("/projects",g)}editProject(g,B){return this.put(`/projects/${g}`,B)}fetchProjects(g){return this.get("/search/projects",{params:g})}cloneProject(g){return this.post(`projects/${g.id}/clone`,g)}archiveProject(g,B){return this.put(`/projects/${g}`,B)}unArchiveProject(g,B){return this.put(`/projects/${g}`,B)}moveAprProject(g){return this.post("repairs/move_plan_to_real",{repairs:[g]})}restoreProject(g){return this.post("/restore_project",{projects_ids:[g]})}importTasks(g){return this.post("tasks/import",g)}importKtd(g){return this.post("/parse_ktd",g,{headers:{"Content-Type":"multipart/form-data"}})}fetchProjectTeamList(g){return this.put(`/projects/${g}`,null)}deleteProject(g){return this.delete(`/projects/${g}`)}}let Go;function cd(){return Go||(Go=new Md),Go}class Dd extends Gg{fetchFilters(g){return this.get(`get_list_repair?smart=1&${g}`)}fetchRepairs(g,B,Q,w,C){return this.get("get_list_repair"+(g?`${B}&per_page=100000${C?"&"+C:""}&${Q?"":w}`:`?per_page=100000${C?"&"+C:""}&${w}`))}fetchRepairTemplates({equipmentId:g,categoryCode:B}){return this.get(`repairs/get_repair_template_list?per_page=100000&categoryCodeList[0]=${B}&equipmentIdList[0]=${g}`)}fetchEquipment(){return this.get("repairs/equipment/list?per_page=100000")}createRepair(g){return this.post("/repairs/equipments",g)}createRepairFromTemplate(g){return this.post("/repairs/create_repair_from_repair_template",g)}startRepair(g){return this.post(`/repairs/${g}/start`,null)}finishRepair(g){return this.post("/repairs/complete_repair_list",{repairIdList:[g]})}finishPreparationProject(g){return this.post(`/repairs/${g}/finish_preparation`,null)}moveRepairToCurrent(g){return this.post("/repairs/transfer_repair_plan_to_current",{repairs:[g]})}moveArchiveToCurrent(g){return this.post("/repairs/transfer_repair_archive_to_current",{repairs_ids:[g]})}moveRepairToApr(g){return this.post("/repairs/transfer_repair_current_to_plan",{repairs:[g]})}moveRepairToArchive(g){return this.post("/repairs/transfer_repair_current_to_archive",{repairs_ids:[g]})}restoreRepair(g){return this.post("/restore_repair",{repairs_ids:[g]})}updateRepair(g,B){return this.put(`/repairs/${B}`,g)}copyRepair(g){return this.post(`/repairs/${g}/clone`,null)}deleteRepair(g){return this.delete(`/repairs/${g}`)}}let ho;function rd(){return ho||(ho=new Dd),ho}class Fd extends Gg{async fetchTaskById(g){return await this.get(`/tasks/${g}`)}async fetchTasksList(g){return await this.get("/list/tasks/search",{params:g})}async fetchSubtasksList(g){return await this.get(`/task/${g}/subtasks/list`)}async fetchTaskBranch(g){return await this.get(`/get_list_task_branch?task_id=${g}`)}async fetchInstrumentsList(g){return await this.get("admin/instruments",{params:g})}async fetchInstrumentTypeListWithPreparedWarehouse(g){return await this.get("/instrument_type/get_instrument_type_list_with_prepared_warehouse",{params:g})}async fetchInstrumentsEquivalentList(g){return await this.get("tasks/instrument/list",{params:g})}async fetchDiffInstruments(g){return await this.get(`tasks/${g.taskId}/fill/module`,{params:g})}async replaceInstruments(g){return await this.post("/instruments/equivalent/attach",g)}async fetchTaskUsagePersonal(g){return await this.get(`tasks/${g.taskId}/usage/users`,{params:g})}async fetchTaskUsageInstrument(g){return await this.get(`tasks/${g.taskId}/usage/instruments`,{params:g})}fetchEquipment(g){return this.get("repairs/equipment/list",{params:g})}fetchTaskVideoSources(g){return this.get("work_zone/get_list_video_source",{params:g})}fetchTaskVideoSourcesStream(g){return this.get("horizon/video-source",{params:g})}createWorkZone(g){return this.post("admin/work-zones",g)}async createTask(g){return await this.post("tasks",g)}async editTask(g){return await this.put(`tasks/${g.taskId}`,g.data)}async mergeTask(g){return await this.post("tasks/merge",g)}async deleteTask(g){return await this.delete(`tasks/${g}`)}async changeStatus(g){const{taskId:B,data:Q}=g;return await this.put(`task/${B}/change-status`,Q)}async uploadComment(g){return await this.post("comments",g)}async deleteComment(g){return await this.delete(`comments/${g}`)}async editComment(g){const{commentId:B,data:Q}=g;return await this.put(`comments/${B}`,Q)}async saveMetrics(g){return await this.put("/update_quality_metrics",g)}async checkReasonForStatus(g){return await this.post("/tasks/check_reason_for_task",g)}async verifyTaskStatus(g){const{task_id:B,data:Q}=g;return await this.get(`/task/${B}/change-status/verification`,{params:Q})}async checkBranchBeforeCloseTask(g){return await this.post("/check_branch_before_close_task",g)}}let lo;function ad(){return lo||(lo=new Fd),lo}class sd extends Gg{login(g,B){return this.post("/login",{email:g,password:B})}loginPhoto(g){return this.post("/login/from_photo",{photo:g})}logout(){return this.post("/logout",null)}userInfo(){return this.get("/users/auth")}configs(){return this.get("/configs")}changePassword(g,B,Q){return this.put(`/users/${g}/password`,{password:B,password_confirmation:Q})}}let Ho;function ud(){return Ho||(Ho=new sd),Ho}class Ud extends Gg{uploadFile(g){return this.post("/upload-file",g,{headers:{"Content-Type":"multipart/form-data"}})}}let fo;function Gd(){return fo||(fo=new Ud),fo}class hd extends Gg{async startVideoAnalytics(){return await this.post("/statanly/start",null)}}let Jo;function ld(){return Jo||(Jo=new hd),Jo}class dd extends Gg{async editUser({id:g,model:B}){return await this.put(`/admin/users/${g}`,B)}async getUser(g){return await this.get(`/admin/users/${g}`)}}let No;function Hd(){return No||(No=new dd),No}/**
7
+ `+C):Q.stack=C}catch{}}throw Q}}_request(g,B){typeof g=="string"?(B=B||{},B.url=g):B=g||{},B=_Q(this.defaults,B);const{transitional:Q,paramsSerializer:w,headers:C}=B;Q!==void 0&&KE.assertOptions(Q,{silentJSONParsing:xg.transitional(xg.boolean),forcedJSONParsing:xg.transitional(xg.boolean),clarifyTimeoutError:xg.transitional(xg.boolean)},!1),w!=null&&(q.isFunction(w)?B.paramsSerializer={serialize:w}:KE.assertOptions(w,{encode:xg.function,serialize:xg.function},!0)),B.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?B.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:B.allowAbsoluteUrls=!0),KE.assertOptions(B,{baseUrl:xg.spelling("baseURL"),withXsrfToken:xg.spelling("withXSRFToken")},!0),B.method=(B.method||this.defaults.method||"get").toLowerCase();let E=C&&q.merge(C.common,C[B.method]);C&&q.forEach(["delete","get","head","post","put","patch","common"],c=>{delete C[c]}),B.headers=Yg.concat(E,C);const e=[];let I=!0;this.interceptors.request.forEach(function(D){typeof D.runWhen=="function"&&D.runWhen(B)===!1||(I=I&&D.synchronous,e.unshift(D.fulfilled,D.rejected))});const o=[];this.interceptors.response.forEach(function(D){o.push(D.fulfilled,D.rejected)});let n,i=0,Y;if(!I){const c=[JM.bind(this),void 0];for(c.unshift.apply(c,e),c.push.apply(c,o),Y=c.length,n=Promise.resolve(B);i<Y;)n=n.then(c[i++],c[i++]);return n}Y=e.length;let M=B;for(i=0;i<Y;){const c=e[i++],D=e[i++];try{M=c(M)}catch(r){D.call(this,r);break}}try{n=JM.call(this,M)}catch(c){return Promise.reject(c)}for(i=0,Y=o.length;i<Y;)n=n.then(o[i++],o[i++]);return n}getUri(g){g=_Q(this.defaults,g);const B=sM(g.baseURL,g.url,g.allowAbsoluteUrls);return nM(B,g.params,g.paramsSerializer)}};q.forEach(["delete","get","head","options"],function(g){$Q.prototype[g]=function(B,Q){return this.request(_Q(Q||{},{method:g,url:B,data:(Q||{}).data}))}}),q.forEach(["post","put","patch"],function(g){function B(Q){return function(C,E,e){return this.request(_Q(e||{},{method:g,headers:Q?{"Content-Type":"multipart/form-data"}:{},url:C,data:E}))}}$Q.prototype[g]=B(),$Q.prototype[g+"Form"]=B(!0)});let ed=class wF{constructor(g){if(typeof g!="function")throw new TypeError("executor must be a function.");let B;this.promise=new Promise(function(C){B=C});const Q=this;this.promise.then(w=>{if(!Q._listeners)return;let C=Q._listeners.length;for(;C-- >0;)Q._listeners[C](w);Q._listeners=null}),this.promise.then=w=>{let C;const E=new Promise(e=>{Q.subscribe(e),C=e}).then(w);return E.cancel=function(){Q.unsubscribe(C)},E},g(function(C,E,e){Q.reason||(Q.reason=new vw(C,E,e),B(Q.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(g){if(this.reason){g(this.reason);return}this._listeners?this._listeners.push(g):this._listeners=[g]}unsubscribe(g){if(!this._listeners)return;const B=this._listeners.indexOf(g);B!==-1&&this._listeners.splice(B,1)}toAbortSignal(){const g=new AbortController,B=Q=>{g.abort(Q)};return this.subscribe(B),g.signal.unsubscribe=()=>this.unsubscribe(B),g.signal}static source(){let g;return{token:new wF(function(w){g=w}),cancel:g}}};function Id(A){return function(B){return A.apply(null,B)}}function od(A){return q.isObject(A)&&A.isAxiosError===!0}const so={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(so).forEach(([A,g])=>{so[g]=A});function RM(A){const g=new $Q(A),B=ZY($Q.prototype.request,g);return q.extend(B,$Q.prototype,g,{allOwnKeys:!0}),q.extend(B,g,null,{allOwnKeys:!0}),B.create=function(w){return RM(_Q(A,w))},B}const fB=RM(hC);fB.Axios=$Q,fB.CanceledError=vw,fB.CancelToken=ed,fB.isCancel=DM,fB.VERSION=NM,fB.toFormData=yE,fB.AxiosError=LA,fB.Cancel=fB.CanceledError,fB.all=function(g){return Promise.all(g)},fB.spread=Id,fB.isAxiosError=od,fB.mergeConfig=_Q,fB.AxiosHeaders=Yg,fB.formToJSON=A=>MM(q.isHTMLForm(A)?new FormData(A):A),fB.getAdapter=fM.getAdapter,fB.HttpStatusCode=so,fB.default=fB;const{Axios:T4,AxiosError:j4,CanceledError:p4,isCancel:y4,CancelToken:z4,VERSION:W4,all:S4,Cancel:L4,isAxiosError:b4,spread:K4,toFormData:V4,AxiosHeaders:x4,HttpStatusCode:X4,formToJSON:O4,getAdapter:Z4,mergeConfig:q4}=fB;class Gg{constructor(){QF(this,"axiosInstance");this.axiosInstance=fB.create({baseURL:process.env.VUE_APP_BACKEND,headers:{"Content-Type":"application/json",Accept:"application/json"}}),this.axiosInstance.interceptors.request.use(g=>{const B=this.getToken();return B&&g.headers&&(g.headers.Authorization=`Bearer ${B}`),g},g=>Promise.reject(g)),this.axiosInstance.interceptors.response.use(g=>g.data,g=>{var B,Q;return(((B=g.response)==null?void 0:B.status)===401||((Q=g.response)==null?void 0:Q.status)===403)&&this.logout(),Promise.reject(g)})}getToken(){return localStorage.getItem("token")}removeToken(){localStorage.removeItem("token")}logout(){this.removeToken(),window.location.href="/sign-in"}handleError(g){g.response?console.error("API Error:",g.response.status,g.response.data):g.request?console.error("No response received:",g.request):console.error("Error during request setup:",g.message)}async get(g,B){try{const Q=await this.axiosInstance.get(g,B);return(Q==null?void 0:Q.data)===!1?!1:(Q==null?void 0:Q.data)??Q}catch(Q){const w=Q;throw this.handleError(w),Q}}async delete(g,B){try{return await this.axiosInstance.delete(g,B)}catch(Q){const w=Q;throw this.handleError(w),Q}}async post(g,B,Q){try{const w=await this.axiosInstance.post(g,B,Q);return(w==null?void 0:w.data)===!1?!1:(w==null?void 0:w.data)||w}catch(w){const C=w;throw this.handleError(C),w}}async put(g,B,Q){try{return(await this.axiosInstance.put(g,B,Q)).data}catch(w){const C=w;throw this.handleError(C),w}}}class td extends Gg{async fetchCriticalPathTasks(g){return await this.get(`gantt/get_list_task_on_critical_path?${g}`)}async fetchGanttList(g){return await this.get(`/list/tasks/search?${g}&gantt=1`)}}let uo;function nd(){return uo||(uo=new td),uo}class id extends Gg{async fetchPieProjects(g){return await this.get("repairs/pie/projects?"+g)}async fetchPieTasks(g){return await this.get("repairs/pie/tasks?"+g)}async fetchPiePersonnel(g){return await this.get("repairs/metrics/get_list_position?"+g)}async fetchPersonnelData(g){return await this.get("repairs/metrics/list_position_intersection_group_by_status?"+g)}async fetchPersonnelInfo(g){return await this.get(`repairs/metrics/list_position_intersection_details?${g}`)}async fetchPiePersonnelInfo(g){return await this.get(`repairs/metrics/get_list_user_by_position?${g}`)}async fetchPieCriticalPath(g){return await this.get("repairs/metrics/get_critical_path_group_by_status?"+g)}async fetchPieCriticalPathInfo(g){return await this.get(`repairs/metrics/get_list_task_critical_path_by_status?${g}`)}async fetchPieTmc(g){return await this.get("repairs/metrics/get_list_instrument_type?"+g)}async fetchPieTmcInfo(g){return await this.get(`repairs/metrics/get_list_warehouse_by_instrument_type?${g}`)}async fetchPieUntimelyClosedTask(g){return await this.get("repairs/metrics/get_list_comment_type?"+g)}async fetchPieUntimelyClosedTaskInfo(g){return await this.get(`repairs/metrics/get_list_task_by_comment_type?${g}`)}async fetchPieAdditionalTasks(g){return await this.get("repairs/metrics/get_list_task_after_plan_fixate_group_by_status?"+g)}async fetchPieAdditionalTasksInfo(g){return await this.get(`repairs/metrics/get_list_task_after_plan_fixate_by_status?${g}`)}async fetchPersonnel(g){return await this.get("repairs/statistic/personnel?"+g)}async fetchPieExpired(g){return await this.get("repairs/metrics/get_list_task_expired_group_by_status?"+g)}async fetchPieExpiredInfo(g){return await this.get(`repairs/metrics/get_list_task_expired?${g}`)}async fetchEconomicsPerformance(g){return await this.get(`repairs/metrics/get_economic_performance?${g}`)}async fetchEconomicsInfo(g){return await this.get(`repairs/metrics/get_list_task_economic_performance?${g}`)}async fetchQualityMetrics(g){return await this.get(`repairs/metrics/get_quality_metrics?${g}`)}async fetchQualityInfo(g){return await this.get(`repairs/metrics/get_list_task_by_quality?${g}`)}async fetchPieWorkZone(g){return await this.get("repairs/metrics/get_list_work_zone_instrument?"+g)}async fetchWorkZoneInfo(g){return await this.get("repairs/metrics/get_list_work_zone_instrument_by_status?"+g)}async fetchPieAllTasks(g){return await this.get("repairs/metrics/get_list_task_group_by_status?"+g)}async fetchPieAllTasksInfo(g){return await this.get("repairs/metrics/get_list_task_by_status?"+g)}}let Uo;function Yd(){return Uo||(Uo=new id),Uo}class Md extends Gg{async fetchProjectById(g){return this.get(`/projects/${g}`)}createProject(g){return this.post("/projects",g)}editProject(g,B){return this.put(`/projects/${g}`,B)}fetchProjects(g){return this.get("/search/projects",{params:g})}cloneProject(g){return this.post(`projects/${g.id}/clone`,g)}archiveProject(g,B){return this.put(`/projects/${g}`,B)}unArchiveProject(g,B){return this.put(`/projects/${g}`,B)}moveAprProject(g){return this.post("repairs/move_plan_to_real",{repairs:[g]})}restoreProject(g){return this.post("/restore_project",{projects_ids:[g]})}importTasks(g){return this.post("tasks/import",g)}importKtd(g){return this.post("/parse_ktd",g,{headers:{"Content-Type":"multipart/form-data"}})}fetchProjectTeamList(g){return this.put(`/projects/${g}`,null)}deleteProject(g){return this.delete(`/projects/${g}`)}}let Go;function cd(){return Go||(Go=new Md),Go}class Dd extends Gg{fetchFilters(g){return this.get(`get_list_repair?smart=1&${g}`)}fetchRepairs(g,B,Q,w,C){return this.get("get_list_repair"+(g?`${B}&per_page=100000${C?"&"+C:""}&${Q?"":w}`:`?per_page=100000${C?"&"+C:""}&${w}`))}fetchRepairTemplates({equipmentId:g,categoryCode:B}){return this.get(`repairs/get_repair_template_list?per_page=100000&categoryCodeList[0]=${B}&equipmentIdList[0]=${g}`)}fetchEquipment(){return this.get("repairs/equipment/list?per_page=100000")}createRepair(g){return this.post("/repairs/equipments",g)}createRepairFromTemplate(g){return this.post("/repairs/create_repair_from_repair_template",g)}startRepair(g){return this.post(`/repairs/${g}/start`,null)}finishRepair(g){return this.post("/repairs/complete_repair_list",{repairIdList:[g]})}finishPreparationProject(g){return this.post(`/repairs/${g}/finish_preparation`,null)}moveRepairToCurrent(g){return this.post("/repairs/transfer_repair_plan_to_current",{repairs:[g]})}moveArchiveToCurrent(g){return this.post("/repairs/transfer_repair_archive_to_current",{repairs_ids:[g]})}moveRepairToApr(g){return this.post("/repairs/transfer_repair_current_to_plan",{repairs:[g]})}moveRepairToArchive(g){return this.post("/repairs/transfer_repair_current_to_archive",{repairs_ids:[g]})}restoreRepair(g){return this.post("/restore_repair",{repairs_ids:[g]})}updateRepair(g,B){return this.put(`/repairs/${B}`,g)}copyRepair(g){return this.post(`/repairs/${g}/clone`,null)}deleteRepair(g){return this.delete(`/repairs/${g}`)}}let ho;function rd(){return ho||(ho=new Dd),ho}class Fd extends Gg{async fetchTaskById(g){return await this.get(`/tasks/${g}`)}async fetchTasksList(g){return await this.get("/list/tasks/search",{params:g})}async fetchSubtasksList(g){return await this.get(`/task/${g}/subtasks/list`)}async fetchTaskBranch(g){return await this.get(`/get_list_task_branch?task_id=${g}`)}async fetchInstrumentsList(g){return await this.get("admin/instruments",{params:g})}async fetchInstrumentTypeListWithPreparedWarehouse(g){return await this.get("/instrument_type/get_instrument_type_list_with_prepared_warehouse",{params:g})}async fetchInstrumentsEquivalentList(g){return await this.get("tasks/instrument/list",{params:g})}async fetchDiffInstruments(g){return await this.get(`tasks/${g.taskId}/fill/module`,{params:g})}async replaceInstruments(g){return await this.post("/instruments/equivalent/attach",g)}async fetchTaskUsagePersonal(g){return await this.get(`tasks/${g.taskId}/usage/users`,{params:g})}async fetchTaskUsageInstrument(g){return await this.get(`tasks/${g.taskId}/usage/instruments`,{params:g})}fetchEquipment(g){return this.get("repairs/equipment/list",{params:g})}fetchTaskVideoSources(g){return this.get("work_zone/get_list_video_source",{params:g})}fetchTaskVideoSourcesStream(g){return this.get("horizon/video-source",{params:g})}createWorkZone(g){return this.post("admin/work-zones",g)}async createTask(g){return await this.post("tasks",g)}async editTask(g){return await this.put(`tasks/${g.taskId}`,g.data)}async mergeTask(g){return await this.post("tasks/merge",g)}async deleteTask(g){return await this.delete(`tasks/${g}`)}async changeStatus(g){const{taskId:B,data:Q}=g;return await this.put(`task/${B}/change-status`,Q)}async uploadComment(g){return await this.post("comments",g)}async deleteComment(g){return await this.delete(`comments/${g}`)}async editComment(g){const{commentId:B,data:Q}=g;return await this.put(`comments/${B}`,Q)}async saveMetrics(g){return await this.put("/update_quality_metrics",g)}async checkReasonForStatus(g){return await this.post("/tasks/check_reason_for_task",g)}async verifyTaskStatus(g){const{task_id:B,data:Q}=g;return await this.get(`/task/${B}/change-status/verification`,{params:Q})}async checkBranchBeforeCloseTask(g){return await this.post("/check_branch_before_close_task",g)}}let lo=null;function ad(){return lo||(lo=new Fd),lo}class sd extends Gg{login(g,B){return this.post("/login",{email:g,password:B})}loginPhoto(g){return this.post("/login/from_photo",{photo:g})}logout(){return this.post("/logout",null)}userInfo(){return this.get("/users/auth")}configs(){return this.get("/configs")}changePassword(g,B,Q){return this.put(`/users/${g}/password`,{password:B,password_confirmation:Q})}}let Ho;function ud(){return Ho||(Ho=new sd),Ho}class Ud extends Gg{uploadFile(g){return this.post("/upload-file",g,{headers:{"Content-Type":"multipart/form-data"}})}}let fo;function Gd(){return fo||(fo=new Ud),fo}class hd extends Gg{async startVideoAnalytics(){return await this.post("/statanly/start",null)}}let Jo;function ld(){return Jo||(Jo=new hd),Jo}class dd extends Gg{async editUser({id:g,model:B}){return await this.put(`/admin/users/${g}`,B)}async getUser(g){return await this.get(`/admin/users/${g}`)}}let No;function Hd(){return No||(No=new dd),No}/**
8
8
  * @license
9
9
  * Copyright 2020 Google LLC. All Rights Reserved.
10
10
  * Licensed under the Apache License, Version 2.0 (the "License");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shared-ritm",
3
- "version": "1.2.75",
3
+ "version": "1.2.76",
4
4
  "private": false,
5
5
  "files": [
6
6
  "dist",
@@ -130,7 +130,7 @@ class TasksService extends ApiService {
130
130
  }
131
131
  }
132
132
 
133
- let api: TasksService
133
+ let api: TasksService | null = null
134
134
 
135
135
  export default function useTasksService() {
136
136
  if (!api) api = new TasksService()