0xV3NOMx
Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64



Your IP : 18.219.247.59


Current Path : /var/www/egov/build/static/js/
Upload File :
Current File : /var/www/egov/build/static/js/305.2de1acc4.chunk.js

(window.webpackJsonp=window.webpackJsonp||[]).push([[305],{1386:function(t,e,r){"use strict";r.r(e);var n=r(3),o=r(68),a=r(100),i=r(101),c=r(103),u=r(102),s=r(104),l=r(2),h=r.n(l),f=r(1377),p=r(1343),d=r(272),y=r(1335),v=r(1337),m=r(941),g=r(105),w=r(267),b=r(271);function E(){E=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var a=e&&e.prototype instanceof m?e:m,i=Object.create(a.prototype),c=new N(n||[]);return o(i,"_invoke",{value:S(t,r,c)}),i}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var f="suspendedStart",p="suspendedYield",d="executing",y="completed",v={};function m(){}function g(){}function w(){}var b={};s(b,i,function(){return this});var L=Object.getPrototypeOf,x=L&&L(L(F([])));x&&x!==r&&n.call(x,i)&&(b=x);var j=w.prototype=m.prototype=Object.create(b);function O(t){["next","throw","return"].forEach(function(e){s(t,e,function(t){return this._invoke(e,t)})})}function k(t,e){function r(o,a,i,c){var u=h(t[o],t,a);if("throw"!==u.type){var s=u.arg,l=s.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then(function(t){r("next",t,i,c)},function(t){r("throw",t,i,c)}):e.resolve(l).then(function(t){s.value=t,i(s)},function(t){return r("throw",t,i,c)})}c(u.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e(function(e,o){r(t,n,e,o)})}return a=a?a.then(o,o):o()}})}function S(e,r,n){var o=f;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var u=_(c,n);if(u){if(u===v)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===f)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var s=h(e,r,n);if("normal"===s.type){if(o=n.done?y:p,s.arg===v)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=y,n.method="throw",n.arg=s.arg)}}}function _(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,_(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var a=h(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,v;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,v):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function T(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function P(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(T,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(typeof e+" is not iterable")}return g.prototype=w,o(j,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:g,configurable:!0}),g.displayName=s(w,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,s(t,u,"GeneratorFunction")),t.prototype=Object.create(j),t},e.awrap=function(t){return{__await:t}},O(k.prototype),s(k.prototype,c,function(){return this}),e.AsyncIterator=k,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new k(l(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then(function(t){return t.done?t.value:i.next()})},O(j),s(j,u,"Generator"),s(j,i,function(){return this}),s(j,"toString",function(){return"[object Generator]"}),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,N.prototype={constructor:N,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(P),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var u=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(u&&s){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,v):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),v},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),P(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;P(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),v}},e}var L=r(1065),x=r.n(L),j=(r(405),r(273));function O(){O=function(){return e};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",u=a.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var a=e&&e.prototype instanceof m?e:m,i=Object.create(a.prototype),c=new N(n||[]);return o(i,"_invoke",{value:S(t,r,c)}),i}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var f="suspendedStart",p="suspendedYield",d="executing",y="completed",v={};function m(){}function g(){}function w(){}var b={};s(b,i,function(){return this});var E=Object.getPrototypeOf,L=E&&E(E(F([])));L&&L!==r&&n.call(L,i)&&(b=L);var x=w.prototype=m.prototype=Object.create(b);function j(t){["next","throw","return"].forEach(function(e){s(t,e,function(t){return this._invoke(e,t)})})}function k(t,e){function r(o,a,i,c){var u=h(t[o],t,a);if("throw"!==u.type){var s=u.arg,l=s.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then(function(t){r("next",t,i,c)},function(t){r("throw",t,i,c)}):e.resolve(l).then(function(t){s.value=t,i(s)},function(t){return r("throw",t,i,c)})}c(u.arg)}var a;o(this,"_invoke",{value:function(t,n){function o(){return new e(function(e,o){r(t,n,e,o)})}return a=a?a.then(o,o):o()}})}function S(e,r,n){var o=f;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===y){if("throw"===a)throw i;return{value:t,done:!0}}for(n.method=a,n.arg=i;;){var c=n.delegate;if(c){var u=_(c,n);if(u){if(u===v)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===f)throw o=y,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=d;var s=h(e,r,n);if("normal"===s.type){if(o=n.done?y:p,s.arg===v)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(o=y,n.method="throw",n.arg=s.arg)}}}function _(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,_(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),v;var a=h(o,e.iterator,r.arg);if("throw"===a.type)return r.method="throw",r.arg=a.arg,r.delegate=null,v;var i=a.arg;return i?i.done?(r[e.resultName]=i.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,v):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function T(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function P(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(T,this),this.reset(!0)}function F(e){if(e||""===e){var r=e[i];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,a=function r(){for(;++o<e.length;)if(n.call(e,o))return r.value=e[o],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}throw new TypeError(typeof e+" is not iterable")}return g.prototype=w,o(x,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:g,configurable:!0}),g.displayName=s(w,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,w):(t.__proto__=w,s(t,u,"GeneratorFunction")),t.prototype=Object.create(x),t},e.awrap=function(t){return{__await:t}},j(k.prototype),s(k.prototype,c,function(){return this}),e.AsyncIterator=k,e.async=function(t,r,n,o,a){void 0===a&&(a=Promise);var i=new k(l(t,r,n,o),a);return e.isGeneratorFunction(r)?i:i.next().then(function(t){return t.done?t.value:i.next()})},j(x),s(x,u,"Generator"),s(x,i,function(){return this}),s(x,"toString",function(){return"[object Generator]"}),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=F,N.prototype={constructor:N,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(P),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function o(n,o){return c.type="throw",c.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var u=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(u&&s){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return o(i.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return o(i.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=t,i.arg=e,a?(this.method="next",this.next=a.finallyLoc,v):this.complete(i)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),v},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),P(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;P(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:F(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),v}},e}var k=function(t){function e(){var t,r;Object(a.a)(this,e);for(var i=arguments.length,s=new Array(i),l=0;l<i;l++)s[l]=arguments[l];return(r=Object(c.a)(this,(t=Object(u.a)(e)).call.apply(t,[this].concat(s)))).state={checked:[],expanded:[],parents:[],userType:"",submit:!1},r.handleSubmit=function(){if(""!=r.state.userType)r.props.getMenuList(r.state.userType),r.setState({submit:!0});else{r.props.showError({header:"Error",content:"Select User Type.!"})}},r.handleChange=function(){var t=Object(o.a)(O().mark(function t(e,n){var o;return O().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:n.name,o=n.value,r.setState({userType:o});case 2:case"end":return t.stop()}},t)}));return function(e,r){return t.apply(this,arguments)}}(),r.handleCreate=Object(o.a)(O().mark(function t(){var e,n,o,a,i,c,u,s;return O().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return e=r.state,n=e.checked,e.expanded,o=e.userType,a=e.parents,i=a.join("*"),c=n.join("*"),u=i.concat("*",c),s={fpermissions:u,usertype:o},t.next=7,r.props.updateUserMenus(s);case 7:r.setState({userType:"",parents:[],checked:[],expanded:[],submit:!1});case 8:case"end":return t.stop()}},t)})),r.onCheck=function(t,e){e.isParent&&e.checked?(r.setState({parents:[].concat(Object(n.a)(r.state.parents),[e.value])}),r.setState({checked:t})):e.isParent&&0==e.checked?(r.setState({parents:Object(n.a)(r.state.parents.filter(function(t,r){return t!=e.value}))}),r.setState({checked:t})):r.setState({checked:t})},r}return Object(s.a)(e,t),Object(i.a)(e,[{key:"componentDidMount",value:function(){var t=Object(o.a)(O().mark(function t(){return O().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,this.props.getUserTypeList();case 2:case"end":return t.stop()}},t,this)}));return function(){return t.apply(this,arguments)}}()},{key:"componentDidUpdate",value:function(t){this.props.menuList.permission!==t.menuList.permission&&this.setState({checked:this.props.menuList.permission})}},{key:"render",value:function(){var t=this,e=this.props.userTypeList,r=void 0==this.props.menuList.tree?[]:this.props.menuList.tree,n=void 0==this.props.menuList.icons?[]:this.props.menuList.icons,o=Object.keys(r).map(function(t,e){return r[t]}),a=(Object.keys(n).map(function(t,e){return n[t].icon}),e.map(function(t,e){return{key:e,value:t.FUSERTYPE,text:"".concat(t.FUSERTYPE," - ").concat(t.FTYPEDESC)}})),i=Object(j.i)();return h.a.createElement(h.a.Fragment,null,h.a.createElement(f.a,{fluid:!0},h.a.createElement(f.a.Content,null,h.a.createElement(f.a.Header,{style:{display:"flex"}},h.a.createElement("h3",null,"Assign Menus"),h.a.createElement("div",{className:"ml-auto"},h.a.createElement(p.a,{basic:!0,color:"blue",content:"Update",onClick:this.handleCreate,icon:"upload"}),h.a.createElement(m.a,{to:"/dashboard"},h.a.createElement(p.a,{basic:!0,color:"red",content:"Exit",icon:"home"})))),h.a.createElement(d.a,null),h.a.createElement(f.a.Description,{style:{height:"".concat(i,"px"),overflowY:"auto"}},h.a.createElement(y.a,null,h.a.createElement(y.a.Field,{width:8},h.a.createElement("label",null,"Select User Type"),h.a.createElement(v.a,{search:!0,selection:!0,id:"fusertype",name:"fusertype",options:a,onChange:this.handleChange,value:this.state.userType})),h.a.createElement(y.a.Field,null,h.a.createElement(p.a,{content:"Submit",color:"blue",onClick:this.handleSubmit})),this.state.submit?h.a.createElement(y.a.Field,null,h.a.createElement("label",null,"Menus"),h.a.createElement(x.a,{nodes:o,checked:this.state.checked,expanded:this.state.expanded,onCheck:this.onCheck,onExpand:function(e){return t.setState({expanded:e})}})):null)))))}}]),e}(l.Component);e.default=Object(g.b)(function(t){return{userTypeList:t.userTypeList,menuList:t.menuList}},{showError:w.A,getUserTypeList:function(){return function(){var t=Object(o.a)(E().mark(function t(e,r){var n,o,a,i;return E().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return n=r(),t.next=3,b.a.get("/app.php",{params:{a:"getUserTypeList",univcode:n.univ.funivcode,usertype:n.user.fcurtype}});case 3:"object"!==typeof(o=t.sent).data?(a={header:"Error",content:"Something went wrong"},e(Object(w.A)(a))):-1===o.data.error_code?(i={header:"Error",content:o.data.data.msg},e(Object(w.A)(i))):e({type:"USER_TYPE_LIST",payload:o.data});case 5:case"end":return t.stop()}},t)}));return function(e,r){return t.apply(this,arguments)}}()},getMenuList:function(t){return function(){var e=Object(o.a)(E().mark(function e(r,n){var o,a,i,c;return E().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o=n(),e.next=3,b.a.get("/app.php",{params:{a:"getMenuList",univcode:o.univ.funivcode,fusertype:t}});case 3:"object"!==typeof(a=e.sent).data?(i={header:"Error",content:"Something went wrong"},r(Object(w.A)(i))):-1===a.data.error_code?(c={header:"Error",content:a.data.data.msg},r(Object(w.A)(c))):r({type:"MENU_LIST",payload:a.data});case 5:case"end":return e.stop()}},e)}));return function(t,r){return e.apply(this,arguments)}}()},updateUserMenus:function(t){return function(){var e=Object(o.a)(E().mark(function e(r,n){var o,a,i,c,u;return E().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return o=n(),e.next=3,b.a.post("/app.php?a=updateUserMenus&univcode="+o.univ.funivcode,{data:t});case 3:"object"!==typeof(a=e.sent).data?(i={header:"Error",content:"Something went wrong"},r(Object(w.A)(i))):-1===a.data.error_code?(c={header:"Error",content:a.data.data.msg},r(Object(w.A)(c))):(u={header:"Success",content:a.data.data.msg},r(Object(w.A)(u)));case 5:case"end":return e.stop()}},e)}));return function(t,r){return e.apply(this,arguments)}}()}})(k)}}]);
//# sourceMappingURL=305.2de1acc4.chunk.js.map