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.127.59
(window.webpackJsonp=window.webpackJsonp||[]).push([[98],{1212:function(e,t,n){"use strict";n.r(t);var r=n(69),o=n(68),a=n(2),i=n.n(a),u=n(1377),l=n(1343),s=n(272),c=n(1333),f=n(1335),h=n(1337),p=n(274),d=n(275),v=n.n(d),m=n(287),g=n.n(m),y=n(105),w=n(267),k=n(533),E=n(371),b=n.n(E),O=(n(372),n(941));function S(){S=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},i=a.iterator||"@@iterator",u=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function s(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(e){s=function(e,t,n){return e[t]=n}}function c(e,t,n,r){var a=t&&t.prototype instanceof g?t:g,i=Object.create(a.prototype),u=new I(r||[]);return o(i,"_invoke",{value:C(e,n,u)}),i}function f(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=c;var h="suspendedStart",p="suspendedYield",d="executing",v="completed",m={};function g(){}function y(){}function w(){}var k={};s(k,i,function(){return this});var E=Object.getPrototypeOf,b=E&&E(E(M([])));b&&b!==n&&r.call(b,i)&&(k=b);var O=w.prototype=g.prototype=Object.create(k);function L(e){["next","throw","return"].forEach(function(t){s(e,t,function(e){return this._invoke(t,e)})})}function x(e,t){function n(o,a,i,u){var l=f(e[o],e,a);if("throw"!==l.type){var s=l.arg,c=s.value;return c&&"object"==typeof c&&r.call(c,"__await")?t.resolve(c.__await).then(function(e){n("next",e,i,u)},function(e){n("throw",e,i,u)}):t.resolve(c).then(function(e){s.value=e,i(s)},function(e){return n("throw",e,i,u)})}u(l.arg)}var a;o(this,"_invoke",{value:function(e,r){function o(){return new t(function(t,o){n(e,r,t,o)})}return a=a?a.then(o,o):o()}})}function C(t,n,r){var o=h;return function(a,i){if(o===d)throw new Error("Generator is already running");if(o===v){if("throw"===a)throw i;return{value:e,done:!0}}for(r.method=a,r.arg=i;;){var u=r.delegate;if(u){var l=D(u,r);if(l){if(l===m)continue;return l}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===h)throw o=v,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=d;var s=f(t,n,r);if("normal"===s.type){if(o=r.done?v:p,s.arg===m)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(o=v,r.method="throw",r.arg=s.arg)}}}function D(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,D(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var a=f(o,t.iterator,n.arg);if("throw"===a.type)return n.method="throw",n.arg=a.arg,n.delegate=null,m;var i=a.arg;return i?i.done?(n[t.resultName]=i.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,m):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function j(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function I(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(j,this),this.reset(!0)}function M(t){if(t||""===t){var n=t[i];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return a.next=a}}throw new TypeError(typeof t+" is not iterable")}return y.prototype=w,o(O,"constructor",{value:w,configurable:!0}),o(w,"constructor",{value:y,configurable:!0}),y.displayName=s(w,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,w):(e.__proto__=w,s(e,l,"GeneratorFunction")),e.prototype=Object.create(O),e},t.awrap=function(e){return{__await:e}},L(x.prototype),s(x.prototype,u,function(){return this}),t.AsyncIterator=x,t.async=function(e,n,r,o,a){void 0===a&&(a=Promise);var i=new x(c(e,n,r,o),a);return t.isGeneratorFunction(n)?i:i.next().then(function(e){return e.done?e.value:i.next()})},L(O),s(O,l,"Generator"),s(O,i,function(){return this}),s(O,"toString",function(){return"[object Generator]"}),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=M,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(P),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return u.type="throw",u.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],u=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=r.call(i,"catchLoc"),s=r.call(i,"finallyLoc");if(l&&s){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){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(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=e,i.arg=t,a?(this.method="next",this.next=a.finallyLoc,m):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),m},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),P(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;P(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:M(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),m}},t}t.default=Object(y.b)(function(e){return{user:e.user}},{showError:w.A,saveUploadedPhotocopy:k.a})(function(e){var t=function(){var e=Object(o.a)(S().mark(function e(t,n){return S().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:n.forEach(function(e){return e.remove()});case 1:case"end":return e.stop()}},e)}));return function(t,n){return e.apply(this,arguments)}}(),n=Object(a.useState)(!1),d=Object(r.a)(n,2),m=d[0],y=d[1],w=Object(a.useState)(g()().format("DD/MM/YYYY")),k=Object(r.a)(w,2),E=k[0],L=k[1],x=Object(a.useState)(g()().format("DD/MM/YYYY")),C=Object(r.a)(x,2),D=C[0],j=C[1],P=Object(a.useState)("0"),I=Object(r.a)(P,2),M=I[0],F=I[1],N=Object(a.useState)("ZZZZZ"),_=Object(r.a)(N,2),T=_[0],V=_[1],A=Object(a.useState)([]),G=Object(r.a)(A,2),R=G[0],Y=G[1],B=Object(a.useState)("PENDING"),U=Object(r.a)(B,2),q=U[0],z=U[1];Object(a.useEffect)(function(){Y([{key:"PENDING",text:"PENDING",value:"PENDING"},{key:"UPLOADED",text:"UPLOADED",value:"UPLOADED"},{key:"ALL",text:"ALL",value:"ALL"}])},[]);var Z=70*window.innerHeight/100,H={n:"[0-1]",m:"[0-9]",e:"[0-3]",d:"[0-9]",z:"[1-2]",y:"[0-9]"};return i.a.createElement(i.a.Fragment,null,i.a.createElement(u.a,{fluid:!0},i.a.createElement(u.a.Content,null,i.a.createElement(u.a.Header,{style:{display:"flex"}},i.a.createElement("h4",null,"Upload Photo Copy Scripts"),i.a.createElement("div",{className:"ml-auto"},i.a.createElement(l.a,{basic:!0,color:"blue",content:"Pending Report",icon:"file pdf outline",onClick:function(){return y(!0)}}),i.a.createElement(O.a,{to:"/dashboard"},i.a.createElement(l.a,{basic:!0,color:"red",content:"Exit",icon:"home"})))),i.a.createElement(s.a,null),i.a.createElement(u.a.Description,{style:{height:"".concat(Z,"px"),overflowY:"auto"}},i.a.createElement(c.a,{style:{maxHeight:"50%",width:"40%"},size:"small",open:m,onClose:function(){return y(!1)},closeOnDimmerClick:!1},i.a.createElement(c.a.Header,{style:{display:"flex"}},"Photo copy pending upload report"),i.a.createElement(c.a.Content,null,i.a.createElement(f.a,null,i.a.createElement(f.a.Group,null,i.a.createElement(f.a.Field,{width:8},i.a.createElement("label",null," Date Range "),i.a.createElement(v.a,{formatChars:H,type:"text",value:E,mask:"ed/nm/zyyy",placeholder:"Date From",name:"vdatefrom",onChange:function(e){return L(e.target.value)}})),i.a.createElement(f.a.Field,{width:8},i.a.createElement(v.a,{formatChars:H,type:"text",value:D,mask:"ed/nm/zyyy",placeholder:"To",name:"vdateto",onChange:function(e){return j(e.target.value)},style:{marginTop:"1.6em"}}))),i.a.createElement(f.a.Group,null,i.a.createElement(f.a.Field,{width:8},i.a.createElement("label",null," QP Code Range "),i.a.createElement(f.a.Input,{type:"text",value:M,maxLength:5,placeholder:"QP Code From",name:"qpcodeFrom",onChange:function(e,t){return F(t.value)}})),i.a.createElement(f.a.Field,{width:8},i.a.createElement(f.a.Input,{type:"text",value:T,maxLength:5,placeholder:"QP Code To",name:"qpcodeTo",onChange:function(e,t){return V(t.value)},style:{marginTop:"1.6em"}}))),i.a.createElement(f.a.Field,null,i.a.createElement("label",null,"Status"),i.a.createElement(h.a,{placeholder:"Select Status",fluid:!0,selection:!0,value:q,onChange:function(e,t){z(t.value)},options:R})),i.a.createElement(f.a.Field,null,i.a.createElement(l.a,{style:{float:"right"},color:"blue",onClick:function(){window.open(p.c+"viewPhotoCopyPendingList&univcode="+e.user.fcuruniv+"&fdeggrp="+e.user.fdeggrp+"&dateFrom="+E+"&dateTo="+D+"&qpcodeFrom="+M+"&qpcodeTo="+T+"&status="+q,"_blank")},content:"View Report"}))))),i.a.createElement(b.a,{getUploadParams:function(t){var n=t.file,r=(t.meta,new FormData);return r.append("fileField",n),r.append("univcode",JSON.stringify(e.user)),{url:p.a+"/upload_pc.php",body:r}},onChangeStatus:function(e,t){e.meta,e.remove},onSubmit:t,validate:function(e){e.file;var t=e.meta.name.split("-");return(5!==t[0].length||4!==t[1].length||6!==t[2].length)&&"Invalid file name"},accept:"application/pdf",maxFiles:50,styles:{dropzone:{minHeight:200,maxHeight:Z-10}}})))))})},275:function(e,t,n){e.exports=n(276)},276:function(e,t,n){"use strict";var r,o=(r=n(2))&&"object"==typeof r&&"default"in r?r.default:r,a=n(106);function i(){return(i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function u(e,t){e.prototype=Object.create(t.prototype),function(e,t){for(var n=Object.getOwnPropertyNames(t),r=0;r<n.length;r++){var o=n[r],a=Object.getOwnPropertyDescriptor(t,o);a&&a.configurable&&void 0===e[o]&&Object.defineProperty(e,o,a)}}(e.prototype.constructor=e,t)}function l(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var s=function(e,t,n,r,o,a,i,u){if(!e){var l;if(void 0===t)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var s=[n,r,o,a,i,u],c=0;(l=new Error(t.replace(/%s/g,function(){return s[c++]}))).name="Invariant Violation"}throw l.framesToPop=1,l}};function c(e,t,n){if("selectionStart"in e&&"selectionEnd"in e)e.selectionStart=t,e.selectionEnd=n;else{var r=e.createTextRange();r.collapse(!0),r.moveStart("character",t),r.moveEnd("character",n-t),r.select()}}var f={9:"[0-9]",a:"[A-Za-z]","*":"[A-Za-z0-9]"},h="_";function p(e,t,n){var r="",o="",a=null,i=[];if(void 0===t&&(t=h),null==n&&(n=f),!e||"string"!=typeof e)return{maskChar:t,formatChars:n,mask:null,prefix:null,lastEditablePosition:null,permanents:[]};var u=!1;return e.split("").forEach(function(e){u=!u&&"\\"===e||(u||!n[e]?(i.push(r.length),r.length===i.length-1&&(o+=e)):a=r.length+1,r+=e,!1)}),{maskChar:t,formatChars:n,prefix:o,mask:r,lastEditablePosition:a,permanents:i}}function d(e,t){return-1!==e.permanents.indexOf(t)}function v(e,t,n){var r=e.mask,o=e.formatChars;if(!n)return!1;if(d(e,t))return r[t]===n;var a=o[r[t]];return new RegExp(a).test(n)}function m(e,t){return t.split("").every(function(t,n){return d(e,n)||!v(e,n,t)})}function g(e,t){var n=e.maskChar,r=e.prefix;if(!n){for(;t.length>r.length&&d(e,t.length-1);)t=t.slice(0,t.length-1);return t.length}for(var o=r.length,a=t.length;a>=r.length;a--){var i=t[a];if(!d(e,a)&&v(e,a,i)){o=a+1;break}}return o}function y(e,t){return g(e,t)===e.mask.length}function w(e,t){var n=e.maskChar,r=e.mask,o=e.prefix;if(!n){for((t=k(e,"",t,0)).length<o.length&&(t=o);t.length<r.length&&d(e,t.length);)t+=r[t.length];return t}if(t)return k(e,w(e,""),t,0);for(var a=0;a<r.length;a++)d(e,a)?t+=r[a]:t+=n;return t}function k(e,t,n,r){var o=e.mask,a=e.maskChar,i=e.prefix,u=n.split(""),l=y(e,t);return!a&&r>t.length&&(t+=o.slice(t.length,r)),u.every(function(n){for(;c=n,d(e,s=r)&&c!==o[s];){if(r>=t.length&&(t+=o[r]),u=n,a&&d(e,r)&&u===a)return!0;if(++r>=o.length)return!1}var u,s,c;return!v(e,r,n)&&n!==a||(r<t.length?t=a||l||r<i.length?t.slice(0,r)+n+t.slice(r+1):(t=t.slice(0,r)+n+t.slice(r),w(e,t)):a||(t+=n),++r<o.length)}),t}function E(e,t){for(var n=e.mask,r=t;r<n.length;++r)if(!d(e,r))return r;return null}function b(e){return e||0===e?e+"":""}function O(e,t,n,r,o){var a=e.mask,i=e.prefix,u=e.lastEditablePosition,l=t,s="",c=0,f=0,h=Math.min(o.start,n.start);return n.end>o.start?f=(c=function(e,t,n,r){var o=e.mask,a=e.maskChar,i=n.split(""),u=r;return i.every(function(t){for(;i=t,d(e,n=r)&&i!==o[n];)if(++r>=o.length)return!1;var n,i;return(v(e,r,t)||t===a)&&r++,r<o.length}),r-u}(e,0,s=l.slice(o.start,n.end),h))?o.length:0:l.length<r.length&&(f=r.length-l.length),l=r,f&&(1!==f||o.length||(h=o.start===n.start?E(e,n.start):function(e,t){for(var n=t;0<=n;--n)if(!d(e,n))return n;return null}(e,n.start)),l=function(e,t,n,r){var o=n+r,a=e.maskChar,i=e.mask,u=e.prefix,l=t.split("");if(a)return l.map(function(t,r){return r<n||o<=r?t:d(e,r)?i[r]:a}).join("");for(var s=o;s<l.length;s++)d(e,s)&&(l[s]="");return n=Math.max(u.length,n),l.splice(n,o-n),t=l.join(""),w(e,t)}(e,l,h,f)),l=k(e,l,s,h),(h+=c)>=a.length?h=a.length:h<i.length&&!c?h=i.length:h>=i.length&&h<u&&c&&(h=E(e,h)),s||(s=null),{value:l=w(e,l),enteredString:s,selection:{start:h,end:h}}}function S(e){return"function"==typeof e}function L(){return window.cancelAnimationFrame||window.webkitCancelRequestAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame}function x(e){return(L()?window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame:function(){return setTimeout(e,1e3/60)})(e)}function C(e){(L()||clearTimeout)(e)}var D=function(e){function t(t){var n=e.call(this,t)||this;n.focused=!1,n.mounted=!1,n.previousSelection=null,n.selectionDeferId=null,n.saveSelectionLoopDeferId=null,n.saveSelectionLoop=function(){n.previousSelection=n.getSelection(),n.saveSelectionLoopDeferId=x(n.saveSelectionLoop)},n.runSaveSelectionLoop=function(){null===n.saveSelectionLoopDeferId&&n.saveSelectionLoop()},n.stopSaveSelectionLoop=function(){null!==n.saveSelectionLoopDeferId&&(C(n.saveSelectionLoopDeferId),n.saveSelectionLoopDeferId=null,n.previousSelection=null)},n.getInputDOMNode=function(){if(!n.mounted)return null;var e=a.findDOMNode(l(l(n))),t="undefined"!=typeof window&&e instanceof window.Element;if(e&&!t)return null;if("INPUT"!==e.nodeName&&(e=e.querySelector("input")),!e)throw new Error("react-input-mask: inputComponent doesn't contain input node");return e},n.getInputValue=function(){var e=n.getInputDOMNode();return e?e.value:null},n.setInputValue=function(e){var t=n.getInputDOMNode();t&&(n.value=e,t.value=e)},n.setCursorToEnd=function(){var e=g(n.maskOptions,n.value),t=E(n.maskOptions,e);null!==t&&n.setCursorPosition(t)},n.setSelection=function(e,t,r){void 0===r&&(r={});var o=n.getInputDOMNode(),a=n.isFocused();o&&a&&(r.deferred||c(o,e,t),null!==n.selectionDeferId&&C(n.selectionDeferId),n.selectionDeferId=x(function(){n.selectionDeferId=null,c(o,e,t)}),n.previousSelection={start:e,end:t,length:Math.abs(t-e)})},n.getSelection=function(){return function(e){var t=0,n=0;if("selectionStart"in e&&"selectionEnd"in e)t=e.selectionStart,n=e.selectionEnd;else{var r=document.selection.createRange();r.parentElement()===e&&(t=-r.moveStart("character",-e.value.length),n=-r.moveEnd("character",-e.value.length))}return{start:t,end:n,length:n-t}}(n.getInputDOMNode())},n.getCursorPosition=function(){return n.getSelection().start},n.setCursorPosition=function(e){n.setSelection(e,e)},n.isFocused=function(){return n.focused},n.getBeforeMaskedValueChangeConfig=function(){var e=n.maskOptions,t=e.mask,r=e.maskChar,o=e.permanents,a=e.formatChars;return{mask:t,maskChar:r,permanents:o,alwaysShowMask:!!n.props.alwaysShowMask,formatChars:a}},n.isInputAutofilled=function(e,t,r,o){var a=n.getInputDOMNode();try{if(a.matches(":-webkit-autofill"))return!0}catch(s){}return!n.focused||o.end<r.length&&t.end===e.length},n.onChange=function(e){var t=l(l(n)).beforePasteState,r=l(l(n)).previousSelection,o=n.props.beforeMaskedValueChange,a=n.getInputValue(),i=n.value,u=n.getSelection();n.isInputAutofilled(a,u,i,r)&&(i=w(n.maskOptions,""),r={start:0,end:0,length:0}),t&&(r=t.selection,i=t.value,u={start:r.start+a.length,end:r.start+a.length,length:0},a=i.slice(0,r.start)+a+i.slice(r.end),n.beforePasteState=null);var s=O(n.maskOptions,a,u,i,r),c=s.enteredString,f=s.selection,h=s.value;if(S(o)){var p=o({value:h,selection:f},{value:i,selection:r},c,n.getBeforeMaskedValueChangeConfig());h=p.value,f=p.selection}n.setInputValue(h),S(n.props.onChange)&&n.props.onChange(e),n.isWindowsPhoneBrowser?n.setSelection(f.start,f.end,{deferred:!0}):n.setSelection(f.start,f.end)},n.onFocus=function(e){var t=n.props.beforeMaskedValueChange,r=n.maskOptions,o=r.mask,a=r.prefix;if(n.focused=!0,n.mounted=!0,o){if(n.value)g(n.maskOptions,n.value)<n.maskOptions.mask.length&&n.setCursorToEnd();else{var i=w(n.maskOptions,a),u=w(n.maskOptions,i),l=g(n.maskOptions,u),s=E(n.maskOptions,l),c={start:s,end:s};if(S(t)){var f=t({value:u,selection:c},{value:n.value,selection:null},null,n.getBeforeMaskedValueChangeConfig());u=f.value,c=f.selection}var h=u!==n.getInputValue();h&&n.setInputValue(u),h&&S(n.props.onChange)&&n.props.onChange(e),n.setSelection(c.start,c.end)}n.runSaveSelectionLoop()}S(n.props.onFocus)&&n.props.onFocus(e)},n.onBlur=function(e){var t=n.props.beforeMaskedValueChange,r=n.maskOptions.mask;if(n.stopSaveSelectionLoop(),n.focused=!1,r&&!n.props.alwaysShowMask&&m(n.maskOptions,n.value)){var o="";S(t)&&(o=t({value:o,selection:null},{value:n.value,selection:n.previousSelection},null,n.getBeforeMaskedValueChangeConfig()).value);var a=o!==n.getInputValue();a&&n.setInputValue(o),a&&S(n.props.onChange)&&n.props.onChange(e)}S(n.props.onBlur)&&n.props.onBlur(e)},n.onMouseDown=function(e){if(!n.focused&&document.addEventListener){n.mouseDownX=e.clientX,n.mouseDownY=e.clientY,n.mouseDownTime=(new Date).getTime();document.addEventListener("mouseup",function e(t){if(document.removeEventListener("mouseup",e),n.focused){var r=Math.abs(t.clientX-n.mouseDownX),o=Math.abs(t.clientY-n.mouseDownY),a=Math.max(r,o),i=(new Date).getTime()-n.mouseDownTime;(a<=10&&i<=200||a<=5&&i<=300)&&n.setCursorToEnd()}})}S(n.props.onMouseDown)&&n.props.onMouseDown(e)},n.onPaste=function(e){S(n.props.onPaste)&&n.props.onPaste(e),e.defaultPrevented||(n.beforePasteState={value:n.getInputValue(),selection:n.getSelection()},n.setInputValue(""))},n.handleRef=function(e){null==n.props.children&&S(n.props.inputRef)&&n.props.inputRef(e)};var r=t.mask,o=t.maskChar,i=t.formatChars,u=t.alwaysShowMask,s=t.beforeMaskedValueChange,f=t.defaultValue,h=t.value;n.maskOptions=p(r,o,i),null==f&&(f=""),null==h&&(h=f);var d=b(h);if(n.maskOptions.mask&&(u||d)&&(d=w(n.maskOptions,d),S(s))){var v=t.value;null==t.value&&(v=f),d=s({value:d,selection:null},{value:v=b(v),selection:null},null,n.getBeforeMaskedValueChangeConfig()).value}return n.value=d,n}u(t,e);var n=t.prototype;return n.componentDidMount=function(){this.mounted=!0,this.getInputDOMNode()&&(this.isWindowsPhoneBrowser=function(){var e=new RegExp("windows","i"),t=new RegExp("phone","i"),n=navigator.userAgent;return e.test(n)&&t.test(n)}(),this.maskOptions.mask&&this.getInputValue()!==this.value&&this.setInputValue(this.value))},n.componentDidUpdate=function(){var e=this.previousSelection,t=this.props,n=t.beforeMaskedValueChange,r=t.alwaysShowMask,o=t.mask,a=t.maskChar,i=t.formatChars,u=this.maskOptions,l=r||this.isFocused(),s=null!=this.props.value,c=s?b(this.props.value):this.value,f=e?e.start:null;if(this.maskOptions=p(o,a,i),this.maskOptions.mask){!u.mask&&this.isFocused()&&this.runSaveSelectionLoop();var h=this.maskOptions.mask&&this.maskOptions.mask!==u.mask;if(u.mask||s||(c=this.getInputValue()),(h||this.maskOptions.mask&&(c||l))&&(c=w(this.maskOptions,c)),h){var d=g(this.maskOptions,c);(null===f||d<f)&&(f=y(this.maskOptions,c)?d:E(this.maskOptions,d))}!this.maskOptions.mask||!m(this.maskOptions,c)||l||s&&this.props.value||(c="");var v={start:f,end:f};if(S(n)){var k=n({value:c,selection:v},{value:this.value,selection:this.previousSelection},null,this.getBeforeMaskedValueChangeConfig());c=k.value,v=k.selection}this.value=c;var O=this.getInputValue()!==this.value;O?(this.setInputValue(this.value),this.forceUpdate()):h&&this.forceUpdate();var L=!1;null!=v.start&&null!=v.end&&(L=!e||e.start!==v.start||e.end!==v.end),(L||O)&&this.setSelection(v.start,v.end)}else u.mask&&(this.stopSaveSelectionLoop(),this.forceUpdate())},n.componentWillUnmount=function(){this.mounted=!1,null!==this.selectionDeferId&&C(this.selectionDeferId),this.stopSaveSelectionLoop()},n.render=function(){var e,t=this.props,n=(t.mask,t.alwaysShowMask,t.maskChar,t.formatChars,t.inputRef,t.beforeMaskedValueChange,t.children),r=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],0<=t.indexOf(n)||(o[n]=e[n]);return o}(t,["mask","alwaysShowMask","maskChar","formatChars","inputRef","beforeMaskedValueChange","children"]);if(n){S(n)||s(!1);var a=["onChange","onPaste","onMouseDown","onFocus","onBlur","value","disabled","readOnly"],u=i({},r);a.forEach(function(e){return delete u[e]}),e=n(u),a.filter(function(t){return null!=e.props[t]&&e.props[t]!==r[t]}).length&&s(!1)}else e=o.createElement("input",i({ref:this.handleRef},r));var l={onFocus:this.onFocus,onBlur:this.onBlur};return this.maskOptions.mask&&(r.disabled||r.readOnly||(l.onChange=this.onChange,l.onPaste=this.onPaste,l.onMouseDown=this.onMouseDown),null!=r.value&&(l.value=this.value)),e=o.cloneElement(e,l)},t}(o.Component);e.exports=D},533:function(e,t,n){"use strict";n.d(t,"a",function(){return u});var r=n(68),o=n(271),a=n(267);function i(){i=function(){return t};var e,t={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeof Symbol?Symbol:{},u=a.iterator||"@@iterator",l=a.asyncIterator||"@@asyncIterator",s=a.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function f(e,t,n,r){var a=t&&t.prototype instanceof y?t:y,i=Object.create(a.prototype),u=new I(r||[]);return o(i,"_invoke",{value:C(e,n,u)}),i}function h(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}t.wrap=f;var p="suspendedStart",d="suspendedYield",v="executing",m="completed",g={};function y(){}function w(){}function k(){}var E={};c(E,u,function(){return this});var b=Object.getPrototypeOf,O=b&&b(b(M([])));O&&O!==n&&r.call(O,u)&&(E=O);var S=k.prototype=y.prototype=Object.create(E);function L(e){["next","throw","return"].forEach(function(t){c(e,t,function(e){return this._invoke(t,e)})})}function x(e,t){function n(o,a,i,u){var l=h(e[o],e,a);if("throw"!==l.type){var s=l.arg,c=s.value;return c&&"object"==typeof c&&r.call(c,"__await")?t.resolve(c.__await).then(function(e){n("next",e,i,u)},function(e){n("throw",e,i,u)}):t.resolve(c).then(function(e){s.value=e,i(s)},function(e){return n("throw",e,i,u)})}u(l.arg)}var a;o(this,"_invoke",{value:function(e,r){function o(){return new t(function(t,o){n(e,r,t,o)})}return a=a?a.then(o,o):o()}})}function C(t,n,r){var o=p;return function(a,i){if(o===v)throw new Error("Generator is already running");if(o===m){if("throw"===a)throw i;return{value:e,done:!0}}for(r.method=a,r.arg=i;;){var u=r.delegate;if(u){var l=D(u,r);if(l){if(l===g)continue;return l}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===p)throw o=m,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=v;var s=h(t,n,r);if("normal"===s.type){if(o=r.done?m:d,s.arg===g)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(o=m,r.method="throw",r.arg=s.arg)}}}function D(t,n){var r=n.method,o=t.iterator[r];if(o===e)return n.delegate=null,"throw"===r&&t.iterator.return&&(n.method="return",n.arg=e,D(t,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),g;var a=h(o,t.iterator,n.arg);if("throw"===a.type)return n.method="throw",n.arg=a.arg,n.delegate=null,g;var i=a.arg;return i?i.done?(n[t.resultName]=i.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=e),n.delegate=null,g):i:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,g)}function j(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function I(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(j,this),this.reset(!0)}function M(t){if(t||""===t){var n=t[u];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function n(){for(;++o<t.length;)if(r.call(t,o))return n.value=t[o],n.done=!1,n;return n.value=e,n.done=!0,n};return a.next=a}}throw new TypeError(typeof t+" is not iterable")}return w.prototype=k,o(S,"constructor",{value:k,configurable:!0}),o(k,"constructor",{value:w,configurable:!0}),w.displayName=c(k,s,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,k):(e.__proto__=k,c(e,s,"GeneratorFunction")),e.prototype=Object.create(S),e},t.awrap=function(e){return{__await:e}},L(x.prototype),c(x.prototype,l,function(){return this}),t.AsyncIterator=x,t.async=function(e,n,r,o,a){void 0===a&&(a=Promise);var i=new x(f(e,n,r,o),a);return t.isGeneratorFunction(n)?i:i.next().then(function(e){return e.done?e.value:i.next()})},L(S),c(S,s,"Generator"),c(S,u,function(){return this}),c(S,"toString",function(){return"[object Generator]"}),t.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},t.values=M,I.prototype={constructor:I,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(P),!t)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function o(r,o){return u.type="throw",u.arg=t,n.next=r,o&&(n.method="next",n.arg=e),!!o}for(var a=this.tryEntries.length-1;a>=0;--a){var i=this.tryEntries[a],u=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var l=r.call(i,"catchLoc"),s=r.call(i,"finallyLoc");if(l&&s){if(this.prev<i.catchLoc)return o(i.catchLoc,!0);if(this.prev<i.finallyLoc)return o(i.finallyLoc)}else if(l){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(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var a=o;break}}a&&("break"===e||"continue"===e)&&a.tryLoc<=t&&t<=a.finallyLoc&&(a=null);var i=a?a.completion:{};return i.type=e,i.arg=t,a?(this.method="next",this.next=a.finallyLoc,g):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),g},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),P(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;P(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:M(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},t}var u=function(e){return function(){var t=Object(r.a)(i().mark(function t(n,r){var u,l,s,c,f;return i().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:return u=r(),n({type:"SET_LOADER"}),t.next=4,o.a.post("app.php?a=submitUploadedPhotocopy&univcode="+u.univ.funivcode,{data:e});case 4:l=t.sent,n({type:"UNSET_LOADER"}),"object"!==typeof l.data?(s={header:"Error",content:"Something went wrong"},n(Object(a.A)(s))):-1===l.data.error_code?(c={header:"Error",content:l.data.msg},n(Object(a.A)(c))):(f={header:"Success",content:l.data.msg},n(Object(a.A)(f)));case 7:case"end":return t.stop()}},t)}));return function(e,n){return t.apply(this,arguments)}}()}}}]);
//# sourceMappingURL=98.ff7393e7.chunk.js.map
|