????
Current Path : C:/inetpub/vhost/quanlycanbo.gdtvietnam.com/www/static/js/ |
Current File : C:/inetpub/vhost/quanlycanbo.gdtvietnam.com/www/static/js/17.e1662ff3.chunk.js |
(this["webpackJsonpgdt-qlcb"]=this["webpackJsonpgdt-qlcb"]||[]).push([[17],{1040:function(t,e,n){"use strict";var a=n(10),r=n(11),o=n(17),c=function(t){Object(r.a)(n,t);var e=Object(o.a)(n);function n(){return Object(a.a)(this,n),e.call(this,"/DMLoaiHopDongs")}return n}(n(669).a);e.a=new c},180:function(t,e,n){"use strict";n.r(e);var a=n(15),r=n(5),o=n(14),c=n(1),i=n(0),u=n.n(i),s=n(18),l=n.n(s),d=n(36),f=n(919),p=n(35),b=n(1037),O=n(1039),h=function(t){return function(e){return function(n){var a=Object(O.a)(),o=a.excelRef,i=a.excelData,u=a.setExcelData;return Object(c.jsxs)(c.Fragment,{children:[Object(c.jsx)(e,Object(r.a)(Object(r.a)({},n),{},{exportExcel:u})),Object(c.jsx)(b.a,{excelData:i,excelRef:o,children:t?t(i):null})]})}}},v=n(7),j=n(729),m=n(701),g=n(714),y=n(705),D=n(895),C=n(934),A=n(725),x=n(724),T=n(1161),N=n(1156),w=function(t){return{value:t,rowspan:2}},U=function(t){return Array.from(new Array(t)).fill(null)},L=function(t,e){return[{value:t,colspan:e}].concat(Object(p.a)(U(e-1)))},S=function(t,e,n){var a={};e.forEach((function(t){var e=t.Uuid;a[e]=[]}));var r,c=Object(f.a)(t);try{for(c.s();!(r=c.n()).done;){var i=r.value,u=i.CanboUuid,s=i[n];a[s].includes(u)||a[s].push(u)}}catch(l){c.e(l)}finally{c.f()}return Object.entries(a).reduce((function(t,e){var n=Object(o.a)(e,2),a=n[0],r=n[1];return t[a]=r.length,t}),{})};var k=h()((function(t){var e=t.exportExcel,n=t.query,a=void 0===n?{}:n,i=a.DmLhdUuid,u=void 0===i?[]:i,s=a.TinhTrang,f=void 0===s?[]:s,b=a.orientation,O=function(t){var e=void 0===t;if(!u||0===u.length)return 0===f.length?"?$count=true&$filter=Status eq true":"?filter=Status eq true and (".concat(f.map((function(t){var e=t.Uuid;return"TinhTrang eq ".concat(e)})).join(" or "),")&$count=true");var n=u.map((function(t,n){var a=t.Uuid;return"".concat(e?"":"Canbo/","CanboLoaihopdong/any(a").concat(n,":a").concat(n,"/DmLhdUuid eq ").concat(a," and a").concat(n,"/DmLhd/Status eq true)")})).join(" or "),a=(new Date).getFullYear();return(e?"?$expand=CanboLoaihopdong($select=Tungay,Denngay,DmLhdUuid)":"?$expand=".concat(t,",Canbo($filter=Status eq $expand=CanboLoaihopdong($select=Tungay,Denngay,DmLhdUuid))"))+"&$filter=".concat(n)+" and ".concat(e?"":"Canbo/","CanboLoaihopdong/any(b:year(b/Denngay) ge ").concat(a,")")+" and ".concat(e?"":"Canbo/","Status eq true")+function(t,e){return 0===t.length?"":" and ".concat(t.map((function(t){var n=t.Uuid;return e?"TinhTrang eq ".concat(n):"Canbo/TinhTrang eq ".concat(n)})).join(" or "))}(f,e)+"&$count=true"},h=function(){var t=Object(d.a)(l.a.mark((function t(){var n,a,i,u,s,d,f,h,g,k,P,E,q,$,B,I,R,M,V,G,z,H,F,X,J,Q,W,_,K,Y,Z,tt,et,nt,at,rt,ot,ct,it,ut,st,lt;return l.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=v.f.IDDonVi,t.next=3,j.a.getAll("?$filter=Uuid eq ".concat(n));case 3:return a=t.sent,i=a.value,u=i||[],s=Object(o.a)(u,1),d=s[0],f=(d=void 0===d?{}:d).OrganName,h=void 0===f?"\u0110\u01a1n v\u1ecb":f,t.next=10,y.b.getAll("?$count=true&$orderby=Douutien asc&$filter=Status eq true");case 10:return g=t.sent,k=g["@odata.count"],P=g.value,E=void 0===P?[]:P,t.next=16,D.a.getAll("?$count=true&$filter=Status eq true");case 16:return q=t.sent,$=q["@odata.count"],B=q.value,I=void 0===B?[]:B,t.next=22,C.a.getAll("?$count=true&$filter=Status eq true");case 22:return R=t.sent,M=R["@odata.count"],V=R.value,G=void 0===V?[]:V,t.next=28,m.a.getAll(O());case 28:return z=t.sent,H=z["@odata.count"],F=void 0===H?"Kh\xf4ng c\xf3 th\xf4ng tin":H,t.next=33,A.a.getAllUnlimited(O("DmBdnv"));case 33:return X=t.sent,t.next=36,x.a.getAllUnlimited(O("DmCv"));case 36:if(J=t.sent,Q=S(X,G,"DmBdnvUuid"),W=S(J,E,"DmCvUuid"),_=S(X,I,"DmTdUuid"),K=function(t){return null===t||void 0===t?void 0:t.Name},Y=[{cells:[w("STT"),w("T\xean c\u01a1 quan, \u0111\u01a1n v\u1ecb tr\u1ef1c thu\u1ed9c"),w("T\u1ed5ng s\u1ed1")].concat(Object(p.a)(L("Tr\xecnh \u0111\u1ed9 chuy\xean m\xf4n \u0111\u01b0\u1ee3c \u0111\xe0o t\u1ea1o",$)),Object(p.a)(L("\u0110\xe3 qua c\xe1c kh\xf3a \u0111\xe0o t\u1ea1o, b\u1ed3i d\u01b0\u1ee1ng",M)),Object(p.a)(L("Ch\u1ee9c v\u1ee5",k)),[w("Ghi ch\xfa")])},{cells:U(3).concat(I.map(K)).concat(G.map(K)).concat(E.map(K)).concat([null])}],Z="S\u1ed1 l\u01b0\u1ee3ng ch\u1ea5t l\u01b0\u1ee3ng c\xe1n b\u1ed9",tt="Bao cao so luong va chat luong can bo.xlsx",et="B\xc1O C\xc1O S\u1ed0 L\u01af\u1ee2NG V\xc0 CH\u1ea4T L\u01af\u1ee2NG C\xd4NG CH\u1ee8C, VI\xcaN CH\u1ee8C L\xc0M C\xd4NG T\xc1C T\u1ed4 CH\u1ee8C, C\xc1N B\u1ed8",nt=[Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({organName:h,numberOfOfficial:F},_),Q),W),{},{note:""})],at={sheetName:Z,fileName:tt,header:Y,columns:[{key:"organName",name:"",width:25},{key:"numberOfOfficial",name:""}].concat(I.concat(G).concat(E).map((function(t){return{key:t.Uuid,name:t.Name}}))).concat([{key:"note",name:""}]),data:nt,title:et},"port"!==b.Uuid){t.next=57;break}return rt=[{key:"",name:"T\xean \u0111\u01a1n v\u1ecb, c\u01a1 quan tr\u1ef1c thu\u1ed9c",width:40,style:{alignment:{horizontal:"center"}}},{key:"",name:"S\u1ed1 l\u01b0\u1ee3ng"},{key:"",name:"Ghi ch\xfa",width:20}],ot=function(){return Object(c.jsx)(T.b,{style:N.d,columns:rt,data:[],topLeft:"B7",rows:rt})},ct=function(t){return function(e,n){var a,r=Object(o.a)(e,2),c=r[0],i=r[1];return{cells:[{value:(n+1).toString()},{value:null===(a=t.find((function(t){return t.Uuid===c})))||void 0===a?void 0:a.Name},{value:i},{value:null}]}}},ut=[{cells:[{value:h,rowspan:2,colspan:3,style:{alignment:{horizontal:"center"}}},null]}].concat([(it=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:3;return{cells:[{value:t,style:{font:{bold:!0,fontSize:12}}},{value:e,colspan:n,style:{font:{bold:!0,fontSize:12}}}]}})("I",h)].concat([it("1","Tr\xecnh \u0111\u1ed9 chuy\xean m\xf4n \u0111\u01b0\u1ee3c \u0111\xe0o t\u1ea1o")]).concat(Object.entries(_).map(ct(I))).concat([it("2","\u0110\xe3 qua c\xe1c kh\xf3a \u0111\xe0o t\u1ea1o, b\u1ed3i d\u01b0\u1ee1ng")]).concat(Object.entries(Q).map(ct(G))).concat([it("3","Ch\u1ee9c v\u1ee5")]).concat(Object.entries(W).map(ct(E)))),st=function(){return ut.map((function(t,e){return Object(c.jsx)(T.a,{style:0===e?void 0:Object(r.a)(Object(r.a)({},N.d),{},{alignment:{wrapText:!1}}),data:[],columns:{length:6},topLeft:0===e?"A1":"'B".concat(7+e),rows:[t]})}))},lt=function(){return Object(c.jsx)(T.a,{rows:[{cells:[{colspan:6,value:et}],height:65}],style:{alignment:{horizontal:"center"},font:{size:16,bold:!0}},topLeft:[4,1]})},t.abrupt("return",e({renderArrayRowGroup:st,renderHeader:ot,title:et,fileName:tt,sheetName:Z,columns:{length:6},renderTitle:lt,nationalMottoColspan:3}));case 57:e(at);case 58:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();return Object(c.jsxs)("button",{onClick:function(){g.a.didOpen({pendingSwal:"\u0110ang xu\u1ea5t b\xe1o c\xe1o ch\u1ea5t l\u01b0\u1ee3ng c\xe1n b\u1ed9",callAPIFn:h,onSuccess:{getSwal:function(){return"B\xe1o c\xe1o ch\u1ea5t l\u01b0\u1ee3ng c\xe1n b\u1ed9 \u0111\xe3 \u0111\u01b0\u1ee3c t\u1ea3i xu\u1ed1ng"}}})},className:"btn btn-primary",children:[Object(c.jsx)("i",{className:"fas fa-file-excel mr-3"}),"Xu\u1ea5t b\xe1o c\xe1o"]})})),P=n(793),E=n(1040),q=n(817),$=n(120),B=function(){return E.a.getAll("?$filter=Status eq true").then((function(t){return t.value}))},I=[{Name:"\u0110ang l\xe0m vi\u1ec7c",Uuid:"'DangLamViec'"},{Name:"Ngh\u1ec9 h\u01b0u",Uuid:"'NghiHuu'"}],R=[{Name:"Chi\u1ec1u d\u1ecdc",Uuid:"land"},{Name:"Chi\u1ec1u ngang",Uuid:"port"}];e.default=function(){var t=u.a.useState({orientation:R[1]}),e=Object(o.a)(t,2),n=e[0],i=e[1],s=n||{},l=s.DmLhdUuid,d=void 0===l?[]:l,f=s.TinhTrang,p=void 0===f?[]:f,b=s.orientation,O={getOptionLabel:function(t){return null===t||void 0===t?void 0:t.Name},getOptionValue:function(t){return null===t||void 0===t?void 0:t.Uuid},isMulti:!0,onChange:function(t,e){var n=e.name;i((function(e){return Object(r.a)(Object(r.a)({},e),{},Object(a.a)({},n,t))}))}};return Object(c.jsxs)("div",{className:"bg-white p-3",children:[Object(c.jsxs)(P.a,{color:"info",children:[Object(c.jsx)("i",{className:"fas fa-info-circle text-info mr-4"}),'Ch\u1ecdn \u0111i\u1ec1u ki\u1ec7n b\xe1o c\xe1o v\xe0 b\u1ea5m v\xe0o n\xfat "Xu\u1ea5t b\xe1o c\xe1o" \u0111\u1ec3 xu\u1ea5t b\xe1o c\xe1o']}),Object(c.jsxs)("div",{className:"row",children:[Object(c.jsxs)("div",{className:"form-group col-md-4",children:[Object(c.jsx)("label",{children:"Lo\u1ea1i h\u1ee3p \u0111\u1ed3ng"}),Object(c.jsx)(q.a,Object(r.a)(Object(r.a)({},O),{},{defaultOptions:!0,cacheOptions:!0,value:d,name:"DmLhdUuid",loadingMessage:function(){return"\u0110ang t\u1ea3i c\xe1c lo\u1ea1i h\u1ee3p \u0111\u1ed3ng"},placeholder:"T\u1ea5t c\u1ea3 lo\u1ea1i h\u1ee3p \u0111\u1ed3ng",loadOptions:B}))]}),Object(c.jsxs)("div",{className:"form-group col-md-4",children:[Object(c.jsx)("label",{children:"Tr\u1ea1ng th\xe1i l\xe0m vi\u1ec7c"}),Object(c.jsx)($.a,Object(r.a)(Object(r.a)({},O),{},{value:p,name:"TinhTrang",placeholder:"T\u1ea5t c\u1ea3 tr\u1ea1ng th\xe1i l\xe0m vi\u1ec7c",options:I}))]}),Object(c.jsxs)("div",{className:"form-group col-md-4",children:[Object(c.jsx)("label",{children:"Excel"}),Object(c.jsx)($.a,Object(r.a)(Object(r.a)({},O),{},{isMulti:!1,value:b,name:"orientation",options:R}))]})]}),Object(c.jsxs)("div",{className:"d-flex justify-content-end",children:[Object(c.jsxs)("button",{className:"btn btn-danger mr-3",onClick:function(){i(void 0)},children:[Object(c.jsx)("i",{className:"fas fa-times mr-3"}),"X\xf3a \u0111i\u1ec1u ki\u1ec7n"]}),Object(c.jsx)(k,{query:n})]})]})}},668:function(t,e,n){"use strict";var a=n(35),r=n(5),o=n(10),c=n(11),i=n(17),u=n(14),s=n(39),l=n(671),d=n(685),f={noLoading:"\ud83d\ude02\ud83d\ude02\ud83d\ude02",noAlert:!0},p=function(t,e){var n=Object(u.a)(e,2),a=n[0],r=n[1];return void 0!==(null===r||void 0===r?void 0:r.Uuid)?t[a]=null===r||void 0===r?void 0:r.Uuid:t[a]=r,t},b=function(t){return Object.entries(t).reduce(p,{})},O=function(t){Object(c.a)(n,t);var e=Object(i.a)(n);function n(t){var c;return Object(o.a)(this,n),(c=e.call(this,"/QLCB"+t)).getAll=function(t){return c.SearchAllOdata(t)},c.add=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:f;return c.InsertODATA(t,e)},c.edit=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:f;return c.UpdateODATA("(".concat(t,")"),e,n)},c.delete=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:f;return c.DeleteADMINODATA("(".concat(t,")"),e)},c.addUpdate=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];if(!t)return Promise.reject("nani");var o=void 0!==t.Uuid,i=Object(r.a)(Object(r.a)({},b(t)),{},{DocumentUuid:e});return o?c.edit(t.Uuid,Object(s.m)(i,[].concat(Object(a.a)(n),["tableData"]))):c.add(Object(s.m)(i,n)).catch((function(){return e?l.a.delete(e).then(Promise.reject):Promise.reject("Thi ra may chon cai chet")}))},c}return n}(d.a);e.a=O},671:function(t,e,n){"use strict";var a=n(10),r=n(34),o=n(11),c=n(17),i=n(686),u=n(7),s=n(63),l=n(220),d=n.n(l),f=function(t){Object(o.a)(n,t);var e=Object(c.a)(n);function n(){var t;return Object(a.a)(this,n),(t=e.call(this,"/Documents")).downloadDoc=function(e){var n=e.Uuid,a=e.Subject;return t.GetAuthenADMINODATA("/Download?uuid=".concat(n),{responseType:"blob",noAlert:!0,noLoading:!0}).then((function(t){return d()(t,a)}))},t.getDocUrlByUuid=function(e){return u.i+u.d+t.prefix+t.path+"/Download?uuid=".concat(e)},t}return Object(r.a)(n,[{key:"addDocument",value:function(t){return this.add(t)}},{key:"uploadFileDocument",value:function(t,e){return this.upload(t,e)}},{key:"getByUuid",value:function(t){return this.getAll("(".concat(t,")"),{noAlert:!0,noLoading:!0})}},{key:"getBase64",value:function(t){var e=this.getDocUrlByUuid(t);return fetch(e,Object(s.g)("GET",null,!0)).then((function(t){return t.blob()})).then(URL.createObjectURL)}}]),n}(i.a);e.a=new f},686:function(t,e,n){"use strict";var a=n(10),r=n(11),o=n(17),c=function(t){Object(r.a)(n,t);var e=Object(o.a)(n);function n(t){var r;return Object(a.a)(this,n),(r=e.call(this,"/SDoc",t)).getAll=function(t,e){return r.SearchAllOdata(t,e)},r.add=function(t){return r.InsertODATA(t)},r.upload=function(t,e){return r.UploadODataSdoc("/upload",!0,!1,e,t)},r.edit=function(t,e){return r.UpdateODATA("(".concat(t,")"),e)},r.delete=function(t){return r.DeleteADMINODATA("(".concat(t,")"),{noLoading:"loadCC",noAlert:"lertCC"})},r}return n}(n(109).a);e.a=c},702:function(t,e,n){"use strict";var a=n(23),r=n(28),o=n(216),c=n(0),i=n.n(c),u=n(2),s=n.n(u),l=n(16),d=n.n(l),f=n(749),p=n(8);function b(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}function O(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?b(Object(n),!0).forEach((function(e){Object(o.a)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):b(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}var h=O(O({},f.Transition.propTypes),{},{children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node]),tag:p.q,baseClass:s.a.string,baseClassActive:s.a.string,className:s.a.string,cssModule:s.a.object,innerRef:s.a.oneOfType([s.a.object,s.a.string,s.a.func])}),v=O(O({},f.Transition.defaultProps),{},{tag:"div",baseClass:"fade",baseClassActive:"show",timeout:p.e.Fade,appear:!0,enter:!0,exit:!0,in:!0});function j(t){var e=t.tag,n=t.baseClass,o=t.baseClassActive,c=t.className,u=t.cssModule,s=t.children,l=t.innerRef,b=Object(r.a)(t,["tag","baseClass","baseClassActive","className","cssModule","children","innerRef"]),O=Object(p.o)(b,p.c),h=Object(p.n)(b,p.c);return i.a.createElement(f.Transition,O,(function(t){var r="entered"===t,f=Object(p.m)(d()(c,n,r&&o),u);return i.a.createElement(e,Object(a.a)({className:f},h,{ref:l}),s)}))}j.propTypes=h,j.defaultProps=v,e.a=j},724:function(t,e,n){"use strict";var a=n(10),r=n(34),o=n(11),c=n(17),i=function(t){Object(o.a)(n,t);var e=Object(c.a)(n);function n(){return Object(a.a)(this,n),e.call(this,"/CanBoPBCVs")}return Object(r.a)(n,[{key:"add",value:function(t){return this.PostAuthenADMINODATA("",t)}},{key:"update",value:function(t,e){return this.UpdateODATA("(".concat(t,")"),e)}},{key:"getDataByIDCanBo",value:function(t){return this.SearchAllOdata("?&$filter=CanboUuid eq ".concat(t," and Status eq true&$orderby=Tungay desc"))}}]),n}(n(668).a);e.a=new i},725:function(t,e,n){"use strict";var a=n(5),r=n(10),o=n(34),c=n(11),i=n(17),u=n(14),s=n(668),l=n(39),d=n(756),f=function(t,e){var n=Object(u.a)(e,2),a=n[0],r=n[1];return r?(r.Uuid?t[a]=r.Uuid:t[a]=r,t):t},p=function(t){return Object.entries(t).reduce(f,{})},b=function(t){Object(c.a)(n,t);var e=Object(i.a)(n);function n(){return Object(r.a)(this,n),e.call(this,"/CanBoBoiDuongNghiepVus")}return Object(o.a)(n,[{key:"add",value:function(t){return this.PostAuthenADMINODATA("",t)}},{key:"update",value:function(t,e){return this.UpdateODATA("(".concat(t,")"),e)}},{key:"delete",value:function(t){return this.DeleteADMINODATA("(".concat(t,")"))}},{key:"addUpdate",value:function(t,e){return t?t.hasOwnProperty.call(t,"Uuid")?this.edit(t.Uuid,Object(l.m)(p(t),["tableData"])):this.add(Object(a.a)(Object(a.a)({},p(t)),{},{DocumentUuid:e,CanboUuid:d.a})):Promise.reject("nani")}},{key:"getDataByIDCanBo",value:function(t){return this.SearchAllOdata("?$expand=DmBdnv($select=Name,Code),DmCn($select=Name,Code),DmDl($select=Name,Code),DmTd($select=Name,Code),&$filter=CanboUuid eq ".concat(t))}}]),n}(s.a);e.a=new b},729:function(t,e,n){"use strict";var a=n(10),r=n(34),o=n(11),c=n(17),i=function(t){Object(o.a)(n,t);var e=Object(c.a)(n);function n(){return Object(a.a)(this,n),e.call(this,"/Organizations")}return Object(r.a)(n,[{key:"getAllData",value:function(){return this.getAll("?$select=name%2CUuid%2Ccode&count=true")}},{key:"addOrganization",value:function(t){return this.add(t)}},{key:"update",value:function(t,e){return this.edit(t,e)}}]),n}(n(668).a);e.a=new i},756:function(t,e,n){"use strict";n.d(e,"a",(function(){return g}));var a=n(10),r=n(15),o=n(18),c=n.n(o),i=n(36),u=n(5),s=n(7),l=n(57),d=n.n(l),f="GDTQLCB",p=function(t,e){return Object(u.a)({method:t,credentials:"same-origin",headers:Object(u.a)({"Content-Type":"application/json","X-Forwarded-For":d.a.get("IP_Client"),Accept:"application/json"},d.a.get(f)?{Authorization:"Bearer ".concat(d.a.get(f))}:{})},e?{body:JSON.stringify(e)}:{})},b=function(t){switch(t){case"add":return"POST";case"update":return"PATCH";case"delete":return"DELETE";default:return"GET"}},O=function(){var t=Object(i.a)(c.a.mark((function t(e){var n,a,r,o,i,u,l,d,f;return c.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.resType,a=void 0===n?"json":n,r=e.endpoint,o=e.method,i=void 0===o?"GET":o,u=e.body,l=p(i,u),t.next=4,fetch(s.i+r,l);case 4:if(d=t.sent,204!==(f=d.status)){t.next=8;break}return t.abrupt("return",Promise.resolve(d));case 8:if(!(f>=200&&f<=300)){t.next=12;break}return t.next=11,d[a]();case 11:return t.abrupt("return",t.sent);case 12:if(!(f>=400&&f<500)){t.next=14;break}return t.abrupt("return",Promise.reject(d));case 14:return t.abrupt("return",Promise.reject(d));case 15:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),h={mixin:function(t){return["add","update","delete","getAll"].reduce((function(e,n){return Object(u.a)(Object(u.a)({},e),{},Object(r.a)({},n,(function(e){return O(function(e,n){return{endpoint:"".concat(t),method:b(e),body:n}}(n,e))})))}),{})}},v=["GET","POST","PUT","PATCH","DELETE"],j=(v.reduce((function(t,e){return Object(u.a)(Object(u.a)({},t),{},Object(r.a)({},e.toLowerCase(),O))}),h),new function t(){var e=this;Object(a.a)(this,t),this.endpoint="",this.getEndpoint=function(t,e){switch(t){case"getById":case"update":case"delete":return"(".concat(e,")");case"add":case"getAll":return"";default:return"/"+t}},this.setService=function(t){e[t]=function(n,a){var r=b(t),o=e.endpoint+e.getEndpoint(t,n);return O("POST"===r?{method:r,endpoint:o,body:a||n}:{method:r,endpoint:o,body:a})}},this.mixin=function(n){var a=new t;return a.endpoint=e.endpoint+n,a};v.forEach((function(t){e[t.toLowerCase()]=O})),["add","update","delete","getAll","getById"].forEach(this.setService)}),m=v.reduce((function(t,e){return Object(u.a)(Object(u.a)({},t),{},Object(r.a)({},e.toLowerCase(),O))}),j).mixin("/odata"),g=(m.mixin("/QLCB"),m.mixin("/DM"),"c313f654-b02b-44d4-b443-0ef61d5f55a6")},793:function(t,e,n){"use strict";var a=n(23),r=n(28),o=n(216),c=n(0),i=n.n(c),u=n(2),s=n.n(u),l=n(16),d=n.n(l),f=n(8),p=n(702);function b(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}function O(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?b(Object(n),!0).forEach((function(e){Object(o.a)(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):b(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}var h={children:s.a.node,className:s.a.string,closeClassName:s.a.string,closeAriaLabel:s.a.string,cssModule:s.a.object,color:s.a.string,fade:s.a.bool,isOpen:s.a.bool,toggle:s.a.func,tag:f.q,transition:s.a.shape(p.a.propTypes),innerRef:s.a.oneOfType([s.a.object,s.a.string,s.a.func])},v={color:"success",isOpen:!0,tag:"div",closeAriaLabel:"Close",fade:!0,transition:O(O({},p.a.defaultProps),{},{unmountOnExit:!0})};function j(t){var e=t.className,n=t.closeClassName,o=t.closeAriaLabel,c=t.cssModule,u=t.tag,s=t.color,l=t.isOpen,b=t.toggle,h=t.children,v=t.transition,j=t.fade,m=t.innerRef,g=Object(r.a)(t,["className","closeClassName","closeAriaLabel","cssModule","tag","color","isOpen","toggle","children","transition","fade","innerRef"]),y=Object(f.m)(d()(e,"alert","alert-"+s,{"alert-dismissible":b}),c),D=Object(f.m)(d()("close",n),c),C=O(O(O({},p.a.defaultProps),v),{},{baseClass:j?v.baseClass:"",timeout:j?v.timeout:0});return i.a.createElement(p.a,Object(a.a)({},g,C,{tag:u,className:y,in:l,role:"alert",innerRef:m}),b?i.a.createElement("button",{type:"button",className:D,"aria-label":o,onClick:b},i.a.createElement("span",{"aria-hidden":"true"},"\xd7")):null,h)}j.propTypes=h,j.defaultProps=v,e.a=j},817:function(t,e,n){"use strict";var a=n(6),r=n(4),o=(n(326),n(327),n(221),n(10)),c=n(34),i=(n(223),n(11)),u=n(58),s=n(38),l=n(0),d=n.n(l),f=(n(12),n(100),n(222),n(22)),p=n(111),b=(n(85),n(322),n(170),n(231));function O(t){var e=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,a=Object(s.a)(t);if(e){var r=Object(s.a)(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return Object(u.a)(this,n)}}var h={cacheOptions:!1,defaultOptions:!1,filterOption:null,isLoading:!1},v=function(t){var e,n;return n=e=function(e){Object(i.a)(u,e);var n=O(u);function u(t){var e;return Object(o.a)(this,u),(e=n.call(this)).select=void 0,e.lastRequest=void 0,e.mounted=!1,e.optionsCache={},e.handleInputChange=function(t,n){var a=e.props,r=a.cacheOptions,o=a.onInputChange,c=Object(f.g)(t,n,o);if(!c)return delete e.lastRequest,void e.setState({inputValue:"",loadedInputValue:"",loadedOptions:[],isLoading:!1,passEmptyOptions:!1});if(r&&e.optionsCache[c])e.setState({inputValue:c,loadedInputValue:c,loadedOptions:e.optionsCache[c],isLoading:!1,passEmptyOptions:!1});else{var i=e.lastRequest={};e.setState({inputValue:c,isLoading:!0,passEmptyOptions:!e.state.loadedInputValue},(function(){e.loadOptions(c,(function(t){e.mounted&&(t&&(e.optionsCache[c]=t),i===e.lastRequest&&(delete e.lastRequest,e.setState({isLoading:!1,loadedInputValue:c,loadedOptions:t||[],passEmptyOptions:!1})))}))}))}return c},e.state={defaultOptions:Array.isArray(t.defaultOptions)?t.defaultOptions:void 0,inputValue:"undefined"!==typeof t.inputValue?t.inputValue:"",isLoading:!0===t.defaultOptions,loadedOptions:[],passEmptyOptions:!1},e}return Object(c.a)(u,[{key:"componentDidMount",value:function(){var t=this;this.mounted=!0;var e=this.props.defaultOptions,n=this.state.inputValue;!0===e&&this.loadOptions(n,(function(e){if(t.mounted){var n=!!t.lastRequest;t.setState({defaultOptions:e||[],isLoading:n})}}))}},{key:"UNSAFE_componentWillReceiveProps",value:function(t){t.cacheOptions!==this.props.cacheOptions&&(this.optionsCache={}),t.defaultOptions!==this.props.defaultOptions&&this.setState({defaultOptions:Array.isArray(t.defaultOptions)?t.defaultOptions:void 0})}},{key:"componentWillUnmount",value:function(){this.mounted=!1}},{key:"focus",value:function(){this.select.focus()}},{key:"blur",value:function(){this.select.blur()}},{key:"loadOptions",value:function(t,e){var n=this.props.loadOptions;if(!n)return e();var a=n(t,e);a&&"function"===typeof a.then&&a.then(e,(function(){return e()}))}},{key:"render",value:function(){var e=this,n=this.props,o=(n.loadOptions,n.isLoading),c=Object(a.a)(n,["loadOptions","isLoading"]),i=this.state,u=i.defaultOptions,s=i.inputValue,l=i.isLoading,f=i.loadedInputValue,p=i.loadedOptions,b=i.passEmptyOptions?[]:s&&f?p:u||[];return d.a.createElement(t,Object(r.a)({},c,{ref:function(t){e.select=t},options:b,isLoading:l||o,onInputChange:this.handleInputChange}))}}]),u}(l.Component),e.defaultProps=h,n}(Object(b.a)(p.a));e.a=v},895:function(t,e,n){"use strict";var a=n(10),r=n(11),o=n(17),c=function(t){Object(r.a)(n,t);var e=Object(o.a)(n);function n(){return Object(a.a)(this,n),e.call(this,"/DMTrinhDos")}return n}(n(669).a);e.a=new c},919:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var a=n(161);function r(t,e){var n;if("undefined"===typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(n=Object(a.a)(t))||e&&t&&"number"===typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,i=!0,u=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return i=t.done,t},e:function(t){u=!0,c=t},f:function(){try{i||null==n.return||n.return()}finally{if(u)throw c}}}}},934:function(t,e,n){"use strict";var a=n(10),r=n(11),o=n(17),c=function(t){Object(r.a)(n,t);var e=Object(o.a)(n);function n(){return Object(a.a)(this,n),e.call(this,"/DMBoiDuongNghiepVus")}return n}(n(669).a);e.a=new c}}]);